2016-05-26 60 views
0

我遇到了一個問題,當我在Testflight中打開我的應用程序時,啓動屏幕隱藏,然後在應用程序加載之前只有一個白色屏幕。離子閃屏隱藏太快testflight

我有這個在我的app.js:

.run(function($ionicPlatform) { 
    $ionicPlatform.ready(function() { 
    setTimeout(function() { 
     navigator.splashscreen.hide(); 
    }, 3000); 
}); 
}) 

而這個配置文件中:

<preference name="SplashScreen" value="splash"/> 
<preference name="AutoHideSplashScreen" value="true"/> 
<preference name="SplashScreenDelay" value="4000"/> 
<preference name="FadeSplashScreen" value="true"/> 
<preference name="FadeSplashScreenDuration" value="1"/> 

啓動屏幕通常隱藏當我在模擬器中運行我的應用程序,它只是當我在Testflight中運行它,它會中斷。配置和app.js都不會影響啓動屏幕在Testflight上顯示的時間。

如果有人有任何建議,我會很感激,謝謝!

回答

0

我的啓動畫面配置如下圖,並沒有任何問題,工作正常

什麼,我在app.js

我加入this plugin我離子項目加入。 我複製我的RES/放到哪個文件夾在config.xml文件中的相應文件夾中的所有啓動畫面drawable-文件內

我的項目的根文件夾

<preference name="SplashScreen" value="screen"/> 
<preference name="SplashScreenDelay" value="3000"/> 
<preference name="SplashMaintainAspectRatio" value="true|false" /> 

<platform name="android"> 
    //then added all dpi as this 

    <splash src="res/drawable-land-hdpi/screen.png" density="land-ldpi"/> 

</platform>