Return true if full screen is active
@returns {boolean}
@private
177844
function isFullscreen() {
        return document.fullScreenElement ||
            document.webkitFullscreenElement ||
            document.mozFullScreenElement ||
            document.msFullscreenElement ||
            isFakeFullscreen;
    }
139040
function toggleFullScreen(elm) {

    if ((document.fullScreenElement && 
         document.fullScreenElement !== null) ||    
        (!document.mozFullScreen && !document.webkitIsFullScreen)) {
        if (elm.requestFullScreen) {  
            elm.requestFullScreen();  
        } else if (elm.mozRequestFullScreen) {  
            elm.mozRequestFullScreen();  
        } else if (elm.webkitRequestFullScreen) {  
          elm.webkitRequestFullScreen();  
      }  
    } else {  
        if (document.cancelFullScreen) {  
          document.cancelFullScreen();  
        } else if (document.mozCancelFullScreen) {  
          document.mozCancelFullScreen();  
        } else if (document.webkitCancelFullScreen) {  
          document.webkitCancelFullScreen();  
        }  
    }  
}
1055321
public function is_active() {

		if ( ! empty( $this->struct['screen'] ) && ! in_array( $this->screen->id, (array) $this->struct['screen'] ) ) {
			return false;
		}

		return parent::is_active();
	}
916798
def fullscreen(self):
        ''' 
        '''
        stream = self._stream
        stream.write(self.alt_screen_enable)
        stream.write(str(self.save_title(0)))     # 0 = both icon, title
        stream.flush()
        try:
            yield self
        finally:
            stream.write(self.alt_screen_disable)
            stream.write(str(self.restore_title(0)))  # 0 = icon & title
            stream.flush()
987237
protected function isPluginsScreen(): bool
    {
        if (!function_exists('get_current_screen')) {
            return false;
        }

        if ($screen = get_current_screen()) {
            return in_array($screen->base, ['plugins', 'plugins-network']);
        }

        return false;
    }
1006379
def is_active(self):
        
        self.open()
        active = lvm_lv_is_active(self.__lvh)
        self.close()
        return bool(active)
226957
function (element, scroller) {
                    if (!element || !_Global.document.body || !_Global.document.body.contains(element)) {
                        return false;
                    }
                    if (!_ElementUtilities._setActive(element, scroller)) {
                        return false;
                    }
                    return (element === _Global.document.activeElement);
                }
184628
private boolean shouldUseFullscreen() {
        SharedPreferences sharedPreferences =
                PreferenceManager.getDefaultSharedPreferences(getActivity());
        String key = getString(R.string.fullscreen_preference_key);
        boolean defaultValue =
                getResources().getBoolean(R.bool.fullscreen_preference_default_value);
        return sharedPreferences.getBoolean(key, defaultValue);
    }
1323015
function () {
        var self = this, statusbar = self.statusbar, layoutRect, width, x, needsRecalc;

        if (self._fullscreen) {
          self.layoutRect(DomUtils.getWindowSize());
          self.layoutRect().contentH = self.layoutRect().innerH;
        }

        self._super();

        layoutRect = self.layoutRect();

        // Resize window based on title width
        if (self.settings.title && !self._fullscreen) {
          width = layoutRect.headerW;
          if (width > layoutRect.w) {
            x = layoutRect.x - Math.max(0, width / 2);
            self.layoutRect({ w: width, x: x });
            needsRecalc = true;
          }
        }

        // Resize window based on statusbar width
        if (statusbar) {
          statusbar.layoutRect({ w: self.layoutRect().innerW }).recalc();

          width = statusbar.layoutRect().minW + layoutRect.deltaW;
          if (width > layoutRect.w) {
            x = layoutRect.x - Math.max(0, width - layoutRect.w);
            self.layoutRect({ w: width, x: x });
            needsRecalc = true;
          }
        }

        // Recalc body and disable auto resize
        if (needsRecalc) {
          self.recalc();
        }
      }
67792
function (/* event */) {
        if (!me.device.isFullscreen) {
            me.device.requestFullscreen();
        } else {
            me.device.exitFullscreen();
        }
        return false;
    }
731273
function () {
        var self = this, layoutRect = self._super(), deltaH = 0, headEl;

        // Reserve vertical space for title
        if (self.settings.title && !self._fullscreen) {
          headEl = self.getEl('head');

          var size = DomUtils.getSize(headEl);

          layoutRect.headerW = size.width;
          layoutRect.headerH = size.height;

          deltaH += layoutRect.headerH;
        }

        // Reserve vertical space for statusbar
        if (self.statusbar) {
          deltaH += self.statusbar.layoutRect().h;
        }

        layoutRect.deltaH += deltaH;
        layoutRect.minH += deltaH;
        //layoutRect.innerH -= deltaH;
        layoutRect.h += deltaH;

        var rect = DomUtils.getWindowSize();

        layoutRect.x = self.settings.x || Math.max(0, rect.w / 2 - layoutRect.w / 2);
        layoutRect.y = self.settings.y || Math.max(0, rect.h / 2 - layoutRect.h / 2);

        return layoutRect;
      }
890580
def is_focused(self):
        
        active_el = self.browser.execute_script("return document.activeElement")
        query_results = self.map(lambda el: el == active_el, 'focused').results

        if query_results:
            return any(query_results)
        return False
1098096
def is_active(self):
        """"""
        if self._queue.exhausted:
            return False
        return any(ch.is_active for ch in self._refs.values())
724127
function (event) {
        var x = event.gameScreenX + (event.width / 2);
        var y = event.gameScreenY + (event.height / 2);
        this.setOpacity(0.50);
        this.checkDirection.call(this, x, y);
        return false;
    }
1230350
function fullscreenchange () {
		var newEvent = document.createEvent('CustomEvent');
		newEvent.initCustomEvent('fullscreenchange', true, false, null);
		// TODO: Any need for variable copy?
		document.dispatchEvent(newEvent);
	}
525393
public boolean isActive()
    {
        FacesContext facesContext = FacesContext.getCurrentInstance();
        if (facesContext != null)
        {
            return facesContext.getViewRoot() != null;
        }
        else
        {
            // No FacesContext means no view scope active.
            return false;
        }
    }
1049593
def toggle_full_screen(self, *args):
        

        LOGGER.debug("> Toggling FullScreen state.")

        if self.is_full_screen():
            self.setUnifiedTitleAndToolBarOnMac(True)
            self.set_visual_style(full_screen_style=False)
            self.showNormal()
            # TODO: Remove hack that ensure toolBar is repainted.
            platform.system() == "Darwin" and self.resize(self.size().width() + 1, self.size().height() + 1)
        else:
            self.setUnifiedTitleAndToolBarOnMac(False)
            self.set_visual_style(full_screen_style=True)
            self.showFullScreen()
        return True