| 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/renderer/render_view_impl.h" | 5 #include "content/renderer/render_view_impl.h" |
| 6 | 6 |
| 7 #include <algorithm> | 7 #include <algorithm> |
| 8 #include <cmath> | 8 #include <cmath> |
| 9 | 9 |
| 10 #include "base/auto_reset.h" | 10 #include "base/auto_reset.h" |
| (...skipping 590 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 601 | 601 |
| 602 if (!drop_data.html.is_null()) { | 602 if (!drop_data.html.is_null()) { |
| 603 WebDragData::Item item; | 603 WebDragData::Item item; |
| 604 item.storageType = WebDragData::Item::StorageTypeString; | 604 item.storageType = WebDragData::Item::StorageTypeString; |
| 605 item.stringType = WebString::fromUTF8(ui::Clipboard::kMimeTypeHTML); | 605 item.stringType = WebString::fromUTF8(ui::Clipboard::kMimeTypeHTML); |
| 606 item.stringData = drop_data.html.string(); | 606 item.stringData = drop_data.html.string(); |
| 607 item.baseURL = drop_data.html_base_url; | 607 item.baseURL = drop_data.html_base_url; |
| 608 item_list.push_back(item); | 608 item_list.push_back(item); |
| 609 } | 609 } |
| 610 | 610 |
| 611 for (std::vector<DropData::FileInfo>::const_iterator it = | 611 for (std::vector<ui::FileInfo>::const_iterator it = |
| 612 drop_data.filenames.begin(); | 612 drop_data.filenames.begin(); |
| 613 it != drop_data.filenames.end(); | 613 it != drop_data.filenames.end(); |
| 614 ++it) { | 614 ++it) { |
| 615 WebDragData::Item item; | 615 WebDragData::Item item; |
| 616 item.storageType = WebDragData::Item::StorageTypeFilename; | 616 item.storageType = WebDragData::Item::StorageTypeFilename; |
| 617 item.filenameData = it->path; | 617 item.filenameData = it->path.AsUTF16Unsafe(); |
| 618 item.displayNameData = it->display_name; | 618 item.displayNameData = it->display_name.AsUTF16Unsafe(); |
| 619 item_list.push_back(item); | 619 item_list.push_back(item); |
| 620 } | 620 } |
| 621 | 621 |
| 622 for (std::map<base::string16, base::string16>::const_iterator it = | 622 for (std::map<base::string16, base::string16>::const_iterator it = |
| 623 drop_data.custom_data.begin(); | 623 drop_data.custom_data.begin(); |
| 624 it != drop_data.custom_data.end(); | 624 it != drop_data.custom_data.end(); |
| 625 ++it) { | 625 ++it) { |
| 626 WebDragData::Item item; | 626 WebDragData::Item item; |
| 627 item.storageType = WebDragData::Item::StorageTypeString; | 627 item.storageType = WebDragData::Item::StorageTypeString; |
| 628 item.stringType = it->first; | 628 item.stringType = it->first; |
| (...skipping 4340 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 4969 std::vector<gfx::Size> sizes(icon_urls[i].sizes().size()); | 4969 std::vector<gfx::Size> sizes(icon_urls[i].sizes().size()); |
| 4970 ConvertToFaviconSizes(icon_urls[i].sizes(), &sizes); | 4970 ConvertToFaviconSizes(icon_urls[i].sizes(), &sizes); |
| 4971 if (!url.isEmpty()) | 4971 if (!url.isEmpty()) |
| 4972 urls.push_back( | 4972 urls.push_back( |
| 4973 FaviconURL(url, ToFaviconType(icon_urls[i].iconType()), sizes)); | 4973 FaviconURL(url, ToFaviconType(icon_urls[i].iconType()), sizes)); |
| 4974 } | 4974 } |
| 4975 SendUpdateFaviconURL(urls); | 4975 SendUpdateFaviconURL(urls); |
| 4976 } | 4976 } |
| 4977 | 4977 |
| 4978 } // namespace content | 4978 } // namespace content |
| OLD | NEW |