|
|
@ -20,11 +20,16 @@ UBLeftPalette::UBLeftPalette(QWidget *parent, const char *name):UBDockPalette(pa |
|
|
|
setObjectName(name); |
|
|
|
setObjectName(name); |
|
|
|
setOrientation(eUBDockOrientation_Left); |
|
|
|
setOrientation(eUBDockOrientation_Left); |
|
|
|
mLastWidth = 300; |
|
|
|
mLastWidth = 300; |
|
|
|
setMaximumWidth(300); |
|
|
|
mCollapseWidth = 180; |
|
|
|
resize(UBSettings::settings()->navigPaletteWidth->get().toInt(), height()); |
|
|
|
/*
|
|
|
|
|
|
|
|
resize(UBSettings::settings()->libPaletteWidth->get().toInt(), parentWidget()->height()); |
|
|
|
|
|
|
|
mpLayout->setContentsMargins(2*border() + customMargin(), customMargin(), customMargin(), customMargin()); |
|
|
|
|
|
|
|
*/ |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
resize(UBSettings::settings()->navigPaletteWidth->get().toInt(), parentWidget()->height()); |
|
|
|
mpLayout->setContentsMargins(customMargin(), customMargin(), 2*border() + customMargin(), customMargin()); |
|
|
|
mpLayout->setContentsMargins(customMargin(), customMargin(), 2*border() + customMargin(), customMargin()); |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
// Add the widgets here
|
|
|
|
mpPageNavigator = new UBPageNavigationWidget(this); |
|
|
|
mpPageNavigator = new UBPageNavigationWidget(this); |
|
|
|
addTabWidget(mpPageNavigator); |
|
|
|
addTabWidget(mpPageNavigator); |
|
|
|
} |
|
|
|
} |
|
|
@ -38,6 +43,21 @@ UBLeftPalette::~UBLeftPalette() |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
void UBLeftPalette::updateMaxWidth() |
|
|
|
|
|
|
|
{ |
|
|
|
|
|
|
|
setMaximumWidth(300); |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
void UBLeftPalette::resizeEvent(QResizeEvent *event) |
|
|
|
|
|
|
|
{ |
|
|
|
|
|
|
|
UBDockPalette::resizeEvent(event); |
|
|
|
|
|
|
|
if(NULL != mpPageNavigator) |
|
|
|
|
|
|
|
{ |
|
|
|
|
|
|
|
mpPageNavigator->setMinimumHeight(height() - 2*border()); |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
UBSettings::settings()->navigPaletteWidth->set(width()); |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
UBPageNavigationWidget* UBLeftPalette::pageNavigator() |
|
|
|
UBPageNavigationWidget* UBLeftPalette::pageNavigator() |
|
|
|
{ |
|
|
|
{ |
|
|
|
return mpPageNavigator; |
|
|
|
return mpPageNavigator; |
|
|
|