This is just a simple default screen selector implementation
16888
function simpleSelector(sources, callback) {

  var options = crel('select', {
    style: 'margin: 0.5rem'
  }, sources.map(function(source) {
    return crel('option', {id: source.id, value: source.id}, source.name);
  }));

  var selector = crel('div',
    {
      style: 'position: absolute; padding: 1rem; z-index: 999999; background: #ffffff; width: 100%; font-family: \'Lucida Sans Unicode\', \'Lucida Grande\', sans-serif; box-shadow: 0px 2px 4px #dddddd;'
    },
    crel('label', { style: 'margin: 0.5rem' }, 'Share screen:'),
    options,
    crel('span', { style: 'margin: 0.5rem; display: inline-block' },
      button('Share', function() {
        close();
        var selected = sources.filter(function(source) {
          return source && source.id === options.value;
        })[0];
        return callback(null, options.value, { title: selected.name });
      }),
      button('Cancel', close)
    )
  );

  function button(text, fn) {
    var button = crel('button', {
      style: 'background: #555555; color: #ffffff; padding: 0.5rem 1rem; margin: 0rem 0.2rem;'
    }, text);
    button.addEventListener('click', fn);
    return button;
  }

  function close() {
    document.body.removeChild(selector);
  }

  document.body.appendChild(selector);
}
894313
def _selectView( self ):
        
        scene = self.uiGanttVIEW.scene()
        scene.blockSignals(True)
        scene.clearSelection()
        for item in self.uiGanttTREE.selectedItems():
            item.viewItem().setSelected(True)
        scene.blockSignals(False)
        
        curr_item = self.uiGanttTREE.currentItem()
        vitem = curr_item.viewItem()
        
        if vitem:
            self.uiGanttVIEW.centerOn(vitem)
167825
function setSelector(image, options, dynamicBlock, retina) {
	dynamicBlock = dynamicBlock || false;
	retina = retina || false;
	var basename = image.isSVG ? path.basename(image.name, '.svg') : path.basename(image.name, '.png');
	if (retina) {
		// If retina, then '@2x','@3x','_2x','_3x' will be removed.
		basename = _.replace(basename, /[@_](\d)x$/, '');
	}
	var selector = (dynamicBlock ? dynamicBlock : image.dir) + options.cssSeparator + basename;
	if (options.pseudoClass) {
		if (image.name.toLowerCase().indexOf('hover') > -1 || image.name.toLowerCase().indexOf('active') > -1) {
			selector = _.replace(selector, 'Hover', ':hover');
			selector = _.replace(selector, 'Active', ':active');
			selector = _.replace(selector, '_hover', ':hover');
			selector = _.replace(selector, '_active', ':active');
		}
	}
	return selector;
}
535569
function () {
            var me = this;
            if (!me.lastBk) {
                me.lastBk = me.selection.getRange().createBookmark(true);
            }
            me.container.style.display = 'none'
        }
185408
function ( e ) {

        e.preventDefault();

        this.s[4].borderColor = this.colors.select;
        this.s[4].color = this.colors.select;

    }
602886
function () {
            if (!this.props.visible) {
                return;
            }

            var node = Preact.findDOMNode(this),
                selectedNode = $(node.parentNode).find(this.props.selectedClassName),
                selectionViewInfo = this.props.selectionViewInfo;

            if (selectedNode.length === 0) {
                return;
            }

            node.style.top = selectedNode.offset().top - selectionViewInfo.get("offsetTop") + selectionViewInfo.get("scrollTop") - selectedNode.position().top + "px";
        }
414340
def DefaultSelector(sock):
    ""
    global _DEFAULT_SELECTOR
    if _DEFAULT_SELECTOR is None:
        if has_selector('poll'):
            _DEFAULT_SELECTOR = PollSelector
        elif hasattr(select, 'select'):
            _DEFAULT_SELECTOR = SelectSelector
        else:
            raise RedisError('Platform does not support any selectors')
    return _DEFAULT_SELECTOR(sock)
876463
private void configureFullscreen(Activity injectionActivity) {
		
		if(injectionActivity.getClass().isAnnotationPresent(Fullscreen.class)) {
			
			injectionActivity.requestWindowFeature(Window.FEATURE_NO_TITLE);
			injectionActivity.getWindow().setFlags(WindowManager.LayoutParams.FLAG_FULLSCREEN, 
												   WindowManager.LayoutParams.FLAG_FULLSCREEN);
		}
	}
