Removed the generic preferredSize() from the Windows backend; all controls are now expected to provide their own on Windows (this is really the only way to go there). NOW I can rework the whole control nonsense...
This commit is contained in:
parent
cafc9daa72
commit
1f6bcde3d9
|
@ -31,10 +31,7 @@ func newControl(class C.LPWSTR, style C.DWORD, extstyle C.DWORD) *controlbase {
|
|||
C.ShowWindow(c.hwnd, C.SW_HIDE)
|
||||
}
|
||||
c.fallocate = baseallocate(c)
|
||||
c.fpreferredSize = func(d *sizing) (int, int) {
|
||||
// TODO
|
||||
return 75, 23
|
||||
}
|
||||
// don't specify c.fpreferredSize; it is custom on ALL controls
|
||||
c.fcommitResize = func(a *allocation, d *sizing) {
|
||||
C.moveWindow(c.hwnd, C.int(a.x), C.int(a.y), C.int(a.width), C.int(a.height))
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue