You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@cordova.apache.org by "Daniel Kurka (JIRA)" <ji...@apache.org> on 2012/04/21 11:02:33 UTC

[jira] [Created] (CB-552) Cordova breaks GWT boot mechanism - device ready will not fire

Daniel Kurka created CB-552:
-------------------------------

             Summary: Cordova breaks GWT boot mechanism - device ready will not fire
                 Key: CB-552
                 URL: https://issues.apache.org/jira/browse/CB-552
             Project: Apache Callback
          Issue Type: Bug
    Affects Versions: 1.6.1, 1.6.0, 1.5.0
         Environment: Cordova apps written with GWT (Google Web Toolkit) do not work with the new cordova releases.
            Reporter: Daniel Kurka
         Attachments: big.js, index.html

When GWT is using a so called xsiframe linker the source code of the app is loaded by a small script to select the appropriate javascript file.
This mechanism used to work fine with all versions before 1.5

I have created a small example (no real GWT app) to show the issue.

The code creates a script element and appends it to the head of the document (as GWT would do in a normal bootup). After appending the script element no more cordova events seem to fire.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Updated] (CB-552) Cordova breaks GWT boot mechanism - device ready will not fire

Posted by "Daniel Kurka (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/CB-552?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Daniel Kurka updated CB-552:
----------------------------

    Attachment: index.html
                big.js
    
> Cordova breaks GWT boot mechanism - device ready will not fire
> --------------------------------------------------------------
>
>                 Key: CB-552
>                 URL: https://issues.apache.org/jira/browse/CB-552
>             Project: Apache Callback
>          Issue Type: Bug
>    Affects Versions: 1.5.0, 1.6.0, 1.6.1
>         Environment: Cordova apps written with GWT (Google Web Toolkit) do not work with the new cordova releases.
>            Reporter: Daniel Kurka
>         Attachments: big.js, index.html
>
>
> When GWT is using a so called xsiframe linker the source code of the app is loaded by a small script to select the appropriate javascript file.
> This mechanism used to work fine with all versions before 1.5
> I have created a small example (no real GWT app) to show the issue.
> The code creates a script element and appends it to the head of the document (as GWT would do in a normal bootup). After appending the script element no more cordova events seem to fire.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Commented] (CB-552) Cordova breaks GWT boot mechanism - device ready will not fire

Posted by "Daniel Kurka (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/CB-552?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13258946#comment-13258946 ] 

Daniel Kurka commented on CB-552:
---------------------------------

I have tested this on iOS 5.1 (iPhone 4S) and Android 4.0.4 (Google Nexus S) with phonegap 1.6.1, but I think this related to all platforms.
                
> Cordova breaks GWT boot mechanism - device ready will not fire
> --------------------------------------------------------------
>
>                 Key: CB-552
>                 URL: https://issues.apache.org/jira/browse/CB-552
>             Project: Apache Callback
>          Issue Type: Bug
>    Affects Versions: 1.5.0, 1.6.0, 1.6.1
>         Environment: Cordova apps written with GWT (Google Web Toolkit) do not work with the new cordova releases.
>            Reporter: Daniel Kurka
>            Assignee: Filip Maj
>         Attachments: big.js, index.html
>
>
> When GWT is using a so called xsiframe linker the source code of the app is loaded by a small script to select the appropriate javascript file.
> This mechanism used to work fine with all versions before 1.5
> I have created a small example (no real GWT app) to show the issue.
> The code creates a script element and appends it to the head of the document (as GWT would do in a normal bootup). After appending the script element no more cordova events seem to fire.
> The index.html contains the "bootup code" and the big.js file would contain the gwt app.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Resolved] (CB-552) Cordova breaks GWT boot mechanism - device ready will not fire

Posted by "Filip Maj (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/CB-552?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Filip Maj resolved CB-552.
--------------------------

       Resolution: Fixed
    Fix Version/s: 1.7.0

Verified that the issue exists in 1.6.1 on a Galaxy Nexus running Android 4.0.2.

