ui/common/context.h

changeset 1200
abb4d3851061
parent 1198
5bb4366b0c32
equal deleted inserted replaced
1199:13b18989113c 1200:abb4d3851061
102 void *onattachdata; 102 void *onattachdata;
103 103
104 ui_callback ondetach; 104 ui_callback ondetach;
105 void *ondetachdata; 105 void *ondetachdata;
106 106
107 ui_callback onattachmentstatuschange;
108 void *onattachmentstatuschangedata;
109
107 ui_callback onclose; 110 ui_callback onclose;
108 void *onclosedata; 111 void *onclosedata;
109 112
110 unsigned int ref; 113 unsigned int ref;
111 }; 114 };
147 void uic_context_detach_document(UiContext *ctx, void *document); 150 void uic_context_detach_document(UiContext *ctx, void *document);
148 void uic_context_attach_context(UiContext *ctx, UiContext *doc_ctx); // TODO 151 void uic_context_attach_context(UiContext *ctx, UiContext *doc_ctx); // TODO
149 void uic_context_detach_context(UiContext *ctx, UiContext *doc_ctx); // TODO 152 void uic_context_detach_context(UiContext *ctx, UiContext *doc_ctx); // TODO
150 void uic_context_detach_all(UiContext *ctx); 153 void uic_context_detach_all(UiContext *ctx);
151 154
155 void uic_send_status_change(UiContext *ctx);
156
152 UiVar* uic_get_var(UiContext *ctx, const char *name); 157 UiVar* uic_get_var(UiContext *ctx, const char *name);
153 UiVar* uic_get_var_t(UiContext *ctx, const char *name, UiVarType type); 158 UiVar* uic_get_var_t(UiContext *ctx, const char *name, UiVarType type);
154 UiVar* uic_create_var(UiContext *ctx, const char *name, UiVarType type); 159 UiVar* uic_create_var(UiContext *ctx, const char *name, UiVarType type);
155 UiVar* uic_create_value_var(UiContext *ctx, void *value); 160 UiVar* uic_create_value_var(UiContext *ctx, void *value);
156 void* uic_create_value(UiContext *ctx, UiVarType type); 161 void* uic_create_value(UiContext *ctx, UiVarType type);
173 void uic_add_state_widget_i(UiContext *ctx, void *widget, ui_enablefunc enable, const int *states, size_t numstates); 178 void uic_add_state_widget_i(UiContext *ctx, void *widget, ui_enablefunc enable, const int *states, size_t numstates);
174 void uic_remove_state_widget(UiContext *ctx, void *widget); 179 void uic_remove_state_widget(UiContext *ctx, void *widget);
175 180
176 UIEXPORT void ui_context_onattach(UiContext *ctx, ui_callback cb, void *data); 181 UIEXPORT void ui_context_onattach(UiContext *ctx, ui_callback cb, void *data);
177 UIEXPORT void ui_context_ondetach(UiContext *ctx, ui_callback cb, void *data); 182 UIEXPORT void ui_context_ondetach(UiContext *ctx, ui_callback cb, void *data);
183 UIEXPORT void ui_context_onattachmentstatuschange(UiContext *ctx, ui_callback cb, void *data);
178 UIEXPORT void ui_context_onattach_action(UiContext *ctx, const char *action); 184 UIEXPORT void ui_context_onattach_action(UiContext *ctx, const char *action);
179 UIEXPORT void ui_context_ondetach_action(UiContext *ctx, const char *action); 185 UIEXPORT void ui_context_ondetach_action(UiContext *ctx, const char *action);
186 UIEXPORT void ui_context_onattachmentstatuschange_action(UiContext *ctx, const char *action);
187
188 UIEXPORT int ui_context_is_attached(UiContext *ctx);
189 UIEXPORT int ui_context_is_attached_to_obj(UiContext *ctx);
180 190
181 #ifdef __cplusplus 191 #ifdef __cplusplus
182 } 192 }
183 #endif 193 #endif
184 194

mercurial