wjywbs wrote:Recently, I'm trying to embed cef1 into multiple tabs in a window. And I found out that repeated initializing cef won't work (same procedure: call CefInitialize, a new g_handler, same HWND, run message loop). The browser only exists in one tab. So does cef1 support tabs like Chrome? Or do I need to use a different method? (I'm using org.eclipse.swt.custom.CTabItem in Java. I tried to use org.eclipse.swt.browser.Browser in several CTabItem and it worked. But cef does not work with several CTabItem.)
I was able to create multiple browser window within multiple views in Eclipse using CEF3 on Windows. I believe eclipse view is not much different than CTabItem. From my understanding, you need to pass in a different HWND for each instance of the browser. Try to use a different window handle, perhaps create a composite for each tab item and pass in the composite handle to the browser create method.
I have a different problem related to multiple instances of the browser within the same process. I was able to create multiple browsers with CEF3 using my JNI java wrapper, but as soon as I close the last browser and re-open a new browser. The new browser doesn't render the html page, it displays text in the browser instead.
Does any one experienced this issue before, or might have any idea what I might be doing wrong?
Thanks!