summaryrefslogtreecommitdiff
path: root/sysdata_windows.go
diff options
context:
space:
mode:
Diffstat (limited to 'sysdata_windows.go')
-rw-r--r--sysdata_windows.go22
1 files changed, 22 insertions, 0 deletions
diff --git a/sysdata_windows.go b/sysdata_windows.go
index da1c6b8..fd0d180 100644
--- a/sysdata_windows.go
+++ b/sysdata_windows.go
@@ -174,3 +174,25 @@ func (s *sysData) setText(text string) error {
}
return nil
}
+
+func (s *sysData) setRect(x int, y int, width int, height int) error {
+ ret := make(chan uiret)
+ defer close(ret)
+ uitask <- &uimsg{
+ call: _moveWindow,
+ p: []uintptr{
+ uintptr(s.hwnd),
+ uintptr(x),
+ uintptr(y),
+ uintptr(width),
+ uintptr(height),
+ uintptr(_TRUE),
+ },
+ ret: ret,
+ }
+ r := <-ret
+ if r.ret == 0 { // failure
+ return r.err
+ }
+ return nil
+}