KDE3Support
k3listbox.h
Go to the documentation of this file.
00001 /* This file is part of the KDE libraries 00002 Copyright (C) 2000 Reginald Stadlbauer <reggie@kde.org> 00003 00004 This library is free software; you can redistribute it and/or 00005 modify it under the terms of the GNU Library General Public 00006 License version 2 as published by the Free Software Foundation. 00007 00008 This library is distributed in the hope that it will be useful, 00009 but WITHOUT ANY WARRANTY; without even the implied warranty of 00010 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 00011 Library General Public License for more details. 00012 00013 You should have received a copy of the GNU Library General Public License 00014 along with this library; see the file COPYING.LIB. If not, write to 00015 the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, 00016 Boston, MA 02110-1301, USA. 00017 */ 00018 #ifndef K3LISTBOX_H 00019 #define K3LISTBOX_H 00020 00021 #include <kde3support_export.h> 00022 #include <Qt3Support/Q3ListBox> 00023 00039 class KDE3SUPPORT_EXPORT K3ListBox : public Q3ListBox 00040 { 00041 Q_OBJECT 00042 00043 public: 00044 explicit K3ListBox( QWidget *parent = 0, const char *name = 0, Qt::WFlags f = 0 ); 00045 00046 Q_SIGNALS: 00047 00058 void executed( Q3ListBoxItem *item ); 00059 00071 void executed( Q3ListBoxItem *item, const QPoint &pos ); 00072 00087 void doubleClicked( Q3ListBoxItem *item, const QPoint &pos ); 00088 00089 protected Q_SLOTS: 00090 void slotOnItem( Q3ListBoxItem *item ); 00091 void slotOnViewport(); 00092 00093 void slotSettingsChanged(int); 00094 00098 void slotAutoSelect(); 00099 00100 protected: 00101 void emitExecute( Q3ListBoxItem *item, const QPoint &pos ); 00102 00103 virtual void keyPressEvent(QKeyEvent *e); 00104 virtual void focusOutEvent( QFocusEvent *fe ); 00105 virtual void leaveEvent( QEvent *e ); 00106 virtual void contentsMousePressEvent( QMouseEvent *e ); 00107 virtual void contentsMouseDoubleClickEvent ( QMouseEvent *e ); 00108 00109 bool m_bUseSingle; 00110 bool m_bChangeCursorOverItem; 00111 00112 Q3ListBoxItem* m_pCurrentItem; 00113 00114 QTimer* m_pAutoSelect; 00115 int m_autoSelectDelay; 00116 00117 private Q_SLOTS: 00118 void slotMouseButtonClicked( int btn, Q3ListBoxItem *item, const QPoint &pos ); 00119 00120 private: 00121 class K3ListBoxPrivate; 00122 K3ListBoxPrivate* const d; 00123 }; 00124 00125 #endif
KDE 4.6 API Reference