Implemented tab stopping.
This commit is contained in:
parent
2146ac2af3
commit
5523cdb22a
|
@ -23,6 +23,8 @@ type tab struct {
|
||||||
func newTab() Tab {
|
func newTab() Tab {
|
||||||
hwnd := C.newControl(C.xWC_TABCONTROL,
|
hwnd := C.newControl(C.xWC_TABCONTROL,
|
||||||
C.TCS_TOOLTIPS | C.WS_TABSTOP,
|
C.TCS_TOOLTIPS | C.WS_TABSTOP,
|
||||||
|
// this is needed to have the tab contents be tab stop
|
||||||
|
// TODO this seems to override WS_TABSTOP
|
||||||
C.WS_EX_CONTROLPARENT)
|
C.WS_EX_CONTROLPARENT)
|
||||||
t := &tab{
|
t := &tab{
|
||||||
_hwnd: hwnd,
|
_hwnd: hwnd,
|
||||||
|
|
|
@ -7,6 +7,7 @@ void uimsgloop(void)
|
||||||
{
|
{
|
||||||
MSG msg;
|
MSG msg;
|
||||||
int res;
|
int res;
|
||||||
|
HWND active;
|
||||||
|
|
||||||
for (;;) {
|
for (;;) {
|
||||||
SetLastError(0);
|
SetLastError(0);
|
||||||
|
@ -15,7 +16,9 @@ void uimsgloop(void)
|
||||||
xpanic("error calling GetMessage()", GetLastError());
|
xpanic("error calling GetMessage()", GetLastError());
|
||||||
if (res == 0) /* WM_QUIT */
|
if (res == 0) /* WM_QUIT */
|
||||||
break;
|
break;
|
||||||
/* TODO IsDialogMessage() */
|
active = GetActiveWindow();
|
||||||
|
if (active != NULL && IsDialogMessageW(active, &msg) != 0)
|
||||||
|
continue;
|
||||||
TranslateMessage(&msg);
|
TranslateMessage(&msg);
|
||||||
DispatchMessageW(&msg);
|
DispatchMessageW(&msg);
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue