[gnome-shell] altTab: fix Alt+Tab scrolling on initial display
- From: Adel Gadllah <agadllah src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-shell] altTab: fix Alt+Tab scrolling on initial display
- Date: Tue, 26 Apr 2011 19:10:40 +0000 (UTC)
commit fe08edbe2bf88aa43b643a8f8449dd49a3bafabe
Author: Dan Winship <danw gnome org>
Date: Mon Apr 18 09:52:21 2011 -0400
altTab: fix Alt+Tab scrolling on initial display
The initial selection of the Alt+Tab dialog was happening before the
dialog was shown and allocated, and so the "do we need to scroll"
check used bogus coordinates. Fix by showing the dialog (and forcing
an allocation) first.
https://bugzilla.gnome.org/show_bug.cgi?id=647807
js/ui/altTab.js | 8 ++++++--
1 files changed, 6 insertions(+), 2 deletions(-)
---
diff --git a/js/ui/altTab.js b/js/ui/altTab.js
index 43b7552..736674e 100644
--- a/js/ui/altTab.js
+++ b/js/ui/altTab.js
@@ -145,6 +145,12 @@ AltTabPopup.prototype = {
this._appIcons = this._appSwitcher.icons;
+ // Need to force an allocation so we can figure out whether we
+ // need to scroll when selecting
+ this.actor.opacity = 0;
+ this.actor.show();
+ this.actor.get_allocation_box();
+
// Make the initial selection
if (switch_group) {
if (backward) {
@@ -174,8 +180,6 @@ AltTabPopup.prototype = {
return false;
}
- this.actor.opacity = 0;
- this.actor.show();
Tweener.addTween(this.actor,
{ opacity: 255,
time: POPUP_FADE_TIME,
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]