Closed
Bug 348737
Opened 18 years ago
Closed 18 years ago
restoring defaults in "manage search engines..." results in unordered list
Categories
(Firefox :: Search, defect, P1)
Tracking
()
VERIFIED
FIXED
Firefox 2
People
(Reporter: cbeard, Assigned: Gavin)
References
Details
(Keywords: verified1.8.1)
Attachments
(1 file)
5.17 KB,
patch
|
mconnor
:
review+
mtschrep
:
approval1.8.1+
|
Details | Diff | Splinter Review |
If you use the "Manage Search Engines..." UI to delete a search engine and then click on "Restore Defaults" it places the deleted search engine at the top of the list. Whereas, it should restore the default set of search engines in the same order as shipped.
Steps to reproduce:
1. Note that search engines are ordered Google, Yahoo!, Amazon.com, Creative Commons, eBay in the drop down.
2. Open the "Manage Search Engines..." UI and delete "Creative Commons".
3. Click on "Restore Defaults".
4. Note that the search engines are now ordered Creative Commons, Google, Yahoo!, Amazon.com, eBay.
Reporter | ||
Updated•18 years ago
|
Flags: blocking-firefox2?
Updated•18 years ago
|
Severity: critical → major
OS: Mac OS X 10.3 → All
Hardware: PC → All
Comment 1•18 years ago
|
||
Known problem. The restored engines are in order with respect to each other, however.
Severity: major → normal
Reporter | ||
Comment 2•18 years ago
|
||
(In reply to comment #1)
> Known problem. The restored engines are in order with respect to each other,
> however.
Is there a bug filed on this already? I disagree that this behaviour is acceptable . It is confusing to the end-user and does not "restore" you to a known good state. It also does not meet the product requirement. We should correct this, and it should block release.
Updated•18 years ago
|
Flags: blocking-firefox2? → blocking-firefox2+
Comment 3•18 years ago
|
||
Won't block beta2, should be fixed by final. Can we use the fact that we have the order in which these searchplugins are first created to help here?
Target Milestone: Firefox 2 beta2 → Firefox 2
Comment 4•18 years ago
|
||
(In reply to comment #2)
> (In reply to comment #1)
> > Known problem. The restored engines are in order with respect to each other,
> > however.
>
> Is there a bug filed on this already?
Nope.
> I disagree that this behaviour is
> acceptable .
I never said it was. I was merely saying that there is some ordering done, so it is possible to restore the default order if you just delete everything.
(In reply to comment #3)
> Won't block beta2, should be fixed by final. Can we use the fact that we have
> the order in which these searchplugins are first created to help here?
>
We already have the ordering info - we merely have to use it. I had some issues trying to get that to work in bug 343707, so that was taken out in order to get some sort of restore defaults functionality landed in the engine manager for beta 2. The safe mode functionality also needs the same change.
Assignee | ||
Comment 5•18 years ago
|
||
Michael: can the "restore" function do a second pass through the list once it's restored the defaults, and produce the correct engineMoveOps to restore the original engine order (defaults at the top)? Obviously not the most efficient algorithm (potentially resulting in a lot of redundant moveOps), but if it works...
Assignee | ||
Updated•18 years ago
|
Status: NEW → ASSIGNED
Priority: -- → P1
Assignee | ||
Comment 7•18 years ago
|
||
This patch:
-Fixes getDefaultEngines to use getLocalizedPref. Calling getLocalizedPref in a loop isn't optimal, because it re-gets the prefservice on each call, but since that loop won't occur very often and isn't perf-critical, I favored readability
-Fixes both moveEngine functions to do nothing if the engine doesn't actually need to move (to ensure that "restoring" one engine in an already sorted list won't move and fire notifications for all engines in that list)
-Makes restoreDefaultEngines move already present default engines to their original positions when restoring
Attachment #235578 -
Flags: review?(mconnor)
Assignee | ||
Updated•18 years ago
|
Whiteboard: [patch-r?]
Comment 8•18 years ago
|
||
Comment on attachment 235578 [details] [diff] [review]
patch
ok.
Is there a reason we don't cache the prefbranch in this impl? its not that much work, and it helps perf a great deal
Attachment #235578 -
Flags: review?(mconnor) → review+
Assignee | ||
Comment 9•18 years ago
|
||
(In reply to comment #8)
> Is there a reason we don't cache the prefbranch in this impl? its not that
> much work, and it helps perf a great deal
Cache it where, in a global? I'd rather not hold on to it for the life of the app. This could certainly be optimized otherwise, but I don't think it's really worth the trouble for the trivial gain.
Whiteboard: [patch-r?]
Assignee | ||
Comment 10•18 years ago
|
||
mozilla/browser/components/search/content/engineManager.js 1.12
mozilla/browser/components/search/nsSearchService.js 1.75
Status: ASSIGNED → RESOLVED
Closed: 18 years ago
Resolution: --- → FIXED
Whiteboard: [needs approval]
Updated•18 years ago
|
Whiteboard: [needs approval] → [baking until 8/29][needs approval]
Comment 11•18 years ago
|
||
Attachment #235578 -
Flags: approval1.8.1?
Comment 12•18 years ago
|
||
Comment on attachment 235578 [details] [diff] [review]
patch
a=schrep/beltnzer for drivers.
Attachment #235578 -
Flags: approval1.8.1? → approval1.8.1+
Updated•18 years ago
|
Whiteboard: [baking until 8/29][needs approval]
Assignee | ||
Comment 13•18 years ago
|
||
mozilla/browser/components/search/nsSearchService.js 1.1.2.63
mozilla/browser/components/search/content/engineManager.js 1.1.2.14
Keywords: fixed1.8.1
Comment 14•18 years ago
|
||
Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.9a1) Gecko/20060827 Minefield/3.0a1 ID:2006082718 [cairo]
search-box missing, manage search engines no response.
the checkin cause this ?
Assignee | ||
Comment 15•18 years ago
|
||
(In reply to comment #14)
> search-box missing, manage search engines no response.
> the checkin cause this ?
Nope, see bug 350424.
Comment 16•18 years ago
|
||
Verified FIXED using Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.8.1b2) Gecko/20060828 BonEcho/2.0b2.
Deleted engines are now restored to their original order.
(If we're going to consider reordering engines making things non-default, shouldn't we activate the "Restore Defaults..." button if someone reorders an engine?)
Status: RESOLVED → VERIFIED
Keywords: fixed1.8.1 → verified1.8.1
Reporter | ||
Comment 17•18 years ago
|
||
Awesome! Thanks!
You need to log in
before you can comment on or make changes to this bug.
Description
•