Class: Todoable::UI::Window

Inherits:
Gtk::Window
  • Object
show all
Defined in:
lib/todoable/ui/gtk/window.rb

Instance Method Summary collapse

Constructor Details

#initialize(base_uri) ⇒ Window

Returns a new instance of Window



21
22
23
24
25
26
27
28
29
30
31
32
# File 'lib/todoable/ui/gtk/window.rb', line 21

def initialize base_uri
  super :toplevel

  # Define window properties
  set_title "Todoable"
  set_default_size 500, 200
  set_window_position :center
  signal_connect("destroy") { Gtk.main_quit }

  # Populate window with internal UI elements
  add(MainPanel.new base_uri)
end