From a9a5967ea18d4b442ae5433cd3759b3921e480ad Mon Sep 17 00:00:00 2001 From: Michael Kolb Date: Thu, 17 Nov 2011 12:50:10 -0800 Subject: Add content description to screenshots in tab manager Bug: 5619945 Change-Id: I26dc592334dbbd6878887408153249d68046001b --- src/com/android/browser/NavTabView.java | 16 +++------------- 1 file changed, 3 insertions(+), 13 deletions(-) diff --git a/src/com/android/browser/NavTabView.java b/src/com/android/browser/NavTabView.java index 4eec702..b15e828 100644 --- a/src/com/android/browser/NavTabView.java +++ b/src/com/android/browser/NavTabView.java @@ -74,11 +74,6 @@ public class NavTabView extends LinearLayout { return v == mImage; } - protected void setHighlighted(boolean highlighted) { - if (highlighted == mHighlighted) return; - mHighlighted = highlighted; - } - private void setTitle() { if (mTab == null) return; if (mHighlighted) { @@ -112,23 +107,18 @@ public class NavTabView extends LinearLayout { return mHighlighted; } - protected void setWebView(WebView w) { - mContent.addView(w, new LayoutParams(LayoutParams.MATCH_PARENT, LayoutParams.MATCH_PARENT)); - } - protected void setWebView(Tab tab) { mTab = tab; setTitle(); Bitmap image = tab.getScreenshot(); if (image != null) { mImage.setImageBitmap(image); + if (tab != null) { + mImage.setContentDescription(tab.getTitle()); + } } } - protected void hideTitle() { - mTitleBar.setVisibility(View.INVISIBLE); - } - @Override public void setOnClickListener(OnClickListener listener) { mClickListener = listener; -- cgit v1.1