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

Side by Side Diff: content/browser/browser_io_surface_manager_mac.h

Issue 1351753002: Mac: Ensure that Mach messages always get a reply (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: IRF Created 5 years, 3 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
« no previous file with comments | « no previous file | content/browser/browser_io_surface_manager_mac.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 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 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 CONTENT_BROWSER_BROWSER_IO_SURFACE_MANAGER_MAC_H_ 5 #ifndef CONTENT_BROWSER_BROWSER_IO_SURFACE_MANAGER_MAC_H_
6 #define CONTENT_BROWSER_BROWSER_IO_SURFACE_MANAGER_MAC_H_ 6 #define CONTENT_BROWSER_BROWSER_IO_SURFACE_MANAGER_MAC_H_
7 7
8 #include <mach/mach.h> 8 #include <mach/mach.h>
9 9
10 #include <map> 10 #include <map>
(...skipping 61 matching lines...) Expand 10 before | Expand all | Expand 10 after
72 ~BrowserIOSurfaceManager() override; 72 ~BrowserIOSurfaceManager() override;
73 73
74 // Performs any initialization work. 74 // Performs any initialization work.
75 bool Initialize(); 75 bool Initialize();
76 76
77 // Message handler that is invoked on |dispatch_source_| when an 77 // Message handler that is invoked on |dispatch_source_| when an
78 // incoming message needs to be received. 78 // incoming message needs to be received.
79 void HandleRequest(); 79 void HandleRequest();
80 80
81 // Message handlers that are invoked from HandleRequest. 81 // Message handlers that are invoked from HandleRequest.
82 bool HandleRegisterIOSurfaceRequest( 82 void HandleRegisterIOSurfaceRequest(
83 const IOSurfaceManagerHostMsg_RegisterIOSurface& request, 83 const IOSurfaceManagerHostMsg_RegisterIOSurface& request,
84 IOSurfaceManagerMsg_RegisterIOSurfaceReply* reply); 84 IOSurfaceManagerMsg_RegisterIOSurfaceReply* reply);
85 bool HandleUnregisterIOSurfaceRequest( 85 bool HandleUnregisterIOSurfaceRequest(
86 const IOSurfaceManagerHostMsg_UnregisterIOSurface& request); 86 const IOSurfaceManagerHostMsg_UnregisterIOSurface& request);
87 bool HandleAcquireIOSurfaceRequest( 87 void HandleAcquireIOSurfaceRequest(
88 const IOSurfaceManagerHostMsg_AcquireIOSurface& request, 88 const IOSurfaceManagerHostMsg_AcquireIOSurface& request,
89 IOSurfaceManagerMsg_AcquireIOSurfaceReply* reply); 89 IOSurfaceManagerMsg_AcquireIOSurfaceReply* reply);
90 90
91 // Whether or not the class has been initialized. 91 // Whether or not the class has been initialized.
92 bool initialized_; 92 bool initialized_;
93 93
94 // The Mach port on which the server listens. 94 // The Mach port on which the server listens.
95 base::mac::ScopedMachReceiveRight server_port_; 95 base::mac::ScopedMachReceiveRight server_port_;
96 96
97 // The dispatch source and queue on which Mach messages will be received. 97 // The dispatch source and queue on which Mach messages will be received.
(...skipping 18 matching lines...) Expand all
116 // Mutex that guards |initialized_|, |io_surfaces_|, |child_process_ids_| 116 // Mutex that guards |initialized_|, |io_surfaces_|, |child_process_ids_|
117 // and |gpu_process_token_|. 117 // and |gpu_process_token_|.
118 base::Lock lock_; 118 base::Lock lock_;
119 119
120 DISALLOW_COPY_AND_ASSIGN(BrowserIOSurfaceManager); 120 DISALLOW_COPY_AND_ASSIGN(BrowserIOSurfaceManager);
121 }; 121 };
122 122
123 } // namespace content 123 } // namespace content
124 124
125 #endif // CONTENT_BROWSER_BROWSER_IO_SURFACE_MANAGER_MAC_H_ 125 #endif // CONTENT_BROWSER_BROWSER_IO_SURFACE_MANAGER_MAC_H_
OLDNEW
« no previous file with comments | « no previous file | content/browser/browser_io_surface_manager_mac.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698