Fixed #568: mode switcher disappearing when selecting the current mode again
This commit is contained in:
parent
1a99acd36d
commit
5ca264d037
|
@ -3,6 +3,12 @@
|
|||
https://github.com/josdejong/jsoneditor
|
||||
|
||||
|
||||
## not yet released, version 5.24.1
|
||||
|
||||
- Fixed #568: mode switcher disappearing when selecting the current
|
||||
mode again.
|
||||
|
||||
|
||||
## 2018-08-22, version 5.24.0
|
||||
|
||||
- Implemented a color picker, and allow hooking in a custom color
|
||||
|
|
|
@ -1043,8 +1043,6 @@ treemode._createFrame = function () {
|
|||
if (this.options && this.options.modes && this.options.modes.length) {
|
||||
var me = this;
|
||||
this.modeSwitcher = new ModeSwitcher(this.menu, this.options.modes, this.options.mode, function onSwitch(mode) {
|
||||
me.modeSwitcher.destroy();
|
||||
|
||||
// switch mode and restore focus
|
||||
me.setMode(mode);
|
||||
me.modeSwitcher.focus();
|
||||
|
|
Loading…
Reference in New Issue