1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-27 07:07:34 +00:00

HexEditor: Add 'Find All' option to Find Dialog to find all matches

This commit is contained in:
Brendan Coles 2021-05-27 15:51:21 +00:00 committed by Andreas Kling
parent d7797c8bf8
commit 6aa766f8ca
9 changed files with 238 additions and 30 deletions

View file

@ -6,6 +6,7 @@
#pragma once
#include "SearchResultsModel.h"
#include <AK/ByteBuffer.h>
#include <AK/Function.h>
#include <AK/HashMap.h>
@ -46,7 +47,9 @@ public:
void set_position(int position);
void highlight(int start, int end);
int find(ByteBuffer& needle, int start = 0);
int find_and_highlight(ByteBuffer& needle, int start = 0);
Vector<Match> find_all(ByteBuffer& needle, int start = 0);
Function<void(int, EditMode, int, int)> on_status_change; // position, edit mode, selection start, selection end
Function<void()> on_change;