Closed
Bug 1503902
Opened 6 years ago
Closed 6 years ago
RDM loses "rotate viewport" setting when closing
Categories
(DevTools :: Responsive Design Mode, defect, P3)
DevTools
Responsive Design Mode
Tracking
(firefox65 verified)
VERIFIED
FIXED
Firefox 65
Tracking | Status | |
---|---|---|
firefox65 | --- | verified |
People
(Reporter: mbalfanz, Assigned: gl)
Details
Attachments
(3 files, 1 obsolete file)
1.13 KB,
patch
|
rcaliman
:
review+
|
Details | Diff | Splinter Review |
593.20 KB,
video/mp4
|
Details | |
6.64 KB,
patch
|
rcaliman
:
review+
|
Details | Diff | Splinter Review |
RDM should store the rotation setting as well when closing and reopening. STR: - enter RDM - rotate viewport - close and reopen RDM ER: - RDM should restore all previous settings incl. rotation AR: - RDM does restore previous settings, but not rotation
Assignee | ||
Updated•6 years ago
|
Assignee: nobody → gl
Status: NEW → ASSIGNED
Priority: -- → P3
Assignee | ||
Comment 1•6 years ago
|
||
Attachment #9023092 -
Flags: review?(rcaliman)
Updated•6 years ago
|
Attachment #9023092 -
Flags: review?(rcaliman) → review+
Pushed by gabriel.luong@gmail.com: https://hg.mozilla.org/integration/mozilla-inbound/rev/969a48cb4f17 RDM should restore the previous state when reopening after rotating the viewport. r=rcaliman
Comment 3•6 years ago
|
||
bugherder |
https://hg.mozilla.org/mozilla-central/rev/969a48cb4f17
Status: ASSIGNED → RESOLVED
Closed: 6 years ago
status-firefox65:
--- → fixed
Resolution: --- → FIXED
Target Milestone: --- → Firefox 65
Reporter | ||
Comment 4•6 years ago
|
||
This doesn't work for me. See the video attached from latest Nightly. Same happens for me on M-C
Reporter | ||
Updated•6 years ago
|
Status: RESOLVED → REOPENED
Resolution: FIXED → ---
Assignee | ||
Comment 5•6 years ago
|
||
(In reply to Martin Balfanz [:mbalfanz] from comment #4) > Created attachment 9024504 [details] > rdm.mp4 > > This doesn't work for me. See the video attached from latest Nightly. Same > happens for me on M-C So, the problem is that you had a device selected, and rotating the viewport when a device is selected does not remove the device association.
Comment 6•6 years ago
|
||
Yeah I see the problem too. When we rotate the viewport, we end up storing the new width/height in prefs. But when we select a device, we also set that device in a pref. So when closing/re-opening RDM, we restore the device (because one was stored) instead of the custom width/height. I think what we should do here is when a device is selected, as soon as you click the rotate button, then we should forget that device and store the new width/height and restore that when reopening RDM. That would make sense to me.
Comment 7•6 years ago
|
||
Comment 8•6 years ago
|
||
This is an attempt at fixing this. I have never worked with this part of the code before, so might be missing something important. But it seems to be working.
Reporter | ||
Comment 9•6 years ago
|
||
As a user, I don't think this makes sense to me. It implies that rotating changes the device, but I still want the same device. If I close and reopen devtools and loose my reference to the device it will be confusing, and eventually I will not be sure anymore what I'm looking at. IMHO we should restore: - selected device or custom - dimensions based on ^, if custom - rotation setting to up the viewport in the right way
Assignee | ||
Comment 10•6 years ago
|
||
(In reply to Martin Balfanz [:mbalfanz] from comment #9) > As a user, I don't think this makes sense to me. It implies that rotating > changes the device, but I still want the same device. If I close and reopen > devtools and loose my reference to the device it will be confusing, and > eventually I will not be sure anymore what I'm looking at. > > IMHO we should restore: > - selected device or custom > - dimensions based on ^, if custom > - rotation setting to up the viewport in the right way Ya, I was thinking about it this morning, and I fell to the same conclusion that rotating a device should preserve the device settings. So, we should realistically restore the stored width/height when restoring the device instead of grabbing it from the device setting.
Comment 11•6 years ago
|
||
Comment on attachment 9024660 [details] Bug 1503902 - Forget current device when rotating the viewport; r?gl! Ok that makes, thanks for the feedback on this attempt. Let me remove this attachment then. I'll let Gabriel (or whoever wants to try this) take it from there as this was just a quick attempt on my part of what I thought was the right approach.
Attachment #9024660 -
Attachment is obsolete: true
Assignee | ||
Comment 12•6 years ago
|
||
In the previous patch, we already store the width/height in prefs. So, we simply avoid resizing the viewport to the device size (since this is not correct when we rotate the device) when we restore RDM and allow the Redux store of the viewport to restore its width/height on open.
Attachment #9025151 -
Flags: review?(rcaliman)
Updated•6 years ago
|
Attachment #9025151 -
Flags: review?(rcaliman) → review+
Comment 13•6 years ago
|
||
Pushed by gabriel.luong@gmail.com: https://hg.mozilla.org/integration/mozilla-inbound/rev/facf21932367 Avoid resizing RDM when restoring the device state and simply use the stored pref width and height. r=rcaliman
Comment 14•6 years ago
|
||
bugherder |
https://hg.mozilla.org/mozilla-central/rev/facf21932367
Status: REOPENED → RESOLVED
Closed: 6 years ago → 6 years ago
Resolution: --- → FIXED
Updated•5 years ago
|
Flags: qe-verify+
Comment 15•5 years ago
|
||
I reproduced this issue using Fx 65.0a1, build ID: 20181101220058, on Windows 10 x64.
I can confirm this issue is fixed, I verified using Fx 65.0b11, build ID: 20190114172331, on Windows 10 x64, macOS X 10.13 and Ubuntu 18.04.
You need to log in
before you can comment on or make changes to this bug.
Description
•