root/src/filemanager/cmd.h

/* [previous][next][first][last][top][bottom][index][help]  */

INCLUDED FROM


DEFINITIONS

This source file includes following definitions.
  1. copy_cmd
  2. copy_cmd_local
  3. rename_cmd
  4. rename_cmd_local
  5. delete_cmd
  6. delete_cmd_local

   1 /** \file cmd.h
   2  *  \brief Header: routines invoked by a function key
   3  *
   4  *  They normally operate on the current panel.
   5  */
   6 
   7 #ifndef MC__CMD_H
   8 #define MC__CMD_H
   9 
  10 #include "lib/global.h"
  11 
  12 #include "file.h"               /* panel_operate() */
  13 #include "panel.h"
  14 
  15 /*** typedefs(not structures) and defined constants **********************************************/
  16 
  17 /*** enums ***************************************************************************************/
  18 
  19 typedef enum
  20 {
  21     LINK_HARDLINK = 0,
  22     LINK_SYMLINK_ABSOLUTE,
  23     LINK_SYMLINK_RELATIVE
  24 } link_type_t;
  25 
  26 /*** structures declarations (and typedefs of structures)*****************************************/
  27 
  28 /*** global variables defined in .c file *********************************************************/
  29 
  30 /*** declarations of public functions ************************************************************/
  31 
  32 #ifdef ENABLE_VFS_FTP
  33 void ftplink_cmd (void);
  34 #endif
  35 #ifdef ENABLE_VFS_SFTP
  36 void sftplink_cmd (void);
  37 #endif
  38 #ifdef ENABLE_VFS_FISH
  39 void fishlink_cmd (void);
  40 #endif
  41 void undelete_cmd (void);
  42 void help_cmd (void);
  43 void smart_dirsize_cmd (WPanel * panel);
  44 void single_dirsize_cmd (WPanel * panel);
  45 void dirsizes_cmd (WPanel * panel);
  46 gboolean view_file_at_line (const vfs_path_t * filename_vpath, gboolean plain_view,
  47                             gboolean internal, long start_line, off_t search_start,
  48                             off_t search_end);
  49 gboolean view_file (const vfs_path_t * filename_vpath, gboolean plain_view, gboolean internal);
  50 void view_cmd (WPanel * panel);
  51 void view_file_cmd (const WPanel * panel);
  52 void view_raw_cmd (WPanel * panel);
  53 void view_filtered_cmd (const WPanel * panel);
  54 void edit_file_at_line (const vfs_path_t * what_vpath, gboolean internal, long start_line);
  55 void edit_cmd (const WPanel * panel);
  56 void edit_cmd_new (void);
  57 #ifdef USE_INTERNAL_EDIT
  58 void edit_cmd_force_internal (const WPanel * panel);
  59 #endif
  60 void mkdir_cmd (WPanel * panel);
  61 void reread_cmd (void);
  62 void vfs_list (WPanel * panel);
  63 void ext_cmd (void);
  64 void edit_mc_menu_cmd (void);
  65 void edit_fhl_cmd (void);
  66 void hotlist_cmd (WPanel * panel);
  67 void compare_dirs_cmd (void);
  68 #ifdef USE_DIFF_VIEW
  69 void diff_view_cmd (void);
  70 #endif
  71 void panel_tree_cmd (void);
  72 void link_cmd (link_type_t link_type);
  73 void edit_symlink_cmd (void);
  74 void swap_cmd (void);
  75 void quick_cd_cmd (WPanel * panel);
  76 void save_setup_cmd (void);
  77 void user_file_menu_cmd (void);
  78 void info_cmd (void);
  79 void listing_cmd (void);
  80 void setup_listing_format_cmd (void);
  81 void quick_cmd_no_menu (void);
  82 void info_cmd_no_menu (void);
  83 void quick_view_cmd (void);
  84 #ifdef HAVE_CHARSET
  85 void encoding_cmd (void);
  86 #endif
  87 /* achown.c */
  88 void advanced_chown_cmd (WPanel * panel);
  89 /* chmod.c */
  90 void chmod_cmd (WPanel * panel);
  91 /* chown.c */
  92 void chown_cmd (WPanel * panel);
  93 #ifdef ENABLE_EXT2FS_ATTR
  94 /* chattr.c */
  95 void chattr_cmd (WPanel * panel);
  96 const char *chattr_get_as_str (unsigned long attr);
  97 #endif
  98 /* find.c */
  99 void find_cmd (WPanel * panel);
 100 
 101 /* --------------------------------------------------------------------------------------------- */
 102 /*** inline functions ****************************************************************************/
 103 /* --------------------------------------------------------------------------------------------- */
 104 
 105 /**
 106  * Copy, default to the other panel.
 107  */
 108 
 109 static inline void
 110 copy_cmd (WPanel * panel)
     /* [previous][next][first][last][top][bottom][index][help]  */
 111 {
 112     panel_operate (panel, OP_COPY, FALSE);
 113 }
 114 
 115 /* --------------------------------------------------------------------------------------------- */
 116 /**
 117  * Copy, default to the same panel, ignore marks.
 118  */
 119 
 120 static inline void
 121 copy_cmd_local (WPanel * panel)
     /* [previous][next][first][last][top][bottom][index][help]  */
 122 {
 123     panel_operate (panel, OP_COPY, TRUE);
 124 }
 125 
 126 /* --------------------------------------------------------------------------------------------- */
 127 /**
 128  * Move/rename, default to the other panel.
 129  */
 130 
 131 static inline void
 132 rename_cmd (WPanel * panel)
     /* [previous][next][first][last][top][bottom][index][help]  */
 133 {
 134     panel_operate (panel, OP_MOVE, FALSE);
 135 }
 136 
 137 /* --------------------------------------------------------------------------------------------- */
 138 /**
 139  * Move/rename, default to the same panel, ignore marks.
 140  */
 141 
 142 static inline void
 143 rename_cmd_local (WPanel * panel)
     /* [previous][next][first][last][top][bottom][index][help]  */
 144 {
 145     panel_operate (panel, OP_MOVE, TRUE);
 146 }
 147 
 148 /* --------------------------------------------------------------------------------------------- */
 149 /**
 150  *  Remove.
 151  */
 152 
 153 static inline void
 154 delete_cmd (WPanel * panel)
     /* [previous][next][first][last][top][bottom][index][help]  */
 155 {
 156     panel_operate (panel, OP_DELETE, FALSE);
 157 }
 158 
 159 /* --------------------------------------------------------------------------------------------- */
 160 /**
 161  *  Remove, ignore marks.
 162  */
 163 
 164 static inline void
 165 delete_cmd_local (WPanel * panel)
     /* [previous][next][first][last][top][bottom][index][help]  */
 166 {
 167     panel_operate (panel, OP_DELETE, TRUE);
 168 }
 169 
 170 /* --------------------------------------------------------------------------------------------- */
 171 
 172 #endif /* MC__CMD_H */

/* [previous][next][first][last][top][bottom][index][help]  */