my god...it's insane how complicated it is to accomplish such a ridiculously simple task
@7xFuryPlayz Жыл бұрын
🤣 yes
@bran_rx Жыл бұрын
istg bro, android studio is unnecessarily complicated
@ubersticks3 жыл бұрын
Thanks again Philipp! Excellent job. I appreciate these short and sweet demos of the new features.
@ankitverma39323 жыл бұрын
Great video. Really helpful.. A kind request if you can show the rest of the features as how to show brand tagline in the bottom and custom backgroud of the splash screen.
@whitemamba003 жыл бұрын
OMG you are reading my mind, I was thinking about creating Splash Screen and now I see this :D thanks bro!
@PhilippLackner3 жыл бұрын
Yes I do
@whitemamba003 жыл бұрын
@@PhilippLackner 😮👀
@theophilus4943 жыл бұрын
thank you so much Philipp the part you helped fix the scaling of the SplashScreen icon was a great eye opener.. the video was really helpful. thank you and happy new year
@hcaltay2 жыл бұрын
If we are using a PNG file for the icon how can we do the last thing you did?
@andrewscott12532 жыл бұрын
Insane would be accurate, I think the new API is so limited and very poorly thought out. It would have been better to leave things as they are rather than enforce this hot mess on us with no proper way to disable it. Its essentially a plain colored screen (no gradients or background images supported yet) with a hole in it into which a small icon / graphic can be shown. Yes it adds animation (which no doubt will often be done poorly) but we could do that anyway in a splash screen activity if we really wanted. This little bit extra comes at the great expense of any flexibility. Now apps loose their individuality, the new splash screen is too brief without extra hack like programming. So now the Splash screen can't even do things like contain a progress indicator, it has essentially become momentary flim flam. Frankly, this represents a giant leap backwards for the sake of uniformity.
@MK-to4et2 жыл бұрын
The actual difference is minimal - if your app didn't have a splash screen (and apps shouldn't if possible IMO) the app icon is briefly shown by default in Android 12 .. that's it .. a pointless animation, I know the app I'm opening I just clicked the icon! The fallout for this is EVERY app that has a custom splash screen and targets sdk 31 will have to migrate as custom splash screens won't play nicely with the mandated splash screen. A new manifest flag to disable the system splash screen giving the developer choice would have been better. This does feel akin to Launch Screen in iOS - it seems feature parity with iOS is more important to Google ... whether anyone asked for these features or not ..
@toml10872 жыл бұрын
And funny thing is the jetpack library to support previous versions is not even stable still, although android 12 was released half year ago.
@bitwisedevs4692 жыл бұрын
Same thought
@Joske3692 жыл бұрын
Android being trash as usual, like scope storage wasn't enough. It wouldv been so much better if they put this time in improving dialogfragments
@Rajmanov2 жыл бұрын
true, this new splash screen is super buggy.
@dimokofficial Жыл бұрын
Thank you very much! I've been racking my brain for a long time why it doesn't work, I've been looking through too many tutorials but when you said it was a studio error, and if you re-enter the application, you'll see a splash screen, I understood what was the matter.
@tarsilacostalonga2 жыл бұрын
Great video, Phillip. It was not clear to me: what is the difference between the properties inside a starting with android: and those without this prefix. I heard you say the ones starting with android: are only for android 12. What about the others?
@NenadStrbic3 жыл бұрын
Brilliant, thank you Philipp, thank you very much. The actual content, cutting edge also.
@sumitsuryawanshi90603 жыл бұрын
you deserve more Subscribers man, Insane Grateful for you Videos. Keep growing brother. God Bless you.
@PhilippLackner3 жыл бұрын
Thanks a ton! All the best for you as well buddy
@ahsakpwks13453 жыл бұрын
You become a really active channel nowadays, and i f.cking love it
@PhilippLackner3 жыл бұрын
I became? I upload at least every 2-3 days for over 2 years 😂 but thanks bro
@ПавелЗубко-ц8ч3 жыл бұрын
Happy new year man !!! Thx for video!
@shaikhshafeen3 жыл бұрын
May your lifespan gets increased Keep uploading! Learning so much stuffs from your channel.
@PhilippLackner3 жыл бұрын
Thanks, will do!
@pubgplayer24272 жыл бұрын
I tried everything but nothing worked for me then I found your video and its working 100%. Thanks
@ArthurKhazbs Жыл бұрын
The baby changing station icon is so... kinky, I guess
@rileyfarro68013 жыл бұрын
After pokedex API with jetpack compose. Now the perfect splash screen. Thank you sensei 👌
@PhilippLackner3 жыл бұрын
Glad I could help!
@fatherGeorge90s2 жыл бұрын
It works nicely on API 32, but on lower API (tried 26) it showed an oversized default launch icon. Do you know what can be the problem?
@xxxx852 жыл бұрын
My splashscreen has an animation (0.6s long), but the splashscreen cancels before the animation can finish. I understand it's because the app underneath has finished loading. But is there no function built into the API to set the minimum amount of time to wait before going to the post-splashscreen theme? Do I really have to create a new task that runs in a thread to prevent the splashscreen from cutting short?
@Ok-Chance2 жыл бұрын
hi , i used a logo as png , how can i scale it
@JorgeSotoRamos3 жыл бұрын
This is the correct way to make a splash screen. Thank you for your good work.
@JorgeSotoRamos3 жыл бұрын
How could I put a text under the image?
@DeceptiveRealities Жыл бұрын
While I understand that Google wants to make all of Android appear consistent, this crosses the line from what is within their remit to what is in ours. Splash screens are part of the app, not part of the OS. If I want a splash screen that takes up the entire screen with a pretty picture and waits for ten minutes then that's my business, not Google's. If my users hate it, they won't download my app or will uninstall it. Simple. What next? Dictating that we can only use "official" Google colours and layouts in our apps? This, along with the "you need 20 testers for your app" shows just what dark path Google is taking developers down. It's fortunate you can hack and circumvent this ridiculous "splash screen" they've dictated and still put up your own - but for how long?
@huntingcarbon2 жыл бұрын
So how can I implement a splashscreen for an app that should be used both below and above android 12?
@SchildiZuHause Жыл бұрын
Thanks for the tutorial, I have added my own svg icon and it works beautifully. How can I adjust the size, because my logo is scaled too big
@DiabloZq3 жыл бұрын
Thank you and happy new year)!
@AlbertBuigues Жыл бұрын
I tried this today but in Android 34 is showing a black screen the rest of the time, the splash appears only 200 ms or less. How can i achieve this?
@ankitverma39322 жыл бұрын
How do I keep a drawable as splash screen background
@farahrayis59283 жыл бұрын
Quality content as always. Thank you!
@cyberavater81032 жыл бұрын
I love your videos bro, really appreciate your work. Can you make videos about app icon and app signing?
@alaminegueye3218 Жыл бұрын
Tried this on a project and I still can't figure out why don't we have the possibility to give another shape to the splash Icon. What if I wanna display a text ?
@baijusharma60273 жыл бұрын
Happy New Year Philipp. Have a great year ahead 🥳🥳. Thanks for sharing your knowledge. God Bless you. 🙏
@PhilippLackner3 жыл бұрын
Thanks, wish you the same!
@shlusiak2 жыл бұрын
Isn't the splash a feature of the launcher launching the activity? As such Android Studio is probably bypassing the launcher and that's why you don't get the splash when launched from there. But also the fact that returning from a child activity to the MainActivity may cause the splash screen to show kind of makes me feel that with this API we can actually do less with less lines of code. :-/
@ZaydMohammed-uc9nt2 жыл бұрын
Hey Philipp, this is really a great tutorial but I keep getting one error. When I put "@style/Theme.SplashScreenAndroid12", it keeps turning red. Is there a solution for this?
@LamijaSahat Жыл бұрын
Thank you for the great video, but i just have one question; how do you add a picture as a splash screen instead of an icon or how do I edit the size and shape of the icon?
@Elleozito Жыл бұрын
What can i do with that 'icon scale' when i'm using a image instead of an icon?i can put "group" on images...
@SG-rb4bz2 жыл бұрын
Thanks for this cool video. Had the same problem - splash screen didn't show if I ran the app from Android Studio :D One question - why did you set theme attribute (Theme.App.Starting) to activity tag in Manifest file as well? Documentation says that theme should be set either in application OR in activity tag.
@jude-l3f3 жыл бұрын
Thanks for the awesome content Phillip 👍🏾
@PhilippLackner3 жыл бұрын
My pleasure!
@breensrobert3 жыл бұрын
nice learnt a lot thanks Philip
@PhilippLackner3 жыл бұрын
Glad it helped!
@schrodingerscat39122 жыл бұрын
The icon looks sooo tiny on physical device (Samsung) How can the icon be increased in size?? It's very limiting, can't apply a larger image or anything.
@itsjee97003 жыл бұрын
API 21 just shows the background color and not the icon . What's the problem ?
@AlbertBuigues Жыл бұрын
which will be the correct way to set a specific time for the splash screen to remain on screen? i tried this: var splashMustRemain = true installSplashScreen().setKeepOnScreenCondition { splashMustRemain } Handler(mainLooper).postDelayed({ splashMustRemain = false }, 3000) it works well in all mobiles except android 34 mobiles that it appears a few milliseconds and the rest is a black screen
@annakarenina96003 жыл бұрын
What is the best practice for splash screen with animation? For user under android 12 version
@PhilippLackner3 жыл бұрын
as I said in the video, the new API supports that. Just pass an animated vector drawable for the theme attribtue
@mike_f3 жыл бұрын
That scaling tip was cool. I fought with that and gave up and ended up using a png with margin around the icon. But the bummer to me is it only seems to work with the stock launcher. My prior splash worked on all launchers. I prefer Nova. I just test with stock. I realize most users are probably just using stock anyway. But after working on the new splash it would be nice to know all users will see it. I've noticed no difference in load time between my old splash and this new one. Wish the branding image worked < 12 but so be it.
@mike_f2 жыл бұрын
@ᐯ❍íÐ not really sure why. I tested on a few custom launchers and none worked. What makes it even worse is how it doesn't even work on an emulator with Google's own launcher on first launch from android studio. You need to kill your app and cold launch it on the emulator.
@vahit·keskin2 жыл бұрын
Can we use image instead of icon? After all, the icon is very small and takes up a limited space.
@ArthurKhazbs Жыл бұрын
Yes, of course. As Philipp said, you can use any drawable.
@hxrin37482 жыл бұрын
Just tried this, great stuff!
@Spham992 жыл бұрын
When I ran the repo he provided, the splashscreen never showed...
@esmeraldafloresmontiel33272 жыл бұрын
Why when installing for the first time from Android Studio the screen is gray and then you have to close and reopen to show your logo?
@valentineeze47773 жыл бұрын
Hello, How do I solve this problem.."The emulator process for AVD Pixel_3_XL_API_29 was killed"?
@ftucilukmi91492 жыл бұрын
Can we create splashscreen using image? Also The image is not circle.. i was try it but the image automatically crop circle. my image is square, and i don't know how to put my square image to splashscreen.. maybe do u have a solution?
@summerwise2 жыл бұрын
I have a question, what kind of things should I do in splash screen? I have a screen with lazyColumn and list. I get this list from usecase in my screenViewModel. Should I start getting this list in splash screen and how to do this in mainActivity and pass list to other viewModel from MainViewModel? Or should I use the same viewModel from my screen in MainActivity for that?
@danielconde132 жыл бұрын
Hello, newbie here. In order to make use of this, does that mean that the minimum API for the app must be 31? How can you implement this? Thanks.
@letoatreides80982 жыл бұрын
I always use API 21, just had to add dependencies myself. I'm very unfamiliar and don't know if adding dependencies breaks the API compability. Like it now doesn't work for older phones?
@samirramic90712 жыл бұрын
So it seems when setting an appicon there is a bug where when you open the app every time for a short peroid the mipmap is displayed? Anyone know anything about that?
@freed54642 жыл бұрын
I cannot get "setContent" to work. I tried a bunch of stuff: [buildFeatures + compose true], [composeOptions + kotlinCompilerExtensionVersion '1.3.0'],. I researched this for like 60 minutes. I just can't get setContent to "be there" -- I get "Unresolved reference: setContent" in the IDE. This is even the case for a brand new Empty Activity App. Any thoughts? Thanks
@freed54642 жыл бұрын
Also [implementation 'androidx.activity:activity-compose:1.6.0-rc01']
@arjunbhat65022 жыл бұрын
Error : You need to use a Theme.AppCompat theme (or descendant) with this activity.
@wahyukoco45622 жыл бұрын
i found the solution! i just didn't change the application theme and just change mainActivity Theme.
@RonaldoGuedes2 жыл бұрын
How can I add a text bellow?
@AniobiStanley3 жыл бұрын
I tried it built and installed, but the "MainActivity" won't launch; it says I would have to use "AppCompat" theme (or its descendants), but in the video Philipp said we should replace the theme in the Manifest file with the "ThemeAppStarting" we just created "java lang IllegalStateException You need to use a ThemeAppCompat theme (or descendant) with this activity."
@ionutmoisoni33562 жыл бұрын
You need to add SplashScreen.installSplashScreen(this); in your launcher activity
@ionutmoisoni33562 жыл бұрын
@Ashish Dwivedi call it before super.onCreate(savedInstanceState); in onCreate. If you are using Kotlin it's "val splashScreen = installSplashScreen()" instead of "SplashScreen splashScreen = SplashScreen.installSplashScreen(this);"
@cyber_dbs Жыл бұрын
@@ionutmoisoni3356 thanks!
@DerCheckerzeigts3 жыл бұрын
For me it does not change for the postSplashScreen, what am I doing wrong?
@JohnMatthews-d4b9 ай бұрын
It is a known bug with Android studio that the emulator does not display when run from studio. I filed the bug for this
@jakesanderson86982 жыл бұрын
is there any way to use this but with a full background image and no logo?
@arunsivanandan4432 Жыл бұрын
#PhilippLackner Nice video. You made it clean and simple by explaining all the steps while implementing it. I have one question though. I understand using the splash screen api, we can eliminate the use of Splash Screen activity which we used to create and customize it a few years back or we can do some network calls or handle some usecase logic. But since we are using this in our landing page, how will you restrict the splash screen from calling again, if the same activity has to be called again due some use case. For example : In landing page (Doing login, plus splash screen got executed) -> Navigated to home page after login successful -> Logging out (Returning back to landing page) - Here when returning back to landing page, the splash screen will be invoked in OnCreate again right ? So how to stop this ? Do we have to use Shared Preferences with a boolean flag ? How do you tackle this situation when using SplashScreenApi ?
@shivanggautam5412 жыл бұрын
can we not add text along with vector drawable in splash screen ?
@YashNagayach2 жыл бұрын
Is this icon scalable to all size devices?
@mkc03212 жыл бұрын
your videos are amazing😀
@xephosbot2 жыл бұрын
May I know how to make a splash screen disappear animation like this? Or is it a built-in transition from Pixel Launcher?
@IdeasComo2 жыл бұрын
Esto funciona para Android 5 por encima?
@abuiman52512 жыл бұрын
Thank you for the useful content, Philipp! But how to change icon shape in Android 12 Splash screen? Is it possible?
@dreamer62287513 жыл бұрын
Best video bro!))
@RajuYadav-qm4ic Жыл бұрын
To fit any jpg png icon in a circle read android window splash screen doc
@mehmethasanakcay43263 жыл бұрын
Hi Philipp, can we add gradient color as a background ? I couldn't find any info about it anywhere.
@parvindersiyan97062 жыл бұрын
hey this looks cool for those application whose next to splash screen is fixed. so if i have two options after splash then how would I used new splash screen api?
@abovemediocrity245 Жыл бұрын
can we remove the circle and the icon?
@TanushreeShelare Жыл бұрын
how to remove the splash screen completely. i have my custom splash screen.
@tiltedbybox61183 жыл бұрын
The splash not showing when you run from Android studio first time doesn't happen on real device (at least on my android 11 phone). It's definitely some stupid bug.
@PhilippLackner3 жыл бұрын
What I'm using here is my real device
@tiltedbybox61183 жыл бұрын
@@PhilippLackner Then maybe it's A12 thing, which is kinda ironic, after all the version introduced the api in the first place. Anyway, at least you pointed out its a bug and how to fix it, so good job.
@rishabhone50833 жыл бұрын
This is definitely much better than the windowBackground method, *But Can we implement SharedElementTransition Animation with this new Splash Api?* The current way I'm using a Splash Screen is, I have a Splash Activity. The App loads with a Dark Background defined with windowBackground, after which the Splash Activity's Layout Inflates, which has a ImageView with the Splash Logo Drawable in the center, and if I'm navigating to the Login Screen, I perform a SharedElement Transition to the LoginActivity's Splash Logo Image. Right now I don't think SharedElementTransitions will be possible with this Api until they allow us to have Custom Layout Xml files to enable SharedElementTransitions. Until then, Happy New Year Phillip
@PhilippLackner3 жыл бұрын
Not possible right now, but that's a quite specific use case 😁 Happy new year too!
@bitwisedevs4692 жыл бұрын
I just use this and upon testing it on multiple device and version, I would say I am correct even at the beginning that this is a half-baked API. Inconsistent behavior and buggy. I hope it gets better or just remove and deprecate it already.
@hussein95773 жыл бұрын
great as always !
@aneessaleh28703 жыл бұрын
At least finish the video first
@hussein95773 жыл бұрын
@@aneessaleh2870 when it's Philipp , i'm sure it's gonna be great
@abdallawanjusi2 жыл бұрын
Hi Phillip, I implemented this splash screen and noticed that when I press the power button to close the phone screen during the splash and I press the power button again to turn on the screen, the splash screen turns black until I restart the app or resume the app by minimizing it and opening it again
@rachimvdr2 жыл бұрын
why do people press power button during opening an app (splash screen time)?
@letoatreides80982 жыл бұрын
Thanks. Not sure what I'm doing wrong. I had to dig around and add the dependencies manually to have the features avaliable, like MutableStateFlow. viewModelScope, viewModels. Is this because I'm using SDK: API 21? If Id use a newer one, the dependencies would already be there? Also, this splash screen, you can't do anything to the design, it will always just be confined to that circle? I'd think the simpler thing would be to just use an activity that shows up at start and design it however you like. And then you're automatically redirected to the main acitivity after 3 seconds. But I'm new to Android development so what do I know?! Thanks for the tutorial!
@michaelengeser35243 жыл бұрын
Hey Thank you for this great video :) One question. If I have a second Activity and go back to my MainActivity the SplashScreen is also be shown. What can I do that it only will be displayed at the beginning? Maybe you have an answer for me.
@shlusiak2 жыл бұрын
That's why Google shouldn't make APIs. The SplashScreen shouldn't be tied to the Activity but to the App because it is the loading state of the "App", not the screen, where I'd expect a loading state in the Activity if there is anything to load. But because your MainActivity may be recreated when you return from your child activity, the splash screen is shown again. You can try to make that better by not controlling how long the splash screen is shown in the activity's ViewModel, maybe that makes a difference? It'd be a lie to say this new API fixes anything.
@bboydarknesz3 жыл бұрын
omg, finally after many years !!! you dope for make this video love you mia khalifa!
@muhammadanas75023 жыл бұрын
awesome tutorial...keep it up.
@Merkost3 жыл бұрын
Hello, Phillip! How do you stream your real device screen to pc? I can't find how to enable this feature anywhere(
@harvey77713 жыл бұрын
I guess he used a tool called Vysor. I have been using it for years.
@KhushbuShah25 Жыл бұрын
Hi Phillip, Thanks for this cool video. I have one query related to the new Splash screen API. Currently, I have a separate Splash screen (an older way) in which I read shared preferences to check if a user is logged in or not. If the user is logged in then will launch Home screen of app, and launch the login screen otherwise. How can I do this without separate activity?
@rrd3 жыл бұрын
What software did you use to mirror your pixel 6 screen? Or is it an AVD?
@PhilippLackner3 жыл бұрын
It's called vysor :)
@josechocobar93343 жыл бұрын
"setContent" is compose?
@izztuka Жыл бұрын
I follow your projects and implement them in my own projects, I wish you could share the project screens in your github repo :/
@baadrqaaba95293 жыл бұрын
Thats what i needed , finally .
@PhilippLackner3 жыл бұрын
Awesome!
@alymohamed59662 жыл бұрын
I think this API is not going to work as it should if the app has more than one activity, if you want to show the splash screen while deciding that you want to stay on the same activity showing this splash screen or moving to another activity like Authentication Activity for example if this is the first use, the transition animation will look very bad.
@BM-tp4kn3 жыл бұрын
The splash screen only displays on a cold start of the app
@crateer3 жыл бұрын
Yes?!
@anwarzahid89202 жыл бұрын
is it working in all device?
@hasanzolfagharipour2 жыл бұрын
Hi philipp, very cool video, thanks a lot. can you tell api for Stretch overscroll effect in android 12 for below. just for google.
@norDevCommand3 жыл бұрын
Nice tutorial, do you know how can i add an animation instead of a icon?
@vahidgarousii3 жыл бұрын
Happy new photo 🤩😍
@jacobgonzalez47462 жыл бұрын
works for API 32?
@shubhamsharma0099 Жыл бұрын
how can i add this in #react native @latest version
@nastenkaoo Жыл бұрын
maybe
@mandroidx14743 жыл бұрын
I didn't used this before bcz i thought it won't allow us to do something during splash,now it is cool,thank u now i got it
@haykmkrtchyan70933 жыл бұрын
What about some animations in splash screen?
@s-w3 жыл бұрын
I couldn't figure that out myself. I just ended up creating a dialog Fragment that can be created and shown from that activity as a splash screen.
@haykmkrtchyan70933 жыл бұрын
@@s-w Me neither. There's only one imageview and textview we can control)
@PhilippLackner3 жыл бұрын
As I said in the video, create an animated vector drawable and pass it for that animated icon theme attribute. For more about animated vector drawables check the docs or so
@haykmkrtchyan70933 жыл бұрын
@@PhilippLackner it's ok thank you. I mean when we need some other complex animations, which is not possible with vector drawables. Something like lottie animation.
@s-w3 жыл бұрын
@Philipp Lackner I would have done that, but my app takes a bit to start when first opened, so I have a progress bar with my app icon, so it's not just the progress bar.
@CalamityDeadshot3 жыл бұрын
Why using delay though? I would expect Google to provide means for displaying the splash screen for as long as it takes to load and draw the starting activity, as it was with the old hacky way.
@bekdev5643 жыл бұрын
I think it is just to demonstrate that you can make network calls, which takes unknows amount of time, and the splash screen closes when the network operation is done. If you don't want to do anything while splash screen is showing, you can omit this part
@PhilippLackner3 жыл бұрын
Exactly. Just to simulate delay. Replace with a suspending network call or whatever
@mrclutch2713 жыл бұрын
Bro.. please guide us ...how to use animated vectors
@nickshv87272 жыл бұрын
3 feb 2022, this is doesn't work. I came from iOS and I can tell that android development fills really bad after iOS