From 77d96ef48977394a6be0386cb1da835ab5747a10 Mon Sep 17 00:00:00 2001 From: Kevin Krammer Date: Mon, 21 Jan 2013 20:40:51 +0100 Subject: [PATCH] Ported slider --- lib/declarativeslider.cpp | 29 ----------------------------- lib/declarativeslider_p.h | 36 ------------------------------------ lib/declarativewidgetsdocument.cpp | 3 +-- lib/lib.pro | 2 -- 4 files changed, 1 insertions(+), 69 deletions(-) delete mode 100644 lib/declarativeslider.cpp delete mode 100644 lib/declarativeslider_p.h diff --git a/lib/declarativeslider.cpp b/lib/declarativeslider.cpp deleted file mode 100644 index d22e39e..0000000 --- a/lib/declarativeslider.cpp +++ /dev/null @@ -1,29 +0,0 @@ -/* - Copyright (C) 2012 Klarälvdalens Datakonsult AB, a KDAB Group company, info@kdab.com - Author: Kevin Krammer, krake@kdab.com - Author: Tobias Koenig, tokoe@kdab.com - - This program 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 2 of the License, or - (at your option) any later version. - - This program 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 this program; if not, write to the Free Software Foundation, Inc., - 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. -*/ - -#include "declarativeslider_p.h" - -DeclarativeSlider::DeclarativeSlider(QObject *parent) - : DeclarativeWidgetProxy(parent) -{ - connectAllSignals(m_proxiedObject, this); -} - -CUSTOM_METAOBJECT(DeclarativeSlider, QSlider) diff --git a/lib/declarativeslider_p.h b/lib/declarativeslider_p.h deleted file mode 100644 index 81cc965..0000000 --- a/lib/declarativeslider_p.h +++ /dev/null @@ -1,36 +0,0 @@ -/* - Copyright (C) 2012 Klarälvdalens Datakonsult AB, a KDAB Group company, info@kdab.com - Author: Kevin Krammer, krake@kdab.com - Author: Tobias Koenig, tokoe@kdab.com - - This program 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 2 of the License, or - (at your option) any later version. - - This program 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 this program; if not, write to the Free Software Foundation, Inc., - 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. -*/ - -#ifndef DECLARATIVESLIDER_P_H -#define DECLARATIVESLIDER_P_H - -#include "declarativewidgetproxy_p.h" - -#include - -class DeclarativeSlider : public DeclarativeWidgetProxy -{ - DECLARATIVE_OBJECT - - public: - explicit DeclarativeSlider(QObject *parent = 0); -}; - -#endif diff --git a/lib/declarativewidgetsdocument.cpp b/lib/declarativewidgetsdocument.cpp index 3ffc6e1..07b2801 100644 --- a/lib/declarativewidgetsdocument.cpp +++ b/lib/declarativewidgetsdocument.cpp @@ -51,7 +51,6 @@ #include "declarativescrollarea_p.h" #include "declarativescrollbar_p.h" #include "declarativeseparator_p.h" -#include "declarativeslider_p.h" #include "declarativespinbox_p.h" #include "declarativestackedlayout_p.h" #include "declarativestackedwidget_p.h" @@ -125,7 +124,6 @@ DeclarativeWidgetsDocument::DeclarativeWidgetsDocument(const QUrl &url, QObject qmlRegisterType("QtGui", 1, 0, "ProgressBar"); qmlRegisterType("QtGui", 1, 0, "ScrollArea"); qmlRegisterType("QtGui", 1, 0, "ScrollBar"); - qmlRegisterType("QtGui", 1, 0, "Slider"); qmlRegisterType("QtGui", 1, 0, "SpinBox"); qmlRegisterType("QtGui", 1, 0, "StackedWidget"); qmlRegisterType(); @@ -171,6 +169,7 @@ DeclarativeWidgetsDocument::DeclarativeWidgetsDocument(const QUrl &url, QObject qmlRegisterExtendedType("QtGui", 1, 0, "MessageBox"); qmlRegisterExtendedType("QtGui", 1, 0, "PushButton"); qmlRegisterExtendedType("QtGui", 1, 0, "RadioButton"); + qmlRegisterExtendedType("QtGui", 1, 0, "Slider"); qmlRegisterExtendedType("QtGui", 1, 0, "StatusBar"); qmlRegisterExtendedType("QtGui", 1, 0, "TableView"); qmlRegisterExtendedType("QtGui", 1, 0, "TabWidget"); diff --git a/lib/lib.pro b/lib/lib.pro index 833d98a..5d019cc 100644 --- a/lib/lib.pro +++ b/lib/lib.pro @@ -41,7 +41,6 @@ HEADERS = \ declarativescrollarea_p.h \ declarativescrollbar_p.h \ declarativeseparator_p.h \ - declarativeslider_p.h \ declarativespinbox_p.h \ declarativestackedlayout_p.h \ declarativestackedwidget_p.h \ @@ -94,7 +93,6 @@ SOURCES = \ declarativescrollarea.cpp \ declarativescrollbar.cpp \ declarativeseparator.cpp \ - declarativeslider.cpp \ declarativespinbox.cpp \ declarativestackedlayout.cpp \ declarativestackedwidget.cpp \ -- 1.7.2.5