kgameerrordialog.h
00001 /* 00002 This file is part of the KDE games library 00003 Copyright (C) 2001 Andreas Beckermann (b_mann@gmx.de) 00004 Copyright (C) 2001 Martin Heni (martin@heni-online.de) 00005 00006 This library is free software; you can redistribute it and/or 00007 modify it under the terms of the GNU Library General Public 00008 License version 2 as published by the Free Software Foundation. 00009 00010 This library 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 GNU 00013 Library General Public License for more details. 00014 00015 You should have received a copy of the GNU Library General Public License 00016 along with this library; see the file COPYING.LIB. If not, write to 00017 the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, 00018 Boston, MA 02110-1301, USA. 00019 */ 00020 00021 #ifndef __KGAMEERRORDIALOG_H__ 00022 #define __KGAMEERRORDIALOG_H__ 00023 00024 #include <kdialogbase.h> 00025 00026 class KGame; 00027 class KGameErrorDialogPrivate; 00028 00039 class KGameErrorDialog : public QObject 00040 { 00041 Q_OBJECT 00042 public: 00043 KGameErrorDialog(QWidget* parent); 00044 ~KGameErrorDialog(); 00045 00052 void setKGame(const KGame* g); 00053 00060 void connectionError(QString s = QString::null); 00061 00062 public slots: 00063 void slotError(int error, QString text); 00064 00070 void slotServerConnectionLost(); 00071 00077 void slotClientConnectionLost(Q_UINT32 clientID,bool broken); 00078 00087 void slotUnsetKGame(); 00088 00089 protected: 00090 void error(const QString& errorText, QWidget* parent = 0); 00091 00092 private: 00093 KGameErrorDialogPrivate* d; 00094 }; 00095 00103 class KGameErrorMessageDialog : public KDialogBase 00104 { 00105 Q_OBJECT 00106 public: 00107 KGameErrorMessageDialog(QWidget* parent); 00108 ~KGameErrorMessageDialog(); 00109 00110 private: 00111 }; 00112 00113 #endif