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

Unified Diff: content/shell/shell_download_manager_delegate.cc

Issue 15979019: [content shell] further restrict what files to open during layout tests (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 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
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/shell/shell_download_manager_delegate.cc
diff --git a/content/shell/shell_download_manager_delegate.cc b/content/shell/shell_download_manager_delegate.cc
index e0ed2617df1aa5154f8a8d05dbaf23ed49f0f387..dc5a87da1594545088be4bb9d642aa93c2ad06ab 100644
--- a/content/shell/shell_download_manager_delegate.cc
+++ b/content/shell/shell_download_manager_delegate.cc
@@ -91,7 +91,8 @@ bool ShellDownloadManagerDelegate::ShouldOpenDownload(
DownloadItem* item,
const DownloadOpenDelayedCallback& callback) {
if (CommandLine::ForCurrentProcess()->HasSwitch(switches::kDumpRenderTree) &&
- WebKitTestController::Get()->IsMainWindow(item->GetWebContents())) {
+ WebKitTestController::Get()->IsMainWindow(item->GetWebContents()) &&
+ item->GetMimeType() == "text/html") {
WebKitTestController::Get()->OpenURL(
net::FilePathToFileURL(item->GetFullPath()));
}
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698