firefox addon - Mozilla: openTab fails in recent version -


In a Firefox extension, I open a new tab:

  var tab = gBrowser AddTab (url, referrer, blank, postdata, blank, blank);   

With Firefox 30, this sometimes fails, after opening 9 tabs:

  typeError: this.selectedItem is empty   

However, the number of tabs increases by 1 (checked with gBrowser.browsers.length).

I tried this alternative code, but after some time I get the same error:

  var wm = Components.classes ["@ mozilla.org/appshell /window-mediator;1"].getService (Components.interfaces.nsIWindowMediator); Var my_browser = wm.getMostRecentWindow ("Navigator: Browser"). GetBrowser (); Var tab = my_browser.addTab (url, referral, blank, postdata, blank, empty);    

In some way it was determined that some changes to custom CSS

  # navigator-toolbox {/ * display: none; * / / * Crashes !!! * / Max-height: 0; Hidden flurry; } #TabsToolbar {/ * Display: None; * / / * Crashes !!! * / Max-height: 0; Hidden flurry; }    

Comments

Popular posts from this blog

ios - Adding an SKSpriteNode to SKScene from a child SKSpriteNode -

Matlab transpose a table vector -

c# - Textbox not clickable but editable -