List of usage examples for com.google.gwt.chrome.crx.client Tabs getOnUpdatedEvent
public static native TabUpdatedEvent getOnUpdatedEvent() ;
From source file:com.google.speedtracer.client.BackgroundPage.java
License:Apache License
private void listenForTabEvents() { // We need to keep the browser action icon consistent. Tabs.getOnUpdatedEvent().addListener(new TabUpdatedEvent.Listener() { public void onTabUpdated(int tabId, ChangeInfo changeInfo, Tab tab) { if (changeInfo.getStatus().equals(ChangeInfo.STATUS_LOADING)) { TabModel tabModel = browserConnectionMap.get(CHROME_BROWSER_ID).tabMap.get(tabId); if (tabModel != null) { // We want the icon to remain what it was before the page // transition. setBrowserActionIcon(tabId, tabModel.currentIcon, tabModel); }//ww w .j a v a 2s .c o m } } }); }