| OLD | NEW |
| (Empty) | |
| 1 // Copyright 2013 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 |
| 5 #ifndef CHROME_BROWSER_UI_SCREEN_CAPTURE_CONFIRMATION_UI_INFOBAR_H_ |
| 6 #define CHROME_BROWSER_UI_SCREEN_CAPTURE_CONFIRMATION_UI_INFOBAR_H_ |
| 7 |
| 8 #include "base/basictypes.h" |
| 9 #include "chrome/browser/ui/screen_capture_confirmation_ui.h" |
| 10 #include "chrome/browser/ui/screen_capture_infobar_delegate.h" |
| 11 |
| 12 namespace content { |
| 13 class WebContents; |
| 14 } |
| 15 |
| 16 // Implements ScreenCaptureConfirmationUI using infobar. |
| 17 // |
| 18 // TODO(sergeyu): Replace this class with a confirmation prompt that doesn't use |
| 19 // infobars. |
| 20 class ScreenCaptureConfirmationUIInfobar |
| 21 : public ScreenCaptureConfirmationUI { |
| 22 public: |
| 23 explicit ScreenCaptureConfirmationUIInfobar( |
| 24 content::WebContents* web_contents); |
| 25 virtual ~ScreenCaptureConfirmationUIInfobar(); |
| 26 |
| 27 // ScreenCaptureConfirmationUI interface. |
| 28 virtual bool Show(const ResultCallback& result_callback, |
| 29 const string16& title) OVERRIDE; |
| 30 |
| 31 // Called by ScreenCaptureInfoBarDelegate. |
| 32 void OnInfobarResult(bool allow); |
| 33 |
| 34 private: |
| 35 ResultCallback result_callback_; |
| 36 InfoBarService* infobar_service_; |
| 37 ScreenCaptureInfoBarDelegate* delegate_; |
| 38 |
| 39 DISALLOW_COPY_AND_ASSIGN(ScreenCaptureConfirmationUIInfobar); |
| 40 }; |
| 41 |
| 42 #endif // CHROME_BROWSER_UI_SCREEN_CAPTURE_CONFIRMATION_UI_INFOBAR_H_ |
| OLD | NEW |