• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 // Copyright (c) 2010 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_VIEWS_CHROME_VIEWS_DELEGATE_H_
6 #define CHROME_BROWSER_UI_VIEWS_CHROME_VIEWS_DELEGATE_H_
7 #pragma once
8 
9 #include "base/basictypes.h"
10 #include "build/build_config.h"
11 #include "ui/base/accessibility/accessibility_types.h"
12 #include "views/views_delegate.h"
13 
14 namespace views {
15 class Window;
16 }
17 
18 class ChromeViewsDelegate : public views::ViewsDelegate {
19  public:
ChromeViewsDelegate()20   ChromeViewsDelegate() {}
~ChromeViewsDelegate()21   virtual ~ChromeViewsDelegate() {}
22 
23   // Overridden from views::ViewsDelegate:
24   virtual ui::Clipboard* GetClipboard() const;
25   virtual void SaveWindowPlacement(views::Window* window,
26                                    const std::wstring& window_name,
27                                    const gfx::Rect& bounds,
28                                    bool maximized);
29   virtual bool GetSavedWindowBounds(views::Window* window,
30                                     const std::wstring& window_name,
31                                     gfx::Rect* bounds) const;
32   virtual bool GetSavedMaximizedState(views::Window* window,
33                                       const std::wstring& window_name,
34                                       bool* maximized) const;
35   virtual void NotifyAccessibilityEvent(
36       views::View* view, ui::AccessibilityTypes::Event event_type);
37   virtual void NotifyMenuItemFocused(
38       const std::wstring& menu_name,
39       const std::wstring& menu_item_name,
40       int item_index,
41       int item_count,
42       bool has_submenu);
43 
44 #if defined(OS_WIN)
45   virtual HICON GetDefaultWindowIcon() const;
46 #endif
47   virtual void AddRef();
48   virtual void ReleaseRef();
49 
50  private:
51   DISALLOW_COPY_AND_ASSIGN(ChromeViewsDelegate);
52 };
53 
54 #endif  // CHROME_BROWSER_UI_VIEWS_CHROME_VIEWS_DELEGATE_H_
55