зеркало из https://github.com/mozilla/gecko-dev.git
Bug 720698: ICS should use blue outline color for URL bar. [r=mfinkle]
This commit is contained in:
Родитель
51da29200e
Коммит
47138fc0a2
|
@ -93,6 +93,19 @@ public class BrowserToolbar extends LinearLayout {
|
|||
super(context, attrs);
|
||||
mContext = context;
|
||||
mInflated = false;
|
||||
|
||||
// Get the device's highlight color
|
||||
TypedArray typedArray;
|
||||
|
||||
if (Build.VERSION.SDK_INT >= 11) {
|
||||
typedArray = context.obtainStyledAttributes(new int[] { android.R.attr.textColorHighlight });
|
||||
} else {
|
||||
ContextThemeWrapper wrapper = new ContextThemeWrapper(mContext, android.R.style.TextAppearance);
|
||||
typedArray = wrapper.getTheme().obtainStyledAttributes(new int[] { android.R.attr.textColorHighlight });
|
||||
}
|
||||
|
||||
mColor = typedArray.getColor(typedArray.getIndex(0), 0);
|
||||
typedArray.recycle();
|
||||
}
|
||||
|
||||
@Override
|
||||
|
@ -107,11 +120,6 @@ public class BrowserToolbar extends LinearLayout {
|
|||
|
||||
mInflated = true;
|
||||
|
||||
// Get the device's highlight color
|
||||
ContextThemeWrapper wrapper = new ContextThemeWrapper(mContext, android.R.style.TextAppearance);
|
||||
TypedArray typedArray = wrapper.getTheme().obtainStyledAttributes(new int[] { android.R.attr.textColorHighlight });
|
||||
mColor = typedArray.getColor(typedArray.getIndex(0), 0);
|
||||
|
||||
mAwesomeBar = (Button) findViewById(R.id.awesome_bar);
|
||||
mAwesomeBar.setOnClickListener(new Button.OnClickListener() {
|
||||
public void onClick(View v) {
|
||||
|
|
Загрузка…
Ссылка в новой задаче