diff options
author | Ole Loots <ole@monochrom.net> | 2012-12-21 00:56:50 +0100 |
---|---|---|
committer | Ole Loots <ole@monochrom.net> | 2012-12-21 00:56:50 +0100 |
commit | f7ee2a03876bf4a5cf66b3a433955e4e55d91362 (patch) | |
tree | 146748923e9aaa464fac29306cc51cb06ef589ec /atari/gemtk/aestabs.h | |
parent | 3019368c93600a335445c09178c9554074c7f656 (diff) | |
download | netsurf-f7ee2a03876bf4a5cf66b3a433955e4e55d91362.tar.gz netsurf-f7ee2a03876bf4a5cf66b3a433955e4e55d91362.tar.bz2 |
- started to work on settings dialog
- some WIP in treeview widgets. Changed destroy / and init handling.
It requires some optimization, when the widget is closed
it must remove itself from the guiwin list, for perfomance.
Diffstat (limited to 'atari/gemtk/aestabs.h')
-rw-r--r-- | atari/gemtk/aestabs.h | 56 |
1 files changed, 56 insertions, 0 deletions
diff --git a/atari/gemtk/aestabs.h b/atari/gemtk/aestabs.h new file mode 100644 index 000000000..c72054acc --- /dev/null +++ b/atari/gemtk/aestabs.h @@ -0,0 +1,56 @@ +#ifndef AESTABS_H_INCLUDED
+#define AESTABS_H_INCLUDED
+ +struct aes_tab_s; +struct aes_tablist_s; +typedef struct aes_tab_s AES_TAB; +typedef struct aes_tablist_s AES_TABLIST; + +#define AES_TABLIST_TAB_ACTIVATED 0x01 +#define AES_TABLIST_TAB_DEACTIVATED 0x02 + +#define AES_TABLIST_OPTION_FORCE_EVENTS 0x01 // do not eat events which do + // not changed the internal state + // this is required for tabs which + // require "activate" events + // for tabs which are already + // selected. + + +struct aes_tablist_user_args_s +{ + short event; + AES_TAB *tab; +}; + +typedef struct aes_tablist_user_args_s AES_TABLIST_FUNC_ARGS; + +typedef void (*aes_tablist_user_func)(AES_TABLIST * list, + AES_TABLIST_FUNC_ARGS * args); + +struct aes_tab_s { + short obj_tab; + short obj_page; + OBJECT * page_tree; + AES_TAB * next, *prev; +}; + +struct aes_tablist_s { + OBJECT *tree; + AES_TAB * first; + aes_tablist_user_func user_func; +}; + + + +AES_TABLIST * tablist_declare(OBJECT *tree, aes_tablist_user_func user_func); +void tablist_delete(AES_TABLIST * tablist); +AES_TAB * tablist_add(AES_TABLIST * tablist, short tab, OBJECT *page_tree, + short page); +short tablist_activate(AES_TABLIST * tablist, short tab, short option); +struct aes_tab_s *tablist_get_active(AES_TABLIST * tablist); +AES_TAB * tablist_find(AES_TABLIST * tablist, OBJECT *page, short tab); + +#define AES_TAB_IS_ACTIVE(l, x) (tablist_get_active(l) == x) +
+#endif // AESTABS_H_INCLUDED
|