mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
Bug 1084545 - Update nav button stroke colors. r=lucasr
This commit is contained in:
parent
824b808bb4
commit
2eb2c49e92
@ -110,6 +110,9 @@
|
||||
<color name="url_bar_blockedtext">#b14646</color>
|
||||
<color name="url_bar_shadow">#12000000</color>
|
||||
|
||||
<color name="nav_button_border_color">#BFBFBF</color>
|
||||
<color name="nav_button_border_color_private">#5F6368</color>
|
||||
|
||||
<color name="home_button_bar_bg">#FFF5F7F9</color>
|
||||
|
||||
<!-- Colour used for share overlay button labels -->
|
||||
|
@ -13,13 +13,6 @@ public class BackButton extends NavButton {
|
||||
super(context, attrs);
|
||||
}
|
||||
|
||||
// TODO: The only reason we can't inherit this method is because there's a color inconsistency.
|
||||
@Override
|
||||
public void setPrivateMode(boolean isPrivate) {
|
||||
super.setPrivateMode(isPrivate);
|
||||
mBorderPaint.setColor(isPrivate ? 0xFF363B40 : 0xFFB5B5B5);
|
||||
}
|
||||
|
||||
@Override
|
||||
protected void onSizeChanged(int width, int height, int oldWidth, int oldHeight) {
|
||||
super.onSizeChanged(width, height, oldWidth, oldHeight);
|
||||
|
@ -12,13 +12,6 @@ public class ForwardButton extends NavButton {
|
||||
super(context, attrs);
|
||||
}
|
||||
|
||||
// TODO: The only reason we can't inherit this method is because there's a color inconsistency.
|
||||
@Override
|
||||
public void setPrivateMode(boolean isPrivate) {
|
||||
super.setPrivateMode(isPrivate);
|
||||
mBorderPaint.setColor(isPrivate ? 0xFF363B40 : 0xFFBFBFBF);
|
||||
}
|
||||
|
||||
@Override
|
||||
protected void onSizeChanged(int width, int height, int oldWidth, int oldHeight) {
|
||||
super.onSizeChanged(width, height, oldWidth, oldHeight);
|
||||
|
@ -20,10 +20,15 @@ abstract class NavButton extends ShapedButton {
|
||||
protected final Paint mBorderPaint;
|
||||
protected final float mBorderWidth;
|
||||
|
||||
protected final int mBorderColor;
|
||||
protected final int mBorderColorPrivate;
|
||||
|
||||
public NavButton(Context context, AttributeSet attrs) {
|
||||
super(context, attrs);
|
||||
|
||||
final Resources res = getResources();
|
||||
mBorderColor = res.getColor(R.color.nav_button_border_color);
|
||||
mBorderColorPrivate = res.getColor(R.color.nav_button_border_color_private);
|
||||
mBorderWidth = res.getDimension(R.dimen.nav_button_border_width);
|
||||
|
||||
// Paint to draw the border.
|
||||
@ -38,6 +43,12 @@ abstract class NavButton extends ShapedButton {
|
||||
setPrivateMode(false);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void setPrivateMode(boolean isPrivate) {
|
||||
super.setPrivateMode(isPrivate);
|
||||
mBorderPaint.setColor(isPrivate ? mBorderColorPrivate : mBorderColor);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void draw(Canvas canvas) {
|
||||
super.draw(canvas);
|
||||
|
Loading…
Reference in New Issue
Block a user