summaryrefslogtreecommitdiffstats
path: root/chrome/browser/views/tab_contents
diff options
context:
space:
mode:
authoryusukes@google.com <yusukes@google.com@0039d316-1c4b-4281-b951-d872f2087c98>2009-06-24 23:09:32 +0000
committeryusukes@google.com <yusukes@google.com@0039d316-1c4b-4281-b951-d872f2087c98>2009-06-24 23:09:32 +0000
commit325544bfa8eac66501fbba1c380f6de2b5968526 (patch)
treee948a627065a4f300869c03892eee8b710b0f634 /chrome/browser/views/tab_contents
parentf3f0770f6fe79e110fe52bff71a4914959112b1b (diff)
downloadchromium_src-325544bfa8eac66501fbba1c380f6de2b5968526.zip
chromium_src-325544bfa8eac66501fbba1c380f6de2b5968526.tar.gz
chromium_src-325544bfa8eac66501fbba1c380f6de2b5968526.tar.bz2
Merging r18584 into chrome/browser/views/tab_contents/tab_contents_view_win.cc.
My last patch (http://src.chromium.org/viewvc/chrome?view=rev&revision=18584) should have been for chrome/browser/views/tab_contents/tab_contents_view_win.cc, not for chrome/browser/tab_contents/tab_contents_view_win.cc since the latter had been deleted (http://src.chromium.org/viewvc/chrome?view=rev&revision=18368). I've confirmed that no patch other than mine is submitted to the old file: http://src.chromium.org/viewvc/chrome/trunk/src/chrome/browser/tab_contents/tab_contents_view_win.cc?view=log BUG=12290 TEST=See http://codereview.chromium.org/125111 Review URL: http://codereview.chromium.org/147074 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@19194 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/browser/views/tab_contents')
-rwxr-xr-xchrome/browser/views/tab_contents/tab_contents_view_win.cc7
1 files changed, 5 insertions, 2 deletions
diff --git a/chrome/browser/views/tab_contents/tab_contents_view_win.cc b/chrome/browser/views/tab_contents/tab_contents_view_win.cc
index 1b7fa80..f4e76b2 100755
--- a/chrome/browser/views/tab_contents/tab_contents_view_win.cc
+++ b/chrome/browser/views/tab_contents/tab_contents_view_win.cc
@@ -144,7 +144,8 @@ void TabContentsViewWin::StartDragging(const WebDropData& drop_data) {
if (drop_data.url.SchemeIs(chrome::kJavaScriptScheme)) {
// We don't want to allow javascript URLs to be dragged to the desktop,
// but we do want to allow them to be added to the bookmarks bar
- // (bookmarklets).
+ // (bookmarklets). So we create a fake bookmark entry (BookmarkDragData
+ // object) which explorer.exe cannot handle, and write the entry to data.
BookmarkDragData::Element bm_elt;
bm_elt.is_url = true;
bm_elt.url = drop_data.url;
@@ -153,7 +154,9 @@ void TabContentsViewWin::StartDragging(const WebDropData& drop_data) {
BookmarkDragData bm_drag_data;
bm_drag_data.elements.push_back(bm_elt);
- bm_drag_data.Write(tab_contents()->profile(), data);
+ // Pass in NULL as the profile so that the bookmark always adds the url
+ // rather than trying to move an existing url.
+ bm_drag_data.Write(NULL, data);
} else {
data->SetURL(drop_data.url, drop_data.url_title);
}