chore: more concise Debug output for WindowId
This commit is contained in:
parent
0086d7153b
commit
df7c496a5d
2 changed files with 8 additions and 1 deletions
|
|
@ -67,7 +67,7 @@ impl Drop for Window {
|
|||
///
|
||||
/// Whenever you receive an event specific to a window, this event contains a `WindowId` which you
|
||||
/// can then compare to the ids of your windows.
|
||||
#[derive(Debug, Copy, Clone, PartialEq, Eq, PartialOrd, Ord, Hash)]
|
||||
#[derive(Copy, Clone, PartialEq, Eq, PartialOrd, Ord, Hash)]
|
||||
pub struct WindowId(pub(crate) platform_impl::WindowId);
|
||||
|
||||
impl WindowId {
|
||||
|
|
@ -86,6 +86,12 @@ impl WindowId {
|
|||
}
|
||||
}
|
||||
|
||||
impl fmt::Debug for WindowId {
|
||||
fn fmt(&self, fmtr: &mut fmt::Formatter<'_>) -> fmt::Result {
|
||||
self.0.fmt(fmtr)
|
||||
}
|
||||
}
|
||||
|
||||
impl From<WindowId> for u64 {
|
||||
fn from(window_id: WindowId) -> Self {
|
||||
window_id.0.into()
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue