diff options
| author | jmoenig <jens@moenig.org> | 2014-07-11 17:59:16 +0200 |
|---|---|---|
| committer | jmoenig <jens@moenig.org> | 2014-07-11 17:59:16 +0200 |
| commit | c4968843e4129eb1b7355a20e6a5e72e67dea704 (patch) | |
| tree | 8c0b0d38242a561f07777793defe7d646baf55bc /morphic.js | |
| parent | 98772028bb648317a8825090540f81f71ad0003e (diff) | |
| download | snap-c4968843e4129eb1b7355a20e6a5e72e67dea704.tar.gz snap-c4968843e4129eb1b7355a20e6a5e72e67dea704.zip | |
fixed #508 (don’t popup empty menus)
thanks, @cycomached!
Diffstat (limited to 'morphic.js')
| -rw-r--r-- | morphic.js | 3 |
1 files changed, 3 insertions, 0 deletions
@@ -6893,6 +6893,9 @@ MenuMorph.prototype.popup = function (world, pos) { if (world.activeMenu) { world.activeMenu.destroy(); } + if (this.items.length < 1 && !this.title) { // don't show empty menus + return; + } world.add(this); world.activeMenu = this; this.fullChanged(); |
