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

Side by Side Diff: chrome/browser/ui/webui/shared_resources_data_source.cc

Issue 10444043: rename chrome_shared2.css to chrome_shared.css (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 years, 7 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 | « chrome/browser/resources/uber/uber_frame.html ('k') | no next file » | 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) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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/ui/webui/shared_resources_data_source.h" 5 #include "chrome/browser/ui/webui/shared_resources_data_source.h"
6 6
7 #include <string> 7 #include <string>
8 8
9 #include "base/memory/ref_counted_memory.h" 9 #include "base/memory/ref_counted_memory.h"
10 #include "base/memory/singleton.h" 10 #include "base/memory/singleton.h"
(...skipping 33 matching lines...) Expand 10 before | Expand all | Expand 10 after
44 for (size_t i = 0; i < kSharedResourcesSize; ++i) { 44 for (size_t i = 0; i < kSharedResourcesSize; ++i) {
45 if (kSharedResources[i].name == key) { 45 if (kSharedResources[i].name == key) {
46 idr = kSharedResources[i].value; 46 idr = kSharedResources[i].value;
47 break; 47 break;
48 } 48 }
49 } 49 }
50 50
51 // In touch layout use some alternate CSS rules. 51 // In touch layout use some alternate CSS rules.
52 // Ideally we'd expose a touch-screen media query operator to the web 52 // Ideally we'd expose a touch-screen media query operator to the web
53 // at large, and then just use that for WebUI instead. crbug.com/123062 53 // at large, and then just use that for WebUI instead. crbug.com/123062
54 if (idr == IDR_SHARED_CSS_CHROME2 && 54 if (idr == IDR_SHARED_CSS_CHROME &&
55 ui::GetDisplayLayout() == ui::LAYOUT_TOUCH) { 55 ui::GetDisplayLayout() == ui::LAYOUT_TOUCH) {
56 idr = IDR_SHARED_CSS_CHROME2_TOUCH; 56 idr = IDR_SHARED_CSS_CHROME_TOUCH;
57 } 57 }
58 } 58 }
59 59
60 return idr; 60 return idr;
61 } 61 }
62 62
63 } // namespace 63 } // namespace
64 64
65 SharedResourcesDataSource::SharedResourcesDataSource() 65 SharedResourcesDataSource::SharedResourcesDataSource()
66 : DataSource(chrome::kChromeUIResourcesHost, NULL) { 66 : DataSource(chrome::kChromeUIResourcesHost, NULL) {
(...skipping 18 matching lines...) Expand all
85 const std::string& path) const { 85 const std::string& path) const {
86 // Requests should not block on the disk! On Windows this goes to the 86 // Requests should not block on the disk! On Windows this goes to the
87 // registry. 87 // registry.
88 // http://code.google.com/p/chromium/issues/detail?id=59849 88 // http://code.google.com/p/chromium/issues/detail?id=59849
89 base::ThreadRestrictions::ScopedAllowIO allow_io; 89 base::ThreadRestrictions::ScopedAllowIO allow_io;
90 90
91 std::string mime_type; 91 std::string mime_type;
92 net::GetMimeTypeFromFile(FilePath().AppendASCII(path), &mime_type); 92 net::GetMimeTypeFromFile(FilePath().AppendASCII(path), &mime_type);
93 return mime_type; 93 return mime_type;
94 } 94 }
OLDNEW
« no previous file with comments | « chrome/browser/resources/uber/uber_frame.html ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698