2018-06-03 21:50:37 +02:00
|
|
|
diff --git a/src/playlist/playlisttab.cpp b/src/playlist/playlisttab.cpp
|
|
|
|
index 01f1290..6ae454b 100644
|
|
|
|
--- a/src/playlist/playlisttab.cpp
|
|
|
|
+++ b/src/playlist/playlisttab.cpp
|
|
|
|
@@ -25,6 +25,7 @@
|
2016-08-20 23:37:11 +02:00
|
|
|
#include <QAction>
|
2010-07-19 21:00:22 +02:00
|
|
|
#include <QBoxLayout>
|
2016-08-20 23:37:11 +02:00
|
|
|
#include <QFileDialog>
|
2010-07-19 21:00:22 +02:00
|
|
|
+#include <QToolBar>
|
|
|
|
#include <QKeyEvent>
|
|
|
|
#include <QListView>
|
2016-08-20 23:37:11 +02:00
|
|
|
#include <QMenu>
|
2018-06-03 21:50:37 +02:00
|
|
|
@@ -446,33 +447,35 @@ PlaylistTab::PlaylistTab(QMenu *menu, KActionCollection *collection, MediaWidget
|
2010-07-19 21:00:22 +02:00
|
|
|
QBoxLayout *sideLayout = new QVBoxLayout(widget);
|
|
|
|
sideLayout->setMargin(0);
|
|
|
|
|
|
|
|
+ QToolBar *ToolBarLayout= new QToolBar();
|
|
|
|
QBoxLayout *boxLayout = new QHBoxLayout();
|
|
|
|
|
|
|
|
QToolButton *toolButton = new QToolButton(widget);
|
|
|
|
toolButton->setDefaultAction(newAction);
|
|
|
|
toolButton->setToolButtonStyle(Qt::ToolButtonTextBesideIcon);
|
|
|
|
- boxLayout->addWidget(toolButton);
|
|
|
|
+ ToolBarLayout->addWidget(toolButton);
|
|
|
|
|
|
|
|
toolButton = new QToolButton(widget);
|
|
|
|
toolButton->setDefaultAction(renameAction);
|
|
|
|
toolButton->setToolButtonStyle(Qt::ToolButtonTextBesideIcon);
|
|
|
|
- boxLayout->addWidget(toolButton);
|
|
|
|
+ ToolBarLayout->addWidget(toolButton);
|
|
|
|
|
|
|
|
toolButton = new QToolButton(widget);
|
|
|
|
toolButton->setDefaultAction(removePlaylistAction);
|
|
|
|
toolButton->setToolButtonStyle(Qt::ToolButtonTextBesideIcon);
|
|
|
|
- boxLayout->addWidget(toolButton);
|
|
|
|
+ ToolBarLayout->addWidget(toolButton);
|
|
|
|
|
|
|
|
toolButton = new QToolButton(widget);
|
|
|
|
toolButton->setDefaultAction(savePlaylistAction);
|
|
|
|
toolButton->setToolButtonStyle(Qt::ToolButtonTextBesideIcon);
|
|
|
|
- boxLayout->addWidget(toolButton);
|
|
|
|
+ ToolBarLayout->addWidget(toolButton);
|
|
|
|
|
|
|
|
toolButton = new QToolButton(widget);
|
|
|
|
toolButton->setDefaultAction(savePlaylistAsAction);
|
|
|
|
toolButton->setToolButtonStyle(Qt::ToolButtonTextBesideIcon);
|
|
|
|
- boxLayout->addWidget(toolButton);
|
|
|
|
+ ToolBarLayout->addWidget(toolButton);
|
|
|
|
|
|
|
|
+ boxLayout->addWidget(ToolBarLayout);
|
|
|
|
boxLayout->addStretch();
|
|
|
|
sideLayout->addLayout(boxLayout);
|
|
|
|
|
2018-06-03 21:50:37 +02:00
|
|
|
@@ -499,28 +502,30 @@ PlaylistTab::PlaylistTab(QMenu *menu, KActionCollection *collection, MediaWidget
|
2010-07-19 21:00:22 +02:00
|
|
|
sideLayout = new QVBoxLayout(widget);
|
|
|
|
sideLayout->setMargin(0);
|
|
|
|
|
|
|
|
+ ToolBarLayout= new QToolBar();
|
|
|
|
boxLayout = new QHBoxLayout();
|
|
|
|
|
|
|
|
toolButton = new QToolButton(widget);
|
|
|
|
toolButton->setDefaultAction(repeatAction);
|
|
|
|
toolButton->setToolButtonStyle(Qt::ToolButtonTextBesideIcon);
|
|
|
|
- boxLayout->addWidget(toolButton);
|
|
|
|
+ ToolBarLayout->addWidget(toolButton);
|
|
|
|
|
|
|
|
toolButton = new QToolButton(widget);
|
|
|
|
toolButton->setDefaultAction(randomAction);
|
|
|
|
toolButton->setToolButtonStyle(Qt::ToolButtonTextBesideIcon);
|
|
|
|
- boxLayout->addWidget(toolButton);
|
|
|
|
+ ToolBarLayout->addWidget(toolButton);
|
|
|
|
|
|
|
|
toolButton = new QToolButton(widget);
|
|
|
|
toolButton->setDefaultAction(removeTrackAction);
|
|
|
|
toolButton->setToolButtonStyle(Qt::ToolButtonTextBesideIcon);
|
|
|
|
- boxLayout->addWidget(toolButton);
|
|
|
|
+ ToolBarLayout->addWidget(toolButton);
|
|
|
|
|
|
|
|
toolButton = new QToolButton(widget);
|
|
|
|
toolButton->setDefaultAction(clearAction);
|
|
|
|
toolButton->setToolButtonStyle(Qt::ToolButtonTextBesideIcon);
|
|
|
|
- boxLayout->addWidget(toolButton);
|
|
|
|
+ ToolBarLayout->addWidget(toolButton);
|
|
|
|
|
|
|
|
+ boxLayout->addWidget(ToolBarLayout);
|
|
|
|
boxLayout->addStretch();
|
|
|
|
sideLayout->addLayout(boxLayout);
|
|
|
|
|
2018-06-03 21:50:37 +02:00
|
|
|
@@ -615,6 +620,7 @@ void PlaylistTab::createFileWidget()
|
2010-07-19 21:00:22 +02:00
|
|
|
fileWidget->setFilter(MediaWidget::extensionFilter());
|
|
|
|
fileWidget->setMode(KFile::Files | KFile::ExistingOnly);
|
|
|
|
fileWidgetSplitter->setStretchFactor(1, 1);
|
|
|
|
+ fileWidget->setMinimumWidth(40);
|
|
|
|
|
2016-08-20 23:37:11 +02:00
|
|
|
// KFileWidget creates a QUrlComboBox without layout (!), which steals the focus:
|
2010-07-19 21:00:22 +02:00
|
|
|
// kDebug() << QApplication::focusWidget();
|