Closed Bug 848666 Opened 12 years ago Closed 12 years ago

The ScratchPad and Style Editor doesn't close after even firefox is Closed and they become unfunctional too

Categories

(DevTools Graveyard :: Scratchpad, defect, P2)

defect

Tracking

(Not tracked)

RESOLVED FIXED
Firefox 27

People

(Reporter: dron.rathore, Assigned: bbenvie)

References

Details

Attachments

(1 file, 2 obsolete files)

User Agent: Mozilla/5.0 (Windows NT 5.1; rv:19.0) Gecko/20100101 Firefox/19.0 Build ID: 20130215130331 Steps to reproduce: Step 1: Open Scratchpad or Style Editor Step 2: Close Firefox Actual results: The ScratchPad and Style Editor Do not closes with the firefox(though it be a utility) but now they become nonfunctional too(instead of Save and open command on ScratchPad). Expected results: Either they should have closed or if not they will remain nonfunctional as Components class will not exist in there context, so the better option is Open them as a Child Instance rather being a new instance out of Firefox.
OS: Windows XP → Windows 7
Priority: -- → P1
Component: Untriaged → Developer Tools: Scratchpad
Priority: P1 → --
Status: UNCONFIRMED → NEW
Ever confirmed: true
OS: Windows 7 → All
Priority: -- → P3
Hardware: x86 → All
Version: 19 Branch → Trunk
Priority: P3 → P2
Attached patch bug-848666.patch (obsolete) — Splinter Review
This patch makes the Scratchpad observe for the "browser-lastwindow-close-requested" event and then attempts to close the Scratchpad. Closing of the browser window is canceled if the use cancels closing the Scratchpad.
Assignee: nobody → bbenvie
Status: NEW → ASSIGNED
Attachment #810795 - Flags: review?(rcampbell)
Attached patch bug-848666.patch (obsolete) — Splinter Review
Woops, here's the correct version.
Attachment #810795 - Attachment is obsolete: true
Attachment #810795 - Flags: review?(rcampbell)
Attachment #810797 - Flags: review?(rcampbell)
Comment on attachment 810797 [details] [diff] [review] bug-848666.patch Review of attachment 810797 [details] [diff] [review]: ----------------------------------------------------------------- This looks like it'd do it. Honestly, I think I would have started this patch writing a test that proves the failure state then written this patch to verify it fixes it. R- without a unittest.
Attachment #810797 - Flags: review?(rcampbell) → review-
Good point, I was trying to think how to write a test to proof the affirmative (that it is closed with the browser) but tests can't close the browser. Proving a negative is feasible though!
Er actually that problem still exists.
Can't we apply a force close for them as after the last-window is closed of the browser? Because they make no sense in persisting after the Browser is been closed, Scratchpad becomes nonfunctional after it also the Style Editor is editing/modifying styles for which DOM(All DOM been killed)?
Well the way this patch works is that if the user cancels the close, it keeps the browser window open. This patch makes it so that there's never a Scratchpad window open if no browser windows open, which addresses your concern. I'm not sure what you mean about the Style Editor, since that lives in the toolbox and the toolbox closes when the tab it's debugging is closed, so this already isn't a problem for the Style Editor (and anything else that lives in the toolbox).
Aah my bad, Style Editor is in Dev tools now :p Okay but we can go for Scratchpad then :)
Attached patch bug-848666.patchSplinter Review
Attachment #810797 - Attachment is obsolete: true
Attachment #812193 - Flags: review?(rcampbell)
Comment on attachment 812193 [details] [diff] [review] bug-848666.patch Review of attachment 812193 [details] [diff] [review]: ----------------------------------------------------------------- woo!
Attachment #812193 - Flags: review?(rcampbell) → review+
(woo assuming green try run of course)
I guess if this fails for whatever reason, it's going to fail somewhat spectacularly with the browser closing and no more tests running. Fun!
Status: ASSIGNED → RESOLVED
Closed: 12 years ago
Flags: in-testsuite+
Resolution: --- → FIXED
Whiteboard: [fixed-in-fx-team]
Target Milestone: --- → Firefox 27
Product: Firefox → DevTools
Product: DevTools → DevTools Graveyard
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: