Only build, but don't run tests in MSRV CI (#2558)
* Only build, but don't run tests in MSRV CI Since the MSRV of development dependencies can easily be bumped without it affecting the MSRV of the published version of `winit` * Run clippy on stable Rust instead of MSRV Rust clippy inspects the `rust-version` field, and only suggests changes that conform to that.
This commit is contained in:
parent
bdcbd7d1f9
commit
ce6c6e8c95
18 changed files with 72 additions and 58 deletions
|
|
@ -196,7 +196,7 @@ impl Handler {
|
|||
if let Some(ref mut callback) = *self.callback.lock().unwrap() {
|
||||
match wrapper {
|
||||
EventWrapper::StaticEvent(event) => {
|
||||
callback.handle_nonuser_event(event, &mut *self.control_flow.lock().unwrap())
|
||||
callback.handle_nonuser_event(event, &mut self.control_flow.lock().unwrap())
|
||||
}
|
||||
EventWrapper::EventProxy(proxy) => self.handle_proxy(proxy, callback),
|
||||
}
|
||||
|
|
@ -205,7 +205,7 @@ impl Handler {
|
|||
|
||||
fn handle_user_events(&self) {
|
||||
if let Some(ref mut callback) = *self.callback.lock().unwrap() {
|
||||
callback.handle_user_events(&mut *self.control_flow.lock().unwrap());
|
||||
callback.handle_user_events(&mut self.control_flow.lock().unwrap());
|
||||
}
|
||||
}
|
||||
|
||||
|
|
@ -226,7 +226,7 @@ impl Handler {
|
|||
},
|
||||
};
|
||||
|
||||
callback.handle_nonuser_event(event, &mut *self.control_flow.lock().unwrap());
|
||||
callback.handle_nonuser_event(event, &mut self.control_flow.lock().unwrap());
|
||||
|
||||
let physical_size = *new_inner_size;
|
||||
let logical_size = physical_size.to_logical(scale_factor);
|
||||
|
|
|
|||
|
|
@ -19,14 +19,14 @@ pub fn initialize() {
|
|||
let process_name = NSProcessInfo::process_info().process_name();
|
||||
|
||||
// About menu item
|
||||
let about_item_title = ns_string!("About ").concat(&*process_name);
|
||||
let about_item_title = ns_string!("About ").concat(&process_name);
|
||||
let about_item = menu_item(&about_item_title, sel!(orderFrontStandardAboutPanel:), None);
|
||||
|
||||
// Seperator menu item
|
||||
let sep_first = NSMenuItem::separatorItem();
|
||||
|
||||
// Hide application menu item
|
||||
let hide_item_title = ns_string!("Hide ").concat(&*process_name);
|
||||
let hide_item_title = ns_string!("Hide ").concat(&process_name);
|
||||
let hide_item = menu_item(
|
||||
&hide_item_title,
|
||||
sel!(hide:),
|
||||
|
|
@ -57,7 +57,7 @@ pub fn initialize() {
|
|||
let sep = NSMenuItem::separatorItem();
|
||||
|
||||
// Quit application menu item
|
||||
let quit_item_title = ns_string!("Quit ").concat(&*process_name);
|
||||
let quit_item_title = ns_string!("Quit ").concat(&process_name);
|
||||
let quit_item = menu_item(
|
||||
&quit_item_title,
|
||||
sel!(terminate:),
|
||||
|
|
|
|||
|
|
@ -74,7 +74,7 @@ impl Deref for Window {
|
|||
type Target = WinitWindow;
|
||||
#[inline]
|
||||
fn deref(&self) -> &Self::Target {
|
||||
&*self.window
|
||||
&self.window
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -45,7 +45,7 @@ pub(crate) fn set_style_mask_async(window: &NSWindow, mask: NSWindowStyleMask) {
|
|||
// TODO(madsmtm): Remove this 'static hack!
|
||||
let window = unsafe { MainThreadSafe(mem::transmute::<&NSWindow, &'static NSWindow>(window)) };
|
||||
Queue::main().exec_async(move || {
|
||||
set_style_mask(*window, mask);
|
||||
set_style_mask(&window, mask);
|
||||
});
|
||||
}
|
||||
pub(crate) fn set_style_mask_sync(window: &NSWindow, mask: NSWindowStyleMask) {
|
||||
|
|
@ -54,7 +54,7 @@ pub(crate) fn set_style_mask_sync(window: &NSWindow, mask: NSWindowStyleMask) {
|
|||
} else {
|
||||
let window = MainThreadSafe(window);
|
||||
Queue::main().exec_sync(move || {
|
||||
set_style_mask(*window, mask);
|
||||
set_style_mask(&window, mask);
|
||||
})
|
||||
}
|
||||
}
|
||||
|
|
@ -111,13 +111,13 @@ pub(crate) fn toggle_full_screen_async(
|
|||
let required =
|
||||
NSWindowStyleMask::NSTitledWindowMask | NSWindowStyleMask::NSResizableWindowMask;
|
||||
if !curr_mask.contains(required) {
|
||||
set_style_mask(*window, required);
|
||||
set_style_mask(&window, required);
|
||||
if let Some(shared_state) = shared_state.upgrade() {
|
||||
let mut shared_state_lock = SharedStateMutexGuard::new(
|
||||
shared_state.lock().unwrap(),
|
||||
"toggle_full_screen_callback",
|
||||
);
|
||||
(*shared_state_lock).saved_style = Some(curr_mask);
|
||||
shared_state_lock.saved_style = Some(curr_mask);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -734,7 +734,7 @@ impl WinitWindow {
|
|||
shared_state_lock.fullscreen = None;
|
||||
|
||||
let maximized = shared_state_lock.maximized;
|
||||
let mask = self.saved_style(&mut *shared_state_lock);
|
||||
let mask = self.saved_style(&mut shared_state_lock);
|
||||
|
||||
drop(shared_state_lock);
|
||||
|
||||
|
|
@ -1191,7 +1191,7 @@ impl WindowExtMacOS for WinitWindow {
|
|||
|
||||
true
|
||||
} else {
|
||||
let new_mask = self.saved_style(&mut *shared_state_lock);
|
||||
let new_mask = self.saved_style(&mut shared_state_lock);
|
||||
self.set_style_mask_async(new_mask);
|
||||
shared_state_lock.is_simple_fullscreen = false;
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue