From 1d573f4179503ea9e1cc15327f67e8b52740adad Mon Sep 17 00:00:00 2001 From: Alex Yatskov Date: Thu, 29 Sep 2016 21:04:03 -0700 Subject: Add visibility query --- ext/fg/js/popup.js | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'ext/fg/js') diff --git a/ext/fg/js/popup.js b/ext/fg/js/popup.js index 88b8e4e3..31ff02d8 100644 --- a/ext/fg/js/popup.js +++ b/ext/fg/js/popup.js @@ -51,6 +51,10 @@ class Popup { this.showAt({x: posX, y: posY}, content); } + visible() { + return this.popup !== null && this.popup.style.visibility !== 'hidden'; + } + hide() { if (this.popup !== null) { this.popup.style.visibility = 'hidden'; -- cgit v1.2.3