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

Side by Side Diff: ui/test/test_suite.cc

Issue 10151025: Add scale factor tag to data packs (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: fix build 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
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 "ui/test/test_suite.h" 5 #include "ui/test/test_suite.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 "build/build_config.h" 9 #include "build/build_config.h"
10 #include "ui/base/resource/resource_bundle.h" 10 #include "ui/base/resource/resource_bundle.h"
(...skipping 36 matching lines...) Expand 10 before | Expand all | Expand 10 after
47 pak_dir = pak_dir.AppendASCII("ui_unittests_strings"); 47 pak_dir = pak_dir.AppendASCII("ui_unittests_strings");
48 PathService::Override(ui::DIR_LOCALES, pak_dir); 48 PathService::Override(ui::DIR_LOCALES, pak_dir);
49 #endif // defined(OS_MACOSX) 49 #endif // defined(OS_MACOSX)
50 50
51 // Force unittests to run using en-US so if we test against string 51 // Force unittests to run using en-US so if we test against string
52 // output, it'll pass regardless of the system language. 52 // output, it'll pass regardless of the system language.
53 ui::ResourceBundle::InitSharedInstanceWithLocale("en-US"); 53 ui::ResourceBundle::InitSharedInstanceWithLocale("en-US");
54 54
55 #if !defined(OS_MACOSX) && defined(OS_POSIX) 55 #if !defined(OS_MACOSX) && defined(OS_POSIX)
56 ui::ResourceBundle::GetSharedInstance().AddDataPack( 56 ui::ResourceBundle::GetSharedInstance().AddDataPack(
57 pak_dir.AppendASCII("ui_resources.pak")); 57 pak_dir.AppendASCII("ui_resources.pak"), 1.0);
58 #endif 58 #endif
59 } 59 }
60 60
61 void UITestSuite::Shutdown() { 61 void UITestSuite::Shutdown() {
62 ui::ResourceBundle::CleanupSharedInstance(); 62 ui::ResourceBundle::CleanupSharedInstance();
63 63
64 #if defined(OS_MACOSX) 64 #if defined(OS_MACOSX)
65 base::mac::SetOverrideFrameworkBundle(NULL); 65 base::mac::SetOverrideFrameworkBundle(NULL);
66 #endif 66 #endif
67 base::TestSuite::Shutdown(); 67 base::TestSuite::Shutdown();
68 } 68 }
69 69
70 } // namespace test 70 } // namespace test
71 } // namespace ui 71 } // namespace ui
OLDNEW
« ui/base/resource/resource_handle.h ('K') | « ui/base/resource/resource_handle.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698