[gnome-shell] boxpointer: Don't hide when we're already hidden
- From: Jasper St. Pierre <jstpierre src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-shell] boxpointer: Don't hide when we're already hidden
- Date: Wed, 20 Nov 2013 14:56:29 +0000 (UTC)
commit d77fc015801e60bb491eac5c5e65cbc347ebb0f4
Author: Jasper St. Pierre <jstpierre mecheye net>
Date: Tue Nov 19 22:39:39 2013 -0500
boxpointer: Don't hide when we're already hidden
You would think we would already do something like this, but apparently
lots of code was calling hide() without checking if the box pointer was
already visible, causing it to queue a full tween. The biggest win was
with ibusCandidatePopup.js, which called hide() on every DBus message.
This increases the performance for me to enter the overview by a tiny
bit. The remaining time is spent updating the frequent apps / all apps
display.
https://bugzilla.gnome.org/show_bug.cgi?id=712727
js/ui/boxpointer.js | 3 +++
1 files changed, 3 insertions(+), 0 deletions(-)
---
diff --git a/js/ui/boxpointer.js b/js/ui/boxpointer.js
index c8a15d3..e940337 100644
--- a/js/ui/boxpointer.js
+++ b/js/ui/boxpointer.js
@@ -121,6 +121,9 @@ const BoxPointer = new Lang.Class({
},
hide: function(animate, onComplete) {
+ if (!this.actor.visible)
+ return;
+
let xOffset = 0;
let yOffset = 0;
let themeNode = this.actor.get_theme_node();
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]