Fix following three issues in SD Card UX
1) Link should not work if up-events happen outside the target region 2) Activity should retain it's last state on changing configuration 3) Improve color contrast for "Format card" button Bug: 246485658 Bug: 246681292 Bug: 246871051 Change-Id: Iebc87e35a3f8496a33a43d906b7faba05d95fe6c
This commit is contained in:
@@ -47,6 +47,7 @@ import com.google.android.setupcompat.template.FooterBarMixin;
|
||||
import com.google.android.setupcompat.template.FooterButton;
|
||||
import com.google.android.setupdesign.GlifLayout;
|
||||
import com.google.android.setupdesign.util.ThemeHelper;
|
||||
import com.google.android.setupdesign.util.ThemeResolver;
|
||||
|
||||
import java.text.NumberFormat;
|
||||
import java.util.List;
|
||||
@@ -72,7 +73,15 @@ public abstract class StorageWizardBase extends FragmentActivity {
|
||||
|
||||
@Override
|
||||
protected void onCreate(Bundle savedInstanceState) {
|
||||
setTheme(SetupWizardUtils.getTheme(this, getIntent()));
|
||||
boolean isDayNightThemeSupportedBySuW = ThemeHelper.isSetupWizardDayNightEnabled(this);
|
||||
int sudTheme =
|
||||
new ThemeResolver.Builder(ThemeResolver.getDefault())
|
||||
.setDefaultTheme(ThemeHelper.getSuwDefaultTheme(this))
|
||||
.setUseDayNight(true)
|
||||
.build()
|
||||
.resolve("", !isDayNightThemeSupportedBySuW);
|
||||
|
||||
this.setTheme(sudTheme);
|
||||
ThemeHelper.trySetDynamicColor(this);
|
||||
super.onCreate(savedInstanceState);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user