• Skip to content
  • Skip to link menu
KDE 4.1 API Reference
  • KDE API Reference
  • API Reference
  • Sitemap
  • Contact Us
 

Applets

applicationmodel.h

Go to the documentation of this file.
00001 /*
00002     Copyright 2007 Pino Toscano <pino@kde.org>
00003     Copyright 2007 Robert Knight <robertknight@gmail.com>
00004 
00005     This library is free software; you can redistribute it and/or
00006     modify it under the terms of the GNU Library General Public
00007     License as published by the Free Software Foundation; either
00008     version 2 of the License, or (at your option) any later version.
00009 
00010     This library is distributed in the hope that it will be useful,
00011     but WITHOUT ANY WARRANTY; without even the implied warranty of
00012     MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
00013     Library General Public License for more details.
00014 
00015     You should have received a copy of the GNU Library General Public License
00016     along with this library; see the file COPYING.LIB.  If not, write to
00017     the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
00018     Boston, MA 02110-1301, USA.
00019 */
00020 
00021 #ifndef APPLICATIONMODEL_H
00022 #define APPLICATIONMODEL_H
00023 
00024 #include "core/kickoffabstractmodel.h"
00025 
00026 namespace Kickoff
00027 {
00028 
00029 class ApplicationModelPrivate;
00030 
00035 class ApplicationModel : public KickoffAbstractModel
00036 {
00037     Q_OBJECT
00038 
00039     public:
00040         ApplicationModel(QObject *parent = 0);
00041         virtual ~ApplicationModel();
00042 
00048         enum DuplicatePolicy
00049         {
00051             ShowDuplicatesPolicy,
00063             ShowLatestOnlyPolicy
00064         };
00065 
00070         void setDuplicatePolicy(DuplicatePolicy policy);
00072         DuplicatePolicy duplicatePolicy() const;
00073 
00074         // reimplemented from QAbstractItemModel
00075         virtual bool canFetchMore(const QModelIndex &parent) const;
00076         virtual int columnCount(const QModelIndex &parent = QModelIndex()) const;
00077         virtual QVariant data(const QModelIndex &index, int role = Qt::DisplayRole) const;
00078         virtual void fetchMore(const QModelIndex &parent);
00079         virtual bool hasChildren(const QModelIndex &parent = QModelIndex()) const;
00080         virtual QVariant headerData(int section, Qt::Orientation orientation, int role = Qt::DisplayRole) const;
00081         virtual QModelIndex index(int row, int column, const QModelIndex &parent = QModelIndex()) const;
00082         virtual QModelIndex parent(const QModelIndex &index) const;
00083         virtual int rowCount(const QModelIndex &parent = QModelIndex()) const;
00084 
00085     public slots:
00086         void slotReloadMenu();
00087         void checkSycocaChange();
00088 
00089     private:
00090         friend class ApplicationModelPrivate;
00091         ApplicationModelPrivate *const d;
00092 
00093         Q_DISABLE_COPY(ApplicationModel)
00094 };
00095 
00096 }
00097 
00098 #endif

Applets

Skip menu "Applets"
  • Main Page
  • Namespace List
  • Class Hierarchy
  • Alphabetical List
  • Class List
  • File List
  • Namespace Members
  • Class Members

API Reference

Skip menu "API Reference"
  • KWin
  •   KWin Libraries
  • Libraries
  •   libkworkspace
  •   libplasma
  •   libsolidcontrol
  •   libtaskmanager
  • Plasma
  •   Animators
  •   Applets
  •   Engines
  • Solid Modules
Generated for API Reference by doxygen 1.5.4
This website is maintained by Adriaan de Groot and Allen Winter.
KDE® and the K Desktop Environment® logo are registered trademarks of KDE e.V. | Legal