Ticket #3493: 3493-Switch-Local-User-buttons-on-menu-selector.patch

File 3493-Switch-Local-User-buttons-on-menu-selector.patch, 1.6 KB (added by mooffie, 9 years ago)
  • src/filemanager/cmd.c

    From f6a8af8623b68594fe49428d59931b52904d74c1 Mon Sep 17 00:00:00 2001
    From: Mooffie <mooffie@gmail.com>
    Date: Wed, 1 Jul 2015 09:38:57 +0300
    Subject: [PATCH] Switch "Local"/"User" buttons on menu selector.
    
    Users are more likely to want to edit their central user menu, not the local
    menu, so we make "User" the first button.
    ---
     src/filemanager/cmd.c | 8 ++++----
     1 file changed, 4 insertions(+), 4 deletions(-)
    
    diff --git a/src/filemanager/cmd.c b/src/filemanager/cmd.c
    index d824c3f..2df38e9 100644
    a b edit_mc_menu_cmd (void) 
    10131013 
    10141014    dir = query_dialog (_("Menu edit"), 
    10151015                        _("Which menu file do you want to edit?"), 
    1016                         D_NORMAL, geteuid ()? 2 : 3, _("&Local"), _("&User"), _("&System Wide")); 
     1016                        D_NORMAL, geteuid ()? 2 : 3, _("&User"), _("&Local"), _("&System Wide")); 
    10171017 
    10181018    menufile_vpath = vfs_path_build_filename (mc_global.sysconfig_dir, MC_GLOBAL_MENU, NULL); 
    10191019 
    edit_mc_menu_cmd (void) 
    10261026    switch (dir) 
    10271027    { 
    10281028    case 0: 
    1029         buffer_vpath = vfs_path_from_str (MC_LOCAL_MENU); 
     1029        buffer_vpath = mc_config_get_full_vpath (MC_USERMENU_FILE); 
    10301030        check_for_default (menufile_vpath, buffer_vpath); 
    1031         chmod (vfs_path_get_last_path_str (buffer_vpath), 0600); 
    10321031        break; 
    10331032 
    10341033    case 1: 
    1035         buffer_vpath = mc_config_get_full_vpath (MC_USERMENU_FILE); 
     1034        buffer_vpath = vfs_path_from_str (MC_LOCAL_MENU); 
    10361035        check_for_default (menufile_vpath, buffer_vpath); 
     1036        chmod (vfs_path_get_last_path_str (buffer_vpath), 0600); 
    10371037        break; 
    10381038 
    10391039    case 2: