aboutsummaryrefslogtreecommitdiff
path: root/include/ui/console.h
diff options
context:
space:
mode:
authorGerd Hoffmann <kraxel@redhat.com>2013-03-14 11:56:16 +0100
committerGerd Hoffmann <kraxel@redhat.com>2013-04-16 09:03:49 +0200
commit0f7b2864d0d0c3ef2801f9214d8c510c80a220d1 (patch)
tree2223119758f09c83a125f6335c483618910e8569 /include/ui/console.h
parent380cd056ec0e7fc8bbd553cdcb061d3ca612bb82 (diff)
console: gui timer fixes
Make gui update rate adaption code in gui_update() actually work. Sprinkle in a tracepoint so you can see the code at work. Remove the update rate adaption code in vnc and make vnc simply use the generic bits instead. Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
Diffstat (limited to 'include/ui/console.h')
-rw-r--r--include/ui/console.h9
1 files changed, 5 insertions, 4 deletions
diff --git a/include/ui/console.h b/include/ui/console.h
index f3e779193c..3cb00180ae 100644
--- a/include/ui/console.h
+++ b/include/ui/console.h
@@ -21,7 +21,8 @@
#define QEMU_CAPS_LOCK_LED (1 << 2)
/* in ms */
-#define GUI_REFRESH_INTERVAL 30
+#define GUI_REFRESH_INTERVAL_DEFAULT 30
+#define GUI_REFRESH_INTERVAL_IDLE 3000
typedef void QEMUPutKBDEvent(void *opaque, int keycode);
typedef void QEMUPutLEDEvent(void *opaque, int ledstate);
@@ -174,8 +175,7 @@ typedef struct DisplayChangeListenerOps {
} DisplayChangeListenerOps;
struct DisplayChangeListener {
- int idle;
- uint64_t gui_timer_interval;
+ uint64_t update_interval;
const DisplayChangeListenerOps *ops;
DisplayState *ds;
@@ -207,12 +207,13 @@ static inline int is_buffer_shared(DisplaySurface *surface)
void register_displaychangelistener(DisplayState *ds,
DisplayChangeListener *dcl);
+void update_displaychangelistener(DisplayChangeListener *dcl,
+ uint64_t interval);
void unregister_displaychangelistener(DisplayChangeListener *dcl);
void dpy_gfx_update(QemuConsole *con, int x, int y, int w, int h);
void dpy_gfx_replace_surface(QemuConsole *con,
DisplaySurface *surface);
-void dpy_refresh(DisplayState *s);
void dpy_gfx_copy(QemuConsole *con, int src_x, int src_y,
int dst_x, int dst_y, int w, int h);
void dpy_text_cursor(QemuConsole *con, int x, int y);