summaryrefslogtreecommitdiff
path: root/frontends/framebuffer
diff options
context:
space:
mode:
Diffstat (limited to 'frontends/framebuffer')
-rw-r--r--frontends/framebuffer/gui.c37
1 files changed, 33 insertions, 4 deletions
diff --git a/frontends/framebuffer/gui.c b/frontends/framebuffer/gui.c
index 914187ba6..74d8b4c5a 100644
--- a/frontends/framebuffer/gui.c
+++ b/frontends/framebuffer/gui.c
@@ -2085,6 +2085,38 @@ gui_window_remove_caret(struct gui_window *g)
}
}
+/**
+ * process miscellaneous window events
+ *
+ * \param gw The window receiving the event.
+ * \param event The event code.
+ * \return NSERROR_OK when processed ok
+ */
+static nserror
+gui_window_event(struct gui_window *gw, enum gui_window_event event)
+{
+ switch (event) {
+ case GW_EVENT_UPDATE_EXTENT:
+ gui_window_update_extent(gw);
+ break;
+
+ case GW_EVENT_REMOVE_CARET:
+ gui_window_remove_caret(gw);
+ break;
+
+ case GW_EVENT_START_THROBBER:
+ gui_window_start_throbber(gw);
+ break;
+
+ case GW_EVENT_STOP_THROBBER:
+ gui_window_stop_throbber(gw);
+ break;
+
+ default:
+ break;
+ }
+ return NSERROR_OK;
+}
static struct gui_window_table framebuffer_window_table = {
.create = gui_window_create,
@@ -2093,15 +2125,12 @@ static struct gui_window_table framebuffer_window_table = {
.get_scroll = gui_window_get_scroll,
.set_scroll = gui_window_set_scroll,
.get_dimensions = gui_window_get_dimensions,
- .update_extent = gui_window_update_extent,
+ .event = gui_window_event,
.set_url = gui_window_set_url,
.set_status = gui_window_set_status,
.set_pointer = gui_window_set_pointer,
.place_caret = gui_window_place_caret,
- .remove_caret = gui_window_remove_caret,
- .start_throbber = gui_window_start_throbber,
- .stop_throbber = gui_window_stop_throbber,
};