Skip to content

Commit

Permalink
Fix "install update" context menu item.
Browse files Browse the repository at this point in the history
Fixes #1422
  • Loading branch information
Anthony Lieuallen committed Oct 6, 2011
1 parent f693dc4 commit 9756233
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 0 deletions.
6 changes: 6 additions & 0 deletions content/addons.js
Expand Up @@ -73,6 +73,9 @@ buildContextMenu = function(event) {
.setAttribute('hidden', true);
document.getElementById('menuitem_installUpdate_clone')
.setAttribute('command', 'cmd_userscript_installUpdate');
} else {
document.getElementById('menuitem_installUpdate')
.setAttribute('command', 'cmd_installUpdate');
}
};

Expand Down Expand Up @@ -405,6 +408,9 @@ var greasemonkeyAddons = {
case 'cmd_userscript_checkUpdate':
script.checkForRemoteUpdate(true);
break;
case 'cmd_userscript_installUpdate':
script.installUpdate(GM_util.getBrowserWindow());
break;
}
},

Expand Down
1 change: 1 addition & 0 deletions content/addons.xul
Expand Up @@ -83,6 +83,7 @@
<command id="cmd_userscript_move_bottom"/>

<command id="cmd_userscript_sort"/>
<command id="cmd_userscript_installUpdate"/>
</commandset>

<menupopup id="userscriptContextMenu"
Expand Down

0 comments on commit 9756233

Please sign in to comment.