Catch Home and Back button press in Tasker created Scene

2,618 views
Skip to first unread message

Wietse van Buitenen

unread,
Aug 1, 2012, 1:33:59 PM8/1/12
to tas...@googlegroups.com
I noticed that when first showing a Scene as Dialog (40x40 pixels) and then another Scene as Overlay Blocking Full Screen, I can put blocking Scenes over an active Pattern Lock.
This opens a lot of options :)

Downside is that when pressing the Home or Back key, the Dialog Scene is closed and the pattern is pushed in front of the Overlay Blocking Scene..
I know the Home and Back keys can only be caught by the active app (which is Tasker in this case) so was wondering if there was a way to catch this?
This would allow me to show the Scene again as Dialog and keep the other Scene on top..

Pent

unread,
Jan 19, 2013, 3:27:35 AM1/19/13
to Tasker
Back will be configurable in the big scene update coming after the UI
refresh.

Home is not 'catchable' by any app.

Pent

Wietse van Buitenen

unread,
Jan 19, 2013, 6:26:08 AM1/19/13
to tas...@googlegroups.com
"the big scene update" sounds very interesting :)
catching back will help me a lot already.

I was just trying to see if home was pressed by using Event %WIN Set and check for %WIN beïng Home (Nova Launcher sets this)
and then check if the Scene was created, which means Home had to be pressed with Scene active so I show the Scene again
This worked fine for a short while but now Tasker doesn't seem to see %WIN changing like it did before
had mixed results with %WIN before and don't quite get what makes it work and what not..

mark jayvee Pabilonia

unread,
Jan 20, 2013, 4:19:20 AM1/20/13
to tas...@googlegroups.com
this is what i am talking about. yeah.. everyone will be waitin.. yey..

woorschtsupp .

unread,
Feb 11, 2014, 8:15:12 AM2/11/14
to tas...@googlegroups.com

On Saturday, January 19, 2013 12:26:08 PM UTC+1, Wietse van Buitenen wrote:
I was just trying to see if home was pressed by using Event %WIN Set and check for %WIN beïng Home (Nova Launcher sets this)
and then check if the Scene was created, which means Home had to be pressed with Scene active so I show the Scene again
This worked fine for a short while but now Tasker doesn't seem to see %WIN changing like it did before
had mixed results with %WIN before and don't quite get what makes it work and what not..
 
I would also appreciate a way to know that the scene is not being shown any more due to someone pushing the Home button.
 
I got a screen filling scene (Activity, Full Display, No Bar) that shows a clock which is reload every minute (two tasks, triggererd by a variable and a time context, one time context from midnight to midnight, the other running from 0:01 to midnight ;-) ). Everything works fine but if someone pushes the home button the 2 tasks keep refreshing the scene while it is not being shown.
 
What I do as workaround now is: reloading the clock every minute so that it is definitely shown again after at most a minute. I do not really like that because the user might push home, put the phone in the pocket and find the battery being empty after a while.
 
If I could detect that the scene is not on the screen any more I could just destroy it ...
 
1. Unfortunately there is no "Overlay, Blocking, Full Display, No Bar"
 
2. Unfortunately %WIN is not set by ADW ... and neither by Touchwiz. Does Nova Launcher work again now?
 
regards
Daniel

woorschtsupp .

unread,
Feb 11, 2014, 8:24:08 AM2/11/14
to tas...@googlegroups.com
Hi,
 
just found Activity - Scene - Test
 
my problem is solved ...

mark jayvee pabilonia

unread,
Feb 15, 2014, 9:45:13 AM2/15/14
to tas...@googlegroups.com
i found an app that can catch the power, back and home buttons.. MX Player.. 

Pent

unread,
Feb 15, 2014, 10:41:52 AM2/15/14
to tas...@googlegroups.com

i found an app that can catch the power, back and home buttons.. MX Player..

Google are strongly for home always returning to the homescreen to prevent apps capturing
the device. There's therefore no way to prevent it without hackery that Google will
undoubtedly close if they notice it.

Pent

colin williams

unread,
May 9, 2015, 5:18:13 AM5/9/15
to tas...@googlegroups.com
Hello, this might be of help, I can capture the home back and app switch buttons using autoinput plugin you can ether block them or respond to the event and it only cost 80p, no root needed and this works on my unrooted note 4 on lollypop.
Reply all
Reply to author
Forward
0 new messages