bitsdojo_window
bitsdojo_window copied to clipboard
Can't hide system buttons on macOS Catalina 10.15.6
After I changed the swift code by following the instruction, it stil displayed the three system buttons on the left top side of the window.The system is macOS Catalina 10.15.6
Have the same bug on Big Sure 11.2.3
I guess this plugins was designed this way,
You can edit following file and add code bellow to hide system icon,
bitsdojo_window/bitsdojo_window_macos/macos/Classes/BitsdojoWindow.swift
if hasCustomFrame {
localStyle.insert(.fullSizeContentView)
self.styleMask = localStyle;
self.titlebarAppearsTransparent = true
self.titleVisibility = .hidden
self.styleMask.remove(.closable)
self.styleMask.remove(.fullScreen)
self.styleMask.remove(.miniaturizable)
self.styleMask.remove(.resizable)
self.isOpaque = false
self.isMovable = false
}
@bitsdojo Could you please help to confirm this issue?
System buttons are not hidden in the current version but support for doing this from Dart is coming with the next update.
[13 Aug 2021] System buttons are not hidden in the current version but support for doing this from Dart is coming with the next update.
Is this still a 'work in progress'?
In my multi platform desktop application I found the following settings in:
{project_root}/macos/Runner/Base.lproj/MainMenu.xib
<window title="APP_NAME" allowsToolTipsWhenApplicationIsInactive="NO" autorecalculatesKeyViewLoop="NO" releasedWhenClosed="NO" animationBehavior="default" id="QvC-M9-y7g" customClass="MainFlutterWindow" customModule="Runner" customModuleProvider="target">
<windowStyleMask key="styleMask" titled="YES" closable="YES" miniaturizable="YES" resizable="YES"/>
<rect key="contentRect" x="335" y="390" width="800" height="600"/>
<rect key="screenRect" x="0.0" y="0.0" width="2560" height="1577"/>
<view key="contentView" wantsLayer="YES" id="EiT-Mj-1SZ">
<rect key="frame" x="0.0" y="0.0" width="800" height="600"/>
<autoresizingMask key="autoresizingMask"/>
</view>
</window>
Changing the closable
, miniaturizable
and resizable
properties to NO removed the system buttons.
@bitsdojo I believe this issue should be closed.
I am on OSX 13.0.1, with Flutter:
Flutter 3.7.7 • channel stable • https://github.com/flutter/flutter.git Framework • revision 2ad6cd72c0 (2 weeks ago) • 2023-03-08 09:41:59 -0800 Engine • revision 1837b5be5f Tools • Dart 2.19.4 • DevTools 2.20.1
@juanheyns That's makes it so you can't resize, or minify the window -- it doesn't just remove the buttons.