mirror of
				https://github.com/zadam/trilium.git
				synced 2025-10-31 18:36:30 +01:00 
			
		
		
		
	feat(native-buttons): set arbitrary offset for traffic light
This commit is contained in:
		| @@ -63,8 +63,12 @@ function initTitleBarButtons() { | |||||||
|         const symbolColor = style.getPropertyValue("--native-titlebar-foreground"); |         const symbolColor = style.getPropertyValue("--native-titlebar-foreground"); | ||||||
|  |  | ||||||
|         if (color && symbolColor) { |         if (color && symbolColor) { | ||||||
|             currentWindow.setTitleBarOverlay({ color, symbolColor }); |             // FIXME, do this only on windows | ||||||
|  |             // currentWindow.setTitleBarOverlay({ color, symbolColor }); | ||||||
|         } |         } | ||||||
|  |  | ||||||
|  |         // FIXME: call only on darwin | ||||||
|  |         currentWindow.setWindowButtonPosition({ x: 20, y: 20 }); | ||||||
|     } |     } | ||||||
|      |      | ||||||
|     // Update the native title bar buttons. |     // Update the native title bar buttons. | ||||||
|   | |||||||
| @@ -115,7 +115,7 @@ async function createMainWindow(app: App) { | |||||||
| function getWindowExtraOpts() { | function getWindowExtraOpts() { | ||||||
|     const extraOpts: Partial<BrowserWindowConstructorOptions> = {}; |     const extraOpts: Partial<BrowserWindowConstructorOptions> = {}; | ||||||
|     if (!optionService.getOptionBool('nativeTitleBarVisible')) { |     if (!optionService.getOptionBool('nativeTitleBarVisible')) { | ||||||
|         extraOpts.titleBarStyle = "hidden"; |         extraOpts.titleBarStyle = (process.platform !== "darwin" ? "hidden" : "hiddenInset"); | ||||||
|         extraOpts.titleBarOverlay = true; |         extraOpts.titleBarOverlay = true; | ||||||
|     } |     } | ||||||
|  |  | ||||||
|   | |||||||
		Reference in New Issue
	
	Block a user