2013-09-28 61 views
0

enter image description here禁用下載選項中的Android

預覽如何禁用下載和桌面選項,當我試圖在Android應用程序中打開這個時候。

WebView mWebView = (WebView) findViewById(R.id.WebView01); 
String pdfurl = ""; // Url of pdf or doc file. 

String weblink="http://docs.google.com/gview?embedded=true&url="+pdfurl;  
mWebView.loadUrl(weblink); 
+0

@本巴,只需出示你的代碼什麼ü試圖.. – FarhaSameer786

+0

當然請編輯的問題 – Anirban

+1

指http://stackoverflow.com/questions/17761231/display-pdf-in-webview-of-android – nikhil

回答

0

試試這一個全屏PDF

private void updateFullscreenStatus(boolean bUseFullscreen) 
    { 
     if(bUseFullscreen) 
     { 
      getWindow().addFlags(WindowManager.LayoutParams.FLAG_FULLSCREEN); 
      getWindow().clearFlags(WindowManager.LayoutParams.FLAG_FORCE_NOT_FULLSCREEN); 
     } 
     else 
     { 
      getWindow().addFlags(WindowManager.LayoutParams.FLAG_FORCE_NOT_FULLSCREEN); 
      getWindow().clearFlags(WindowManager.LayoutParams.FLAG_FULLSCREEN); 
     } 

     m_contentView.requestLayout(); 
    } 
+0

如何在我的代碼中添加此updateFullscreenStatus方法? – Anirban