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

Browser: Don't show error message box when canceling editor dialog

Currently, an error message box appears when a user tries to cancel
the editor dialog while editing or adding a bookmark.

This snapshot resolves this by having `add_bookmark()` and
`BookmarksBarWidget::edit_bookmark()` perform an if check on the
result of `BookmarkEditor::edit_bookmark()` to see if the dialog
was canceled.
This commit is contained in:
Kemal Zebari 2023-05-03 15:01:52 -07:00 committed by Andreas Kling
parent 0ad131e13d
commit 8f5cc613d2
2 changed files with 26 additions and 6 deletions

View file

@ -44,7 +44,7 @@ public:
bool contains_bookmark(StringView url);
ErrorOr<void> remove_bookmark(StringView url);
ErrorOr<void> add_bookmark(StringView url, StringView title);
ErrorOr<void> edit_bookmark(StringView url, PerformEditOn perform_edit_on = PerformEditOn::ExistingBookmark);
ErrorOr<void> edit_bookmark(StringView url);
virtual Optional<GUI::UISize> calculated_min_size() const override
{