-
Notifications
You must be signed in to change notification settings - Fork 502
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix part of #3258 : Replacing CircularImageView with ShapeableImageView #4139
Conversation
PTAL @BenHenning |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks @bhaktideshmukh! Apologies for the delayed review.
I just took a first pass--PTAL. I also think that you have failing tests. Please make sure that affected tests are passing (I think one of my comments will help with this).
@@ -33,7 +33,7 @@ | |||
app:layout_constraintStart_toStartOf="parent" | |||
app:layout_constraintTop_toTopOf="parent" /> | |||
|
|||
<de.hdodenhof.circleimageview.CircleImageView | |||
<com.google.android.material.imageview.ShapeableImageView |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This & later changes don't require the appearance overlay property to be set?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I added the appearance overlay property here.
app/src/main/res/layout-sw600dp-land/profile_chooser_add_view.xml
Outdated
Show resolved
Hide resolved
@@ -459,4 +459,9 @@ | |||
<item name="android:gravity">center_horizontal</item> | |||
</style> | |||
|
|||
<!-- ShapeableImageView --> | |||
<style name="ShapeAppearanceOverlay.App.Circular" parent=""> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I believe you can omit parent if it isn't defined.
@@ -459,4 +459,9 @@ | |||
<item name="android:gravity">center_horizontal</item> | |||
</style> | |||
|
|||
<!-- ShapeableImageView --> | |||
<style name="ShapeAppearanceOverlay.App.Circular" parent=""> | |||
<item name="cornerSize">50%</item> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is there documentation that you can point to explaining this property?
Also, I'm not sure about the style & item names (both in terms of formatting consistency and the way the style name is broken up). @rt4914 what are your thoughts?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Given other styles names that we have like
TextInputLayout
,
TextInputEditText
,
AppTabTextAppearance
I think ShapeableImageView.Circular
can be a good name because it clearly mentions where to use this theme (ShapeableImageView) and also what will be the output of the theme (Circular).
Also @rt4914 I noticed in the screenshots that the 'add profile' button isn't aligned with the others--is this a recent regression? |
5fa7648
to
e07e458
Compare
PTAL @BenHenning |
Unassigning @bhaktideshmukh since a re-review was requested. @bhaktideshmukh, please make sure you have addressed all review comments. Thanks! |
b76ed47
to
80dc56e
Compare
@BenHenning Its a known issue, mentioned in #2116 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@bhaktideshmukh Please rename the PR title and description to mention ``Fix part of #instead of
Fix #...` because once this PR is approved you will need to do similar changes in other places too like `ProfileProgress`, `ProfileList`, `ProfileEdit` and in last you will need to remove the existing `CircularImageView` library mentioned in the issue.
@bhaktideshmukh Please add screenshot of MDPIP device and API 21 too. |
80dc56e
to
8cda1f2
Compare
Done! |
Here for MDPI API 21 is not available. |
@rt4914 PTAL |
Unassigning @bhaktideshmukh since a re-review was requested. @bhaktideshmukh, please make sure you have addressed all review comments. Thanks! |
@bhaktideshmukh Select the second tab which is |
Done!! |
PTAL @rt4914 |
Apologies @bhaktideshmukh but I'll need to close this since you force pushed the branch. Please open a new PR. In the future, you should never force push as it can break comment history. See step 3 under https://github.com/oppia/oppia-android/wiki/Making-a-code-change#making-a-code-change-using-the-terminal (though I suggest reviewing all those instructions to make sure you know our process). Once the PR is recreated, we can take another review pass on it. |
I apologize for my mistake. I read the instructions. |
Explanation
Fix part of #3258 : Replacing CircularImageView with ShapeableImageView.
Screenshots
Phone portrait mode
Phone landscape mode
Tablet portrait mode
Tablet landscape mode
Essential Checklist
For UI-specific PRs only
If your PR includes UI-related changes, then: