From 935ad6b02c47a74d94dc5afd5ca2795cbd9f7c75 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Petr=20Mr=C3=A1zek?= Date: Sun, 4 Aug 2013 12:21:51 +0200 Subject: [PATCH] Fix KDE includes problem --- gui/instancemodel.h | 2 +- gui/mainwindow.cpp | 17 +++-------------- libgroupview/CMakeLists.txt | 16 ++++++++-------- ...odel.h => categorizedsortfilterproxymodel.h} | 1 - .../{kcategorizedview.h => categorizedview.h} | 1 - .../{kcategorydrawer.h => categorydrawer.h} | 0 ....cpp => categorizedsortfilterproxymodel.cpp} | 4 ++-- ..._p.h => categorizedsortfilterproxymodel_p.h} | 0 ...kcategorizedview.cpp => categorizedview.cpp} | 10 +++++----- ...kcategorizedview_p.h => categorizedview_p.h} | 0 .../{kcategorydrawer.cpp => categorydrawer.cpp} | 8 ++++---- 11 files changed, 23 insertions(+), 36 deletions(-) rename libgroupview/include/{kcategorizedsortfilterproxymodel.h => categorizedsortfilterproxymodel.h} (99%) rename libgroupview/include/{kcategorizedview.h => categorizedview.h} (99%) rename libgroupview/include/{kcategorydrawer.h => categorydrawer.h} (100%) rename libgroupview/src/{kcategorizedsortfilterproxymodel.cpp => categorizedsortfilterproxymodel.cpp} (97%) rename libgroupview/src/{kcategorizedsortfilterproxymodel_p.h => categorizedsortfilterproxymodel_p.h} (100%) rename libgroupview/src/{kcategorizedview.cpp => categorizedview.cpp} (99%) rename libgroupview/src/{kcategorizedview_p.h => categorizedview_p.h} (100%) rename libgroupview/src/{kcategorydrawer.cpp => categorydrawer.cpp} (97%) diff --git a/gui/instancemodel.h b/gui/instancemodel.h index 3938da45..fe05744f 100644 --- a/gui/instancemodel.h +++ b/gui/instancemodel.h @@ -1,7 +1,7 @@ #pragma once #include -#include "kcategorizedsortfilterproxymodel.h" +#include "categorizedsortfilterproxymodel.h" #include "lists/InstanceList.h" #include diff --git a/gui/mainwindow.cpp b/gui/mainwindow.cpp index c4e8dc03..d3dee254 100644 --- a/gui/mainwindow.cpp +++ b/gui/mainwindow.cpp @@ -45,8 +45,8 @@ #include "gui/legacymodeditdialog.h" #include "gui/instancesettings.h" -#include "kcategorizedview.h" -#include "kcategorydrawer.h" +#include "categorizedview.h" +#include "categorydrawer.h" #include "lists/InstanceList.h" #include "AppSettings.h" @@ -84,12 +84,6 @@ MainWindow::MainWindow ( QWidget *parent ) : // Create the widget view = new KCategorizedView ( ui->centralWidget ); drawer = new KCategoryDrawer ( view ); - /* - QPalette pal = view->palette(); - pal.setBrush(QPalette::Base, QBrush(QPixmap(QString::fromUtf8(":/backgrounds/kitteh")))); - view->setPalette(pal); - */ - view->setStyleSheet( "QListView\ {\ @@ -137,13 +131,8 @@ MainWindow::MainWindow ( QWidget *parent ) : connect(view, SIGNAL(clicked(const QModelIndex &)), this, SLOT(instanceChanged(const QModelIndex &))); - // Load the instances. + // Load the instances. FIXME: this is not the place I'd say. instList.loadList(); - // just a test - /* - instList.at(0)->setGroup("TEST GROUP"); - instList.at(0)->setName("TEST ITEM"); - */ //FIXME: WTF if (!MinecraftVersionList::getMainList().isLoaded()) diff --git a/libgroupview/CMakeLists.txt b/libgroupview/CMakeLists.txt index c53988a0..d60d914a 100644 --- a/libgroupview/CMakeLists.txt +++ b/libgroupview/CMakeLists.txt @@ -13,19 +13,19 @@ SET(LIBGROUPVIEW_HEADERS include/libgroupview_config.h # Public headers -include/kcategorizedsortfilterproxymodel.h -include/kcategorizedview.h -include/kcategorydrawer.h +include/categorizedsortfilterproxymodel.h +include/categorizedview.h +include/categorydrawer.h # Private headers -src/kcategorizedsortfilterproxymodel_p.h -src/kcategorizedview_p.h +src/categorizedsortfilterproxymodel_p.h +src/categorizedview_p.h ) SET(LIBGROUPVIEW_SOURCES -src/kcategorizedsortfilterproxymodel.cpp -src/kcategorizedview.cpp -src/kcategorydrawer.cpp +src/categorizedsortfilterproxymodel.cpp +src/categorizedview.cpp +src/categorydrawer.cpp ) # Set the include dir path. diff --git a/libgroupview/include/kcategorizedsortfilterproxymodel.h b/libgroupview/include/categorizedsortfilterproxymodel.h similarity index 99% rename from libgroupview/include/kcategorizedsortfilterproxymodel.h rename to libgroupview/include/categorizedsortfilterproxymodel.h index df1be736..1ef39fc2 100644 --- a/libgroupview/include/kcategorizedsortfilterproxymodel.h +++ b/libgroupview/include/categorizedsortfilterproxymodel.h @@ -24,7 +24,6 @@ #include -//#include #include class QItemSelection; diff --git a/libgroupview/include/kcategorizedview.h b/libgroupview/include/categorizedview.h similarity index 99% rename from libgroupview/include/kcategorizedview.h rename to libgroupview/include/categorizedview.h index e0ac31fd..243ccf15 100644 --- a/libgroupview/include/kcategorizedview.h +++ b/libgroupview/include/categorizedview.h @@ -23,7 +23,6 @@ #include -//#include #include class KCategoryDrawer; diff --git a/libgroupview/include/kcategorydrawer.h b/libgroupview/include/categorydrawer.h similarity index 100% rename from libgroupview/include/kcategorydrawer.h rename to libgroupview/include/categorydrawer.h diff --git a/libgroupview/src/kcategorizedsortfilterproxymodel.cpp b/libgroupview/src/categorizedsortfilterproxymodel.cpp similarity index 97% rename from libgroupview/src/kcategorizedsortfilterproxymodel.cpp rename to libgroupview/src/categorizedsortfilterproxymodel.cpp index 46a845e0..09da9dd3 100644 --- a/libgroupview/src/kcategorizedsortfilterproxymodel.cpp +++ b/libgroupview/src/categorizedsortfilterproxymodel.cpp @@ -19,8 +19,8 @@ * Boston, MA 02110-1301, USA. */ -#include "kcategorizedsortfilterproxymodel.h" -#include "kcategorizedsortfilterproxymodel_p.h" +#include "categorizedsortfilterproxymodel.h" +#include "categorizedsortfilterproxymodel_p.h" #include diff --git a/libgroupview/src/kcategorizedsortfilterproxymodel_p.h b/libgroupview/src/categorizedsortfilterproxymodel_p.h similarity index 100% rename from libgroupview/src/kcategorizedsortfilterproxymodel_p.h rename to libgroupview/src/categorizedsortfilterproxymodel_p.h diff --git a/libgroupview/src/kcategorizedview.cpp b/libgroupview/src/categorizedview.cpp similarity index 99% rename from libgroupview/src/kcategorizedview.cpp rename to libgroupview/src/categorizedview.cpp index 4da4271f..f4449949 100644 --- a/libgroupview/src/kcategorizedview.cpp +++ b/libgroupview/src/categorizedview.cpp @@ -29,8 +29,8 @@ * design. */ -#include "kcategorizedview.h" -#include "kcategorizedview_p.h" +#include "categorizedview.h" +#include "categorizedview_p.h" #include // trunc on C99 compliant systems //#include // trunc for not C99 compliant systems @@ -39,8 +39,8 @@ #include #include -#include "kcategorydrawer.h" -#include "kcategorizedsortfilterproxymodel.h" +#include "categorydrawer.h" +#include "categorizedsortfilterproxymodel.h" //BEGIN: Private part @@ -1710,4 +1710,4 @@ void KCategorizedView::slotCollapseOrExpandClicked ( QModelIndex idx ) } -#include "kcategorizedview.moc" +#include "categorizedview.moc" diff --git a/libgroupview/src/kcategorizedview_p.h b/libgroupview/src/categorizedview_p.h similarity index 100% rename from libgroupview/src/kcategorizedview_p.h rename to libgroupview/src/categorizedview_p.h diff --git a/libgroupview/src/kcategorydrawer.cpp b/libgroupview/src/categorydrawer.cpp similarity index 97% rename from libgroupview/src/kcategorydrawer.cpp rename to libgroupview/src/categorydrawer.cpp index 951c1eb2..04903206 100644 --- a/libgroupview/src/kcategorydrawer.cpp +++ b/libgroupview/src/categorydrawer.cpp @@ -18,14 +18,14 @@ * Boston, MA 02110-1301, USA. */ -#include "kcategorydrawer.h" +#include "categorydrawer.h" #include #include #include -#include -#include +#include +#include #define HORIZONTAL_HINT 3 @@ -228,4 +228,4 @@ void KCategoryDrawer::mouseLeft(const QModelIndex&, const QRect&) { } -#include "kcategorydrawer.moc" +#include "categorydrawer.moc"