| 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 212 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 223 // no longer be focusable (e.g. if the location bar was focused and then | 223 // no longer be focusable (e.g. if the location bar was focused and then |
| 224 // we switched to fullscreen mode). In that case we default to the | 224 // we switched to fullscreen mode). In that case we default to the |
| 225 // default focus. | 225 // default focus. |
| 226 SetInitialFocus(); | 226 SetInitialFocus(); |
| 227 } | 227 } |
| 228 view_storage->RemoveView(last_focused_view_storage_id_); | 228 view_storage->RemoveView(last_focused_view_storage_id_); |
| 229 } | 229 } |
| 230 } | 230 } |
| 231 | 231 |
| 232 void TabContentsViewTouch::UpdatePreferredSize(const gfx::Size& pref_size) { | 232 void TabContentsViewTouch::UpdatePreferredSize(const gfx::Size& pref_size) { |
| 233 tab_contents_->UpdatePreferredSize(pref_size); |
| 233 } | 234 } |
| 234 | 235 |
| 235 bool TabContentsViewTouch::IsDoingDrag() const { | 236 bool TabContentsViewTouch::IsDoingDrag() const { |
| 236 return false; | 237 return false; |
| 237 } | 238 } |
| 238 | 239 |
| 239 void TabContentsViewTouch::CancelDragAndCloseTab() { | 240 void TabContentsViewTouch::CancelDragAndCloseTab() { |
| 240 } | 241 } |
| 241 | 242 |
| 242 bool TabContentsViewTouch::IsEventTracking() const { | 243 bool TabContentsViewTouch::IsEventTracking() const { |
| (...skipping 189 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 432 rwhv->SetSize(size); | 433 rwhv->SetSize(size); |
| 433 | 434 |
| 434 if (needs_resize) | 435 if (needs_resize) |
| 435 SetFloatingPosition(size); | 436 SetFloatingPosition(size); |
| 436 } | 437 } |
| 437 | 438 |
| 438 void TabContentsViewTouch::SetFloatingPosition(const gfx::Size& size) { | 439 void TabContentsViewTouch::SetFloatingPosition(const gfx::Size& size) { |
| 439 // TODO(anicolao): rework this once we have WebUI views for dialogs | 440 // TODO(anicolao): rework this once we have WebUI views for dialogs |
| 440 SetBounds(x(), y(), size.width(), size.height()); | 441 SetBounds(x(), y(), size.width(), size.height()); |
| 441 } | 442 } |
| OLD | NEW |