However, when I pulled in the [latest master for Cordova-JS as of commit 194c77|http://git-wip-us.apache.org/repos/asf?p=incubator-cordova-js.git;a=commit;h=194c7743b42847f9e56cb1958462624393bd8209], rebuilt the JavaScript and re-deployed, I could no longer reproduce the issue. I am thinking that the fix for CB-499 also fixes this issue. This issue was related to how require.js dynamically created script tags, which would mess with how the DOMContentLoaded event was fired on the document.  Because cordova.js attached to DOMContentLoaded very late, it messed up the way the deviceready event got fired.

@Daniel: can you try cloning the incubator-cordova-js repository, building the latest master, replacing your project's cordova.js with the newly-built cordova.js file for the platforms you are seeing the issue on, re-testing and letting me know how it goes?
                
> Cordova breaks GWT boot mechanism - device ready will not fire
> --------------------------------------------------------------
>
>                 Key: CB-552
>                 URL: https://issues.apache.org/jira/browse/CB-552
>             Project: Apache Callback
>          Issue Type: Bug
>          Components: CordovaJS
>    Affects Versions: 1.5.0, 1.6.0, 1.6.1
>         Environment: Cordova apps written with GWT (Google Web Toolkit) do not work with the new cordova releases.
>            Reporter: Daniel Kurka
>            Assignee: Filip Maj
>             Fix For: 1.7.0
>
>         Attachments: big.js, index.html
>
>
> When GWT is using a so called xsiframe linker the source code of the app is loaded by a small script to select the appropriate javascript file.
> This mechanism used to work fine with all versions before 1.5
> I have created a small example (no real GWT app) to show the issue.
> The code creates a script element and appends it to the head of the document (as GWT would do in a normal bootup). After appending the script element no more cordova events seem to fire.
> The index.html contains the "bootup code" and the big.js file would contain the gwt app.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Commented] (CB-552) Cordova breaks GWT boot mechanism - device ready will not fire

Posted by "Daniel Kurka (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/CB-552?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13259156#comment-13259156 ] 

Daniel Kurka commented on CB-552:
---------------------------------

This is indeed fixed in trunk. There are some other weirdness, which I will investigate further (events are not received by the gwt app), but the bootup code is now working fine.

I verified on iOS 5.1 (iPhone 4S) and Android 4.0.4 (Google Nexus S). Thanks for the quick reply!
                
> Cordova breaks GWT boot mechanism - device ready will not fire
> --------------------------------------------------------------
>
>                 Key: CB-552
>                 URL: https://issues.apache.org/jira/browse/CB-552
>             Project: Apache Callback
>          Issue Type: Bug
>          Components: CordovaJS
>    Affects Versions: 1.5.0, 1.6.0, 1.6.1
>         Environment: Cordova apps written with GWT (Google Web Toolkit) do not work with the new cordova releases.
>            Reporter: Daniel Kurka
>            Assignee: Filip Maj
>             Fix For: 1.7.0
>
>         Attachments: big.js, index.html
>
>
> When GWT is using a so called xsiframe linker the source code of the app is loaded by a small script to select the appropriate javascript file.
> This mechanism used to work fine with all versions before 1.5
> I have created a small example (no real GWT app) to show the issue.
> The code creates a script element and appends it to the head of the document (as GWT would do in a normal bootup). After appending the script element no more cordova events seem to fire.
> The index.html contains the "bootup code" and the big.js file would contain the gwt app.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Updated] (CB-552) Cordova breaks GWT boot mechanism - device ready will not fire

Posted by "Filip Maj (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/CB-552?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Filip Maj updated CB-552:
-------------------------

    Component/s: CordovaJS

Cool, thanks for the info. I will investigate. We recently committed a fix to a problem that is similar to this, but which could only be reproduced on iOS (not Android).
                
> Cordova breaks GWT boot mechanism - device ready will not fire
> --------------------------------------------------------------
>
>                 Key: CB-552
>                 URL: https://issues.apache.org/jira/browse/CB-552
>             Project: Apache Callback
>          Issue Type: Bug
>          Components: CordovaJS
>    Affects Versions: 1.5.0, 1.6.0, 1.6.1
>         Environment: Cordova apps written with GWT (Google Web Toolkit) do not work with the new cordova releases.
>            Reporter: Daniel Kurka
>            Assignee: Filip Maj
>         Attachments: big.js, index.html
>
>
> When GWT is using a so called xsiframe linker the source code of the app is loaded by a small script to select the appropriate javascript file.
> This mechanism used to work fine with all versions before 1.5
> I have created a small example (no real GWT app) to show the issue.
> The code creates a script element and appends it to the head of the document (as GWT would do in a normal bootup). After appending the script element no more cordova events seem to fire.
> The index.html contains the "bootup code" and the big.js file would contain the gwt app.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Assigned] (CB-552) Cordova breaks GWT boot mechanism - device ready will not fire

