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

Unified Diff: chrome/browser/resources/ntp/apps.js

Issue 7623010: Polish the new tab notification code a bit, as per request in last review (style changes). (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Created 9 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/ntp/apps.js
===================================================================
--- chrome/browser/resources/ntp/apps.js (revision 96214)
+++ chrome/browser/resources/ntp/apps.js (working copy)
@@ -192,29 +192,17 @@
bubble.style.top = y + "px";
// Move the arrow and shadow to the right location.
- var arrow = $('arrow-contents');
- var border = $('arrow-border');
- var shadow = $('arrow-shadow');
+ var arrow_container = $('arrow-container');
y += 26;
- x -= arrow.style.width + 23;
- arrow.style.left = x + "px";
- arrow.style.top = y + "px";
- x -= 1;
- border.style.left = x + "px";
- border.style.top = y + "px";
- x -= 1;
- shadow.style.left = x + "px";
- shadow.style.top = y + "px";
+ x -= arrow_container.style.width + 25;
+ arrow_container.style.left = x + "px";
+ arrow_container.style.top = y + "px";
// Animate the bubble into view.
bubble.classList.add("notification-bubble-opened");
bubble.classList.remove("notification-bubble-closed");
- arrow.classList.add("notification-bubble-opened");
- arrow.classList.remove("notification-bubble-closed");
- border.classList.add("notification-bubble-opened");
- border.classList.remove("notification-bubble-closed");
- shadow.classList.add("notification-bubble-opened");
- shadow.classList.remove("notification-bubble-closed");
+ arrow_container.classList.add("notification-bubble-opened");
+ arrow_container.classList.remove("notification-bubble-closed");
bubble.focus();
}
@@ -224,12 +212,8 @@
// This will fade the bubble out of existence.
$('app-notification-bubble').classList.add("notification-bubble-closed");
$('app-notification-bubble').classList.remove("notification-bubble-opened");
- $('arrow-border').classList.add("notification-bubble-closed");
- $('arrow-border').classList.remove("notification-bubble-opened");
- $('arrow-shadow').classList.add("notification-bubble-closed");
- $('arrow-shadow').classList.remove("notification-bubble-opened");
- $('arrow-contents').classList.add("notification-bubble-closed");
- $('arrow-contents').classList.remove("notification-bubble-opened");
+ $('arrow-container').classList.add("notification-bubble-closed");
+ $('arrow-container').classList.remove("notification-bubble-opened");
}
var apps = (function() {
« chrome/browser/resources/ntp/apps.css ('K') | « chrome/browser/resources/ntp/apps.css ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698