#include "simapi.h" /**************************************************************************** ** Form implementation generated from reading ui file './gpggenbase.ui' ** ** Created: Вск Мар 4 15:40:46 2007 ** by: The User Interface Compiler ($Id: qt/main.cpp 3.3.7 edited Aug 31 2005 $) ** ** WARNING! All changes made in this file will be lost! ****************************************************************************/ #include "gpggenbase.h" #include #include #include #include #include #include #include #include /* * Constructs a GpgGenBase 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. */ GpgGenBase::GpgGenBase( QWidget* parent, const char* name, bool modal, WFlags fl ) : QDialog( parent, name, modal, fl ) { if ( !name ) setName( "GpgGen" ); setProperty( "sizeGripEnabled", QVariant( TRUE, 0 ) ); GpgGenLayout = new QGridLayout( this, 1, 1, 11, 6, "GpgGenLayout"); TextLabel3 = new QLabel( this, "TextLabel3" ); TextLabel3->setProperty( "alignment", int( QLabel::AlignVCenter | QLabel::AlignRight ) ); GpgGenLayout->addWidget( TextLabel3, 1, 0 ); TextLabel4 = new QLabel( this, "TextLabel4" ); TextLabel4->setProperty( "alignment", int( QLabel::AlignVCenter | QLabel::AlignRight ) ); GpgGenLayout->addWidget( TextLabel4, 2, 0 ); TextLabel2 = new QLabel( this, "TextLabel2" ); TextLabel2->setProperty( "alignment", int( QLabel::AlignVCenter | QLabel::AlignRight ) ); GpgGenLayout->addWidget( TextLabel2, 0, 0 ); edtName = new QLineEdit( this, "edtName" ); GpgGenLayout->addWidget( edtName, 0, 1 ); edtComment = new QLineEdit( this, "edtComment" ); GpgGenLayout->addWidget( edtComment, 2, 1 ); cmbMail = new QComboBox( FALSE, this, "cmbMail" ); GpgGenLayout->addWidget( cmbMail, 1, 1 ); TextLabel1 = new QLabel( this, "TextLabel1" ); TextLabel1->setProperty( "alignment", int( QLabel::AlignVCenter | QLabel::AlignRight ) ); GpgGenLayout->addWidget( TextLabel1, 3, 0 ); TextLabel2_2 = new QLabel( this, "TextLabel2_2" ); TextLabel2_2->setProperty( "alignment", int( QLabel::AlignVCenter | QLabel::AlignRight ) ); GpgGenLayout->addWidget( TextLabel2_2, 4, 0 ); edtPass1 = new QLineEdit( this, "edtPass1" ); edtPass1->setProperty( "echoMode", "Password" ); GpgGenLayout->addWidget( edtPass1, 3, 1 ); edtPass2 = new QLineEdit( this, "edtPass2" ); edtPass2->setProperty( "echoMode", "Password" ); GpgGenLayout->addWidget( edtPass2, 4, 1 ); lblProcess = new QLabel( this, "lblProcess" ); lblProcess->setProperty( "sizePolicy", QSizePolicy( (QSizePolicy::SizeType)7, (QSizePolicy::SizeType)7, 0, 0, lblProcess->sizePolicy().hasHeightForWidth() ) ); lblProcess->setProperty( "alignment", int( QLabel::AlignCenter ) ); GpgGenLayout->addMultiCellWidget( lblProcess, 5, 5, 0, 1 ); Layout1 = new QHBoxLayout( 0, 0, 6, "Layout1"); Horizontal_Spacing2 = new QSpacerItem( 20, 20, QSizePolicy::Expanding, QSizePolicy::Minimum ); Layout1->addItem( Horizontal_Spacing2 ); buttonOk = new QPushButton( this, "buttonOk" ); buttonOk->setProperty( "autoDefault", QVariant( TRUE, 0 ) ); buttonOk->setProperty( "default", QVariant( TRUE, 0 ) ); Layout1->addWidget( buttonOk ); buttonCancel = new QPushButton( this, "buttonCancel" ); buttonCancel->setProperty( "autoDefault", QVariant( TRUE, 0 ) ); Layout1->addWidget( buttonCancel ); GpgGenLayout->addMultiCellLayout( Layout1, 6, 6, 0, 1 ); languageChange(); resize( QSize(385, 241).expandedTo(minimumSizeHint()) ); clearWState( WState_Polished ); // signals and slots connections connect( buttonOk, SIGNAL( clicked() ), this, SLOT( accept() ) ); connect( buttonCancel, SIGNAL( clicked() ), this, SLOT( reject() ) ); // tab order setTabOrder( edtName, cmbMail ); setTabOrder( cmbMail, edtComment ); setTabOrder( edtComment, edtPass1 ); setTabOrder( edtPass1, edtPass2 ); setTabOrder( edtPass2, buttonOk ); setTabOrder( buttonOk, buttonCancel ); } /* * Destroys the object and frees any allocated resources */ GpgGenBase::~GpgGenBase() { // no need to delete child widgets, Qt does it all for us } /* * Sets the strings of the subwidgets using the current * language. */ void GpgGenBase::languageChange() { setProperty( "caption", i18n( "Generate key" ) ); TextLabel3->setProperty( "text", i18n( "EMail:" ) ); TextLabel4->setProperty( "text", i18n( "Comment:" ) ); TextLabel2->setProperty( "text", i18n( "Name:" ) ); TextLabel1->setProperty( "text", i18n( "Passphrase:" ) ); TextLabel2_2->setProperty( "text", i18n( "Retype passphrase:" ) ); lblProcess->setProperty( "text", QString::null ); buttonOk->setProperty( "text", i18n( "&OK" ) ); buttonCancel->setProperty( "text", i18n( "&Cancel" ) ); } #include "gpggenbase.moc"