author | harlekin <harlekin> | 2002-11-04 20:06:58 (UTC) |
---|---|---|
committer | harlekin <harlekin> | 2002-11-04 20:06:58 (UTC) |
commit | 222d1d8b75494d520b5373fbaf64518afcdfcf89 (patch) (side-by-side diff) | |
tree | 77faff83517567d4a8ce562a644f8582b57e8737 | |
parent | 3c2605811571b5c8ccfbe2bdb1a03ec7a9c9f1c1 (diff) | |
download | opie-222d1d8b75494d520b5373fbaf64518afcdfcf89.zip opie-222d1d8b75494d520b5373fbaf64518afcdfcf89.tar.gz opie-222d1d8b75494d520b5373fbaf64518afcdfcf89.tar.bz2 |
removed extra buttons - why double when they are in the titelbar
-rw-r--r-- | core/launcher/mediummountgui.cpp | 24 | ||||
-rw-r--r-- | core/launcher/mediummountgui.h | 8 |
2 files changed, 9 insertions, 23 deletions
diff --git a/core/launcher/mediummountgui.cpp b/core/launcher/mediummountgui.cpp index 6d60ce4..b0a1b10 100644 --- a/core/launcher/mediummountgui.cpp +++ b/core/launcher/mediummountgui.cpp @@ -144,7 +144,7 @@ void MediumMountGui::startGui() { connect( CheckBoxAll, SIGNAL( clicked() ), this, SLOT( deactivateOthers() ) ); QVBox* dirBox = new QVBox( this ); - dirBox->setMargin( 4 ); + dirBox->setMargin( 5 ); // select dirs DirSelectText = new QLabel( dirBox, "DirSelectText" ); @@ -154,6 +154,7 @@ void MediumMountGui::startGui() { LineEdit1 = new QLineEdit( dirLineBox ); PushButton3 = new QPushButton( dirLineBox ); PushButton3->setText( tr( "Add" ) ); + PushButton3->setFocus(); // decision DirSelectText_2 = new QLabel( dirBox ); @@ -171,20 +172,9 @@ void MediumMountGui::startGui() { CheckBoxAll->setChecked( checkmimeall ); deactivateOthers(); - QHBox* buttonBox = new QHBox( this ); - // buttons - quit = new QPushButton( buttonBox ); - quit->setFocus(); - quit->setText( tr( "Yes" ) ); - quit_2 = new QPushButton( buttonBox ); - quit_2->setText( tr( "No" ) ); - mainLayout->addWidget( GroupBox1 ); mainLayout->addWidget( dirBox ); - mainLayout->addWidget( buttonBox ); - - connect( quit, SIGNAL( clicked() ), this, SLOT( yesPressed() ) ); - connect( quit_2, SIGNAL( clicked() ), this, SLOT( noPressed() ) ); + mainLayout->addStretch( 0 ); } @@ -196,10 +186,10 @@ void MediumMountGui::deactivateOthers() { CheckBoxImage->setEnabled( mod ); } -void MediumMountGui::yesPressed() { +void MediumMountGui::accept() { writeConfig( true ); // and do something - accept(); + QDialog::accept(); } @@ -207,9 +197,9 @@ QStringList MediumMountGui::mimeTypes() { return mimeTypeList; } -void MediumMountGui::noPressed() { +void MediumMountGui::reject() { writeConfig( false ); - reject(); + QDialog::reject(); } MediumMountGui::~MediumMountGui() { diff --git a/core/launcher/mediummountgui.h b/core/launcher/mediummountgui.h index 39f9a52..d5c0fe7 100644 --- a/core/launcher/mediummountgui.h +++ b/core/launcher/mediummountgui.h @@ -22,8 +22,6 @@ public: ~MediumMountGui(); protected: - QPushButton* quit; - QPushButton* quit_2; QLabel* DirSelectText_2; QLineEdit* LineEdit1; QPushButton* PushButton3; @@ -39,7 +37,6 @@ protected: QCheckBox* CheckBoxLink; QCheckBox* AskBox; - public: bool check(); QStringList mimeTypes(); @@ -50,12 +47,11 @@ private: void writeConfig( bool checkagain ); private slots: - void yesPressed(); - void noPressed(); + void accept(); + void reject(); void deactivateOthers(); private: QString mediumPath; - bool checkagain:1; bool checkmimeaudio:1; bool checkmimeimage:1; |