[Bugfix/Feature] OpenPlugin and default plugins

selecting files to run is nice and all but you might not like the plugin
you can edit it OpenPlugin Viewer Plugin but instead pop it when you add
a file to reduce suprises

shortcut viewer is not ready for this so exclude it for now

Change-Id: I950599d87f47d42e8c2d59695f6583d497b217f0
adds: default plugin (if any) is selected in the open with dialog
This commit is contained in:
William Wilgus 2024-05-09 15:29:54 -04:00
parent 6e82897bfc
commit 4128a1fe48
3 changed files with 52 additions and 15 deletions

View file

@ -79,9 +79,12 @@ char* filetype_get_plugin(int attr, char *buffer, size_t buffer_len);
/* returns true if the attr is supported */
bool filetype_supported(int attr);
/* List avialable viewers */
/* List avialable viewers and start selected plugin with current_file as argument */
int filetype_list_viewers(const char* current_file);
/* return the plugin filename the user selected for the file Returns NULL if canceled */
char* filetype_get_viewer(char *buffer, size_t buffer_len, const char* current_file);
/* start a plugin with file as the argument (called from onplay.c) */
int filetype_load_plugin(const char* plugin, const char* file);