User Tools

Site Tools


howto:enable_asuslauncher_in_advanced_mode

Enabling AsusLauncher in Advanced Desktop Mode

Do you like the simple tabbed interface of Easy Mode, but want the functionality of the advanced desktop? Now you can get the best of both worlds. You can keep the simple AsusLauncher GUI and but have all the power and perks of running the KDE desktop (including using Beryl). You won't even have to give up your regular desktop to do it.

This guide will show you how to have AsusLauncher at startup of advanced desktop.

Preparation

If you have not yet enabled Advanced Desktop, follow this guide

Trying it out

First you should experiment with AsusLauncher before committing it to startup. We'll try it out, not because it is hard to fix, but it's easier to fix problems by reseting rather than possibly mucking about with the restore function or other Linux distributions. To try AsusLauncher out, follow these steps.

  • Option 1: open a console from start→applications→system→console
sudo /opt/xandros/bin/AsusLauncher
  • NB: the power button will not work if you have not applied the power button fix, since AsusLauncher must be run as root. Running any application as root messes up the power button script. Here is a link to the fix.

Alternatively, if you want to be able to access the regular desktop, you will need a system tray icon to toggle the visibility of AsusLauncher. You can do this with the following command in a terminal.

  • Option 2: open a console from start→applications→system→console and enter the following command
ksystraycmd sudo /opt/xandros/bin/AsusLauncher

You will notice an X near the battery meter and other system tray applications. You can toggle the visibility of AsusLauncher by clicking this X.

How to kill AsusLauncher

If you want to quit AsusLauncher you will either have to reboot or run the taskmanger as root. To kill the process from a taskbar, follow these steps. If you want to quit the AsusLauncher quick test, simply press <CTRL> + 'C' in the console window.

  1. open a console from start→applications→system→console and enter the following command
    sudo ksysguard --showprocesses
  2. next to the “Tree” check box, open the drop down menu and select “All Processes”
  3. find the AsusLauncher process and press the Kill button to kill it
  • NB: be careful when killing processes as you can do some serious damage to the system if you are not careful

How to create an 'easy-switch' shortcut in Advanced Desktop Mode

If you want to regularly switch between AsusLauncher (Easy Desktop Mode)and the Advanced Desktop without rebooting, a good alternative will be to create a shortcut, like eg: a desktop Icon, where which you can enable/disable the AsusLauncher anytime you want to.

Create a shortcut

  1. Rightclick on the desktop, select “Create New » Shortcut”
  2. Select “Program”, “Next>”
  3. In the “Type the location of the program”-window type:
    Konsole
  4. Next>
  5. name it whatever you want… eg: “Easy Desktop”, click “Finish”

Modify Shortcut

  1. Rightclick the Icon and select “properties”
  2. Select “Execute”-tab, and modify the text in the 'Command'-window to:
    konsole -e sudo /opt/xandros/bin/AsusLauncher
  3. click 'ok'

Exiting AsusLauncher

After you doubleclicked your 'easy desktop'-icon you'll see that Konsole still is active and waiting. You can exit the easy desktop mode by closing the console window, or pressing <CTRL> + 'C' in the konsole-window.

You can copy or move the 'easy desktop'-Icon anywhere you'd like (eg. in: 'My Documents' or so…)

Instructions: making AsusLauncher start on boot

  1. open a console from start→applications→system→console and enter the following command
    sudo kwrite /home/user/.kde/Autostart/AsusLauncher.desktop
  2. create a shortcut to start AsusLauncher
    • paste in the following code to startup AsusLauncher without a system tray icon
      [Desktop Entry]
      Comment=
      Exec=sudo /opt/xandros/bin/AsusLauncher
      GenericName=
      Icon=kcmx
      Name=AsusLauncher
      Path=
      StartupNotify=false
      Terminal=0
      TerminalOptions=
      Type=Application
      X-KDE-SubstituteUID=false
      X-KDE-Username=
    • alternatively paste in the following code to startup AsusLauncher with a system tray icon
      [Desktop Entry]
      Comment=
      Exec=ksystraycmd sudo /opt/xandros/bin/AsusLauncher
      GenericName=
      Icon=kcmx
      Name=AsusLauncher
      Path=
      StartupNotify=false
      Terminal=0
      TerminalOptions=
      Type=Application
      X-KDE-SubstituteUID=false
      X-KDE-Username=
  3. save the file
    • NB: AsusLauncher MUST be run with the sudo command. If it is started on startup without the sudo command, your system will get stuck in an infinite loop. If this happens you will have to modify or remove the shortcut you made following these instruction or perform an F9 restore (NOT recommended).
  4. Since AsusLauncher requires root privileges to run, you will need to follow this guide to fix your power button

Forcing Applications to Run as user Rather Than root

One problem with running AsusLauncher in advanced mode is that all applications run as root (the superuser). This causes some undesirable behavior, including that the application sees the home directory as /root rather than as /user/home. Described below is some rather tedious editing that will force applications to run as user rather than root.

Note: Some apparently simpler ways of accomplishing this fail to work properly. See this forum thread for details.

  1. Create a new desktop shortcut file that will run an arbitrary program as user. To do this, create a new file called /user/home/.AsusLauncher/udo.profile containing the following:
    [Desktop Entry]
    Comment=
    Exec=sudo -u user
    GenericName=
    Icon=
    Name=Udo
    Path=
    StartupNotify=false
    Terminal=0
    TerminalOptions=
    Type=Application
    X-KDE-SubstituteUID=true
    X-KDE-Username=user
  2. Make a backup copy of your simpleui.rc file. This will normally be at /opt/xandros/share/AsusLauncher/simpleui.rc, but if you've made any customizations, it may be at /user/home/.AsusLauncher/simpleui.rc or /var/lib/AsusLauncher/simpleui.rc – in either case, make a copy in case you make a mistake.
  3. Use a text editor to edit your simpleui.rc file that you just backed up in the previous step. For each application you don't want to run as root, you need to do the following:
    • Find the corresponding line that starts with <parcel
    • If the line already contains an entry of the form shortcut=“something.desktop”, skip it and deal with it in step 4.
    • If not, then add the following to the line, immediately before extraargs=:
      shortcut="/home/user/.AsusLauncher/udo.desktop" 

      For example, the entry for File Manager should look something like this:

      <parcel simplecat="Work" shortcut="/home/user/.AsusLauncher/udo.desktop" extraargs="/usr/bin/XandrosFileManager -maximized" 
      	icon="file_manager_norm.png"
      	selected_icon="file_manager_hi.png">
      	<name lang="en">File Manager</name>
      </parcel>
  4. For each of the items you skipped at step 3, use a text editor to edit the corresponding shortcut file (after making a backup copy of the file in case you make a mistake). Prepend the command sudo -u user to the command specified on the Exec line in the shortcut file. For example, if the relevant line in your simpleui.rc file contains shortcut=“skype.desktop”, then you should open the file /usr/share/applications/skype.desktop in a text editor, and change the line:
    Exec=run-skype.sh

    to read as follows:

    Exec=sudo -u user run-skype.sh

    Also note that /usr/games is not in root's default path, so you have to specify the full pathname of any program that is located there or the program won't launch. For example, in the file /usr/share/applications/frozen-bubble.desktop, the line

    Exec=frozen-bubble

    has to become

    Exec=sudo -u user /usr/games/frozen-bubble



This wiki is primarily based on http://forum.eeeuser.com/viewtopic.php?id=5741 rio sosh code rio

howto/enable_asuslauncher_in_advanced_mode.txt · Last modified: 2012/01/27 19:13 by hello