Detects a Windows Phone 10 device (in mobile browsing mode).
554796
function DetectWindowsPhone10()
   {
      if (stripos($this->useragent, $this->deviceWinPhone10) > -1)
         return $this->true; 
      else
         return $this->false; 
   }
777948
public boolean detectNintendo() {

        if ((userAgent.indexOf(deviceNintendo) != -1)
            || (userAgent.indexOf(deviceWii) != -1)
            || (userAgent.indexOf(deviceNintendoDs) != -1)) {
            return true;
        }
        return false;
    }
708513
public function detect()
  {
    $detected = true;
    if ( empty( $this->ua ) )
    {
      $detected = false;
    }
    else
    {
      // If it's not any of the common browsers, perhaps it's something mobile.
      if ( !$this->isMSIE() && !$this->isChrome() && !$this->isFirefox() && !$this->isSafari() && !$this->isEdge() && !$this->isOpera() )
      {
        if ( !$this->isOtherMobile() )
        {
          $detected = false;
        }
      }
      else
      {
        // If it's one of the default browsers, check to see if it's the mobile version.
        if ( !$this->isChromeMobile() && !$this->isSafariMobile() && !$this->isFirefoxMobile() && !$this->isOperaMobile() )
        {
          // If not, check for other mobile conditions, otherwise mark as definitely not mobile.
          if ( !$this->isOtherMobile() )
          {
            $this->mobile = false;
            $this->touch = false;
            $this->android = false;
            $this->ios = false;
            $this->tablet = false;
            $this->phone = false;
          }
        }
      }
    }

    if ( $detected )
    {
      // Deal with Width/Height
      if ( !$this->width )
      {
        $this->width = ( $this->phone ) ? $this->defaultSize[ 'phone' ][ 'width' ] : $this->defaultSize['tablet']['width'];
        $this->height = ( $this->phone ) ? $this->defaultSize[ 'phone' ][ 'height' ] : $this->defaultSize['tablet']['height'];
      }

      // Deal with Browser
      if ( $this->isModern() )
      {
        $browser = 'modern';
      }
      elseif($this->isFallback())
      {
        $browser = 'fallback';
      }
      else
      {
        $browser = 'baseline';
      }

      // Return the array that DeviceFeatureInfo expects.
      return array(
        'hidpi'       => false,
        'width'       => $this->width,
        'height'      => $this->height,
        'low_speed'   => false,
        'low_battery' => false,
        'metered'     => $this->metered,
        'browser'     => $browser,
        'touch'       => $this->touch,
        'android'     => $this->android,
        'ios'         => $this->ios,
        'user-agent'  => $this->ua
      );
    }

    return null;
  }
680483
function() {
		var appVersion = navigator.appVersion;
		mfp.isIE7 = appVersion.indexOf("MSIE 7.") !== -1; 
		mfp.isIE8 = appVersion.indexOf("MSIE 8.") !== -1;
		mfp.isLowIE = mfp.isIE7 || mfp.isIE8;
		mfp.isAndroid = (/android/gi).test(appVersion);
		mfp.isIOS = (/iphone|ipad|ipod/gi).test(appVersion);
		mfp.supportsTransition = supportsTransitions();

		// We disable fixed positioned lightbox on devices that don't handle it nicely.
		// If you know a better way of detecting this - let me know.
		mfp.probablyMobile = (mfp.isAndroid || mfp.isIOS || /(Opera Mini)|Kindle|webOS|BlackBerry|(Opera Mobi)|(Windows Phone)|IEMobile/i.test(navigator.userAgent) );
		_document = $(document);

		mfp.popupsCache = {};
	}
87171
def detectMaemoTablet(self):
        
        if UAgentInfo.maemo in self.__userAgent:
            return True

        return UAgentInfo.linux in self.__userAgent \
            and UAgentInfo.deviceTablet in self.__userAgent \
            and not self.detectWebOSTablet() \
            and not self.detectAndroid()
148230
function DetectBlackBerry()
   {
       if ((stripos($this->useragent, $this->deviceBB) > -1) ||
          (stripos($this->httpaccept, $this->vndRIM) > -1))
         return $this->true;
      if ($this->DetectBlackBerry10Phone() == $this->true) 
         return $this->true;       
       else
         return $this->false; 
   }
855273
def detectSailfishPhone(self):
        
        if self.detectSailfish() \
           and UAgentInfo.mobile in self.__userAgent:
            return True

        return False
473682
function deviceFound(device)
	{
		// Parse advertisement data record.
		// TODO: Move to startScan.
		evothings.ble.parseAdvertisementData(device)

		// For debugging, print advertisement data.
		//console.log(JSON.stringify(device.advertisementData))

		// Alternative way to identify the device by advertised service UUID.
		/*
		if (device.advertisementData.kCBAdvDataServiceUUIDs.indexOf(
			'0000aa10-0000-1000-8000-00805f9b34fb') > -1)
		{
			showMessage('Found the TI SensorTag!')
		}
		*/

		if (device.advertisementData.kCBAdvDataLocalName == 'CC2650 SensorTag')
		{
			showMessage('Found the TI SensorTag!')

			// Stop scanning.
			evothings.ble.stopScan()

			// Connect.
			connectToDevice(device)
		}
	}
