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

Side by Side Diff: chrome_frame/cfproxy.h

Issue 5978003: Make IPC::Channel::Listener:OnMessageReceived have a return value indicating ... (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: '' Created 10 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 | Annotate | Revision Log
« no previous file with comments | « chrome/worker/worker_thread.cc ('k') | chrome_frame/cfproxy_private.h » ('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) 2010 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2010 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 #ifndef CHROME_FRAME_CFPROXY_H_ 5 #ifndef CHROME_FRAME_CFPROXY_H_
6 #define CHROME_FRAME_CFPROXY_H_ 6 #define CHROME_FRAME_CFPROXY_H_
7 #pragma once 7 #pragma once
8 8
9 #include <windows.h> 9 #include <windows.h>
10 #include <map> // for proxy factory 10 #include <map> // for proxy factory
(...skipping 130 matching lines...) Expand 10 before | Expand all | Expand 10 after
141 // Allow only one delegate per tab, i.e. delegate can handle only a single tab. 141 // Allow only one delegate per tab, i.e. delegate can handle only a single tab.
142 // Note: all of the methods are invoked always in a background IPC thread. 142 // Note: all of the methods are invoked always in a background IPC thread.
143 class ChromeProxyDelegate : public IPC::Channel::Listener { 143 class ChromeProxyDelegate : public IPC::Channel::Listener {
144 public: 144 public:
145 enum DisconnectReason { 145 enum DisconnectReason {
146 CHROME_EXE_LAUNCH_FAILED, 146 CHROME_EXE_LAUNCH_FAILED,
147 CHROME_EXE_LAUNCH_TIMEOUT, 147 CHROME_EXE_LAUNCH_TIMEOUT,
148 CHANNEL_ERROR 148 CHANNEL_ERROR
149 }; 149 };
150 150
151 // IPC::Channel::Listener.
152 void OnMessageReceived(const IPC::Message& message) = 0;
153
154 virtual void Connected(ChromeProxy* proxy) = 0; 151 virtual void Connected(ChromeProxy* proxy) = 0;
155 virtual void Disconnected() = 0; 152 virtual void Disconnected() = 0;
156 virtual void PeerLost(ChromeProxy* proxy, DisconnectReason reason) = 0; 153 virtual void PeerLost(ChromeProxy* proxy, DisconnectReason reason) = 0;
157 virtual int tab_handle() = 0; // to avoid reverse lookup :) 154 virtual int tab_handle() = 0; // to avoid reverse lookup :)
158 155
159 // Sync message responses. 156 // Sync message responses.
160 virtual void Completed_CreateTab(bool success, HWND chrome_wnd, 157 virtual void Completed_CreateTab(bool success, HWND chrome_wnd,
161 HWND tab_window, int tab_handle, int session_id) = 0; 158 HWND tab_window, int tab_handle, int session_id) = 0;
162 virtual void Completed_ConnectToTab(bool success, HWND chrome_window, 159 virtual void Completed_ConnectToTab(bool success, HWND chrome_window,
163 HWND tab_window, int tab_handle, int session_id) = 0; 160 HWND tab_window, int tab_handle, int session_id) = 0;
(...skipping 25 matching lines...) Expand all
189 void GetProxy(ChromeProxyDelegate* delegate, const ProxyParams& params); 186 void GetProxy(ChromeProxyDelegate* delegate, const ProxyParams& params);
190 bool ReleaseProxy(ChromeProxyDelegate* delegate, const std::string& profile); 187 bool ReleaseProxy(ChromeProxyDelegate* delegate, const std::string& profile);
191 protected: 188 protected:
192 virtual ChromeProxy* CreateProxy(); 189 virtual ChromeProxy* CreateProxy();
193 typedef std::map<std::string, ChromeProxy*> ProxyMap; 190 typedef std::map<std::string, ChromeProxy*> ProxyMap;
194 ProxyMap proxies_; 191 ProxyMap proxies_;
195 Lock lock_; 192 Lock lock_;
196 }; 193 };
197 194
198 #endif // CHROME_FRAME_CFPROXY_H_ 195 #endif // CHROME_FRAME_CFPROXY_H_
OLDNEW
« no previous file with comments | « chrome/worker/worker_thread.cc ('k') | chrome_frame/cfproxy_private.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698