Closed Bug 171079 Opened 20 years ago Closed 20 years ago

View Selection Source triggers typeaheadfind

Categories

(SeaMonkey :: Find In Page, defect, P2)

defect

Tracking

(Not tracked)

VERIFIED FIXED
mozilla1.2beta

People

(Reporter: tuukka.tolvanen, Assigned: aaronlev)

References

Details

Attachments

(1 file)

User-Agent:       Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.2b) Gecko/20020927 Phoenix/0.2
Build Identifier: linux trunk cvs 2002-09-26

.

Reproducible: Always

Steps to Reproduce:
1) http://www.mozilla.org/
2) typeaheadfind /moz
3) select text
4) context menu > View Selection Source
Actual Results:  
viewsource comes up; typeaheadfind happens, apparently from the end of selection
onwards; selection goes away.

Expected Results:  
viewsource comes up.
Blocks: isearch
Confirmed, Win2K 2002092617.
Confirming and marking NEW 2002092608 on Win2k.

OS -> All
Status: UNCONFIRMED → NEW
Ever confirmed: true
OS: Linux → All
Status: NEW → ASSIGNED
Priority: -- → P2
Target Milestone: --- → mozilla1.2beta
CC'ing the reviewers of the previous patch in bug 167921, which caused this.

The problem is, typeaheadfind was comparing the currently focused window with
the last window that typeaheadfind occcured in. If they're different, it lets
webbrowserfind do the find next.

It *should* be comparing the window where actual find next command is occuring,
instead of assuming that window is focused.
Seeking r=akkana, sr=sfraser.

The old code used nsISupportsPRBool so that the findnext observer could pass
back a boolean indicating whether it handled the command.

New patch uses nsISupportsInterfacePointer to pass in the current search frame.
The pointer data is cleared out when the observer handles the command.
NotifyObservers doesn't have any other params available, and the return value
apparently won't make it back to the caller. So clearing out the data to
indicate it's been used is the best alternative.
Comment on attachment 101735 [details] [diff] [review]
Still uses nsIObserver, but passes in the current search frame to use in comparison

r=akkana
Attachment #101735 - Flags: review+
Comment on attachment 101735 [details] [diff] [review]
Still uses nsIObserver, but passes in the current search frame to use in comparison

sr=sfraser
Attachment #101735 - Flags: superreview+
checked in
Status: ASSIGNED → RESOLVED
Closed: 20 years ago
Resolution: --- → FIXED
vrfy'd fixed with 2002.10.22.08 comm trunk builds.
Status: RESOLVED → VERIFIED
Hardware: PC → All
Component: Keyboard: Navigation → Keyboard: Find as you Type
Product: Core → SeaMonkey
You need to log in before you can comment on or make changes to this bug.