Clicking in the draw area now deselects the URL bar.

svn path=/trunk/netsurf/; revision=6306
This commit is contained in:
Sean Fox 2009-01-30 21:59:01 +00:00
parent 0de8393358
commit 4789d3c09d
3 changed files with 10 additions and 0 deletions

View File

@ -282,6 +282,11 @@ void nsgtk_attach_menu_handlers(GladeXML *xml, gpointer g)
}
}
GtkWindow *nsgtk_get_window_for_scaffold(struct gtk_scaffolding *g)
{
return g->window;
}
/* event handlers and support functions for them */
gboolean nsgtk_window_delete_event(GtkWidget *widget, gpointer data)

View File

@ -25,6 +25,8 @@
typedef struct gtk_scaffolding nsgtk_scaffolding;
GtkWindow *nsgtk_get_window_for_scaffold(struct gtk_scaffolding *g);
nsgtk_scaffolding *nsgtk_new_scaffolding(struct gui_window *toplevel);
gboolean nsgtk_scaffolding_is_busy(nsgtk_scaffolding *scaffold);

View File

@ -365,6 +365,9 @@ gboolean nsgtk_window_button_press_event(GtkWidget *widget,
GdkEventButton *event, gpointer data)
{
struct gui_window *g = data;
GtkWindow *window = nsgtk_get_window_for_scaffold(g->scaffold);
gtk_window_set_focus(window, NULL);
g->mouse->pressed_x = event->x / g->bw->scale;
g->mouse->pressed_y = event->y / g->bw->scale;