mirror of
https://github.com/darlinghq/darling-cocotron.git
synced 2025-02-13 08:15:14 +00:00
Add stubs and other things for The Unarchiver
This commit is contained in:
parent
abcd7e4f5e
commit
04280a8d90
@ -116,6 +116,8 @@ set(AppKit_sources
|
||||
NSFontMetric.m
|
||||
NSPoofAnimation.m
|
||||
NSErrors.m
|
||||
NSPopover.m
|
||||
NSRunningApplication.m
|
||||
|
||||
nib.subproj/NSButtonImageSource.m
|
||||
nib.subproj/NSNibBindingConnector.m
|
||||
|
@ -55,6 +55,8 @@ NSString * const NSApplicationWillTerminateNotification=@"NSApplicationWillTermi
|
||||
|
||||
NSString * const NSApplicationDidChangeScreenParametersNotification=@"NSApplicationDidChangeScreenParametersNotification";
|
||||
|
||||
const NSAppKitVersion NSAppKitVersionNumber = 1504; // macOS 10.12
|
||||
|
||||
@interface NSDocumentController(forward)
|
||||
-(void)_updateRecentDocumentsMenu;
|
||||
@end
|
||||
@ -352,7 +354,7 @@ id NSApp=nil;
|
||||
[_applicationIconImage release];
|
||||
_applicationIconImage=image;
|
||||
|
||||
[image setName: @"NSApplicationIcon"];
|
||||
[image setName: NSImageNameApplicationIcon];
|
||||
}
|
||||
|
||||
-(void)setWindowsMenu:(NSMenu *)menu {
|
||||
|
@ -19,6 +19,8 @@ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLI
|
||||
#import <Foundation/NSKeyedArchiver.h>
|
||||
#import <AppKit/NSRaise.h>
|
||||
|
||||
NSImageName const NSImageNameApplicationIcon = @"NSApplicationIcon";
|
||||
|
||||
// Private class used so the context knows the flipped status of a locked image
|
||||
// 10.4 does something like that - probably for more than just getting the flippiness - 10.6 uses some special NSSnapshotBitmapGraphicsContext
|
||||
@interface NSImageCacheView : NSView {
|
||||
|
@ -12,6 +12,7 @@ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLI
|
||||
|
||||
NSString *const NSPasteboardTypeString = @"NSStringPboardType";
|
||||
NSString *const NSPasteboardTypePDF = @"NSPDFPboardType";
|
||||
NSString *const NSPasteboardTypePNG = @"NSPDFPboardType";
|
||||
NSString *const NSPasteboardTypeTIFF = @"NSTIFFPboardType";
|
||||
NSString *const NSPasteboardTypeRTF = @"NSRTFPboardType";
|
||||
NSString *const NSPasteboardTypeRTFD = @"NSRTFDPboardType";
|
||||
|
20
AppKit/NSPopover.m
Normal file
20
AppKit/NSPopover.m
Normal file
@ -0,0 +1,20 @@
|
||||
#import <Foundation/NSObject.h>
|
||||
|
||||
// DUMMY
|
||||
|
||||
@interface NSPopover : NSObject
|
||||
@end
|
||||
|
||||
@implementation NSPopover
|
||||
- (NSMethodSignature *)methodSignatureForSelector:(SEL)aSelector
|
||||
{
|
||||
return [NSMethodSignature signatureWithObjCTypes: "v@:"];
|
||||
}
|
||||
|
||||
- (void)forwardInvocation:(NSInvocation *)anInvocation
|
||||
{
|
||||
NSLog(@"Stub called: %@ in %@", NSStringFromSelector([anInvocation selector]), [self class]);
|
||||
}
|
||||
@end
|
||||
|
||||
|
19
AppKit/NSRunningApplication.m
Normal file
19
AppKit/NSRunningApplication.m
Normal file
@ -0,0 +1,19 @@
|
||||
#import <Foundation/NSObject.h>
|
||||
|
||||
// DUMMY
|
||||
|
||||
@interface NSRunningApplication : NSObject
|
||||
@end
|
||||
|
||||
@implementation NSRunningApplication
|
||||
+ (NSMethodSignature *)methodSignatureForSelector:(SEL)aSelector
|
||||
{
|
||||
return [NSMethodSignature signatureWithObjCTypes: "v@:"];
|
||||
}
|
||||
|
||||
+ (void)forwardInvocation:(NSInvocation *)anInvocation
|
||||
{
|
||||
NSLog(@"Stub called: %@ in %@", NSStringFromSelector([anInvocation selector]), self);
|
||||
}
|
||||
@end
|
||||
|
@ -49,6 +49,7 @@ NSString * const NSWindowWillCloseNotification=@"NSWindowWillCloseNotification";
|
||||
NSString * const NSWindowWillMoveNotification=@"NSWindowWillMoveNotification";
|
||||
NSString * const NSWindowWillStartLiveResizeNotification=@"NSWindowWillStartLiveResizeNotification";
|
||||
NSString * const NSWindowDidEndLiveResizeNotification=@"NSWindowDidEndLiveResizeNotification";
|
||||
NSString * const NSWindowWillBeginSheetNotification=@"NSWindowWillBeginSheetNotification";
|
||||
|
||||
NSString * const NSWindowWillAnimateNotification=@"NSWindowWillAnimateNotification";
|
||||
NSString * const NSWindowAnimatingNotification=@"NSWindowAnimatingNotification";
|
||||
|
@ -36,6 +36,8 @@ APPKIT_EXPORT NSString *const NSApplicationWillTerminateNotification;
|
||||
APPKIT_EXPORT NSString *const NSApplicationDidChangeScreenParametersNotification;
|
||||
|
||||
APPKIT_EXPORT id NSApp;
|
||||
typedef double NSAppKitVersion;
|
||||
APPKIT_EXPORT const NSAppKitVersion NSAppKitVersionNumber;
|
||||
|
||||
typedef id NSModalSession;
|
||||
|
||||
|
@ -123,3 +123,9 @@ typedef enum {
|
||||
@interface NSBundle (NSImage)
|
||||
- (NSString *)pathForImageResource:(NSString *)name;
|
||||
@end
|
||||
|
||||
typedef NSString* NSImageName;
|
||||
|
||||
APPKIT_EXPORT NSImageName const NSImageNameApplicationIcon;
|
||||
// TODO: A ton of other defined image names
|
||||
|
||||
|
@ -12,6 +12,7 @@ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLI
|
||||
// New Pasteboard Types (added in 10.6) and interchangeable with the old pasteboard types in Cocotron
|
||||
APPKIT_EXPORT NSString *const NSPasteboardTypeString;
|
||||
APPKIT_EXPORT NSString *const NSPasteboardTypePDF;
|
||||
APPKIT_EXPORT NSString *const NSPasteboardTypePNG;
|
||||
APPKIT_EXPORT NSString *const NSPasteboardTypeTIFF;
|
||||
APPKIT_EXPORT NSString *const NSPasteboardTypeRTF;
|
||||
APPKIT_EXPORT NSString *const NSPasteboardTypeRTFD;
|
||||
|
@ -100,6 +100,7 @@ APPKIT_EXPORT NSString *const NSWindowDidUpdateNotification;
|
||||
APPKIT_EXPORT NSString *const NSWindowWillCloseNotification;
|
||||
APPKIT_EXPORT NSString *const NSWindowWillStartLiveResizeNotification;
|
||||
APPKIT_EXPORT NSString *const NSWindowDidEndLiveResizeNotification;
|
||||
APPKIT_EXPORT NSString *const NSWindowWillBeginSheetNotification;
|
||||
|
||||
@interface NSWindow : NSResponder {
|
||||
NSRect _frame;
|
||||
|
Loading…
x
Reference in New Issue
Block a user