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

Side by Side Diff: win8/delegate_execute/delegate_execute.cc

Issue 740653005: Remove implicit conversions from scoped_refptr to T* in win8/ (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Address comments Created 6 years 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
« no previous file with comments | « no previous file | win8/metro_driver/ime/input_source.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 <atlbase.h> 5 #include <atlbase.h>
6 #include <atlcom.h> 6 #include <atlcom.h>
7 #include <atlctl.h> 7 #include <atlctl.h>
8 #include <initguid.h> 8 #include <initguid.h>
9 #include <shellapi.h> 9 #include <shellapi.h>
10 10
(...skipping 44 matching lines...) Expand 10 before | Expand all | Expand 10 after
55 if (FAILED(hr)) 55 if (FAILED(hr))
56 return hr; 56 return hr;
57 57
58 // We use the same class creation logic as ATL itself. See 58 // We use the same class creation logic as ATL itself. See
59 // _ATL_OBJMAP_ENTRY::RegisterClassObject() in atlbase.h 59 // _ATL_OBJMAP_ENTRY::RegisterClassObject() in atlbase.h
60 hr = ImplType::_ClassFactoryCreatorClass::CreateInstance( 60 hr = ImplType::_ClassFactoryCreatorClass::CreateInstance(
61 ImplType::_CreatorClass::CreateInstance, IID_IUnknown, 61 ImplType::_CreatorClass::CreateInstance, IID_IUnknown,
62 instance_.ReceiveVoid()); 62 instance_.ReceiveVoid());
63 if (FAILED(hr)) 63 if (FAILED(hr))
64 return hr; 64 return hr;
65 hr = ::CoRegisterClassObject(clsid, instance_, CLSCTX_LOCAL_SERVER, 65 hr = ::CoRegisterClassObject(clsid, instance_.get(), CLSCTX_LOCAL_SERVER,
66 REGCLS_MULTIPLEUSE | REGCLS_SUSPENDED, &registration_token_); 66 REGCLS_MULTIPLEUSE | REGCLS_SUSPENDED,
67 &registration_token_);
67 if (FAILED(hr)) 68 if (FAILED(hr))
68 return hr; 69 return hr;
69 70
70 return ParentClass::PreMessageLoop(nShowCmd); 71 return ParentClass::PreMessageLoop(nShowCmd);
71 } 72 }
72 73
73 HRESULT PostMessageLoop() { 74 HRESULT PostMessageLoop() {
74 if (registration_token_ != 0) { 75 if (registration_token_ != 0) {
75 ::CoRevokeClassObject(registration_token_); 76 ::CoRevokeClassObject(registration_token_);
76 registration_token_ = 0; 77 registration_token_ = 0;
(...skipping 115 matching lines...) Expand 10 before | Expand all | Expand 10 after
192 case DelegateExecuteOperation::RELAUNCH_CHROME: 193 case DelegateExecuteOperation::RELAUNCH_CHROME:
193 ret_code = RelaunchChrome(operation); 194 ret_code = RelaunchChrome(operation);
194 break; 195 break;
195 default: 196 default:
196 NOTREACHED(); 197 NOTREACHED();
197 } 198 }
198 } 199 }
199 AtlTrace("delegate_execute exit, code = %d\n", ret_code); 200 AtlTrace("delegate_execute exit, code = %d\n", ret_code);
200 return ret_code; 201 return ret_code;
201 } 202 }
OLDNEW
« no previous file with comments | « no previous file | win8/metro_driver/ime/input_source.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698