| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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 "content/browser/renderer_host/render_view_host_impl.h" | 5 #include "content/browser/renderer_host/render_view_host_impl.h" |
| 6 | 6 |
| 7 #include <set> | 7 #include <set> |
| 8 #include <string> | 8 #include <string> |
| 9 #include <utility> | 9 #include <utility> |
| 10 #include <vector> | 10 #include <vector> |
| (...skipping 1283 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1294 GetProcess()->GetBrowserContext(), | 1294 GetProcess()->GetBrowserContext(), |
| 1295 GetSiteInstance())->GetFileSystemContext(); | 1295 GetSiteInstance())->GetFileSystemContext(); |
| 1296 filtered_data.file_system_files.clear(); | 1296 filtered_data.file_system_files.clear(); |
| 1297 for (size_t i = 0; i < drop_data.file_system_files.size(); ++i) { | 1297 for (size_t i = 0; i < drop_data.file_system_files.size(); ++i) { |
| 1298 fileapi::FileSystemURL file_system_url = | 1298 fileapi::FileSystemURL file_system_url = |
| 1299 file_system_context->CrackURL(drop_data.file_system_files[i].url); | 1299 file_system_context->CrackURL(drop_data.file_system_files[i].url); |
| 1300 if (policy->CanReadFileSystemFile(GetProcess()->GetID(), file_system_url)) | 1300 if (policy->CanReadFileSystemFile(GetProcess()->GetID(), file_system_url)) |
| 1301 filtered_data.file_system_files.push_back(drop_data.file_system_files[i]); | 1301 filtered_data.file_system_files.push_back(drop_data.file_system_files[i]); |
| 1302 } | 1302 } |
| 1303 | 1303 |
| 1304 float scale = ui::GetImageScale(GetScaleFactorForView(GetView())); | 1304 float scale = GetScaleFactorForView(GetView()); |
| 1305 gfx::ImageSkia image(gfx::ImageSkiaRep(bitmap, scale)); | 1305 gfx::ImageSkia image(gfx::ImageSkiaRep(bitmap, scale)); |
| 1306 view->StartDragging(filtered_data, drag_operations_mask, image, | 1306 view->StartDragging(filtered_data, drag_operations_mask, image, |
| 1307 bitmap_offset_in_dip, event_info); | 1307 bitmap_offset_in_dip, event_info); |
| 1308 } | 1308 } |
| 1309 | 1309 |
| 1310 void RenderViewHostImpl::OnUpdateDragCursor(WebDragOperation current_op) { | 1310 void RenderViewHostImpl::OnUpdateDragCursor(WebDragOperation current_op) { |
| 1311 RenderViewHostDelegateView* view = delegate_->GetDelegateView(); | 1311 RenderViewHostDelegateView* view = delegate_->GetDelegateView(); |
| 1312 if (view) | 1312 if (view) |
| 1313 view->UpdateDragCursor(current_op); | 1313 view->UpdateDragCursor(current_op); |
| 1314 } | 1314 } |
| (...skipping 378 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1693 return true; | 1693 return true; |
| 1694 } | 1694 } |
| 1695 | 1695 |
| 1696 void RenderViewHostImpl::AttachToFrameTree() { | 1696 void RenderViewHostImpl::AttachToFrameTree() { |
| 1697 FrameTree* frame_tree = delegate_->GetFrameTree(); | 1697 FrameTree* frame_tree = delegate_->GetFrameTree(); |
| 1698 | 1698 |
| 1699 frame_tree->ResetForMainFrameSwap(); | 1699 frame_tree->ResetForMainFrameSwap(); |
| 1700 } | 1700 } |
| 1701 | 1701 |
| 1702 } // namespace content | 1702 } // namespace content |
| OLD | NEW |