wxMGL update

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@11613 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Václav Slavík
2001-09-15 22:13:20 +00:00
parent 7d9f12f3b9
commit 72fa862b04
2 changed files with 8 additions and 10 deletions

View File

@@ -74,8 +74,6 @@ bool wxYield()
while (wxEventLoop::GetActive()->Pending())
wxEventLoop::GetActive()->Dispatch();
}
else
MGL_wmUpdateDC(g_winMng); // FIXME_MGL -- temporary hack, please remove
/* it's necessary to call ProcessIdle() to update the frames sizes which
might have been changed (it also will update other things set from
@@ -209,12 +207,8 @@ bool wxApp::SendIdleEvents(wxWindow* win)
win->GetEventHandler()->ProcessEvent(event);
#if 0 // FIXME_MGL - what the hell it is?
win->OnInternalIdle();
if ( event.MoreRequested() )
needMore = TRUE;
#endif
wxNode* node = win->GetChildren().First();
while (node)

View File

@@ -166,7 +166,7 @@ void wxDestroyMGL_WM()
static void wxWindowPainter(window_t *wnd, MGLDC *dc)
{
wxWindowMGL *w = (wxWindow*) wnd->userData;
if (w)
if (w && !(w->GetStyle() & wxTRANSPARENT_WINDOW))
{
MGLDevCtx ctx(dc);
w->HandlePaint(&ctx);
@@ -396,7 +396,6 @@ static ibool wxWindowKeybHandler(window_t *wnd, event_t *e)
event.m_scanCode = 0; // not used by wx at all
event.m_x = where.x;
event.m_y = where.y;
wxLogDebug("key pressed, x=%i y=%i", event.m_x, event.m_y); // FIXME_MGL -remove
event.m_shiftDown = e->modifiers & EVT_SHIFTKEY;
event.m_controlDown = e->modifiers & EVT_CTRLSTATE;
event.m_altDown = e->modifiers & EVT_LEFTALT;
@@ -538,10 +537,17 @@ bool wxWindowMGL::Create(wxWindow *parent,
w = WidthDefault(size.x);
h = HeightDefault(size.y);
long mgl_style = 0;
if ( !(style & wxNO_FULL_REPAINT_ON_RESIZE) )
mgl_style |= MGL_WM_FULL_REPAINT_ON_RESIZE;
if ( style & wxSTAY_ON_TOP )
mgl_style |= MGL_WM_ALWAYS_ON_TOP;
m_wnd = MGL_wmCreateWindow(g_winMng,
parent ? parent->GetHandle() : NULL,
x, y, w, h);
MGL_wmSetWindowFlags(m_wnd, mgl_style);
MGL_wmSetWindowUserData(m_wnd, (void*) this);
MGL_wmSetWindowPainter(m_wnd, wxWindowPainter);
MGL_wmShowWindow(m_wnd, m_isShown);
@@ -676,8 +682,6 @@ bool wxWindowMGL::SetCursor(const wxCursor& cursor)
else
MGL_wmSetWindowCursor(m_wnd, *wxSTANDARD_CURSOR->GetMGLCursor());
// FIXME_MGL -- should it set children's cursor or not?!
return TRUE;
}