maemo.org - Talk

maemo.org - Talk (https://talk.maemo.org/index.php)
-   Maemo 5 / Fremantle (https://talk.maemo.org/forumdisplay.php?f=40)
-   -   Reboot in power menu (https://talk.maemo.org/showthread.php?t=86304)

sup 2012-08-25 12:21

Reboot in power menu
 
I tried following this guide: http://nokia-n900.com/how-to-adding-...powerkey-menu/ with no success. I figured I need to replace typographical quatation marks with " and I am able to reboot from command line with /usr/bin/sudo reboot (without sudo gainroot) and I have reboot item in the power menu, but it does nothing when pressed. Any ideas? Is that guide wrong?

UPDATE: I found a way to to this. It was rather easy in the end.

conred 2012-08-25 12:37

Re: Reboot in power menu
 
I followed this simpler guide which works as suspected: http://wiki.maemo.org/Customizing_Ma...power_key_menu

sup 2012-08-25 13:47

Re: Reboot in power menu
 
Quote:

Originally Posted by conred (Post 1255579)
I followed this simpler guide which works as suspected: http://wiki.maemo.org/Customizing_Ma...power_key_menu

Yep, but that is a rather crude method, if I understand it correctly. Might as well try it anyway.

imo 2012-08-25 14:18

Re: Reboot in power menu
 
it could work as an alternative though
root
reboot

sifo 2012-08-25 14:45

Re: Reboot in power menu
 
there is a thread "how to add a reboot button for noobs" you may want to read it.
( power search up ahead ! )

./sifo

sup 2012-08-25 14:59

Re: Reboot in power menu
 
Quote:

Originally Posted by sifo (Post 1255612)
there is a thread "how to add a reboot button for noobs" you may want to read it.
( power search up ahead ! )

./sifo

I have seen that. I did not read the entire thread, but it is the method suggested by conred if I am not mistaken.

sifo 2012-08-25 15:04

Re: Reboot in power menu
 
are you really want to play with systemui.xml ? be careful it may lead to a reflash sometims...
i made a deb long time ago to copy a systemui.xml which contains the reboot and to backup the original one but i lost it :D, will post it here if i found it

./sifo

ersanpermana 2012-08-25 17:49

Re: Reboot in power menu
 
2 Attachment(s)
My power menu:D https://www.facebook.com/media/set/?...1114376&type=3

enne30 2012-08-26 17:15

Re: Reboot in power menu
 
I know this may not be the right place to answer for, anyway where do I find configuration file for System Menu to change item's order?

sup 2012-08-26 17:17

Re: Reboot in power menu
 
/etc/systemui/systemui.xml - change the priority, I think

enne30 2012-08-26 17:31

Re: Reboot in power menu
 
1 Attachment(s)
Quote:

Originally Posted by sup (Post 1255938)
/etc/systemui/systemui.xml - change the priority, I think

Well, actually I meant the menu in the attached image... Maybe I'm wrong with the name :o

sup 2012-08-26 17:41

Re: Reboot in power menu
 
No idea. Try googlin it:-).

em28 2012-08-27 08:49

Re: Reboot in power menu
 
Hi there.
although I get root I cant go to /etc/systemui/.
I get a "Permission denied" error. :confused:

sifo 2012-08-27 09:03

Re: Reboot in power menu
 
try this...
Code:

root
leafpad /etc/systemui/systemui.xml

you need leafpad installed and a brain to know what you are doing :p

./sifo

em28 2012-08-27 10:37

Re: Reboot in power menu
 
Thanx.

Got it working after some wrong coding. :rolleyes:

sup 2012-11-22 13:56

Re: Reboot in power menu
 
So I found a way to do this thanks to this thread.

One needs to just put the following into /etc/system/systemui.xml :
Code:

  <menuitem priority="750" name="Reboot">
    <icon>general_refresh</icon>
      <callback service="com.nokia.xterm"
        path="/com/nokia/xterm"
        interface="com.nokia.xterm" method="run_command"
        bus="session" autostart="true">
      <argument type="string">/usr/bin/reboot_manual</argument>
    </callback>
  </menuitem>

And create (executable!) file /usr/bin/reboot_manual with the following content:
Code:

#!/bin/sh
# gain superuser rights.
if [ `id -u` != 0 ] ; then
    exec sudo gainroot <<EOF
exec sh $0 $*
EOF
exit $?
fi 
# put your code below
reboot

Reboot and the button should work and reboot nicely.

sixwheeledbeast 2012-11-22 18:04

Re: Reboot in power menu
 
Quote:

Originally Posted by sup (Post 1297240)
So I found a way to do this thanks to this thread.
Reboot and the button should work and reboot nicely.

Please note anybody new to this, playing about with systemui.xml can make your device unbootable if you mess it up.

peterleinchen 2012-11-22 22:57

Re: Reboot in power menu
 
Yep, just cleaned up my systemui.xml.
And you may check with
Code:

killall systemui
and waiting a few seconds, if everything is OK.

Nevertheless sixwheeledbeast's warning is valid (as in my case I am very cautious while editing and there was no mistake). If systemui should not pop up or display error or whatever, you should have possibility to re-/edit again (do NOT reboot) ...

DfLo1913 2012-11-24 20:37

Re: Reboot in power menu
 
Any chance of a download on Ham? Thanks

sixwheeledbeast 2012-11-24 20:48

Re: Reboot in power menu
 
Quote:

Originally Posted by DfLo1913 (Post 1297963)
Any chance of a download on Ham? Thanks

Eh??
Download what?

Do you mean PowEdit

DfLo1913 2012-11-24 20:56

Re: Reboot in power menu
 
Quote:

Originally Posted by sixwheeledbeast (Post 1297966)
Eh??
Download what?

Do you mean PowEdit

I mean a deb package of a reboot button in the power menu for everyone to download

DfLo1913 2012-11-24 22:36

Re: Reboot in power menu
 
If I go through PowEdit. How would I go about creating a reboot button on there? Thanks

DfLo1913 2012-11-25 01:06

Re: Reboot in power menu
 
Anyone that can help? Thanks


All times are GMT. The time now is 00:23.

vBulletin® Version 3.8.8