1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184
|
/***************************************************************************
rename.h - description
-------------------
begin : Sat Dec 1 2001
copyright : (C) 2001 by Richard Groult
email : rgroult@jalix.org
***************************************************************************/
/***************************************************************************
* *
* This program is free software; you can redistribute it and/or modify *
* it under the terms of the GNU General Public License as published by *
* the Free Software Foundation; either version 2 of the License, or *
* (at your option) any later version. *
* *
* This program is distributed in the hope that it will be useful, but *
* WITHOUT ANY WARRANTY; without even the implied warranty of *
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU *
* General Public License for more details. *
* *
* You should have received a copy of the GNU General Public License *
* along with this program; if not, write to the Free Software *
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 *
* USA. *
* *
* For license exceptions see LICENSE.EXC file, attached with the source *
* code. *
* *
***************************************************************************/
#ifndef __RENAMESERIES_H__
#define __RENAMESERIES_H__
#ifdef HAVE_CONFIG_H
#include <config.h>
#endif
// Qt
#include <qvariant.h>
#include <qspinbox.h>
// KDE
#include <kdatepicker.h>
#include <kdialogbase.h>
class BatchRenamer;
class ProgressDialog;
class QPopupMenu;
class QVBoxLayout;
class QHBoxLayout;
class QGridLayout;
class QSpacerItem;
class QGroupBox;
class QLabel;
class QSpinBox;
class QLineEdit;
class QPushButton;
class QCheckBox;
class QButtonGroup;
class QRadioButton;
class KDateWidget;
class QFrame;
class QListView;
class QListViewItem;
class QToolButton;
class KCompletion;
class KLineEdit;
class KConfig;
class RenameSeries : public KDialogBase
{
Q_OBJECT
public:
/**
construct a dialog to rename in series files
*/
RenameSeries( QWidget* parent = 0, const char* name = 0 );
~RenameSeries();
/**
@param filename a file to add for rename
*/
void addFile(const QString& filename);
/**
re-init all data
*/
void clear();
int exec ();
void setDateFormat(const QString& format);
QString getDateFormat();
void setTimeFormat(const QString& format);
QString getTimeFormat();
void writeConfig(KConfig *config, const QString& group);
void readConfig(KConfig *config, const QString& group);
public slots:
void slotOk();
protected:
QString getPath( const QString& fn );
bool checkErrors(bool checkDir=true);
QPopupMenu *EXIFpopup;
BatchRenamer *m_batchRenamer;
ProgressDialog *m_progressDialog;
QListViewItem *last;
QMemArray<QString*> arrayNames;
int taille;
BatchRenamer *newNames;
QListViewItem* currentItem;
QPixmap *pix;
protected:
QGroupBox* GroupBox1;
QGroupBox* GroupBox9;
QLabel* TextLabel2_2;
QSpinBox* spinIndex;
QGroupBox* groupBox4;
QLineEdit* paternLineEdit;
QPushButton* EXIFButton;
QCheckBox* overwrite;
QCheckBox* checkExtension;
QButtonGroup* ButtonGroup1;
QRadioButton* optionCopy;
QRadioButton* optionMove;
QLineEdit* dirname;
QPushButton* buttonChooseDir;
QRadioButton* optionRename;
QGroupBox* GroupBox5;
QCheckBox* CheckBox7;
KDateWidget* kDatePicker;
QFrame* Line2;
QGroupBox* groupBox5;
QListView* remanedPreviewListView;
QToolButton* moveUpPushButton;
QToolButton* moveDownPushButton;
QCheckBox* previewCheckBox;
QLabel* PixmapLabel;
QGridLayout* RenameSeriesLayout;
QGridLayout* GroupBox1Layout;
QHBoxLayout* GroupBox9Layout;
QSpacerItem* spacer12;
QGridLayout* groupBox4Layout;
QGridLayout* ButtonGroup1Layout;
QVBoxLayout* GroupBox5Layout;
QVBoxLayout* groupBox5Layout;
QHBoxLayout* layout13;
QVBoxLayout* layout12;
QVBoxLayout* layout15;
QHBoxLayout* layout14_3;
QSpacerItem* spacer6_3;
QSpacerItem* spacer4_3;
protected slots:
virtual void languageChange();
virtual void slotMoveDown();
virtual void slotMoveUp();
virtual void slotSetImagePreview(int);
virtual void slotUpdatePreview(QListViewItem*);
virtual void slotUpdateRenamed(const QString&);
virtual void slotUpdateRenamed();
void chooseDir();
void EXIFButtonClicked();
void EXIFpopupMenuClicked(int pos);
};
#endif
|