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

Side by Side Diff: base/win/metro.cc

Issue 10470002: Add ShellIntegration::ActivateMetroChrome, which launches Chrome in metro-mode on Windows 8. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: metro_exports -> metro Created 8 years, 6 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 | « base/win/metro.h ('k') | chrome/app/metro_driver_win.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 "base/win/metro.h" 5 #include "base/win/metro.h"
6 6
7 #include "base/string_util.h" 7 #include "base/string_util.h"
8 8
9 namespace base { 9 namespace base {
10 namespace win { 10 namespace win {
11 11
12 const char kActivateApplication[] = "ActivateApplication";
13
12 HMODULE GetMetroModule() { 14 HMODULE GetMetroModule() {
13 return GetModuleHandleA("metro_driver.dll"); 15 return GetModuleHandleA("metro_driver.dll");
14 } 16 }
15 17
16 wchar_t* LocalAllocAndCopyString(const string16& src) { 18 wchar_t* LocalAllocAndCopyString(const string16& src) {
17 size_t dest_size = (src.length() + 1) * sizeof(wchar_t); 19 size_t dest_size = (src.length() + 1) * sizeof(wchar_t);
18 wchar_t* dest = reinterpret_cast<wchar_t*>(LocalAlloc(LPTR, dest_size)); 20 wchar_t* dest = reinterpret_cast<wchar_t*>(LocalAlloc(LPTR, dest_size));
19 base::wcslcpy(dest, src.c_str(), dest_size); 21 base::wcslcpy(dest, src.c_str(), dest_size);
20 return dest; 22 return dest;
21 } 23 }
22 24
23 } // namespace win 25 } // namespace win
24 } // namespace base 26 } // namespace base
25
OLDNEW
« no previous file with comments | « base/win/metro.h ('k') | chrome/app/metro_driver_win.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698