diff options
author | Petr Vobornik <pvoborni@redhat.com> | 2013-03-19 13:50:05 +0100 |
---|---|---|
committer | Petr Vobornik <pvoborni@redhat.com> | 2013-05-06 16:22:19 +0200 |
commit | 89635f1bc356bb9146c73e25530872e15e6acfec (patch) | |
tree | 3a1d89e482d115417628e7e4aad804bcd1148b11 /install/ui/src/freeipa/Application_controller.js | |
parent | b06d008f31a49bc907a4e310dacf97d72a78efc5 (diff) | |
download | freeipa-89635f1bc356bb9146c73e25530872e15e6acfec.tar.gz freeipa-89635f1bc356bb9146c73e25530872e15e6acfec.tar.xz freeipa-89635f1bc356bb9146c73e25530872e15e6acfec.zip |
Fix dirty dialog behavior
Dirty dialog was displayed twice because of double event registration in menu widget.
https://fedorahosted.org/freeipa/ticket/3236
Diffstat (limited to 'install/ui/src/freeipa/Application_controller.js')
-rw-r--r-- | install/ui/src/freeipa/Application_controller.js | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/install/ui/src/freeipa/Application_controller.js b/install/ui/src/freeipa/Application_controller.js index 16b639e73..03b987a1f 100644 --- a/install/ui/src/freeipa/Application_controller.js +++ b/install/ui/src/freeipa/Application_controller.js @@ -179,13 +179,13 @@ define(['dojo/_base/declare', var current_facet = this.current_facet; if (current_facet && !current_facet.can_leave()) { - var permit_clb = function() { + var permit_clb = lang.hitch(this, function() { // Some facet's might not call reset before this call but after // so they are still dirty. Calling reset prevent's opening of // dirty dialog again. if (current_facet.is_dirty()) current_facet.reset(); //TODO change this.router.navigate_to_hash(event.hash, event.facet); - }; + }); var dialog = current_facet.show_leave_dialog(permit_clb); this.router.canceled = true; |