~ubuntu-branches/ubuntu/oneiric/kdepim/oneiric-updates

« back to all changes in this revision

Viewing changes to incidenceeditor-ng/freebusyitem.h

  • Committer: Package Import Robot
  • Author(s): Philip Muškovac
  • Date: 2011-06-28 19:33:24 UTC
  • mfrom: (0.2.13) (0.1.13 sid)
  • Revision ID: package-import@ubuntu.com-20110628193324-8yvjs8sdv9rdoo6c
Tags: 4:4.7.0-0ubuntu1
* New upstream release
  - update install files
  - add missing kdepim-doc package to control file
  - Fix Vcs lines
  - kontact breaks/replaces korganizer << 4:4.6.80
  - tighten the dependency of kdepim-dev on libkdepim4 to fix lintian error

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
/*
 
2
  Copyright (c) 2000,2001,2004 Cornelius Schumacher <schumacher@kde.org>
 
3
  Copyright (c) 2010 Klarälvdalens Datakonsult AB, a KDAB Group company, info@kdab.com
 
4
  Copyright (c) 2010 Andras Mantia <andras@kdab.com>
 
5
  Copyright (C) 2010 Casey Link <casey@kdab.com>
 
6
 
 
7
  This library is free software; you can redistribute it and/or modify it
 
8
  under the terms of the GNU Library General Public License as published by
 
9
  the Free Software Foundation; either version 2 of the License, or (at your
 
10
  option) any later version.
 
11
 
 
12
  This library is distributed in the hope that it will be useful, but WITHOUT
 
13
  ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
 
14
  FITNESS FOR A PARTICULAR PURPOSE.  See the GNU Library General Public
 
15
  License for more details.
 
16
 
 
17
  You should have received a copy of the GNU Library General Public License
 
18
  along with this library; see the file COPYING.LIB.  If not, write to the
 
19
  Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
 
20
  02110-1301, USA.
 
21
*/
 
22
 
 
23
#ifndef INCIDENCEEDITOR_FREEBUSYITEM_H
 
24
#define INCIDENCEEDITOR_FREEBUSYITEM_H
 
25
 
 
26
#include "incidenceeditors-ng_export.h"
 
27
 
 
28
#include <KCalCore/FreeBusy>
 
29
 
 
30
namespace IncidenceEditorNG {
 
31
 
 
32
/**
 
33
 * The FreeBusyItem is the whole line for a given attendee..
 
34
 */
 
35
class INCIDENCEEDITORS_NG_EXPORT FreeBusyItem
 
36
{
 
37
  public:
 
38
    typedef QSharedPointer<FreeBusyItem> Ptr;
 
39
 
 
40
    /**
 
41
     * @param parentWidget is passed to Akonadi when fetching free/busy data.
 
42
     */
 
43
    FreeBusyItem( const KCalCore::Attendee::Ptr &attendee, QWidget *parentWidget );
 
44
    ~FreeBusyItem() {}
 
45
 
 
46
    KCalCore::Attendee::Ptr attendee() const;
 
47
    void setFreeBusy( const KCalCore::FreeBusy::Ptr &fb );
 
48
    KCalCore::FreeBusy::Ptr freeBusy() const;
 
49
 
 
50
    QString email() const;
 
51
    void setUpdateTimerID( int id );
 
52
    int updateTimerID() const;
 
53
 
 
54
    void startDownload( bool forceDownload );
 
55
    void setIsDownloading( bool d );
 
56
    bool isDownloading() const;
 
57
 
 
58
  signals:
 
59
    void attendeeChanged( const KCalCore::Attendee::Ptr &attendee );
 
60
    void freebusyChanged( const KCalCore::FreeBusy::Ptr fb );
 
61
 
 
62
  private:
 
63
    KCalCore::Attendee::Ptr mAttendee;
 
64
    KCalCore::FreeBusy::Ptr mFreeBusy;
 
65
 
 
66
    // This is used for the update timer
 
67
    int mTimerID;
 
68
 
 
69
    // Only run one download job at a time
 
70
    bool mIsDownloading;
 
71
 
 
72
    QWidget *mParentWidget;
 
73
};
 
74
 
 
75
}
 
76
#endif