768269
public void autoFullscreen(float x) {
        if (CURRENT_JZVD != null
                && (currentState == CURRENT_STATE_PLAYING || currentState == CURRENT_STATE_PAUSE)
                && currentScreen != SCREEN_WINDOW_FULLSCREEN
                && currentScreen != SCREEN_WINDOW_TINY) {
            if (x > 0) {
                JZUtils.setRequestedOrientation(getContext(), ActivityInfo.SCREEN_ORIENTATION_LANDSCAPE);
            } else {
                JZUtils.setRequestedOrientation(getContext(), ActivityInfo.SCREEN_ORIENTATION_REVERSE_LANDSCAPE);
            }
            gotoScreenFullscreen();
        }
    }
780193
function toggleFullScreen(editor) {
    // Set fullscreen
    var cm = editor.codemirror;
    cm.setOption('fullScreen', !cm.getOption('fullScreen'));


    // Prevent scrolling on body during fullscreen active
    if (cm.getOption('fullScreen')) {
        saved_overflow = document.body.style.overflow;
        document.body.style.overflow = 'hidden';
    } else {
        document.body.style.overflow = saved_overflow;
    }


    // Update toolbar class
    var wrap = cm.getWrapperElement();

    if (!/fullscreen/.test(wrap.previousSibling.className)) {
        wrap.previousSibling.className += ' fullscreen';
    } else {
        wrap.previousSibling.className = wrap.previousSibling.className.replace(/\s*fullscreen\b/, '');
    }


    // Update toolbar button
    if (editor.toolbarElements.fullscreen) {
        var toolbarButton = editor.toolbarElements.fullscreen;

        if (!/active/.test(toolbarButton.className)) {
            toolbarButton.className += ' active';
        } else {
            toolbarButton.className = toolbarButton.className.replace(/\s*active\s*/g, '');
        }
    }


    // Hide side by side if needed
    var sidebyside = cm.getWrapperElement().nextSibling;
    if (/editor-preview-active-side/.test(sidebyside.className))
        toggleSideBySide(editor);
}
706458
public void createViewBasedOnConfiguration() {
		// set default values, when appropriate
		arrowCheckBox.setValue(super.isWithArrow());
		scaleBarBox.setValue(super.isWithScaleBar());
		dpiTextBox.setText(super.getDpi() + "");
		rasterDpiTextBox.setText(super.getRasterDpi() + "");
		if (super.isLandscape()) {
			optionLandscapeOrientation.setValue(true);
		} else {
			optionPortraitOrientation.setValue(true);
		}
		postPrintActionRadioButtonMap.get(super.getPostPrintAction()).setValue(true);

		// show/hide option sections
		titleSection.setVisible(getOptionsToShowConfiguration().isShowTitleOption());
		orientationSection.setVisible(getOptionsToShowConfiguration().isShowLandscapeOption());
		pageSizeSection.setVisible(getOptionsToShowConfiguration().isShowPageSizeOption());
		withArrowSection.setVisible(getOptionsToShowConfiguration().isShowWithArrowOption());
		withScaleBarSection.setVisible(getOptionsToShowConfiguration().isShowWithScaleBarOption());
		dpiSection.setVisible(getOptionsToShowConfiguration().isShowDpiOption());
		rasterDpiSection.setVisible(getOptionsToShowConfiguration().isShowRasterDpiOption());
		postPrintActionSection.setVisible(getOptionsToShowConfiguration().isShowPostPrintActionOption());
		fileNameSection.setVisible(getOptionsToShowConfiguration().isShowFileNameOption());
		syncSection.setVisible(getOptionsToShowConfiguration().isShowSyncOption());
	}
