hi hi!
i have some problems with graphics, this is my coding
Boolean CMainForm::OnOpen(EventPtr pEvent, Boolean& bHandled) { RectangleType bounds; bounds.topLeft.x = 3; bounds.topLeft.y = 95; bounds.extent.x = 150; bounds.extent.y = 35; WinEraseRectangle(&bounds,0); WinDrawRectangleFrame(rectangleFrame,&bounds); bHandled = false; return true; }
my problem is, when running in OS4 emulator, the rectangle appears but when running in OS5 simulator the rectangle appears for 1 second and dissapears
is this a bug? or do i need to check for version of the OS and do something?
You need to also draw these graphics for a frmUpdateEvent, not just on frmOpen. Also, for the frmOpenEvent, you need to first call FrmDrawForm to setup your drawing window and draw the controls, then do your own drawing, then set handled to true to tell the system not to redraw things.
-- Ben Combee, Senior Software Engineer, palmOne, Inc. "Combee on Palm OS" weblog: http://palmos.combee.net/ Developer Forum Archives: http://news.palmos.com/read/all_forums/
-- For information on using the Palm Developer Forums, or to unsubscribe, please see http://www.palmos.com/dev/support/forums/
