{ "id": "160802", "key": "TIMOB-23521", "fields": { "issuetype": { "id": "1", "description": "A problem which impairs or prevents the functions of the product.", "name": "Bug", "subtask": false }, "project": { "id": "10153", "key": "TIMOB", "name": "Titanium SDK/CLI", "projectCategory": { "id": "10100", "description": "Titanium and related SDKs used in application development", "name": "Client" } }, "fixVersions": [ { "id": "16980", "description": "New V8", "name": "Release 6.0.0", "archived": false, "released": true, "releaseDate": "2016-11-15" } ], "resolution": { "id": "1", "description": "A fix for this issue is checked into the tree and tested.", "name": "Fixed" }, "resolutiondate": "2016-09-11T16:56:36.000+0000", "created": "2016-06-06T07:55:02.000+0000", "priority": { "name": "Critical", "id": "1" }, "labels": [ "ti.facebook" ], "versions": [], "issuelinks": [], "assignee": { "name": "hknoechel", "key": "hansknoechel", "displayName": "Hans Knöchel", "active": true, "timeZone": "Europe/Berlin" }, "updated": "2016-09-16T22:02:48.000+0000", "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" } }, "components": [ { "id": "10202", "name": "Android", "description": "Android Platform" }, { "id": "10206", "name": "iOS", "description": "iOS Platform" } ], "description": "The facebook module does not open the native share dialog, it only opens the web version in a webview.\r\n\r\nIt should open the sharesheet ie. https://developers.facebook.com/docs/sharing/ios\r\n\r\nCode to reproduce is standard boilerplate from the docs:\r\nfb.presentShareDialog({\r\n link: 'https://appcelerator.com/',\r\n title: 'great product',\r\n description: 'Titanium is a great product', \r\n picture: 'http://www.appcelerator.com/wp-content/uploads/scale_triangle1.png'\r\n });", "attachment": [], "flagged": false, "summary": "Ti.Facebook - presentShareDialog does not open native app, only webview", "creator": { "name": "bearus", "key": "bearus", "displayName": "Be Rushton", "active": true, "timeZone": "Australia/Brisbane" }, "subtasks": [], "reporter": { "name": "bearus", "key": "bearus", "displayName": "Be Rushton", "active": true, "timeZone": "Australia/Brisbane" }, "environment": null, "closedSprints": [ { "id": 707, "state": "closed", "name": "2016 Sprint 19 SDK", "startDate": "2016-09-10T00:17:15.164Z", "endDate": "2016-09-24T00:17:00.000Z", "completeDate": "2016-09-26T05:17:04.253Z", "originBoardId": 114 }, { "id": 685, "state": "closed", "name": "2016 Sprint 16 SDK", "startDate": "2016-07-30T00:40:02.939Z", "endDate": "2016-08-13T00:40:00.000Z", "completeDate": "2016-08-15T08:00:33.056Z", "originBoardId": 114 } ], "comment": { "comments": [ { "id": "387631", "author": { "name": "nsalahin", "key": "nsalahin", "displayName": "Nazmus Salahin", "active": true, "timeZone": "Asia/Dhaka" }, "body": "Hello,\r\n\r\nThanks for reporting. Native share dialog will not be opened if {{Facebook}} app is not installed in the device. So, please make sure that {{Facebook}} app is installed in the device and let us know.\r\n\r\nThanks in advance", "updateAuthor": { "name": "nsalahin", "key": "nsalahin", "displayName": "Nazmus Salahin", "active": true, "timeZone": "Asia/Dhaka" }, "created": "2016-06-06T08:38:26.000+0000", "updated": "2016-06-06T08:38:26.000+0000" }, { "id": "387639", "author": { "name": "bearus", "key": "bearus", "displayName": "Be Rushton", "active": true, "timeZone": "Australia/Brisbane" }, "body": "Doesn't matter if native app is installed or not. ", "updateAuthor": { "name": "bearus", "key": "bearus", "displayName": "Be Rushton", "active": true, "timeZone": "Australia/Brisbane" }, "created": "2016-06-06T12:48:02.000+0000", "updated": "2016-06-06T12:48:02.000+0000" }, { "id": "387640", "author": { "name": "bearus", "key": "bearus", "displayName": "Be Rushton", "active": true, "timeZone": "Australia/Brisbane" }, "body": "Facebook changed the way a lot of their code worked when iOS 9 came out last year. Older versions of the module still open the native app but things changed in the newer Facebook sdk ", "updateAuthor": { "name": "bearus", "key": "bearus", "displayName": "Be Rushton", "active": true, "timeZone": "Australia/Brisbane" }, "created": "2016-06-06T12:50:55.000+0000", "updated": "2016-06-06T12:50:55.000+0000" }, { "id": "390898", "author": { "name": "hknoechel", "key": "hansknoechel", "displayName": "Hans Knöchel", "active": true, "timeZone": "Europe/Berlin" }, "body": "Similar to the login-process, the native Facebook SDK on iOS 9+ decides internally which behavior to use. Since the app-switching in iOS9+ requires the user to confirm the switch, they (currently) prefer opening the safari-dialog for those operations. We follow their best-practices, so if you see it as an issue, please follow-up with Facebook. Thanks!", "updateAuthor": { "name": "hknoechel", "key": "hansknoechel", "displayName": "Hans Knöchel", "active": true, "timeZone": "Europe/Berlin" }, "created": "2016-07-18T10:59:31.000+0000", "updated": "2016-07-18T10:59:31.000+0000" }, { "id": "390900", "author": { "name": "bearus", "key": "bearus", "displayName": "Be Rushton", "active": true, "timeZone": "Australia/Brisbane" }, "body": "Could you give us the option please? Not everyone agrees with the current behaviour. It was available previously and we need to maintain the currently functionality of existing applications.", "updateAuthor": { "name": "bearus", "key": "bearus", "displayName": "Be Rushton", "active": true, "timeZone": "Australia/Brisbane" }, "created": "2016-07-18T11:24:43.000+0000", "updated": "2016-07-18T11:24:43.000+0000" }, { "id": "390901", "author": { "name": "hknoechel", "key": "hansknoechel", "displayName": "Hans Knöchel", "active": true, "timeZone": "Europe/Berlin" }, "body": "As said before, we cannot change Facebook's internal decisions and behavior. I am not sure how I can help you while being restricted by the Facebook SDK.", "updateAuthor": { "name": "hknoechel", "key": "hansknoechel", "displayName": "Hans Knöchel", "active": true, "timeZone": "Europe/Berlin" }, "created": "2016-07-18T11:27:26.000+0000", "updated": "2016-07-18T11:27:26.000+0000" }, { "id": "390902", "author": { "name": "bearus", "key": "bearus", "displayName": "Be Rushton", "active": true, "timeZone": "Australia/Brisbane" }, "body": "Yeah I can see where you are coming from. There does seem to be some ways around it though like this one http://stackoverflow.com/a/35732372/568754. There is plenty of people that disagree with the change.\r\n\r\nIf these workarounds aren't an option is there a way to use an older Facebook SDK? Will the old ti.facebook versions work or has there been too many bug fixes to get them working on Ti 5.3.1.GA and above?", "updateAuthor": { "name": "bearus", "key": "bearus", "displayName": "Be Rushton", "active": true, "timeZone": "Australia/Brisbane" }, "created": "2016-07-18T11:43:52.000+0000", "updated": "2016-07-18T11:43:52.000+0000" }, { "id": "390903", "author": { "name": "hknoechel", "key": "hansknoechel", "displayName": "Hans Knöchel", "active": true, "timeZone": "Europe/Berlin" }, "body": "UPDATE: Actually, I found a way to configure the dialog. There is a property {{mode}} that we could possibly set. I wrapped up a PR here which I'd like you to test:\r\n\r\nPR: https://github.com/appcelerator-modules/ti.facebook/pull/58\r\nRelease (iOS): https://github.com/appcelerator-modules/ti.facebook/releases/tag/ios-5.2.1\r\nRelease (Android): https://github.com/appcelerator-modules/ti.facebook/releases/tag/android-6.0.1\r\n\r\nDemo:\r\n{code:javascript}\r\nvar fb = require(\"ti.facebook\");\r\nfb.initialize();\r\nfb. presentShareDialog({\r\n title: \"Appc rocks!\"\r\n link: \"http://appcelerator.com\",\r\n mode: fb.SHARE_DIALOG_MODE_AUTOMATIC\r\n});\r\n{code}", "updateAuthor": { "name": "hknoechel", "key": "hansknoechel", "displayName": "Hans Knöchel", "active": true, "timeZone": "Europe/Berlin" }, "created": "2016-07-18T11:47:10.000+0000", "updated": "2016-08-01T08:50:43.000+0000" }, { "id": "392099", "author": { "name": "hknoechel", "key": "hansknoechel", "displayName": "Hans Knöchel", "active": true, "timeZone": "Europe/Berlin" }, "body": "PR's merged, titanium_mobile updated.", "updateAuthor": { "name": "hknoechel", "key": "hansknoechel", "displayName": "Hans Knöchel", "active": true, "timeZone": "Europe/Berlin" }, "created": "2016-08-01T08:47:24.000+0000", "updated": "2016-08-01T08:47:24.000+0000" }, { "id": "395227", "author": { "name": "lchoudhary", "key": "lchoudhary", "displayName": "Lokesh Choudhary", "active": true, "timeZone": "America/Los_Angeles" }, "body": "Verified the fix.\r\n\r\nThe {{mode}} property works fine on android.\r\n\r\nEnvironment:\r\nAppc Studio : 4.8.0.201608221113\r\nTi SDK : 6.0.0.v20160901034311\r\nTi CLI : 5.0.9\r\nAlloy : 1.9.1\r\nMAC El Capitan : 10.11.6\r\nAppc NPM : 4.2.7\r\nAppc CLI : 6.0.0-31\r\nNode: 4.4.4\r\nNexus 6 - Android 6.0.1\r\nFacebook Module : 6.0.1\r\n\r\nOn iOS:\r\nWhen I run with facebook iOS module 5.2.1, build fails with:\r\n{code}\r\n[TRACE] : ld: warning: directory not found for option '-F/Users/lchoudhary/Desktop/workspaces/new_test_workspace/test_proj/build/iphone/../../modules/iphone/facebook/5.3.0/platform'\r\n[TRACE] : ld: warning: directory not found for option '-F/Users/lchoudhary/Library/Application Support/Titanium/modules/iphone/facebook/5.3.0/platform'\r\n[TRACE] : ld: warning: directory not found for option '-F/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS9.3.sdk/System/Library/PrivateFrameworks/'\r\n[TRACE] : ld: warning: directory not found for option '-F/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS9.3.sdk/System/Library/PrivateFrameworks/'\r\n[TRACE] : ld: framework not found FBSDKCoreKit\r\n[TRACE] : clang: error: linker command failed with exit code 1 (use -v to see invocation)\r\n[ERROR] : ** BUILD FAILED **\r\n[ERROR] : The following build commands failed:\r\n[ERROR] : \tLd build/Intermediates/test_proj.build/Debug-iphoneos/test_proj.build/Objects-normal/arm64/test_proj normal arm64\r\n[ERROR] : (1 failure)\r\n{code}\r\n\r\nIOS facebook modules 5.2.2 & higher do not seem to have this issue & the {{mode}} property seems to work fine.\r\n\r\nReopening as the fix is in 5.2.1 facebook module.\r\n\r\nUsing:\r\nXcode: 7.3.1\r\nIphone 6 - 9.3.5\r\nIOS facebook module : 5.2.1\r\nAppc Studio : 4.8.0.201608221113\r\nTi SDK : 6.0.0.v20160901034311\r\nAppc CLI : 6.0.0-31\r\n", "updateAuthor": { "name": "lchoudhary", "key": "lchoudhary", "displayName": "Lokesh Choudhary", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2016-09-02T20:48:20.000+0000", "updated": "2016-09-02T20:51:54.000+0000" }, { "id": "395228", "author": { "name": "hknoechel", "key": "hansknoechel", "displayName": "Hans Knöchel", "active": true, "timeZone": "Europe/Berlin" }, "body": "Thanks Lokesh! I would highly suggest to use MOD-2280 for 6.0.0 which not only includes an important fix but should also fix the above problem. [~cng] to discuss. Otherwise, I will backport it manually.", "updateAuthor": { "name": "hknoechel", "key": "hansknoechel", "displayName": "Hans Knöchel", "active": true, "timeZone": "Europe/Berlin" }, "created": "2016-09-02T21:05:18.000+0000", "updated": "2016-09-02T21:05:18.000+0000" }, { "id": "395230", "author": { "name": "lchoudhary", "key": "lchoudhary", "displayName": "Lokesh Choudhary", "active": true, "timeZone": "America/Los_Angeles" }, "body": "[~hansknoechel], facebook module 5.2.3 & 5.2.4 for IOS works fine. \r\nYou can resolve the ticket after your discussion with [~cng].", "updateAuthor": { "name": "lchoudhary", "key": "lchoudhary", "displayName": "Lokesh Choudhary", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2016-09-02T21:18:15.000+0000", "updated": "2016-09-02T21:18:15.000+0000" }, { "id": "395295", "author": { "name": "cng", "key": "cng", "displayName": "Chee Kiat Ng", "active": false, "timeZone": "America/Los_Angeles" }, "updateAuthor": { "name": "cng", "key": "cng", "displayName": "Chee Kiat Ng", "active": false, "timeZone": "America/Los_Angeles" }, "created": "2016-09-05T02:52:18.000+0000", "updated": "2016-09-05T02:52:18.000+0000" }, { "id": "396390", "author": { "name": "lchoudhary", "key": "lchoudhary", "displayName": "Lokesh Choudhary", "active": true, "timeZone": "America/Los_Angeles" }, "body": "Verified the fix for IOS with 5.2.6 facebook module. \r\n\r\nClosing.\r\n\r\nEnvironment:\r\nAppc Studio : 4.8.0.201609061702\r\nTi SDK : 6.0.0.v20160915125929\r\nTi CLI : 5.0.9\r\nAlloy : 1.9.1\r\nMAC El Capitan : 10.11.6\r\nAppc NPM : 4.2.8-6\r\nAppc CLI : 6.0.0-44\r\nNode: 4.4.4\r\nNexus 6 - Android 6.0.1", "updateAuthor": { "name": "lchoudhary", "key": "lchoudhary", "displayName": "Lokesh Choudhary", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2016-09-16T22:02:26.000+0000", "updated": "2016-09-16T22:02:26.000+0000" } ], "maxResults": 18, "total": 18, "startAt": 0 } } }