Implemented RepaintAll() on Windows.

This commit is contained in:
Pietro Gagliardi 2014-06-09 22:26:37 -04:00
parent f8d46b6bdb
commit caeff5bb88
3 changed files with 20 additions and 0 deletions

View File

@ -698,6 +698,9 @@ func areaWndProc(hwnd _HWND, uMsg uint32, wParam _WPARAM, lParam _LPARAM) _LRESU
adjustAreaScrollbars(s)
repaintArea(s) // this calls for an update
return 0
case msgRepaintAll:
repaintArea(s)
return 0
default:
return defWindowProc(hwnd, uMsg, wParam, lParam)
}

View File

@ -669,3 +669,19 @@ func (s *sysData) setAreaSize(width int, height int) {
}
<-ret
}
func (s *sysData) repaintAll() {
ret := make(chan uiret)
defer close(ret)
uitask <- &uimsg{
call: _sendMessage,
p: []uintptr{
uintptr(s.hwnd),
uintptr(msgRepaintAll),
uintptr(0),
uintptr(0),
},
ret: ret,
}
<-ret
}

View File

@ -39,6 +39,7 @@ const (
msgRequested = _WM_APP + iota + 1 // + 1 just to be safe
msgQuit
msgSetAreaSize
msgRepaintAll
)
var (