Skip to content

Instantly share code, notes, and snippets.

@mumez
Created December 22, 2014 07:15
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save mumez/98a55fba675e417425c8 to your computer and use it in GitHub Desktop.
Save mumez/98a55fba675e417425c8 to your computer and use it in GitHub Desktop.
#import <Foundation/Foundation.h>
#import "SUYScratchPresentationSpace.h"
@interface ScratchIPhonePresentationSpace (PyonTalk)
//Smalltalk actions
- (IBAction) keyBackspace: (id) sender;
- (IBAction) keyEnter: (id) sender;
- (IBAction) keyEscape: (id) sender;
- (IBAction) doIt: (id) sender;
- (IBAction) printIt: (id) sender;
- (IBAction) inspectIt: (id) sender;
//Smalltalk actions
@end
#import <Foundation/Foundation.h>
#import "SUYScratchPresentationSpace.h"
#import "SUYScratchPresentationSpace+PyonTalk.h"
@implementation ScratchIPhonePresentationSpace (PyonTalk)
//Smalltalk actions
#pragma mark - Smalltalk actions
- (IBAction) keyBackspace: (id) sender {
[self pushCharacter: [NSString stringWithFormat:@"%c", 8]];
}
- (IBAction) keyEnter: (id) sender {
[self pushCharacter: [NSString stringWithFormat:@"%c", 13]];
}
- (IBAction) keyEscape: (id) sender {
[self pushCharacter: [NSString stringWithFormat:@"%c", 27]];
}
- (IBAction) doIt: (id) sender {
[self pushCharacter: [NSString stringWithFormat:@"%c", 24]];
}
- (IBAction) printIt: (id) sender {
[self pushCharacter: [NSString stringWithFormat:@"%c", 25]];
}
- (IBAction) inspectIt: (id) sender {
[self pushCharacter: [NSString stringWithFormat:@"%c", 26]];
}
//Smalltalk actions override
#pragma mark - Smalltalk hack
- (void)radioButtonSetController:(GSRadioButtonSetController *)controller didSelectButtonAtIndex:(NSUInteger)selectedIndex
{
//[self changedViewModeIndex:selectedIndex];
[self setViewModeIndex:selectedIndex];
}
@end
@mumez
Copy link
Author

mumez commented Dec 22, 2014

An Obj-C extension for uncovering Smalltalk under Pyonkee.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment