GNOME Bugzilla – Bug 595382
[main] Better handle pushModal failing
Last modified: 2009-09-17 20:40:09 UTC
Previously we'd leave the focus on the stack, etc.
Created attachment 143279 [details] [review] [main] Better handle pushModal failing
Comment on attachment 143279 [details] [review] [main] Better handle pushModal failing sure, though there's still the problem that no one looks at the return value.
Review of attachment 143279 [details] [review]: Looks fine, one style comment. ::: js/ui/main.js @@ +212,3 @@ let timestamp = global.screen.get_display().get_current_time(); + if (modalCount == 0 && !global.begin_modal(timestamp)) { I'm not fan of the short-circuiting logic here too shell-like - I'd rather see: if (modalCount == 0) { if (!global.begin_modal(timestamp)) { .. } }
Oh, and what Dan says too .. the callers need to check - it *can* happen - e.g., if anybody on the desktop does XGrabPointer() without grabbing the keyboard, then the overview key will trigger this problem.
Created attachment 143393 [details] [review] Better handle pushModal failing Previously we'd leave the focus on the stack, etc.
Review of attachment 143393 [details] [review]: Looks good to me
Attachment 143393 [details] pushed as cee7106 - Better handle pushModal failing