mirror of
https://git.sr.ht/~eliasnaur/gio
synced 2026-07-06 09:55:40 +00:00
ui: rename Config.Val to Pixels
Signed-off-by: Elias Naur <mail@eliasnaur.com>
This commit is contained in:
+4
-5
@@ -4,7 +4,6 @@ package layout
|
||||
|
||||
import (
|
||||
"image"
|
||||
"math"
|
||||
|
||||
"gioui.org/ui"
|
||||
)
|
||||
@@ -101,10 +100,10 @@ func (in *Insets) Begin(c *ui.Config, ops *ui.Ops, cs Constraints) Constraints {
|
||||
if in.begun {
|
||||
panic("must End before Begin")
|
||||
}
|
||||
in.top = int(math.Round(float64(c.Val(in.Top))))
|
||||
in.right = int(math.Round(float64(c.Val(in.Right))))
|
||||
in.bottom = int(math.Round(float64(c.Val(in.Bottom))))
|
||||
in.left = int(math.Round(float64(c.Val(in.Left))))
|
||||
in.top = c.Pixels(in.Top)
|
||||
in.right = c.Pixels(in.Right)
|
||||
in.bottom = c.Pixels(in.Bottom)
|
||||
in.left = c.Pixels(in.Left)
|
||||
in.begun = true
|
||||
in.ops = ops
|
||||
in.cs = cs
|
||||
|
||||
Reference in New Issue
Block a user