1
0
mirror of https://github.com/emilk/egui.git synced 2026-08-31 13:50:04 -04:00

MacOS: Support fullsize content (no titlebar, but window controls) (#2049)

Co-authored-by: Emil Ernerfeldt <emil.ernerfeldt@gmail.com>
This commit is contained in:
Paul Rouget
2022-09-16 20:31:21 +08:00
committed by GitHub
parent 0605bcfca7
commit c4117066cf
3 changed files with 22 additions and 0 deletions

View File

@@ -223,6 +223,13 @@ pub struct NativeOptions {
/// Default: `false`.
pub fullscreen: bool,
/// On Mac: the window doesn't have a titlebar, but floating window buttons.
///
/// See [winit's documentation][with_fullsize_content_view] for information on Mac-specific options.
///
/// [with_fullsize_content_view]: https://docs.rs/winit/latest/x86_64-apple-darwin/winit/platform/macos/trait.WindowBuilderExtMacOS.html#tymethod.with_fullsize_content_view
pub fullsize_content: bool,
/// On Windows: enable drag and drop support. Drag and drop can
/// not be disabled on other platforms.
///
@@ -361,6 +368,7 @@ impl Default for NativeOptions {
maximized: false,
decorated: true,
fullscreen: false,
fullsize_content: false,
drag_and_drop_support: true,
icon_data: None,
initial_window_pos: None,