kowindowlist.h
00001 /* 00002 This file is part of KOrganizer. 00003 Copyright (c) 2000 Cornelius Schumacher <schumacher@kde.org> 00004 00005 This program is free software; you can redistribute it and/or modify 00006 it under the terms of the GNU General Public License as published by 00007 the Free Software Foundation; either version 2 of the License, or 00008 (at your option) any later version. 00009 00010 This program 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 00013 GNU General Public License for more details. 00014 00015 You should have received a copy of the GNU General Public License 00016 along with this program; if not, write to the Free Software 00017 Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. 00018 00019 As a special exception, permission is given to link this program 00020 with any edition of Qt, and distribute the resulting executable, 00021 without including the source code for Qt in the source distribution. 00022 */ 00023 #ifndef KOWINDOWLIST_H 00024 #define KOWINDOWLIST_H 00025 00026 #include <qobject.h> 00027 00028 #include "korganizer.h" 00029 00030 class KURL; 00031 00041 class KOWindowList : public QObject 00042 { 00043 Q_OBJECT 00044 public: 00049 KOWindowList(const char *name=0); 00050 virtual ~KOWindowList(); 00051 00053 bool lastInstance(); 00054 00056 KOrganizer* findInstance(const KURL &url); 00057 00058 signals: 00059 00060 public slots: 00061 void addWindow(KOrganizer *); 00062 void removeWindow(KOrganizer *); 00063 00065 void deactivateCalendars(KOrganizer *); 00066 00067 private: 00068 QPtrList<KOrganizer> mWindowList; // list of all existing KOrganizer instances 00069 }; 00070 00071 #endif