Qt-Advanced-Docking-System/sip/FloatingDockContainer.sip
Hugo Slepicka 4d2de7bb2a
FIX: Update Python bindings for 3.4.2 and current master. (#193)
* FIX: Update python bindings for 3.4.2.

* FIX: Try to fix windows build.

* FIX: Add const at nativeEvent argument.

* FIX: Adjusting sip bindings for changes from 8b6df4aaa5.
2020-06-04 23:55:02 +02:00

80 lines
2.1 KiB
Plaintext

// NOTE: there is a separate sip/linux/FloatingDockContainer.sip as the base
// class for CFloatingDockContainer changes for Linux.
%Import QtWidgets/QtWidgetsmod.sip
%If (Qt_5_0_0 -)
%If (WS_X11)
typedef QDockWidget tFloatingWidgetBase;
%End
%If (!WS_X11)
typedef QWidget tFloatingWidgetBase;
%End
namespace ads
{
class IFloatingWidget
{
%TypeHeaderCode
#include <FloatingDockContainer.h>
%End
public:
virtual void startFloating(const QPoint& DragStartMousePos, const QSize& Size,
ads::eDragState DragState, QWidget* MouseEventHandler) = 0;
virtual void moveFloating() = 0;
virtual void finishDragging() = 0;
virtual ~IFloatingWidget();
};
class CFloatingDockContainer : tFloatingWidgetBase, ads::IFloatingWidget
{
%TypeHeaderCode
#include <FloatingDockContainer.h>
%End
protected:
virtual void startFloating(const QPoint& DragStartMousePos, const QSize& Size,
ads::eDragState DragState, QWidget* MouseEventHandler);
void startDragging(const QPoint& DragStartMousePos, const QSize& Size,
QWidget* MouseEventHandler);
virtual void finishDragging();
void initFloatingGeometry(const QPoint& DragStartMousePos, const QSize& Size);
void moveFloating();
bool restoreState(ads::CDockingStateReader& Stream, bool Testing);
void updateWindowTitle();
protected:
virtual void changeEvent(QEvent *event);
virtual void moveEvent(QMoveEvent *event);
virtual bool event(QEvent *e);
virtual void closeEvent(QCloseEvent *event);
virtual void hideEvent(QHideEvent *event);
virtual void showEvent(QShowEvent *event);
%If (WS_WIN)
virtual bool nativeEvent(const QByteArray &eventType, void *message, long *result);
%End
public:
CFloatingDockContainer(ads::CDockManager* DockManager /TransferThis/);
CFloatingDockContainer(ads::CDockAreaWidget* DockArea /TransferThis/);
CFloatingDockContainer(ads::CDockWidget* DockWidget /TransferThis/);
virtual ~CFloatingDockContainer();
ads::CDockContainerWidget* dockContainer() const;
bool isClosable() const;
bool hasTopLevelDockWidget() const;
ads::CDockWidget* topLevelDockWidget() const;
QList<ads::CDockWidget*> dockWidgets() const;
};
};
%End