View previous topic :: View next topic |
Author |
Message |
tupac
Joined: 20 Jun 2011 Posts: 13
|
Posted: Fri Jun 29, 2012 9:45 pm Post subject: Launch Browser --No dialog box |
|
|
Hi, I am trying to force load a webpage that is required for my app.
Problem is I don't want the pop up dialog but asking to launch the page.
How can I use: launch_browser (t_url, Q_LAUNCH_BROWSER_NEW); without have the pop up dialog?
The api says its a wrapper for the STK_CMD -- is it the wrapper making this menu or is it the host os? |
|
Back to top |
|
|
pz
Joined: 12 Mar 2004 Posts: 1161
|
Posted: Mon Jul 02, 2012 11:56 am Post subject: |
|
|
The dialog is done by the phone itself.
Usually this is controlled by T_ALPHA setting to NULL string (i.e. len=0). The very old 11.14 says this ALPHA is used when you are using existing browser but quite likely this has been changed and also will be phone/vendor depending. So check some new 11.14.
We don't use ALPHA in lauch_browser() API (for simplicity sake) so you have to reimplement it using stk_cmd() to see if/how it works. |
|
Back to top |
|
|
tupac
Joined: 20 Jun 2011 Posts: 13
|
Posted: Mon Jul 02, 2012 3:28 pm Post subject: ALPHA_T |
|
|
So you mentioned T_ALPHA, how would I go about setting alpha_t when using stk_cmd()
This is what I have so far.
Code: | void browser_no_menu(void *data)
{
u8 *buf = buf_A ();
u8 len = 0;
//Assuming the url goes in buf_a
buf[len++] = "h";
buf[len++] = "t";
buf[len++] = "t";
buf[len++] = "p";
buf[len++] = ":";
buf[len++] = "/";
buf[len++] = "/";
buf[len++] = ".";
buf[len++] = "t";
buf[len++] = "e";
buf[len++] = "s";
buf[len++] = "t";
buf[len++] = ".";
buf[len++] = "c";
buf[len++] = "o";
buf[len++] = "m";
stk_cmd (STK_CMD_LAUNCH_BROWSER, 0x00, DEV_ID_ME, len);
} |
|
|
Back to top |
|
|
tupac
Joined: 20 Jun 2011 Posts: 13
|
Posted: Wed Jul 04, 2012 8:40 pm Post subject: |
|
|
Anyone? |
|
Back to top |
|
|
pz
Joined: 12 Mar 2004 Posts: 1161
|
Posted: Fri Jul 06, 2012 4:25 pm Post subject: |
|
|
You have to construct the buf_A() according to 11.14. - use TLV fields.
E.g. (not realted to launch browser):
Code: |
buf[len++] = T_SS_STRING | CR_FLAG;
buf[len++] = sizeof(t_Text_ss);
for (i = 0; i < sizeof(t_Text_ss); i++)
buf[len++] = rb(t_Text_ss+i);
|
Use T_URL and T_ALPHA_ID in your case. |
|
Back to top |
|
|
|