enable webview zoom controls
bump version
This commit is contained in:
parent
4057f5ac69
commit
2c71f2e829
@ -1,8 +1,8 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
package="org.fox.ttrss"
|
||||
android:versionCode="181"
|
||||
android:versionName="1.8.1" >
|
||||
android:versionCode="182"
|
||||
android:versionName="1.8.2" >
|
||||
|
||||
<uses-sdk
|
||||
android:minSdkVersion="8"
|
||||
|
@ -95,21 +95,7 @@ public class ArticleFragment extends Fragment implements GestureDetector.OnDoubl
|
||||
m_article = savedInstanceState.getParcelable("article");
|
||||
}
|
||||
|
||||
final View view = inflater.inflate(R.layout.article_fragment, container, false);
|
||||
|
||||
WebView content = (WebView) view.findViewById(R.id.content);
|
||||
|
||||
if (content != null) content.setVisibility(View.INVISIBLE);
|
||||
|
||||
// prevent flicker in ics
|
||||
if (android.os.Build.VERSION.SDK_INT >= 11) {
|
||||
content.setLayerType(View.LAYER_TYPE_SOFTWARE, null);
|
||||
}
|
||||
|
||||
new Handler().postDelayed(new Runnable() {
|
||||
@Override
|
||||
public void run() {
|
||||
if (isAdded()) {
|
||||
View view = inflater.inflate(R.layout.article_fragment, container, false);
|
||||
|
||||
if (m_article != null) {
|
||||
|
||||
@ -181,6 +167,11 @@ public class ArticleFragment extends Fragment implements GestureDetector.OnDoubl
|
||||
if (web != null) {
|
||||
registerForContextMenu(web);
|
||||
|
||||
// prevent flicker in ics
|
||||
if (android.os.Build.VERSION.SDK_INT >= 11) {
|
||||
web.setLayerType(View.LAYER_TYPE_SOFTWARE, null);
|
||||
}
|
||||
|
||||
web.setWebChromeClient(new WebChromeClient() {
|
||||
@Override
|
||||
public void onProgressChanged(WebView view, int progress) {
|
||||
@ -203,7 +194,10 @@ public class ArticleFragment extends Fragment implements GestureDetector.OnDoubl
|
||||
|
||||
WebSettings ws = web.getSettings();
|
||||
ws.setSupportZoom(true);
|
||||
ws.setBuiltInZoomControls(false);
|
||||
ws.setBuiltInZoomControls(true);
|
||||
|
||||
if (!m_activity.isCompatMode())
|
||||
ws.setDisplayZoomControls(false);
|
||||
|
||||
web.getSettings().setLayoutAlgorithm(LayoutAlgorithm.SINGLE_COLUMN);
|
||||
|
||||
@ -341,11 +335,6 @@ public class ArticleFragment extends Fragment implements GestureDetector.OnDoubl
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
}, 50);
|
||||
|
||||
|
||||
return view;
|
||||
}
|
||||
|
||||
|
@ -175,7 +175,10 @@ public class OfflineArticleFragment extends Fragment implements GestureDetector.
|
||||
|
||||
WebSettings ws = web.getSettings();
|
||||
ws.setSupportZoom(true);
|
||||
ws.setBuiltInZoomControls(false);
|
||||
ws.setBuiltInZoomControls(true);
|
||||
|
||||
if (!m_activity.isCompatMode())
|
||||
ws.setDisplayZoomControls(false);
|
||||
|
||||
web.getSettings().setLayoutAlgorithm(LayoutAlgorithm.SINGLE_COLUMN);
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user