comparison dep/animia/src/win/quartz.mm @ 182:c413e475f496

dep/animia: various stylistic changes
author Paper <mrpapersonic@gmail.com>
date Mon, 04 Dec 2023 13:19:54 -0500
parents 44c5e6dd9488
children
comparison
equal deleted inserted replaced
181:d26cd2c00270 182:c413e475f496
1 /* We actually DON'T need Objective-C for most of this file.
2 * GetWindowTitle() is the only function that really needs it.
3 * (and even then, we can use the C bindings for it...)
4 *
5 * However, being able to use the Foundation classes makes things
6 * so, so, so much easier, and so I've decided to make this file
7 * in Objective-C++.
8 */
1 #include "animia/win/quartz.h" 9 #include "animia/win/quartz.h"
2 #include "animia.h" 10 #include "animia.h"
3 11
4 #import <Foundation/Foundation.h> 12 #import <Foundation/Foundation.h>
5 #import <CoreGraphics/CoreGraphics.h> 13 #import <CoreGraphics/CoreGraphics.h>
22 30
23 result = [string UTF8String]; 31 result = [string UTF8String];
24 return true; 32 return true;
25 } 33 }
26 34
35 /* This is really the only a*/
27 static bool GetWindowTitle(unsigned int wid, std::string& result) { 36 static bool GetWindowTitle(unsigned int wid, std::string& result) {
28 NSWindow* window = [NSApp windowWithWindowNumber: wid]; 37 NSWindow* window = [NSApp windowWithWindowNumber: wid];
29 if (!window) 38 if (!window)
30 return false; 39 return false;
31 40