firefox addon - jpm run shows demo ActionButton, but jpm xpi does not -


broken mdn demo

i copied first demo, added own custom icons, nothing else. tested using jpm run, works fine, buttons appear in navigation bar, can customized , move around, clicking button opens tab mozilla.org expected, great.

jpm xpi, installation generates 2 error messages, same mentioned in a similar question, unlike question, icon won't show anywhere in interface.

however, if exit restart browser -jsconsole, not error message, yet still no button appearing anywhere.

this error message confusing, mentions low level , has nothing of basic high level code have entered.

[exception... "component returned failure code: 0x80004005 (ns_error_failure) [nsiuri.hostport]"  nsresult: "0x80004005 (ns_error_failure)"  location: "js frame :: resource://gre/modules/popupnotifications.jsm :: popupnotifications_refreshpanel/< :: line 667"  data: no]  popupnotifications_refreshpanel/<() popupnotifications.jsm:667 foreach() self-hosted popupnotifications_refreshpanel() popupnotifications.jsm:616 popupnotifications_showpanel() popupnotifications.jsm:728 popupnotifications_update() popupnotifications.jsm:844 popupnotifications_show() popupnotifications.jsm:394 gxpinstallobserver.showinstallconfirmation() browser-addons.js:206 gxpinstallobserver.observe/shownotification() browser-addons.js:383 gxpinstallobserver.observe() browser-addons.js:399 notifyobservers() amwebinstalllistener.js:51 installer.prototype.checkalldownloaded() amwebinstalllistener.js:171 installer() amwebinstalllistener.js:81 extwebinstalllistener.prototype.onwebinstallrequested() amwebinstalllistener.js:335 buildnextinstall() extensions.js:1276 gviewcontroller.commands.cmd_installfromfile.docommand/buildnextinstall/<() extensions.js:1286 safecall() addonmanager.jsm:179 addonmanagerinternal.getinstallforfile/<.nextobject/<() addonmanager.jsm:1955 this.xpiprovider.getinstallforfile/<() xpiprovider.jsm:3872 makesafe/<() xpiprovider.jsm:1982 addoninstall.prototype.initlocalinstall/</<() xpiprovider.jsm:5306 makesafe/<() xpiproviderutils.js:168 completeaddon() xpiproviderutils.js:157 getaddon() addonrepository.jsm:583 this.addonrepository.getcachedaddonbyid<() addonrepository.jsm:595 next() self-hosted taskimpl_run() task.jsm:319 taskimpl() task.jsm:280 createasyncfunction/asyncfunction() task.jsm:254 getrepositoryaddon() xpiproviderutils.js:159 this.xpidatabase.getaddon/<() xpiproviderutils.js:1119 handler.prototype.process() promise-backend.js:937 this.promisewalker.walkerloop() promise-backend.js:816 bound () self-hosted bound bound () self-hosted (unknown)  [exception... "component returned failure code: 0x80004005 (ns_error_failure) [nsiuri.hostport]"  nsresult: "0x80004005 (ns_error_failure)"  location: "js frame :: resource://gre/modules/popupnotifications.jsm :: popupnotifications_refreshpanel/< :: line 667"  data: no]  popupnotifications_refreshpanel/<() popupnotifications.jsm:667 foreach() self-hosted popupnotifications_refreshpanel() popupnotifications.jsm:616 popupnotifications_showpanel() popupnotifications.jsm:728 popupnotifications_update() popupnotifications.jsm:844 popupnotifications_show() popupnotifications.jsm:394 gxpinstallobserver.observe() browser-addons.js:432 notifyobservers() amwebinstalllistener.js:51 installer.prototype.checkallinstalled() amwebinstalllistener.js:230 installer.prototype.oninstallended() amwebinstalllistener.js:270 addonmanagerinternal.callinstalllisteners() addonmanager.jsm:1716 this.addonmanagerprivate.callinstalllisteners() addonmanager.jsm:2976 addoninstall.prototype.startinstall/<() xpiprovider.jsm:6212 interpretgeneratorresume() self-hosted next() self-hosted taskimpl_run() task.jsm:319 bound taskimpl_run() self-hosted handler.prototype.process() promise-backend.js:937 this.promisewalker.walkerloop() promise-backend.js:816 bound () self-hosted bound bound () self-hosted (unknown) 

there mention in about:config @ browser.uicustomization.state (or in user.pref) icon supposed be, not there. note \"action-button--guid-mozilla-link\" below. bug happening in 49.0a1 nightly, not in 50.0a1 nightly, maybe fixed?

user_pref("browser.uicustomization.state", "{\"placements\":{\"panelui-contents\":[\"edit-controls\",\"zoom-controls\",\"new-window-button\",\"e10s-button\",\"privatebrowsing-button\",\"save-page-button\",\"print-button\",\"history-panelmenu\",\"fullscreen-button\",\"find-button\",\"preferences-button\",\"add-ons-button\",\"developer-button\",\"sync-button\",\"bookmarks-menu-button\",\"home-button\",\"loop-button\",\"pocket-button\"],\"addon-bar\":[\"addonbar-closebutton\",\"status-bar\"],\"personaltoolbar\":[\"personal-bookmarks\"],\"nav-bar\":[\"urlbar-container\",\"search-container\",\"downloads-button\",\"action-button--guid-mozilla-link\"],\"tabstoolbar\":[\"tabbrowser-tabs\",\"new-tab-button\",\"alltabs-button\"],\"toolbar-menubar\":[\"menubar-items\"]},\"seen\":[\"loop-button\",\"pocket-button\",\"developer-button\",\"action-button--guid-mozilla-link\"],\"dirtyareacache\":[\"nav-bar\",\"panelui-contents\",\"addon-bar\",\"personaltoolbar\",\"tabstoolbar\",\"toolbar-menubar\"],\"currentversion\":6,\"newelementcount\":173}"); 

after comparing 49.0a1 50.0a1, , ensuring button icons in same order, difference 49.0a1 has newelementcount = 173 , 50.0a1 has newelementcount = 0.

after customize -> reset in 49.0a1, demo action button "appears", somewhat, in "additional tools , features", text label. icon not visible. button can't moved around "properly", in click , drag / hover / index of position land in, incorrect, , when dropped, lands "nowhere", disappears ui, yet user pref appears remain valid.


Comments

Popular posts from this blog

java - Static nested class instance -

c# - Bluetooth LE CanUpdate Characteristic property -

JavaScript - Replace variable from string in all occurrences -