diff --git a/src/libtomahawk/CMakeLists.txt b/src/libtomahawk/CMakeLists.txt index 6f4741457..bb2c59693 100644 --- a/src/libtomahawk/CMakeLists.txt +++ b/src/libtomahawk/CMakeLists.txt @@ -80,6 +80,7 @@ set( libGuiSources playlist/dynamic/echonest/EchonestControl.cpp playlist/dynamic/echonest/EchonestSteerer.cpp playlist/dynamic/widgets/DynamicWidget.cpp + playlist/dynamic/widgets/DynamicQmlWidget.cpp playlist/dynamic/widgets/DynamicControlWrapper.cpp playlist/dynamic/widgets/DynamicControlList.cpp playlist/dynamic/widgets/ReadOrWriteWidget.cpp diff --git a/src/libtomahawk/playlist/dynamic/widgets/DynamicQmlWidget.cpp b/src/libtomahawk/playlist/dynamic/widgets/DynamicQmlWidget.cpp new file mode 100644 index 000000000..6cff5c878 --- /dev/null +++ b/src/libtomahawk/playlist/dynamic/widgets/DynamicQmlWidget.cpp @@ -0,0 +1,24 @@ +#include "DynamicQmlWidget.h" +#include "utils/TomahawkUtilsGui.h" + +#include + +namespace Tomahawk +{ + +DynamicQmlWidget::DynamicQmlWidget( const dynplaylist_ptr& playlist, QWidget* parent) + : QDeclarativeView( parent ) +{ + setResizeMode(QDeclarativeView::SizeRootObjectToView); + + setSource(QUrl("qrc" RESPATH "qml/ArtistInfoScene.qml")); + + +} + +DynamicQmlWidget::~DynamicQmlWidget() +{ + +} + +} diff --git a/src/libtomahawk/playlist/dynamic/widgets/DynamicQmlWidget.h b/src/libtomahawk/playlist/dynamic/widgets/DynamicQmlWidget.h new file mode 100644 index 000000000..662da5812 --- /dev/null +++ b/src/libtomahawk/playlist/dynamic/widgets/DynamicQmlWidget.h @@ -0,0 +1,41 @@ +/* === This file is part of Tomahawk Player - === + * + * Copyright 2012, Michael Zanetti + * + * Tomahawk is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 3 of the License, or + * (at your option) any later version. + * + * Tomahawk is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with Tomahawk. If not, see . + */ + +#ifndef DYNAMIC_QML_WIDGET_H +#define DYNAMIC_QML_WIDGET_H + +#include "ViewPage.h" +#include "Typedefs.h" + +#include + +namespace Tomahawk +{ + + +class DynamicQmlWidget : public QDeclarativeView, public Tomahawk::ViewPage +{ +Q_OBJECT +public: + explicit DynamicQmlWidget( const dynplaylist_ptr& playlist, QWidget* parent = 0); + virtual ~DynamicQmlWidget(); + +}; + +} +#endif // DYNAMIC_QML_WIDGET_H