T trueboss323 Active Member Licensed User Longtime User Apr 29, 2017 #1 Right now, when the user opens my app, they are greeted with a black screen that lasts for a few seconds before the main activity appears. Instead I would like it to to have a splash screen of the app's icon , and then have that icon animate to zoom out to fit as the Activity action bar icon. Or something similar. So at least this gives a nice animation. I know this is possible and it shouldn't be difficult but I was unable to find any help with this.
Right now, when the user opens my app, they are greeted with a black screen that lasts for a few seconds before the main activity appears. Instead I would like it to to have a splash screen of the app's icon , and then have that icon animate to zoom out to fit as the Activity action bar icon. Or something similar. So at least this gives a nice animation. I know this is possible and it shouldn't be difficult but I was unable to find any help with this.
T trueboss323 Active Member Licensed User Longtime User Apr 29, 2017 #3 It's pretty good but it wasn't exactly what I'm looking for. Take for example the Youtube app when you open it , the youtube icon immediately appears with the splash screen sliding from the bottom to the top. Then it fades after a moment and shows the main activity. Upvote 0
It's pretty good but it wasn't exactly what I'm looking for. Take for example the Youtube app when you open it , the youtube icon immediately appears with the splash screen sliding from the bottom to the top. Then it fades after a moment and shows the main activity.
moster67 Expert Licensed User Longtime User Apr 29, 2017 #4 This one is nice https://www.b4x.com/android/forum/threads/how-to-make-a-simple-loading-screen.39476/#content Upvote 0
This one is nice https://www.b4x.com/android/forum/threads/how-to-make-a-simple-loading-screen.39476/#content
T trueboss323 Active Member Licensed User Longtime User May 3, 2017 #5 That one is based on webview, which requries to have webview loaded to start the animation. The one i'm talking about loads instatly the moment you launch the app. You see this in apps like Youtube, Maps , Facebook, Twitter, etc. Upvote 0
That one is based on webview, which requries to have webview loaded to start the animation. The one i'm talking about loads instatly the moment you launch the app. You see this in apps like Youtube, Maps , Facebook, Twitter, etc.
T trueboss323 Active Member Licensed User Longtime User Sep 7, 2017 #6 Anyone? I tried it again by opening the Youtube app , I get instantly greeted with the splash screen when I open it. With my app, I get a blank activity, with the Title bar at top while my app loads until LoadLayout is called. But even when I place this at the very beginning of the sub I still get that blank activity lasting for a few seconds , it would be much better if I could replace that with a splash screen just like Youtube and other Google apps . Upvote 0
Anyone? I tried it again by opening the Youtube app , I get instantly greeted with the splash screen when I open it. With my app, I get a blank activity, with the Title bar at top while my app loads until LoadLayout is called. But even when I place this at the very beginning of the sub I still get that blank activity lasting for a few seconds , it would be much better if I could replace that with a splash screen just like Youtube and other Google apps .
Erel B4X founder Staff member Licensed User Longtime User Sep 7, 2017 #7 There are several ways to remove the action bar before the UI is ready. The simplest way is to use an AppCompat theme (https://www.b4x.com/android/forum/threads/appcompat-with-toolbar-minimal-example.79896/#content). Upvote 0
There are several ways to remove the action bar before the UI is ready. The simplest way is to use an AppCompat theme (https://www.b4x.com/android/forum/threads/appcompat-with-toolbar-minimal-example.79896/#content).
T trueboss323 Active Member Licensed User Longtime User Sep 7, 2017 #8 I am using the AppCompact theme. In your example when it says 'Waiting for IDE debugger to connect" there is a bit of a delay and shows that white screen. And that is the screen I am trying to replace with a splash screen. Upvote 0
I am using the AppCompact theme. In your example when it says 'Waiting for IDE debugger to connect" there is a bit of a delay and shows that white screen. And that is the screen I am trying to replace with a splash screen.
Erel B4X founder Staff member Licensed User Longtime User Sep 7, 2017 #9 trueboss323 said: With my app, I get a blank activity, with the Title bar at top while my app loads until LoadLayout is called. Click to expand... Do you see the action bar at that point? Upvote 0
trueboss323 said: With my app, I get a blank activity, with the Title bar at top while my app loads until LoadLayout is called. Click to expand... Do you see the action bar at that point?
T trueboss323 Active Member Licensed User Longtime User Sep 7, 2017 #10 When I start it up it's not visible for a few seconds before showing my main activity. Upvote 0
Erel B4X founder Staff member Licensed User Longtime User Sep 8, 2017 #11 So this the above statement is not relevant, right? Why does it take your activity several seconds to show? What are you doing in Activity_Create (or Service_Create of the Starter service)? Upvote 0
So this the above statement is not relevant, right? Why does it take your activity several seconds to show? What are you doing in Activity_Create (or Service_Create of the Starter service)?
T trueboss323 Active Member Licensed User Longtime User Sep 9, 2017 #12 Erel said: So this the above statement is not relevant, right? Why does it take your activity several seconds to show? What are you doing in Activity_Create (or Service_Create of the Starter service)? Click to expand... This just doesn't happen with my app , I have the same issue on other projects. I did a test of creating a simple app that doesn't load too many resources , but that still has the delay. Can this be an Android limitation ? But then how could apps like Youtube , Maps, Facebook not have this issue ? Upvote 0
Erel said: So this the above statement is not relevant, right? Why does it take your activity several seconds to show? What are you doing in Activity_Create (or Service_Create of the Starter service)? Click to expand... This just doesn't happen with my app , I have the same issue on other projects. I did a test of creating a simple app that doesn't load too many resources , but that still has the delay. Can this be an Android limitation ? But then how could apps like Youtube , Maps, Facebook not have this issue ?
Erel B4X founder Staff member Licensed User Longtime User Sep 10, 2017 #13 I'm sorry but I still don't understand. If you are using AppCompat then you shouldn't see an empty activity with a title bar. You wrote in post #6 that you do see that. Maybe it will be best if you create a small project that demonstrates what you see and upload it. Upvote 0
I'm sorry but I still don't understand. If you are using AppCompat then you shouldn't see an empty activity with a title bar. You wrote in post #6 that you do see that. Maybe it will be best if you create a small project that demonstrates what you see and upload it.
T trueboss323 Active Member Licensed User Longtime User Sep 12, 2017 #14 I found this old topic , that explains what I am talking about. Moreover what bluedude was saying that there is a delay between the time it takes for Activity Create / LoadLayout to be called. That thread is over 5 years now and I wonder if anything has changed, especially now that the emulators are faster , if we could still do anything about it ? Upvote 0
I found this old topic , that explains what I am talking about. Moreover what bluedude was saying that there is a delay between the time it takes for Activity Create / LoadLayout to be called. That thread is over 5 years now and I wonder if anything has changed, especially now that the emulators are faster , if we could still do anything about it ?
Erel B4X founder Staff member Licensed User Longtime User Sep 12, 2017 #15 I'm sorry but as I tried 5 times to get a clear answer from you I cannot further help. trueboss323 said: That thread is over 5 years now and I wonder if anything has changed Click to expand... You can use AppCompat to improve the behavior. Testing performance on the emulator is a mistake. Upvote 0
I'm sorry but as I tried 5 times to get a clear answer from you I cannot further help. trueboss323 said: That thread is over 5 years now and I wonder if anything has changed Click to expand... You can use AppCompat to improve the behavior. Testing performance on the emulator is a mistake.
Mashiane Expert Licensed User Longtime User Apr 22, 2018 #16 Edit the manifest and include.. SetActivityAttribute(main, android:theme, @android:style/Theme.Translucent.NoTitleBar) Here is a splash screen example with this... https://www.b4x.com/android/forum/threads/sample-splash-screen.71517/#content Upvote 0
Edit the manifest and include.. SetActivityAttribute(main, android:theme, @android:style/Theme.Translucent.NoTitleBar) Here is a splash screen example with this... https://www.b4x.com/android/forum/threads/sample-splash-screen.71517/#content