Closed Bug 343917 Opened 18 years ago Closed 18 years ago

Use Current page as homepage is slightly broken

Categories

(Firefox :: Settings UI, defect)

2.0 Branch
x86
Linux
defect
Not set
normal

Tracking

()

RESOLVED INVALID

People

(Reporter: ispiked, Assigned: Waldo)

References

()

Details

With the new preference window...

Steps to reproduce:
1. Go to a URL such as http://www.google.com/.
2. Go to Edit > Preferences and choose the "Use this page" radio button.

also..

3. Click the "Use Current" button.

Results:
After step 2 nothing is displayed in the textbox. When I close the pref. window the pref. isn't written either.

After step 3 the current URL is loaded in the textbox, and the page's title is also loaded in the "Use a Bookmark" textbox as well as that radio button being selected.

Expected results:
When the radio box is selected, update the textbox. Also, don't switch the radio box and update the page title when the "Use Current" button is pressed.
(In reply to comment #0)
> 1. Go to a URL such as http://www.google.com/.
> 2. Go to Edit > Preferences and choose the "Use this page" radio button.
> 
> After step 2 nothing is displayed in the textbox. When I close the pref.
> window the pref. isn't written either.

This is intentional -- the URL written to prefs is the URL in the corresponding text field, and since there's nothing there, nothing is written.

This somewhat-unintuitive behavior is a result of the particular UI model chosen, which I think is theoretically better than the previous UI but is worse in practice, at least as I implemented it.  I can think of ways to change this to make this particular case a little better (populate the field with the current homepage choice on radio selection), but the problem would remain if you select the bookmark radio and then cancel (with a set homepage which isn't a bookmark [or, referring to the next comment, in history]).

Also, while I remember, there's some brokenness if you have Firefox Start selected and then select Bookmarks and then Current Page (or maybe the other way around) without activating a corresponding button or typing a URL.  That needs to be fixed, and this feels like a homepage preference UI meta-bug.
(In reply to comment #0)
> 1. Go to a URL such as http://www.google.com/.
> 2. Go to Edit > Preferences and choose the "Use this page" radio button.
> 3. Click the "Use Current" button.
> 
> After step 3 the current URL is loaded in the textbox, and the page's title is
> also loaded in the "Use a Bookmark" textbox as well as that radio button being
> selected.

(Note: this particular concern is Places-specific and thus is not germane to 2.0 work, although handling of bookmark homepages with 2.0 code is sub-par for reasons easily understood by anyone familiar with the 2.0 bookmarks "API".)

http://lxr.mozilla.org/mozilla/source/browser/components/preferences/main.js#102

The Places APIs let us determine whether a URL exists in bookmarks or history, but on my glance through the APIs I didn't see a way to determine whether a URL only exists in bookmarks or not.  Brett, did I just miss such an API, or is this something that needs to be taken into account as the Places code/API evolves?
Assignee: nobody → jwalden+bmo
The home page prefs UI has changed, making this bug INVALID.  Feel free to file new bugs against the new UI, however.  :-)
Status: NEW → RESOLVED
Closed: 18 years ago
Resolution: --- → INVALID
You need to log in before you can comment on or make changes to this bug.