Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(164)

Unified Diff: chrome/browser/resources/local_ntp/most_visited_util.js

Issue 473583002: [Local NTP] Implementing Material Design styling (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fixing comments. Created 6 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: chrome/browser/resources/local_ntp/most_visited_util.js
diff --git a/chrome/browser/resources/local_ntp/most_visited_util.js b/chrome/browser/resources/local_ntp/most_visited_util.js
index 06f97bce2c27cc5cea36c76fc92d0489c3b35948..3f4b8ffd4c9c630a96bacfa0e928e15ea7f67932 100644
--- a/chrome/browser/resources/local_ntp/most_visited_util.js
+++ b/chrome/browser/resources/local_ntp/most_visited_util.js
@@ -156,6 +156,9 @@ function createMostVisitedLink(params, href, title, text, direction, provider) {
}
// Else follow <a> normally, so transition type would be LINK.
});
+ link.addEventListener('mousedown', function(e) {
+ e.preventDefault(); // Prevent drag-select.
+ });
return link;
}
@@ -163,11 +166,11 @@ function createMostVisitedLink(params, href, title, text, direction, provider) {
/**
* Decodes most visited styles from URL parameters.
+ * - c: A hexadecimal number interpreted as a hex color code.
* - f: font-family.
* - fs: font-size as a number in pixels.
* - ta: text-align property, as a string.
* - tf: specifying a text fade starting position, in pixels.
- * - c: A hexadecimal number interpreted as a hex color code.
* @param {Object.<string, string>} params URL parameters specifying style.
* @param {boolean} isTitle if the style is for the Most Visited Title.
* @return {Object} Styles suitable for CSS interpolation.
« no previous file with comments | « chrome/browser/resources/local_ntp/most_visited_thumbnail.js ('k') | chrome/browser/search/local_ntp_source.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698