[Q] Single-app Android ROM? - Android Software/Hacking General [Developers Only]

Sorry if it has been asked before, but is it possible to automatically start an app at the startup? Effectively, I am looking to create a single app custom build for a project, so need to be able to start the app on power up.
Also, would like to remove as many as possible of standard modules to decrease the start up time (my app doesn't need much).
Any pointers would be appreciated.

If you want to hide normal, Android screen, then create your app as launcher and remove default one.

Brut.all said:
If you want to hide normal, Android screen, then create your app as launcher and remove default one.
Click to expand...
Click to collapse
Thanks, so any app can be setup as a launcher? Does it require implementing some interfaces or tweaking some config files? Any source code examples? Is there any difference in implementing it for different Android versions?
Any advice is really appreciated!

I do not know what rights it would need exactly, but setting your application to run as a Launcher (Home) you would probably need to declare that in the manifest. Once it is running on the phone, you clear Launcher or Home defaults and then you hit the home button when on the home screen. From there (if declared correctly) you can set it as the default home.
Again, i have never done it and this is from Android coding and usage experience only helping me have an educated (?) guess.
Unconnected.

Thanks for the advice.
I managed to setup my app as the "Home" app, however, when I reboot the phone, first thing I see is the "Screen locked" screen... Anyway, to get rid of it?

If you want to start something at boot, you have to create a broadcast receiver and capture the "android.intent.action.BOOT_COMPLETED" intent. You can then run whatever you need to when the intent is fired.

maniacx21 said:
If you want to start something at boot, you have to create a broadcast receiver and capture the "android.intent.action.BOOT_COMPLETED" intent. You can then run whatever you need to when the intent is fired.
Click to expand...
Click to collapse
Thanks, tried that - the same problem, the Screen Locked screen comes up first on startup. If I unlock then yes, my app has started and in foreground.
So no way to get my app loaded _before_ the Locked screen?

Err, you could make your app a screen unlock app...
(look at the source of the unlock app at AOSP)

The_Double said:
Err, you could make your app a screen unlock app...
(look at the source of the unlock app at AOSP)
Click to expand...
Click to collapse
Thanks, I'm already calling .disableKeyguard() in onReceive() for the BOOT_COMPLETED.
However, the problem is that the device displays the Locked screen BEFORE my app gets BOOT_COMPLETED - so the app can unlock and start fine, but my goal was to go directly from the boot logo into my application without seeing any Android stuff...
Anyway to get this effect without having to have a own custom ROM?

No SDK method, as far as I know, of doing what you want. Might have to look into custom ROMs.

OK, so seems like a Custom ROM is a must.
Now, it looks like Huawei's devices (u8110/Pulse Mini and u8120/v845) could be a good base for that with the source available and custom ROMs already in existence.
So the idea is to package the single App that will be starting on BOOT_COMPLETED taking over the screen and buttons.
So the ROM needs to be modified to:
1) remove all unnecessary apps and libraries
2) customise bootlogo and bootanimation
3) on startup the ROM should go straight from bootanimation into the App (so, no display of the home screen at all)
4) on press&hold Power down - go straight into shutdown without extra confirmation dialogs
Can someone point out if 3) is possible/easy and any references to the Android source code for the bootup & power down would be great?

Related

[Q] Homescreen app resuming

In Windows Phone 8 it is possible to resume apps right from the homescreen instead of relaunching them as in Windows Phone 7.5/7.8. So I was wondering if there are any hacks avaible which bring this feature to WP7? I love this feature but I can't seem to find it.
renegadEEE said:
In Windows Phone 8 it is possible to resume apps right from the homescreen instead of relaunching them as in Windows Phone 7.5/7.8. So I was wondering if there are any hacks avaible which bring this feature to WP7? I love this feature but I can't seem to find it.
Click to expand...
Click to collapse
you can code wp7 apps to act similar. so as example my app if you are out of the app and it is in the tasks so when you hold the back button and you see it. then when you resume to my app it doesnt load again the whole app. i have coded it so that it "save the state" of the app and after resuming to it it doesnt load it from begin. some developers are lazy and dont implement this. But this is an normal behaviour since mango so i use it.
the problem is however if you instead of going back to the already "open" app you just tap it again on the start screen it loads the whole app from begin. so thats a little point back but users should use the back button and the multitasking to come back and not the tiles. i think the tiles in wp7 are ment to be like to start the apps first time, after that you have the back button and the multitasking cards.
Dinchy87 said:
you can code wp7 apps to act similar. so as example my app if you are out of the app and it is in the tasks so when you hold the back button and you see it. then when you resume to my app it doesnt load again the whole app. i have coded it so that it "save the state" of the app and after resuming to it it doesnt load it from begin. some developers are lazy and dont implement this. But this is an normal behaviour since mango so i use it.
the problem is however if you instead of going back to the already "open" app you just tap it again on the start screen it loads the whole app from begin. so thats a little point back but users should use the back button and the multitasking to come back and not the tiles. i think the tiles in wp7 are ment to be like to start the apps first time, after that you have the back button and the multitasking cards.
Click to expand...
Click to collapse
I understand the philosophy behind it but I do regret it since the multitasking menu is a total clutter of frozen screens of all the running applications and my homescreen is way more organised so much easier to find the app that I want. Hopefully someone will come up with a fix for this.

