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

Side by Side Diff: chrome/browser/chromeos/gview_request_interceptor.cc

Issue 7639009: Cleanup: Remove old webkit/glue/plugins/plugin_list.h (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: '' Created 9 years, 4 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « no previous file | chrome/test/ui/npapi_test_helper.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "chrome/browser/chromeos/gview_request_interceptor.h" 5 #include "chrome/browser/chromeos/gview_request_interceptor.h"
6 6
7 #include "base/file_path.h" 7 #include "base/file_path.h"
8 #include "base/path_service.h" 8 #include "base/path_service.h"
9 #include "chrome/common/chrome_paths.h" 9 #include "chrome/common/chrome_paths.h"
10 #include "googleurl/src/gurl.h" 10 #include "googleurl/src/gurl.h"
11 #include "net/base/escape.h" 11 #include "net/base/escape.h"
12 #include "net/base/load_flags.h" 12 #include "net/base/load_flags.h"
13 #include "net/url_request/url_request.h" 13 #include "net/url_request/url_request.h"
14 #include "net/url_request/url_request_redirect_job.h" 14 #include "net/url_request/url_request_redirect_job.h"
15 #include "webkit/glue/plugins/plugin_list.h" 15 #include "webkit/plugins/npapi/plugin_list.h"
16 16
17 namespace chromeos { 17 namespace chromeos {
18 18
19 // The PDF mime type is treated special if the browser has a built-in 19 // The PDF mime type is treated special if the browser has a built-in
20 // PDF viewer plug-in installed - we want to intercept only if we're 20 // PDF viewer plug-in installed - we want to intercept only if we're
21 // told to. 21 // told to.
22 static const char kPdfMimeType[] = "application/pdf"; 22 static const char kPdfMimeType[] = "application/pdf";
23 23
24 // This is the list of mime types currently supported by the Google 24 // This is the list of mime types currently supported by the Google
25 // Document Viewer. 25 // Document Viewer.
(...skipping 51 matching lines...) Expand 10 before | Expand all | Expand 10 after
77 // will redirect the browser to this new URL. 77 // will redirect the browser to this new URL.
78 if (supported_mime_types_.count(mime_type) > 0) { 78 if (supported_mime_types_.count(mime_type) > 0) {
79 std::string url(kGViewUrlPrefix); 79 std::string url(kGViewUrlPrefix);
80 url += EscapePath(request->url().spec()); 80 url += EscapePath(request->url().spec());
81 return new net::URLRequestRedirectJob(request, GURL(url)); 81 return new net::URLRequestRedirectJob(request, GURL(url));
82 } 82 }
83 return NULL; 83 return NULL;
84 } 84 }
85 85
86 } // namespace chromeos 86 } // namespace chromeos
OLDNEW
« no previous file with comments | « no previous file | chrome/test/ui/npapi_test_helper.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698