kpilot/kpilot
dbRecordEditor.h
00001 #ifndef _KPILOT_DBRECORDEDITOR_H 00002 #define _KPILOT_DBRECORDEDITOR_H 00003 /* dbRecordEditor.h KPilot 00004 ** 00005 ** Copyright (C) 2003 Reinhold Kainhofer <reinhold@kainhofer.com> 00006 ** 00007 */ 00008 00009 /* 00010 ** This program is free software; you can redistribute it and/or modify 00011 ** it under the terms of the GNU General Public License as published by 00012 ** the Free Software Foundation; either version 2 of the License, or 00013 ** (at your option) any later version. 00014 ** 00015 ** This program is distributed in the hope that it will be useful, 00016 ** but WITHOUT ANY WARRANTY; without even the implied warranty of 00017 ** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 00018 ** GNU General Public License for more details. 00019 ** 00020 ** You should have received a copy of the GNU General Public License 00021 ** along with this program in a file called COPYING; if not, write to 00022 ** the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, 00023 ** MA 02110-1301, USA. 00024 */ 00025 00026 /* 00027 ** Bug reports and questions can be sent to kde-pim@kde.org 00028 */ 00029 00030 #include "options.h" 00031 #include <kdialogbase.h> 00032 00033 class QVBoxLayout; 00034 class QHBoxLayout; 00035 class QGridLayout; 00036 00037 #ifdef USE_KHEXEDIT 00038 namespace KHE { 00039 class BytesEditInterface; 00040 } 00041 using namespace KHE; 00042 #endif 00043 00044 class QButtonGroup; 00045 class QCheckBox; 00046 class QLabel; 00047 class QLineEdit; 00048 00049 class DBRecordEditorBase; 00050 class PilotRecord; 00051 00055 class DBRecordEditor : public KDialogBase 00056 { 00057 Q_OBJECT 00058 public: 00059 DBRecordEditor(PilotRecord*r=0L, int n=-1, QWidget *parent = 0); 00060 ~DBRecordEditor(); 00061 00062 protected: 00063 QLabel* fRecordIndexLabel; 00064 QLabel* fRecordIDLabel; 00065 QLineEdit* fRecordIndex; 00066 QLineEdit* fRecordID; 00067 QButtonGroup* fFlagsGroup; 00068 QCheckBox* fDirty; 00069 QCheckBox* fDeleted; 00070 QCheckBox* fBusy; 00071 QCheckBox* fSecret; 00072 QCheckBox* fArchived; 00073 QWidget* fRecordData; 00074 #ifdef USE_KHEXEDIT 00075 KHE::BytesEditInterface*fRecordDataIf; 00076 #endif 00077 00078 protected: 00079 QGridLayout* DBRecordEditorBaseLayout; 00080 QGridLayout* fFlagsGroupLayout; 00081 00082 protected: 00083 // DBRecordEditorBase*fWidget; 00084 QWidget*fWidget; 00085 char*fBuffer; 00086 protected slots: 00087 virtual void languageChange(); 00088 protected: 00089 void initWidgets(); 00090 void fillWidgets(); 00091 PilotRecord*rec; 00092 int nr; 00093 protected slots: 00094 virtual void slotOk(); 00095 virtual void slotCancel(); 00096 }; 00097 00098 #endif