I want to set the back panel to transparent, so I installed the following code in
styles.xml <style name="dialog" parent="@android:style/Theme.Dialog"> <item name="android:windowFrame">@null</item> <item name="android:windowIsFloating">true</item> <item name="android:windowContentOverlay">@null</item> <item name="android:windowAnimationStyle">@android:style/Animation.Dialog</item> <item name="android:windowSoftInputMode">stateUnspecified|adjustPan</item> <item name="android:windowBackground">@android:color/transparent</item> <item name="android:windowNoTitle">true</item> </style>
And I use Progressdialog as the following code in the JAVA file and in fragment .
Activity activity = getActivity() ; mProgressDialog = new ProgressDialog(activity,R.style.dialog) ; mProgressDialog.setCancelable(false) ; mProgressDialog.show() ;
But I get progress, as in the following figure, and it does not have a transparent background.

Why doesn't the background change to transparent?
android android-styles progressdialog
Martin Feb 22 '14 at 16:49 2014-02-22 16:49
source share