Hello -
In an attempt to eliminate flicker from my application, I have
implemented double buffering just like Chris Barker's wiki page.
I apologize in advance if this is such a no-brainier question, but how
can I get stock objects (like a wx.Button) to be drawn on the
wx.BufferedPaintDC ? How can I specify their device context to use
for the painting?
Right now I am setting up the buffer, copying it to the screen and
then the MediaCtrl is updating the on-screen buffer so it appears to
work just fine. However, the problem I have is as soon as I press
down on one of my customer double buffered Volume Up or Volume Down
buttons, the screen gets refreshed to show movement in the button and
the media player (since it was using the on screen buffer) gets
overwritten when the entire double buffer is Blit() to the screen.
I have tried Refreshing the media player after I call the Draw()
method of all my double buffered objects, but I get a very noticeable
flicker.
Another thing I am not totally clear on is why the entire screen is
getting copied over on the paint instead of just invalidating the
rectangle around my button and only refreshing that portion? Instead,
my entire screen is being refreshed with the contents of the double
buffer.
Your help would be greatly appreciated, thank you.
John