kmail Library API Documentation

kmsystemtray.h

00001 /*************************************************************************** 00002 kmsystemtray.h - description 00003 ------------------- 00004 begin : Fri Aug 31 22:38:44 EDT 2001 00005 copyright : (C) 2001 by Ryan Breen 00006 email : ryan@porivo.com 00007 ***************************************************************************/ 00008 00009 /*************************************************************************** 00010 * * 00011 * This program is free software; you can redistribute it and/or modify * 00012 * it under the terms of the GNU General Public License as published by * 00013 * the Free Software Foundation; either version 2 of the License, or * 00014 * (at your option) any later version. * 00015 * * 00016 ***************************************************************************/ 00017 00018 #ifndef KMSYSTEMTRAY_H 00019 #define KMSYSTEMTRAY_H 00020 00021 #include <ksystemtray.h> 00022 00023 #include <qmap.h> 00024 #include <qguardedptr.h> 00025 #include <qptrvector.h> 00026 #include <qpixmap.h> 00027 #include <qimage.h> 00028 00029 class KMFolder; 00030 class KMMainWidget; 00031 class QMouseEvent; 00032 class KPopupMenu; 00033 class QPoint; 00034 00039 class KMSystemTray : public KSystemTray 00040 { 00041 Q_OBJECT 00042 public: 00044 KMSystemTray(QWidget* parent=0, const char *name=0); 00046 ~KMSystemTray(); 00047 00048 void setMode(int mode); 00049 00050 enum SystrayMode { 00051 AlwaysOn, 00052 OnNewMail 00053 }; 00054 00055 private slots: 00056 void updateNewMessageNotification(KMFolder * folder); 00057 void foldersChanged(); 00058 void selectedAccount(int); 00059 00060 protected: 00061 void mousePressEvent(QMouseEvent *); 00062 bool mainWindowIsOnCurrentDesktop(); 00063 void showKMail(); 00064 void hideKMail(); 00065 void buildPopupMenu(); 00066 void updateCount(); 00067 00068 QString prettyName(KMFolder *); 00069 KMMainWidget * getKMMainWidget(); 00070 00071 private: 00072 00073 bool mParentVisible; 00074 QPoint mPosOfMainWin; 00075 int mDesktopOfMainWin; 00076 00077 int mMode; 00078 int mCount; 00079 int mNewMessagePopupId; 00080 00081 KPopupMenu * mPopupMenu; 00082 QPixmap mDefaultIcon; 00083 QImage mLightIconImage; 00084 00085 QPtrVector<KMFolder> mPopupFolders; 00086 QMap<QGuardedPtr<KMFolder>, int> mFoldersWithUnread; 00087 }; 00088 00089 #endif
KDE Logo
This file is part of the documentation for kmail Library Version 3.2.2.
Documentation copyright © 1996-2004 the KDE developers.
Generated on Wed Jul 28 23:58:04 2004 by doxygen 1.3.7 written by Dimitri van Heesch, © 1997-2003