- editor.on( 'dialogHide', function ( evt )\r
- {\r
- evt.removeListener();\r
- resetFromWord();\r
- });\r
+ editor.on( 'dialogShow', function ( evt )\r
+ {\r
+ evt.removeListener();\r
+ evt.data.on( 'cancel', resetFromWord );\r
+ });\r
+\r
+ editor.on( 'dialogHide', function( evt )\r
+ {\r
+ evt.data.removeListener( 'cancel', resetFromWord );\r
+ } );\r