The code looks like this:
- Code: Select all
public class MyMessageRouter extends CefMessageRouterHandlerAdapter {
@Override
public boolean onQuery(CefBrowser browser,
long query_id,
String request,
boolean persistent,
CefQueryCallback callback) {
// do something here
return true;
}
@Override
public void onQueryCanceled(CefBrowser browser, long query_id) {
log.info("We closed the tab.");
}
}
Now on JCEF, I am launching multiple tabs (e.g. 4). And when I close the first tab (in any order), I do see the following log:
- Code: Select all
We closed the tab.
WARNING:message_in_transit_queue.cc(18)] Destroying nonempty message queue
But then when I close the other tabs, I don't see the "We closed the tab" log any more.
Any reason why the message queue is getting closed and why closing other tabs doesn't fire the onQueryCanceled for them?