summaryrefslogtreecommitdiff
path: root/noncore/settings/aqpkg/instoptionsimpl.cpp
Unidiff
Diffstat (limited to 'noncore/settings/aqpkg/instoptionsimpl.cpp') (more/less context) (ignore whitespace changes)
-rw-r--r--noncore/settings/aqpkg/instoptionsimpl.cpp37
1 files changed, 33 insertions, 4 deletions
diff --git a/noncore/settings/aqpkg/instoptionsimpl.cpp b/noncore/settings/aqpkg/instoptionsimpl.cpp
index 3a37eec..47b250d 100644
--- a/noncore/settings/aqpkg/instoptionsimpl.cpp
+++ b/noncore/settings/aqpkg/instoptionsimpl.cpp
@@ -10,34 +10,63 @@
10 * * 10 * *
11 * This program is free software; you can redistribute it and/or modify * 11 * This program is free software; you can redistribute it and/or modify *
12 * it under the terms of the GNU General Public License as published by * 12 * it under the terms of the GNU General Public License as published by *
13 * the Free Software Foundation; either version 2 of the License, or * 13 * the Free Software Foundation; either version 2 of the License, or *
14 * (at your option) any later version. * 14 * (at your option) any later version. *
15 * * 15 * *
16 ***************************************************************************/ 16 ***************************************************************************/
17 17
18#ifdef QWS 18#ifdef QWS
19#include <qpe/config.h> 19#include <qpe/config.h>
20#endif 20#endif
21 21
22#include <qdialog.h>
23#include <qcheckbox.h> 22#include <qcheckbox.h>
23#include <qgroupbox.h>
24#include <qlayout.h>
24 25
26#include "global.h"
25#include "instoptionsimpl.h" 27#include "instoptionsimpl.h"
26#include "ipkg.h" 28#include "ipkg.h"
27#include "global.h"
28 29
29InstallOptionsDlgImpl::InstallOptionsDlgImpl( int flags, QWidget * parent, const char* name, bool modal, WFlags fl ) 30InstallOptionsDlgImpl::InstallOptionsDlgImpl( int flags, QWidget * parent, const char* name, bool modal, WFlags fl )
30 : InstallOptionsDlg( parent, name, modal, fl ) 31 : QDialog( parent, name, modal, fl )
31{ 32{
33 setCaption( tr( "Options" ) );
34
35 QVBoxLayout *layout = new QVBoxLayout( this );
36 layout->setMargin( 2 );
37 layout->setSpacing( 4 );
38
39 QGroupBox *grpbox = new QGroupBox( 0, Qt::Vertical, tr( "Options" ), this );
40 grpbox->layout()->setSpacing( 2 );
41 grpbox->layout()->setMargin( 4 );
42 layout->addWidget( grpbox );
43
44 QVBoxLayout *grplayout = new QVBoxLayout( grpbox->layout() );
45
46 forceDepends = new QCheckBox( tr( "Force Depends" ), grpbox );
47 grplayout->addWidget( forceDepends );
48
49 forceReinstall = new QCheckBox( tr( "Force Reinstall" ), grpbox );
50 grplayout->addWidget( forceReinstall );
51
52 forceRemove = new QCheckBox( tr( "Force Remove" ), grpbox );
53 grplayout->addWidget( forceRemove );
54
55 forceOverwrite = new QCheckBox( tr( "Force Overwrite" ), grpbox );
56 grplayout->addWidget( forceOverwrite );
57
58 verboseWget = new QCheckBox( tr( "Verbose WGet" ), grpbox );
59 grplayout->addWidget( verboseWget );
60
32 if ( flags & FORCE_DEPENDS ) 61 if ( flags & FORCE_DEPENDS )
33 forceDepends->setChecked( true ); 62 forceDepends->setChecked( true );
34 if ( flags & FORCE_REINSTALL ) 63 if ( flags & FORCE_REINSTALL )
35 forceReinstall->setChecked( true ); 64 forceReinstall->setChecked( true );
36 if ( flags & FORCE_REMOVE ) 65 if ( flags & FORCE_REMOVE )
37 forceRemove->setChecked( true ); 66 forceRemove->setChecked( true );
38 if ( flags & FORCE_OVERWRITE ) 67 if ( flags & FORCE_OVERWRITE )
39 forceOverwrite->setChecked( true ); 68 forceOverwrite->setChecked( true );
40 if ( flags & VERBOSE_WGET ) 69 if ( flags & VERBOSE_WGET )
41 verboseWget->setChecked( true ); 70 verboseWget->setChecked( true );
42// if ( flags & MAKE_LINKS ) 71// if ( flags & MAKE_LINKS )
43 // makeLinks->setChecked( true ); 72 // makeLinks->setChecked( true );
@@ -58,13 +87,13 @@ int InstallOptionsDlgImpl :: getFlags()
58 if ( forceDepends->isChecked() ) 87 if ( forceDepends->isChecked() )
59 flags |= FORCE_DEPENDS; 88 flags |= FORCE_DEPENDS;
60 if ( forceReinstall->isChecked() ) 89 if ( forceReinstall->isChecked() )
61 flags |= FORCE_REINSTALL; 90 flags |= FORCE_REINSTALL;
62 if ( forceRemove->isChecked() ) 91 if ( forceRemove->isChecked() )
63 flags |= FORCE_REMOVE; 92 flags |= FORCE_REMOVE;
64 if ( forceOverwrite->isChecked() ) 93 if ( forceOverwrite->isChecked() )
65 flags |= FORCE_OVERWRITE; 94 flags |= FORCE_OVERWRITE;
66 if ( verboseWget->isChecked() ) 95 if ( verboseWget->isChecked() )
67 flags |= VERBOSE_WGET; 96 flags |= VERBOSE_WGET;
68 97
69 return flags; 98 return flags;
70} \ No newline at end of file 99}