]> Dogcows Code - chaz/openbox/blobdiff - openbox/prompt.h
key input works for ObPrompt windows now
[chaz/openbox] / openbox / prompt.h
index 8d996ef30264f831a9ab4bd21318abc99d59c43a..09361b0496d795237cca46e8250e7abe849ca89e 100644 (file)
@@ -26,12 +26,14 @@ typedef struct _ObPromptElement ObPromptElement;
 #include "geom.h"
 #include "render/render.h"
 #include <glib.h>
+#include <X11/Xlib.h>
 
 struct _ObPromptElement {
     gchar *text;
     Window window;
 
     gint x, y, width, height;
+    gboolean pressed;
 };
 
 struct _ObPrompt
@@ -39,6 +41,8 @@ struct _ObPrompt
     ObInternalWindow super;
     gint ref;
 
+    guint event_mask;
+
     /* keep a copy of this because we re-render things that may need it
        (i.e. the buttons) */
     RrAppearance *a_bg;
@@ -52,6 +56,9 @@ struct _ObPrompt
     /* one for each answer */
     ObPromptElement *button;
     guint n_buttons;
+
+    /* points to the button with the focus */
+    ObPromptElement *focus;
 };
 
 void prompt_startup(gboolean reconfig);
@@ -64,6 +71,8 @@ void prompt_unref(ObPrompt *self);
 /*! Show the prompt.  It will be centered within the given area rectangle */
 void prompt_show(ObPrompt *self, struct _ObClient *parent);
 void prompt_hide(ObPrompt *self);
-void prompt_hide_window(Window window);
+
+void prompt_key_event(ObPrompt *self, XEvent *e);
+void prompt_mouse_event(ObPrompt *self, XEvent *e);
 
 #endif
This page took 0.020542 seconds and 4 git commands to generate.