MozillaZine

How do I close the last/only tab without closing Firefox 3.5

User Help for Mozilla Firefox
trupson
Guest
 

Post Posted July 1st, 2009, 2:45 pm

Add this in your userchrome.css and the x will return:


/* Add tab-close-button to last tab */
.tabbrowser-tabs[closebuttons="alltabs"] > .tabbrowser-tab >
.tab-close-button { display: -moz-box !important; }
.tabbrowser-tabs:not([closebuttons="noclose"]):not
([closebuttons="closeatend"]) >
.tabbrowser-tab[selected="true"] > .tab-close-button { display: -moz-
box !important; }

Frank Lion

User avatar
 
Posts: 19516
Joined: April 23rd, 2004, 6:59 pm
Location: ... The Exorcist....United Kingdom

Post Posted July 1st, 2009, 3:15 pm

Bluefang wrote:No Frank, what the OP basically said was that they have to exit Firefox to close the last tab, not closing the last tab cause Firefox to exit.

Well, the thread title seemed pretty clear, but...

@trupson ...that is a very poor way of coding. Good job you're not making a theme.
Metal Lion latest SeaMonkey & Thunderbird Themes - Sea Monkey and Silver Sea Monkey
"The only thing necessary for the triumph of evil, is for good men to do nothing." - Edmund Burke (attrib.)

Mouse_
Guest
 

Post Posted July 1st, 2009, 4:07 pm

@Frank, whether it's bad code or not, it fixes the problem much more effectively than your pedantic trolling.



@trupson, thanks for the code, it works like a charm.

Frank Lion

User avatar
 
Posts: 19516
Joined: April 23rd, 2004, 6:59 pm
Location: ... The Exorcist....United Kingdom

Post Posted July 1st, 2009, 4:55 pm

Mouse_ wrote:@Frank, whether it's bad code or not, it fixes the problem much more effectively than your pedantic trolling.

Well, I was going to check something and then suggest a more effective coding for this that wouldn't break with extensions but forget that! How is trying to help people trolling, anonymous rodent?
Metal Lion latest SeaMonkey & Thunderbird Themes - Sea Monkey and Silver Sea Monkey
"The only thing necessary for the triumph of evil, is for good men to do nothing." - Edmund Burke (attrib.)

Guest
Guest
 

Post Posted July 1st, 2009, 5:15 pm

Code: Select all
.tabbrowser-tab[first-tab][last-tab] .tab-close-button
{
  display: -moz-box !important;
}

Guest
Guest
 

Post Posted July 1st, 2009, 6:42 pm

I am a Firefox user. How can I set a Firefox-3.0.x-like last tab close button? I do not want to install any addon nor want to close FF after clicking the last tab button.

I used to use the last tab button to close the last open webpage because in my system this method was quicklier than opening a blank page.

I tried both codes posted above but the tab button closes Firefox 3.5, not only the last open webpage.

PanPArowka997
Guest
 

Post Posted July 1st, 2009, 8:10 pm

Agger whit last post! O want back "close last tab" :-( Im really sad that mozilla delate it:/ and give us those "open new tab" icon :/
Last edited by LIMPET235 on July 1st, 2009, 9:33 pm, edited 1 time in total.
Reason: Removed offensive language..

Bluefang

User avatar
 
Posts: 7857
Joined: August 10th, 2005, 2:55 pm
Location: Vermont

Post Posted July 1st, 2009, 8:24 pm

I tried both codes posted above but the tab button closes Firefox 3.5, not only the last open webpage.

That has already been answered multiple times

Frank Lion wrote:1) In the address bar, type about:config
2) In the search box, type browser.tabs.closeWindowWithLastTab
3) Toggle this to false.
There have always been ghosts in the machine... random segments of code that have grouped together to form unexpected protocols. Unanticipated, these free radicals engender questions of free will, creativity, and even the nature of what we might call the soul...

Guest
Guest
 

Post Posted July 1st, 2009, 10:21 pm

I am the Firefox 3.5 user who posted at 6:42 pm

The method:

> 1) In the address bar, type about:config
> 2) In the search box, type browser.tabs.closeWindowWithLastTab
> 3) Toggle this to false.

does NOT work in my system to set a Firefox-3.0.x-like last tab close button.

Nothing happens. The last tab close button still is missing.

LIMPET235
Moderator

User avatar
 
Posts: 37719
Joined: October 19th, 2007, 1:53 am
Location: The South Coast of N.S.W. Oz.

Post Posted July 1st, 2009, 10:39 pm

@ Guest ^, above...
Check this setting in your configurations.
Open a new, blank tab.
Type or C n P, "about:config" (without the quotes) into the URL bar.
At the top of the next screen, there is a Filter bar.
Type or C n P, "browser.tabs.closeButtons" (without the quotes) into the bar.
Right click to highlight & toggle or re-set to 1. (One).
This gives you buttons on all tabs.
(I have it set at 3...for one button only, at the RHS).
Change is instantaneous.
Ancient Amateur Astronomer
Win-7-HP/Intel® DualCore-2.0GHz/500G HDD/4 Gig Ram/550Watt PSU/350WattUPS/Firefox-20.0-56.0.1-57.0/T-bird-2.0.0.24/SnagIt-v10.0.1/MWP-7.11.0.
RadioYachting.
(Always choose the "Custom" Install.)

Bluefang

User avatar
 
Posts: 7857
Joined: August 10th, 2005, 2:55 pm
Location: Vermont

Post Posted July 1st, 2009, 11:33 pm

I swear people are not reading this topic

browser.tabs.closeWindowWithLastTab ONLY controls wether or not the window is closed when you close the last tab. It does not affect the visibility of the close button.

the userChrome.css code is what controls the visibility of the button. If you don't want to mess around with the userChrome.css, then install Tab Mix Plus
There have always been ghosts in the machine... random segments of code that have grouped together to form unexpected protocols. Unanticipated, these free radicals engender questions of free will, creativity, and even the nature of what we might call the soul...

Guest
Guest
 

Post Posted July 1st, 2009, 11:40 pm

LIMPET235, thank you for your help, but it didn't work.

* "browser.tabs.closeButtons" value was 1 in my system.
* I changed it to 0,
* I restarted Firefox 3.5,
* I resetted "browser.tabs.closeButtons" value to 1
* I restarted Firefox 3.5,

Results Last tab close button still is missing.

Guest
Guest
 

Post Posted July 1st, 2009, 11:59 pm

Bluefang, thank you for your comment. I really try to avoid addons.

I feel Firefox 3.5 is a beta browser, not a finished one. Seems each new version of Firefox has less features than the previous one: it already lost DOM tool, Links and Forms tab in Page Info tool, and now, what sicks me more is the missing last tab close button and that I have to do two clicks to clear recent history instead the one click of Firefox 3.0.x

Somatt
Guest
 

Post Posted July 2nd, 2009, 2:26 am

I have the same disappointment about this.
Being able to close the last tab with a simple button without closing firefox is a basic feature.
Actually, considering the time firefox takes to load, it's even a needed feature !!
That it is not enabled by default, I'm fine with it. But now I see we can't enable that simple button without adding a third party plugin or non standard css ?? Come on, what have they been high on at mozilla !
I'm fine with them improving the motor, but don't take away the rearview mirror !!

Alia
Guest
 

Post Posted July 2nd, 2009, 2:51 am

Sorry if I caused confusion here, English is not my native language. I'll try again. My actual problem is that I now need to close Firefox to close the last open tab. Or if I remove the tab bar, Firefox closes when I click on the X in the title bar. The workaround that's been posted here also doesn't work for me, it doesn't bring back the X on the last tab. I want Firefox to always remain open but I don't want to have the last tab page displayed all the time. So I want to be able to close the last tab without having to manually open another empty tab first, or using a control key combination for it. I've found out by now that for me clicking the mouse wheel button closes the tab, but that's also not very convenient. I really want the X back on the last tab. So I'll guess I'll go and try TabMix too.

Return to Firefox Support


Who is online

Users browsing this forum: aborix and 8 guests