]> git.tdb.fi Git - libs/gui.git/blobdiff - source/graphics/windows/window.cpp
Paint the window in WM_PAINT
[libs/gui.git] / source / graphics / windows / window.cpp
index 046894f7e8815c2a90864cead486c3ac1c2163d7..cc364723d292b109dcce847122f6096881befe1d 100644 (file)
@@ -199,8 +199,18 @@ bool Window::event(const Event &evnt)
                        unsigned width = update_rect.right-update_rect.left;
                        unsigned height = update_rect.bottom-update_rect.top;
                        signal_expose.emit(update_rect.left, update_rect.top, width, height, evnt);
+
+                       PAINTSTRUCT paint;
+                       if(BeginPaint(priv->window, &paint))
+                               EndPaint(priv->window, &paint);
                }
                break;
+       case WM_SETFOCUS:
+               signal_got_focus.emit();
+               break;
+       case WM_KILLFOCUS:
+               signal_lost_focus.emit();
+               break;
        default:
                return false;
        }