Format .m files

This commit is contained in:
Chris Thrasher 2022-07-11 23:43:51 -06:00 committed by Lukas Dürrenberger
parent dd0f0ff4c6
commit 55a1a2a4c4
6 changed files with 53 additions and 66 deletions

View File

@ -22,7 +22,7 @@ endif()
# Run # Run
set(SOURCES "") set(SOURCES "")
foreach(FOLDER IN ITEMS examples include src test tools) foreach(FOLDER IN ITEMS examples include src test tools)
file(GLOB_RECURSE folder_files "${FOLDER}/*.h" "${FOLDER}/*.hpp" "${FOLDER}/*.inl" "${FOLDER}/*.cpp" "${FOLDER}/*.mm") file(GLOB_RECURSE folder_files "${FOLDER}/*.h" "${FOLDER}/*.hpp" "${FOLDER}/*.inl" "${FOLDER}/*.cpp" "${FOLDER}/*.mm" "${FOLDER}/*.m")
list(FILTER folder_files EXCLUDE REGEX "gl.h|vulkan.h|stb_perlin.h") # 3rd party code to exclude from formatting list(FILTER folder_files EXCLUDE REGEX "gl.h|vulkan.h|stb_perlin.h") # 3rd party code to exclude from formatting
list(APPEND SOURCES ${folder_files}) list(APPEND SOURCES ${folder_files})
endforeach() endforeach()

View File

@ -126,18 +126,14 @@
[appleMenu addItem:[NSMenuItem separatorItem]]; [appleMenu addItem:[NSMenuItem separatorItem]];
// PREFERENCES // PREFERENCES
[appleMenu addItemWithTitle:@"Preferences..." [appleMenu addItemWithTitle:@"Preferences..." action:nil keyEquivalent:@""];
action:nil
keyEquivalent:@""];
// SEPARATOR // SEPARATOR
[appleMenu addItem:[NSMenuItem separatorItem]]; [appleMenu addItem:[NSMenuItem separatorItem]];
// SERVICES // SERVICES
NSMenu* serviceMenu = [[[NSMenu alloc] initWithTitle:@""] autorelease]; NSMenu* serviceMenu = [[[NSMenu alloc] initWithTitle:@""] autorelease];
NSMenuItem* serviceItem = [appleMenu addItemWithTitle:@"Services" NSMenuItem* serviceItem = [appleMenu addItemWithTitle:@"Services" action:nil keyEquivalent:@""];
action:nil
keyEquivalent:@""];
[serviceItem setSubmenu:serviceMenu]; [serviceItem setSubmenu:serviceMenu];
[NSApp setServicesMenu:serviceMenu]; [NSApp setServicesMenu:serviceMenu];
@ -145,20 +141,17 @@
[appleMenu addItem:[NSMenuItem separatorItem]]; [appleMenu addItem:[NSMenuItem separatorItem]];
// HIDE // HIDE
[appleMenu addItemWithTitle:[@"Hide " stringByAppendingString:appName] [appleMenu addItemWithTitle:[@"Hide " stringByAppendingString:appName] action:@selector(hide:) keyEquivalent:@"h"];
action:@selector(hide:)
keyEquivalent:@"h"];
// HIDE OTHER // HIDE OTHER
NSMenuItem* hideOtherItem = [appleMenu addItemWithTitle:@"Hide Others" NSMenuItem* hideOtherItem = [appleMenu
addItemWithTitle:@"Hide Others"
action:@selector(hideOtherApplications:) action:@selector(hideOtherApplications:)
keyEquivalent:@"h"]; keyEquivalent:@"h"];
[hideOtherItem setKeyEquivalentModifierMask:(NSAlternateKeyMask | NSCommandKeyMask)]; [hideOtherItem setKeyEquivalentModifierMask:(NSAlternateKeyMask | NSCommandKeyMask)];
// SHOW ALL // SHOW ALL
[appleMenu addItemWithTitle:@"Show All" [appleMenu addItemWithTitle:@"Show All" action:@selector(unhideAllApplications:) keyEquivalent:@""];
action:@selector(unhideAllApplications:)
keyEquivalent:@""];
// SEPARATOR // SEPARATOR
[appleMenu addItem:[NSMenuItem separatorItem]]; [appleMenu addItem:[NSMenuItem separatorItem]];
@ -186,7 +179,8 @@
NSMenu* fileMenu = [[NSMenu alloc] initWithTitle:@"File"]; NSMenu* fileMenu = [[NSMenu alloc] initWithTitle:@"File"];
// CLOSE WINDOW // CLOSE WINDOW
NSMenuItem* closeItem = [[NSMenuItem alloc] initWithTitle:@"Close Window" NSMenuItem* closeItem = [[NSMenuItem alloc]
initWithTitle:@"Close Window"
action:@selector(performClose:) action:@selector(performClose:)
keyEquivalent:@"w"]; keyEquivalent:@"w"];
[fileMenu addItem:closeItem]; [fileMenu addItem:closeItem];
@ -211,24 +205,21 @@
NSMenu* windowMenu = [[NSMenu alloc] initWithTitle:@"Window"]; NSMenu* windowMenu = [[NSMenu alloc] initWithTitle:@"Window"];
// MINIMIZE // MINIMIZE
NSMenuItem* minimizeItem = [[NSMenuItem alloc] initWithTitle:@"Minimize" NSMenuItem* minimizeItem = [[NSMenuItem alloc]
initWithTitle:@"Minimize"
action:@selector(performMiniaturize:) action:@selector(performMiniaturize:)
keyEquivalent:@"m"]; keyEquivalent:@"m"];
[windowMenu addItem:minimizeItem]; [windowMenu addItem:minimizeItem];
[minimizeItem release]; [minimizeItem release];
// ZOOM // ZOOM
[windowMenu addItemWithTitle:@"Zoom" [windowMenu addItemWithTitle:@"Zoom" action:@selector(performZoom:) keyEquivalent:@""];
action:@selector(performZoom:)
keyEquivalent:@""];
// SEPARATOR // SEPARATOR
[windowMenu addItem:[NSMenuItem separatorItem]]; [windowMenu addItem:[NSMenuItem separatorItem]];
// BRING ALL TO FRONT // BRING ALL TO FRONT
[windowMenu addItemWithTitle:@"Bring All to Front" [windowMenu addItemWithTitle:@"Bring All to Front" action:@selector(bringAllToFront:) keyEquivalent:@""];
action:@selector(bringAllToFront:)
keyEquivalent:@""];
return windowMenu; return windowMenu;
} }
@ -278,5 +269,3 @@
@end @end

View File

@ -59,4 +59,3 @@
@end @end

View File

@ -37,4 +37,3 @@
} }
@end @end