kmail

kmmainwin.h
1/*
2 * kmail: KDE mail client
3 * Copyright (c) 1996-1998 Stefan Taferner <taferner@kde.org>
4 *
5 * This program is free software; you can redistribute it and/or modify
6 * it under the terms of the GNU General Public License as published by
7 * the Free Software Foundation; either version 2 of the License, or
8 * (at your option) any later version.
9 *
10 * This program is distributed in the hope that it will be useful,
11 * but WITHOUT ANY WARRANTY; without even the implied warranty of
12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13 * GNU General Public License for more details.
14 *
15 * You should have received a copy of the GNU General Public License
16 * along with this program; if not, write to the Free Software
17 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
18 *
19 */
20#ifndef __KMMAINWIN
21#define __KMMAINWIN
22
23#include <tdemainwindow.h>
24#include "tdeversion.h"
25#include "tqstring.h"
26
27class KMMainWidget;
28namespace KPIM {
29 class StatusbarProgressWidget;
30 class ProgressDialog;
31}
32using KPIM::StatusbarProgressWidget;
33using KPIM::ProgressDialog;
34
35class KMMainWin : public TDEMainWindow
36{
37 TQ_OBJECT
38
39
40public:
41 // the main window needs to have a name since else restoring the window
42 // settings by twin doesn't work
43 KMMainWin(TQWidget *parent = 0);
44 virtual ~KMMainWin();
45 KMMainWidget *mainKMWidget() const { return mKMMainWidget; };
46 StatusbarProgressWidget* progressWidget() const { return mLittleProgress; }
47 ProgressDialog* progressDialog() const { return mProgressDialog; }
48
49
51 virtual void readConfig(void);
52
54 virtual void writeConfig(void);
55
56public slots:
57 void displayStatusMsg(const TQString&);
58 void slotEditToolbars();
59 void slotUpdateToolbars();
60 void setupStatusBar();
61
62protected:
63 virtual bool queryClose ();
64
65protected slots:
66 void slotQuit();
67 void slotConfigChanged();
68 void slotShowTipOnStart();
69
70private slots:
71 void slotNewMailReader();
72
73private:
74 KMMainWidget *mKMMainWidget;
75 StatusbarProgressWidget *mLittleProgress;
76 ProgressDialog *mProgressDialog;
77 int mMessageStatusId;
78 bool mReallyClose;
79};
80
81#endif