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

Side by Side Diff: chrome/browser/resources/ntp4/trash.js

Issue 8423055: [Aura] Initial app list webui. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: remove grabber.js Created 9 years, 1 month 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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 /** 5 /**
6 * @fileoverview Trash 6 * @fileoverview Trash
7 * This is the class for the trash can that appears when dragging an app. 7 * This is the class for the trash can that appears when dragging an app.
8 */ 8 */
9 9
10 cr.define('ntp4', function() { 10 cr.define('ntp4', function() {
11 'use strict'; 11 'use strict';
12 12
13 function Trash(trash) { 13 function Trash(trash) {
14 trash.__proto__ = Trash.prototype; 14 trash.__proto__ = Trash.prototype;
15 trash.initialize(); 15 trash.initialize();
16 return trash; 16 return trash;
17 } 17 }
18 18
19 Trash.prototype = { 19 Trash.prototype = {
20 __proto__: HTMLDivElement.prototype, 20 __proto__: HTMLDivElement.prototype,
21 21
22 initialize: function(element) { 22 initialize: function(element) {
23 this.dragWrapper_ = new DragWrapper(this, this); 23 this.dragWrapper_ = new cr.ui.DragWrapper(this, this);
24 }, 24 },
25 25
26 /** 26 /**
27 * Determines whether we are interested in the drag data for |e|. 27 * Determines whether we are interested in the drag data for |e|.
28 * @param {Event} e The event from drag enter. 28 * @param {Event} e The event from drag enter.
29 * @return {bool} 29 * @return {bool}
30 */ 30 */
31 shouldAcceptDrag: function(e) { 31 shouldAcceptDrag: function(e) {
32 var tile = ntp4.getCurrentlyDraggingTile(); 32 var tile = ntp4.getCurrentlyDraggingTile();
33 if (!tile) 33 if (!tile)
(...skipping 40 matching lines...) Expand 10 before | Expand all | Expand 10 after
74 doDragLeave: function(e) { 74 doDragLeave: function(e) {
75 ntp4.getCurrentlyDraggingTile().dragClone.classList.remove( 75 ntp4.getCurrentlyDraggingTile().dragClone.classList.remove(
76 'hovering-on-trash'); 76 'hovering-on-trash');
77 }, 77 },
78 }; 78 };
79 79
80 return { 80 return {
81 Trash: Trash, 81 Trash: Trash,
82 }; 82 };
83 }); 83 });
OLDNEW
« no previous file with comments | « chrome/browser/resources/ntp4/touch_handler.js ('k') | chrome/browser/resources/shared/js/cr/ui/card_slider.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698