API Documentation
Loading...
Searching...
No Matches
PopupManager.h
Go to the documentation of this file.
1#pragma once
2#include "DLLInfo.h"
3#include <NDEVR/PopupInfo.h>
4#include <NDEVR/SoftwareService.h>
5#include <NDEVR/QCustomDockWidget.h>
6#include <QWidget>
7#include <QPointer>
8namespace NDEVR
9{
10 class ContainerWidget;
11 class PopupWidget;
12 /**--------------------------------------------------------------------------------------------------
13 \brief Responsible for displaying widgets that want to be in their own window.
14 **/
15 class NDEVR_WIDGETS_API PopupManager : public QObject, public SoftwareService
16 {
17 public:
20 virtual void hideWidget(QWidget* widget, const PopupInfo& popup_origin);
21 virtual bool showWidget(QWidget* widget, PopupInfo popup_origin, PopupInfo popup_end);
22
23 virtual DropArea defaultDropArea(const QCustomDockWidget*) const { return DropArea::e_drop_popup; };
24 virtual SectionWidget* defaultDropReference(const QCustomDockWidget*) const { return nullptr; };
25 virtual RibbonArea defaultRibbonArea(const QCustomDockWidget*) { return RibbonArea::e_top; };
26 /**--------------------------------------------------------------------------------------------------
27 \brief Returns the primary container widget for adding new docks
28 \return The primary container widget, as defined by the application
29 **/
30 virtual ContainerWidgetBase* container() const { return nullptr; };
31 protected:
32 PopupWidget* m_popup_widget = nullptr;
34 };
35}
#define NDEVR_WIDGETS_API
Definition DLLInfo.h:59
The root class that manages a series of SectionContent that can share the same space or lay out in va...
Definition ContainerWidget.h:66
A hash-based key-value store, useful for quick associative lookups. Key features include:
Definition Dictionary.h:61
Responsible for displaying widgets that want to be in their own window.
Definition PopupManager.h:16
virtual void hideWidget(QWidget *widget, const PopupInfo &popup_origin)
virtual SectionWidget * defaultDropReference(const QCustomDockWidget *) const
Definition PopupManager.h:24
virtual bool showWidget(QWidget *widget, PopupInfo popup_origin, PopupInfo popup_end)
Dictionary< QObject *, QPointer< QCustomDockWidget > > m_docks
Definition PopupManager.h:33
virtual ContainerWidgetBase * container() const
Returns the primary container widget for adding new docks.
Definition PopupManager.h:30
virtual DropArea defaultDropArea(const QCustomDockWidget *) const
Definition PopupManager.h:23
virtual RibbonArea defaultRibbonArea(const QCustomDockWidget *)
Definition PopupManager.h:25
Provides a wrapper for a widget that can be docked inside a Container or floated as a top-level windo...
Definition QCustomDockWidget.h:61
SectionWidget manages multiple instances of SectionContent. It displays a title TAB,...
Definition SectionWidget.h:55
Software Services provide an interface for adding to or changing the software behavior via functional...
Definition SoftwareService.h:9
Definition ACIColor.h:37
RibbonArea
Requests a ribbon or tab area to be in a certain location and orientation relative to another widget.
Definition RibbonArea.h:71
DropArea
relates where a widget should be dropped relative to another.
Definition RibbonArea.h:46
Class which is used to pass arguments and requests for creating a popup dialog or widget....
Definition PopupInfo.h:15