Switching between tabs flicker

Having problems with building or using CEF's C/C++ APIs? This forum is here to help. Please do not post bug reports or feature requests here.

Switching between tabs flicker

Postby SturmCoder » Sun Oct 29, 2017 11:18 pm

Hi all,

Is there any way to prevent browser from resizing/redrawing itself when got focus?

It causes flicker and hangs if there is lot of elements in page when switchig tabs making whole thing looking trippy.

It also happens when minimized and restored again.

Etc. when external link is open in new tab and switched to it (when browser got focus after losing it again I suppose it redraw itself again)
Im using custom mdi tab control on winforms.

I tried so far to send message like:
Code: Select all
SendMessage(parent.Handle, WM_SETREDRAW, false, 0);

It works as It should but I cant find suitable handler to fire it just on focus get and loose.

I also tried implementing IFocusHandler and it works great but it is quite dificult to call SendMessage in place where object reference is required inside a derived class, in this case parent.Handle(browser) a handle to control that is about to be suspended and resumed redrawn.

Any ideas how to stop redraw on got focus and resume it emmidiately after redrawn is complete?
Thank you
Code: Select all
Life runs on code
SturmCoder
Newbie
 
Posts: 3
Joined: Sun Oct 29, 2017 12:42 pm

Return to Support Forum

Who is online

Users browsing this forum: Google [Bot] and 34 guests