1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
|
// Copyright (c) 2010 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
#include "chrome/browser/tab_contents/tab_contents_delegate.h"
#include "chrome/browser/search_engines/template_url.h"
#include "gfx/rect.h"
void TabContentsDelegate::DetachContents(TabContents* source) {
}
bool TabContentsDelegate::IsPopup(const TabContents* source) const {
return false;
}
TabContents* TabContentsDelegate::GetConstrainingContents(TabContents* source) {
return source;
}
bool TabContentsDelegate::ShouldFocusConstrainedWindow(TabContents* source) {
return true;
}
void TabContentsDelegate::WillShowConstrainedWindow(TabContents* source) {
}
void TabContentsDelegate::ContentsMouseEvent(
TabContents* source, const gfx::Point& location, bool motion) {
}
void TabContentsDelegate::ContentsZoomChange(bool zoom_in) { }
void TabContentsDelegate::OnContentSettingsChange(TabContents* source) { }
bool TabContentsDelegate::IsApplication() const { return false; }
void TabContentsDelegate::ConvertContentsToApplication(TabContents* source) { }
bool TabContentsDelegate::CanReloadContents(TabContents* source) const {
return true;
}
gfx::Rect TabContentsDelegate::GetRootWindowResizerRect() const {
return gfx::Rect();
}
void TabContentsDelegate::ShowHtmlDialog(HtmlDialogUIDelegate* delegate,
gfx::NativeWindow parent_window) {
}
void TabContentsDelegate::BeforeUnloadFired(TabContents* tab,
bool proceed,
bool* proceed_to_fire_unload) {
*proceed_to_fire_unload = true;
}
void TabContentsDelegate::ForwardMessageToExternalHost(
const std::string& message,
const std::string& origin,
const std::string& target) {
}
bool TabContentsDelegate::IsExternalTabContainer() const { return false; }
void TabContentsDelegate::SetFocusToLocationBar(bool select_all) {}
bool TabContentsDelegate::ShouldFocusPageAfterCrash() {
return true;
}
void TabContentsDelegate::RenderWidgetShowing() {}
ExtensionFunctionDispatcher*
TabContentsDelegate::CreateExtensionFunctionDispatcher(
RenderViewHost* render_view_host,
const std::string& extension_id) {
return NULL;
}
bool TabContentsDelegate::TakeFocus(bool reverse) {
return false;
}
void TabContentsDelegate::LostCapture() {
}
void TabContentsDelegate::SetTabContentBlocked(
TabContents* contents, bool blocked) {
}
void TabContentsDelegate::TabContentsFocused(TabContents* tab_content) {
}
int TabContentsDelegate::GetExtraRenderViewHeight() const {
return 0;
}
bool TabContentsDelegate::CanDownload(int request_id) {
return true;
}
void TabContentsDelegate::OnStartDownload(DownloadItem* download,
TabContents* tab) {
}
bool TabContentsDelegate::HandleContextMenu(const ContextMenuParams& params) {
return false;
}
bool TabContentsDelegate::ExecuteContextMenuCommand(int command) {
return false;
}
void TabContentsDelegate::ConfirmSetDefaultSearchProvider(
TabContents* tab_contents,
TemplateURL* template_url,
TemplateURLModel* template_url_model) {
delete template_url;
}
void TabContentsDelegate::ConfirmAddSearchProvider(
const TemplateURL* template_url,
Profile* profile) {
delete template_url;
}
void TabContentsDelegate::ShowPageInfo(Profile* profile,
const GURL& url,
const NavigationEntry::SSLStatus& ssl,
bool show_history) {
}
bool TabContentsDelegate::PreHandleKeyboardEvent(
const NativeWebKeyboardEvent& event,
bool* is_keyboard_shortcut) {
return false;
}
void TabContentsDelegate::HandleKeyboardEvent(
const NativeWebKeyboardEvent& event) {
}
void TabContentsDelegate::HandleMouseUp() {
}
void TabContentsDelegate::HandleMouseActivate() {
}
void TabContentsDelegate::ShowRepostFormWarningDialog(
TabContents* tab_contents) {
}
void TabContentsDelegate::ShowContentSettingsWindow(
ContentSettingsType content_type) {
}
void TabContentsDelegate::ShowCollectedCookiesDialog(
TabContents* tab_contents) {
}
bool TabContentsDelegate::OnGoToEntryOffset(int offset) {
return true;
}
bool TabContentsDelegate::ShouldAddNavigationToHistory(
const history::HistoryAddPageArgs& add_page_args,
NavigationType::Type navigation_type) {
return true;
}
void TabContentsDelegate::OnDidGetApplicationInfo(TabContents* tab_contents,
int32 page_id) {
}
gfx::NativeWindow TabContentsDelegate::GetFrameNativeWindow() {
return NULL;
}
void TabContentsDelegate::TabContentsCreated(TabContents* new_contents) {
}
bool TabContentsDelegate::infobars_enabled() {
return true;
}
bool TabContentsDelegate::ShouldEnablePreferredSizeNotifications() {
return false;
}
void TabContentsDelegate::UpdatePreferredSize(const gfx::Size& pref_size) {
}
void TabContentsDelegate::OnSetSuggestResult(int32 page_id,
const std::string& result) {
}
void TabContentsDelegate::ContentRestrictionsChanged(TabContents* source) {
}
TabContentsDelegate::~TabContentsDelegate() {
}
|