From 06419abcca6e601671d78fbda2102740bcf403a6 Mon Sep 17 00:00:00 2001 From: Richard Wilson Date: Sun, 20 Mar 2005 14:57:19 +0000 Subject: [project @ 2005-03-20 14:57:19 by rjw] Further work towards configurable toolbars. svn path=/import/netsurf/; revision=1551 --- riscos/theme.h | 21 ++++++++++++++++----- 1 file changed, 16 insertions(+), 5 deletions(-) (limited to 'riscos/theme.h') diff --git a/riscos/theme.h b/riscos/theme.h index 38a8c2343..d0a9f0428 100644 --- a/riscos/theme.h +++ b/riscos/theme.h @@ -17,7 +17,10 @@ typedef enum { THEME_BROWSER_TOOLBAR, THEME_HOTLIST_TOOLBAR, - THEME_HISTORY_TOOLBAR + THEME_HISTORY_TOOLBAR, + THEME_BROWSER_EDIT_TOOLBAR, + THEME_HOTLIST_EDIT_TOOLBAR, + THEME_HISTORY_EDIT_TOOLBAR } toolbar_type; struct theme_file_header { @@ -78,7 +81,7 @@ struct toolbar { struct toolbar_icon *suggest; /**< suggestion toolbar icon (read only) */ struct theme_descriptor *descriptor; /**< theme descriptor (read only) */ toolbar_type type; /**< toolbar type (read only) */ - bool locked; /**< toolbar is locked from editing */ + struct toolbar *editor; /**< toolbar editor */ }; struct theme_descriptor { @@ -118,9 +121,17 @@ void ro_gui_theme_resize_toolbar_status(struct toolbar *toolbar); bool ro_gui_theme_process_toolbar(struct toolbar *toolbar, int width); void ro_gui_theme_destroy_toolbar(struct toolbar *toolbar); +void ro_gui_theme_toggle_edit(struct toolbar *toolbar); +void ro_gui_theme_toolbar_editor_sync(struct toolbar *toolbar); +void ro_gui_theme_toolbar_editor_click(struct toolbar *toolbar, wimp_pointer *pointer); +void ro_gui_theme_toolbar_editor_drag_end(wimp_dragged *drag); + struct toolbar_icon *ro_gui_theme_toolbar_get_icon(struct toolbar *toolbar, int x, int y); -bool ro_gui_theme_toolbar_separator_following(struct toolbar_icon *icon); -#define ro_gui_theme_toolbar_height(toolbar) toolbar->height > toolbar->max_height ? \ - toolbar->max_height : toolbar->height +#define ro_gui_theme_toolbar_height(toolbar) toolbar->height + \ + (toolbar->editor ? toolbar->editor->height : 0) > toolbar->max_height ? \ + toolbar->max_height : toolbar->height + \ + (toolbar->editor ? toolbar->editor->height : 0) +#define ro_gui_theme_toolbar_full_height(toolbar) toolbar->height + \ + (toolbar->editor ? toolbar->editor->height : 0) #endif -- cgit v1.2.3