[ 
https://issues.apache.org/jira/browse/CB-2602?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13802786#comment-13802786
 ] 

Cordova_Fan commented on CB-2602:
---------------------------------

Hi James,

Thanks for the clarification. Here is the code where I am experiencing problem. 
This is specific to iOS:

function onDeviceReady() {
    require.config({
        baseUrl: "scripts",
        paths: {
            phonegap: 'libs/phonegap/phonegap-loader',
            facebook: 'libs/facebook/facebook-loader',
            jQuery: 'libs/jquery/jquery-loader',
            jQueryMigrate: 'libs/jquery.migrate/jquery-migrate-1.1.1',
            jQueryMobile: 'libs/jquery.mobile/jquery.mobile-loader',
            underscore: 'libs/underscore/underscore-loader',
            Backbone: 'libs/backbone/backbone-loader',
            headerview: 'views/header/index',
            footerview: 'views/footer/index'
        },
        shim: {
            'facebook': {
                exports: 'FB'
            },
            jQuery: { exports: "jQuery" },
            jQueryMobile: {
                deps: ['phonegap', 'jQuery'],
                exports: 'jQuery.mobile'
            },
            jQueryMigrate: {
                deps: ['jQuery']
            },
            underscore: {
                exports: '_'
            },
            Backbone: {
                deps: ['jQueryMobile', 'jQuery', 'underscore'],
                exports: 'Backbone'
            }

        },
        waitSeconds: 100,
        locale: localStorage.getItem('locale') || 'en-us'
    });

    //Window.open works here
    
    require([
        'phonegap',
        'jQuery',
        'jQueryMigrate',
        'jQueryMobile',
        'underscore'
    ],
        function (cordova, $, jqMigrate, jQueryMobile,  _) {
            //
            //The window.open does not work here
           //
            require(['app'], function (app) {
                console.log('MAIN: Initializing app');
                app.init();
            })
        });
}

As you can see my window.open method does not fire inside the require callback.
Any advice is greatly appreciated.

Thanks,
Satya

> Hashchange prevents transition from splash screen
> -------------------------------------------------
>
>                 Key: CB-2602
>                 URL: https://issues.apache.org/jira/browse/CB-2602
>             Project: Apache Cordova
>          Issue Type: Bug
>          Components: iOS
>            Reporter: haric
>            Assignee: Andrew Grieve
>
> location.hashchange on page load prevents transition from splash screen.  
> However, works from device ready or after setting an interval.



--
This message was sent by Atlassian JIRA
(v6.1#6144)

Reply via email to