summaryrefslogtreecommitdiff
path: root/plugins
diff options
context:
space:
mode:
authorGravatar Alexey Yakovenko <wakeroid@gmail.com>2010-05-02 14:18:23 +0200
committerGravatar Alexey Yakovenko <wakeroid@gmail.com>2010-05-02 14:18:23 +0200
commit8aa4799f644cefb27afbec1e09958c8f58712c3c (patch)
treedae604d8c674f25e55ab729eb8d265524bd71274 /plugins
parent2e53930ee9f06102ee39bf95b21775a563679d31 (diff)
gtk warning fix
Diffstat (limited to 'plugins')
-rw-r--r--plugins/gtkui/ddbequalizer.c2
-rw-r--r--plugins/gtkui/ddbequalizer.vala10
2 files changed, 6 insertions, 6 deletions
diff --git a/plugins/gtkui/ddbequalizer.c b/plugins/gtkui/ddbequalizer.c
index 1bc3c3df..fac3a1f0 100644
--- a/plugins/gtkui/ddbequalizer.c
+++ b/plugins/gtkui/ddbequalizer.c
@@ -136,13 +136,13 @@ static void ddb_equalizer_real_realize (GtkWidget* base) {
GdkWindow* _tmp1_;
self = (DdbEqualizer*) base;
GTK_WIDGET_SET_FLAGS ((GtkWidget*) self, GTK_REALIZED);
- gtk_widget_add_events ((GtkWidget*) self, (gint) (((GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK) | GDK_LEAVE_NOTIFY_MASK) | GDK_POINTER_MOTION_MASK));
attrs = (memset (&_tmp0_, 0, sizeof (GdkWindowAttr)), _tmp0_.window_type = GDK_WINDOW_CHILD, _tmp0_.wclass = GDK_INPUT_OUTPUT, _tmp0_.event_mask = gtk_widget_get_events ((GtkWidget*) self) | GDK_EXPOSURE_MASK, _tmp0_);
((GtkWidget*) self)->window = (_tmp1_ = gdk_window_new (gtk_widget_get_parent_window ((GtkWidget*) self), &attrs, 0), _g_object_unref0 (((GtkWidget*) self)->window), _tmp1_);
gdk_window_move_resize (((GtkWidget*) self)->window, ((GtkWidget*) self)->allocation.x, ((GtkWidget*) self)->allocation.y, ((GtkWidget*) self)->allocation.width, ((GtkWidget*) self)->allocation.height);
gdk_window_set_user_data (((GtkWidget*) self)->window, self);
gtk_widget_set_style ((GtkWidget*) self, gtk_style_attach (gtk_widget_get_style ((GtkWidget*) self), ((GtkWidget*) self)->window));
gtk_style_set_background (gtk_widget_get_style ((GtkWidget*) self), ((GtkWidget*) self)->window, GTK_STATE_NORMAL);
+ gtk_widget_add_events ((GtkWidget*) self, (gint) (((GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK) | GDK_LEAVE_NOTIFY_MASK) | GDK_POINTER_MOTION_MASK));
ddb_equalizer_send_configure (self);
}
diff --git a/plugins/gtkui/ddbequalizer.vala b/plugins/gtkui/ddbequalizer.vala
index 84766a3f..a0be8aee 100644
--- a/plugins/gtkui/ddbequalizer.vala
+++ b/plugins/gtkui/ddbequalizer.vala
@@ -75,11 +75,6 @@ namespace Ddb {
public override void realize () {
set_flags (Gtk.WidgetFlags.REALIZED);
- add_events (Gdk.EventMask.BUTTON_PRESS_MASK
- | Gdk.EventMask.BUTTON_RELEASE_MASK
- | Gdk.EventMask.LEAVE_NOTIFY_MASK
- | Gdk.EventMask.POINTER_MOTION_MASK);
-
var attrs = Gdk.WindowAttr () {
window_type = Gdk.WindowType.CHILD,
wclass = Gdk.WindowClass.INPUT_OUTPUT,
@@ -92,6 +87,11 @@ namespace Ddb {
this.window.set_user_data (this);
this.style = this.style.attach (this.window);
this.style.set_background (this.window, Gtk.StateType.NORMAL);
+ add_events (Gdk.EventMask.BUTTON_PRESS_MASK
+ | Gdk.EventMask.BUTTON_RELEASE_MASK
+ | Gdk.EventMask.LEAVE_NOTIFY_MASK
+ | Gdk.EventMask.POINTER_MOTION_MASK);
+
send_configure ();
}