bool WebForm::OnLoadingRequested (const Osp::Base::String& url, WebNavigationType type) { AppLogDebug("URL REQUESTED %S", url.GetPointer()); if(url.StartsWith("gap://", 0)) { // __cordovaCommand = null; __cordovaCommand = new String(url); // FIXME: for some reason this does not work if we return true. Web freezes. // __pWeb->StopLoading(); // String* test; // test = __pWeb->EvaluateJavascriptN(L"'test'"); // AppLogDebug("String is %S", test->GetPointer()); // delete test; // return true; return false; } else if(url.StartsWith("http://", 0) || url.StartsWith("https://", 0)) { AppLogDebug("Non Cordova command. External URL. Launching WebBrowser"); LaunchBrowser(url); return false; } return false; }