我試圖發佈我的android應用程序創建與科爾多瓦,併發布時,我遵循所有步驟像android:debuggable =「false」甚至刪除這條線作爲其最新的建議,但問題是當我在我的模擬器中安裝簽名的版本版本我能夠調試它...任何幫助?WebView.setWebContentsDebuggingEnabled(false),但我可以在安裝已簽名APK後調試代碼
更新: -
按照建議我試圖..
public class appname extends CordovaActivity
{
@Override
public void onCreate(Bundle savedInstanceState)
{
super.onCreate(savedInstanceState);
super.init();
super.loadUrl(Config.getStartUrl());
if(Build.VERSION.SDK_INT >= Build.VERSION_CODES.KITKAT){
if(0 != (getApplicationInfo().flags = ApplicationInfo.FLAG_DEBUGGABLE)){
//Log.i("Your app", "Disable web debugging");
WebView.setWebContentsDebuggingEnabled(false);
}
}
}
}
在公共無效的onCreate(捆綁savedInstanceState){}
實測值這段代碼在CordovaWebView.java
if((appInfo.flags & ApplicationInfo.FLAG_DEBUGGABLE) != 0 &&
android.os.Build.VERSION.SDK_INT >= android.os.Build.VERSION_CODES.KITKAT)
{
setWebContentsDebuggingEnabled(true); // I tried setting this false as well
}
但它仍然沒有工作......我仍然能夠調試html js fil es
你如何調試旅遊代碼? – 2014-08-29 04:36:21
通過鍍鉻設備工具 – Luckyy 2014-08-29 05:51:31