mirror of
https://github.com/tomahawk-player/tomahawk.git
synced 2025-08-01 20:00:13 +02:00
Replace the comboboxes in the whatshot widget with the breadcrumb. No data model yet, that is coming soon.
This commit is contained in:
@@ -30,6 +30,7 @@
|
|||||||
#include "playlist/playlistmodel.h"
|
#include "playlist/playlistmodel.h"
|
||||||
#include "playlist/treeproxymodel.h"
|
#include "playlist/treeproxymodel.h"
|
||||||
#include "widgets/overlaywidget.h"
|
#include "widgets/overlaywidget.h"
|
||||||
|
#include "widgets/siblingcrumbbutton.h"
|
||||||
#include "utils/tomahawkutils.h"
|
#include "utils/tomahawkutils.h"
|
||||||
#include "utils/logger.h"
|
#include "utils/logger.h"
|
||||||
#include <dynamic/GeneratorInterface.h>
|
#include <dynamic/GeneratorInterface.h>
|
||||||
@@ -51,8 +52,14 @@ WhatsHotWidget::WhatsHotWidget( QWidget* parent )
|
|||||||
TomahawkUtils::unmarginLayout( layout() );
|
TomahawkUtils::unmarginLayout( layout() );
|
||||||
TomahawkUtils::unmarginLayout( ui->verticalLayout->layout() );
|
TomahawkUtils::unmarginLayout( ui->verticalLayout->layout() );
|
||||||
TomahawkUtils::unmarginLayout( ui->verticalLayout_2->layout() );
|
TomahawkUtils::unmarginLayout( ui->verticalLayout_2->layout() );
|
||||||
TomahawkUtils::unmarginLayout( ui->horizontalLayout->layout() );
|
|
||||||
TomahawkUtils::unmarginLayout( ui->horizontalLayout_3->layout() );
|
SiblingCrumbButtonFactory * crumbFactory = new SiblingCrumbButtonFactory;
|
||||||
|
|
||||||
|
ui->breadCrumbLeft->setButtonFactory(crumbFactory);
|
||||||
|
ui->breadCrumbLeft->setRootIcon(QIcon( RESPATH "images/charts.png" ));
|
||||||
|
|
||||||
|
ui->breadCrumbRight->setButtonFactory(crumbFactory);
|
||||||
|
ui->breadCrumbRight->setRootIcon(QIcon( RESPATH "images/charts.png" ));
|
||||||
|
|
||||||
|
|
||||||
m_tracksModel = new PlaylistModel( ui->tracksView );
|
m_tracksModel = new PlaylistModel( ui->tracksView );
|
||||||
|
@@ -14,67 +14,7 @@
|
|||||||
<item>
|
<item>
|
||||||
<layout class="QVBoxLayout" name="verticalLayout">
|
<layout class="QVBoxLayout" name="verticalLayout">
|
||||||
<item>
|
<item>
|
||||||
<widget class="HeaderWidget" name="bg1">
|
<widget class="HeaderBreadCrumb" name="breadCrumbLeft">
|
||||||
<layout class="QHBoxLayout" name="horizontalLayout">
|
|
||||||
<item>
|
|
||||||
<widget class="ComboBox" name="sourceComobLeft">
|
|
||||||
<property name="sizeAdjustPolicy">
|
|
||||||
<enum>QComboBox::AdjustToContentsOnFirstShow</enum>
|
|
||||||
</property>
|
|
||||||
<property name="iconSize">
|
|
||||||
<size>
|
|
||||||
<width>0</width>
|
|
||||||
<height>0</height>
|
|
||||||
</size>
|
|
||||||
</property>
|
|
||||||
<item>
|
|
||||||
<property name="text">
|
|
||||||
<string>Billboard</string>
|
|
||||||
</property>
|
|
||||||
</item>
|
|
||||||
<item>
|
|
||||||
<property name="text">
|
|
||||||
<string>Last.fm</string>
|
|
||||||
</property>
|
|
||||||
</item>
|
|
||||||
<item>
|
|
||||||
<property name="text">
|
|
||||||
<string>iTunes</string>
|
|
||||||
</property>
|
|
||||||
</item>
|
|
||||||
<item>
|
|
||||||
<property name="text">
|
|
||||||
<string/>
|
|
||||||
</property>
|
|
||||||
</item>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item>
|
|
||||||
<spacer name="horizontalSpacer">
|
|
||||||
<property name="orientation">
|
|
||||||
<enum>Qt::Horizontal</enum>
|
|
||||||
</property>
|
|
||||||
<property name="sizeHint" stdset="0">
|
|
||||||
<size>
|
|
||||||
<width>40</width>
|
|
||||||
<height>5</height>
|
|
||||||
</size>
|
|
||||||
</property>
|
|
||||||
</spacer>
|
|
||||||
</item>
|
|
||||||
<item>
|
|
||||||
<widget class="ComboBox" name="typeComboLeft">
|
|
||||||
<property name="sizeAdjustPolicy">
|
|
||||||
<enum>QComboBox::AdjustToContentsOnFirstShow</enum>
|
|
||||||
</property>
|
|
||||||
<item>
|
|
||||||
<property name="text">
|
|
||||||
<string>Top 100 Tracks</string>
|
|
||||||
</property>
|
|
||||||
</item>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
</layout>
|
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
<item>
|
<item>
|
||||||
@@ -92,67 +32,7 @@
|
|||||||
<item>
|
<item>
|
||||||
<layout class="QVBoxLayout" name="verticalLayout_2">
|
<layout class="QVBoxLayout" name="verticalLayout_2">
|
||||||
<item>
|
<item>
|
||||||
<widget class="HeaderWidget" name="bg2" native="true">
|
<widget class="HeaderBreadCrumb" name="breadCrumbRight">
|
||||||
<layout class="QHBoxLayout" name="horizontalLayout_3">
|
|
||||||
<item>
|
|
||||||
<widget class="ComboBox" name="sourceComboRight">
|
|
||||||
<property name="sizeAdjustPolicy">
|
|
||||||
<enum>QComboBox::AdjustToContentsOnFirstShow</enum>
|
|
||||||
</property>
|
|
||||||
<property name="iconSize">
|
|
||||||
<size>
|
|
||||||
<width>0</width>
|
|
||||||
<height>0</height>
|
|
||||||
</size>
|
|
||||||
</property>
|
|
||||||
<item>
|
|
||||||
<property name="text">
|
|
||||||
<string>Billboard</string>
|
|
||||||
</property>
|
|
||||||
</item>
|
|
||||||
<item>
|
|
||||||
<property name="text">
|
|
||||||
<string>Last.fm</string>
|
|
||||||
</property>
|
|
||||||
</item>
|
|
||||||
<item>
|
|
||||||
<property name="text">
|
|
||||||
<string>iTunes</string>
|
|
||||||
</property>
|
|
||||||
</item>
|
|
||||||
<item>
|
|
||||||
<property name="text">
|
|
||||||
<string/>
|
|
||||||
</property>
|
|
||||||
</item>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item>
|
|
||||||
<spacer name="horizontalSpacer_3">
|
|
||||||
<property name="orientation">
|
|
||||||
<enum>Qt::Horizontal</enum>
|
|
||||||
</property>
|
|
||||||
<property name="sizeHint" stdset="0">
|
|
||||||
<size>
|
|
||||||
<width>40</width>
|
|
||||||
<height>5</height>
|
|
||||||
</size>
|
|
||||||
</property>
|
|
||||||
</spacer>
|
|
||||||
</item>
|
|
||||||
<item>
|
|
||||||
<widget class="ComboBox" name="typeComboRight">
|
|
||||||
<property name="sizeAdjustPolicy">
|
|
||||||
<enum>QComboBox::AdjustToContentsOnFirstShow</enum>
|
|
||||||
</property>
|
|
||||||
<item>
|
|
||||||
<property name="text">
|
|
||||||
<string>Top 100 Tracks</string>
|
|
||||||
</property>
|
|
||||||
</item>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
</layout>
|
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
<item>
|
<item>
|
||||||
@@ -181,14 +61,9 @@
|
|||||||
<header location="global">artistview.h</header>
|
<header location="global">artistview.h</header>
|
||||||
</customwidget>
|
</customwidget>
|
||||||
<customwidget>
|
<customwidget>
|
||||||
<class>ComboBox</class>
|
<class>HeaderBreadCrumb</class>
|
||||||
<extends>QComboBox</extends>
|
|
||||||
<header location="global">widgets/combobox.h</header>
|
|
||||||
</customwidget>
|
|
||||||
<customwidget>
|
|
||||||
<class>HeaderWidget</class>
|
|
||||||
<extends>QWidget</extends>
|
<extends>QWidget</extends>
|
||||||
<header location="global">widgets/HeaderWidget.h</header>
|
<header location="global">widgets/headerbreadcrumb.h</header>
|
||||||
</customwidget>
|
</customwidget>
|
||||||
</customwidgets>
|
</customwidgets>
|
||||||
<resources/>
|
<resources/>
|
||||||
|
Reference in New Issue
Block a user