diff --git a/v2/internal/ffenestri/ffenestri_darwin.c b/v2/internal/ffenestri/ffenestri_darwin.c index 0a775c75..45965f63 100644 --- a/v2/internal/ffenestri/ffenestri_darwin.c +++ b/v2/internal/ffenestri/ffenestri_darwin.c @@ -285,7 +285,7 @@ void* NewApplication(const char *title, int width, int height, int resizable, in result->fullSizeContent = 0; result->useToolBar = 0; result->hideToolbarSeparator = 0; - result->appearance = "NSAppearanceNameAqua"; + result->appearance = NULL; result->titlebarAppearsTransparent = 0; result->webviewIsTranparent = 0; @@ -857,9 +857,11 @@ void Run(void *applicationPointer, int argc, char **argv) { } // Set Appearance - msg(mainWindow, s("setAppearance:"), - msg(c("NSAppearance"), s("appearanceNamed:"), str(app->appearance)) - ); + if( app->appearance != NULL ) { + msg(mainWindow, s("setAppearance:"), + msg(c("NSAppearance"), s("appearanceNamed:"), str(app->appearance)) + ); + } // Finally call run diff --git a/v2/pkg/options/default.go b/v2/pkg/options/default.go index c0385929..94fe1afd 100644 --- a/v2/pkg/options/default.go +++ b/v2/pkg/options/default.go @@ -11,7 +11,7 @@ var Default = &App{ RGBA: 0xFFFFFFFF, Mac: &mac.Options{ TitleBar: mac.TitleBarDefault(), - Appearance: mac.NSAppearanceNameAqua, + Appearance: mac.DefaultAppearance, WebviewIsTransparent: false, }, } diff --git a/v2/pkg/options/mac/appearance.go b/v2/pkg/options/mac/appearance.go index 074dc147..934bb208 100644 --- a/v2/pkg/options/mac/appearance.go +++ b/v2/pkg/options/mac/appearance.go @@ -4,6 +4,8 @@ package mac type AppearanceType string const ( + // DefaultAppearance uses the default system value + DefaultAppearance AppearanceType = "" // NSAppearanceNameAqua - The standard light system appearance. NSAppearanceNameAqua AppearanceType = "NSAppearanceNameAqua" // NSAppearanceNameDarkAqua - The standard dark system appearance. diff --git a/v2/test/runtime/main.go b/v2/test/runtime/main.go index b8349520..55453291 100644 --- a/v2/test/runtime/main.go +++ b/v2/test/runtime/main.go @@ -26,8 +26,8 @@ func main() { Mac: &mac.Options{ // TitleBar: mac.TitleBarHidden(), // TitleBar: mac.TitleBarHiddenInset(), - TitleBar: mac.TitleBarDefault(), - Appearance: mac.NSAppearanceNameDarkAqua, + TitleBar: mac.TitleBarDefault(), + // Appearance: mac.NSAppearanceNameDarkAqua, }, })