Sha256: 12ddd2b461afb05274f1de0747a4dbbc098a5d578f899a3b41e93c729b834b28

Contents?: true

Size: 846 Bytes

Versions: 101

Compression:

Stored size: 846 Bytes

Contents

require "gtk-sharp, Version=2.12.0.0, Culture=neutral, PublicKeyToken=35e10195dab3c99f"
require "glade-sharp, Version=2.12.0.0, Culture=neutral, PublicKeyToken=35e10195dab3c99f"

RealGtk = Gtk
RealGtk::Application.init

Gtk = Class.new do
  class Window
    def initialize(title = "")
      @ob = RealGtk::Window.new(title)
    end
    
    def add(widget)
      @ob.add(widget.ob)
    end
    
    def show_all
      @ob.show_all
    end
  end
  
  class Button
    def initialize(title = nil)
      @ob = RealGtk::Button.new(title)
    end
    
    def ob
      return @ob
    end
    
    def signal_connect(signal, &block)
      @ob.send(signal) do |sender, e|
        block.call
      end
    end
  end
  
  def self.main
    RealGtk::Application.run
  end
  
  def self.main_quit
    RealGtk::Application.quit
  end
end

require "test_2.rb"

Version data entries

101 entries across 101 versions & 1 rubygems

Version Path
knjrbfw-0.0.72 lib/knj/ironruby-gtk2/tests/test_ironruby_window.rb
knjrbfw-0.0.71 lib/knj/ironruby-gtk2/tests/test_ironruby_window.rb
knjrbfw-0.0.70 lib/knj/ironruby-gtk2/tests/test_ironruby_window.rb
knjrbfw-0.0.69 lib/knj/ironruby-gtk2/tests/test_ironruby_window.rb
knjrbfw-0.0.68 lib/knj/ironruby-gtk2/tests/test_ironruby_window.rb
knjrbfw-0.0.67 lib/knj/ironruby-gtk2/tests/test_ironruby_window.rb
knjrbfw-0.0.66 lib/knj/ironruby-gtk2/tests/test_ironruby_window.rb
knjrbfw-0.0.65 lib/knj/ironruby-gtk2/tests/test_ironruby_window.rb
knjrbfw-0.0.64 lib/knj/ironruby-gtk2/tests/test_ironruby_window.rb
knjrbfw-0.0.63 lib/knj/ironruby-gtk2/tests/test_ironruby_window.rb
knjrbfw-0.0.62 lib/knj/ironruby-gtk2/tests/test_ironruby_window.rb
knjrbfw-0.0.59 lib/knj/ironruby-gtk2/tests/test_ironruby_window.rb
knjrbfw-0.0.58 lib/knj/ironruby-gtk2/tests/test_ironruby_window.rb
knjrbfw-0.0.57 lib/knj/ironruby-gtk2/tests/test_ironruby_window.rb
knjrbfw-0.0.55 lib/knj/ironruby-gtk2/tests/test_ironruby_window.rb
knjrbfw-0.0.54 lib/knj/ironruby-gtk2/tests/test_ironruby_window.rb
knjrbfw-0.0.53 lib/knj/ironruby-gtk2/tests/test_ironruby_window.rb
knjrbfw-0.0.52 lib/knj/ironruby-gtk2/tests/test_ironruby_window.rb
knjrbfw-0.0.51 lib/knj/ironruby-gtk2/tests/test_ironruby_window.rb
knjrbfw-0.0.50 lib/knj/ironruby-gtk2/tests/test_ironruby_window.rb