Modal: move style to xml

Summary:
The styles that get applied to the Dialogs that are created in RN are set in
`themes.xml`, so I'm moving `windowTranslucentStatus` there as well so that we
have all of them collocated.

Reviewed By: astreet

Differential Revision: D3913402

fbshipit-source-id: 8f23e84fb017c8810634ffe8279171061292b351
This commit is contained in:
Andrei Coman 2016-09-26 03:47:06 -07:00 committed by Facebook Github Bot 6
parent 7fd9e77837
commit 0abaaeead0
2 changed files with 1 additions and 2 deletions

View File

@ -247,8 +247,6 @@ public class ReactModalHostView extends ViewGroup implements LifecycleEventListe
private void updateProperties() { private void updateProperties() {
Assertions.assertNotNull(mDialog, "mDialog must exist when we call updateProperties"); Assertions.assertNotNull(mDialog, "mDialog must exist when we call updateProperties");
mDialog.getWindow().addFlags(WindowManager.LayoutParams.FLAG_TRANSLUCENT_STATUS);
if (mTransparent) { if (mTransparent) {
mDialog.getWindow().clearFlags(WindowManager.LayoutParams.FLAG_DIM_BEHIND); mDialog.getWindow().clearFlags(WindowManager.LayoutParams.FLAG_DIM_BEHIND);
} else { } else {

View File

@ -6,6 +6,7 @@
<item name="android:windowNoTitle">true</item> <item name="android:windowNoTitle">true</item>
<item name="android:windowIsFloating">false</item> <item name="android:windowIsFloating">false</item>
<item name="android:windowBackground">@android:color/transparent</item> <item name="android:windowBackground">@android:color/transparent</item>
<item name="android:windowTranslucentStatus">true</item>
</style> </style>
<style name="Theme.FullScreenDialogAnimatedSlide" parent="Theme.FullScreenDialog"> <style name="Theme.FullScreenDialogAnimatedSlide" parent="Theme.FullScreenDialog">