libtdepim

ldapsearchdialog.h
1/* ldapsearchdialogimpl.h - LDAP access
2 * Copyright (C) 2002 Klarälvdalens Datakonsult AB
3 *
4 * Author: Steffen Hansen <hansen@kde.org>
5 *
6 * This file is free software; you can redistribute it and/or modify
7 * it under the terms of the GNU General Public License as published by
8 * the Free Software Foundation; either version 2 of the License, or
9 * (at your option) any later version.
10 *
11 * This file is distributed in the hope that it will be useful,
12 * but WITHOUT ANY WARRANTY; without even the implied warranty of
13 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 * GNU General Public License for more details.
15 *
16 * You should have received a copy of the GNU General Public License
17 * along with this program; if not, write to the Free Software
18 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
19 */
20
21#ifndef LDAPSEARCHDIALOG_H
22#define LDAPSEARCHDIALOG_H
23
24#include <tqptrlist.h>
25
26#include <ldapclient.h>
27#include <kdialogbase.h>
28#include <klineedit.h>
29
30class KComboBox;
31
32class TQCheckBox;
33class TQListView;
34class TQPushButton;
35
36namespace KPIM {
37
38class LDAPSearchDialog : public KDialogBase
39{
40 TQ_OBJECT
41
42
43 public:
44 LDAPSearchDialog( TQWidget* parent, const char* name = 0 );
45 ~LDAPSearchDialog();
46
47 bool isOK() const { return mIsOK; }
48
49 void restoreSettings();
50
51 void setSearchText( const TQString &text ) { mSearchEdit->setText( text ); }
52 TQString selectedEMails() const;
53 signals:
54 void addresseesAdded();
55
56 protected slots:
57 void slotAddResult( const KPIM::LdapObject& obj );
58 void slotSetScope( bool rec );
59 void slotStartSearch();
60 void slotStopSearch();
61 void slotSearchDone();
62 void slotError( const TQString& );
63 virtual void slotHelp();
64 virtual void slotUser1();
65 virtual void slotUser2();
66 virtual void slotUser3();
67
68 protected:
69
70 virtual void closeEvent( TQCloseEvent* );
71
72 private:
73 void saveSettings();
74
75 TQString makeFilter( const TQString& query, const TQString& attr, bool startsWith );
76
77 void cancelQuery();
78
79 int mNumHosts;
80 TQPtrList<KPIM::LdapClient> mLdapClientList;
81 bool mIsOK;
82 KComboBox* mFilterCombo;
83 KComboBox* mSearchType;
84 KLineEdit* mSearchEdit;
85
86 TQCheckBox* mRecursiveCheckbox;
87 TQListView* mResultListView;
88 TQPushButton* mSearchButton;
89};
90
91
92}
93#endif
This class is internal.
Definition: ldapclient.h:106
TDEPIM classes for drag and drop of mails.