mirror of
https://github.com/rust-windowing/winit.git
synced 2026-09-02 14:50:04 -04:00
macOS: Fix overridden fullscreen selectors (#2546)
This commit is contained in:
@@ -221,9 +221,9 @@ declare_class!(
|
|||||||
}
|
}
|
||||||
|
|
||||||
/// Invoked when before enter fullscreen
|
/// Invoked when before enter fullscreen
|
||||||
#[sel(windowWillEnterFullscreen:)]
|
#[sel(windowWillEnterFullScreen:)]
|
||||||
fn window_will_enter_fullscreen(&self, _: Option<&Object>) {
|
fn window_will_enter_fullscreen(&self, _: Option<&Object>) {
|
||||||
trace_scope!("windowWillEnterFullscreen:");
|
trace_scope!("windowWillEnterFullScreen:");
|
||||||
|
|
||||||
let mut shared_state = self
|
let mut shared_state = self
|
||||||
.window
|
.window
|
||||||
@@ -287,9 +287,9 @@ declare_class!(
|
|||||||
}
|
}
|
||||||
|
|
||||||
/// Invoked when entered fullscreen
|
/// Invoked when entered fullscreen
|
||||||
#[sel(windowDidEnterFullscreen:)]
|
#[sel(windowDidEnterFullScreen:)]
|
||||||
fn window_did_enter_fullscreen(&mut self, _: Option<&Object>) {
|
fn window_did_enter_fullscreen(&mut self, _: Option<&Object>) {
|
||||||
trace_scope!("windowDidEnterFullscreen:");
|
trace_scope!("windowDidEnterFullScreen:");
|
||||||
*self.initial_fullscreen = false;
|
*self.initial_fullscreen = false;
|
||||||
let mut shared_state = self.window.lock_shared_state("window_did_enter_fullscreen");
|
let mut shared_state = self.window.lock_shared_state("window_did_enter_fullscreen");
|
||||||
shared_state.in_fullscreen_transition = false;
|
shared_state.in_fullscreen_transition = false;
|
||||||
@@ -301,9 +301,9 @@ declare_class!(
|
|||||||
}
|
}
|
||||||
|
|
||||||
/// Invoked when exited fullscreen
|
/// Invoked when exited fullscreen
|
||||||
#[sel(windowDidExitFullscreen:)]
|
#[sel(windowDidExitFullScreen:)]
|
||||||
fn window_did_exit_fullscreen(&self, _: Option<&Object>) {
|
fn window_did_exit_fullscreen(&self, _: Option<&Object>) {
|
||||||
trace_scope!("windowDidExitFullscreen:");
|
trace_scope!("windowDidExitFullScreen:");
|
||||||
|
|
||||||
self.window.restore_state_from_fullscreen();
|
self.window.restore_state_from_fullscreen();
|
||||||
let mut shared_state = self.window.lock_shared_state("window_did_exit_fullscreen");
|
let mut shared_state = self.window.lock_shared_state("window_did_exit_fullscreen");
|
||||||
@@ -331,9 +331,9 @@ declare_class!(
|
|||||||
/// due to being in the midst of handling some other animation or user gesture.
|
/// due to being in the midst of handling some other animation or user gesture.
|
||||||
/// This method indicates that there was an error, and you should clean up any
|
/// This method indicates that there was an error, and you should clean up any
|
||||||
/// work you may have done to prepare to enter full-screen mode.
|
/// work you may have done to prepare to enter full-screen mode.
|
||||||
#[sel(windowDidFailToEnterFullscreen:)]
|
#[sel(windowDidFailToEnterFullScreen:)]
|
||||||
fn window_did_fail_to_enter_fullscreen(&self, _: Option<&Object>) {
|
fn window_did_fail_to_enter_fullscreen(&self, _: Option<&Object>) {
|
||||||
trace_scope!("windowDidFailToEnterFullscreen:");
|
trace_scope!("windowDidFailToEnterFullScreen:");
|
||||||
let mut shared_state = self
|
let mut shared_state = self
|
||||||
.window
|
.window
|
||||||
.lock_shared_state("window_did_fail_to_enter_fullscreen");
|
.lock_shared_state("window_did_fail_to_enter_fullscreen");
|
||||||
|
|||||||
Reference in New Issue
Block a user