maemo.org - Talk

maemo.org - Talk (https://talk.maemo.org/index.php)
-   Applications (https://talk.maemo.org/forumdisplay.php?f=41)
-   -   iphone / htc like power button one click = screen lock (https://talk.maemo.org/showthread.php?t=44971)

MohammadAG 2010-02-19 21:19

Re: iphone / htc like power button one click = screen lock
 
Download and install rootsh from extras.
Open terminal and type root
Then type vi /etc/mce/mce.ini
Scroll down to this line:
PowerKeyShortAction=menu
Press I to enter input mode, remove menu and type tklock so that it's:
PowerKeyShortAction=tklock
Press CTRL+C to exit input mode
Type :w to save the file then press
Press CTRL+Z to exit
Type stop mce then start mce

Remember to remap the menu to something else (double click/long click w/e)

P.S. don't use caps, if someone has an answer they'll post it

Grant 2010-02-19 21:22

Re: iphone / htc like power button one click = screen lock
 
Check out this thread on how to create a desktop shortcut that locks your screen. I have one on the bottom right corner of each of the 4 desktops, so locking the screen is always just a tap away.

Ali_rshojakhani 2010-02-19 21:25

Re: iphone / htc like power button one click = screen lock
 
thnx guys... btw sorry for being rude. my bad.

Ali_rshojakhani 2010-02-19 22:01

Re: iphone / htc like power button one click = screen lock
 
Quote:

Originally Posted by MohammadAG (Post 537357)
Download and install rootsh from extras.
Open terminal and type root
Then type vi /etc/mce/mce.ini
Scroll down to this line:
PowerKeyShortAction=menu
Press I to enter input mode, remove menu and type tklock so that it's:
PowerKeyShortAction=tklock
Press CTRL+C to exit input mode
Type :w to save the file then press
Press CTRL+Z to exit
Type stop mce then start mce

Remember to remap the menu to something else (double click/long click w/e)

P.S. don't use caps, if someone has an answer they'll post it


thank u so much...
for unlocking is there a way to skip the swipe screen?

Crude 2010-02-20 06:07

Re: iphone / htc like power button one click = screen lock
 
Ali_rshojakhani, it would be quite a hassle if you tweaked the power button because a single press on it actually brings up a menu with a number of options such as: Silent, Secure Device and a very important option End Task (Which is useful if an app hangs).

If you modify it than how would you bring down this menu? Also a single click can be pressed in your pocket by mistake and if there is no slide to unlock then random presses on the screen can be a problem and trust me, the resistive touch screen does allow for random changes in your pocket if unlocked (happened to me).

I believe the more you use it the more you'll realise that there's no need for the change. Anyhow there are two apps in the D-level repo: Tweakr and Shortcutd that you might be interested in. These give you access to a number of settings not available.

Try them, I'm sure you'll like them. They work great.

Matan 2010-02-20 12:28

Re: iphone / htc like power button one click = screen lock
 
Package powerlock in extras-devel (and my repository) implements lock and unlock on single power key press.

HtheB 2010-02-20 13:58

Re: iphone / htc like power button one click = screen lock
 
There is an app on the repositories called tweakr...

You can change the power button actions with this on the phone settings :)

GIve it a try :)

Grant 2010-02-20 16:24

Re: iphone / htc like power button one click = screen lock
 
Quote:

Originally Posted by Matan (Post 538336)
Package powerlock in extras-devel (and my repository) implements lock and unlock on single power key press.

Added powerlock from your repository, very nice! Thanks for that. After installation, I used tweakr to set a single power key short press to "do nothing" which made the locking go a little faster since the menu doesn't pop down briefly. But, changing power key double press to "show menu" doesn't work since your app registers the first press and locks the screen. With powerlock installed, is there no other way to access the power key menu than by keeping the default power key menu settings, which gives you a 2 second window to select an option from the menu before it locks? I only use that menu to quickly enable silent mode, so its no big deal to me, but was wondering if you will be improving upon your nice app.

ToJa92 2010-02-20 16:36

Re: iphone / htc like power button one click = screen lock
 
Or how about this, switch the function of the lock-switch with the powerbutton? So pressing the power button have the desired effect and you can still turn off the device easily. And access the menu.

Matan 2010-02-20 17:16

Re: iphone / htc like power button one click = screen lock
 
Switching keys can be easily done in kernel space, but not in user space, since mce is closed. You can ask Nokia for those options, but my guess is that such request will be ignored.


All times are GMT. The time now is 12:28.

vBulletin® Version 3.8.8