Skip to content

Instantly share code, notes, and snippets.

@zenom
Created February 21, 2015 14:38
Show Gist options
  • Save zenom/38534fb697d9ede78bee to your computer and use it in GitHub Desktop.
Save zenom/38534fb697d9ede78bee to your computer and use it in GitHub Desktop.
Loading Window
@preferencesWindowController = PreferencesWindow.alloc.initWithWindowNibName('PreferencesWindow')
@preferencesWindowController.window
class PreferencesWindow < NSWindowController
extend IB
outlet :text_field, NSTextField
outlet :title, NSTextField
outlet :button, NSButton
outlet :connect, NSButton
def windowDidLoad
puts "Window Did Load"
end
def button_pressed(sender)
title.text = text_field.text
text_field.text = ''
end
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment