mirror of
https://git.sr.ht/~eliasnaur/gio
synced 2026-07-05 09:25:38 +00:00
app: (android,ios) fix build
Signed-off-by: Elias Naur <mail@eliasnaur.com>
This commit is contained in:
+4
-4
@@ -217,10 +217,10 @@ func onFocusChange(env *C.JNIEnv, class C.jclass, view C.jlong, focus C.jboolean
|
|||||||
func onWindowInsets(env *C.JNIEnv, class C.jclass, view C.jlong, top, right, bottom, left C.jint) {
|
func onWindowInsets(env *C.JNIEnv, class C.jclass, view C.jlong, top, right, bottom, left C.jint) {
|
||||||
w := views[view]
|
w := views[view]
|
||||||
w.insets = Insets{
|
w.insets = Insets{
|
||||||
Top: ui.Px(float32(top)),
|
Top: unit.Px(float32(top)),
|
||||||
Right: ui.Px(float32(right)),
|
Right: unit.Px(float32(right)),
|
||||||
Bottom: ui.Px(float32(bottom)),
|
Bottom: unit.Px(float32(bottom)),
|
||||||
Left: ui.Px(float32(left)),
|
Left: unit.Px(float32(left)),
|
||||||
}
|
}
|
||||||
if w.stage >= StageRunning {
|
if w.stage >= StageRunning {
|
||||||
w.draw(true)
|
w.draw(true)
|
||||||
|
|||||||
+4
-4
@@ -86,10 +86,10 @@ func onDraw(view C.CFTypeRef, dpi, sdpi, width, height C.CGFloat, sync C.int, to
|
|||||||
Y: int(height + .5),
|
Y: int(height + .5),
|
||||||
},
|
},
|
||||||
Insets: Insets{
|
Insets: Insets{
|
||||||
Top: ui.Px(float32(top)),
|
Top: unit.Px(float32(top)),
|
||||||
Right: ui.Px(float32(right)),
|
Right: unit.Px(float32(right)),
|
||||||
Bottom: ui.Px(float32(bottom)),
|
Bottom: unit.Px(float32(bottom)),
|
||||||
Left: ui.Px(float32(left)),
|
Left: unit.Px(float32(left)),
|
||||||
},
|
},
|
||||||
Config: Config{
|
Config: Config{
|
||||||
pxPerDp: float32(dpi) * inchPrDp,
|
pxPerDp: float32(dpi) * inchPrDp,
|
||||||
|
|||||||
Reference in New Issue
Block a user