summaryrefslogtreecommitdiff
path: root/endless/eostopbar.c
diff options
context:
space:
mode:
authorPhilip Chimento <philip@endlessm.com>2013-12-03 16:29:36 -0800
committerPhilip Chimento <philip@endlessm.com>2013-12-17 12:00:03 -0800
commit1493b8b870908bf466222d8db7041935a4d504e7 (patch)
tree5cab55c9294d414fe7146c6a9576d6789c9888fd /endless/eostopbar.c
parent9bd3455dba4eaa06c4a848c948b1042e65784357 (diff)
Remove internal child code
GTK 3.10 has gtk_window_set_titlebar(), so we can remove a lot of code that was necessary for treating the top bar as an internal child and dragging the window by its top bar. By setting the 'decorated' flag again, this also solves #375. [endlessm/eos-sdk#28]
Diffstat (limited to 'endless/eostopbar.c')
-rw-r--r--endless/eostopbar.c27
1 files changed, 0 insertions, 27 deletions
diff --git a/endless/eostopbar.c b/endless/eostopbar.c
index 81edee6..6975e39 100644
--- a/endless/eostopbar.c
+++ b/endless/eostopbar.c
@@ -51,32 +51,6 @@ enum {
static guint top_bar_signals[LAST_SIGNAL] = { 0 };
-static gboolean
-eos_top_bar_button_press_event (GtkWidget *widget,
- GdkEventButton *event)
-{
- GtkWidget *window;
-
- /* ignore right clicks */
- if (gdk_event_triggers_context_menu ((GdkEvent *) event))
- return FALSE;
-
- /* ignore double clicks, etc */
- if (event->type != GDK_BUTTON_PRESS)
- return FALSE;
-
- window = gtk_widget_get_toplevel (widget);
- if (!window)
- return FALSE;
-
- gtk_window_begin_move_drag (GTK_WINDOW (window),
- event->button,
- event->x_root,
- event->y_root,
- event->time);
- return TRUE;
-}
-
static void
eos_top_bar_get_preferred_height (GtkWidget *widget,
int *minimum,
@@ -118,7 +92,6 @@ eos_top_bar_class_init (EosTopBarClass *klass)
GObjectClass *object_class = G_OBJECT_CLASS (klass);
GtkWidgetClass *widget_class = GTK_WIDGET_CLASS (klass);
- widget_class->button_press_event = eos_top_bar_button_press_event;
widget_class->get_preferred_height = eos_top_bar_get_preferred_height;
widget_class->draw = eos_top_bar_draw;