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

Side by Side Diff: Source/devtools/front_end/OverridesView.js

Issue 179743002: DevTools: Display pixel value in Device Emulation (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Created 6 years, 10 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 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) 2014 Google Inc. All rights reserved. 2 * Copyright (C) 2014 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 555 matching lines...) Expand 10 before | Expand all | Expand 10 after
566 this._heightOverrideElement = this._createInput(cellElement, "metrics-ov erride-height", String(metrics.height || screen.height), this._applyDeviceMetric sUserInput.bind(this), true); 566 this._heightOverrideElement = this._createInput(cellElement, "metrics-ov erride-height", String(metrics.height || screen.height), this._applyDeviceMetric sUserInput.bind(this), true);
567 567
568 rowElement = tableElement.createChild("tr"); 568 rowElement = tableElement.createChild("tr");
569 cellElement = rowElement.createChild("td"); 569 cellElement = rowElement.createChild("td");
570 cellElement.colSpan = 4; 570 cellElement.colSpan = 4;
571 this._widthRangeInput = cellElement.createChild("input"); 571 this._widthRangeInput = cellElement.createChild("input");
572 this._widthRangeInput.type = "range"; 572 this._widthRangeInput.type = "range";
573 this._widthRangeInput.min = 100; 573 this._widthRangeInput.min = 100;
574 this._widthRangeInput.max = 2000; 574 this._widthRangeInput.max = 2000;
575 this._widthRangeInput.addEventListener("change", this._rangeValueChanged .bind(this), false); 575 this._widthRangeInput.addEventListener("change", this._rangeValueChanged .bind(this), false);
576 this._widthRangeInput.addEventListener("input", this._rangeValueChanged. bind(this), false);
576 this._widthRangeInput.value = this._widthOverrideElement.value; 577 this._widthRangeInput.value = this._widthOverrideElement.value;
577 578
578 rowElement = tableElement.createChild("tr"); 579 rowElement = tableElement.createChild("tr");
579 rowElement.title = WebInspector.UIString("Ratio between a device's physi cal pixels and device-independent pixels."); 580 rowElement.title = WebInspector.UIString("Ratio between a device's physi cal pixels and device-independent pixels.");
580 cellElement = rowElement.createChild("td"); 581 cellElement = rowElement.createChild("td");
581 cellElement.appendChild(document.createTextNode(WebInspector.UIString("D evice pixel ratio:"))); 582 cellElement.appendChild(document.createTextNode(WebInspector.UIString("D evice pixel ratio:")));
582 cellElement = rowElement.createChild("td"); 583 cellElement = rowElement.createChild("td");
583 this._deviceScaleFactorOverrideElement = this._createInput(cellElement, "metrics-override-device-scale", String(metrics.deviceScaleFactor || 1), this._a pplyDeviceMetricsUserInput.bind(this), true); 584 this._deviceScaleFactorOverrideElement = this._createInput(cellElement, "metrics-override-device-scale", String(metrics.deviceScaleFactor || 1), this._a pplyDeviceMetricsUserInput.bind(this), true);
584 585
585 var textAutosizingOverrideElement = this._createNonPersistedCheckbox(Web Inspector.UIString("Enable text autosizing "), this._applyDeviceMetricsUserInput .bind(this)); 586 var textAutosizingOverrideElement = this._createNonPersistedCheckbox(Web Inspector.UIString("Enable text autosizing "), this._applyDeviceMetricsUserInput .bind(this));
(...skipping 502 matching lines...) Expand 10 before | Expand all | Expand 10 after
1088 1089
1089 __proto__ : WebInspector.OverridesView.Tab.prototype 1090 __proto__ : WebInspector.OverridesView.Tab.prototype
1090 } 1091 }
1091 1092
1092 /** @enum {string} */ 1093 /** @enum {string} */
1093 WebInspector.OverridesView.SensorsTab.DeviceOrientationModificationSource = { 1094 WebInspector.OverridesView.SensorsTab.DeviceOrientationModificationSource = {
1094 UserInput: "userInput", 1095 UserInput: "userInput",
1095 UserDrag: "userDrag", 1096 UserDrag: "userDrag",
1096 ResetButton: "resetButton" 1097 ResetButton: "resetButton"
1097 } 1098 }
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