How to add widget on pin locked screens - Java for Android App Development

Im making an emergency app for androids, the app is going to be accessible from any pin locked phone, so only this app is accessible without entering the pin, and not the rest of the phone.
Whats the best way to place it in the best visible way on the lockscreen for easy access?
I have an animated widget i would like to use for this, is that possible, or, what are the limitations/possibilities here?
For a similar app/function reference, see this:
https://play.google.com/store/apps/details?id=com.matrix.emergency&hl=no
Thanks

I would even go as far as to say you should make your own lockscreen replacement. Then you can decide on your own whether users can access your app without pin or not
---------------------------------
Phone : Nexus 4
OS:
Pure KitKat 4.4.2 stock, no root, no mods (but only for the first time ;D)
---------------------------------
Gesendet von Tapatalk

Masrepus said:
I would even go as far as to say you should make your own lockscreen replacement. Then you can decide on your own whether users can access your app without pin or not
---------------------------------
Phone : Nexus 4
OS:
Pure KitKat 4.4.2 stock, no root, no mods (but only for the first time ;D)
---------------------------------
Gesendet von Tapatalk
Click to expand...
Click to collapse
Yea, know of any good examples on that?

Hm you can take any locker as an example, go locker, slide locker, etc. You dont even have to make an appwidget as you can just place the views fixed inside your lock screen layout
---------------------------------
Phone : Nexus 4
OS:
Pure KitKat 4.4.2 stock, no root, no mods (but only for the first time ;D)
---------------------------------
Gesendet von Tapatalk

Masrepus said:
Hm you can take any locker as an example, go locker, slide locker, etc. You dont even have to make an appwidget as you can just place the views fixed inside your lock screen layout
---------------------------------
Phone : Nexus 4
OS:
Pure KitKat 4.4.2 stock, no root, no mods (but only for the first time ;D)
---------------------------------
Gesendet von Tapatalk
Click to expand...
Click to collapse
But how about if i want to use the widget i have, are there any possibilities to place that on the main lockscreen?
I know it works if i add a new lockscreen, but then i cant add more widgets there like, clock, weather and stuff, only one for each new screen?
What do you mean by that? "you can just place the views fixed inside your lock screen layout "

appfactory said:
But how about if i want to use the widget i have, are there any possibilities to place that on the main lockscreen?
I know it works if i add a new lockscreen, but then i cant add more widgets there like, clock, weather and stuff, only one for each new screen?
What do you mean by that? "you can just place the views fixed inside your lock screen layout "
Click to expand...
Click to collapse
by "you can just place the views fixed inside your lock screen layout "
he means that instead of an appwidget you can directly place you Views ie layouts there in your CustomLockscreen
Hint : Try broadcast receivers listening to intent SCREEN_OFF and SCREEN_ON
Sent from my GT-S5302 using Tapatalk 2

Or you let the user decide about the widget: http://forum.xda-developers.com/showthread.php?t=2572592

appfactory said:
But how about if i want to use the widget i have, are there any possibilities to place that on the main lockscreen?
I know it works if i add a new lockscreen, but then i cant add more widgets there like, clock, weather and stuff, only one for each new screen?
What do you mean by that? "you can just place the views fixed inside your lock screen layout "
Click to expand...
Click to collapse
Your widget is eg made of one TextView inside some kind of layout, may it be a linear layout or sth. So then instead of putting those elements into the MyOwnLockscreenWidgetLayout.xml, you arrange them in your main MyLockscreenReplacementLayout.xml
See what i mean?
Now about using other widgets of other apps in your lockscreen replacement: you can do this
Take widget locker by teslacoil as an example. I think implementing that is a bit more complicated, but there is a guide inside the android dev docs. Your app has to act as a so called AppWidgetHost and answer to some specific broadcasts. That as much as i know about the topic. Just have a look at the docs
Ah edit: ive just seen that @nikwen posted the link to a guide about that. Have a look at it!
---------------------------------
Phone : Nexus 4
OS:
Pure KitKat 4.4.2 stock, no root, no mods (but only for the first time ;D)
---------------------------------
Gesendet von Tapatalk

Related

REQUEST - Customizable Stock Lockscreen

Hello fellow G2-Users,
One thing that bothers me with this great phone is the lack to customize the stock lockscreen. For example display calendar and weather, changing the clock etc. I know there is WidgetLocker and other apps but i want to keep the great unlocking animation from the stock lockscreen and of course knockoff from lockscreen.
Who else wants this?
Who can make this possible?
THX
screenager said:
Hello fellow G2-Users,
One thing that bothers me with this great phone is the lack to customize the stock lockscreen. For example display calendar and weather, changing the clock etc. I know there is WidgetLocker and other apps but i want to keep the great unlocking animation from the stock lockscreen and of course knockoff from lockscreen.
Who else wants this?
Who can make this possible?
THX
Click to expand...
Click to collapse
I'm using a PIN code for security, so that changes things a bit. On that version of the lock screen, you can swipe from the left and add widgets. Stock lockscreen.
SeanRinVA
Sent from my LG G2 using Tapatalk
SeanRinVA said:
I'm using a PIN code for security, so that changes things a bit. On that version of the lock screen, you can swipe from the left and add widgets. Stock lockscreen.
SeanRinVA
Sent from my LG G2 using Tapatalk
Click to expand...
Click to collapse
Thx for your suggestion!! iam aware of that and it is also avaible without PIN security. But i want to see my next appointment and weather on the main lockscreen and change the (ugly) stock clock.
Try "Android Weather" app. It has the features you mention, you can make the widget transparent if you want, and it can be added to the lockscreen.
screenager said:
Thx for your suggestion!! iam aware of that and it is also avaible without PIN security. But i want to see my next appointment and weather on the main lockscreen and change the (ugly) stock clock.
Click to expand...
Click to collapse
matthewtyson said:
Try "Android Weather" app. It has the features you mention, you can make the widget transparent if you want, and it can be added to the lockscreen.
Click to expand...
Click to collapse
oh THX just realize you can remove the stock clock. wow. sometimes you dont the forest because of the trees.
mod pls close thread.

