Skip to content

Commit

Permalink
Adds detection for Formovie brand
Browse files Browse the repository at this point in the history
  • Loading branch information
liviuconcioiu committed Dec 22, 2024
1 parent d98ad25 commit b03a78b
Show file tree
Hide file tree
Showing 4 changed files with 28 additions and 1 deletion.
2 changes: 1 addition & 1 deletion DeviceDetector.php
Original file line number Diff line number Diff line change
Expand Up @@ -1070,7 +1070,7 @@ protected function parseDevice(): void
/**
* All devices that contain Andr0id in string are assumed to be a tv
*/
if ($this->matchUserAgent('Andr0id|(?:Android(?: UHD)?|Google) TV|\(lite\) TV|BRAVIA| TV$')) {
if ($this->matchUserAgent('Andr0id|(?:Android(?: UHD)?|(<!Xming )Google) TV|\(lite\) TV|BRAVIA| TV$')) {
$this->device = AbstractDeviceParser::DEVICE_TYPE_TV;
}

Expand Down
1 change: 1 addition & 0 deletions Parser/Device/AbstractDeviceParser.php
Original file line number Diff line number Diff line change
Expand Up @@ -647,6 +647,7 @@ abstract class AbstractDeviceParser extends AbstractParser
'44' => 'Four Mobile',
'F0' => 'Fonos',
'F2' => 'FORME',
'FRM' => 'Formovie',
'F5' => 'Formuler',
'FR' => 'Forstar',
'RF' => 'Fortis',
Expand Down
18 changes: 18 additions & 0 deletions Tests/fixtures/peripheral.yml
Original file line number Diff line number Diff line change
Expand Up @@ -1630,3 +1630,21 @@
model: MoGo Pro
os_family: Android
browser_family: Chrome
-
user_agent: Mozilla/5.0 (Linux; Android 11; Xming Google TV Build/RTM7.230903.079; wv) AppleWebKit/537.36 (KHTML, like Gecko) Version/4.0 Chrome/129.0.6668.102 Mobile Safari/537.36
os:
name: Android TV
version: "11"
platform: ""
client:
type: browser
name: Chrome Webview
version: 129.0.6668.102
engine: Blink
engine_version: 129.0.6668.102
device:
type: peripheral
brand: Formovie
model: Xming
os_family: Android
browser_family: Chrome
8 changes: 8 additions & 0 deletions regexes/device/mobiles.yml
Original file line number Diff line number Diff line change
Expand Up @@ -36379,6 +36379,14 @@ Yoka TV:
device: 'tv'
model: 'KB2 Pro'

# Formovie (https://www.formovie.com)
Formovie:
regex: 'Xming'
device: 'peripheral'
models:
- regex: 'Xming Google TV(?:[);/ ]|$)'
model: 'Xming' # Xming Page One or Xming Episode One

# Formuler (formuler.tv)
Formuler:
regex: 'Formuler[ _]|(?:S_TURBO_PRO)(?:[);/ ]|$)'
Expand Down

0 comments on commit b03a78b

Please sign in to comment.