Browser: Move BookmarksBarWidget::PerformEditOn to anon namespace

Since none of `BookmarksBarWidget`'s methods use this enum class any
longer, let's just move it to the anonymous namespace so that
`BookmarkEditor` can still make use of it.
This commit is contained in:
Kemal Zebari 2023-11-14 12:43:45 -08:00 committed by Andrew Kaster
parent bd1e76a98a
commit 6b5a0100d9
2 changed files with 7 additions and 7 deletions

View file

@ -27,15 +27,20 @@ namespace Browser {
namespace {
enum class PerformEditOn {
NewBookmark,
ExistingBookmark
};
class BookmarkEditor final : public GUI::Dialog {
C_OBJECT(BookmarkEditor)
public:
static Vector<JsonValue>
edit_bookmark(Window* parent_window, StringView title, StringView url, BookmarksBarWidget::PerformEditOn perform_edit_on)
edit_bookmark(Window* parent_window, StringView title, StringView url, PerformEditOn perform_edit_on)
{
auto editor = BookmarkEditor::construct(parent_window, title, url);
if (perform_edit_on == BookmarksBarWidget::PerformEditOn::NewBookmark) {
if (perform_edit_on == PerformEditOn::NewBookmark) {
editor->set_title("Add Bookmark");
} else {
editor->set_title("Edit Bookmark");

View file

@ -32,11 +32,6 @@ public:
InNewWindow
};
enum class PerformEditOn {
NewBookmark,
ExistingBookmark
};
Function<void(DeprecatedString const& url, Open)> on_bookmark_click;
Function<void(DeprecatedString const&, DeprecatedString const&)> on_bookmark_hover;
Function<void()> on_bookmark_change;