-
-
Notifications
You must be signed in to change notification settings - Fork 284
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* Add WindowExtUnix * Add change file
- Loading branch information
Ngo Iok Ui (Wu Yu Wei)
authored
Apr 23, 2021
1 parent
1ef1f58
commit 004e298
Showing
5 changed files
with
33 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
--- | ||
"wry": minor | ||
--- | ||
|
||
Add platform module and WindowExtUnix trait on Linux | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
// Copyright 2019-2021 Tauri Programme within The Commons Conservancy | ||
// SPDX-License-Identifier: Apache-2.0 | ||
// SPDX-License-Identifier: MIT | ||
|
||
pub mod unix { | ||
use crate::application::window::{Window, WindowRequest}; | ||
|
||
pub trait WindowExtUnix { | ||
fn skip_taskbar(&self); | ||
} | ||
|
||
impl WindowExtUnix for Window { | ||
fn skip_taskbar(&self) { | ||
if let Err(e) = self | ||
.window_requests_tx | ||
.send((self.window_id, WindowRequest::SkipTaskbar)) | ||
{ | ||
log::warn!("Fail to send skip taskbar request: {}", e); | ||
} | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters