Fix XEmbed compilation error on 32-bit platforms

This commit is contained in:
cyclopsian 2019-10-20 12:31:00 +00:00 committed by Christian Duerr
parent a75e949344
commit 8a26341457
2 changed files with 5 additions and 2 deletions

View File

@ -15,6 +15,7 @@ use std::convert::From;
#[cfg(not(any(target_os = "macos", windows)))]
use std::ffi::c_void;
use std::fmt;
use std::os::raw::c_ulong;
use glutin::dpi::{LogicalPosition, LogicalSize, PhysicalPosition, PhysicalSize};
use glutin::event_loop::EventLoop;
@ -392,7 +393,7 @@ impl Window {
}
#[cfg(not(any(target_os = "macos", windows)))]
fn x_embed_window(window: &GlutinWindow, parent_id: u64) {
fn x_embed_window(window: &GlutinWindow, parent_id: c_ulong) {
let (xlib_display, xlib_window) = match (window.xlib_display(), window.xlib_window()) {
(Some(display), Some(window)) => (display, window),
_ => return,

View File

@ -1,3 +1,5 @@
use std::os::raw::c_ulong;
use serde::Deserialize;
use crate::config::{
@ -45,7 +47,7 @@ pub struct WindowConfig {
/// XEmbed parent
#[serde(skip)]
pub embed: Option<u64>,
pub embed: Option<c_ulong>,
/// GTK theme variant
#[serde(deserialize_with = "option_explicit_none")]