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

Side by Side Diff: Source/devtools/front_end/ui/treeoutline.js

Issue 690893002: Don't use getPropertyCSSValue in treeoutline.js (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Created 6 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
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2007 Apple Inc. All rights reserved. 2 * Copyright (C) 2007 Apple Inc. All rights reserved.
3 * 3 *
4 * Redistribution and use in source and binary forms, with or without 4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions 5 * modification, are permitted provided that the following conditions
6 * are met: 6 * are met:
7 * 7 *
8 * 1. Redistributions of source code must retain the above copyright 8 * 1. Redistributions of source code must retain the above copyright
9 * notice, this list of conditions and the following disclaimer. 9 * notice, this list of conditions and the following disclaimer.
10 * 2. Redistributions in binary form must reproduce the above copyright 10 * 2. Redistributions in binary form must reproduce the above copyright
(...skipping 1001 matching lines...) Expand 10 before | Expand all | Expand 10 after
1012 1012
1013 return this.parent; 1013 return this.parent;
1014 } 1014 }
1015 1015
1016 /** 1016 /**
1017 * @return {boolean} 1017 * @return {boolean}
1018 */ 1018 */
1019 TreeElement.prototype.isEventWithinDisclosureTriangle = function(event) 1019 TreeElement.prototype.isEventWithinDisclosureTriangle = function(event)
1020 { 1020 {
1021 // FIXME: We should not use getComputedStyle(). For that we need to get rid of using ::before for disclosure triangle. (http://webk.it/74446) 1021 // FIXME: We should not use getComputedStyle(). For that we need to get rid of using ::before for disclosure triangle. (http://webk.it/74446)
1022 var paddingLeftValue = window.getComputedStyle(this._listItemNode).getProper tyCSSValue("padding-left"); 1022 var paddingLeftValue = window.getComputedStyle(this._listItemNode).paddingLe ft;
1023 var computedLeftPadding = paddingLeftValue ? paddingLeftValue.getFloatValue( CSSPrimitiveValue.CSS_PX) : 0; 1023 console.assert(paddingLeftValue.endsWith("px"));
1024 var computedLeftPadding = parseFloat(paddingLeftValue, 10);
1024 var left = this._listItemNode.totalOffsetLeft() + computedLeftPadding; 1025 var left = this._listItemNode.totalOffsetLeft() + computedLeftPadding;
1025 return event.pageX >= left && event.pageX <= left + this.arrowToggleWidth && this.hasChildren; 1026 return event.pageX >= left && event.pageX <= left + this.arrowToggleWidth && this.hasChildren;
1026 } 1027 }
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698