{ "id": "159088", "key": "TIMOB-23117", "fields": { "issuetype": { "id": "4", "description": "An improvement or enhancement to an existing feature or task.", "name": "Improvement", "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": "17706", "name": "Release 5.4.0", "archived": false, "released": true, "releaseDate": "2016-08-11" } ], "resolution": { "id": "1", "description": "A fix for this issue is checked into the tree and tested.", "name": "Fixed" }, "resolutiondate": "2016-05-10T23:04:28.000+0000", "created": "2016-03-28T19:05:24.000+0000", "epic": { "id": 151897, "key": "TIMOB-19699", "name": "Android: Hyperloop for Android module", "summary": "Bring Hyperloop to Android", "color": { "key": "color_4" }, "done": false }, "priority": { "name": "High", "id": "2" }, "labels": [], "versions": [], "issuelinks": [ { "id": "51661", "type": { "id": "10001", "name": "Cloners", "inward": "is cloned into", "outward": "is cloned from" }, "inwardIssue": { "id": "160185", "key": "TIMOB-23360", "fields": { "summary": "Hyperloop: Android: Support overriding constructors in subclasses", "status": { "description": "The issue is open and ready for the assignee to start work on it.", "name": "Open", "id": "1", "statusCategory": { "id": 2, "key": "new", "colorName": "blue-gray", "name": "To Do" } }, "priority": { "name": "High", "id": "2" }, "issuetype": { "id": "4", "description": "An improvement or enhancement to an existing feature or task.", "name": "Improvement", "subtask": false } } } } ], "assignee": { "name": "cwilliams", "key": "cwilliams", "displayName": "Christopher Williams", "active": true, "timeZone": "America/New_York" }, "updated": "2018-08-06T17:49:28.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": "13715", "name": "Hyperloop", "description": "Hyperloop project" } ], "description": "Hyperloop Android (not sure if it works in iOS) currently cannot call the superclass inside a Hyperloop-based subclass. We should support that in order to match a common OOP-pattern.", "attachment": [], "flagged": false, "summary": "Hyperloop: Android: Support calls to super-class", "creator": { "name": "hknoechel", "key": "hansknoechel", "displayName": "Hans Knöchel", "active": true, "timeZone": "Europe/Berlin" }, "subtasks": [], "reporter": { "name": "falko", "key": "falko", "displayName": "Andrey Tkachenko", "active": true, "timeZone": "Europe/Moscow" }, "environment": null, "closedSprints": [ { "id": 627, "state": "closed", "name": "2016 Sprint 10 SDK", "startDate": "2016-05-07T00:43:56.954Z", "endDate": "2016-05-21T00:43:00.000Z", "completeDate": "2016-05-23T02:06:04.349Z", "originBoardId": 114 } ], "comment": { "comments": [ { "id": "383607", "author": { "name": "cwilliams", "key": "cwilliams", "displayName": "Christopher Williams", "active": true, "timeZone": "America/New_York" }, "body": "[~hansknoechel] Do you have some sample code for the usage you're expecting? I assume this is when you override a method in a JS subclass and want to be able to call the super implementation in it?", "updateAuthor": { "name": "cwilliams", "key": "cwilliams", "displayName": "Christopher Williams", "active": true, "timeZone": "America/New_York" }, "created": "2016-04-21T23:08:48.000+0000", "updated": "2016-04-21T23:08:48.000+0000" }, { "id": "383650", "author": { "name": "hknoechel", "key": "hansknoechel", "displayName": "Hans Knöchel", "active": true, "timeZone": "Europe/Berlin" }, "body": "The initial request contained a constructor method:\r\n{code:javascript}\r\nMyView = android.view.View.extend({\r\n MyView: function() {\r\n // Constructor called?\r\n }\r\n});\r\n{code}\r\n\r\nand a super-class call:\r\n{code:javascript}\r\nvar MyView = View.extend({\r\n onMeasure: function(widthMeasureSpec, heightMeasureSpec) {\r\n View.prototype.onMeasure.call(this, widthMeasureSpec, heightMeasureSpec);\r\n // or\r\n this.super.onMeasure.call(this, widthMeasureSpec, heightMeasureSpec);\r\n }\r\n}\r\n{code}\r\nIf you can think of a better structure, please go ahead! :-)", "updateAuthor": { "name": "hknoechel", "key": "hansknoechel", "displayName": "Hans Knöchel", "active": true, "timeZone": "Europe/Berlin" }, "created": "2016-04-22T08:08:55.000+0000", "updated": "2016-04-22T11:37:51.000+0000" }, { "id": "385290", "author": { "name": "cwilliams", "key": "cwilliams", "displayName": "Christopher Williams", "active": true, "timeZone": "America/New_York" }, "body": "https://github.com/appcelerator/hyperloop.next/pull/29", "updateAuthor": { "name": "cwilliams", "key": "cwilliams", "displayName": "Christopher Williams", "active": true, "timeZone": "America/New_York" }, "created": "2016-05-10T15:49:26.000+0000", "updated": "2016-05-10T15:49:26.000+0000" }, { "id": "385291", "author": { "name": "cwilliams", "key": "cwilliams", "displayName": "Christopher Williams", "active": true, "timeZone": "America/New_York" }, "body": "This PR is for an implementation that uses a this.super property. So it'd look more like this:\r\n\r\n{code:javascript}\r\nvar MyView = View.extend({\r\n onMeasure: function (widthMeasureSpec, heightMeasureSpec) {\r\n this.super.onMeasure(widthMeasureSpec, heightMeasureSpec);\r\n // do your own custom work now.\r\n }\r\n});\r\n{code}", "updateAuthor": { "name": "cwilliams", "key": "cwilliams", "displayName": "Christopher Williams", "active": true, "timeZone": "America/New_York" }, "created": "2016-05-10T15:51:44.000+0000", "updated": "2016-05-10T15:51:44.000+0000" }, { "id": "385293", "author": { "name": "cwilliams", "key": "cwilliams", "displayName": "Christopher Williams", "active": true, "timeZone": "America/New_York" }, "body": "Another note, the PR I posted does not attempt to address overriding constructors as mentioned above. Quite honestly how to achieve that has me a bit stumped right now...", "updateAuthor": { "name": "cwilliams", "key": "cwilliams", "displayName": "Christopher Williams", "active": true, "timeZone": "America/New_York" }, "created": "2016-05-10T15:57:39.000+0000", "updated": "2016-05-10T15:57:39.000+0000" }, { "id": "385334", "author": { "name": "hknoechel", "key": "hansknoechel", "displayName": "Hans Knöchel", "active": true, "timeZone": "Europe/Berlin" }, "body": "Alright. Should we file an own ticket for the constructor call?", "updateAuthor": { "name": "hknoechel", "key": "hansknoechel", "displayName": "Hans Knöchel", "active": true, "timeZone": "Europe/Berlin" }, "created": "2016-05-10T22:33:08.000+0000", "updated": "2016-05-10T22:33:08.000+0000" }, { "id": "400239", "author": { "name": "rdperottoni", "key": "rdperottoni", "displayName": "Rodolfo Perottoni", "active": true, "timeZone": "Australia/Brisbane" }, "body": "@Chris Williams @Hans Knoechel how can I get the current application context using this same approach?\r\n\r\nBy getting a reference to the current *Activity* on native code I can just call *getApplicationContext()* and that's it.\r\nOn the other hand, with Hyperloop I'd need to go past the first super class (Activity -> ContextThemeWrapper -> ContextWrapper -> Context.getApplicationContext()).\r\n\r\nHow do you see that happening?", "updateAuthor": { "name": "rdperottoni", "key": "rdperottoni", "displayName": "Rodolfo Perottoni", "active": true, "timeZone": "Australia/Brisbane" }, "created": "2016-11-02T09:31:35.000+0000", "updated": "2016-11-02T09:31:35.000+0000" }, { "id": "440185", "author": { "name": "emerriman", "key": "emerriman", "displayName": "Eric Merriman ", "active": true, "timeZone": "America/Los_Angeles" }, "body": "Cleaning up older fixed issues. If this issue should not have been closed as fixed, please reopen.", "updateAuthor": { "name": "emerriman", "key": "emerriman", "displayName": "Eric Merriman ", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2018-08-06T17:49:28.000+0000", "updated": "2018-08-06T17:49:28.000+0000" } ], "maxResults": 8, "total": 8, "startAt": 0 } } }