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
3 // found in the LICENSE file.
5 #ifndef UI_VIEWS_TEST_TEST_VIEWS_DELEGATE_H_
6 #define UI_VIEWS_TEST_TEST_VIEWS_DELEGATE_H_
8 #include "base/basictypes.h"
9 #include "base/compiler_specific.h"
10 #include "base/memory/scoped_ptr.h"
11 #include "build/build_config.h"
12 #include "ui/base/accessibility/accessibility_types.h"
13 #include "ui/views/views_delegate.h"
23 class TestViewsDelegate : public ViewsDelegate {
26 virtual ~TestViewsDelegate();
28 void SetUseTransparentWindows(bool transparent);
30 // Overridden from ViewsDelegate:
31 virtual void SaveWindowPlacement(const Widget* window,
32 const std::string& window_name,
33 const gfx::Rect& bounds,
34 ui::WindowShowState show_state) OVERRIDE;
35 virtual bool GetSavedWindowPlacement(
37 const std::string& window_name,
39 ui::WindowShowState* show_state) const OVERRIDE;
41 virtual void NotifyAccessibilityEvent(
42 View* view, ui::AccessibilityTypes::Event event_type) OVERRIDE {}
44 virtual void NotifyMenuItemFocused(const string16& menu_name,
45 const string16& menu_item_name,
48 bool has_submenu) OVERRIDE {}
50 virtual HICON GetDefaultWindowIcon() const OVERRIDE {
54 virtual NonClientFrameView* CreateDefaultNonClientFrameView(
55 Widget* widget) OVERRIDE;
56 virtual bool UseTransparentWindows() const OVERRIDE;
57 virtual void AddRef() OVERRIDE {}
58 virtual void ReleaseRef() OVERRIDE {}
59 virtual content::WebContents* CreateWebContents(
60 content::BrowserContext* browser_context,
61 content::SiteInstance* site_instance) OVERRIDE;
62 virtual void OnBeforeWidgetInit(
63 Widget::InitParams* params,
64 internal::NativeWidgetDelegate* delegate) OVERRIDE;
65 virtual base::TimeDelta GetDefaultTextfieldObscuredRevealDuration() OVERRIDE;
68 bool use_transparent_windows_;
70 DISALLOW_COPY_AND_ASSIGN(TestViewsDelegate);
75 #endif // UI_VIEWS_TEST_TEST_VIEWS_DELEGATE_H_