Sha256: acab8a2ab825d46934aedb6c5f09028fd36e709b80b54e2c3e4efb8b11c48b47
Contents?: true
Size: 759 Bytes
Versions: 4
Compression:
Stored size: 759 Bytes
Contents
class Gtk::Menu def initialize if Gtk.takeob @ob = Gtk.takeob Gtk.takeob = nil else splitted = self.class.to_s.split("::") classname = splitted[splitted.length - 1] class_spawn = Gtk.evalob("org.gnome.gtk." + classname) @ob = class_spawn.new end end def popup(arg1, arg2, event_button, event_time) @ob.popup end def prepend(object) @ob.prepend(object.ob) end end class Gtk::MenuItem def initialize(title) if Gtk.takeob @ob = Gtk.takeob Gtk.takeob = nil else splitted = self.class.to_s.split("::") classname = splitted[splitted.length - 1] class_spawn = Gtk.evalob("org.gnome.gtk." + classname) if title @ob = class_spawn.new(title) else @ob = class_spawn.new end end end end
Version data entries
4 entries across 4 versions & 1 rubygems
Version | Path |
---|---|
knjrbfw-0.0.8 | lib/knj/jruby-gtk2/menu.rb |
knjrbfw-0.0.7 | lib/knj/jruby-gtk2/menu.rb |
knjrbfw-0.0.4 | lib/knj/jruby-gtk2/menu.rb |
knjrbfw-0.0.3 | lib/knj/jruby-gtk2/menu.rb |