diff options
| author | Rusty Wagner <rusty.wagner@gmail.com> | 2025-06-17 21:35:08 -0400 |
|---|---|---|
| committer | Rusty Wagner <rusty.wagner@gmail.com> | 2025-06-23 15:19:52 -0400 |
| commit | f59acf14a8a8630a5b9a0e0cb422a1192f247f5d (patch) | |
| tree | 7018ad230557f9e1fcb68cbbd4e6fdefb9b3005a /ui/sidebarcontainer.h | |
| parent | df2691ad3443fdf9767869be73c1014f49383239 (diff) | |
Allow sidebar icons to be hidden
Diffstat (limited to 'ui/sidebarcontainer.h')
| -rw-r--r-- | ui/sidebarcontainer.h | 16 |
1 files changed, 12 insertions, 4 deletions
diff --git a/ui/sidebarcontainer.h b/ui/sidebarcontainer.h index 3ab30c83..acd27761 100644 --- a/ui/sidebarcontainer.h +++ b/ui/sidebarcontainer.h @@ -4,10 +4,9 @@ #include <QtWidgets/QStackedWidget> #include <QtWidgets/QWidget> #include "splitter.h" +#include "sidebarwidget.h" class Sidebar; -class SidebarWidgetType; -class SidebarWidgetAndHeader; class SplitPaneWidget; /*! @@ -88,17 +87,22 @@ class BINARYNINJAUIAPI SidebarWidgetContainer : public QWidget std::map<SplitPaneWidget*, std::map<ViewFrame*, std::map<QString, std::map<SidebarWidgetType*, SidebarWidgetAndHeader*>>>> m_widgets; + std::map<SplitPaneWidget*, + std::map<ViewFrame*, std::map<QString, std::map<SidebarWidgetType*, SidebarContentClassifier*>>>> + m_contentClassifiers; std::map<SplitPaneWidget*, std::map<QString, std::set<SidebarWidgetType*>>> m_priorWidgets; std::map<SidebarWidgetType*, SidebarFloatingWidgetState> m_savedFloatingWidgetState; SidebarStackedWidget& stackedWidgetForType(SidebarWidgetType* type); std::vector<SidebarWidgetAndHeader*> widgetsForContext() const; + std::vector<SidebarContentClassifier*> contentClassifiersForContext() const; void insertWidgetIntoContainer(SidebarWidgetType* type, QStackedWidget* widget); void updateContentsVisibility(); private Q_SLOTS: void floatingWidgetClosed(SidebarWidgetType* type); + void childContentClassificationChanged(); public: SidebarWidgetContainer(Sidebar* sidebar, SidebarContainerLocation location); @@ -134,8 +138,11 @@ public: SidebarWidget* widgetWithTitle(SidebarWidgetType* type, const QString& title) const; bool hasWidgetWithTitle(SidebarWidgetType* type, const QString& title) const; bool activateWidgetWithTitle(SidebarWidgetType* type, const QString& title) const; - bool hasContent(SidebarWidgetType* type) const; - bool shouldHide(SidebarWidgetType* type) const; + SidebarContentClassification contentClassification(SidebarWidgetType* type); + bool hasContent(SidebarWidgetType* type); + bool shouldHide(SidebarWidgetType* type); + + SidebarContentClassifier* contentClassifier(SidebarWidgetType* type); virtual QSize sizeHint() const override; @@ -162,4 +169,5 @@ public: Q_SIGNALS: void showContents(); void hideContents(); + void contentClassificationChanged(); }; |
