From c01de80583445618f2752f7aa8859645ac1a4591 Mon Sep 17 00:00:00 2001 From: cutealien Date: Fri, 4 Aug 2023 10:22:58 +0000 Subject: [PATCH] Merging r6511 through r6520 from branch releases/1.8 to trunk Note: Due to OSX always failing merge OSX it's rather applying a second patch from Ryan Schmidt from bugreport #462 to trunk (Not sure why svn merging always fails for OSX. Probably related to MacOSX files getting moved in the past. Was that done without svn move commands? I guess that can't be fixed anymore now) git-svn-id: svn://svn.code.sf.net/p/irrlicht/code/trunk@6521 dfc29bdd-3216-0410-991c-e03cc46cb475 --- source/Irrlicht/CIrrDeviceOSX.h | 2 +- source/Irrlicht/CIrrDeviceOSX.mm | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/source/Irrlicht/CIrrDeviceOSX.h b/source/Irrlicht/CIrrDeviceOSX.h index 08ea424..fa9a95e 100644 --- a/source/Irrlicht/CIrrDeviceOSX.h +++ b/source/Irrlicht/CIrrDeviceOSX.h @@ -22,7 +22,7 @@ namespace irr class CIrrDeviceMacOSX; } -@interface CIrrDelegateOSX : NSObject +@interface CIrrDelegateOSX : NSObject - (id)initWithDevice:(irr::CIrrDeviceMacOSX*)device; - (void)terminate:(id)sender; diff --git a/source/Irrlicht/CIrrDeviceOSX.mm b/source/Irrlicht/CIrrDeviceOSX.mm index 0defe11..06a6d1e 100644 --- a/source/Irrlicht/CIrrDeviceOSX.mm +++ b/source/Irrlicht/CIrrDeviceOSX.mm @@ -564,7 +564,7 @@ CIrrDeviceMacOSX::CIrrDeviceMacOSX(const SIrrlichtCreationParameters& param) { [[NSAutoreleasePool alloc] init]; [[NSApplication sharedApplication] activateIgnoringOtherApps:YES]; - [NSApp setDelegate:(id)[[[CIrrDelegateOSX alloc] initWithDevice:this] autorelease]]; + [[NSApplication sharedApplication] setDelegate:[[[CIrrDelegateOSX alloc] initWithDevice:this] autorelease]]; // Create menu @@ -685,7 +685,7 @@ bool CIrrDeviceMacOSX::createWindow() { if (Window) { - [Window setDelegate:(id)[NSApp delegate]]; + [Window setDelegate:(CIrrDelegateOSX *)[NSApp delegate]]; [Window setAcceptsMouseMovedEvents:TRUE]; [Window setIsVisible:TRUE]; [Window makeKeyAndOrderFront:nil];