Closed Bug 286367 Opened 19 years ago Closed 18 years ago

clear button disabled after quick search

Categories

(SeaMonkey :: MailNews: Message Display, defect)

x86
All
defect
Not set
normal

Tracking

(Not tracked)

RESOLVED FIXED

People

(Reporter: ajschult784, Assigned: ajschult784)

References

()

Details

(Keywords: fixed-seamonkey1.1, regression)

Attachments

(1 file)

With linux seamonkey trunk build 2005031405 If I do a "quick" quick search (type
in the search bar and hit enter quickly), the clear button stays deactivated.  I
get these in JS Console:

Error: gSearchBundle has no properties
Source File: chrome://messenger/content/searchBar.js
Line: 106

Error: gSearchBundle has no properties
Source File: chrome://messenger/content/searchBar.js
Line: 65

It looks like 272856 switched the code path around, but it looks like
gSearchInput can get initialized in quite a few different places (which would
then prevent the call to GetDocumentElements), but gSearchBundle can only
initialized in GetDocumentElements.
Attached patch patchSplinter Review
see fish in barrel.  shoot.
Attachment #177585 - Flags: superreview?(bienvenu)
Attachment #177585 - Flags: review?(neil.parkwaycc.co.uk)
Comment on attachment 177585 [details] [diff] [review]
patch

Hmm... maybe we should back out 272856 and fix it a different way?
Hmm... so onSearchInput() is to blame here because to select the text it calls
GetSearchInput before onEnterInSearchBar().
I'm seeing the exact same thing in Windows build 2005041905, including the
Javascript Console errors.  Changing OS to ALL.

Looks like a recurrence of Bug 277884.
OS: Linux → All
Comment on attachment 177585 [details] [diff] [review]
patch

>Index: searchBar.js
>===================================================================
> function onEnterInSearchBar()
> {
>-   if (!gSearchInput)
>+   if (!gSearchBundle)
>      getDocumentElements();

Wouldn't the following be better?
>+   if (!gSearchBundle || !gSearchInput)
Well, there are four variables that get initialized by getDocumentElements and
all of them could get checked.  But gSearchBundle (or gStatusBar or
gClearButton) only get set in that function, while gSearchInput can get set by a
separate call to GetSearchInput (which is exactly what's happening in this bug).
Comment on attachment 177585 [details] [diff] [review]
patch

This'll do for now, but I want to totally rewrite this to use a timed textbox
anyway ;-)
Attachment #177585 - Flags: review?(neil.parkwaycc.co.uk) → review+
WFM (build 2005-07-30 Windows)
Doesn't work for me. I don't see anything in the js console anymore, but the
'clear' button is still disabled after typing something.
I am seeing this problem running the 2005-11-20 nightly

Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.9a1) Gecko/20051120 SeaMonkey/1.5a

I see the following JavaScript errors:

Error: gSearchBundle has no properties
Source File: chrome://messenger/content/searchBar.js
Line: 106

Error: gSearchBundle has no properties
Source File: chrome://messenger/content/searchBar.js
Line: 65
This might get fixed when bug 179050 gets fully fixed.
I tried adding 179050 to the "depends on" field, but I do not have permission to set that field.  Could someone set that field?
While we are waiting for Bug 179050 to get fixed, could the fix from Comment 7 get checked in so this problem gets resolved?
Depends on: 179050
Attachment #177585 - Flags: superreview?(bienvenu) → superreview+
I checked in the patch.  I don't see the bug now that bug 179050 is fixed, but this should provide robustification and perhaps catch an edge case.
Status: NEW → RESOLVED
Closed: 18 years ago
Resolution: --- → FIXED
Which branch received Attachment 177585 [details] [diff]?  I installed SeaMonkey 1.1a to get the fix for 179050, and this issue does seem fixed there.  But it would be nice to be able to also use the more stable SeaMonkey 1.0 branch.
Comment on attachment 177585 [details] [diff] [review]
patch

requesting branch approval to fix bug 364060 on branch
Attachment #177585 - Flags: approval-seamonkey1.1?
Comment on attachment 177585 [details] [diff] [review]
patch

This seemingly has baked on trunk for a very long time now, so giving straight a=me for SeaMonkey 1.1
Attachment #177585 - Flags: approval-seamonkey1.1? → approval-seamonkey1.1+
patch landed, bug 364060 is fixed-on-branch
Blocks: 364060
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: