Create web page launcher, losing focus

Posted by user356131 on Stack Overflow See other posts from Stack Overflow or by user356131
Published on 2010-06-02T06:34:58Z Indexed on 2010/06/02 7:23 UTC
Read the original article Hit count: 176

Filed under:
|

I have created a php webpage. I now want to create a launcher application in android phone, it simply opens the browser with the url "http://<mywebsite>/m".

I use uri intent to launch the browser in onCreate function.

public void onCreate(...)
{
    ....
    startActivity(new Intent(Intent.ACTION_VIEW, new Uri(http://<mywebsite>/m)));
    ...
}

I execute this program in my G1 phone (Cyan Mod 5). However, when I click the "Home" key, and then re-enter my application through Task list, I lose focus for my last started browser, and the screen blank

Any suggestion?! Should I need any code in onResume function to re-focus my web!?

© Stack Overflow or respective owner

Related posts about android

Related posts about intent