DockFocusController.h
Go to the documentation of this file.
1 #ifndef DockFocusControllerH
2 #define DockFocusControllerH
3 //============================================================================
8 //============================================================================
9 
10 //============================================================================
11 // INCLUDES
12 //============================================================================
13 #include <QObject>
14 #include "ads_globals.h"
15 #include "DockManager.h"
16 
17 namespace ads
18 {
19 struct DockFocusControllerPrivate;
20 class CDockManager;
21 class CFloatingDockContainer;
22 
26 class ADS_EXPORT CDockFocusController : public QObject
27 {
28  Q_OBJECT
29 private:
32 
33 private slots:
34  void onApplicationFocusChanged(QWidget *old, QWidget *now);
35  void onFocusedDockAreaViewToggled(bool Open);
36  void onStateRestored();
37  void onDockWidgetVisibilityChanged(bool Visible);
38 
39 public:
40  using Super = QObject;
44  CDockFocusController(CDockManager* DockManager);
45 
49  virtual ~CDockFocusController();
50 
55  template <class QWidgetPtr>
56  static void setWidgetFocus(QWidgetPtr widget)
57  {
59  {
60  return;
61  }
62 
63  widget->setFocus(Qt::OtherFocusReason);
64  }
65 
70  void notifyWidgetOrAreaRelocation(QWidget* RelocatedWidget);
71 
78  void notifyFloatingWidgetDrop(CFloatingDockContainer* FloatingWidget);
79 
84  CDockWidget* focusedDockWidget() const;
85 
86 public slots:
90  void setDockWidgetFocused(CDockWidget* focusedNow);
91 }; // class DockFocusController
92 }
93  // namespace ads
94 //-----------------------------------------------------------------------------
95 #endif // DockFocusControllerH
96 
static bool testConfigFlag(eConfigFlag Flag)
static void setWidgetFocus(QWidgetPtr widget)
enables styling of focused dock widget tabs or floating widget titlebar
Definition: DockManager.h:182
Declaration of.
DockFocusControllerPrivate * d
private data (pimpl)
#define ADS_EXPORT
Definition: ads_globals.h:50
Declaration of CDockManager class.


plotjuggler
Author(s): Davide Faconti
autogenerated on Sun Dec 6 2020 03:47:34