The WebControl can’t display the even alert of JS

The WebControl can’t display the even alert of JS

BY 19 Dec 2013 Native Application Development

I write the .js and .html as below,and then call LoadUrl(“the url…………………”);in the file of .cpp.    

But I can’t get the the even Pop-up box of alert(“Tizen2”);alert(“Tizen4”);alert(“Tizen6”);

Hope get some opiniones from this forum,thank you very much!

//loadurl.js
function loadurl(){
alert(“Tizen1”);
alert(“Tizen2”);
alert(“Tizen3”);
alert(“Tizen4”);
alert(“Tizen5”);
alert(“Tizen6”);
alert(“Tizen7”);
}

//ll.html

<html>
<head>
       <title>”load url” </title>
       <script language=”javascript” type=”text/javascript” src=”loadurl.js”></script>
</head>
<body>
      <script language=”javascript” >
         loadurl();
      </script>
</body>
</html>

//.cpp

    if (null == mpWeb) {
        Tizen::Graphics::Rectangle bound = GetClientAreaBounds();
        mpWeb = new (std::nothrow) Tizen::Web::Controls::Web();
        r = mpWeb->Construct(Tizen::Graphics::Rectangle(0, 0, bound.width, bound.height));
        Tizen::Web::Controls::WebSetting setting;
       setting.SetJavascriptEnabled(true);
        r = AddControl(mpWeb);
        mpWeb->LoadUrl(L”http://192.168.7.210/XXX/ll.html”);
        return r;
    }

Written by