From 758258d7764744c7ed787617818d3265c077021b Mon Sep 17 00:00:00 2001 From: emeric Date: Wed, 2 Sep 2015 20:39:48 +0200 Subject: [PATCH] [UI] Make scroll bars depends on WT version --- src/ui/audio/desktop/PlayQueue.cpp | 3 ++- src/ui/audio/desktop/TableFilter.cpp | 6 ++++++ src/ui/audio/desktop/TrackView.cpp | 2 ++ 3 files changed, 10 insertions(+), 1 deletion(-) diff --git a/src/ui/audio/desktop/PlayQueue.cpp b/src/ui/audio/desktop/PlayQueue.cpp index dc38bd31..dff36f79 100644 --- a/src/ui/audio/desktop/PlayQueue.cpp +++ b/src/ui/audio/desktop/PlayQueue.cpp @@ -291,9 +291,10 @@ _trackSelector(new TrackSelector()) this->setColumnWidth(COLUMN_ID_NAME, 240); this->setLayoutSizeAware(true); +#if WT_VERSION >= 0X03030400 this->setOverflow(Wt::WContainerWidget::OverflowHidden, Wt::Horizontal); this->setOverflow(Wt::WContainerWidget::OverflowScroll, Wt::Vertical); - +#endif this->setColumnHidden(COLUMN_ID_TRACK_ID, true); _itemDelegate = new PlayQueueItemDelegate(); diff --git a/src/ui/audio/desktop/TableFilter.cpp b/src/ui/audio/desktop/TableFilter.cpp index 7e11ae93..1c59f1f2 100644 --- a/src/ui/audio/desktop/TableFilter.cpp +++ b/src/ui/audio/desktop/TableFilter.cpp @@ -48,8 +48,10 @@ TableFilterGenre::TableFilterGenre(Wt::WContainerWidget* parent) this->selectionChanged().connect(this, &TableFilterGenre::emitUpdate); +#if WT_VERSION >= 0X03030400 this->setOverflow(Wt::WContainerWidget::OverflowHidden, Wt::Horizontal); this->setOverflow(Wt::WContainerWidget::OverflowScroll, Wt::Vertical); +#endif this->setLayoutSizeAware(true); @@ -123,8 +125,10 @@ TableFilterArtist::TableFilterArtist(Wt::WContainerWidget* parent) this->selectionChanged().connect(this, &TableFilterArtist::emitUpdate); +#if WT_VERSION >= 0X03030400 this->setOverflow(Wt::WContainerWidget::OverflowHidden, Wt::Horizontal); this->setOverflow(Wt::WContainerWidget::OverflowScroll, Wt::Vertical); +#endif this->setLayoutSizeAware(true); @@ -204,8 +208,10 @@ TableFilterRelease::TableFilterRelease(Wt::WContainerWidget* parent) this->selectionChanged().connect(this, &TableFilterRelease::emitUpdate); +#if WT_VERSION >= 0X03030400 this->setOverflow(Wt::WContainerWidget::OverflowHidden, Wt::Horizontal); this->setOverflow(Wt::WContainerWidget::OverflowScroll, Wt::Vertical); +#endif this->setLayoutSizeAware(true); diff --git a/src/ui/audio/desktop/TrackView.cpp b/src/ui/audio/desktop/TrackView.cpp index 26f89f04..f4bf5df4 100644 --- a/src/ui/audio/desktop/TrackView.cpp +++ b/src/ui/audio/desktop/TrackView.cpp @@ -67,7 +67,9 @@ TrackView::TrackView(Wt::WContainerWidget* parent) this->setColumnWidth(6, 70); // Date this->setColumnWidth(7, 70); // Original Date this->setColumnWidth(8, 180); // Genres +#if WT_VERSION >= 0X03030400 this->setOverflow(Wt::WContainerWidget::OverflowScroll, Wt::Vertical); +#endif // Duration display {