Listen for MenuItems 'activate' signal rather than 'button_release_event'.
authorTilman Sauerbeck <tilman@code-monkey.de>
Sun, 12 Mar 2006 11:05:27 +0000 (11:05 +0000)
committerTilman Sauerbeck <tilman@code-monkey.de>
Sun, 12 Mar 2006 12:05:27 +0000 (12:05 +0000)
bin/snett

index 58896a5..1dce708 100755 (executable)
--- a/bin/snett
+++ b/bin/snett
@@ -37,7 +37,7 @@ class Gtk::MenuItem
        def set_callback(meth, args = [])
                args.unshift(meth)
 
-               signal_connect("button_release_event") do
+               signal_connect("activate") do
                        Snett::Snett.instance.xmms.send(*args)
                        false
                end
@@ -178,7 +178,7 @@ module Snett
                                item = Gtk::ImageMenuItem.new(text)
                                item.image = Gtk::Image.new(stock, Gtk::IconSize::MENU)
 
-                               item.signal_connect("button_release_event") do
+                               item.signal_connect("activate") do
                                        PlaylistDialog.new(sym).show_all
                                        false
                                end
@@ -194,7 +194,7 @@ module Snett
                        append(Gtk::SeparatorMenuItem.new)
 
                        item = Gtk::ImageMenuItem.new(Gtk::Stock::ABOUT)
-                       item.signal_connect("button_release_event") do
+                       item.signal_connect("activate") do
                                props = {
                                        "name" => PKG_NAME,
                                        "version" => VERSION,
@@ -209,7 +209,7 @@ module Snett
                        append(item)
 
                        item = Gtk::ImageMenuItem.new(Gtk::Stock::QUIT)
-                       item.signal_connect("button_release_event") do
+                       item.signal_connect("activate") do
                                Snett.instance.signal_emit("destroy")
                                false
                        end