summaryrefslogtreecommitdiffstats
path: root/src/filemanager/ext.h
diff options
context:
space:
mode:
authorDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-15 20:22:03 +0000
committerDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-15 20:22:03 +0000
commitffccd5b2b05243e7976db80f90f453dccfae9886 (patch)
tree39a43152d27f7390d8f7a6fb276fa6887f87c6e8 /src/filemanager/ext.h
parentInitial commit. (diff)
downloadmc-ffccd5b2b05243e7976db80f90f453dccfae9886.tar.xz
mc-ffccd5b2b05243e7976db80f90f453dccfae9886.zip
Adding upstream version 3:4.8.30.upstream/3%4.8.30
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'src/filemanager/ext.h')
-rw-r--r--src/filemanager/ext.h33
1 files changed, 33 insertions, 0 deletions
diff --git a/src/filemanager/ext.h b/src/filemanager/ext.h
new file mode 100644
index 0000000..771ca18
--- /dev/null
+++ b/src/filemanager/ext.h
@@ -0,0 +1,33 @@
+/** \file ext.h
+ * \brief Header: extension dependent execution
+ */
+
+#ifndef MC__EXT_H
+#define MC__EXT_H
+/*** typedefs(not structures) and defined constants **********************************************/
+
+/*** enums ***************************************************************************************/
+
+/*** structures declarations (and typedefs of structures)*****************************************/
+
+/*** global variables defined in .c file *********************************************************/
+
+/*** declarations of public functions ************************************************************/
+
+int regex_command_for (void *target, const vfs_path_t * filename_vpath, const char *action,
+ vfs_path_t ** script_vpath);
+
+/* Call it after the user has edited the mc.ext file,
+ * to flush the cached mc.ext file
+ */
+void flush_extension_file (void);
+
+/*** inline functions ****************************************************************************/
+
+static inline int
+regex_command (const vfs_path_t * filename_vpath, const char *action)
+{
+ return regex_command_for (NULL, filename_vpath, action, NULL);
+}
+
+#endif /* MC__EXT_H */