disappearing text in child window

new topic     » topic index » view thread      » older message » newer message

Below is demo stub for minor problem I'm encountering.
It has two windows, one is child of first, and child has text written to it on activate.

But some few seconds after activation, I regularly hear some hard disk activity,
and the text disappears.

What's up with that?

I know I can make the text reappear "onPaint" the child window,
but that still shows a momentary flicker of the window, which I don't like,
and I'm wondering WHY does the text disappear in the first place,
and what causes the window to flicker when I'm not doing anything
programmatically?

Dan (demo follows)

--  code generated by Win32Lib IDE v0.20.1 
 
  
include Win32lib.ew 
without warning 
 
-------------------------------------------------------------------------------- 
--  Window Window1 
constant Window1 = createEx( Window, "Window1", 0, Default, Default,  
400, 300, 0, 0 ) 
--------------------------------------------------------- 
-------------------------------------------------------------------------------- 
--  Window Window2 
sequence IDEFlags 
IDEFlags = classDefaults(Window, { {1,  
   {WS_SYSMENU,WS_MINIMIZEBOX,WS_MAXIMIZEBOX}},{2, {WS_EX_DLGMODALFRAME}} } ) 
constant Window2 = createEx( Window, "Window 2", Window1,  
    Default, Default, 331, 195,  
   {WS_CHILD, WS_CLIPSIBLINGS, WS_BORDER, WS_DLGFRAME,  
    WS_THICKFRAME, WS_CAPTION, WS_SYSMENU, WS_MINIMIZEBOX,  
WS_MAXIMIZEBOX}, {WS_EX_DLGMODALFRAME} ) 
moveZOrder( Window2, HWND_TOP) 
--------------------------------------------------------- 
-------------------------------------------------------------------------------- 
procedure Window1_onActivate (integer self, integer event, sequence params)--params is () 
   openWindow(Window2, Normal) 
end procedure 
setHandler( Window1, w32HActivate, routine_id("Window1_onActivate")) 
-------------------------------------------------------------------------------- 
procedure Window2_onActivate (integer self, integer event, sequence params)--params is () 
  wPuts(Window2, "here is some text") 
end procedure 
setHandler( Window2, w32HActivate, routine_id("Window2_onActivate")) 
 
 
WinMain( Window1,Normal ) 
new topic     » topic index » view thread      » older message » newer message

Search



Quick Links

User menu

Not signed in.

Misc Menu