diff --git a/src/tools/ecode/ecode.cpp b/src/tools/ecode/ecode.cpp index b1adcac3e..80ab97c11 100644 --- a/src/tools/ecode/ecode.cpp +++ b/src/tools/ecode/ecode.cpp @@ -3296,8 +3296,9 @@ void App::init( const LogLevel& logLevel, std::string file, const Float& pidelDe } #endif #if EE_PLATFORM == EE_PLATFORM_MACOS - macOS_CreateApplicationMenus(); - macOS_EnableScrollMomentum(); + macOS_createApplicationMenus(); + macOS_enableScrollMomentum(); + macOS_removeTitleBarSeparator( mWindow->getWindowHandler() ); mThreadPool->run( [this]() { // Checks if the default shell path contains more paths diff --git a/src/tools/ecode/macos/macos.hpp b/src/tools/ecode/macos/macos.hpp index f0cdf9206..d933e7043 100644 --- a/src/tools/ecode/macos/macos.hpp +++ b/src/tools/ecode/macos/macos.hpp @@ -5,9 +5,14 @@ extern "C" { #endif -void macOS_CreateApplicationMenus(); +void macOS_createApplicationMenus(); -void macOS_EnableScrollMomentum(); +void macOS_enableScrollMomentum(); + +void macOS_removeTitleBarSeparator( void* nsWindow ); + +void macOS_setTitleBarBackgroundColor( void* nsWindow, float red, float green, float blue, + float alpha ); #ifdef __cplusplus } diff --git a/src/tools/ecode/macos/macos.m b/src/tools/ecode/macos/macos.m index 98dde2b7a..a56b99490 100644 --- a/src/tools/ecode/macos/macos.m +++ b/src/tools/ecode/macos/macos.m @@ -7,9 +7,7 @@ @end // Recreates the menubar replacing the default SDL menubar -void -macOS_CreateApplicationMenus(void) -{ +void macOS_createApplicationMenus() { NSString *appName; NSString *title; NSMenu *appleMenu; @@ -64,6 +62,11 @@ macOS_CreateApplicationMenus(void) [NSApp setWindowsMenu:windowMenu]; } -void macOS_EnableScrollMomentum() { +void macOS_enableScrollMomentum() { [[NSUserDefaults standardUserDefaults] setBool:YES forKey:@"AppleMomentumScrollSupported"]; } + +void macOS_removeTitleBarSeparator( void* window ) { + NSWindow* nsWindow = window; + [nsWindow setTitlebarSeparatorStyle:NSTitlebarSeparatorStyleNone]; +}