Eneboo - Documentación para desarrolladores
src/flbase/FLFormRecordDB.h
Ir a la documentación de este archivo.
00001 /***************************************************************************
00002                            FLFormRecordDB.h
00003                           -------------------
00004  begin                : Sat Jul 28 2001
00005  copyright            : (C) 2001-2005 by InfoSiAL S.L.
00006  email                : mail@infosial.com
00007 ***************************************************************************/
00008 /***************************************************************************
00009  *   This program is free software; you can redistribute it and/or modify  *
00010  *   it under the terms of the GNU General Public License as published by  *
00011  *   the Free Software Foundation; version 2 of the License.               *
00012  ***************************************************************************/
00013 /***************************************************************************
00014    Este  programa es software libre. Puede redistribuirlo y/o modificarlo
00015    bajo  los  términos  de  la  Licencia  Pública General de GNU   en  su
00016    versión 2, publicada  por  la  Free  Software Foundation.
00017  ***************************************************************************/
00018 
00019 #ifndef FLFORMRECORDDB_H
00020 #define FLFORMRECORDDB_H
00021 
00022 #include <qpushbutton.h>
00023 #include <qsqlrecord.h>
00024 #include <qtooltip.h>
00025 #include <qwhatsthis.h>
00026 
00027 #include "FLFormDB.h"
00028 
00029 class FLFormRecordDBInterface;
00030 
00046 class FLFormRecordDB: public FLFormDB
00047 {
00048   Q_OBJECT
00049 
00050   friend class FLFormRecordDBInterface;
00051 
00052 public:
00053 
00063   FLFormRecordDB(FLSqlCursor *cursor, const QString &actionName = QString::null,
00064                  QWidget *parent = 0, bool showAcceptContinue = true);
00065 
00069   ~FLFormRecordDB();
00070 
00076   void setCursor(FLSqlCursor *c);
00077 
00081   void setMainWidget(QWidget *w);
00082 
00088   void setMainWidget();
00089 
00090 protected:
00091 
00095   void initForm();
00096 
00100   void closeEvent(QCloseEvent *e);
00101 
00114   bool validateForm();
00115 
00122   void acceptedForm();
00123 
00130   void afterCommitBuffer();
00131 
00138   void afterCommitTransaction();
00139 
00146   void canceledForm();
00147 
00151   QPushButton *pushButtonAccept;
00152 
00156   QPushButton *pushButtonAcceptContinue;
00157 
00161   QPushButton *pushButtonFirst;
00162 
00166   QPushButton *pushButtonPrevious;
00167 
00171   QPushButton *pushButtonNext;
00172 
00176   QPushButton *pushButtonLast;
00177 
00178 public slots:
00179 
00183   void initScript();
00184 
00188   virtual void accept();
00189 
00193   virtual void acceptContinue();
00194 
00198   virtual void reject();
00199 
00200 protected slots:
00201 
00205   virtual void firstRecord();
00206 
00210   virtual void previousRecord();
00211 
00215   virtual void nextRecord();
00216 
00220   virtual void lastRecord();
00221 
00225   void disablePushButtonCancel();
00226 
00227 private:
00228 
00232   bool accepted;
00233 
00237   bool showAcceptContinue_;
00238 
00242   FLFormRecordDBInterface *iface;
00243 
00247   bool accepting;
00248 
00252   int initialModeAccess;
00253 
00257   int initTransLevel;
00258 };
00259 
00260 #endif
 Todo Clases Namespaces Archivos Funciones Variables 'typedefs' Enumeraciones Valores de enumeraciones Propiedades Amigas 'defines'