When I switch from one activity to another activity, a black screen appears within a few seconds between transactions. I will finish the job correctly before calling startActvity () .
I use the theme android: theme = "@android: style / Theme.Translucent" for my activity. Although a black screen appears between the activity transaction
Can someone tell me how to solve this problem?
Thank you in advance:)
startActivity().
, onCreate ( onCreate, onStart onResume, ).
:
<style name="noAnimTheme" parent="android:Theme"> <item name="android:windowAnimationStyle">@null</item> </style>
<activity android:name=".ui.ArticlesActivity" android:theme="@style/noAnimTheme"> </activity>
: -
protected void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.xyz); // comment code here }
A B, OnCreate, OnResume B. , , , . , .
, , . :
startActivity(new Intent(this, MyNextActivity.class));
, .
, , , :
<item name="android:windowBackground">@drawable/window_background</item> <shape xmlns:android="http://schemas.android.com/apk/res/android" android:shape="rectangle"> <solid android:color="@color/window_background"/> </shape>
windowBackground Android 6 (Marshmallow)
- , . .
How to remove the delay when opening an operation using DrawerLayout?
Source: https://habr.com/ru/post/1620717/More articles:How to download standalone installer for ASP.NET 5 - asp.net-coreHide method works, but doesn't turn off in jQuery - javascriptIOS image from Retina Size URL? - iosBootstrap 3 modal - slideIn bottom and stick - javascriptseo toolkit - request denied by robots.txt rule - seoUnmarshalling type codes and offset value and their value? - androidВставка данных из массива в datatable - c#Copy to Datatable - c #Provide an implementation of an abstract method, but limit visibility - javaHow can you control a variable during a Matlab loop without printing it? - loopsAll Articles