korganizer

previewdialog.h
1/*
2 This file is part of KOrganizer.
3
4 Copyright (c) 2003,2004 Cornelius Schumacher <schumacher@kde.org>
5 Copyright (C) 2004 Reinhold Kainhofer <reinhold@kainhofer.com>
6
7 Copyright (C) 2010 Klarälvdalens Datakonsult AB, a KDAB Group company <info@kdab.net>
8 Author: Sergio Martins, <sergio.martins@kdab.com>
9
10 This program is free software; you can redistribute it and/or modify
11 it under the terms of the GNU General Public License as published by
12 the Free Software Foundation; either version 2 of the License, or
13 (at your option) any later version.
14
15 This program is distributed in the hope that it will be useful,
16 but WITHOUT ANY WARRANTY; without even the implied warranty of
17 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
18 GNU General Public License for more details.
19
20 You should have received a copy of the GNU General Public License
21 along with this program; if not, write to the Free Software
22 Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
23
24 As a special exception, permission is given to link this program
25 with any edition of TQt, and distribute the resulting executable,
26 without including the source code for TQt in the source distribution.
27*/
28
29#ifndef PREVIEWDIALOG_H
30#define PREVIEWDIALOG_H
31
32#include <kdialogbase.h>
33#include <kurl.h>
34
35class KOListView;
36
37namespace KCal {
38 class CalendarLocal;
39}
40
41class PreviewDialog : public KDialogBase
42{
43 TQ_OBJECT
44
45 public:
46 PreviewDialog( const KURL &url, TQWidget *parent );
47 ~PreviewDialog();
48 bool loadCalendar();
49
50 public slots:
51 void slotAdd();
52 void slotMerge();
53
54 signals:
55 void dialogFinished( PreviewDialog * );
56 void openURL( const KURL &, bool );
57 void addResource( const KURL & );
58
59 private:
60 // Checks if mOriginalUrl is a temp file, if it is we ask the user a place to
61 // keep the calendar file
62 bool isTempFile() const;
63 private:
64 KURL mOriginalUrl;
65 KURL *mLocalUrl;
66 KOListView *mListView;
67 KCal::CalendarLocal *mCalendar;
68};
69
70#endif
This class provides a multi-column list view of events.
Definition: kolistview.h:69