OLD | NEW |
1 // Copyright (c) 2011 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 #include "chrome/browser/ui/views/chrome_views_delegate.h" | 5 #include "chrome/browser/ui/views/chrome_views_delegate.h" |
6 | 6 |
7 #include "base/memory/scoped_ptr.h" | 7 #include "base/memory/scoped_ptr.h" |
8 #include "base/string_util.h" | 8 #include "base/string_util.h" |
9 #include "base/utf_string_conversions.h" | 9 #include "base/utf_string_conversions.h" |
10 #include "chrome/browser/browser_process.h" | 10 #include "chrome/browser/browser_process.h" |
11 #include "chrome/browser/prefs/pref_service.h" | 11 #include "chrome/browser/prefs/pref_service.h" |
12 #include "chrome/browser/prefs/scoped_user_pref_update.h" | 12 #include "chrome/browser/prefs/scoped_user_pref_update.h" |
13 #include "chrome/browser/profiles/profile_manager.h" | 13 #include "chrome/browser/profiles/profile_manager.h" |
14 #include "chrome/browser/ui/views/accessibility_event_router_views.h" | 14 #include "chrome/browser/ui/views/accessibility_event_router_views.h" |
15 #include "chrome/browser/ui/views/event_utils.h" | 15 #include "chrome/browser/ui/views/event_utils.h" |
16 #include "chrome/browser/ui/window_sizer.h" | 16 #include "chrome/browser/ui/window_sizer.h" |
17 #include "chrome/common/pref_names.h" | 17 #include "chrome/common/pref_names.h" |
18 #include "ui/base/clipboard/clipboard.h" | 18 #include "ui/base/clipboard/clipboard.h" |
19 #include "ui/gfx/rect.h" | 19 #include "ui/gfx/rect.h" |
20 #include "views/widget/native_widget.h" | 20 #include "ui/views/widget/native_widget.h" |
21 #include "views/widget/widget.h" | 21 #include "ui/views/widget/widget.h" |
22 | 22 |
23 #if defined(OS_WIN) | 23 #if defined(OS_WIN) |
24 #include "chrome/browser/app_icon_win.h" | 24 #include "chrome/browser/app_icon_win.h" |
25 #endif | 25 #endif |
26 | 26 |
27 namespace { | 27 namespace { |
28 | 28 |
29 // If the given window has a profile associated with it, use that profile's | 29 // If the given window has a profile associated with it, use that profile's |
30 // preference service. Otherwise, store and retrieve the data from Local State. | 30 // preference service. Otherwise, store and retrieve the data from Local State. |
31 // This function may return NULL if the necessary pref service has not yet | 31 // This function may return NULL if the necessary pref service has not yet |
(...skipping 99 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
131 g_browser_process->AddRefModule(); | 131 g_browser_process->AddRefModule(); |
132 } | 132 } |
133 | 133 |
134 void ChromeViewsDelegate::ReleaseRef() { | 134 void ChromeViewsDelegate::ReleaseRef() { |
135 g_browser_process->ReleaseModule(); | 135 g_browser_process->ReleaseModule(); |
136 } | 136 } |
137 | 137 |
138 int ChromeViewsDelegate::GetDispositionForEvent(int event_flags) { | 138 int ChromeViewsDelegate::GetDispositionForEvent(int event_flags) { |
139 return event_utils::DispositionFromEventFlags(event_flags); | 139 return event_utils::DispositionFromEventFlags(event_flags); |
140 } | 140 } |
OLD | NEW |