{ "id": "97672", "key": "ALOY-117", "fields": { "issuetype": { "id": "4", "description": "An improvement or enhancement to an existing feature or task.", "name": "Improvement", "subtask": false }, "project": { "id": "11113", "key": "ALOY", "name": "Alloy", "projectCategory": { "id": "10400", "description": "Tools for developing applications", "name": "Tooling" } }, "fixVersions": [ { "id": "14171", "description": "", "name": "2012 Sprint 19", "archived": true, "released": true, "releaseDate": "2012-09-24" }, { "id": "14176", "description": "Release 3.0.0", "name": "Release 3.0.0", "archived": false, "released": true, "releaseDate": "2012-12-13" } ], "resolution": { "id": "1", "description": "A fix for this issue is checked into the tree and tested.", "name": "Fixed" }, "resolutiondate": "2012-09-12T17:10:35.000+0000", "created": "2012-07-19T15:38:19.000+0000", "priority": { "name": "Low", "id": "4" }, "labels": [], "versions": [], "issuelinks": [ { "id": "19006", "type": { "id": "10020", "name": "Depends", "inward": "is dependent of", "outward": "depends on" }, "outwardIssue": { "id": "97662", "key": "TIMOB-10043", "fields": { "summary": "Android: Add \"physicalSizeCategory\" to Ti.Platform.displayCaps", "status": { "description": "The issue is considered finished, the resolution is correct. Issues which are closed can be reopened.", "name": "Closed", "id": "6", "statusCategory": { "id": 3, "key": "done", "colorName": "green", "name": "Done" } }, "priority": { "name": "Low", "id": "4" }, "issuetype": { "id": "2", "description": "A new feature of the product, which has yet to be developed.", "name": "New Feature", "subtask": false } } } }, { "id": "19995", "type": { "id": "10003", "name": "Relates", "inward": "relates to", "outward": "relates to" }, "inwardIssue": { "id": "99404", "key": "TIMOB-10492", "fields": { "summary": "MobileWeb: Need a way to determine if the browser is on tablet or handset", "status": { "description": "The issue is considered finished, the resolution is correct. Issues which are closed can be reopened.", "name": "Closed", "id": "6", "statusCategory": { "id": 3, "key": "done", "colorName": "green", "name": "Done" } }, "priority": { "name": "Low", "id": "4" }, "issuetype": { "id": "1", "description": "A problem which impairs or prevents the functions of the product.", "name": "Bug", "subtask": false } } } } ], "assignee": null, "updated": "2018-03-07T22:26:03.000+0000", "status": { "description": "A resolution has been taken, and it is awaiting verification by reporter. From here issues are either reopened, or are closed.", "name": "Resolved", "id": "5", "statusCategory": { "id": 3, "key": "done", "colorName": "green", "name": "Done" } }, "components": [ { "id": "12329", "name": "Runtime", "description": "Generic bucket for uncategorized runtime issues" } ], "description": "Here's a general idea of how it will be performed on each platform. The code below is not what will be used. It has been expanded for clarity and will be more concise and performant in practice, and obviously platform-safe. \r\n\r\nh4. iOS (done)\r\n\r\n{code:javascript}\r\nvar isIosTablet = Ti.Platform.osname === 'ipad';\r\n{code}\r\n\r\nh4. Android (done)\r\n\r\n{code:javascript}\r\nvar isAndroidTablet = Ti.Platform.osname === 'android' && \r\n (Ti.Platform.displayCaps.physicalSizeCategory === 'large' ||\r\n Ti.Platform.displayCaps.physicalSizeCategory === 'xlarge');\r\n{code}\r\n\r\nThis code relies on the linked issue. I put a PR in place to expose this Android API. Until this API is processed, I will put together an Android module that we can use in Alloy in the meantime.\r\n\r\n*UPDATE:* Android module found here: https://github.com/tonylukasavage/physicalSizeCategory\r\n\r\n\r\nh4. Mobileweb (not done)\r\n\r\n{code:javascript}\r\n// we may have to resort to just using the Ti.Platform.displayCaps.platformHeight(Width)\r\n// until an API can be exposed from Mobileweb to allow better size detection.\r\nvar isMobilewebTablet = !(Math.max(\r\n Ti.Platform.displayCaps.platformHeight,\r\n Ti.Platform.displayCaps.platformWidth\r\n) < 700);\r\n{code}\r\n", "attachment": [], "flagged": false, "summary": "Identify is a device is \"handheld\" or \"tablet\" on all supported platforms", "creator": { "name": "tlukasavage", "key": "tlukasavage", "displayName": "Tony Lukasavage", "active": true, "timeZone": "America/Los_Angeles" }, "subtasks": [], "reporter": { "name": "tlukasavage", "key": "tlukasavage", "displayName": "Tony Lukasavage", "active": true, "timeZone": "America/Los_Angeles" }, "environment": null, "comment": { "comments": [ { "id": "216691", "author": { "name": "rmcmahon", "key": "rmcmahon", "displayName": "Russell McMahon", "active": true, "timeZone": "America/Los_Angeles" }, "body": "Setting a due date. We need to keep following up to make sure Mobile Web implements the feature.", "updateAuthor": { "name": "rmcmahon", "key": "rmcmahon", "displayName": "Russell McMahon", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2012-08-28T20:14:33.000+0000", "updated": "2012-08-28T20:14:33.000+0000" }, { "id": "216722", "author": { "name": "tlukasavage", "key": "tlukasavage", "displayName": "Tony Lukasavage", "active": true, "timeZone": "America/Los_Angeles" }, "body": "I have been following up. Follow the progress in the linked TIMOB ticket: TIMOB-10492", "updateAuthor": { "name": "tlukasavage", "key": "tlukasavage", "displayName": "Tony Lukasavage", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2012-08-29T04:26:57.000+0000", "updated": "2012-08-29T04:26:57.000+0000" }, { "id": "218443", "author": { "name": "tlukasavage", "key": "tlukasavage", "displayName": "Tony Lukasavage", "active": true, "timeZone": "America/Los_Angeles" }, "body": "Bryan has given some advice in the linked ticket. I will implement it and close the ticket.", "updateAuthor": { "name": "tlukasavage", "key": "tlukasavage", "displayName": "Tony Lukasavage", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2012-09-11T14:51:04.000+0000", "updated": "2012-09-11T14:51:04.000+0000" } ], "maxResults": 3, "total": 3, "startAt": 0 } } }