Skip to content

Conversation

@Wittmaxi
Copy link

@Wittmaxi Wittmaxi commented Oct 15, 2024

synchronize search history with the FindReplaceOverlay and FindReplaceDialog.

37

This fix is not as extensive as a prior attempt (#2308) and thus does not require as much testing. Since this is a high-priority issue, we want this to be fixed ASAP.

  1. search histories and options are now stored at a centralized place - in the options for the FindReplaceAction class.
  2. the name of the search history settings section is now unified
  3. the search history component of the Find/Replace Overlay now updates it's history on the fly to accomodate.

@github-actions
Copy link
Contributor

github-actions bot commented Oct 15, 2024

Test Results

 1 821 files  ±0   1 821 suites  ±0   1h 43m 28s ⏱️ - 4m 30s
 7 714 tests ±0   7 485 ✅  - 1  228 💤 ±0  1 ❌ +1 
24 303 runs  ±0  23 555 ✅  - 1  747 💤 ±0  1 ❌ +1 

For more details on these failures, see this check.

Results for commit a3b0aa4. ± Comparison against base commit 4fbbe1b.

♻️ This comment has been updated with latest results.

Copy link
Contributor

@HeikoKlare HeikoKlare left a comment

Choose a reason for hiding this comment

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

Sharing the settings between the dialog and the overlay is good. The current proposal will produce a regression in the dialog, which needs to be resolved.

Comment on lines 345 to 347
fDialogSettings= settings.getSection(FindReplaceDialog.class.getName());
if (fDialogSettings == null)
fDialogSettings= settings.addNewSection(FindReplaceDialog.class.getName());
Copy link
Contributor

Choose a reason for hiding this comment

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

This will break the FindReplaceDialog, as it still uses the subsection according to its class name. Shouldn't we use a subsection in the dialog settings of the bundle, e.g., using the class name of the FindReplaceAction class, like done with the FindReplaceDialog before?

Copy link
Author

@Wittmaxi Wittmaxi Oct 16, 2024

Choose a reason for hiding this comment

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

I have made it so that FindReplaceDialog, FindReplaceOverlay and FindNextAction have the exact same method for getting the Dialog Settings in 5847b3d
I have contemplated adding this as a public method to the FindReplaceAction, however I chose not to in order not to pollute API

Copy link
Contributor

Choose a reason for hiding this comment

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

@Wittmaxi Now you extract different settings sections, as each class (the action, overlay and dialog) retrieve the one according their own class instead of the one for the same class (such as the action):

IDialogSettings dialogSettings = settings.getSection(getClass().getName());

@Wittmaxi
Copy link
Author

random fails documented in

#195
#294
#751

@HeikoKlare HeikoKlare force-pushed the MW_fix_find_next branch 5 times, most recently from d8d2d07 to afb6baa Compare October 28, 2024 14:58
…ipse-platform#2285

Synchronize search history with the FindReplaceOverlay,
FindReplaceDialog and FindNextAction.

Fixes eclipse-platform#2285
@HeikoKlare
Copy link
Contributor

Failing test is unrelated and documented: #926

@HeikoKlare HeikoKlare merged commit b0d7509 into eclipse-platform:master Oct 29, 2024
15 of 17 checks passed
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.

2 participants