X-Git-Url: https://git.distorted.org.uk/~mdw/sgt/puzzles/blobdiff_plain/7e04cb48eafb52a436f609dadbbce02761cbe5b3..5eae38d148446beb4fdc1aaed5fbd4a876f30e99:/macosx.m diff --git a/macosx.m b/macosx.m index 0f53c5b..52a70ef 100644 --- a/macosx.m +++ b/macosx.m @@ -49,6 +49,9 @@ * - Can we arrange for a pop-up menu from the Dock icon which * launches specific games, perhaps? * + * - Why are the right and bottom edges of the Pattern grid one + * pixel thinner than they should be? + * * Grotty implementation details that could probably be improved: * * - I am _utterly_ unconvinced that NSImageView was the right way @@ -117,39 +120,19 @@ NSMenu *typemenu; @interface DataMenuItem : NSMenuItem { void *payload; - int payload_free; } - (void)setPayload:(void *)d; -- (void)setPayloadFree:(BOOL)yesno; - (void *)getPayload; @end @implementation DataMenuItem -- (id)initWithTitle:(NSString *)title - action:(SEL)act - keyEquivalent:(NSString *)key -{ - payload = NULL; - payload_free = NO; - return [super initWithTitle:title action:act keyEquivalent:key]; -} - (void)setPayload:(void *)d { payload = d; } -- (void)setPayloadFree:(BOOL)yesno -{ - payload_free = yesno; -} - (void *)getPayload { return payload; } -- (void)dealloc -{ - if (payload_free) - sfree(payload); - [super dealloc]; -} @end /* ---------------------------------------------------------------------- @@ -485,7 +468,6 @@ struct frontend { [item setTarget:self]; [item setAction:@selector(presetGame:)]; [item setPayload:params]; - [item setPayloadFree:YES]; [typemenu insertItem:item atIndex:0]; }