Databasehandlingdialogclasses  0.5.3
hk_kderowselector.h
1 // ****************************************************************************
2 // copyright (c) 2000-2005 Horst Knorr <hk_classes@knoda.org>
3 // This file is part of the hk_kdeclasses library.
4 // This file may be distributed and/or modified under the terms of the
5 // GNU General Public License version 2 as published by the Free Software
6 // Foundation and appearing in the file COPYING included in the
7 // packaging of this file.
8 // This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
9 // WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
10 // ****************************************************************************
11 
12 #ifndef HK_KDEROWSELECTOR
13 #define HK_KDEROWSELECTOR
14 #include <qwidget.h>
15 #include <qlayout.h>
16 #include <qpushbutton.h>
17 #include <klineedit.h>
18 #include <hk_dsrowselector.h>
19 #include <hk_datasource.h>
20 
21 class hk_form;
32 class hk_kderowselector : public QWidget , public hk_dsrowselector
33 {
34  Q_OBJECT
35 
36  public:
37  hk_kderowselector(QWidget* wid=0,hk_form* form=NULL);
38  virtual ~hk_kderowselector();
39 
40  protected slots:
41  void slotpress_gotofirst(void);
42  void slotpress_gotoprevious(void);
43  void slotpress_gotonext(void);
44  void slotpress_gotolast(void);
45  void slotpress_storechanges(void);
46  void slotpress_delete(void);
47  void slotpress_insert(void);
48  void slotlineedit(void);
49 
50  signals:
51  void previousrow_clicked();
52  void nextrow_clicked();
53  void insertrow_clicked();
54  void lastrow_clicked();
55  void firstrow_clicked();
56  void deleterow_clicked();
60  void rowselector_clicked();
61 
62  protected:
63  virtual void focusInEvent ( QFocusEvent * );
64  virtual void focusOutEvent ( QFocusEvent * );
65  virtual void widget_specific_tooltip_changed(void);
66  void widget_specific_enable_disable(void);
67  bool widget_specific_row_change(void);
68  void datasource_delete(void);
69  bool datasource_enable(void);
70  virtual void widget_specific_insert_mode(void);
71  virtual void resizeEvent (QResizeEvent *);
72  virtual void moveEvent ( QMoveEvent * ) ;
73  bool widget_specific_coordinates(uint px,uint py,uint pwidth,uint pheight);
74  virtual void widget_specific_backgroundcolour_changed(const hk_colour&);
75  virtual void widget_specific_foregroundcolour_changed(const hk_colour&);
76  virtual void widget_specific_enabled_changed(void);
77  virtual bool presentationmode_changed(void);
78 
79  private:
80  QPushButton* button_delete;
81  QPushButton* button_insert;
82  QPushButton* button_gotofirst;
83  QPushButton* button_gotoprevious;
84  QPushButton* button_gotonext;
85  QPushButton* button_gotolast;
86  QPushButton* button_store;
87  KLineEdit* label;
88  QHBoxLayout* layout;
89  void reposition(void);
90 
91 };
92 #endif
KDE Widget to select a specific row.
Definition: hk_kderowselector.h:32
void rowselector_clicked()