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

Side by Side Diff: chrome/browser/themes/browser_theme_pack.cc

Issue 8437002: Move BrowserThread to content namespace. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: A few updates. Created 9 years, 1 month 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
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/themes/browser_theme_pack.h" 5 #include "chrome/browser/themes/browser_theme_pack.h"
6 6
7 #include <limits> 7 #include <limits>
8 8
9 #include "base/stl_util.h" 9 #include "base/stl_util.h"
10 #include "base/string_util.h" 10 #include "base/string_util.h"
11 #include "base/threading/thread_restrictions.h" 11 #include "base/threading/thread_restrictions.h"
12 #include "base/utf_string_conversions.h" 12 #include "base/utf_string_conversions.h"
13 #include "base/values.h" 13 #include "base/values.h"
14 #include "chrome/browser/themes/theme_service.h" 14 #include "chrome/browser/themes/theme_service.h"
15 #include "content/public/browser/browser_thread.h" 15 #include "content/public/browser/browser_thread.h"
16 #include "grit/theme_resources.h" 16 #include "grit/theme_resources.h"
17 #include "grit/theme_resources_standard.h" 17 #include "grit/theme_resources_standard.h"
18 #include "grit/ui_resources.h" 18 #include "grit/ui_resources.h"
19 #include "net/base/file_stream.h" 19 #include "net/base/file_stream.h"
20 #include "net/base/net_errors.h" 20 #include "net/base/net_errors.h"
21 #include "third_party/skia/include/core/SkCanvas.h" 21 #include "third_party/skia/include/core/SkCanvas.h"
22 #include "ui/base/resource/data_pack.h" 22 #include "ui/base/resource/data_pack.h"
23 #include "ui/base/resource/resource_bundle.h" 23 #include "ui/base/resource/resource_bundle.h"
24 #include "ui/gfx/codec/png_codec.h" 24 #include "ui/gfx/codec/png_codec.h"
25 #include "ui/gfx/image/image.h" 25 #include "ui/gfx/image/image.h"
26 #include "ui/gfx/skbitmap_operations.h" 26 #include "ui/gfx/skbitmap_operations.h"
27 27
28 using content::BrowserThread;
29
28 namespace { 30 namespace {
29 31
30 // Version number of the current theme pack. We just throw out and rebuild 32 // Version number of the current theme pack. We just throw out and rebuild
31 // theme packs that aren't int-equal to this. 33 // theme packs that aren't int-equal to this.
32 const int kThemePackVersion = 18; 34 const int kThemePackVersion = 18;
33 35
34 // IDs that are in the DataPack won't clash with the positive integer 36 // IDs that are in the DataPack won't clash with the positive integer
35 // uint16. kHeaderID should always have the maximum value because we want the 37 // uint16. kHeaderID should always have the maximum value because we want the
36 // "header" to be written last. That way we can detect whether the pack was 38 // "header" to be written last. That way we can detect whether the pack was
37 // successfully written and ignore and regenerate if it was only partially 39 // successfully written and ignore and regenerate if it was only partially
(...skipping 1022 matching lines...) Expand 10 before | Expand all | Expand 10 after
1060 hsl.h = tints_[i].h; 1062 hsl.h = tints_[i].h;
1061 hsl.s = tints_[i].s; 1063 hsl.s = tints_[i].s;
1062 hsl.l = tints_[i].l; 1064 hsl.l = tints_[i].l;
1063 return hsl; 1065 return hsl;
1064 } 1066 }
1065 } 1067 }
1066 } 1068 }
1067 1069
1068 return ThemeService::GetDefaultTint(id); 1070 return ThemeService::GetDefaultTint(id);
1069 } 1071 }
OLDNEW
« no previous file with comments | « chrome/browser/themes/browser_theme_pack.h ('k') | chrome/browser/themes/browser_theme_pack_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698