Closed Bug 586826 Opened 14 years ago Closed 14 years ago

When close all tabs in TabView, I can not return to browser

Categories

(Firefox :: Tabbed Browser, defect, P3)

defect

Tracking

()

RESOLVED FIXED
Firefox 4.0b4

People

(Reporter: alice0775, Assigned: dao)

References

Details

User-Agent:       Mozilla/5.0 (Windows NT 6.1; WOW64; rv:2.0b4pre) Gecko/20100812 Minefield/4.0b4pre ID:20100812135028
Build Identifier: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:2.0b4pre) Gecko/20100812 Minefield/4.0b4pre ID:20100812135028

In latest m-c hourly build, with tabcandy enabled, 
When close all tabs in TabView, I can not return to browser.


Reproducible: Always

Steps to Reproduce:
1.Create a tab group
2.Close all tabs

Actual Results:  
I can not return to browser

Expected Results:  
Should be able to return.
I can confirm this using a very recent hourly trunk build (http://hg.mozilla.org/mozilla-central/rev/c8ee0c411f5e)

Bug 586528 is related to this. It would be nice to have an easy toggle button.
Status: UNCONFIRMED → NEW
Ever confirmed: true
Whiteboard: b4
Priority: -- → P3
Assigning to Aza for the design.
Assignee: nobody → aza
OS: Windows 7 → All
Hardware: x86 → All
Whiteboard: b4 → [Aug-13-testday][b4]
WORKAROUND
Create new group by drag mouse in TabView
Click icon at left-bottom of the group box
Click created New Tab
tabbrowser.xml line 1402 added by bug 574217 is bogus:

>1401             if (this.tabs.length - this._removingTabs.length == 1 && 
>1402                 (!TabView || !TabView.isVisible())) {
>1403               closeWindow = aCloseWindowWithLastTab != null ? aCloseWindowWithLastTab :
>1404                             !window.toolbar.visible ||
>1405                               this.tabContainer._closeWindowWithLastTab;
>1406 
>1407               // Closing the tab and replacing it with a blank one is notably slower
>1408               // than closing the window right away. If the caller opts in, take
>1409               // the fast path.
>1410               if (closeWindow &&
>1411                   aCloseWindowFastpath &&
>1412                   this._removingTabs.length == 0 &&
>1413                   (this._windowIsClosing = window.closeWindow(true)))
>1414                 return null;
>1415 
>1416               newTab = true;
>1417             }

There should never be a state where a window has zero tabs open.
Blocks: 574217
Severity: normal → major
(In reply to comment #5)
> tabbrowser.xml line 1402 added by bug 574217 is bogus:

I asked Marco to back this out when he lands his stuff.

Bug 586959 is related to this.
There's been some discussion about whether the window should close if you're in Tab Candy and you close the last tab. For instance, one work flow would be to close all your old tabs before starting a fresh session, and it's an extra step to create a new window first. 

That said, this fix is great for beta 4, and in fact might be the right thing overall. 

Aza, care to weigh in? Maybe start a fresh bug if we want special behavior for closing the last tab inside the Tab Candy window? Obviously if we do allow that, we'll need to make it easier to get back out of that state (including the proposed global "new tab" button).
This problem is gone in new profile, because bug 574217 has been backed out.
However, if set browser.tabs.closeWindowWithLastTab to false, this problem still happens.
(In reply to comment #8)
> This problem is gone in new profile, because bug 574217 has been backed out.
Not all of  the bug 574217, see changeset of 28f97576f0b4.
blocking2.0: --- → ?
Keywords: relnote
Component: Tabbed Browser → TabCandy
QA Contact: tabbed.browser → tabcandy
(In reply to comment #8)
> This problem is gone in new profile, because bug 574217 has been backed out.
> However, if set browser.tabs.closeWindowWithLastTab to false, this problem
> still happens.

If set browser.tabs.closeWindowWithLastTab to false, a new tab would be opened in the tab view interface and you can use it to go back to the browser view.
(In reply to comment #10)
> (In reply to comment #8)
> > This problem is gone in new profile, because bug 574217 has been backed out.
> > However, if set browser.tabs.closeWindowWithLastTab to false, this problem
> > still happens.
> 
> If set browser.tabs.closeWindowWithLastTab to false, a new tab would be opened
> in the tab view interface and you can use it to go back to the browser view.
Confirmed
Fixed by changeset 28f97576f0b4
Status: NEW → RESOLVED
Closed: 14 years ago
Keywords: relnote
Resolution: --- → FIXED
Whiteboard: [Aug-13-testday][b4]
Assignee: aza → dao
blocking2.0: ? → ---
Component: TabCandy → Tabbed Browser
QA Contact: tabcandy → tabbed.browser
Target Milestone: --- → Firefox 4.0b4
Build identifier: Mozilla/5.0 (Windows NT 6.1; rv:2.0b11pre) Gecko/20110130 Firefox/4.0b11pre

If I have one tab in one group and I close the tab the window closes too but if I close the group the window doesn't closes, it opens a new tab. Shouldn't this two actions do the same thing?
You need to log in before you can comment on or make changes to this bug.