not quite so much needs to be delayed to the init() function
[personal-kdebase.git] / workspace / kcontrol / kdm / kdm-users.h
blob5b273f47c43b68a86ce863558984ab3cddabcc48
1 /*
2 Copyright (C) 1997 Thomas Tanghus (tanghus@earthling.net)
4 This program is free software; you can redistribute it and/or
5 modify it under the terms of the GNU General Public
6 License as published by the Free Software Foundation; either
7 version 2 of the License, or (at your option) any later version.
9 This program is distributed in the hope that it will be useful,
10 but WITHOUT ANY WARRANTY; without even the implied warranty of
11 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12 General Public License for more details.
14 You should have received a copy of the GNU Library General Public License
15 along with this library; see the file COPYING.LIB. If not, write to
16 the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
17 Boston, MA 02110-1301, USA.
20 #ifndef __KDMUSERS_H__
21 #define __KDMUSERS_H__
23 #include <QWidget>
25 class K3ListView;
26 class Q3ListViewItem;
27 class KComboBox;
28 class QCheckBox;
29 class QGroupBox;
30 class QLabel;
31 class QLineEdit;
32 class QPushButton;
33 class QRadioButton;
34 class QStackedWidget;
36 class KDMUsersWidget : public QWidget {
37 Q_OBJECT
39 public:
40 KDMUsersWidget( QWidget *parent = 0 );
42 void load();
43 void save();
44 void defaults();
45 void makeReadOnly();
47 bool eventFilter( QObject *o, QEvent *e );
49 public Q_SLOTS:
50 void slotClearUsers();
51 void slotAddUsers( const QMap<QString,int> & );
52 void slotDelUsers( const QMap<QString,int> & );
54 Q_SIGNALS:
55 void changed();
56 void setMinMaxUID( int, int );
58 private Q_SLOTS:
59 void slotMinMaxChanged();
60 void slotShowOpts();
61 void slotUpdateOptIn( Q3ListViewItem *item );
62 void slotUpdateOptOut( Q3ListViewItem *item );
63 void slotUserSelected();
64 void slotUnsetUserPix();
65 void slotFaceOpts();
66 void slotUserButtonClicked();
68 private:
69 void updateOptList( Q3ListViewItem *item, QStringList &list );
70 void userButtonDropEvent( QDropEvent *e );
71 void changeUserPix( const QString & );
73 QGroupBox *minGroup; // top left
74 QLineEdit *leminuid, *lemaxuid;
76 QGroupBox *usrGroup; // right below
77 QCheckBox *cbshowlist, *cbcomplete, *cbinverted, *cbusrsrt;
79 QLabel *s_label; // middle
80 QStackedWidget *wstack;
81 K3ListView *optoutlv, *optinlv;
83 QGroupBox *faceGroup; // right
84 QRadioButton *rbadmonly, *rbprefadm, *rbprefusr, *rbusronly;
86 KComboBox *usercombo; // right below
87 QPushButton *userbutton;
88 QPushButton *rstuserbutton;
90 QString m_userPixDir;
91 QString m_defaultText;
92 QStringList hiddenUsers, selectedUsers;
93 QString defminuid, defmaxuid;
94 bool m_readOnly;
97 #endif