1
/****************************************************************************
2
** accountdlg.h - dialogs for manipulating Jabber accounts
3
** Copyright (C) 2001, 2002 Justin Karneges
5
** This program is free software; you can redistribute it and/or
6
** modify it under the terms of the GNU General Public License
7
** as published by the Free Software Foundation; either version 2
8
** of the License, or (at your option) any later version.
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.
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., 59 Temple Place - Suite 330, Boston, MA 02111-1307,USA.
19
****************************************************************************/
2
* accountdlg.h - dialogs for manipulating PsiAccounts
3
* Copyright (C) 2001, 2002 Justin Karneges
5
* This program is free software; you can redistribute it and/or
6
* modify it under the terms of the GNU General Public License
7
* as published by the Free Software Foundation; either version 2
8
* of the License, or (at your option) any later version.
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.
15
* You should have received a copy of the GNU General Public License
16
* along with this library; if not, write to the Free Software
17
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
21
21
#ifndef ACCOUNTDLG_H
22
22
#define ACCOUNTDLG_H
27
#include"uniquewindow.h"
29
25
#include"ui_accountmanage.h"
26
#include"ui_accountadd.h"
27
#include"ui_accountreg.h"
28
#include"ui_accountremove.h"
30
29
#include"ui_accountmodify.h"
31
#include"busywidget.h"
34
class AccountViewItem : public QListViewItem
54
class MiniClient : public QObject
37
AccountViewItem(QListView *, JabSession *);
58
MiniClient(QObject *parent=0);
62
void connectToServer(const Jid &j, bool ssl, const QString &host, int port, ProxyManager *pm, int proxy, QString *pass);
71
void tls_handshaken();
73
void cs_securityLayerActivated(int);
74
void cs_needAuthParams(bool, bool, bool);
75
void cs_authenticated();
76
void cs_connectionClosed();
77
void cs_delayedCloseFinished();
82
AdvancedConnector *conn;
85
QCATLSHandler *tlsHandler;
86
QPtrList<QCA::Cert> certList;
44
92
class AccountManageDlg : public AccountManageUI
48
AccountManageDlg(JabSessionManager *, QWidget *parent=0, const char *name=0);
96
AccountManageDlg(PsiCon *, const char *name=0);
49
97
~AccountManageDlg();
51
static AccountManageDlg *find();
54
void signalModify(const QString &);
57
void updateEntry(JabSession *);
58
void sessionUpdate(JabSession *);
100
void qlv_selectionChanged(QListViewItem *);
62
103
void modify(QListViewItem *);
65
JabSessionManager *jsm;
68
class AccountModifyDlg : public AccountModifyUI, public UniqueWindow
72
AccountModifyDlg(JabSession *, bool haveSSL, QWidget *parent=0, const char *name=0);
105
void accountAdded(PsiAccount *);
106
void accountUpdated(PsiAccount *);
107
void accountRemoved(PsiAccount *);
113
class AccountAddDlg : public AccountAddUI
117
AccountAddDlg(PsiCon *, QWidget *parent=0, const char *name=0);
122
void setAddButton(const QString &);
128
class AccountModifyDlg : public AccountModifyUI
132
AccountModifyDlg(PsiAccount *, QWidget *parent=0, const char *name=0);
73
133
~AccountModifyDlg();
75
static AccountModifyDlg *find(const QString &accname);
135
void setPassword(const QString &);
78
138
void sslToggled(bool);
139
void hostToggled(bool);
142
void detailsChangePW();
87
class AccountRegisterDlg : public QDialog
91
AccountRegisterDlg(QWidget *parent=0, const char *name=0);
92
~AccountRegisterDlg();
94
void start(const QString &, int, bool, const QString &, const QString &);
97
static bool reg(QWidget *, const QString &, int, bool, const QString &, const QString &);
101
void closeEvent(QCloseEvent *);
104
void accRegisterFinished(bool, const QString &);
105
void jab_error(JabError *);
146
void pgpToggled(bool);
147
void optpp_toggled(bool);
157
void setKeyID(bool b, const QString &s="");
160
class AccountRegDlg : public AccountRegUI
164
AccountRegDlg(ProxyManager *, QWidget *parent=0, const char *name=0);
168
QString sp_host, pass;
175
//void closeEvent(QCloseEvent *);
181
void sslToggled(bool);
182
void hostToggled(bool);
185
void client_handshaken();
194
ProxyManager *proxyman;
199
class AccountRemoveDlg : public AccountRemoveUI
203
AccountRemoveDlg(ProxyManager *, const UserAccount &, QWidget *parent=0, const char *name=0);
208
//void closeEvent(QCloseEvent *);
215
void bg_clicked(int);
217
void client_handshaken();
219
void unreg_finished();