| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2013 Google Inc. All rights reserved. | 2 * Copyright (C) 2013 Google 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 are | 5 * modification, are permitted provided that the following conditions are |
| 6 * met: | 6 * met: |
| 7 * | 7 * |
| 8 * * Redistributions of source code must retain the above copyright | 8 * * 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 * * Redistributions in binary form must reproduce the above | 10 * * Redistributions in binary form must reproduce the above |
| (...skipping 152 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 163 WebInspector.installDragHandle(dividersLabelBarElement, this._startWindo
wDragging.bind(this), this._windowDragging.bind(this), null, "-webkit-grabbing",
"-webkit-grab"); | 163 WebInspector.installDragHandle(dividersLabelBarElement, this._startWindo
wDragging.bind(this), this._windowDragging.bind(this), null, "-webkit-grabbing",
"-webkit-grab"); |
| 164 | 164 |
| 165 this.windowLeft = 0.0; | 165 this.windowLeft = 0.0; |
| 166 this.windowRight = 1.0; | 166 this.windowRight = 1.0; |
| 167 | 167 |
| 168 this._parentElement.addEventListener("mousewheel", this._onMouseWheel.bind(t
his), true); | 168 this._parentElement.addEventListener("mousewheel", this._onMouseWheel.bind(t
his), true); |
| 169 this._parentElement.addEventListener("dblclick", this._resizeWindowMaximum.b
ind(this), true); | 169 this._parentElement.addEventListener("dblclick", this._resizeWindowMaximum.b
ind(this), true); |
| 170 WebInspector.appendStyle(this._parentElement, "ui_lazy/overviewGrid.css"); | 170 WebInspector.appendStyle(this._parentElement, "ui_lazy/overviewGrid.css"); |
| 171 | 171 |
| 172 this._leftResizeElement = parentElement.createChild("div", "overview-grid-wi
ndow-resizer"); | 172 this._leftResizeElement = parentElement.createChild("div", "overview-grid-wi
ndow-resizer"); |
| 173 this._leftResizeElement.style.left = 0; | 173 this._leftResizeElement.style.left = "0"; |
| 174 WebInspector.installDragHandle(this._leftResizeElement, this._resizerElement
StartDragging.bind(this), this._leftResizeElementDragging.bind(this), null, "ew-
resize"); | 174 WebInspector.installDragHandle(this._leftResizeElement, this._resizerElement
StartDragging.bind(this), this._leftResizeElementDragging.bind(this), null, "ew-
resize"); |
| 175 | 175 |
| 176 this._rightResizeElement = parentElement.createChild("div", "overview-grid-w
indow-resizer"); | 176 this._rightResizeElement = parentElement.createChild("div", "overview-grid-w
indow-resizer"); |
| 177 this._rightResizeElement.style.right = 0; | 177 this._rightResizeElement.style.right = "0"; |
| 178 WebInspector.installDragHandle(this._rightResizeElement, this._resizerElemen
tStartDragging.bind(this), this._rightResizeElementDragging.bind(this), null, "e
w-resize"); | 178 WebInspector.installDragHandle(this._rightResizeElement, this._resizerElemen
tStartDragging.bind(this), this._rightResizeElementDragging.bind(this), null, "e
w-resize"); |
| 179 this.setEnabled(true); | 179 this.setEnabled(true); |
| 180 } | 180 } |
| 181 | 181 |
| 182 WebInspector.OverviewGrid.Events = { | 182 WebInspector.OverviewGrid.Events = { |
| 183 WindowChanged: "WindowChanged", | 183 WindowChanged: "WindowChanged", |
| 184 Click: "Click" | 184 Click: "Click" |
| 185 } | 185 } |
| 186 | 186 |
| 187 WebInspector.OverviewGrid.Window.prototype = { | 187 WebInspector.OverviewGrid.Window.prototype = { |
| (...skipping 271 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 459 position = Math.max(0, Math.min(position, this._width)); | 459 position = Math.max(0, Math.min(position, this._width)); |
| 460 if (position < this._startPosition) { | 460 if (position < this._startPosition) { |
| 461 this._windowSelector.style.left = position + "px"; | 461 this._windowSelector.style.left = position + "px"; |
| 462 this._windowSelector.style.right = this._width - this._startPosition
+ "px"; | 462 this._windowSelector.style.right = this._width - this._startPosition
+ "px"; |
| 463 } else { | 463 } else { |
| 464 this._windowSelector.style.left = this._startPosition + "px"; | 464 this._windowSelector.style.left = this._startPosition + "px"; |
| 465 this._windowSelector.style.right = this._width - position + "px"; | 465 this._windowSelector.style.right = this._width - position + "px"; |
| 466 } | 466 } |
| 467 } | 467 } |
| 468 } | 468 } |
| OLD | NEW |