copytodlgbase.cpp
Go to the documentation of this file.00001 #include <kdialog.h>
00002 #include <klocale.h>
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012 #include "copytodlgbase.h"
00013
00014 #include <qvariant.h>
00015 #include <qpushbutton.h>
00016 #include <qlabel.h>
00017 #include <qlistbox.h>
00018 #include <klineedit.h>
00019 #include <qbuttongroup.h>
00020 #include <qradiobutton.h>
00021 #include <qlayout.h>
00022 #include <qtooltip.h>
00023 #include <qwhatsthis.h>
00024
00025
00026
00027
00028
00029
00030
00031
00032 CopyToDialogBase::CopyToDialogBase( QWidget* parent, const char* name, bool modal, WFlags fl )
00033 : QDialog( parent, name, modal, fl )
00034 {
00035 if ( !name )
00036 setName( "CopyToDialogBase" );
00037 CopyToDialogBaseLayout = new QVBoxLayout( this, 11, 6, "CopyToDialogBaseLayout");
00038
00039 textLabel1 = new QLabel( this, "textLabel1" );
00040 CopyToDialogBaseLayout->addWidget( textLabel1 );
00041
00042 fileList = new QListBox( this, "fileList" );
00043 CopyToDialogBaseLayout->addWidget( fileList );
00044
00045 textLabel2 = new QLabel( this, "textLabel2" );
00046 CopyToDialogBaseLayout->addWidget( textLabel2 );
00047
00048 layout2 = new QHBoxLayout( 0, 0, 6, "layout2");
00049
00050 url_line = new KLineEdit( this, "url_line" );
00051 layout2->addWidget( url_line );
00052
00053 url_button = new QPushButton( this, "url_button" );
00054 layout2->addWidget( url_button );
00055 CopyToDialogBaseLayout->addLayout( layout2 );
00056
00057 buttonGroup1 = new QButtonGroup( this, "buttonGroup1" );
00058 buttonGroup1->setColumnLayout(0, Qt::Vertical );
00059 buttonGroup1->layout()->setSpacing( 6 );
00060 buttonGroup1->layout()->setMargin( 11 );
00061 buttonGroup1Layout = new QVBoxLayout( buttonGroup1->layout() );
00062 buttonGroup1Layout->setAlignment( Qt::AlignTop );
00063
00064 traditional = new QRadioButton( buttonGroup1, "traditional" );
00065 traditional->setChecked( TRUE );
00066 buttonGroup1Layout->addWidget( traditional );
00067
00068 relative = new QRadioButton( buttonGroup1, "relative" );
00069 buttonGroup1Layout->addWidget( relative );
00070 CopyToDialogBaseLayout->addWidget( buttonGroup1 );
00071
00072 layout1 = new QHBoxLayout( 0, 0, 6, "layout1");
00073 spacer1 = new QSpacerItem( 101, 20, QSizePolicy::Expanding, QSizePolicy::Minimum );
00074 layout1->addItem( spacer1 );
00075
00076 okbutton = new QPushButton( this, "okbutton" );
00077 layout1->addWidget( okbutton );
00078
00079 cancelbutton = new QPushButton( this, "cancelbutton" );
00080 layout1->addWidget( cancelbutton );
00081 CopyToDialogBaseLayout->addLayout( layout1 );
00082 languageChange();
00083 resize( QSize(291, 356).expandedTo(minimumSizeHint()) );
00084 clearWState( WState_Polished );
00085
00086
00087 connect( cancelbutton, SIGNAL( clicked() ), this, SLOT( reject() ) );
00088 connect( okbutton, SIGNAL( clicked() ), this, SLOT( accept() ) );
00089 }
00090
00091
00092
00093
00094 CopyToDialogBase::~CopyToDialogBase()
00095 {
00096
00097 }
00098
00099
00100
00101
00102
00103 void CopyToDialogBase::languageChange()
00104 {
00105 setCaption( tr2i18n( "Copy To" ) );
00106 textLabel1->setText( tr2i18n( "Files to copy:" ) );
00107 textLabel2->setText( tr2i18n( "Destination:" ) );
00108 url_button->setText( tr2i18n( "..." ) );
00109 buttonGroup1->setTitle( tr2i18n( "Copy Mode" ) );
00110 QWhatsThis::add( buttonGroup1, tr2i18n( "Traditional means like 'cp' - all the files goes to the same target directory. \\nRelative means that the local project relative path will be appended to the target path." ) );
00111 traditional->setText( tr2i18n( "Traditional" ) );
00112 relative->setText( tr2i18n( "Relative" ) );
00113 okbutton->setText( tr2i18n( "&OK" ) );
00114 cancelbutton->setText( tr2i18n( "&Cancel" ) );
00115 }
00116
00117 #include "copytodlgbase.moc"
This file is part of the documentation for KDevelop Version 3.1.2.