My favorites | Sign in
Logo
             
New issue | Search
for
| Advanced search | Search tips
Issue 12290: Can't drag bookmarklets to the bookmarks bar
23 people starred this issue and may be notified of changes. Back to list
Status:  Fixed
Owner:  yusukes@chromium.org
Closed:  Jun 24
Cc:  venkataramana@chromium.org
Type-Bug
Pri-1
OS-Windows
Area-BrowserUI
Regression
Mstone-4


Sign in to add a comment
 
Reported by sylvain.pasche, May 19, 2009
Chrome Version       : 2.0.182.0 (Developer Build 16426)
URLs (if applicable) : https://www.squarefree.com/bookmarklets/zap.html
Other browsers tested: not applicable

What steps will reproduce the problem?
1. show the bookmarks bar
1. open https://www.squarefree.com/bookmarklets/zap.html
2. try dragging a bookmarklet to the bookmarks bar

What is the expected result?
A drag target feedback is visible and a bookmark is created on drop.

What happens instead?
The bookmarks bar doesn't accept the drop.

This worked with Chrome 1.0, so it's a regression.

Comment 1 by venkataramana@chromium.org, May 20, 2009
Build: 2.0.182.0 (Developer Build 16482).
I can't reproduce this. Does this happen for every URL or only for the above URL and
are you sure the above URL is not bookmarked already on Bookmarks bar?

Thanks,
Venkat.
Cc: venkatar...@chromium.org
Labels: -Area-Misc Area-BrowserUI FeedbackRequested
Comment 2 by sylvain.pasche, May 20, 2009
Strange, the issue only happens when I use the --user-data-dir command line
parameter. Without it, I can bookmark these URLs. (With Chrome 1.0 it also works when
a --user-data-dir is specified)

And it seems to happen for all the URLs using the javascript: protocol.

Minimal testcase: data:text/html,<a href="javascript:alert('foo')">sample javascript
url</a>
Comment 3 by venkataramana@chromium.org, May 20, 2009
Still no luck even with user-data-dir command line.
The above testcase also does not help me to reproduce the issue though. Keeping it
open for few more days, to get feedback from other users.

-Venkat.
Comment 4 by Carolyn.Blue, May 22, 2009
I'm using version 2.0.181.1 (Official Build 16409) and I'm also experiencing this 
issue. I tried the bookmarklet at http://keepvid.com/ among others, and it doesn't 
appear to matter whether I start Chrome using the --user-data-dir command line flag or 
not — I'm unable to drag a bookmarklet either way.
Comment 5 by angusdev, May 26, 2009
reproduced in 3.0.182.1 (16871) with test case
data:text/html,<a href="javascript:alert('foo')">sample javascript
url</a>
Comment 6 by empty1, May 29, 2009
reproduced using Chrome 3.0.182.3

I am able to drag bookmarks to my bookmark bar as long as it is a regular http:// 
link

http://delicious.com/home

but not if it is a javascript bookmarklet

javascript:(function(){location.href='http://delicious.com/save?
url='+encodeURIComponent(window.location.href)+'&title='+encodeURIComponent(document.
title)+'&v=5&jump=yes'})()
Comment 7 by alexandr...@yahoo.com, May 29, 2009
Yeah, as long as it is an html site, it can be bookmarked, but if it is a java 
bookmark, then it can not dropped, you can try with the bookmarklets from 
http://www.labnol.org/internet/guide-to-useful-bookmarklets/7931/ or 
http://lifehacker.com/395697/top-10-useful-bookmarklets

PS. I have version 3.0.182.3 (Official Build 17055) using Windows XP Professional sp3, 
US English Language, if any of this helps
Comment 8 by hkdennis2k, Jun 07, 2009
I am using 3.0.183.1, I tried to add bookmarklet for Google Reader (since Chrome does 
not handle RSS subscription). However drop links which using "javascript:" protocol to 
bookmark toolbar is not allowed.

I tried also open up "bookmark manager" window, and drop links into it.

"http", "https", "ftp", "mailto" and even "ed2k" links are ok..
But not for "javascript" links.
Comment 9 by heorgheorg, Jun 12, 2009
Just updated to 3.0.187.1 and (still) can't drag bookmarklets to the bookmarks bar. 
Comment 10 by yusukes@chromium.org, Jun 14, 2009
Reproduced in r18152 (trunk, Windows Vista) and 3.0.187.0 (dev channel, Windows XP 
SP3). I'm working on this.
Status: Started
Owner: yusu...@chromium.org
Comment 11 by yusukes@chromium.org, Jun 14, 2009
http://codereview.chromium.org/125111
Labels: -OS-All OS-Windows
Comment 12 by divilex@hotmail.com, Jun 14, 2009
Remove label: Feedback Requested.
Comment 13 by yusukes@chromium.org, Jun 14, 2009
 Issue 12976  has been merged into this issue.
Comment 14 by bugdroid1@chromium.org, Jun 16, 2009
The following revision refers to this bug:
    http://src.chromium.org/viewvc/chrome?view=rev&revision=18584 

------------------------------------------------------------------------
r18584 | yusukes@google.com | 2009-06-16 20:14:12 -0700 (Tue, 16 Jun 2009) | 16 lines
Changed paths:
   A http://src.chromium.org/viewvc/chrome/trunk/src/chrome/browser/tab_contents/tab_contents_view_win.cc

