text: function BrowserButton(t){BrowserButtonBase.call(this,t),this._popupDetails=null,chrome.browserAction.onClicked.addListener(func.bind(this._onClicked,this)),this._initDetails(t)}var extensionInfo=require("kango/extension_info"),utils=require("kango/utils"),object=utils.object,func=utils.func,io=require("kango/io");BrowserButton.prototype=object.extend(BrowserButtonBase,{_onClicked:function(){return this.fireEvent(this.event.COMMAND)},_initDetails:function(t){object.isObject(t)&&(object.isString(t.icon)&&this.setIcon(t.icon),object.isString(t.caption)&&this.setCaption(t.caption),object.isString(t.tooltipText)&&this.setTooltipText(t.tooltipText),object.isObject(t.popup)&&this.setPopup(t.popup))},setTooltipText:function(t){chrome.browserAction.setTitle({title:t.toString()})},setCaption:function(t){},setIcon:function(t){chrome.browserAction.setIcon({path:io.getFileUrl(t)})},setBadgeValue:function(t){chrome.browserAction.setBadgeText({text:null!=t&&0!=t?t.toString():""})},setBadgeBackgroundColor:function(t){chrome.browserAction.setBadgeBackgroundColor({color:t})},setPopup:function(t){this._popupDetails=t;var o="";t&&t.url&&(o=t.url),chrome.browserAction.setPopup({popup:o})},getPopupDetails:function(){return this._popupDetails},setContextMenu:function(){}}),extensionInfo.browser_button&&(module.exports=new BrowserButton(extensionInfo.browser_button),module.exports.getPublicApi=getPublicApi);