1 #include "pluginprefs.h"
2 #include "preferences.h"
7 #define _(String) gettext(String)
8 #define gettext_noop(String) String
9 #define N_(String) gettext_noop (String)
12 PluginPrefs::PluginPrefs(MWindow *mwindow, PreferencesWindow *pwindow)
13 : PreferencesDialog(mwindow, pwindow)
17 PluginPrefs::~PluginPrefs()
25 int PluginPrefs::create_objects()
30 // add_border(get_resources()->get_bg_shadow1(),
31 // get_resources()->get_bg_shadow2(),
32 // get_resources()->get_bg_color(),
33 // get_resources()->get_bg_light2(),
34 // get_resources()->get_bg_light1());
36 add_subwindow(new BC_Title(x, y, _("Plugin Set"), LARGEFONT, BLACK));
38 add_subwindow(new BC_Title(x, y, _("Look for global plugins here"), MEDIUMFONT, BLACK));
40 add_subwindow(ipathtext = new PluginGlobalPathText(x, y, pwindow, pwindow->thread->preferences->global_plugin_dir));
41 add_subwindow(ipath = new BrowseButton(mwindow,
46 pwindow->thread->preferences->global_plugin_dir,
47 ("Global Plugin Path"),
48 _("Select the directory for plugins"),
52 add_subwindow(new BC_Title(x, y, _("Look for personal plugins here"), MEDIUMFONT, BLACK));
54 add_subwindow(lpathtext = new PluginLocalPathText(x, y, pwindow, pwindow->thread->preferences->local_plugin_dir));
55 add_subwindow(lpath = new BrowseButton(mwindow,
60 pwindow->thread->preferences->local_plugin_dir,
61 _9"Personal Plugin Path"),
62 _("Select the directory for plugins"),
72 PluginGlobalPathText::PluginGlobalPathText(int x, int y, PreferencesWindow *pwindow, char *text)
73 : BC_TextBox(x, y, 200, 1, text)
75 this->pwindow = pwindow;
78 PluginGlobalPathText::~PluginGlobalPathText() {}
80 int PluginGlobalPathText::handle_event()
82 strcpy(pwindow->thread->preferences->global_plugin_dir, get_text());
89 PluginLocalPathText::PluginLocalPathText(int x, int y, PreferencesWindow *pwindow, char *text)
90 : BC_TextBox(x, y, 200, 1, text)
92 this->pwindow = pwindow;
95 PluginLocalPathText::~PluginLocalPathText() {}
97 int PluginLocalPathText::handle_event()
99 strcpy(pwindow->thread->preferences->local_plugin_dir, get_text());