app: Add gimp_tool_options_editor_get_tool_options()

Add gimp_tool_options_editor_get_tool_options() for unit testing
purposes.
This commit is contained in:
Martin Nordholts 2009-12-24 17:31:45 +01:00
parent e8ff034ab5
commit 0f7c373f3b
2 changed files with 11 additions and 4 deletions

View File

@ -310,6 +310,13 @@ gimp_tool_options_editor_new (Gimp *gimp,
return GTK_WIDGET (editor);
}
GimpToolOptions *
gimp_tool_options_editor_get_tool_options (GimpToolOptionsEditor *editor)
{
g_return_val_if_fail (GIMP_IS_TOOL_OPTIONS_EDITOR (editor), NULL);
return editor->p->visible_tool_options;
}
/* private functions */

View File

@ -49,10 +49,10 @@ struct _GimpToolOptionsEditorClass
};
GType gimp_tool_options_editor_get_type (void) G_GNUC_CONST;
GtkWidget * gimp_tool_options_editor_new (Gimp *gimp,
GimpMenuFactory *menu_factory);
GType gimp_tool_options_editor_get_type (void) G_GNUC_CONST;
GtkWidget * gimp_tool_options_editor_new (Gimp *gimp,
GimpMenuFactory *menu_factory);
GimpToolOptions * gimp_tool_options_editor_get_tool_options (GimpToolOptionsEditor *editor);
#endif /* __GIMP_TOOL_OPTIONS_EDITOR_H__ */