| OLD | NEW |
| 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 #ifndef CHROME_BROWSER_UI_VIEWS_SIMPLE_MESSAGE_BOX_VIEWS_H_ | 5 #ifndef CHROME_BROWSER_UI_VIEWS_SIMPLE_MESSAGE_BOX_VIEWS_H_ |
| 6 #define CHROME_BROWSER_UI_VIEWS_SIMPLE_MESSAGE_BOX_VIEWS_H_ | 6 #define CHROME_BROWSER_UI_VIEWS_SIMPLE_MESSAGE_BOX_VIEWS_H_ |
| 7 #pragma once | 7 #pragma once |
| 8 | 8 |
| 9 #include "base/basictypes.h" | 9 #include "base/basictypes.h" |
| 10 #include "base/memory/ref_counted.h" | 10 #include "base/memory/ref_counted.h" |
| (...skipping 56 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 67 DIALOG_YES_NO, | 67 DIALOG_YES_NO, |
| 68 }; | 68 }; |
| 69 | 69 |
| 70 SimpleMessageBoxViews(gfx::NativeWindow parent_window, | 70 SimpleMessageBoxViews(gfx::NativeWindow parent_window, |
| 71 DialogType type, | 71 DialogType type, |
| 72 const string16& title, | 72 const string16& title, |
| 73 const string16& message); | 73 const string16& message); |
| 74 virtual ~SimpleMessageBoxViews(); | 74 virtual ~SimpleMessageBoxViews(); |
| 75 | 75 |
| 76 // MessageLoop::Dispatcher implementation. | 76 // MessageLoop::Dispatcher implementation. |
| 77 #if defined(OS_WIN) | |
| 78 // Dispatcher method. This returns true if the menu was canceled, or | 77 // Dispatcher method. This returns true if the menu was canceled, or |
| 79 // if the message is such that the menu should be closed. | 78 // if the message is such that the menu should be closed. |
| 80 virtual bool Dispatch(const MSG& msg) OVERRIDE; | 79 virtual bool Dispatch(const base::NativeEvent& event) OVERRIDE; |
| 81 #elif defined(USE_AURA) | |
| 82 virtual base::MessagePumpDispatcher::DispatchStatus Dispatch( | |
| 83 XEvent* xevent) OVERRIDE; | |
| 84 #endif | |
| 85 | 80 |
| 86 const DialogType type_; | 81 const DialogType type_; |
| 87 string16 message_box_title_; | 82 string16 message_box_title_; |
| 88 views::MessageBoxView* message_box_view_; | 83 views::MessageBoxView* message_box_view_; |
| 89 DispositionType disposition_; | 84 DispositionType disposition_; |
| 90 | 85 |
| 91 DISALLOW_COPY_AND_ASSIGN(SimpleMessageBoxViews); | 86 DISALLOW_COPY_AND_ASSIGN(SimpleMessageBoxViews); |
| 92 }; | 87 }; |
| 93 | 88 |
| 94 #endif // CHROME_BROWSER_UI_VIEWS_SIMPLE_MESSAGE_BOX_VIEWS_H_ | 89 #endif // CHROME_BROWSER_UI_VIEWS_SIMPLE_MESSAGE_BOX_VIEWS_H_ |
| OLD | NEW |