Commit 3911b490 authored by llhuillier's avatar llhuillier
Browse files

stuff2

parent 54fba78e
......@@ -12,6 +12,6 @@
},
"browser_action": {
"default_icon": "button.png",
"default_title": "Recharger la page"
"default_title": "Accès hors campus"
}
}
\ No newline at end of file
#cbutton
#mybutton
{list-style-image: url("chrome://custombutton/content/button.png");}
\ No newline at end of file
......@@ -13,13 +13,13 @@
<!-- Firefox -->
<toolbarpalette id="BrowserToolbarPalette">
<toolbarbutton id="cbutton"/>
<toolbarbutton id="mybutton"/>
</toolbarpalette>
<!-- button details -->
<toolbarbutton id="cbutton"
<toolbarbutton id="mybutton"
label="Accès distant"
tooltiptext="Recharger la page"
tooltiptext="Accès hors campus"
oncommand="transformUrl()"
class="toolbarbutton-1 chromeclass-toolbar-additional custombutton"
/>
......
......@@ -2,18 +2,18 @@ window.addEventListener("load", em_myextensionLoad, true);
function em_myextensionLoad() {
if (document.getElementById("cbutton")) return;
if (document.getElementById("mybutton")) return;
try {
var firefoxnav = document.getElementById("nav-bar");
var curSet = firefoxnav.currentSet;
if (curSet.indexOf("cbutton") == -1)
if (curSet.indexOf("mybutton") == -1)
{
var set;
if (curSet.indexOf("urlbar-container") != -1)
set = firefoxnav.currentSet + ",cbutton";
set = firefoxnav.currentSet + ",mybutton";
else
set = curSet.replace(/urlbar-container/, "cbutton,urlbar-container");
set = curSet.replace(/urlbar-container/, "mybutton,urlbar-container");
firefoxnav.setAttribute("currentset", set);
firefoxnav.currentSet = set;
document.persist("nav-bar", "currentset");
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment