Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Firefox OS fixes #38

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 2 commits into from
Sep 12, 2015
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 5 additions & 1 deletion 6 user_agents/parsers.py
Original file line number Diff line number Diff line change
Expand Up @@ -62,6 +62,7 @@
'Windows RT',
'Windows CE',
'Windows Mobile',
'Firefox OS',
)

TOUCH_CAPABLE_DEVICE_FAMILIES = (
Expand Down Expand Up @@ -164,6 +165,8 @@ def is_tablet(self):
return True
if self.os.family.startswith('Windows RT'):
return True
if self.os.family == 'Firefox OS' and 'Mobile' not in self.browser.family:
return True
return False

@property
Expand All @@ -175,7 +178,8 @@ def is_mobile(self):
return True
# Device is considered Mobile OS is Android and not tablet
# This is not fool proof but would have to suffice for now
if self.os.family == 'Android' and not self.is_tablet:
if ((self.os.family == 'Android' or self.os.family == 'Firefox OS')
and not self.is_tablet):
return True
if self.os.family == 'BlackBerry OS' and self.device.family != 'Blackberry Playbook':
return True
Expand Down
Morty Proxy This is a proxified and sanitized view of the page, visit original site.