Skip to content

Commit

Permalink
2007-05-17 Matthew Allum <[email protected]>
Browse files Browse the repository at this point in the history
        * src/matchbox-keyboard-ui.c:
        Actually select for structure notify events on root to know
        when a resize has happened.


git-svn-id: https://svn.o-hand.com/repos/matchbox/trunk/matchbox-keyboard@1544 b067294f-1dea-0310-9683-c47a78595994
  • Loading branch information
mallum committed May 17, 2007
1 parent ec478a4 commit 7c0ecf1
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 2 deletions.
6 changes: 6 additions & 0 deletions ChangeLog
Original file line number Diff line number Diff line change
@@ -1,3 +1,9 @@
2007-05-17 Matthew Allum <[email protected]>

* src/matchbox-keyboard-ui.c:
Actually select for structure notify events on root to know
when a resize has happened.

2007-05-15 Matthew Allum <[email protected]>

* src/matchbox-keyboard-ui.c:
Expand Down
10 changes: 8 additions & 2 deletions src/matchbox-keyboard-ui.c
Original file line number Diff line number Diff line change
Expand Up @@ -147,6 +147,8 @@ update_display_size(MBKeyboardUI *ui)
{
XWindowAttributes winattr;

MARK();

XGetWindowAttributes(ui->xdpy, ui->xwin_root, &winattr);

/* XXX should actually trap an X error here */
Expand All @@ -163,6 +165,8 @@ update_display_size(MBKeyboardUI *ui)
&& ui->dpy_orientation != ui->valid_orientation)
mb_kbd_ui_hide (ui);

DBG("#### Orientation know '%i'", ui->dpy_orientation);

return;
}

Expand Down Expand Up @@ -693,7 +697,8 @@ mb_kbd_ui_resources_create(MBKeyboardUI *ui)
CWOverrideRedirect|CWEventMask,
&win_attr);

XSelectInput (ui->xdpy, ui->xwin_root, SubstructureNotifyMask);
XSelectInput (ui->xdpy, ui->xwin_root,
SubstructureNotifyMask|StructureNotifyMask);

wm_hints = XAllocWMHints();

Expand Down Expand Up @@ -1148,7 +1153,8 @@ mb_kbd_ui_event_loop(MBKeyboardUI *ui)
xev.xconfigure.width,
xev.xconfigure.height);
}

if (xev.xconfigure.window == ui->xwin_root)
update_display_size(ui);
break;
case MappingNotify:
fakekey_reload_keysyms(ui->fakekey);
Expand Down

0 comments on commit 7c0ecf1

Please sign in to comment.