mirror of
https://github.com/godotengine/godot.git
synced 2025-11-10 02:21:15 +00:00
Android: Add option to change background color and fix system bar regression
This commit is contained in:
parent
967e2d499a
commit
0506299c21
5 changed files with 54 additions and 6 deletions
|
|
@ -324,12 +324,13 @@ abstract class BaseGodotEditor : GodotActivity(), GameMenuFragment.GameMenuListe
|
|||
}
|
||||
}
|
||||
|
||||
private fun updateImmersiveAndEdgeToEdgeModes() {
|
||||
private fun updateWindowAppearance() {
|
||||
val editorWindowInfo = getEditorWindowInfo()
|
||||
if (editorWindowInfo == EDITOR_MAIN_INFO || editorWindowInfo == RUN_GAME_INFO) {
|
||||
godot?.apply {
|
||||
enableImmersiveMode(isInImmersiveMode(), true)
|
||||
enableEdgeToEdge(isInEdgeToEdgeMode(), true)
|
||||
setSystemBarsAppearance()
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
@ -339,13 +340,13 @@ abstract class BaseGodotEditor : GodotActivity(), GameMenuFragment.GameMenuListe
|
|||
runOnUiThread {
|
||||
// Hide the loading indicator
|
||||
editorLoadingIndicator?.visibility = View.GONE
|
||||
updateImmersiveAndEdgeToEdgeModes()
|
||||
updateWindowAppearance()
|
||||
}
|
||||
}
|
||||
|
||||
override fun onResume() {
|
||||
super.onResume()
|
||||
updateImmersiveAndEdgeToEdgeModes()
|
||||
updateWindowAppearance()
|
||||
|
||||
if (getEditorWindowInfo() == EDITOR_MAIN_INFO &&
|
||||
godot?.isEditorHint() == true &&
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue