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

Unified Diff: chrome/android/java_staging/src/org/chromium/chrome/browser/compositor/Invalidator.java

Issue 1206673003: Merge java_staging/src into java/src. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: rebase Created 5 years, 6 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
Index: chrome/android/java_staging/src/org/chromium/chrome/browser/compositor/Invalidator.java
diff --git a/chrome/android/java_staging/src/org/chromium/chrome/browser/compositor/Invalidator.java b/chrome/android/java_staging/src/org/chromium/chrome/browser/compositor/Invalidator.java
deleted file mode 100644
index 784946833bf77a06fb2a9412379482f78711e1d2..0000000000000000000000000000000000000000
--- a/chrome/android/java_staging/src/org/chromium/chrome/browser/compositor/Invalidator.java
+++ /dev/null
@@ -1,55 +0,0 @@
-// Copyright 2015 The Chromium Authors. All rights reserved.
-// Use of this source code is governed by a BSD-style license that can be
-// found in the LICENSE file.
-
-package org.chromium.chrome.browser.compositor;
-
-/**
- * The {@link Invalidator} invalidates a client when it is the right time.
- */
-public class Invalidator {
- /**
- * Interface for the client that gets invalidated.
- */
- public interface Client {
- /**
- * Do the invalidation.
- */
- void doInvalidate();
- }
-
- /**
- * Interface for the host that drives the invalidations.
- */
- public interface Host {
- /**
- * Requests an invalidation of the view.
- *
- * @param view The {@link View} to invalidate.
- */
- void deferInvalidate(Client view);
- }
-
- private Host mHost;
-
- /**
- * @param host The invalidator host, responsible for invalidating views.
- */
- public void set(Host host) {
- mHost = host;
- }
-
- /**
- * Invalidates either immediately (if no host is specified) or at time
- * triggered by the host.
- *
- * @param client The {@link Client} to invalidate, most likely a view.
- */
- public void invalidate(Client client) {
- if (mHost != null) {
- mHost.deferInvalidate(client);
- } else {
- client.doInvalidate();
- }
- }
-}

Powered by Google App Engine
This is Rietveld 408576698