Installing a widget from an APP - android

I know i'm going to die as maybe i didn't place this post correctly, also i'm not a developer, only a graphic designer.
I'm looking for some advise, hope someone could help me with that.
Imagine that you launch your app, and within that there is a button that says "Install widget". You press that button, then the app closes and a widget appears on the home screen.
Is that possible?
i've been reading that before 4.2 i wasn't, but something changed from then. Problem is that i have no more information about this, and also i don't know if it changed over time.
I'm behind the graphic design of a widget. The idea is that you first download the app, which will help you to configure the widget, and then you have to manually place the widget in place.
They are afraid that some people wont understand, and they will cease trying.
I only would like to know if this is possible, (or something similar) and if someone knows any APP that does this thingie.
Note: APPS like "Swiftkey" guides you in the process of installing your keyboard. it asks you to go to a determinate place of the phone settings, and gives you a shortcut to that place so you don't have to go by yourself.
It would be amazing. To directly place a widget o to guide them trhough shortcuts.
Many many thanks in advance!

Is that possible?
No. The user installs the app widget through the home screen.
The idea is that you first download the app, which will help you to configure the widget, and then you have to manually place the widget in place.
That is also not possible. The flow is that the user chooses the app widget in the home screen, places the widget in place, then if you have a configuration activity defined, you will get a chance to help the user configure the app widget (e.g., to choose the city for the weather report that the app widget should display).
APPS like "Swiftkey" guides you in the process of installing your keyboard. it asks you to go to a determinate place of the phone settings, and gives you a shortcut to that place so you don't have to go by yourself.
Input method editors (a.k.a., soft keyboards) are configured through the Settings app, and therefore there is a consistent place to direct users towards. App widgets are configured through the home screen, and different home screens can implement that process in different ways, so there is no standard spot to direct the users towards.

Related

Android home screen widget - how to add option to launch apps from the widget

I have a nicely working widget.
I have an idea to add an option for the users to launch any (previously installed) app from the widget by pressing the dedicated button. So I want users to be able to choose 1-2 apps from their installed apps in the widget configuration part and be able to launch them from the widget.
Is there any way to add this functionality without declaring this widget a launcher?
If yes, could I get any hints, maybe some tuts, please?
I really appreciate any help you can provide.
Adam

Suggest user to place apps appwidget on the homescreen

i have an app on googleplay (MyWords-MyDictionary). After collecting some stats from google analystics i saw that very few is using apps appwidget. I am assuming that people are not aware of the appwidgets existence.. Problem is my apps unique strengt is its appwidget. So somehow i need to suggest user to put the app widget on the homescreen...
What is the right way to do it... How can i make user aware of my widget? It is possible to open the widgetpicker and point out my widget and on click maybe it will be added to the homescreen?
On splash screen make a textview stating "You have my gratitude for downloading the app but please do try the widget as well."
P.S. you don't have to use fancy language you can also type t hanks but this site won't let me type it like that

Can an Android app interact with another app?

I want to be able to tap the statusbar and the contents in the displayed app to be scrolled up to the top.
Is it technically possible that an app intercept my tap and send the appropriate command to the active app? I have noticed for example that AntTek quick settings shows a drop-down window when swiping down from statusbar. While using the app I did also notice that even by just tapping the statusbar (before beginning to move the finger down), the app seems to already interact with the touch as it dims the screen brightness in preparation to display it's "window" (sorry I use the MS Windows term), so clearly a statusbar tap CAN be sensed by an app.
Starting from this, I wonder if such an app could then send a message to the active program telling it to scroll up.
Is that possible? And if yes, the message must be customized to a particular app (let's say the browser as the most important) or is it standardized so the apps speak the same language between themselves?
I am not a programmer so answers with codesamples might be less helpful than a plain english explanation. Finding out that is possible would lead rather to pursuing a programmer to implement the idea rather than starting to develop it myself.
Thanks :-)
There is an XPosed-module which seems to do exactly what you want.
To use XPosed-modules, you'll need to root your phone and install the XPosed-framework.
The XPosed-module is called "Statusbar Scroll to Top" and its repository can be found here:
http://repo.xposed.info/module/com.mohammadag.statusbarscrolltotop
This will work for almost all app-lists, but for example won't work for browser-content.
If you want to scroll to the top of the page in a browser, then you'll probably do best to get a browser which can do that on its own. (For example Habit Browser has it built-in and respective plugins are available for Firefox.)
Yes it is possible. HiroMacro and Frep can do this, but it requires root. https://play.google.com/store/apps/details?id=com.prohiro.macro&hl=en
(how do they simulate mouse and keyboard interactions on other applications? i have no clue :/ anyone?)
Is it technically possible that an app intercept my tap and send the appropriate command to the active app?
No. One app cannot send fake input to another app, for security reasons.
An android app comprises of several activities. Each activity display a GUI that allows the user to perform a specific task. To take the user from one activity to another, app must use an Intent to define our app’s intent to do something.
An intent can be explicit in order to start a specific component (a specific Activity instance) or implicit in order to start any component that can handle the intended action.
Interacting one app to other app in android
google docs link

how to create shortcut in folder in android menu. (not on home screen)

I am totally newbie and I am not an English native speaker, so please don't yell at me if I do something wrong.
I made an android app in eclipse (nothing special), but I have one problem. I want to add a shortcut in folder so the user can call it from folder. in that folder i will later add more shortcuts. i want to separate my apps from others. this folder and the shortcuts need to be in main manu.
I tried some codes what I found here in stackoverflow, but I stacked and I don't know how to proceed.
Thanks in forward for anwsers
Though I am not an Android developer, I don't think you have to update anything. Users should just be able to drag your application icon to the home screen. If you want action-specific shortcuts (I.E., go to Wi-Fi settings in the settings app), then please update your question.
you open start menu and you have your own folder with your shortcuts
In Android, the "start menu" equivalent is called the home screen. There are many, many implementations of a home screen -- dozens that come pre-installed on different devices, and hundreds more than can be downloaded from the Play Store and elsewhere.
Some home screens may have the concept of a "folder", but they may or may not expose an API to developers to control it. Other home screens will not have "folders" at all.
You are welcome to contact each home screen author to find out whether they support the notion of "folders" and whether there is a specific way for your app to create a "folder" and appear inside of it.
Or, you are welcome to build your own home screen, complete with as many folders as you like.

Only displaying pre-installed applications on android device

So I am using the Home sample to build an application that creates a second home screen for the user. The idea is to be able to have only one user account yet restrict certain access to chosen applications. I have managed to ensure that all of the applications are invisible in the XML yet I am struggling with how to change this to make certain apps visible.
Is it possible to write a whitelist of accepted apps for instance the preinstalled apps or child friendly apps for children who game using the android device and then put in a Java method to access this white list? This is the only way I can think to make it work.
If anyone knows the correct way can you please help.
Thanks.
Ok so I discovered how to do this.
In the home sample they provide a for loop in the Home.java file that covers all apps and displays them. It take a simple if statement to restrict the apps that can be viewed -
// for loop is here
if (info.activityInfo.applicationInfo.packageName.contains("com.android"))
//then the rest of the home sample is here.
Still very basic but provides me with a good enough UI so that kids cannot see apps I don't want them to.

Categories

Resources