+ ContextMenuActionProvider(QObject* parent = nullptr);
+ ~ContextMenuActionProvider() override;
+
+ //! Provide a list of actions applying to the given item
+ /**
+ * Note that this list ist not persistent, hence it should only be used immediately after
+ * calling this function (e.g. in a context menu). Optionally one can provide a QObject and a slot
+ * (that should take a QAction * as parameter) that is invoked for actions that require external
+ * handling.
+ * @param index The item index in the NetworkModel
+ * @param receiver The optional object that is notified for actions that need to be handled externally.
+ * The action type will be stored in the QAction's data().
+ * @param slot The receiving slot
+ * @return A list of actions applying to the given item
+ */
+ template<typename Receiver, typename Slot>
+ void addActions(QMenu* menu, const QModelIndex& index, Receiver* receiver, Slot slot, bool isCustomBufferView = false)
+ {
+ addActions(menu, index, buildActionSlot(receiver, std::move(slot)), isCustomBufferView);
+ }
+ void addActions(QMenu* menu, const QModelIndex& index, ActionSlot = {}, bool isCustomBufferView = false);
+
+ template<typename Receiver, typename Slot>
+ void addActions(QMenu* menu, const QList<QModelIndex>& indexList, Receiver* receiver, Slot slot, bool isCustomBufferView = false)
+ {
+ addActions(menu, indexList, buildActionSlot(receiver, std::move(slot)), isCustomBufferView);
+ }
+ void addActions(QMenu* menu, const QList<QModelIndex>& indexList, ActionSlot = {}, bool isCustomBufferView = false);
+
+ template<typename Receiver, typename Slot>
+ void addActions(QMenu* menu, BufferId id, Receiver* receiver, Slot slot)
+ {
+ addActions(menu, id, buildActionSlot(receiver, std::move(slot)));
+ }
+ void addActions(QMenu* menu, BufferId id, ActionSlot = {});
+
+ template<typename Receiver, typename Slot>
+ void addActions(QMenu* menu, MessageFilter* filter, BufferId msgBuffer, Receiver* receiver, Slot slot)
+ {
+ addActions(menu, filter, msgBuffer, buildActionSlot(receiver, std::move(slot)));
+ }
+ void addActions(QMenu* menu, MessageFilter* filter, BufferId msgBuffer, ActionSlot = {});
+
+ template<typename Receiver, typename Slot>
+ void addActions(QMenu* menu, MessageFilter* filter, BufferId msgBuffer, const QString& chanOrNick, Receiver* receiver, Slot slot)
+ {
+ addActions(menu, filter, msgBuffer, chanOrNick, buildActionSlot(receiver, std::move(slot)));
+ }
+ void addActions(QMenu* menu, MessageFilter* filter, BufferId msgBuffer, const QString& chanOrNick, ActionSlot = {});