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

Side by Side Diff: chrome_frame/test/net/fake_external_tab.cc

Issue 10270023: Add new ResourceBundle::Delegate interface. (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/tools/profiles/generate_profile.cc ('k') | ui/aura/demo/demo_main.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) 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_frame/test/net/fake_external_tab.h" 5 #include "chrome_frame/test/net/fake_external_tab.h"
6 6
7 #include <atlbase.h> 7 #include <atlbase.h>
8 #include <atlcom.h> 8 #include <atlcom.h>
9 #include <exdisp.h> 9 #include <exdisp.h>
10 #include <Winsock2.h> 10 #include <Winsock2.h>
(...skipping 440 matching lines...) Expand 10 before | Expand all | Expand 10 after
451 451
452 // Load Chrome.dll as our resource dll. 452 // Load Chrome.dll as our resource dll.
453 FilePath dll; 453 FilePath dll;
454 PathService::Get(base::DIR_MODULE, &dll); 454 PathService::Get(base::DIR_MODULE, &dll);
455 dll = dll.Append(chrome::kBrowserResourcesDll); 455 dll = dll.Append(chrome::kBrowserResourcesDll);
456 HMODULE res_mod = ::LoadLibraryExW(dll.value().c_str(), 456 HMODULE res_mod = ::LoadLibraryExW(dll.value().c_str(),
457 NULL, LOAD_LIBRARY_AS_DATAFILE | LOAD_LIBRARY_AS_IMAGE_RESOURCE); 457 NULL, LOAD_LIBRARY_AS_DATAFILE | LOAD_LIBRARY_AS_IMAGE_RESOURCE);
458 DCHECK(res_mod); 458 DCHECK(res_mod);
459 _AtlBaseModule.SetResourceInstance(res_mod); 459 _AtlBaseModule.SetResourceInstance(res_mod);
460 460
461 ResourceBundle::InitSharedInstanceWithLocale("en-US"); 461 ResourceBundle::InitSharedInstanceWithLocale("en-US", NULL);
462 462
463 CommandLine* cmd = CommandLine::ForCurrentProcess(); 463 CommandLine* cmd = CommandLine::ForCurrentProcess();
464 cmd->AppendSwitch(switches::kDisableWebResources); 464 cmd->AppendSwitch(switches::kDisableWebResources);
465 cmd->AppendSwitch(switches::kSingleProcess); 465 cmd->AppendSwitch(switches::kSingleProcess);
466 466
467 browser_process_.reset(new FakeBrowserProcessImpl(*cmd)); 467 browser_process_.reset(new FakeBrowserProcessImpl(*cmd));
468 // BrowserProcessImpl's constructor should set g_browser_process. 468 // BrowserProcessImpl's constructor should set g_browser_process.
469 DCHECK(g_browser_process); 469 DCHECK(g_browser_process);
470 g_browser_process->SetApplicationLocale("en-US"); 470 g_browser_process->SetApplicationLocale("en-US");
471 471
(...skipping 419 matching lines...) Expand 10 before | Expand all | Expand 10 after
891 // content::InitializeSandboxInfo(&sandbox_info); 891 // content::InitializeSandboxInfo(&sandbox_info);
892 FakeMainDelegate delegate; 892 FakeMainDelegate delegate;
893 content::ContentMain( 893 content::ContentMain(
894 reinterpret_cast<HINSTANCE>(GetModuleHandle(NULL)), 894 reinterpret_cast<HINSTANCE>(GetModuleHandle(NULL)),
895 &sandbox_info, 895 &sandbox_info,
896 &delegate); 896 &delegate);
897 897
898 // Note: In debug builds, we ExitProcess during PostDestroyThreads. 898 // Note: In debug builds, we ExitProcess during PostDestroyThreads.
899 return g_test_suite->test_result(); 899 return g_test_suite->test_result();
900 } 900 }
OLDNEW
« no previous file with comments | « chrome/tools/profiles/generate_profile.cc ('k') | ui/aura/demo/demo_main.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698