1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-26 19:57:45 +00:00

HexEditor: Add toolbar and context menus to the Annotations panel

The Annotations panel is the most obvious place to perform actions
related to annotations, so let's make that possible. :^)

The toolbar gets open/save/save-as actions for annotations, and one for
adding an annotation. The table itself gets a context menu for editing
or deleting the selected annotation.
This commit is contained in:
Sam Atkins 2024-02-06 16:57:02 +00:00 committed by Sam Atkins
parent a5d11c0a26
commit 56eb45ccbc
5 changed files with 67 additions and 4 deletions

View file

@ -64,6 +64,7 @@ public:
void add_annotation(Annotation);
void delete_annotation(Annotation const&);
Optional<Annotation&> closest_annotation_at(size_t position);
Optional<Annotation&> get_annotation(GUI::ModelIndex const& index);
ErrorOr<void> save_to_file(Core::File&) const;
ErrorOr<void> load_from_file(Core::File&);