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/tab_contents/tab_contents_view_touch.h" | 5 #include "chrome/browser/ui/views/tab_contents/tab_contents_view_touch.h" |
6 | 6 |
7 #include <X11/extensions/XInput2.h> | 7 #include <X11/extensions/XInput2.h> |
8 #undef Status | 8 #undef Status |
9 | 9 |
10 #include "base/string_util.h" | 10 #include "base/string_util.h" |
(...skipping 204 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
215 // if the location bar was focused and the tab is dragged out), or it may | 215 // if the location bar was focused and the tab is dragged out), or it may |
216 // no longer be focusable (e.g. if the location bar was focused and then | 216 // no longer be focusable (e.g. if the location bar was focused and then |
217 // we switched to fullscreen mode). In that case we default to the | 217 // we switched to fullscreen mode). In that case we default to the |
218 // default focus. | 218 // default focus. |
219 SetInitialFocus(); | 219 SetInitialFocus(); |
220 } | 220 } |
221 view_storage->RemoveView(last_focused_view_storage_id_); | 221 view_storage->RemoveView(last_focused_view_storage_id_); |
222 } | 222 } |
223 } | 223 } |
224 | 224 |
225 void TabContentsViewTouch::UpdatePreferredSize(const gfx::Size& pref_size) { | |
226 } | |
227 | |
228 bool TabContentsViewTouch::IsDoingDrag() const { | 225 bool TabContentsViewTouch::IsDoingDrag() const { |
229 return false; | 226 return false; |
230 } | 227 } |
231 | 228 |
232 void TabContentsViewTouch::CancelDragAndCloseTab() { | 229 void TabContentsViewTouch::CancelDragAndCloseTab() { |
233 } | 230 } |
234 | 231 |
235 bool TabContentsViewTouch::IsEventTracking() const { | 232 bool TabContentsViewTouch::IsEventTracking() const { |
236 return false; | 233 return false; |
237 } | 234 } |
(...skipping 186 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
424 rwhv->SetSize(size); | 421 rwhv->SetSize(size); |
425 | 422 |
426 if (needs_resize) | 423 if (needs_resize) |
427 SetFloatingPosition(size); | 424 SetFloatingPosition(size); |
428 } | 425 } |
429 | 426 |
430 void TabContentsViewTouch::SetFloatingPosition(const gfx::Size& size) { | 427 void TabContentsViewTouch::SetFloatingPosition(const gfx::Size& size) { |
431 // TODO(anicolao): rework this once we have WebUI views for dialogs | 428 // TODO(anicolao): rework this once we have WebUI views for dialogs |
432 SetBounds(x(), y(), size.width(), size.height()); | 429 SetBounds(x(), y(), size.width(), size.height()); |
433 } | 430 } |
OLD | NEW |