Permalink
Browse files

update cocoa examples

  • Loading branch information...
1 parent 23325e1 commit ec2b5bc380331be874421396ee6c8a7931dbab94 @jckarter committed Sep 22, 2012
@@ -28,7 +28,7 @@ record ExampleController = newClass("ExampleController", NSObject,
["performAdd:", IBAction((self, sender) => { _performMath(self, add); })],
["performSubtract:", IBAction((self, sender) => { _performMath(self, subtract); })],
["performMultiply:", IBAction((self, sender) => { _performMath(self, multiply); })],
- ["performDivide:", IBAction((self, sender) => { _performMath(self, divide); })],
+ ["performDivide:", IBAction((self, sender) => { _performMath(self, quotient); })],
["performClear:", IBAction((self, sender) => {
self^.leftField.setStringValue(NSSTR(""));
self^.rightField.setStringValue(NSSTR(""));
@@ -1,6 +1,6 @@
import cocoa.*;
import cocoa.qtkit.*;
-import printer.(println);
+import printer.(error, println);
import unix.(sleep);
main(args) {
@@ -19,7 +19,7 @@ main(args) {
movie.play();
var duration = movie.duration();
- sleep(UInt(duration.timeValue / duration.timeScale + 1));
+ sleep(UInt(duration.timeValue \ duration.timeScale + 1));
println("Done");
}
}
@@ -43,7 +43,7 @@ record ExampleController = newClass("ExampleController", NSObject,
case (2)
_performMath(self, multiply);
case (3)
- _performMath(self, divide);
+ _performMath(self, quotient);
else {}
})],
),

0 comments on commit ec2b5bc

Please sign in to comment.