diff --git a/Userland/Libraries/LibGUI/Action.cpp b/Userland/Libraries/LibGUI/Action.cpp index dcf7ca8c3b..b1d3a433dd 100644 --- a/Userland/Libraries/LibGUI/Action.cpp +++ b/Userland/Libraries/LibGUI/Action.cpp @@ -65,11 +65,6 @@ NonnullRefPtr Action::create_checkable(DeprecatedString text, Shortcut c return adopt_ref(*new Action(move(text), shortcut, Shortcut {}, move(icon), move(callback), parent, true)); } -ErrorOr> Action::try_create_checkable(DeprecatedString text, Shortcut const& shortcut, Function callback, Core::EventReceiver* parent) -{ - return adopt_nonnull_ref_or_enomem(new (nothrow) Action(move(text), shortcut, Shortcut {}, move(callback), parent, true)); -} - RefPtr Action::find_action_for_shortcut(Core::EventReceiver& object, Shortcut const& shortcut) { RefPtr found_action = nullptr; diff --git a/Userland/Libraries/LibGUI/Action.h b/Userland/Libraries/LibGUI/Action.h index de2f8e257a..558cf15a2e 100644 --- a/Userland/Libraries/LibGUI/Action.h +++ b/Userland/Libraries/LibGUI/Action.h @@ -77,8 +77,6 @@ public: static NonnullRefPtr create_checkable(DeprecatedString text, Shortcut const& shortcut, Function callback, Core::EventReceiver* parent = nullptr); static NonnullRefPtr create_checkable(DeprecatedString text, Shortcut const& shortcut, RefPtr icon, Function callback, Core::EventReceiver* parent = nullptr); - static ErrorOr> try_create_checkable(DeprecatedString text, Shortcut const& shortcut, Function callback, Core::EventReceiver* parent = nullptr); - static RefPtr find_action_for_shortcut(Core::EventReceiver& object, Shortcut const& shortcut); virtual ~Action() override;