mirror of
https://github.com/githubuser0xFFFF/Qt-Advanced-Docking-System.git
synced 2024-11-15 13:15:43 +08:00
Changed type of sideTabBarArea properties to int to fix non working Linux stylesheet selectors
This commit is contained in:
parent
6adce7337b
commit
f4bfa0f3c5
@ -53,7 +53,7 @@ class CDockingStateReader;
|
||||
class ADS_EXPORT CAutoHideDockContainer : public QFrame
|
||||
{
|
||||
Q_OBJECT
|
||||
Q_PROPERTY(ads::SideBarLocation sideTabBarArea READ sideTabBarArea)
|
||||
Q_PROPERTY(int sideTabBarArea READ sideTabBarArea)
|
||||
private:
|
||||
AutoHideDockContainerPrivate* d; ///< private data (pimpl)
|
||||
friend struct AutoHideDockContainerPrivate;
|
||||
|
@ -47,7 +47,7 @@ struct DockWidgetSideTabPrivate
|
||||
{
|
||||
CDockWidgetSideTab* _this;
|
||||
CDockWidget* DockWidget;
|
||||
CSideTabBar* SideTabBar;
|
||||
CSideTabBar* SideTabBar = nullptr;
|
||||
Qt::Orientation Orientation{Qt::Vertical};
|
||||
|
||||
/**
|
||||
@ -114,10 +114,10 @@ void CDockWidgetSideTab::updateStyle()
|
||||
//============================================================================
|
||||
SideBarLocation CDockWidgetSideTab::sideTabBarArea() const
|
||||
{
|
||||
auto dockAreaWidget = d->DockWidget->dockAreaWidget();
|
||||
if (dockAreaWidget && dockAreaWidget->isAutoHide())
|
||||
if (d->SideTabBar)
|
||||
{
|
||||
return dockAreaWidget->autoHideDockContainer()->sideTabBarArea();
|
||||
qDebug() << "CDockWidgetSideTab::sideTabBarArea() " << d->SideTabBar->sideTabBarArea();
|
||||
return d->SideTabBar->sideTabBarArea();
|
||||
}
|
||||
|
||||
return Left;
|
||||
|
@ -50,7 +50,7 @@ class ADS_EXPORT CDockWidgetSideTab : public CPushButton
|
||||
{
|
||||
Q_OBJECT
|
||||
|
||||
Q_PROPERTY(ads::SideBarLocation sideTabBarArea READ sideTabBarArea)
|
||||
Q_PROPERTY(int sideTabBarArea READ sideTabBarArea)
|
||||
Q_PROPERTY(Qt::Orientation orientation READ orientation)
|
||||
Q_PROPERTY(bool activeTab READ isActiveTab)
|
||||
|
||||
|
@ -128,10 +128,10 @@ CSideTabBar::~CSideTabBar()
|
||||
//============================================================================
|
||||
void CSideTabBar::insertSideTab(int Index, CDockWidgetSideTab* SideTab)
|
||||
{
|
||||
SideTab->updateOrientationForArea(d->SideTabArea);
|
||||
SideTab->installEventFilter(this);
|
||||
d->TabsLayout->insertWidget(Index, SideTab);
|
||||
SideTab->setSideTabBar(this);
|
||||
SideTab->updateOrientationForArea(d->SideTabArea);
|
||||
d->TabsLayout->insertWidget(Index, SideTab);
|
||||
show();
|
||||
}
|
||||
|
||||
|
@ -50,7 +50,7 @@ class CAutoHideDockContainer;
|
||||
class ADS_EXPORT CSideTabBar : public QFrame
|
||||
{
|
||||
Q_OBJECT
|
||||
Q_PROPERTY(ads::SideBarLocation sideTabBarArea READ sideTabBarArea)
|
||||
Q_PROPERTY(int sideTabBarArea READ sideTabBarArea)
|
||||
Q_PROPERTY(Qt::Orientation orientation READ orientation)
|
||||
|
||||
private:
|
||||
|
Loading…
Reference in New Issue
Block a user