Posted by "Filip Maj (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/CB-552?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Filip Maj reassigned CB-552:
----------------------------

    Assignee: Filip Maj
    
> Cordova breaks GWT boot mechanism - device ready will not fire
> --------------------------------------------------------------
>
>                 Key: CB-552
>                 URL: https://issues.apache.org/jira/browse/CB-552
>             Project: Apache Callback
>          Issue Type: Bug
>    Affects Versions: 1.5.0, 1.6.0, 1.6.1
>         Environment: Cordova apps written with GWT (Google Web Toolkit) do not work with the new cordova releases.
>            Reporter: Daniel Kurka
>            Assignee: Filip Maj
>         Attachments: big.js, index.html
>
>
> When GWT is using a so called xsiframe linker the source code of the app is loaded by a small script to select the appropriate javascript file.
> This mechanism used to work fine with all versions before 1.5
> I have created a small example (no real GWT app) to show the issue.
> The code creates a script element and appends it to the head of the document (as GWT would do in a normal bootup). After appending the script element no more cordova events seem to fire.
> The index.html contains the "bootup code" and the big.js file would contain the gwt app.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Updated] (CB-552) Cordova breaks GWT boot mechanism - device ready will not fire

Posted by "Daniel Kurka (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/CB-552?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Daniel Kurka updated CB-552:
----------------------------

    Description: 
When GWT is using a so called xsiframe linker the source code of the app is loaded by a small script to select the appropriate javascript file.
This mechanism used to work fine with all versions before 1.5

I have created a small example (no real GWT app) to show the issue.

The code creates a script element and appends it to the head of the document (as GWT would do in a normal bootup). After appending the script element no more cordova events seem to fire.


The index.html contains the "bootup code" and the big.js file would contain the gwt app.


  was:
When GWT is using a so called xsiframe linker the source code of the app is loaded by a small script to select the appropriate javascript file.
This mechanism used to work fine with all versions before 1.5

I have created a small example (no real GWT app) to show the issue.

The code creates a script element and appends it to the head of the document (as GWT would do in a normal bootup). After appending the script element no more cordova events seem to fire.

    
> Cordova breaks GWT boot mechanism - device ready will not fire
> --------------------------------------------------------------
>
>                 Key: CB-552
>                 URL: https://issues.apache.org/jira/browse/CB-552
>             Project: Apache Callback
>          Issue Type: Bug
>    Affects Versions: 1.5.0, 1.6.0, 1.6.1
>         Environment: Cordova apps written with GWT (Google Web Toolkit) do not work with the new cordova releases.
>            Reporter: Daniel Kurka
>         Attachments: big.js, index.html
>
>
> When GWT is using a so called xsiframe linker the source code of the app is loaded by a small script to select the appropriate javascript file.
> This mechanism used to work fine with all versions before 1.5
> I have created a small example (no real GWT app) to show the issue.
> The code creates a script element and appends it to the head of the document (as GWT would do in a normal bootup). After appending the script element no more cordova events seem to fire.
> The index.html contains the "bootup code" and the big.js file would contain the gwt app.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Commented] (CB-552) Cordova breaks GWT boot mechanism - device ready will not fire

Posted by "Filip Maj (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/CB-552?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13258945#comment-13258945 ] 

Filip Maj commented on CB-552:
------------------------------

Which platform are you experiencing this problem on? Android/iOS/BB/Windows Phone/etc. And what device / OS version is it running?
                
> Cordova breaks GWT boot mechanism - device ready will not fire
> --------------------------------------------------------------
>
>                 Key: CB-552
>                 URL: https://issues.apache.org/jira/browse/CB-552
>             Project: Apache Callback
>          Issue Type: Bug
>    Affects Versions: 1.5.0, 1.6.0, 1.6.1
>         Environment: Cordova apps written with GWT (Google Web Toolkit) do not work with the new cordova releases.
>            Reporter: Daniel Kurka
>         Attachments: big.js, index.html
>
>
> When GWT is using a so called xsiframe linker the source code of the app is loaded by a small script to select the appropriate javascript file.
> This mechanism used to work fine with all versions before 1.5
> I have created a small example (no real GWT app) to show the issue.
> The code creates a script element and appends it to the head of the document (as GWT would do in a normal bootup). After appending the script element no more cordova events seem to fire.
> The index.html contains the "bootup code" and the big.js file would contain the gwt app.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira