diff options
author | Petr Vobornik <pvoborni@redhat.com> | 2012-09-07 14:24:58 +0200 |
---|---|---|
committer | Petr Vobornik <pvoborni@redhat.com> | 2012-09-12 09:37:53 +0200 |
commit | b4d35718a52e2649a407b95b85193f20401c346d (patch) | |
tree | 94754f053396ebe75e791081532f242eede1329c /install/ui | |
parent | 1f831393a24c0c3c7df50c4327395f1197f485e5 (diff) | |
download | freeipa-b4d35718a52e2649a407b95b85193f20401c346d.tar.gz freeipa-b4d35718a52e2649a407b95b85193f20401c346d.tar.xz freeipa-b4d35718a52e2649a407b95b85193f20401c346d.zip |
Prevent opening of multiple dirty dialogs on navigation
Facets which performs AJAX call after update refresh (clear dirty state) after calling callback of dirty dialog. It might lead to multiple openings of dirty dialog.
Assuming that calling dirty dialog's callback can be evaluated as "dirty state is gone", we can call reset in the callback to prevent the issue. There will be an incorrect state in the facet for a moment. It will be fixed soon on execute of callback of the refresh AJAX call. It is not an issue because it will happen in background. User will be looking on different facet.
https://fedorahosted.org/freeipa/ticket/2667
Diffstat (limited to 'install/ui')
-rw-r--r-- | install/ui/navigation.js | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/install/ui/navigation.js b/install/ui/navigation.js index 502b05490..deef37dd8 100644 --- a/install/ui/navigation.js +++ b/install/ui/navigation.js @@ -134,6 +134,11 @@ IPA.navigation = function(spec) { }); dialog.callback = 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 (prev_facet.is_dirty()) prev_facet.reset(); $.bbq.pushState(params); }; |