Skip to content

Commit 2f20fdf

Browse files
authored
fix(core): compile error for 32bit targets (#9361)
* fix(core): compile error for 32bit targets * clippy giving me trust issues
1 parent 6251645 commit 2f20fdf

2 files changed

Lines changed: 9 additions & 3 deletions

File tree

.changes/fix-runtime-wry-32bit.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
---
2+
tauri-runtime-wry: patch:bug
3+
---
4+
5+
Fixes an issue causing compilation to fail for i686 and armv7 32-bit targets.

core/tauri-runtime-wry/src/lib.rs

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1525,12 +1525,12 @@ impl<T: UserEvent> WindowDispatch<T> for WryWindowDispatcher<T> {
15251525
window_getter!(self, WindowMessage::IsFocused)
15261526
}
15271527

1528-
/// Gets the windows current decoration state.
1528+
/// Gets the window's current decoration state.
15291529
fn is_decorated(&self) -> Result<bool> {
15301530
window_getter!(self, WindowMessage::IsDecorated)
15311531
}
15321532

1533-
/// Gets the windows current resizable state.
1533+
/// Gets the window's current resizable state.
15341534
fn is_resizable(&self) -> Result<bool> {
15351535
window_getter!(self, WindowMessage::IsResizable)
15361536
}
@@ -3517,7 +3517,8 @@ fn create_window<T: UserEvent, F: Fn(RawWindow) + Send + 'static>(
35173517
let monitor_pos = m.position();
35183518
let monitor_size = m.size();
35193519

3520-
let window_position = window_position.to_logical(m.scale_factor());
3520+
// type annotations required for 32bit targets.
3521+
let window_position: LogicalPosition<i32> = window_position.to_logical(m.scale_factor());
35213522

35223523
monitor_pos.x <= window_position.x
35233524
&& window_position.x <= monitor_pos.x + monitor_size.width as i32

0 commit comments

Comments
 (0)