author | tille <tille> | 2002-07-30 14:37:26 (UTC) |
---|---|---|
committer | tille <tille> | 2002-07-30 14:37:26 (UTC) |
commit | 988409a5a21b3a4238ce41316e48777c885f147a (patch) (unidiff) | |
tree | 0c62baa663e715f81e936664e0775dddb96ea519 /noncore | |
parent | 0adb56cb2cd83e9933baa9776c77c4c637f93d04 (diff) | |
download | opie-988409a5a21b3a4238ce41316e48777c885f147a.zip opie-988409a5a21b3a4238ce41316e48777c885f147a.tar.gz opie-988409a5a21b3a4238ce41316e48777c885f147a.tar.bz2 |
Added -force-overwrite ipkg option
-rw-r--r-- | noncore/unsupported/oipkg/installdialog.cpp | 17 | ||||
-rw-r--r-- | noncore/unsupported/oipkg/installdialog.h | 1 | ||||
-rw-r--r-- | noncore/unsupported/oipkg/pmipkg.cpp | 2 |
3 files changed, 16 insertions, 4 deletions
diff --git a/noncore/unsupported/oipkg/installdialog.cpp b/noncore/unsupported/oipkg/installdialog.cpp index c676e84..fd93ad3 100644 --- a/noncore/unsupported/oipkg/installdialog.cpp +++ b/noncore/unsupported/oipkg/installdialog.cpp | |||
@@ -42,10 +42,10 @@ InstallDialog::InstallDialog( PackageManagerSettings* s, QWidget* parent, const | |||
42 | GroupBoxOptions->layout()->setSpacing( 0 ); | 42 | GroupBoxOptions->layout()->setSpacing( 0 ); |
43 | GroupBoxOptions->layout()->setMargin( 0 ); | 43 | GroupBoxOptions->layout()->setMargin( 0 ); |
44 | GroupBoxOptionsLayout = new QGridLayout( GroupBoxOptions->layout() ); | 44 | GroupBoxOptionsLayout = new QGridLayout( GroupBoxOptions->layout() ); |
45 | GroupBoxOptionsLayout->setAlignment( Qt::AlignTop ); | 45 | GroupBoxOptionsLayout->setAlignment( Qt::AlignTop ); |
46 | GroupBoxOptionsLayout->setSpacing( 2 ); | 46 | GroupBoxOptionsLayout->setSpacing( 0 ); |
47 | GroupBoxOptionsLayout->setMargin( 2 ); | 47 | GroupBoxOptionsLayout->setMargin( 0 ); |
48 | 48 | ||
49 | _force_depends = new QCheckBox( GroupBoxOptions, "_force_depends" ); | 49 | _force_depends = new QCheckBox( GroupBoxOptions, "_force_depends" ); |
50 | QFont _force_depends_font( _force_depends->font() ); | 50 | QFont _force_depends_font( _force_depends->font() ); |
51 | _force_depends_font.setPointSize( 8 ); | 51 | _force_depends_font.setPointSize( 8 ); |
@@ -65,13 +65,21 @@ InstallDialog::InstallDialog( PackageManagerSettings* s, QWidget* parent, const | |||
65 | 65 | ||
66 | _force_remove = new QCheckBox( GroupBoxOptions, "_force_remove" ); | 66 | _force_remove = new QCheckBox( GroupBoxOptions, "_force_remove" ); |
67 | QFont _force_remove_font( _force_remove->font() ); | 67 | QFont _force_remove_font( _force_remove->font() ); |
68 | _force_remove_font.setPointSize( 8 ); | 68 | _force_remove_font.setPointSize( 8 ); |
69 | _force_remove->setFont( _force_remove_font ); | 69 | _force_remove->setFont( _force_remove_font ); |
70 | _force_remove->setText( tr( "-force-removal-of-essential-packages" ) ); | 70 | _force_remove->setText( tr( "-force-removal-of-essential-packages" ) ); |
71 | 71 | ||
72 | GroupBoxOptionsLayout->addWidget( _force_remove, 2, 0 ); | 72 | GroupBoxOptionsLayout->addWidget( _force_remove, 2, 0 ); |
73 | 73 | ||
74 | _force_overwrite = new QCheckBox( GroupBoxOptions, "_force_overwrite" ); | ||
75 | QFont _force_overwrite_font( _force_overwrite->font() ); | ||
76 | _force_overwrite_font.setPointSize( 8 ); | ||
77 | _force_overwrite->setFont( _force_overwrite_font ); | ||
78 | _force_overwrite->setText( tr( "-force-overwrite" ) ); | ||
79 | |||
80 | GroupBoxOptionsLayout->addWidget(_force_overwrite, 3, 0 ); | ||
81 | |||
74 | InstallDialogLayout->addWidget( GroupBoxOptions, 1, 0 ); | 82 | InstallDialogLayout->addWidget( GroupBoxOptions, 1, 0 ); |
75 | toRemoveItem = new QCheckListItem( ListViewPackages, tr("To remove") ); | 83 | toRemoveItem = new QCheckListItem( ListViewPackages, tr("To remove") ); |
76 | toInstallItem = new QCheckListItem( ListViewPackages, tr("To install") ); | 84 | toInstallItem = new QCheckListItem( ListViewPackages, tr("To install") ); |
77 | 85 | ||
@@ -97,10 +105,11 @@ bool InstallDialog::event( QEvent* ev ) | |||
97 | _force_depends_font.setPointSize( 8 ); | 105 | _force_depends_font.setPointSize( 8 ); |
98 | _force_depends->setFont( _force_depends_font ); | 106 | _force_depends->setFont( _force_depends_font ); |
99 | QFont _force_reinstall_font( _force_reinstall->font() ); | 107 | QFont _force_reinstall_font( _force_reinstall->font() ); |
100 | _force_reinstall_font.setPointSize( 8 ); | 108 | _force_reinstall_font.setPointSize( 8 ); |
101 | _force_reinstall->setFont( _force_reinstall_font ); | 109 | _force_reinstall->setFont( _force_reinstall_font ); |
102 | QFont _force_remove_font( _force_remove->font() ); | 110 | QFont _force_remove_font( _force_remove->font() ); |
111 | QFont _force_overwrite_font( _force_overwrite->font() ); | ||
103 | _force_remove_font.setPointSize( 8 ); | 112 | _force_remove_font.setPointSize( 8 ); |
104 | _force_remove->setFont( _force_remove_font ); | 113 | _force_remove->setFont( _force_remove_font ); |
105 | } | 114 | } |
106 | return ret; | 115 | return ret; |
diff --git a/noncore/unsupported/oipkg/installdialog.h b/noncore/unsupported/oipkg/installdialog.h index 828c8df..d3510ff 100644 --- a/noncore/unsupported/oipkg/installdialog.h +++ b/noncore/unsupported/oipkg/installdialog.h | |||
@@ -34,8 +34,9 @@ public: InstallDialog( PackageManagerSettings* s, QWidget* parent = 0, const | |||
34 | PackageListView* ListViewPackages; | 34 | PackageListView* ListViewPackages; |
35 | QGroupBox* GroupBoxOptions; | 35 | QGroupBox* GroupBoxOptions; |
36 | QCheckBox* _force_depends; | 36 | QCheckBox* _force_depends; |
37 | QCheckBox* _force_reinstall; | 37 | QCheckBox* _force_reinstall; |
38 | QCheckBox* _force_overwrite; | ||
38 | QCheckBox* _force_remove; | 39 | QCheckBox* _force_remove; |
39 | QCheckListItem *toRemoveItem; | 40 | QCheckListItem *toRemoveItem; |
40 | QCheckListItem *toInstallItem; | 41 | QCheckListItem *toInstallItem; |
41 | 42 | ||
diff --git a/noncore/unsupported/oipkg/pmipkg.cpp b/noncore/unsupported/oipkg/pmipkg.cpp index 84de67b..2ed313c 100644 --- a/noncore/unsupported/oipkg/pmipkg.cpp +++ b/noncore/unsupported/oipkg/pmipkg.cpp | |||
@@ -74,8 +74,10 @@ bool PmIpkg::runIpkg(const QString& args, const QString& dest ) | |||
74 | if (installDialog->_force_reinstall->isChecked()) | 74 | if (installDialog->_force_reinstall->isChecked()) |
75 | cmd += " -force-reinstall "; | 75 | cmd += " -force-reinstall "; |
76 | if (installDialog->_force_remove->isChecked()) | 76 | if (installDialog->_force_remove->isChecked()) |
77 | cmd += " -force-removal-of-essential-packages "; | 77 | cmd += " -force-removal-of-essential-packages "; |
78 | if (installDialog->_force_overwrite->isChecked()) | ||
79 | cmd += " -force-overwrite "; | ||
78 | } | 80 | } |
79 | } //!args.contains("update") | 81 | } //!args.contains("update") |
80 | 82 | ||
81 | out( "Starting to "+ args+"\n"); | 83 | out( "Starting to "+ args+"\n"); |