Skip to content

Respect the search reverse direction when pressing NVDA+shift+F3 first call#11771

Merged
feerrenrut merged 3 commits into
nvaccess:masterfrom
CyrilleB79:findPrevious
Oct 19, 2020
Merged

Respect the search reverse direction when pressing NVDA+shift+F3 first call#11771
feerrenrut merged 3 commits into
nvaccess:masterfrom
CyrilleB79:findPrevious

Conversation

@CyrilleB79

Copy link
Copy Markdown
Contributor

Link to issue number:

Fixes #11770

Summary of the issue:

When pressing NVDA+shift+F3 in browse mode for first time, the find dialog opens since nothing was searched before. However, the find dialog always considers that the term to find should be after the current cursor position.
In the case of NVDA+shift+F3 however, the user has clearly indicated that he wants to search backwards; this is not respected in this case.

Description of how this pull request fixes the issue:

Add a boolean "reverse" parameter to the script_find and the FindDialog so that reverse searching can be honoured in this case.
This PR does the minimum to fix #11770.

Even if the FindDialog contains the information to know if search should be forward or backward (depending on how it was called), this information does not appear in the GUI and cannot be controlled/changed in the dialog.
This would be a new feature and may be the object of another PR if there is a need for it.

Testing performed:

Tested these situations when nothing has been searched before:

  • NVDA+ctrl+F (normal search)
  • NVDA+F3 when there is something to find after current position
  • NVDA+F3 when there is nothing to find after current position
  • NVDA+shift+F3 when there is something to find after current position
  • NVDA+shift+F3 when there is nothing to find after current position
    Also tested these cases when something has been already searched before.

Known issues with pull request:

None

Change log entry:

Section: Bug fixes

The backward search direction is now respected when calling find previous script as first search action. (#11770)

Note: feel free to rephrase this change log entry; I did not find better.

…VDA+shift+F3 if nothing else was searched before.
@AppVeyorBot

Copy link
Copy Markdown

See test results for failed build of commit 3abf893d3b

@AppVeyorBot

This comment has been minimized.

@AppVeyorBot

This comment has been minimized.

@feerrenrut feerrenrut left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks @CyrilleB79

@feerrenrut feerrenrut merged commit de30c94 into nvaccess:master Oct 19, 2020
@nvaccessAuto nvaccessAuto added this to the 2020.4 milestone Oct 19, 2020
@CyrilleB79 CyrilleB79 deleted the findPrevious branch October 20, 2020 07:14
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Bug with NVDA+shift+f3

4 participants