Why is there that code?

Talk about code development, features, specific bugs, enhancements, patches, and similar things.
Forum rules
Please keep everything here strictly on-topic.
This board is meant for Pale Moon source code development related subjects only like code snippets, patches, specific bugs, git, the repositories, etc.

This is not for tech support! Please do not post tech support questions in the "Development" board!
Please make sure not to use this board for support questions. Please post issues with specific websites, extensions, etc. in the relevant boards for those topics.

Please keep things on-topic as this forum will be used for reference for Pale Moon development. Expect topics that aren't relevant as such to be moved or deleted.
Fedor2

Why is there that code?

Unread post by Fedor2 » 2018-02-06, 04:18

https://github.com/MoonchildProductions ... ue.js#L685

I do not get it, what is the purpose of that, can it be some bug? Becauase of that browser.showQuitWarning not works, but there are users who want use this setting.

I removed that code, and browser.showQuitWarning began do properly, and seems no other things has broken. Let that code to be removed from main code.

New Tobin Paradigm

Re: Why is there that code?

Unread post by New Tobin Paradigm » 2018-02-06, 05:43

No. Stop telling us what to do about things you don't understand. The feature works as intended.

User avatar
Moonchild
Pale Moon guru
Pale Moon guru
Posts: 35481
Joined: 2011-08-28, 17:27
Location: Motala, SE
Contact:

Re: Why is there that code?

Unread post by Moonchild » 2018-02-06, 10:26

If # pages < 2, then don't show quit warning == correct behavior.
"Sometimes, the best way to get what you want is to be a good person." -- Louis Rossmann
"Seek wisdom, not knowledge. Knowledge is of the past; wisdom is of the future." -- Native American proverb
"Linux makes everything difficult." -- Lyceus Anubite

Fedor2

Re: Why is there that code?

Unread post by Fedor2 » 2018-02-06, 11:18

Yes, by default it do that way exactly.
But when users enabled browser.showQuitWarning they want get quit warning on one page too, is that wrong?

User avatar
Moonchild
Pale Moon guru
Pale Moon guru
Posts: 35481
Joined: 2011-08-28, 17:27
Location: Motala, SE
Contact:

Re: Why is there that code?

Unread post by Moonchild » 2018-02-06, 12:39

Fedor2 wrote:Yes, by default it do that way exactly.
But when users enabled browser.showQuitWarning they want get quit warning on one page too, is that wrong?
You clearly don't understand the preferences involved. Stop messing with them.
"Sometimes, the best way to get what you want is to be a good person." -- Louis Rossmann
"Seek wisdom, not knowledge. Knowledge is of the past; wisdom is of the future." -- Native American proverb
"Linux makes everything difficult." -- Lyceus Anubite

Fedor2

Re: Why is there that code?

Unread post by Fedor2 » 2018-02-07, 05:59

So i want to understand.
If you want to get quit warning on closing browser with one page, what you are to tweak in the prefs?
I found these related:

Code: Select all

browser.tabs.warnOnClose;true
browser.tabs.warnOnCloseOtherTabs;true
browser.warnOnQuit;true
browser.showQuitWarning;false
One is false, and with that you get quit warning on two and greater pages, so i think if to enable the last, i shall get quit warning regardless page count, but with check in the code mentioned above, execution cannot reach to process showQuitWarning if opened only one page.

Locked