204327
function toggleFullscreen(element, callback) {
    if (callback && typeof callback === 'function') {
        if (!isFullscreen()) {
            var fn = function (e) {
                if (isFullscreen()) {
                    callback(true);
                }
                else {
                    callback(false);
                }
            };
            fullscreenChange(fn);
            enterFullscreen(element);
        }
        else {
            exitFullscreen();
            callback(false);
        }
        return Promise.resolve();
    }
    return new Promise(function (resolve) {
        if (!isFullscreen()) {
            enterFullscreen(element);
        }
        else {
            exitFullscreen();
        }
        resolve();
    });
    /**
     * enter fullscreen mode.
     * @param {Element} element
     */
    function enterFullscreen(element) {
        var userAgent = navigator.userAgent.toLowerCase();
        if (element.requestFullscreen) {
            element.requestFullscreen();
        }
        else if (element.msRequestFullscreen) {
            element.msRequestFullscreen();
        }
        else if (element.mozRequestFullScreen) {
            element.parentElement.mozRequestFullScreen();
        }
        else if (userAgent.indexOf('edge') != -1) {
            element.parentElement.webkitRequestFullscreen();
        }
        else if (element.webkitRequestFullscreen) {
            element.webkitRequestFullscreen();
        }
    }
    /**
     * exit fullscreen mode.
     */
    function exitFullscreen() {
        var _doument = document;
        if (document.exitFullscreen) {
            document.exitFullscreen();
        }
        else if (_doument.msExitFullscreen) {
            _doument.msExitFullscreen();
        }
        else if (_doument.mozCancelFullScreen) {
            _doument.mozCancelFullScreen();
        }
        else if (_doument.webkitExitFullscreen) {
            _doument.webkitExitFullscreen();
        }
    }
}
698790
private void initFullscreen(Resolution output, int depth)
    {
        final java.awt.Window window = new java.awt.Window(frame, conf);
        window.setBackground(Color.BLACK);
        window.setIgnoreRepaint(true);
        window.setPreferredSize(new Dimension(output.getWidth(), output.getHeight()));
        dev.setFullScreenWindow(window);

        final DisplayMode disp = isSupported(new DisplayMode(output.getWidth(),
                                                             output.getHeight(),
                                                             depth,
                                                             output.getRate()));
        if (disp == null)
        {
            throw new LionEngineException(ScreenFullAwt.ERROR_UNSUPPORTED_FULLSCREEN
                                          + formatResolution(output, depth)
                                          + getSupportedResolutions());
        }
        if (!dev.isDisplayChangeSupported())
        {
            throw new LionEngineException(ScreenFullAwt.ERROR_SWITCH);
        }
        dev.setDisplayMode(disp);
        window.validate();

        ToolsAwt.createBufferStrategy(window, conf);
        buf = window.getBufferStrategy();

        // Set input listeners
        componentForKeyboard = frame;
        componentForMouse = window;
        componentForCursor = window;
        frame.validate();
    }
19576
function() {
    var self = this;
    if (!this.get('screen')) {
      this.set('screen', new Screen());
    }
    this.updateTextLines();
    this.observe(this, 'change:text change:width', function() {
      self.updateTextLines();
    });
    this.observe(this, 'change:visible change:textLines change:height', function() {
      self.render();
    });
    this.render();
  }
896776
function Toolbar() {
		var buttons = {};

		/*jslint unparam: true*//* allow the unused param title until Toolbar rewrite*/
		function add(id, text, title, fn) {
			if (!buttons[id]) {
				var button = renderer.text(
					text,
					0,
					0
				)
				.css(options.toolbar.itemStyle)
				.align({
					align: 'right',
					x: -marginRight - 20,
					y: plotTop + 30
				})
				.on('click', fn)
				/*.on('touchstart', function(e) {
					e.stopPropagation(); // don't fire the container event
					fn();
				})*/
				.attr({
					align: 'right',
					zIndex: 20
				})
				.add();
				buttons[id] = button;
			}
		}
		/*jslint unparam: false*/

		function remove(id) {
			discardElement(buttons[id].element);
			buttons[id] = null;
		}

		// public
		return {
			add: add,
			remove: remove
		};
	}
786370
function fullscreenchangeHandler() {
        viewerAPI.fire('fullscreenchange');
        if (isFullscreen()) {
            $el.addClass('crocodoc-fullscreen');
            viewerAPI.fire('fullscreenenter');
        } else {
            $el.removeClass('crocodoc-fullscreen');
            viewerAPI.fire('fullscreenexit');
        }
    }
523359
def select_rect(action, action_space, select_add, screen, screen2):
  """"""
  select = spatial(action, action_space).unit_selection_rect
  out_rect = select.selection_screen_coord.add()
  screen_rect = point.Rect(screen, screen2)
  screen_rect.tl.assign_to(out_rect.p0)
  screen_rect.br.assign_to(out_rect.p1)
  select.selection_add = bool(select_add)