[SCM] WebKit Debian packaging branch, debian/experimental, updated. upstream/1.3.3-9427-gc2be6fc
abarth at webkit.org
abarth at webkit.org
Wed Dec 22 12:46:32 UTC 2010
The following commit has been merged in the debian/experimental branch:
commit 7579ac83e648da52d2e8d4af3f2add3e9176ee26
Author: abarth at webkit.org <abarth at webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Date: Mon Aug 30 00:10:14 2010 +0000
2010-08-29 Adam Barth <abarth at webkit.org>
Attempt to make Sam's life easier by not opening a comment text field
if there's a selection. This should make it easier to copy/paste text
out of the diff without accidentally opening comment boxes.
* code-review.js:
git-svn-id: http://svn.webkit.org/repository/webkit/trunk@66341 268f45cc-cd09-0410-ab3c-d52691b4dbfc
diff --git a/BugsSite/ChangeLog b/BugsSite/ChangeLog
index 8006a80..f50caeb 100644
--- a/BugsSite/ChangeLog
+++ b/BugsSite/ChangeLog
@@ -1,5 +1,13 @@
2010-08-29 Adam Barth <abarth at webkit.org>
+ Attempt to make Sam's life easier by not opening a comment text field
+ if there's a selection. This should make it easier to copy/paste text
+ out of the diff without accidentally opening comment boxes.
+
+ * code-review.js:
+
+2010-08-29 Adam Barth <abarth at webkit.org>
+
Turns out we're supposed to use find instead of children here.
* code-review.js:
diff --git a/BugsSite/code-review.js b/BugsSite/code-review.js
index ac73d15..9edae76 100644
--- a/BugsSite/code-review.js
+++ b/BugsSite/code-review.js
@@ -72,6 +72,8 @@
var line = $('#' + id);
if (line.attr('data-has-comment'))
return;
+ if (!window.getSelection().isCollapsed)
+ return; // If there's a selection, we assume the user wants to copy the text.
line.attr('data-has-comment', 'true');
var comment_block = $('<div class="comment"><div class="actions"><img class="delete" src="' + kDeleteImage + '"></div><textarea data-comment-for="' + id + '"></textarea></div>');
insertCommentFor(line, comment_block);
--
WebKit Debian packaging
More information about the Pkg-webkit-commits
mailing list