Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(2835)

Unified Diff: chrome/android/java/src/org/chromium/chrome/browser/Tab.java

Issue 1057043002: Don't return NativePages from Tab#getAllViews. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Added old method back until downstream references are removed Created 5 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | chrome/android/java/src/org/chromium/chrome/browser/compositor/layouts/Layout.java » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/android/java/src/org/chromium/chrome/browser/Tab.java
diff --git a/chrome/android/java/src/org/chromium/chrome/browser/Tab.java b/chrome/android/java/src/org/chromium/chrome/browser/Tab.java
index a8151da2c3c3356b33239972513d50541a7e8472..fcbca7187d5b389bf845524fa49ac1359603ddd0 100644
--- a/chrome/android/java/src/org/chromium/chrome/browser/Tab.java
+++ b/chrome/android/java/src/org/chromium/chrome/browser/Tab.java
@@ -1380,13 +1380,24 @@ public class Tab implements ViewGroup.OnHierarchyChangeListener,
}
/**
+ * TODO(dtrainor): Remove after method is no longer used downstream.
* Used to get a list of Android {@link View}s that represent both the normal content as well as
- * overlays.
+ * overlays. This does not return {@link View}s for {@link NativePage}s.
* @param content A {@link List} that will be populated with {@link View}s that represent all of
* the content in this {@link Tab}.
*/
public void getAllViews(List<View> content) {
- content.add(getView());
+ getAllContentViews(content);
+ }
+
+ /**
+ * Used to get a list of Android {@link View}s that represent both the normal content as well as
+ * overlays. This does not return {@link View}s for {@link NativePage}s.
+ * @param content A {@link List} that will be populated with {@link View}s that represent all of
+ * the content in this {@link Tab}.
+ */
+ public void getAllContentViews(List<View> content) {
+ if (!isNativePage()) content.add(getView());
for (int i = 0; i < mOverlayContentViewCores.size(); i++) {
content.add(mOverlayContentViewCores.get(i).getContainerView());
}
« no previous file with comments | « no previous file | chrome/android/java/src/org/chromium/chrome/browser/compositor/layouts/Layout.java » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698