mirror of
https://github.com/pinnacle-comp/pinnacle.git
synced 2024-12-26 21:58:10 +01:00
Add WindowId::reset
for testing
This commit is contained in:
parent
b763adcb5a
commit
c1f0aea060
1 changed files with 6 additions and 0 deletions
|
@ -27,6 +27,12 @@ impl WindowId {
|
|||
Self(WINDOW_ID_COUNTER.fetch_add(1, Ordering::Relaxed))
|
||||
}
|
||||
|
||||
/// Reset the static window id counter to 0.
|
||||
/// FIXME: remove statics
|
||||
pub fn reset() {
|
||||
WINDOW_ID_COUNTER.store(0, Ordering::Relaxed);
|
||||
}
|
||||
|
||||
/// Get the window that has this WindowId.
|
||||
pub fn window(&self, pinnacle: &Pinnacle) -> Option<WindowElement> {
|
||||
pinnacle
|
||||
|
|
Loading…
Reference in a new issue