- //! Create an AbstractChatView for the given BufferId and add it to the UI if necessary
- virtual AbstractChatView *createChatView(BufferId) = 0;
+ //! Create an AbstractChatView for the given BufferId and add it to the UI if necessary
+ virtual AbstractChatView* createChatView(BufferId) = 0;
+
+ //! Remove a chat view from the UI and delete it
+ /** This method shall remove the view from the UI (for example, from a QStackedWidget) if appropriate.
+ * It also shall delete the object afterwards.
+ * \param view The chat view to be removed and deleted
+ */
+ virtual void removeChatView(BufferId) = 0;