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

Side by Side Diff: chrome/browser/ui/cocoa/about_ipc_dialog.h

Issue 6265015: [Mac] Merge single-function file about_ipc_dialog.{h,mm} into about_ipc_bridge.{h,mm}. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: '' Created 9 years, 11 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
OLDNEW
1 // Copyright (c) 2009 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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_BROWSER_UI_COCOA_ABOUT_IPC_DIALOG_H_ 5 #ifndef CHROME_BROWSER_UI_COCOA_ABOUT_IPC_DIALOG_H_
6 #define CHROME_BROWSER_UI_COCOA_ABOUT_IPC_DIALOG_H_ 6 #define CHROME_BROWSER_UI_COCOA_ABOUT_IPC_DIALOG_H_
7 #pragma once 7 #pragma once
8 8
9 #include "ipc/ipc_message.h" 9 #include "ipc/ipc_logging.h"
10 #include "ipc/ipc_message_utils.h"
10 11
11 #if defined(IPC_MESSAGE_LOG_ENABLED) 12 #if defined(IPC_MESSAGE_LOG_ENABLED)
12 13
14 #ifdef __OBJC__
15 @class AboutIPCController;
16 #else
17 class AboutIPCController;
18 #endif
19
13 namespace AboutIPCDialog { 20 namespace AboutIPCDialog {
14 // The dialog is a singleton. If the dialog is already opened, it won't do 21 // The dialog is a singleton. If the dialog is already opened, it won't do
15 // anything, so you can just blindly call this function all you want. 22 // anything, so you can just blindly call this function all you want.
16 // RunDialog() is Called from chrome/browser/browser_about_handler.cc 23 // RunDialog() is Called from chrome/browser/browser_about_handler.cc
17 // in response to an about:ipc URL. 24 // in response to an about:ipc URL.
18 void RunDialog(); 25 void RunDialog();
26 }
27
28 // On Windows, the AboutIPCDialog is a views::View. On Mac we have a
29 // Cocoa dialog. This class bridges from C++ to ObjC.
30 class AboutIPCBridge : public IPC::Logging::Consumer {
31 public:
32 AboutIPCBridge(AboutIPCController* controller) : controller_(controller) { }
33 virtual ~AboutIPCBridge() { }
34
35 // IPC::Logging::Consumer implementation.
36 virtual void Log(const IPC::LogData& data);
37
38 private:
39 AboutIPCController* controller_; // weak; owns me
40 DISALLOW_COPY_AND_ASSIGN(AboutIPCBridge);
19 }; 41 };
20 42
43 #endif // IPC_MESSAGE_LOG_ENABLED
21 44
22 #endif /* IPC_MESSAGE_LOG_ENABLED */ 45 #endif // CHROME_BROWSER_UI_COCOA_ABOUT_IPC_DIALOG_H_
23
24 #endif /* CHROME_BROWSER_UI_COCOA_ABOUT_IPC_DIALOG_H_ */
OLDNEW
« no previous file with comments | « chrome/browser/ui/cocoa/about_ipc_controller.h ('k') | chrome/browser/ui/cocoa/about_ipc_dialog.mm » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698