caan these things be removed for the lock/ home screens

1. is it possible to remove the app icons from the lock screen so no icons show,
2. is it possible to not have any icons or widget on a home screen other than the icon to access all the apps
3. what about removing scroll line above the apps at the very bottom of the homescreen
can these be done without a launcher?
1, yes I did it because I wasn't issuing them
2, maybe
3, also maybe
Sent from my LG-D801 using Tapatalk
how do i do this?
1. LockScreen Settings-> Shorcuts and there you can select for each position to have no application.
2. You can remove everything by drag and drop
3. I have seen here on xda a method, but I don't remember where. Could be some xposed modules, not sure
Sent from my LG-D802 using Tapatalk
bugxyz said:
1. LockScreen Settings-> Shorcuts and there you can select for each position to have no application.
2. You can remove everything by drag and drop
3. I have seen here on xda a method, but I don't remember where. Could be some xposed modules, not sure
Sent from my LG-D802 using Tapatalk
Click to expand...
Click to collapse
is it possible not to any have any widgets on the lock screen and or remove the tap her to add a widget?
From stock rom, I don't think is possible, but we have very good developers here, maybe someone created a mod for lockscreen
Sent from my LG-D802 using Tapatalk
3. - this can be done by modyfing systemui or framework; I can't do it, but if You want to learn, there are even some guides on Youtube.
@joeynox
You can hide the divider line with G2 TweaksBox (xposed module) and the dev has the option to hide "tap here to add a widget" in his to-do list.
3. - this can be done by modyfing systemui or framework; I can't do it, but if You want to learn, there are even some guides on Youtube.
Click to expand...
Click to collapse
You would need to mod LGLockscreen.apk in JB roms or LGKeyguard.apk in KK.

2 special questions

Good evening guys, after digging through androids and trebuchets code for More than a day, I need your help:
1.) I need to know the method which is responsible for the creation of the choose action/complete action with dialog. Or to be exact: the method which checks whether there is a default action set and doesnt create a dialog.
2.) How do launchers likr Trebuchet, Nova and so on get their icons? I know about the ActivityInfo.loadIcon(pm) method, and i know no other way(except losding the logo which isnt the case) to get a logo. The thing is that i need to modify this method(the method providing the icon). It has to be the loadIcon() thing OR there is some method interrupting the call in the launcher. I studied the trebuchet source because its open source and i thought that the icons may be loaded differently due to the ability to load icon packs, but this isnt the case either.
Gesendet von meinem SM-N9005 mit Tapatalk

Lock screen replacement

I'm looking for a lock screen (app or mod) and i'm looking for 2 features: i have to be able to unlock the screen by swiping wherever i want (like on stock g2), and it has to show notifications and let me open them. Any suggestion?
Go to playstore and search for "widget locker". It's a paid app and requires root access...
Gesendet von meinem LG-D802

Lockscreen widgets ? Alternative lockscreen ?

Hey guys !
I keep customizing my S7 edge, but there is 1 thing I couldn't customize yet : The lockscreen
With my former phone (LG G3), I tried many alternatives lockscreen, but they all had problems (battery drain, not fast enough, some lags, not fluent, etc...).
I'd like to make my lockscreen more alive, with useful informations on it. And I use fingerprint unlock.
So here is my question : Do you know a way to make it work ? A good xposed module working with touchwiz ? Or a good lockscreen app ?
Thanks, have a great day
BigBen60 said:
Hey guys !
I keep customizing my S7 edge, but there is 1 thing I couldn't customize yet : The lockscreen
With my former phone (LG G3), I tried many alternatives lockscreen, but they all had problems (battery drain, not fast enough, some lags, not fluent, etc...).
I'd like to make my lockscreen more alive, with useful informations on it. And I use fingerprint unlock.
So here is my question : Do you know a way to make it work ? A good xposed module working with touchwiz ? Or a good lockscreen app ?
Thanks, have a great day
Click to expand...
Click to collapse
Have you had a go with good lock from the Samsung store. It's pretty good at being customized.
Sent from my SM-G935F using Tapatalk
dannybee1 said:
Have you had a go with good lock from the Samsung store. It's pretty good at being customized.
Sent from my SM-G935F using Tapatalk
Click to expand...
Click to collapse
Yeah I already tried it, but don't really like it. And there is no widget on lockscreen
BigBen60 said:
Yeah I already tried it, but don't really like it. And there is no widget on lockscreen
Click to expand...
Click to collapse
Yes there is ! In routine's setup when you choose the clock style swipe to the top and ull find a way to add a widget
Yeah, go to routines, and clock and swipe to top, you can add one widget. I personally like the worded clock. You can also add widgets for when you swipe down for notifications.
Sent from my SM-G935F using Tapatalk
Ok thanks

Categories

Resources