Retain status
This commit is contained in:
parent
67ab6a131a
commit
b5c8aabb75
2 changed files with 3 additions and 4 deletions
|
@ -47,6 +47,7 @@ public class HelpActivity extends OsmandActionBarActivity {
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
protected void onCreate(Bundle savedInstanceState) {
|
protected void onCreate(Bundle savedInstanceState) {
|
||||||
|
((OsmandApplication) getApplication()).applyTheme(this);
|
||||||
super.onCreate(savedInstanceState);
|
super.onCreate(savedInstanceState);
|
||||||
FrameLayout frame = new FrameLayout(this);
|
FrameLayout frame = new FrameLayout(this);
|
||||||
frame.setId(DIALOG);
|
frame.setId(DIALOG);
|
||||||
|
@ -81,9 +82,6 @@ public class HelpActivity extends OsmandActionBarActivity {
|
||||||
@Override
|
@Override
|
||||||
public void onCreate(Bundle savedInstanceState) {
|
public void onCreate(Bundle savedInstanceState) {
|
||||||
super.onCreate(savedInstanceState);
|
super.onCreate(savedInstanceState);
|
||||||
boolean isLightTheme = (getOsmandApplication())
|
|
||||||
.getSettings().OSMAND_THEME.get() == OsmandSettings.OSMAND_LIGHT_THEME;
|
|
||||||
int themeId = isLightTheme ? R.style.OsmandLightTheme : R.style.OsmandDarkTheme;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
@NonNull
|
@NonNull
|
||||||
|
@ -335,7 +333,7 @@ public class HelpActivity extends OsmandActionBarActivity {
|
||||||
@Override
|
@Override
|
||||||
public void onClick(View v) {
|
public void onClick(View v) {
|
||||||
HelpArticleDialogFragment.instantiateWithAsset(filename, name)
|
HelpArticleDialogFragment.instantiateWithAsset(filename, name)
|
||||||
.show(ctx.getSupportFragmentManager(), null);
|
.show(ctx.getSupportFragmentManager(), "DIALOG_HELP_ARTICLE");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -38,6 +38,7 @@ public class HelpArticleDialogFragment extends DialogFragment {
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void onCreate(Bundle savedInstanceState) {
|
public void onCreate(Bundle savedInstanceState) {
|
||||||
|
setRetainInstance(true);
|
||||||
super.onCreate(savedInstanceState);
|
super.onCreate(savedInstanceState);
|
||||||
boolean isLightTheme = (getOsmandApplication())
|
boolean isLightTheme = (getOsmandApplication())
|
||||||
.getSettings().OSMAND_THEME.get() == OsmandSettings.OSMAND_LIGHT_THEME;
|
.getSettings().OSMAND_THEME.get() == OsmandSettings.OSMAND_LIGHT_THEME;
|
||||||
|
|
Loading…
Reference in a new issue