head-management: add compositor-space-scaler-v1 extension
This commit is contained in:
parent
a12b259648
commit
a8ed4785af
11 changed files with 120 additions and 9 deletions
|
|
@ -15,7 +15,7 @@ impl Default for Scale {
|
|||
}
|
||||
|
||||
impl Scale {
|
||||
pub fn from_int(f: u32) -> Self {
|
||||
pub const fn from_int(f: u32) -> Self {
|
||||
Self(f.saturating_mul(BASE))
|
||||
}
|
||||
|
||||
|
|
@ -31,7 +31,7 @@ impl Scale {
|
|||
self.0.saturating_add(BASE - 1) / BASE
|
||||
}
|
||||
|
||||
pub fn from_wl(wl: u32) -> Self {
|
||||
pub const fn from_wl(wl: u32) -> Self {
|
||||
Self(wl)
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue