-
Notifications
You must be signed in to change notification settings - Fork 24.3k
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
[Android] update scroll views to support wide gamut color #43197
base: main
Are you sure you want to change the base?
[Android] update scroll views to support wide gamut color #43197
Conversation
eeb6432
to
42778aa
Compare
@cipolleschi has imported this pull request. If you are a Meta employee, you can view this diff on Phabricator. |
1 similar comment
@cipolleschi has imported this pull request. If you are a Meta employee, you can view this diff on Phabricator. |
@@ -857,9 +858,10 @@ private boolean isScrollPerfLoggingEnabled() { | |||
public void draw(Canvas canvas) { | |||
if (mEndFillColor != Color.TRANSPARENT) { |
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 doesn't seem right, since we are now comparing int color to packed color long.
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 in this case they both evaluate to 0L but I'll update to make it explicit.
if (contentView != null && contentView.getBottom() < getHeight()) { | ||
Paint paint = new Paint(); | ||
paint.setColor(mEndFillColor); | ||
canvas.drawRect(0, contentView.getBottom(), getWidth(), getHeight(), paint); |
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.
Why do we do this if we are creating mEndBackground
from new color?
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.
That was an oversight. I meant to remove mEndBackground
as we need to draw on the canvas directly in order to use paint.
/rebase |
cfbfc83
to
07105c3
Compare
This PR is stale because it has been open 180 days with no activity. Remove stale label or comment or this will be closed in 7 days. |
do not close |
Summary:
This builds on previous PRs for the wide gamut color RFC and extends Android scroll views with support for DisplayP3 color.
Changelog:
[ANDROID] [ADDED] - update scroll views to support wide gamut color
Test Plan:
[JS] Add support for CSS4 color() functions #42831
[Android] Update ColorPropConverterto support color function values #43031
[Android] Add isWideColorGamutEnabled to ReactActivityDelegate #43036
[Android] Add DisplayP3 background and border support to View #43056