Commit 3814d338 authored by Asbjørn Pettersen's avatar Asbjørn Pettersen
Browse files

add OS2 functions

parent 6fea6b33
2000-05-17 Asbjorn Pettersen <asbjornP@dualog.no>
* app/module_db.c:
* modules/modregister.h: cd wo
* modules/modregister.c (mod_dialog_register): add OS/2 functions
for dialog_register() and dialog_unregister().
2000-05-17 Sven Neumann <sven@gimp.org> 2000-05-17 Sven Neumann <sven@gimp.org>
   
* app/menus.c: rewrote the "Help/Dump Items" function. Now it * app/menus.c: rewrote the "Help/Dump Items" function. Now it
......
...@@ -67,6 +67,8 @@ extern void gimp_color_selector_register(); ...@@ -67,6 +67,8 @@ extern void gimp_color_selector_register();
extern void gimp_color_selector_unregister(); extern void gimp_color_selector_unregister();
extern void gimp_color_display_register(); extern void gimp_color_display_register();
extern void gimp_color_display_unregister(); extern void gimp_color_display_unregister();
extern void dialog_register();
extern void dialog_unregister();
static struct main_funcs_struc { static struct main_funcs_struc {
gchar *name; gchar *name;
...@@ -78,6 +80,8 @@ gimp_main_funcs[] = { ...@@ -78,6 +80,8 @@ gimp_main_funcs[] = {
{ "gimp_color_selector_unregister", gimp_color_selector_unregister }, { "gimp_color_selector_unregister", gimp_color_selector_unregister },
{ "gimp_color_display_register", gimp_color_display_register }, { "gimp_color_display_register", gimp_color_display_register },
{ "gimp_color_display_unregister", gimp_color_display_unregister }, { "gimp_color_display_unregister", gimp_color_display_unregister },
{ "dialog_register", dialog_register },
{ "dialog_unregister", dialog_unregister },
{ NULL, NULL } { NULL, NULL }
}; };
#endif #endif
......
...@@ -67,6 +67,8 @@ extern void gimp_color_selector_register(); ...@@ -67,6 +67,8 @@ extern void gimp_color_selector_register();
extern void gimp_color_selector_unregister(); extern void gimp_color_selector_unregister();
extern void gimp_color_display_register(); extern void gimp_color_display_register();
extern void gimp_color_display_unregister(); extern void gimp_color_display_unregister();
extern void dialog_register();
extern void dialog_unregister();
static struct main_funcs_struc { static struct main_funcs_struc {
gchar *name; gchar *name;
...@@ -78,6 +80,8 @@ gimp_main_funcs[] = { ...@@ -78,6 +80,8 @@ gimp_main_funcs[] = {
{ "gimp_color_selector_unregister", gimp_color_selector_unregister }, { "gimp_color_selector_unregister", gimp_color_selector_unregister },
{ "gimp_color_display_register", gimp_color_display_register }, { "gimp_color_display_register", gimp_color_display_register },
{ "gimp_color_display_unregister", gimp_color_display_unregister }, { "gimp_color_display_unregister", gimp_color_display_unregister },
{ "dialog_register", dialog_register },
{ "dialog_unregister", dialog_unregister },
{ NULL, NULL } { NULL, NULL }
}; };
#endif #endif
......
...@@ -67,6 +67,8 @@ extern void gimp_color_selector_register(); ...@@ -67,6 +67,8 @@ extern void gimp_color_selector_register();
extern void gimp_color_selector_unregister(); extern void gimp_color_selector_unregister();
extern void gimp_color_display_register(); extern void gimp_color_display_register();
extern void gimp_color_display_unregister(); extern void gimp_color_display_unregister();
extern void dialog_register();
extern void dialog_unregister();
static struct main_funcs_struc { static struct main_funcs_struc {
gchar *name; gchar *name;
...@@ -78,6 +80,8 @@ gimp_main_funcs[] = { ...@@ -78,6 +80,8 @@ gimp_main_funcs[] = {
{ "gimp_color_selector_unregister", gimp_color_selector_unregister }, { "gimp_color_selector_unregister", gimp_color_selector_unregister },
{ "gimp_color_display_register", gimp_color_display_register }, { "gimp_color_display_register", gimp_color_display_register },
{ "gimp_color_display_unregister", gimp_color_display_unregister }, { "gimp_color_display_unregister", gimp_color_display_unregister },
{ "dialog_register", dialog_register },
{ "dialog_unregister", dialog_unregister },
{ NULL, NULL } { NULL, NULL }
}; };
#endif #endif
......
...@@ -107,4 +107,24 @@ mod_color_display_unregister (const char *name) ...@@ -107,4 +107,24 @@ mod_color_display_unregister (const char *name)
return (status); return (status);
} }
void mod_dialog_register (GtkWidget *dialog)
{
dialog_reg_func reg_func;
reg_func = (dialog_reg_func) get_main_func("dialog_register");
if (!reg_func)
return;
(*reg_func) (dialog);
}
void mod_dialog_unregister (GtkWidget *dialog)
{
dialog_reg_func reg_func;
reg_func = (dialog_reg_func) get_main_func("dialog_unregister");
if (!reg_func)
return;
(*reg_func) (dialog);
}
#endif #endif
...@@ -40,6 +40,12 @@ typedef gboolean (*color_unreg_func) (GimpColorSelectorID, ...@@ -40,6 +40,12 @@ typedef gboolean (*color_unreg_func) (GimpColorSelectorID,
void *); void *);
typedef G_MODULE_EXPORT gboolean (*display_unreg_func) (const char *name); typedef G_MODULE_EXPORT gboolean (*display_unreg_func) (const char *name);
typedef void (*dialog_reg_func) (GtkWidget *dialog);
void mod_dialog_register (GtkWidget *dialog);
void mod_dialog_unregister (GtkWidget *dialog);
#define dialog_register mod_dialog_register
#define dialog_unregister mod_dialog_unregister
GimpColorSelectorID GimpColorSelectorID
mod_color_selector_register (const char *name, mod_color_selector_register (const char *name,
......
...@@ -107,4 +107,24 @@ mod_color_display_unregister (const char *name) ...@@ -107,4 +107,24 @@ mod_color_display_unregister (const char *name)
return (status); return (status);
} }
void mod_dialog_register (GtkWidget *dialog)
{
dialog_reg_func reg_func;
reg_func = (dialog_reg_func) get_main_func("dialog_register");
if (!reg_func)
return;
(*reg_func) (dialog);
}
void mod_dialog_unregister (GtkWidget *dialog)
{
dialog_reg_func reg_func;
reg_func = (dialog_reg_func) get_main_func("dialog_unregister");
if (!reg_func)
return;
(*reg_func) (dialog);
}
#endif #endif
...@@ -40,6 +40,12 @@ typedef gboolean (*color_unreg_func) (GimpColorSelectorID, ...@@ -40,6 +40,12 @@ typedef gboolean (*color_unreg_func) (GimpColorSelectorID,
void *); void *);
typedef G_MODULE_EXPORT gboolean (*display_unreg_func) (const char *name); typedef G_MODULE_EXPORT gboolean (*display_unreg_func) (const char *name);
typedef void (*dialog_reg_func) (GtkWidget *dialog);
void mod_dialog_register (GtkWidget *dialog);
void mod_dialog_unregister (GtkWidget *dialog);
#define dialog_register mod_dialog_register
#define dialog_unregister mod_dialog_unregister
GimpColorSelectorID GimpColorSelectorID
mod_color_selector_register (const char *name, mod_color_selector_register (const char *name,
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment