Commit d262d519 authored by danakj@chromium.org's avatar danakj@chromium.org

Revert of cc: Remove the --enable-partial-swap flag. (https://codereview.chromium.org/167953003/)

Reason for revert:
Should have only enabled this on ChromeOS. Enabled elsewhere by mistake.

Original issue's description:
> cc: Remove the --enable-partial-swap flag.
> 
> R=piman
> BUG=
> 
> Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=251898

TBR=piman@chromium.org
NOTREECHECKS=true
NOTRY=true
BUG=

Review URL: https://codereview.chromium.org/172763002

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@252038 0039d316-1c4b-4281-b951-d872f2087c98
parent 5b80a350
...@@ -82,6 +82,7 @@ const char kStrictLayerPropertyChangeChecking[] = ...@@ -82,6 +82,7 @@ const char kStrictLayerPropertyChangeChecking[] =
// Virtual viewport for fixed-position elements, scrollbars during pinch. // Virtual viewport for fixed-position elements, scrollbars during pinch.
const char kEnablePinchVirtualViewport[] = "enable-pinch-virtual-viewport"; const char kEnablePinchVirtualViewport[] = "enable-pinch-virtual-viewport";
const char kEnablePartialSwap[] = "enable-partial-swap";
// Disable partial swap which is needed for some OpenGL drivers / emulators. // Disable partial swap which is needed for some OpenGL drivers / emulators.
const char kUIDisablePartialSwap[] = "ui-disable-partial-swap"; const char kUIDisablePartialSwap[] = "ui-disable-partial-swap";
......
...@@ -36,6 +36,7 @@ CC_EXPORT extern const char kCompositeToMailbox[]; ...@@ -36,6 +36,7 @@ CC_EXPORT extern const char kCompositeToMailbox[];
CC_EXPORT extern const char kMaxTilesForInterestArea[]; CC_EXPORT extern const char kMaxTilesForInterestArea[];
CC_EXPORT extern const char kMaxUnusedResourceMemoryUsagePercentage[]; CC_EXPORT extern const char kMaxUnusedResourceMemoryUsagePercentage[];
CC_EXPORT extern const char kEnablePinchVirtualViewport[]; CC_EXPORT extern const char kEnablePinchVirtualViewport[];
CC_EXPORT extern const char kEnablePartialSwap[];
CC_EXPORT extern const char kStrictLayerPropertyChangeChecking[]; CC_EXPORT extern const char kStrictLayerPropertyChangeChecking[];
CC_EXPORT extern const char kEnableMapImage[]; CC_EXPORT extern const char kEnableMapImage[];
CC_EXPORT extern const char kDisableMapImage[]; CC_EXPORT extern const char kDisableMapImage[];
......
...@@ -177,6 +177,7 @@ std::string DeriveCommandLine(const GURL& start_url, ...@@ -177,6 +177,7 @@ std::string DeriveCommandLine(const GURL& start_url,
cc::switches::kEnableGPURasterization, cc::switches::kEnableGPURasterization,
cc::switches::kEnableImplSidePainting, cc::switches::kEnableImplSidePainting,
cc::switches::kEnableMapImage, cc::switches::kEnableMapImage,
cc::switches::kEnablePartialSwap,
cc::switches::kEnablePerTilePainting, cc::switches::kEnablePerTilePainting,
cc::switches::kEnablePinchVirtualViewport, cc::switches::kEnablePinchVirtualViewport,
cc::switches::kEnableTopControlsPositionCalculation, cc::switches::kEnableTopControlsPositionCalculation,
...@@ -236,6 +237,15 @@ std::string DeriveCommandLine(const GURL& start_url, ...@@ -236,6 +237,15 @@ std::string DeriveCommandLine(const GURL& start_url,
::switches::kRegisterPepperPlugins).c_str()); ::switches::kRegisterPepperPlugins).c_str());
} }
// TODO(zelidrag): Remove this hack that get us around compositing bug from
// http://crbug.com/179256 once that bug is resolved.
if (command_line->HasSwitch(::switches::kForceAppMode)) {
std::string switch_to_remove("--");
switch_to_remove.append(cc::switches::kEnablePartialSwap);
cmd_line_str = cmd_line_str.replace(cmd_line_str.find(switch_to_remove),
switch_to_remove.length(), "");
}
return cmd_line_str; return cmd_line_str;
} }
......
...@@ -1110,6 +1110,7 @@ void RenderProcessHostImpl::PropagateBrowserCommandLineToRenderer( ...@@ -1110,6 +1110,7 @@ void RenderProcessHostImpl::PropagateBrowserCommandLineToRenderer(
cc::switches::kEnableImplSidePainting, cc::switches::kEnableImplSidePainting,
cc::switches::kEnableLCDText, cc::switches::kEnableLCDText,
cc::switches::kEnableMapImage, cc::switches::kEnableMapImage,
cc::switches::kEnablePartialSwap,
cc::switches::kEnablePerTilePainting, cc::switches::kEnablePerTilePainting,
cc::switches::kEnablePinchVirtualViewport, cc::switches::kEnablePinchVirtualViewport,
cc::switches::kEnableTopControlsPositionCalculation, cc::switches::kEnableTopControlsPositionCalculation,
......
...@@ -170,7 +170,8 @@ scoped_ptr<RenderWidgetCompositor> RenderWidgetCompositor::Create( ...@@ -170,7 +170,8 @@ scoped_ptr<RenderWidgetCompositor> RenderWidgetCompositor::Create(
settings.top_controls_hide_threshold = hide_threshold; settings.top_controls_hide_threshold = hide_threshold;
} }
settings.partial_swap_enabled = widget->AllowPartialSwap(); settings.partial_swap_enabled = widget->AllowPartialSwap() &&
cmd->HasSwitch(cc::switches::kEnablePartialSwap);
settings.background_color_instead_of_checkerboard = settings.background_color_instead_of_checkerboard =
cmd->HasSwitch(cc::switches::kBackgroundColorInsteadOfCheckerboard); cmd->HasSwitch(cc::switches::kBackgroundColorInsteadOfCheckerboard);
settings.show_overdraw_in_tracing = settings.show_overdraw_in_tracing =
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment