X-Git-Url: http://git.maemo.org/git/?a=blobdiff_plain;f=src%2Fcurrentalertstablemodel.h;h=062bc11bc2faeb8a5ca3fe2d80eb51b0713ac441;hb=8c81978843d45998b02e3556bb4e326c37dac723;hp=75c8a75b34a31d4811ebd91b7becebb3553a7fa3;hpb=ae684d7266ec7e510a3a20f7a729418076ad5a84;p=kitchenalert diff --git a/src/currentalertstablemodel.h b/src/currentalertstablemodel.h index 75c8a75..062bc11 100644 --- a/src/currentalertstablemodel.h +++ b/src/currentalertstablemodel.h @@ -1,9 +1,11 @@ /************************************************************************** - KitchenAlert v.0.019 + KitchenAlert Copyright (C) 2010 Heli Hyvättinen - This program is free software: you can redistribute it and/or modify + This file is part of KitchenAlert. + + Kitchen Alert 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. @@ -26,8 +28,21 @@ #define CURRENTALERTSTABLEMODEL_H #include +#include #include "timer.h" + +/*! Class that contains the model that holds the timers' + + @author Heli Hyvättinen + @date 2010-07-20 + @version 0.1 + +Class that contains the model that holds the timers + +*/ + + class CurrentAlertsTableModel : public QAbstractTableModel { Q_OBJECT @@ -40,8 +55,12 @@ public: QVariant data(const QModelIndex &index, int role) const; + QVariant headerData(int section, Qt::Orientation orientation, int role) const; + QModelIndex giveIndexForTimer(Timer * ptimer); + bool isThisTimerAlerting(QModelIndex index); + signals: public slots: @@ -54,6 +73,9 @@ public slots: void snoozeTimer(QModelIndex index); void stopTimer(QModelIndex index); + + void setUpdateViewOnChanges(bool update); + private: QList currentTimers_; @@ -62,6 +84,10 @@ private: static const int timeRemainingColumnNumber_ = 1; static const int statusColumnNumber_ = 2; + + + bool updateViewOnChanges_; + }; #endif // CURRENTALERTSTABLEMODEL_H