OLD | NEW |
(Empty) | |
| 1 // Copyright (c) 2009 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. |
| 4 #ifndef CHROME_FRAME_TEST_NET_PROCESS_SINGLETON_SUBCLASS_H_ |
| 5 #define CHROME_FRAME_TEST_NET_PROCESS_SINGLETON_SUBCLASS_H_ |
| 6 |
| 7 #include <windows.h> |
| 8 #include "base/file_path.h" |
| 9 |
| 10 struct FunctionStub; |
| 11 |
| 12 class ProcessSingletonSubclassDelegate { |
| 13 public: |
| 14 virtual void OnConnectAutomationProviderToChannel( |
| 15 const std::string& channel_id) = 0; |
| 16 }; |
| 17 |
| 18 class ProcessSingletonSubclass { |
| 19 public: |
| 20 ProcessSingletonSubclass(ProcessSingletonSubclassDelegate* delegate); |
| 21 ~ProcessSingletonSubclass(); |
| 22 |
| 23 bool Subclass(const FilePath& user_data_dir); |
| 24 |
| 25 protected: |
| 26 static LRESULT CALLBACK SubclassWndProc(ProcessSingletonSubclass* me, |
| 27 HWND hwnd, UINT msg, WPARAM wp, LPARAM lp); |
| 28 LRESULT OnCopyData(HWND hwnd, HWND from_hwnd, const COPYDATASTRUCT* cds); |
| 29 protected: |
| 30 FunctionStub* stub_; |
| 31 ProcessSingletonSubclassDelegate* delegate_; |
| 32 WNDPROC original_wndproc_; |
| 33 }; |
| 34 |
| 35 #endif // CHROME_FRAME_TEST_NET_PROCESS_SINGLETON_SUBCLASS_H_ |
| 36 |
OLD | NEW |