{ "id": "61637", "key": "TIMOB-1005", "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": "11225", "name": "Release 1.5.0", "archived": true, "released": true, "releaseDate": "2010-12-14" } ], "resolution": { "id": "1", "description": "A fix for this issue is checked into the tree and tested.", "name": "Fixed" }, "resolutiondate": "2011-04-17T01:54:56.000+0000", "created": "2011-04-15T02:41:20.000+0000", "priority": { "name": "Medium", "id": "3" }, "labels": [ "android", "defect", "kroll" ], "versions": [], "issuelinks": [], "assignee": { "name": "blainhamon", "key": "blainhamon", "displayName": "Blain Hamon", "active": true, "timeZone": "America/Los_Angeles" }, "updated": "2011-04-17T01:54:56.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" } ], "description": "{html}

Platform 1.3.0 OS MacOSX/WinXP, iPhone emulator 3.1.3, android\nemulator 2.1

\n

Please take a look at example on the documentation page for\nTitanium.UI.Window, \"Passing data\" section. You have variable a and\nmethod b. I tried to reproduce this in my project. In app.js I have\nmethod, variable, TabGroup, 2 Tabs which have windows created with\nurl property and a and b attached. I can access a and b from child\nwindow on iPhone, but only variable a on Android. When I try to\ncall method b, smth. like Titanium.UI.currentWindow.b() I get an\nerror from rhino JS library, smth. like \"b is not a method, it's an\nobject and not callable\". Actually it's true, on Android, b is an\nobject of KrollContext, not function, I can see this when I print\nTitanium.UI.currentWindow.b to standard output. I even can call\nTitanium.UI.currentWindow.b.call() and it even works but I can't\npass any arguments to b, anyway, IMHO this feature is totally\nbroken on Android. iPhone is OK here

{html}", "attachment": [], "flagged": false, "summary": "Functions and currentWindow on Android broken", "creator": { "name": "konstantin", "key": "konstantin", "displayName": "Konstantin", "active": true, "timeZone": "America/Los_Angeles" }, "subtasks": [], "reporter": { "name": "konstantin", "key": "konstantin", "displayName": "Konstantin", "active": true, "timeZone": "America/Los_Angeles" }, "environment": null, "comment": { "comments": [ { "id": "124549", "author": { "name": "konstantin", "key": "konstantin", "displayName": "Konstantin", "active": true, "timeZone": "America/Los_Angeles" }, "body": "{html}

Correction: not KrollContext but KrollCallback

{html}", "updateAuthor": { "name": "konstantin", "key": "konstantin", "displayName": "Konstantin", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2011-04-15T02:41:20.000+0000", "updated": "2011-04-15T02:41:20.000+0000" }, { "id": "124550", "author": { "name": "konstantin", "key": "konstantin", "displayName": "Konstantin", "active": true, "timeZone": "America/Los_Angeles" }, "body": "{html}

Finally I'd like to say, it's not only problem of currentWindow\nproperty, any *Proxy object's custom methods have same problem, for\nexample:

\n
\nvar object = Ti.Module.createSomething({});\nobject.specialHandler = function(arg){/*Handler here*/};\n//Somewhere inside handler\n  this.specialHandler('parameter');\n
\n

raises same error, specialHandler is not a method anymore. It's\na blocking bug for me on Android

{html}", "updateAuthor": { "name": "konstantin", "key": "konstantin", "displayName": "Konstantin", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2011-04-15T02:41:20.000+0000", "updated": "2011-04-15T02:41:20.000+0000" }, { "id": "124551", "author": { "name": "dthorp", "key": "dthorp", "displayName": "Don Thorp", "active": true, "timeZone": "America/Los_Angeles" }, "body": "{html}

This is really a duplicate, special case of #915

{html}", "updateAuthor": { "name": "dthorp", "key": "dthorp", "displayName": "Don Thorp", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2011-04-15T02:41:21.000+0000", "updated": "2011-04-15T02:41:21.000+0000" }, { "id": "124552", "author": { "name": "mculpepper", "key": "mculpepper", "displayName": "Marshall Culpepper", "active": true, "timeZone": "America/Los_Angeles" }, "body": "{html}

Confirm this works as it should w/ new Kroll

{html}", "updateAuthor": { "name": "mculpepper", "key": "mculpepper", "displayName": "Marshall Culpepper", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2011-04-15T02:41:21.000+0000", "updated": "2011-04-15T02:41:21.000+0000" }, { "id": "124553", "author": { "name": "mculpepper", "key": "mculpepper", "displayName": "Marshall Culpepper", "active": true, "timeZone": "America/Los_Angeles" }, "body": "{html}

(from [ad1506dc5a33e2f763f9ec37a6fbd3245c7fb728])\nadded a test for custom proxy instance methods [#1005\nstate:fixed-in-qa] \nhttps://github.com/appcelerator/titanium_mobile/commit/ad1506dc5a33...

{html}", "updateAuthor": { "name": "mculpepper", "key": "mculpepper", "displayName": "Marshall Culpepper", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2011-04-15T02:41:21.000+0000", "updated": "2011-04-15T02:41:21.000+0000" }, { "id": "124554", "author": { "name": "mschmulen", "key": "mschmulen", "displayName": "Matt Schmulen", "active": true, "timeZone": "America/Los_Angeles" }, "body": "{html}

Pass Titanium SDK version: 1.5.0 (12/01/10 09:30 ac7cfd8)\ndrillbit test Android Sim 1.6/2.1

\n

android sim 1.6
\n\nhttps://5111068499667359260-a-appcelerator-com-s-sites.googlegroups...

\n

android sim 2.1
\n\nhttps://5111068499667359260-a-appcelerator-com-s-sites.googlegroups...

{html}", "updateAuthor": { "name": "mschmulen", "key": "mschmulen", "displayName": "Matt Schmulen", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2011-04-15T02:41:22.000+0000", "updated": "2011-04-15T02:41:22.000+0000" }, { "id": "124555", "author": { "name": "krishnan", "key": "krishnan", "displayName": "krishnan", "active": true, "timeZone": "America/Los_Angeles" }, "body": "{html}

Did this got resolved?

{html}", "updateAuthor": { "name": "krishnan", "key": "krishnan", "displayName": "krishnan", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2011-04-15T02:41:22.000+0000", "updated": "2011-04-15T02:41:22.000+0000" } ], "maxResults": 7, "total": 7, "startAt": 0 } } }