Do not write a profile path on a BookmarkDragData object since a dragged url (javascript:...) on a web page does not belong to (the profile's) bookmark model.

Currently the following function returns DRAG_NONE and thus the drop operation is not accepted. The reason for the return value is because ops becomes DragDropTypes::DRAG_MOVE (since data.profile_path_ is not empty()) but event.GetSourceOperations() returns DragDropTypes::DRAG_COPY | DragDropTypes::DRAG_LINK.

int BookmarkBarView::CalculateDropOperation(const DropTargetEvent& event,
...
    int ops = data.GetFirstNode(profile_)
        ? DragDropTypes::DRAG_MOVE
        : DragDropTypes::DRAG_COPY | DragDropTypes::DRAG_LINK;
    return bookmark_utils::PreferredDropOperation(event.GetSourceOperations(),
                                                  ops);

BUG=12290
TEST=Open http://delicious.com/help/bookmarklets page and drag the "Bookmark on Delicious" link on "Google Chrome" section to the bookmark bar.

Review URL: http://codereview.chromium.org/125111
------------------------------------------------------------------------

Comment 15 by yusukes@chromium.org, Jun 16, 2009
(No comment was entered for this change.)
Status: Fixed
Comment 16 by yusukes@chromium.org, Jun 16, 2009
(No comment was entered for this change.)
Labels: -FeedbackRequested
Comment 17 by mal.chromium, Jun 19, 2009
 Issue 14236  has been merged into this issue.
Comment 18 by phist...@chromium.org, Jun 22, 2009
 Issue 14797  has been merged into this issue.
Comment 19 by alexandr...@yahoo.com, Jun 22, 2009
@ yusu...@chromium.org: Feedback: Still does not work on 3.0.189.0 (Official Build 
18569)
Comment 20 by yusukes@chromium.org, Jun 22, 2009
@alexandr Unfortunately the patch is not included in 3.0.189.0. Please wait for the 
next dev channel release.

Comment 21 by alexandr...@yahoo.com, Jun 22, 2009
@ yusu...@chromium.org: ok, thanks I just didn't knew if it had been patch on this
version, and saw you asking for feedback. Is the patch on the latest Chromium Build?
Comment 22 by yusukes@chromium.org, Jun 22, 2009
> Is the patch on the latest Chromium Build?

Do you mean the latest build on http://build.chromium.org/buildbot/snapshots/chromium-rel-xp/? If so, yes, the patch is 
already applied to the build.

Comment 23 by alexandr...@yahoo.com, Jun 23, 2009
Well it still does not work on 3.0.191.0 (Developer Build 19018)
Comment 24 by mal.chromium, Jun 23, 2009
This is still broken in 3.0.190.x official builds.
Status: Assigned
Labels: -Pri-2 Pri-1 Regression Mstone-4
Comment 25 by yusukes@chromium.org, Jun 23, 2009
Reproduced on my end too. I'm looking into this, thanks.
Status: Started
Comment 26 by yusukes@chromium.org, Jun 23, 2009
Review started.
http://codereview.chromium.org/147074

Comment 27 by jmickus, Jun 24, 2009
This used to work, but stopped working with one of the recent versions of Chrome.  
Sadly, I couldn't identify which version in which the problem was introduced.
Comment 28 by bugdroid1@chromium.org, Jun 24, 2009
The following revision refers to this bug:
    http://src.chromium.org/viewvc/chrome?view=rev&revision=19194 

------------------------------------------------------------------------
r19194 | yusukes@google.com | 2009-06-24 16:09:32 -0700 (Wed, 24 Jun 2009) | 11 lines
Changed paths:
   D /trunk/src/chrome/browser/tab_contents/tab_contents_view_win.cc
   M http://src.chromium.org/viewvc/chrome/trunk/src/chrome/browser/views/tab_contents/tab_contents_view_win.cc?r1=19194&r2=19193

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
------------------------------------------------------------------------

Comment 29 by yusukes@chromium.org, Jun 24, 2009
(No comment was entered for this change.)
Status: Fixed
Comment 30 by wanderlust01, Jun 25, 2009
Problem still persists - even though status is marked FIXED.

I have 3.0.190.1 and it is still not possible to drag and drop the Facebook ( as 
example ) bookmarklet into the bookmarks bar. 

http://www.facebook.com/share_options.php 

I noticed however the following phenomena - if I drag the bookmarklet further up to 
the "tab bar", a small white down arrow appears and if I "drop" the bookmarklet there 
- it opens a new tab and executes the bookmarklet. kinda' a 50% workaround.

Comment 31 by phistuck, Jun 25, 2009
It is fixed, but did not make it to the 190.1 release.
In the next one, you can expect to drag them to the bookmarks bar and it will add them.

The dragging to the tab strip is different, it just opens the dragged link it a new tab\same tab 
.
Comment 32 by TheCybor...@gmail.com, Jun 25, 2009
It was fixed in revision r19194 (as noted above by the bugdroid).
Chrome 3.0.190.1 is revision r19007 (see about:version).
Comment 33 by greggemarshall, Jul 08, 2009
I'm having the same issue trying to drag bookmarklets (e.g. su.pr) on the toolbar with 
Chrome 3.0.190.4
Comment 34 by yusukes@chromium.org, Jul 08, 2009
@greggemarshall Please try 3.0.191.3 or later.
http://googlechromereleases.blogspot.com/2009/07/dev-update-animated-gif-fix.html

Comment 35 by patrickb...@gmail.com, Jul 09, 2009
It is still not possible with the bookmarklet on 
http://keepvid.com/ ... But this never worked with chrome.

3.0.192.1 (Official Build 20012)
Comment 36 by yusukes@chromium.org, Jul 09, 2009
@patrickb Thanks for the report. It seems like a separate issue of WebKit.
Could you file a new bug?

Comment 37 by patrickb...@gmail.com, Jul 09, 2009
done:  issue 16307 
Comment 38 by yusukes@chromium.org, Jul 09, 2009
thanks!
Sign in to add a comment