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

Unified Diff: perf/dashboard/ui/endure_js/dom_utils.js

Issue 1654813003: Remove old dead perf dashboard pages and js (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/tools/
Patch Set: Created 4 years, 11 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
« no previous file with comments | « perf/dashboard/ui/endure_js/coordinates.js ('k') | perf/dashboard/ui/endure_js/endure_plotter.js » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: perf/dashboard/ui/endure_js/dom_utils.js
===================================================================
--- perf/dashboard/ui/endure_js/dom_utils.js (revision 298504)
+++ perf/dashboard/ui/endure_js/dom_utils.js (working copy)
@@ -1,43 +0,0 @@
-/*
- Copyright (c) 2012 The Chromium Authors. All rights reserved.
- Use of this source code is governed by a BSD-style license that can be
- found in the LICENSE file.
-*/
-
-/**
- * @fileoverview Collection of functions which operate on DOM.
- */
-
-var domUtils = window['domUtils'] || {};
-
-/**
- * Returns pageX and pageY of the given element.
- *
- * @param {Element} element An element of which the top-left position is to be
- * returned in the coordinate system of the document page.
- * @return {Object} A point object which has {@code x} and {@code y} fields.
- */
-domUtils.pageXY = function(element) {
- var x = 0, y = 0;
- for (; element; element = element.offsetParent) {
- x += element.offsetLeft;
- y += element.offsetTop;
- }
- return {'x': x, 'y': y};
-};
-
-/**
- * Returns pageX and pageY of the given event.
- *
- * @param {Event} event An event of which the position is to be returned in
- * the coordinate system of the document page.
- * @return {Object} A point object which has {@code x} and {@code y} fields.
- */
-domUtils.pageXYOfEvent = function(event) {
- return (event.pageX != null && event.pageY != null) ?
- {'x': event.pageX, 'y': event.pageY} :
- {'x': event.clientX + document.body.scrollLeft +
- document.documentElement.scrollLeft,
- 'y': event.clientY + document.body.scrollTop +
- document.documentElement.scrollTop};
-};
« no previous file with comments | « perf/dashboard/ui/endure_js/coordinates.js ('k') | perf/dashboard/ui/endure_js/endure_plotter.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698