From 8bf104801369f43387e7538b5ed208f352e3b26b Mon Sep 17 00:00:00 2001 From: "jam@chromium.org" Date: Wed, 8 Feb 2012 01:22:18 +0000 Subject: Move handling of debug urls like chrome://crash, chrome://gpuclean to content. These are for testing the content layer, so they belong there. This allows us to hide GpuProcessHostUIShim from chrome. I cleaned up the about_handler.* files which were overly complicated. I also was able to remove a method from ContentBrowserClient. BUG=98716 Review URL: https://chromiumcodereview.appspot.com/9349010 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@120891 0039d316-1c4b-4281-b951-d872f2087c98 --- chrome/browser/browser_about_handler.cc | 33 --------------------------------- 1 file changed, 33 deletions(-) (limited to 'chrome/browser/browser_about_handler.cc') diff --git a/chrome/browser/browser_about_handler.cc b/chrome/browser/browser_about_handler.cc index 7212cb6..0c7b22b 100644 --- a/chrome/browser/browser_about_handler.cc +++ b/chrome/browser/browser_about_handler.cc @@ -12,10 +12,8 @@ #include "base/string_util.h" #include "chrome/browser/net/url_fixer_upper.h" #include "chrome/browser/ui/browser_dialogs.h" -#include "chrome/common/about_handler.h" #include "chrome/common/chrome_switches.h" #include "chrome/common/url_constants.h" -#include "content/browser/gpu/gpu_process_host_ui_shim.h" #include "content/browser/sensors/sensors_provider.h" #if defined(USE_TCMALLOC) @@ -104,10 +102,6 @@ bool WillHandleBrowserAboutURL(GURL* url, if (!url->SchemeIs(chrome::kChromeUIScheme)) return false; - // Circumvent processing URLs that the renderer process will handle. - if (chrome_about_handler::WillHandle(*url)) - return false; - CommandLine* cl = CommandLine::ForCurrentProcess(); bool enableUberPage = !cl->HasSwitch(switches::kDisableUberPage); @@ -172,33 +166,6 @@ bool HandleNonNavigationAboutURL(const GURL& url) { #endif // OFFICIAL_BUILD - // Handle URLs to crash the browser or wreck the gpu process. - if (host == chrome::kChromeUIBrowserCrashHost) { - // Induce an intentional crash in the browser process. - CHECK(false); - } - - if (host == chrome::kChromeUIGpuCleanHost) { - GpuProcessHostUIShim* shim = GpuProcessHostUIShim::GetOneInstance(); - if (shim) - shim->SimulateRemoveAllContext(); - return true; - } - - if (host == chrome::kChromeUIGpuCrashHost) { - GpuProcessHostUIShim* shim = GpuProcessHostUIShim::GetOneInstance(); - if (shim) - shim->SimulateCrash(); - return true; - } - - if (host == chrome::kChromeUIGpuHangHost) { - GpuProcessHostUIShim* shim = GpuProcessHostUIShim::GetOneInstance(); - if (shim) - shim->SimulateHang(); - return true; - } - #if defined(OS_CHROMEOS) if (host == chrome::kChromeUIRotateHost) { content::ScreenOrientation change = content::SCREEN_ORIENTATION_TOP; -- cgit v1.1