The pick-handling callback function.
960624
function (o) {
            // The input argument is either an Event or a TapRecognizer. Both have the same properties for determining
            // the mouse or tap location.
            var x = o.clientX,
                y = o.clientY;

            var redrawRequired = highlightedItems.length > 0; // must redraw if we de-highlight previously picked items

            // De-highlight any previously highlighted placemarks.
            for (var h = 0; h < highlightedItems.length; h++) {
                highlightedItems[h].highlighted = false;
            }
            highlightedItems = [];

            // Perform the pick. Must first convert from window coordinates to canvas coordinates, which are
            // relative to the upper left corner of the canvas rather than the upper left corner of the page.
            var pickList = wwd.pick(wwd.canvasCoordinates(x, y));
            //console.log(wwd.frameStatistics.frameTime);
            if (pickList.objects.length > 0) {
                redrawRequired = true;
            }

            // Highlight the items picked by simply setting their highlight flag to true.
            if (pickList.objects.length > 0) {
                for (var p = 0; p < pickList.objects.length; p++) {
                    pickList.objects[p].userObject.highlighted = true;

                    // Keep track of highlighted items in order to de-highlight them later.
                    highlightedItems.push(pickList.objects[p].userObject);
                }
            }

            // Update the window if we changed anything.
            if (redrawRequired) {
                wwd.redraw(); // redraw to make the highlighting changes take effect on the screen
            }
        }
44805
function handleMouseEvent(deck, type, event) {
  let callback;
  switch (type) {
    case 'click':
      // Hack: because we do not listen to pointer down, perform picking now
      deck._lastPointerDownInfo = deck.pickObject({
        x: event.pixel.x,
        y: event.pixel.y
      });
      callback = deck._onEvent;
      break;

    case 'mousemove':
      callback = deck._onPointerMove;
      break;

    case 'mouseout':
      callback = deck._onPointerLeave;
      break;

    default:
      return;
  }

  callback({
    type,
    offsetCenter: event.pixel,
    srcEvent: event
  });
}
730090
@Override
    protected void doPick()
    {
        if (mCollidables.size() > 0)
        {
            GVRPickedObject[] picked = null;

            synchronized (mCollidables)
            {
                picked = pickBounds(mScene, mCollidables);
            }
            if (mPickClosest && (picked.length > 0))
            {
                GVRPickedObject closest = null;
                float dist = 100000.0f;
                for (GVRPickedObject hit : picked)
                {
                    if ((hit != null) && (hit.hitDistance < dist))
                    {
                        dist = hit.hitDistance;
                        closest = hit;
                    }
                }
                if (closest != null)
                {
                    picked = new GVRPickedObject[] { closest };
                }
                else
                {
                    picked = sEmptyList;
                }
            }
            generatePickEvents(picked);
        }
    }
927410
function pickReverseEach( reverse, node, callback ) {
        var test = type.call( node, 'Undefined' ) ||
            node==='false' ||
            node===false ||
            (
                type.call( node, 'Boolean' ) && 
                !node.valueOf()
            );

        if ( test ) {
            pickReverse.call( this, reverse, true, callback );
        }
        else if ( type.call( node.isBoolean, 'Function' ) ) {
            if ( node.isBoolean.tick ) {

            }
            else {
                pickReverse.call( this, reverse, ( ( node.isBoolean() && !node.valueOf() ) || !node ), callback );
            }
        }
        else {
            pickReverse.call( this, reverse, !node, callback );
        }
    }
1073883
function scrape(iterator, data, params, cb) {
    var $ = artoo.$,
        scraped = [],
        loneSelector = !!data.attr || !!data.method || data.scrape ||
                       typeof data === 'string' ||
                       typeof data === 'function';

    params = params || {};

    // Transforming to selector
    var $iterator;
    if (typeof iterator === 'function')
      $iterator = $(iterator($));
    else
      $iterator = $(iterator);

    // Iteration
    $iterator.each(function(i) {
      var item = {},
          p;

      // TODO: figure iteration scope elsewhere for scrape recursivity
      if (loneSelector)
        item = (typeof data === 'object' && 'scrape' in data) ?
          scrape(
            (data.sel ? $(this).find(data.sel) : $(this))
              .find(data.scrape.iterator),
            data.scrape.data,
            data.scrape.params
          ) :
          step(data, this);
      else
        for (p in data) {
          item[p] = (typeof data[p] === 'object' && 'scrape' in data[p]) ?
            scrape(
              (data[p].sel ? $(this).find(data[p].sel) : $(this))
                .find(data[p].scrape.iterator),
              data[p].scrape.data,
              data[p].scrape.params
            ) :
            step(data[p], this);
        }

      scraped.push(item);

      // Breaking if limit i attained
      return !params.limit || i < params.limit - 1;
    });

    scraped = params.one ? scraped[0] : scraped;

    // Triggering callback
    if (typeof cb === 'function')
      cb(scraped);

    // Returning data
    return scraped;
  }
153902
function pick(obj, arr) {
  var res = {};
  for (var i = 0, len = arr.length; i < len; i++) {
    var prop = arr[i];
    if (prop in obj) {
      res[prop] = obj[prop];
    }
  }
  return res;
}
774098
function pick() {
                if (this._remainingOptions.length === 0) {
                  this._remainingOptions = clone(this._originalOptions);
                }

                var index = Math.floor(Math.random() * this._remainingOptions.length);
                return this._remainingOptions.splice(index, 1)[0];
              }
1050028
def unpickle_dict(items):
    ''''''
    pickled_keys = items.pop('_pickled', '').split(',')
    ret = {}
    for key, val in items.items():
        if key in pickled_keys:
            ret[key] = pickle.loads(val)
        else:
            ret[key] = val
    return ret
101582
function() {

                // If it’s already started, do nothing.
                if ( STATE && STATE.start ) return P


                // Update the picker states.
                STATE.methods = {}
                STATE.start = true
                STATE.open = false
                STATE.type = ELEMENT.type


                // Confirm focus state, convert into text input to remove UA stylings,
                // and set as readonly to prevent keyboard popup.
                ELEMENT.autofocus = ELEMENT == getActiveElement()
                ELEMENT.readOnly = !SETTINGS.editable
                ELEMENT.id = ELEMENT.id || STATE.id
                if ( ELEMENT.type != 'text' ) {
                    ELEMENT.type = 'text'
                }


                // Create a new picker component with the settings.
                P.component = new COMPONENT(P, SETTINGS)


                // Create the picker root with a holder and then prepare it.
                P.$root = $( PickerConstructor._.node('div', createWrappedComponent(), CLASSES.picker, 'id="' + ELEMENT.id + '_root" tabindex="0"') )
                prepareElementRoot()


                // If there’s a format for the hidden input element, create the element.
                if ( SETTINGS.formatSubmit ) {
                    prepareElementHidden()
                }


                // Prepare the input element.
                prepareElement()


                // Insert the root as specified in the settings.
                if ( SETTINGS.container ) $( SETTINGS.container ).append( P.$root )
                else $ELEMENT.after( P.$root )


                // Bind the default component and settings events.
                P.on({
                    start: P.component.onStart,
                    render: P.component.onRender,
                    stop: P.component.onStop,
                    open: P.component.onOpen,
                    close: P.component.onClose,
                    set: P.component.onSet
                }).on({
                    start: SETTINGS.onStart,
                    render: SETTINGS.onRender,
                    stop: SETTINGS.onStop,
                    open: SETTINGS.onOpen,
                    close: SETTINGS.onClose,
                    set: SETTINGS.onSet
                })


                // Once we’re all set, check the theme in use.
                IS_DEFAULT_THEME = isUsingDefaultTheme( P.$root.children()[ 0 ] )


                // If the element has autofocus, open the picker.
                if ( ELEMENT.autofocus ) {
                    P.open()
                }


                // Trigger queued the “start” and “render” events.
                return P.trigger( 'start' ).trigger( 'render' )
            }
360468
function scrape(dyn, url, scope, selector) {
  return new Promise(function(dresolve, dreject) {
    var scraper = dyn ? dx : x;
    scraper(url, scope, selector)(function(err, res) {
      dresolve(res);
    })
  })
}
375666
function pickValue( ref, node, success, complete ) {

        if ( !ref ) {
            console.error('pickValue !ref return');
            return;
        }

        var events = {};
        $$.defineEvent( events );

        events.eventListener({
            // limit: 1,
            self: this,
            action: 'success',
            listen: success
        });

        events.eventListener({
            self: this,
            action: 'complete',
            listen: complete
        });

        ref.exec({ node: node }, events );
    }
123767
function pick(obj, select) {
  var result = {};
  if (typeof select === 'string') {
    select = [].slice.call(arguments, 1);
  }
  var len = select.length;
  for (var i = 0; i < len; i++) {
    var key = select[i];
    if (key in obj) {
      result[key] = obj[key];
    }
  }
  return result;
}
26354
def preserve_selection():
    
    sl = cmds.ls(sl=True)
    try:
        yield
    finally:
        cmds.select(sl, replace=True)
1269754
function pickParams(params, keys) {
    params = _.cloneDeep(params);
    // decamelize all options
    for (var key in params) {
        var value = params[key];
        delete params[key];
        // TODO: handle this inconsistency consistently in the library :(
        // 'base64String': introduced by 'image.upload()'
        if (["base64String"].indexOf(key) === -1) {
            key = decamelize(key, "_");
        }
        params[key] = value;
    }
    if (SETTINGS.enforce_params_filter) {
        return _.pick(params, keys);
    }
    return params;
}
25424
function pickoutValue(target, str) {
  const strDepth = str.split('.');
  const newTarget = target[strDepth[0]];
  if (newTarget === undefined) throw new Error('Cannot find the value');
  if (strDepth.length === 1) return newTarget;
  return pickoutValue(newTarget, strDepth.splice(1).join('.'));
}
1221304
function cleanSelector (o) {
	var a = o.replace(/\s*,\s*/g, ",").replace(/\n/g, "").split(',');

	a = a.filter( function( item, index, inputArray ) {
		return inputArray.indexOf(item) == index;
	});

	return a.join(',\n');
}
1061793
function pick(obj, props) {
    props = to_1.toArray(props, []);
    if (!is_1.isValue(obj) || !is_1.isObject(obj) || !props || !props.length)
        return obj;
    return props.reduce(function (a, c) {
        var val = get(obj, c, undefined);
        if (is_1.isUndefined(val))
            return a;
        return set(a, c, val);
    }, {});
}