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

Unified Diff: remoting/android/java/src/org/chromium/chromoting/Desktop.java

Issue 2480203002: ui: Cleanup class/struct forward declarations (Closed)
Patch Set: Sync CL to position 430550 Created 4 years, 1 month 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 | « ppapi/cpp/var.h ('k') | remoting/android/java/src/org/chromium/chromoting/DesktopCanvas.java » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: remoting/android/java/src/org/chromium/chromoting/Desktop.java
diff --git a/remoting/android/java/src/org/chromium/chromoting/Desktop.java b/remoting/android/java/src/org/chromium/chromoting/Desktop.java
index 9cfb8792fbf1770594710127ea79b3196f2bfbfe..6c4ffd8aa6d939ed06a9dc7ea51b360c51aeddf5 100644
--- a/remoting/android/java/src/org/chromium/chromoting/Desktop.java
+++ b/remoting/android/java/src/org/chromium/chromoting/Desktop.java
@@ -6,6 +6,8 @@ package org.chromium.chromoting;
import android.annotation.SuppressLint;
import android.content.res.Configuration;
+import android.graphics.Color;
+import android.graphics.drawable.ColorDrawable;
import android.os.Build;
import android.os.Bundle;
import android.os.Handler;
@@ -128,6 +130,12 @@ public class Desktop
View decorView = getWindow().getDecorView();
decorView.setOnSystemUiVisibilityChangeListener(this);
+ // The background color is displayed when the user resizes the window in split-screen past
+ // the boundaries of the image we render. The default background is white and we use black
+ // for our canvas, thus there is a visual artifact when we draw the canvas over the
+ // background. Setting the background color to match our canvas will prevent the flash.
+ getWindow().setBackgroundDrawable(new ColorDrawable(Color.BLACK));
+
mActivityLifecycleListener = mClient.getCapabilityManager().onActivityAcceptingListener(
this, Capabilities.CAST_CAPABILITY);
mActivityLifecycleListener.onActivityCreated(this, savedInstanceState);
« no previous file with comments | « ppapi/cpp/var.h ('k') | remoting/android/java/src/org/chromium/chromoting/DesktopCanvas.java » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698