summaryrefslogtreecommitdiff
path: root/redo/common_windows.go
diff options
context:
space:
mode:
authorPietro Gagliardi <[email protected]>2014-07-17 15:10:26 -0400
committerPietro Gagliardi <[email protected]>2014-07-17 15:10:26 -0400
commit19f7b2946a6198862f860b1f7c5798c0d66b8fc1 (patch)
treedcad78ffbde01eb9d4b952e15a33f6308eea8559 /redo/common_windows.go
parent1a712d4064a646f366612139269d075db78d56cd (diff)
Laid down the framework for control events on Windows. The only problem left is that we need to use functions from comctl32.dll, so it's time to bring that blob of code back.
Diffstat (limited to 'redo/common_windows.go')
-rw-r--r--redo/common_windows.go10
1 files changed, 10 insertions, 0 deletions
diff --git a/redo/common_windows.go b/redo/common_windows.go
index d2cae60..30c0d75 100644
--- a/redo/common_windows.go
+++ b/redo/common_windows.go
@@ -46,3 +46,13 @@ func storelpParam(hwnd uintptr, lParam t_LPARAM) {
cs = (*s_CREATESTRUCTW)(unsafe.Pointer(uintptr(lParam)))
f_SetWindowLongPtrW(hwnd, c_GWLP_USERDATA, cs.lpCreateParams)
}
+
+func (w t_WPARAM) HIWORD() uint16 {
+ u := uintptr(w) & 0xFFFF0000
+ return uint16(u >> 16)
+}
+
+func (w t_WPARAM) LOWORD() uint16 {
+ u := uintptr(w) & 0x0000FFFF
+ return uint16(u)
+}