Show touch/tap for App in Android - android

I'm developing app which have some Buttons. Now for UX perspective I want to show touch or taps on click of that.
These can be achieved by selectors for buttons that I know Other than is In all android mobiles within developer options showtouch/showtap options is available. These can be set programmatically but once If I set all applications will enable this option.
Can I restrict this option only to my app?
If yes can I customize this for better UI?
Thanks in Advance.
Any links/code related this will be helpful.

You can't do this using something external from your App.
There is nothing to do that.
The only solution could be to create a transparent View as an "Overlay" and show it for few milliseconds on the specific point where the Touch event has occurred.
Obliviously you have to show that Overlay View only when required by your UI and leave the display free-from-overlays when your App is not in foreground/use.
A special Permission is required for Overlay View starting from Marshmallow 6.x and should be prompted to the user that could accept or denied it.

Related

Android: Highlight menu item in draw over other apps settings

Starting from Android 11, using Settings.ACTION_MANAGE_OVERLAY_PERMISSION will ignore the package name, and instead will show a list of all apps that can have this permission. So you have to navigate and find your app to enable/disable the permission.
There is a way to highlight the specific app you want in the list instead of having to search for it through all the apps. Like this.
Following something similar to this: Highlighting a menu item in system settings
I want to make the same but for the "Draw over other apps" setting. (Settings.ACTION_MANAGE_OVERLAY_PERMISSION)
According to this answer, there are undocumented features of Android that can be used.
I want to know if something similar to what I am trying to achieve is possible and how?
Thanks in advance!

Disable Bluetooth Tile in Quick Settings Panel

I want to disable Bluetooth tile from the quick settings panel. I am using android 9 and I want to do it on a system app. So if there are some changes to be made in source, I would be happy to know it.
I have found many solutions telling how to add a new custom tile via TileService, but I need to disable tiles that are already present (like Bluetooth tile).
Note: I do not want the feature itself to be disabled, i.e. the user would be able to enable disable feature from the settings app itself. I just want to disable the qs tile.
Searched a bit on cs.android.com and this seems to be the relevant class.
frameworks/base/packages/SystemUI/src/com/android/systemui/qs/tiles/BluetoothTile.java
From there you can handle click ( or not handle it actually), or show a "disabled" icon etc.
If you want to "remove" it, then frameworks/base/packages/SystemUI/src/com/android/systemui/qs/tileimpl/QSFactoryImpl.java seems to be the class that adds them. It reads from Settings.Secure.QS_TILES
frameworks/base/packages/SystemUI/src/com/android/systemui/qs/tileimpl/QSFactoryImpl.java
yes, This file we can edit and remove unwanted tiles.

Tasker : create a bubbled floating windows?

What i wanted to do, and didn't find any suitable solution, is :
create a scene in tasker (no problem on doing it :) )
display this scene on overlayed mode on other app (ex: waze,). Overlay is mandatory (as i know but i am maybe wrong) to let's the underlayed application work and refresh screen normally
allow interaction with button on the scene, just like we can do it if i choose the dialog mode for my scene. The problem with dialog mode is that the underlayed apps screen does not refresh.
In fact what i wanted to to is to display some button when i am running waze, to allow me to sens ETA Sms to my wife, or skip to the next track on my musics apps, or close waze quickly.....
As a resume i want to do what is
create floating windows like offered by apps like Overlays
but only using tasker
Best regards
Best
Please share some images of your requirements so that we can help you better but anyways I found a solution maybe it'll help you with some little customization.
According to my understanding, you need something like this:
You can download the whole project and customize it according to your requirements from Here

How to make "Google Play Service"-like overlay prompt on android?

Sorry for my bad English.
I need to make an native SDK to show an overlay popup window to show a message on the top of the current activity.
The window will show about several seconds and then dismiss.
When the window is showing, the content behind needs to be active.
I try several methods, such as startActivity with not touchable and popupWindow.showAtLocation, but no one can act as the same behavior like Google Play Service-overlay window when you log in using Google account in applications.
I cannot get the current activity context or the current view since I don't have the GET_TASK permission.
Google Play popup overlay window Screenshot:
I need advise, thanks.
I think you need to create a showCase for your app.
This library will help you .
if you want more customization. you have to create a Service. And read this question if you want an overlay.

Enabling my application to show up in the Android Global Search

I have an application that I have made searchable, and I want to include it in the Google Search bar by default, or give my users the option of enabling it from within my application. I have already exposed it by adding android:includeInGlobalSearch into my searchable.xml, but how would I enable it from my settings within the application?
I know I can also launch the Settings.ACTION_SEARCH_SETTINGS activity and have them select it, but how would I shift the focus/scroll to my application if it is below the initial fold?
AFAIK, you can't. The user has to enable it, you can't force them to. You can' control the focus scroll either, best you could do is experiment with different names and see how this affects sorting.

Categories

Resources