Closed
Bug 757477
Opened 12 years ago
Closed 12 years ago
[Responsive Mode] restore previous size / preset
Categories
(DevTools :: General, defect)
Tracking
(Not tracked)
RESOLVED
FIXED
Firefox 15
People
(Reporter: paul, Unassigned)
Details
(Whiteboard: [fixed-in-fx-team])
Attachments
(1 file, 3 obsolete files)
(deleted),
patch
|
Details | Diff | Splinter Review |
We should restore the latest size and preset.
Reporter | ||
Comment 1•12 years ago
|
||
Reporter | ||
Updated•12 years ago
|
Attachment #626043 -
Flags: review?(dcamp)
Reporter | ||
Updated•12 years ago
|
Reporter | ||
Comment 2•12 years ago
|
||
rebased
Reporter | ||
Updated•12 years ago
|
Attachment #626043 -
Attachment is obsolete: true
Attachment #626043 -
Flags: review?(dcamp)
Reporter | ||
Updated•12 years ago
|
Attachment #627753 -
Flags: review?(dcamp)
Comment 3•12 years ago
|
||
Comment on attachment 627753 [details] [diff] [review]
patch v1
Review of attachment 627753 [details] [diff] [review]:
-----------------------------------------------------------------
::: browser/devtools/responsivedesign/responsivedesign.jsm
@@ +76,5 @@
> this.presets = [{custom: true}];
> }
>
> // Default size. The first preset (custom) is the one that will be used.
> let bbox = this.stack.getBoundingClientRect();
Do you need this bbox
@@ +81,5 @@
> +
> + try {
> + this.presets[0].width = Services.prefs.getIntPref("devtools.responsiveUI.customWidth");
> + this.presets[0].height = Services.prefs.getIntPref("devtools.responsiveUI.customHeight");
> + this.currentPreset = Services.prefs.getIntPref("devtools.responsiveUI.currentPreset");
Should there be a sanity check on these values? Can a really-large custom size cause any real problems?
Should the preset be some sort of absolute string rather than an integer index? That could make later updates to the preset list less fragile.
@@ +306,5 @@
> */
> rotate: function RUI_rotate() {
> this.setSize(this.currentHeight, this.currentWidth);
> + if (this.currentPreset == 0)
> + this.saveCustomSize();
Do you save the rotation value anywhere?
Attachment #627753 -
Flags: review?(dcamp)
Comment 4•12 years ago
|
||
(In reply to Dave Camp (:dcamp) from comment #3)
> Comment on attachment 627753 [details] [diff] [review]
> patch v1
>
> Review of attachment 627753 [details] [diff] [review]:
> -----------------------------------------------------------------
>
> ::: browser/devtools/responsivedesign/responsivedesign.jsm
> @@ +76,5 @@
> > this.presets = [{custom: true}];
> > }
> >
> > // Default size. The first preset (custom) is the one that will be used.
> > let bbox = this.stack.getBoundingClientRect();
>
> Do you need this bbox
... outside of the catch block?
Reporter | ||
Comment 5•12 years ago
|
||
addressed dave's comments
Reporter | ||
Updated•12 years ago
|
Attachment #627753 -
Attachment is obsolete: true
Reporter | ||
Updated•12 years ago
|
Attachment #629500 -
Flags: review?(dcamp)
Updated•12 years ago
|
Attachment #629500 -
Flags: review?(dcamp) → review+
Comment 6•12 years ago
|
||
I had bitrotted you pretty badly, so I fixed it.
Attachment #629500 -
Attachment is obsolete: true
Reporter | ||
Comment 7•12 years ago
|
||
Whiteboard: [fixed-in-fx-team]
Comment 8•12 years ago
|
||
Status: NEW → RESOLVED
Closed: 12 years ago
Resolution: --- → FIXED
Target Milestone: --- → Firefox 15
Updated•6 years ago
|
Product: Firefox → DevTools
You need to log in
before you can comment on or make changes to this bug.
Description
•