Skip to content

Commit

Permalink
fix butttonClicked typo
Browse files Browse the repository at this point in the history
  • Loading branch information
mogenson committed Jan 20, 2024
1 parent 66ba933 commit 8ad7985
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions LuaRepl.app/Contents/MacOS/main.lua
Original file line number Diff line number Diff line change
Expand Up @@ -97,15 +97,15 @@ local function makeAppMenu(app)
end

local function makeAppDelegate(app, textField, textView)
local butttonClicked = "buttonClicked:"
local buttonClicked = "buttonClicked:"

local AppDelegateClass = objc.newClass("AppDelegate")
objc.addMethod(AppDelegateClass, "applicationShouldTerminateAfterLastWindowClosed:", "B@:",
function(self, cmd)
print("quitting...")
return YES
end)
objc.addMethod(AppDelegateClass, butttonClicked, "v@:@",
objc.addMethod(AppDelegateClass, buttonClicked, "v@:@",
function(self, cmd, sender)
runRepl(textField, textView)
end)
Expand All @@ -114,7 +114,7 @@ local function makeAppDelegate(app, textField, textView)
appDelegate:autorelease()
app:setDelegate(appDelegate)

return objc.NSButton:buttonWithTitle_target_action(NSString("Eval"), appDelegate, butttonClicked)
return objc.NSButton:buttonWithTitle_target_action(NSString("Eval"), appDelegate, buttonClicked)
end


Expand Down

0 comments on commit 8ad7985

Please sign in to comment.