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

Side by Side Diff: content/public/test/android/javatests/src/org/chromium/content/browser/test/util/TestWebContentsObserver.java

Issue 589113002: Rename java WebContentsObserverAndroid to WebContentsObserver (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: style issues fixed Created 6 years, 2 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 unified diff | Download patch
« no previous file with comments | « content/public/android/javatests/src/org/chromium/content/browser/WebContentsObserverAndroidTest.java ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2012 The Chromium Authors. All rights reserved. 1 // Copyright 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 package org.chromium.content.browser.test.util; 5 package org.chromium.content.browser.test.util;
6 6
7 import org.chromium.content.browser.WebContentsObserverAndroid; 7 import org.chromium.content.browser.WebContentsObserver;
8 import org.chromium.content.browser.test.util.TestCallbackHelperContainer.OnPage FinishedHelper; 8 import org.chromium.content.browser.test.util.TestCallbackHelperContainer.OnPage FinishedHelper;
9 import org.chromium.content.browser.test.util.TestCallbackHelperContainer.OnPage StartedHelper; 9 import org.chromium.content.browser.test.util.TestCallbackHelperContainer.OnPage StartedHelper;
10 import org.chromium.content.browser.test.util.TestCallbackHelperContainer.OnRece ivedErrorHelper; 10 import org.chromium.content.browser.test.util.TestCallbackHelperContainer.OnRece ivedErrorHelper;
11 import org.chromium.content_public.browser.WebContents; 11 import org.chromium.content_public.browser.WebContents;
12 12
13 /** 13 /**
14 * The default WebContentsObserverAndroid used by ContentView tests. The below c allbacks can be 14 * The default WebContentsObserver used by ContentView tests. The below callback s can be
15 * accessed by using {@link TestCallbackHelperContainer} or extending this class . 15 * accessed by using {@link TestCallbackHelperContainer} or extending this class .
16 */ 16 */
17 public class TestWebContentsObserver extends WebContentsObserverAndroid { 17 public class TestWebContentsObserver extends WebContentsObserver {
18 18
19 private final OnPageStartedHelper mOnPageStartedHelper; 19 private final OnPageStartedHelper mOnPageStartedHelper;
20 private final OnPageFinishedHelper mOnPageFinishedHelper; 20 private final OnPageFinishedHelper mOnPageFinishedHelper;
21 private final OnReceivedErrorHelper mOnReceivedErrorHelper; 21 private final OnReceivedErrorHelper mOnReceivedErrorHelper;
22 22
23 public TestWebContentsObserver(WebContents webContents) { 23 public TestWebContentsObserver(WebContents webContents) {
24 super(webContents); 24 super(webContents);
25 mOnPageStartedHelper = new OnPageStartedHelper(); 25 mOnPageStartedHelper = new OnPageStartedHelper();
26 mOnPageFinishedHelper = new OnPageFinishedHelper(); 26 mOnPageFinishedHelper = new OnPageFinishedHelper();
27 mOnReceivedErrorHelper = new OnReceivedErrorHelper(); 27 mOnReceivedErrorHelper = new OnReceivedErrorHelper();
(...skipping 29 matching lines...) Expand all
57 mOnPageFinishedHelper.notifyCalled(url); 57 mOnPageFinishedHelper.notifyCalled(url);
58 } 58 }
59 59
60 @Override 60 @Override
61 public void didFailLoad(boolean isProvisionalLoad, boolean isMainFrame, 61 public void didFailLoad(boolean isProvisionalLoad, boolean isMainFrame,
62 int errorCode, String description, String failingUrl) { 62 int errorCode, String description, String failingUrl) {
63 super.didFailLoad(isProvisionalLoad, isMainFrame, errorCode, description , failingUrl); 63 super.didFailLoad(isProvisionalLoad, isMainFrame, errorCode, description , failingUrl);
64 mOnReceivedErrorHelper.notifyCalled(errorCode, description, failingUrl); 64 mOnReceivedErrorHelper.notifyCalled(errorCode, description, failingUrl);
65 } 65 }
66 } 66 }
OLDNEW
« no previous file with comments | « content/public/android/javatests/src/org/chromium/content/browser/WebContentsObserverAndroidTest.java ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698