164404
def detectBlackBerryTouch(self):
        
        return UAgentInfo.deviceBBStorm in self.__userAgent \
                or UAgentInfo.deviceBBTorch in self.__userAgent \
                or UAgentInfo.deviceBBBoldTouch in self.__userAgent \
                or UAgentInfo.deviceBBCurveTouch in self.__userAgent
1299393
function DetectIos()
   {
      if (($this->DetectIphoneOrIpod() == $this->true) ||
        ($this->DetectIpad() == $this->true))
         return $this->true; 
      else
         return $this->false;
   }
311045
public function detectSystem()
    {
        $detect      = new MobileDetect();
        $linkDefault = $this->data['default'];
        if ($detect->is('iOS')) {
            $this->link = isset($this->data['ios']) ? $this->data['ios'] : $linkDefault;
        } elseif ($detect->is('AndroidOS')) {
            $this->link = isset($this->data['android']) ? $this->data['android'] : $linkDefault;
        } elseif ($detect->is('BlackBerryOS')) {
            $this->link = isset($this->data['black_berry']) ? $this->data['black_berry'] : $linkDefault;
        } elseif ($detect->is('PalmOS')) {
            $this->link = isset($this->data['palm']) ? $this->data['palm'] : $linkDefault;
        } elseif ($detect->is('WindowsMobileOS') || $detect->is('WindowsPhoneOS')) {
            $this->link = isset($this->data['windows_mobile']) ? $this->data['windows_mobile'] : $linkDefault;
        } elseif ($detect->is('MeeGoOS')) {
            $this->link = isset($this->data['mee_go']) ? $this->data['mee_go'] : $linkDefault;
        } elseif ($detect->is('MaemoOS')) {
            $this->link = isset($this->data['mae_mo']) ? $this->data['mae_mo'] : $linkDefault;
        } elseif ($detect->is('JavaOS')) {
            $this->link = isset($this->data['java']) ? $this->data['java'] : $linkDefault;
        } elseif ($detect->is('webOS')) {
            $this->link = isset($this->data['web_os']) ? $this->data['web_os'] : $linkDefault;
        } elseif ($detect->is('badaOS')) {
            $this->link = isset($this->data['bada_os']) ? $this->data['bada_os'] : $linkDefault;
        } elseif ($detect->is('BREWOS')) {
            $this->link = isset($this->data['brewos']) ? $this->data['brewos'] : $linkDefault;
        } else {
            $this->link = $linkDefault;
        }

        return $this;
    }
89933
public boolean detectMobileQuick() {

        //Let's exclude tablets
        if (isTierTablet) {
            return false;
        }
        //Most mobile browsing is done on smartphones
        if (detectSmartphone()) {
            return true;
        }

        //Catch-all for many mobile devices
        if (userAgent.indexOf(mobile) != -1) {
            return true;
        }

        if (detectOperaMobile()) {
            return true;
        }

        //We also look for Kindle devices
        if (detectKindle() || detectAmazonSilk()) {
            return true;
        }

        if (detectWapWml() || detectMidpCapable() || detectBrewDevice()) {
            return true;
        }

        if ((userAgent.indexOf(engineNetfront) != -1) || (userAgent.indexOf(engineUpBrowser) != -1)) {
            return true;
        }

        return false;
    }
946680
function() {

                // Adapted from http://www.detectmobilebrowsers.com
                var ua = navigator.userAgent || navigator.vendor || window.opera;

                // Checks for iOs, Android, Blackberry, Opera Mini, and Windows mobile devices
                return (/iPhone|iPod|iPad|Silk|Android|BlackBerry|Opera Mini|IEMobile/).test(ua);

            }
1066196
function DetectTizen()
   {
      if ((stripos($this->useragent, $this->deviceTizen) > -1)
			&& (stripos($this->useragent, $this->mobile) > -1))
         return $this->true; 
      else
         return $this->false; 
   }
127656
function DetectTierIphone()
   {
      if ($this->initCompleted == $this->true ||
          $this->isTierIphone == $this->true)
         return $this->isTierIphone;

      if (($this->DetectIphoneOrIpod() == $this->true)
			|| ($this->DetectAndroidPhone() == $this->true)
			|| ($this->DetectWindowsPhone() == $this->true)
			|| ($this->DetectBlackBerry10Phone() == $this->true)
			|| ($this->DetectPalmWebOS() == $this->true)
			|| ($this->DetectBada() == $this->true)
			|| ($this->DetectTizen() == $this->true)
			|| ($this->DetectFirefoxOSPhone() == $this->true)
			|| ($this->DetectSailfishPhone() == $this->true)
			|| ($this->DetectUbuntuPhone() == $this->true)
			|| ($this->DetectGamingHandheld() == $this->true))
         return $this->true; 
      
      //Note: BB10 phone is in the previous paragraph
      if (($this->DetectBlackBerryWebKit() == $this->true) &&
		($this->DetectBlackBerryTouch() == $this->true))
         return $this->true;
      
      else
         return $this->false; 
   }
315954
def detectWebOSTV(self):
        
        return UAgentInfo.deviceWebOStv in self.__userAgent \
            and UAgentInfo.smartTV2 in self.__userAgent
497276
def detect_firefox_o_s_phone()

      if (detect_ios() || detect_android() || detect_sailfish())
        return false
      end

      if ((user_agent.include?(ENGINE_FIREFOX)) && (user_agent.include?(MOBILE)))
        return true
      end

      return false
    end