[Q] Why does my launcher only work the way I want it when I reset app preferences?

What I want my launcher (Home Screen App) to do is the same Surelock does, what I mean by this is I want to activate the launcher imediately once I get in the app I want to be prompted for a launcher.
I can already do it, however after I set the android launcher allways, when I get in the app again I can't make it into a launcher.
I can only make it into a launcher again if I reset app preferences on the tablet's settings...
You want to be able to choose between two or more launchers every time you "go home"?
What you have now is a situation where a launcher stays in memory and is the default after having chosen it once?
I think you will have to manually edit memory handling for that either on the app side or by modifying the android memory settings.
Android generally tries to keep the launcher in memory or cached by default I think.
Perhaps, but this is pure speculation, toy can use the developer settings for this.
There is an option in that menu for killing apps immediately after closing them, and one for max allowed background apps.
You could see if one of those (both at once is not needed) do the trick, be warned though, that'll essentially end multitasking.
Sent from my GT-I9000 using xda premium
Thanks, what I want is...
Hr Kristian said:
You want to be able to choose between two or more launchers every time you "go home"?
Perhaps, but this is pure speculation, toy can use the developer settings for this.
There is an option in that menu for killing apps immediately after closing them, and one for max allowed background apps.
You could see if one of those (both at once is not needed) do the trick, be warned though, that'll essentially end multitasking.
Sent from my GT-I9000 using xda premium
Click to expand...
Click to collapse
Hey, thank you for your reply, what I want to be able to do is what Surelock does, which is everytime I click on my custom launcher application I get prompted to choose a default launcher, and as soon as I do it the changes take effect immediately. Meaning I enter HOME mode instantly, so when I press the home key the home is already my custom HOME app. and The back key won't work either.
This is exactly what I need to do...
What happens now is that on the first time I run the application I get the same result as in the surelock application which is what I want. And if I restart the tablet I restar on my own launcher which is also perfect, however...
if I exit my own launcher (which I've made possible by pressing a button) when I choose to use android launcher as allways, I imediately move to the android launcher which is also what I want.
The problem is when I go to the application to repeat the same process, it will still ask me which launcher I want to choose but when I choose mine, the changes don't take effect.
The changes will only take effect if I reset app preferences in the tablet's settings...
And I want to be able to repeat the process as many times as I want without having to reset the app preferences...
Right, now I get it.
You will have to write two (near identical) scripts that 1: clears the launcher default or directly changes it to the other (better) 2: starts the other launcher.
I don't know how to do that, but Claystone Launcher apparently has the function so it's perfectly doable.
Sent from my GT-I9000 using xda premium

App as Lock Screen -OR- Allow app to run when device is locked

Hi gang,
I've got an old android device running CM11 that I'm using mainly as an alarm clock.
I'd like to be able to run only the clock app (Gentle Alarm) .... and then if I want to use any other apps like email or whatever, I'd have to unlock the device.
A lock screen widget doesn't quite cut it, as I'd like the full functionality of the alarm clock app (or actually, *any* app I select, for that matter) available, but as soon as I click the home or back button, I'd be taken to my lock screen.
I could see this feature being useful for lots of reasons... say if I had a tablet as a remote control for the TV/stereo that guests could use, yet i didn't want them running other games or apps.
Is this possible?
Am I off my rocker?
So much easier than I thought..... Using CM12+ (Lollipop) I can "pin" an app which will enable it to be the only app which can run - switching to another app or going home presents the user with the lock screen. Perfect.
I feel like a bit of an idiot not realizing this was a built-in feature of the OS. But hopefully this info will help someone else along the way.........

Questions About Using Lineage OS 18.1 on Pixel 3

Greetings,
So I've successfully installed Lineage OS 18.1 Nightly and it runs really well. I've got the NikGapps Core and Magisk installed. Was able to add the apps I like from Google Play store and used the free or open source alternatives I could find for others.
I have a few questions for anyone using Lineage since I'm not sure if these are bugs or design choices or parts of Android 11.
Any clarification would be great. Basically, there's a few things I noticed that are different/don't seem to operate normally.
I can upload screenshots if necessary but let me give you the cliff notes of what I'm experiencing:
-No labels on the home screen icons, even though setting says "Show labels on desktop". Is this me interpreting something incorrectly?
-All icons on the home screen and app drawer appear to have a white background... should be transparent?
-The default sms messaging app always shows quick replay phrases despite turning off the setting "Always suggest quick actions/replies" in the notifications menu
-There is no way to turn off suggested apps... when you use an app it places it in a new section at the top of the app drawer. Looks like the menu setting is missing (there in vanilla A11).
-There is no built in volume limited. This was on my stock Galaxy S7 so if it is an OEM thing I understand. Perhaps you have a suggestion?
-Notifications from the default sms messaging app do not pop up over other on screen elements (specifically fullscreen video in Brave). Does this have to do with the "Bubbles" setting under notifications?
-Screen automatically dims/sleeps when watching fullscreen video (again in Brave)... happens inconsistently and going in/out of fullscreen seems to stop it from happening again.
-There is no swype ability on the keyboard. I assume this is a OEM keyboard setting or something.. is there an alternate keyboard you would recommend (open source, free) that won't steal your info/privacy violations?
-Last thing which is more of a question than anything else, since I cannot install a stable twrp, I used the Lineage OS recovery. It doesn't seem to have a backup/restore function. So is there a way for me to, with the setup I currently have, to do a complete and full backup? By this I mean like capture an image of all the partitions as they currently are, as you would with a PC.
Sorry for n00b but the last unlocked rooted custom rom I ran was Cyanogen back on a Motorola Photon. Thank you in advance, any input or clarification is much appreciated as you are a helpful, insightful bunch here.

Looking for an Android App -- a launcher, but... not.

I'm looking for an app that behaves like a launcher, but isn't an actual launcher/home app: multi screen, can use widgets, has an app drawer, etc, but doesn't specify itself as a launcher program.
Basically, I want to use is as one of the sides in a split screen configuration, but any app that defines itself as a home screen app android will treat differently and give most of the screen real estate to when it's running.
Google fails me because any search terms I can come up with to search for such an app just gives me useless listicles of 'the best android launchers!'
Any suggestions?
Are you seeking such action?
Split Screen Launcher - Apps on Google Play
Launch two apps on the screen
play.google.com
ze7zez said:
Are you seeking such action?
Split Screen Launcher - Apps on Google Play
Launch two apps on the screen
play.google.com
Click to expand...
Click to collapse
No, that's an app that just launches apps in split screen. I want basically a launcher that runs as an app and not a home screen.
Well, you still want your "splitable" Launcher to handle the home button/intent, so I think the only answer is to patch Android so that the Home app can be split screened.
There's some logic in there for older apps ("this app is too old and can't operate split screen"), probably some for Home activity.
Renate said:
Well, you still want your "splitable" Launcher to handle the home button/intent, so I think the only answer is to patch Android so that the Home app can be split screened.
There's some logic in there for older apps ("this app is too old and can't operate split screen"), probably some for Home activity.
Click to expand...
Click to collapse
Not really -- I'm ok with using a completely different app for my actual home screen. I effectively just want an app to behave exactly like a launcher, only not to tell Android it is a launcher.
I realise this may not exist. If it doesn't I'll probably just find an open source one and modify it accordingly; I was just hoping it was already a thing.
dnfm said:
(...) launcher that runs as an app (...)
Click to expand...
Click to collapse
https://www.reddit.com/r/androidapps/comments/v9phh4/_/ibz42jl
Take your favorite launcher. Use ApkTool. Edit AndroidManifest.xml and remove:
<category android:name="android.intent.category.HOME"/>
Build it back with ApkTool then sign it.
Of course this can not coexist with your "Homey" version unless you change the package.
Renate said:
Take your favorite launcher. Use ApkTool. Edit AndroidManifest.xml and remove:
<category android:name="android.intent.category.HOME"/>
Build it back with ApkTool then sign it.
Of course this can not coexist with your "Homey" version unless you change the package.
Click to expand...
Click to collapse
Ya I figured it might be that easy, but my Android dev experience has been limited to writing a widget. Thanks for the heads up. I think I'll end up doing this.

Categories

Resources