#include #include /**************************************************************************** ** Form implementation generated from reading ui file '/home/oliver/work/programming/kyammi/src/UpdateDatabaseDialogBase.ui' ** ** Created: Sun Jul 31 13:19:46 2005 ** by: The User Interface Compiler ($Id: qt/main.cpp 3.3.4 edited Nov 24 2003 $) ** ** WARNING! All changes made in this file will be lost! ****************************************************************************/ #include "UpdateDatabaseDialogBase.h" #include #include #include #include #include #include #include #include #include #include /* * Constructs a UpdateDatabaseDialogBase as a child of 'parent', with the * name 'name' and widget flags set to 'f'. * * The dialog will by default be modeless, unless you set 'modal' to * TRUE to construct a modal dialog. */ UpdateDatabaseDialogBase::UpdateDatabaseDialogBase( QWidget* parent, const char* name, bool modal, WFlags fl ) : QDialog( parent, name, modal, fl ) { if ( !name ) setName( "UpdateDatabaseDialogBase" ); setSizeGripEnabled( TRUE ); UpdateDatabaseDialogBaseLayout = new QGridLayout( this, 1, 1, 11, 6, "UpdateDatabaseDialogBaseLayout"); PushButtonOk = new QPushButton( this, "PushButtonOk" ); PushButtonOk->setSizePolicy( QSizePolicy( (QSizePolicy::SizeType)7, (QSizePolicy::SizeType)0, 0, 0, PushButtonOk->sizePolicy().hasHeightForWidth() ) ); UpdateDatabaseDialogBaseLayout->addWidget( PushButtonOk, 4, 0 ); ButtonChooseScanDir = new QPushButton( this, "ButtonChooseScanDir" ); UpdateDatabaseDialogBaseLayout->addWidget( ButtonChooseScanDir, 1, 2 ); LineEditFilePattern = new QLineEdit( this, "LineEditFilePattern" ); UpdateDatabaseDialogBaseLayout->addWidget( LineEditFilePattern, 2, 1 ); LineEditScanDir = new QLineEdit( this, "LineEditScanDir" ); UpdateDatabaseDialogBaseLayout->addWidget( LineEditScanDir, 1, 1 ); LabelScanDir = new QLabel( this, "LabelScanDir" ); UpdateDatabaseDialogBaseLayout->addWidget( LabelScanDir, 1, 0 ); TextLabel1 = new QLabel( this, "TextLabel1" ); TextLabel1->setSizePolicy( QSizePolicy( (QSizePolicy::SizeType)5, (QSizePolicy::SizeType)4, 0, 0, TextLabel1->sizePolicy().hasHeightForWidth() ) ); QFont TextLabel1_font( TextLabel1->font() ); TextLabel1_font.setBold( TRUE ); TextLabel1_font.setItalic( TRUE ); TextLabel1->setFont( TextLabel1_font ); UpdateDatabaseDialogBaseLayout->addMultiCellWidget( TextLabel1, 0, 0, 0, 2 ); LabelFilePattern = new QLabel( this, "LabelFilePattern" ); UpdateDatabaseDialogBaseLayout->addWidget( LabelFilePattern, 2, 0 ); PushButtonCancel = new QPushButton( this, "PushButtonCancel" ); PushButtonCancel->setSizePolicy( QSizePolicy( (QSizePolicy::SizeType)7, (QSizePolicy::SizeType)0, 0, 0, PushButtonCancel->sizePolicy().hasHeightForWidth() ) ); UpdateDatabaseDialogBaseLayout->addMultiCellWidget( PushButtonCancel, 4, 4, 1, 2 ); CheckBoxFollowSymlinks = new QCheckBox( this, "CheckBoxFollowSymlinks" ); CheckBoxFollowSymlinks->setEnabled( TRUE ); UpdateDatabaseDialogBaseLayout->addMultiCellWidget( CheckBoxFollowSymlinks, 3, 3, 0, 1 ); languageChange(); resize( QSize(433, 266).expandedTo(minimumSizeHint()) ); clearWState( WState_Polished ); // signals and slots connections connect( PushButtonOk, SIGNAL( clicked() ), this, SLOT( accept() ) ); connect( PushButtonCancel, SIGNAL( clicked() ), this, SLOT( reject() ) ); // tab order setTabOrder( LineEditScanDir, ButtonChooseScanDir ); setTabOrder( ButtonChooseScanDir, LineEditFilePattern ); setTabOrder( LineEditFilePattern, CheckBoxFollowSymlinks ); setTabOrder( CheckBoxFollowSymlinks, PushButtonOk ); setTabOrder( PushButtonOk, PushButtonCancel ); } /* * Destroys the object and frees any allocated resources */ UpdateDatabaseDialogBase::~UpdateDatabaseDialogBase() { // no need to delete child widgets, Qt does it all for us } /* * Sets the strings of the subwidgets using the current * language. */ void UpdateDatabaseDialogBase::languageChange() { setCaption( tr2i18n( "Update Database - Scan Harddisk" ) ); PushButtonOk->setText( tr2i18n( "Start Scan..." ) ); ButtonChooseScanDir->setText( tr2i18n( "..." ) ); QToolTip::add( ButtonChooseScanDir, tr2i18n( "choose directory" ) ); QToolTip::add( LineEditFilePattern, tr2i18n( "filename pattern (eg. \"*.mp3 *.ogg\")" ) ); QToolTip::add( LineEditScanDir, tr2i18n( "yammi will search in this directory (and recursive in all subdirectories) for new song files" ) ); LabelScanDir->setText( tr2i18n( "base directory for scanning" ) ); QToolTip::add( LabelScanDir, tr2i18n( "yammi will search in this directory (and recursive in all subdirectories) for new song files" ) ); TextLabel1->setText( tr2i18n( "Options for scanning your harddisk" ) ); LabelFilePattern->setText( tr2i18n( "pattern of files to import" ) ); QToolTip::add( LabelFilePattern, tr2i18n( "filename pattern (eg. \"*.mp3 *.ogg\")" ) ); PushButtonCancel->setText( tr2i18n( "Cancel" ) ); CheckBoxFollowSymlinks->setText( tr2i18n( "follow symbolic links" ) ); QToolTip::add( CheckBoxFollowSymlinks, tr2i18n( "Choose whether yammi should follow symbolic links when traversing the directory structure" ) ); } #include "UpdateDatabaseDialogBase.moc"