~willismonroe/ubuntu/precise/xdg-utils/typo-fix-996304

« back to all changes in this revision

Viewing changes to scripts/xdg-mime

  • Committer: Bazaar Package Importer
  • Author(s): Jonathan Marsden
  • Date: 2011-05-07 18:12:59 UTC
  • Revision ID: james.westby@ubuntu.com-20110507181259-yrlu64g4d33h3f5j
Tags: 1.1.0~rc1-2ubuntu4
* scripts/xdg-mime:
 - Fix detectDE to detect LXDE.
 - Create ~/.local/share/applications/mimeapps.list when needed in
   non-gnome/kde environments.

* scripts/xdg-email:
 - Fix detectDE to detect LXDE.
 - Added open_lxde shell function, used when LXDE detected.
 - Added run_sylpheed function, used to call sylpheed (LP: 779156).

Show diffs side-by-side

added added

removed removed

Lines of Context:
431
431
    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;
432
432
    elif xprop -root _DT_SAVE_MODE 2> /dev/null | grep ' = \"xfce4\"$' >/dev/null 2>&1; then DE=xfce;
433
433
    elif [ x"$DESKTOP_SESSION" = x"LXDE" ]; then DE=lxde;
 
434
    elif [ x"XDG_CURRENT_DESKTOP" = x"LXDE" ]; then DE=lxde;
434
435
    else DE=""
435
436
    fi
436
437
}
670
671
    default_file="$xdg_user_dir/applications/mimeapps.list"
671
672
    DEBUG 2 "make_default_generic $1 $2"
672
673
    DEBUG 1 "Updating $default_file"
 
674
    mkdir -p `dirname "$default_file"`
 
675
    touch "$default_file"
673
676
    awk -v mimetype="$2" -v application="$1" '
674
677
    BEGIN {
675
678
        prefix=mimetype "="