cordova-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Sergey Shakhnazarov (JIRA)" <j...@apache.org>
Subject [jira] [Resolved] (CB-9516) Android SplashScreen - Spinner Does Not Display
Date Tue, 26 Jan 2016 11:25:39 GMT

     [ https://issues.apache.org/jira/browse/CB-9516?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]

Sergey Shakhnazarov resolved CB-9516.
-------------------------------------
    Resolution: Fixed

Fixed in 3.1.1-dev

> Android SplashScreen - Spinner Does Not Display
> -----------------------------------------------
>
>                 Key: CB-9516
>                 URL: https://issues.apache.org/jira/browse/CB-9516
>             Project: Apache Cordova
>          Issue Type: Bug
>          Components: Plugin SplashScreen
>    Affects Versions: 5.0.1
>         Environment: Cordova 5 and Android Lollipop 5.0 and 5.1
>            Reporter: Mark Ludlow
>            Priority: Minor
>              Labels: android, easyfix
>
> The spinner dialog is not displaying on Android. I believe one cause of this is the message
"spinner > stop" which being used to display the webview, is also stopping the spinner
prematurely.
> See this comment in CoreAndroid.js:
> // This gets called from JavaScript onCordovaReady to show the webview.
> // I recommend we change the name of the Message as spinner/stop is not
> // indicative of what this actually does (shows the webview).
>                 cordova.getActivity().runOnUiThread(new Runnable() {
>                     public void run() {
>                         webView.getPluginManager().postMessage("spinner", "stop");
>                     }
>                 });
> The "spinner > stop" message is fired almost immediately after SplashScreen.spinnerStart()
is called, thus hiding the spinner before it actually displays. I was able to partially fix
this by commenting out the call to spinnerStop() in the "spinner > stop" message handler:
> if ("spinner".equals(id)) {
>             if ("stop".equals(data.toString())) {
>                 //this.spinnerStop();
>                 getView().setVisibility(View.VISIBLE);
>             }
>         }
> The second issue, at least for Cordova 5 and Lollipop, is that in the pluginInitialize()
method, loadSpinner() is being called before showSplashScreen(true).
> I reversed these lines and made the change above and now the splashscreen displays correctly.




--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@cordova.apache.org
For additional commands, e-mail: issues-help@cordova.apache.org


Mime
View raw message