Index: xdg-email.in =================================================================== RCS file: /cvs/portland/portland/xdg-utils/scripts/xdg-email.in,v retrieving revision 1.39 diff -u -r1.39 xdg-email.in --- xdg-email.in 24 Sep 2010 17:47:58 -0000 1.39 +++ xdg-email.in 16 Oct 2010 08:45:44 -0000 @@ -363,7 +363,7 @@ open_xfce "${mailto}" ;; - generic) + generic|lxde) open_generic "${mailto}" ;; Index: xdg-file-dialog.in =================================================================== RCS file: /cvs/portland/portland/xdg-utils/scripts/xdg-file-dialog.in,v retrieving revision 1.12 diff -u -r1.12 xdg-file-dialog.in --- xdg-file-dialog.in 24 Sep 2010 15:43:53 -0000 1.12 +++ xdg-file-dialog.in 16 Oct 2010 08:45:44 -0000 @@ -312,7 +312,7 @@ open_kde "$filename" ;; - gnome|xfce) + gnome|xfce|lxde) open_zenity "$filename" ;; @@ -326,7 +326,7 @@ open_multi_kde "$filename" ;; - gnome|xfce) + gnome|xfce|lxde) open_multi_zenity "$filename" ;; @@ -340,7 +340,7 @@ save_kde "$filename" ;; - gnome|xfce) + gnome|xfce|lxde) save_zenity "$filename" ;; @@ -354,7 +354,7 @@ directory_kde "$filename" ;; - gnome|xfce) + gnome|xfce|lxde) directory_zenity "$filename" ;; Index: xdg-open.in =================================================================== RCS file: /cvs/portland/portland/xdg-utils/scripts/xdg-open.in,v retrieving revision 1.38 diff -u -r1.38 xdg-open.in --- xdg-open.in 24 Sep 2010 15:43:54 -0000 1.38 +++ xdg-open.in 16 Oct 2010 08:45:44 -0000 @@ -163,6 +163,32 @@ exit_failure_operation_impossible "no method available for opening '$1'" } +open_lxde() +{ + # pcmanfm only knows how to handle file:// urls and filepaths, it seems. + if (echo "$1" | grep -q '^file://' || + ! echo "$1" | egrep -q '^[a-zA-Z+\.\-]+:') + then + local file="$(echo "$1" | sed 's%^file://%%')" + + # handle relative paths + if ! echo "$file" | grep -q '^/'; then + file="$(pwd)/$file" + fi + + pcmanfm "$file" + + else + open_generic "$1" + fi + + if [ $? -eq 0 ]; then + exit_success + else + exit_failure_operation_failed + fi +} + [ x"$1" != x"" ] || exit_failure_syntax url= @@ -215,6 +241,10 @@ open_xfce "$url" ;; + lxde) + open_lxde "$url" + ;; + generic) open_generic "$url" ;; Index: xdg-su.in =================================================================== RCS file: /cvs/portland/portland/xdg-utils/scripts/xdg-su.in,v retrieving revision 1.17 diff -u -r1.17 xdg-su.in --- xdg-su.in 24 Sep 2010 15:43:54 -0000 1.17 +++ xdg-su.in 16 Oct 2010 08:45:44 -0000 @@ -146,7 +146,7 @@ su_kde ;; - gnome) + gnome|lxde) su_gnome ;; Index: xdg-terminal.in =================================================================== RCS file: /cvs/portland/portland/xdg-utils/scripts/xdg-terminal.in,v retrieving revision 1.4 diff -u -r1.4 xdg-terminal.in --- xdg-terminal.in 24 Sep 2010 15:43:54 -0000 1.4 +++ xdg-terminal.in 16 Oct 2010 08:45:44 -0000 @@ -161,7 +161,7 @@ terminal_xfce "$command" ;; - generic) + generic|lxde) terminal_generic "$command" ;; Index: xdg-utils-common.in =================================================================== RCS file: /cvs/portland/portland/xdg-utils/scripts/xdg-utils-common.in,v retrieving revision 1.28 diff -u -r1.28 xdg-utils-common.in --- xdg-utils-common.in 1 Mar 2010 06:55:01 -0000 1.28 +++ xdg-utils-common.in 16 Oct 2010 08:45:44 -0000 @@ -197,6 +197,7 @@ elif [ x"$GNOME_DESKTOP_SESSION_ID" != x"" ]; then DE=gnome; elif `dbus-send --print-reply --dest=org.freedesktop.DBus /org/freedesktop/DBus org.freedesktop.DBus.GetNameOwner string:org.gnome.SessionManager > /dev/null 2>&1` ; then DE=gnome; elif xprop -root _DT_SAVE_MODE 2> /dev/null | grep ' = \"xfce4\"$' >/dev/null 2>&1; then DE=xfce; + elif [ x"$DESKTOP_SESSION" == x"LXDE" ]; then DE=lxde; fi }