Skip to content

Commit 876ee4e

Browse files
committed
Fixed the bug: it is too large to fit into a software layer (or drawing cache). https://www.94cb.com/t/3893
1 parent c56a06f commit 876ee4e

File tree

1 file changed

+5
-2
lines changed

1 file changed

+5
-2
lines changed

app/src/main/java/com/lincanbin/carbonforum/adapter/PostAdapter.java

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -144,8 +144,11 @@ public postViewHolder(View itemView) {
144144
// http://stackoverflow.com/questions/15133132/android-webview-doesnt-display-web-page-in-some-cases
145145
Content.setLayerType(View.LAYER_TYPE_SOFTWARE, null);
146146
} else {
147-
// Content.setLayerType(View.LAYER_TYPE_HARDWARE, null);
148-
Content.setLayerType(View.LAYER_TYPE_SOFTWARE, null);
147+
//Content.setLayerType(View.LAYER_TYPE_HARDWARE, null);
148+
//Content.setLayerType(View.LAYER_TYPE_SOFTWARE, null);
149+
// 修复显示长帖时申请不到内存的bug
150+
// http://stackoverflow.com/questions/18471194/webview-in-scrollview-view-too-large-to-fit-into-drawing-cache-how-to-rewor
151+
Content.setLayerType(View.LAYER_TYPE_NONE, null);
149152
}
150153
// http://stackoverflow.com/questions/5003156/android-webview-style-background-colortransparent-ignored-on-android-2-2
151154
Content.setBackgroundColor(Color.TRANSPARENT);

0 commit comments

Comments
 (0)