I have made my full FF extension, and there is a button in the URL bar. The boss now wants the button to show a certain string when you hover over it. Here is my current code for the button:
var loadURLButton = function(doc, urlBtnClick) {
var urlBarIcons = doc.getElementById('urlbar-icons')
var btn = doc.createElement('toolbarbutton');
btn.setAttribute('id', 'urlbutton');
btn.setAttribute('image', require('sdk/self').data.url("canNone.png"));
btn.addEventListener('command', urlBtnClick, false);
urlBarIcons.appendChild(btn);
return btn;
}
var doc = require('sdk/window/utils').getMostRecentBrowserWindow().document;
var urlbarButton = loadURLButton(doc, openTab);
What can I add to this in order to make some id pop up on hover?
See Question&Answers more detail:
os 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…