Trouble showing webview
<p>I need to show a web page for a several amount of seconds, then start another activity.
What I am doing is on the onResume() method, I call the Thread.sleep() and then start the new activity, but when I execute it, it doesn't show me webpage. It shows a black screen, and executes the next activity. What could i possibly be doing wrong? Here is my code:</p>

<pre><code>public class ShowPortalActivity extends Activity {

@Override
protected void onCreate(Bundle savedInstanceState) {
    super.onCreate(savedInstanceState);

            String url = "http://someurl.com";
            WebView webview = (WebView) findViewById(R.id.webView);
            // next line explained below
            webview.setWebViewClient(new WebViewClient());
            webview.getSettings().setJavaScriptEnabled(true);
            webview.loadUrl(url);





}

@Override
protected void onResume() {
    // TODO Auto-generated method stub
    super.onResume();
    try {
        newActivity();
    } catch (InterruptedException e) {
        // TODO Auto-generated catch block
        e.printStackTrace();
    }
}

void newActivity() throws InterruptedException {
    Thread.sleep(3000);
    Intent intent = new Intent(ShowPortalActivity.this, Inicio.class);
    startActivity(intent);

}
</code></pre>

<p>}</p>
