summaryrefslogtreecommitdiff
Unidiff
Diffstat (more/less context) (ignore whitespace changes)
-rw-r--r--noncore/unsupported/oipkg/mainwindow.cpp35
-rw-r--r--noncore/unsupported/oipkg/pmipkg.cpp21
-rw-r--r--noncore/unsupported/oipkg/utils.cpp9
-rw-r--r--noncore/unsupported/oipkg/utils.h9
4 files changed, 37 insertions, 37 deletions
diff --git a/noncore/unsupported/oipkg/mainwindow.cpp b/noncore/unsupported/oipkg/mainwindow.cpp
index 084900d..53db477 100644
--- a/noncore/unsupported/oipkg/mainwindow.cpp
+++ b/noncore/unsupported/oipkg/mainwindow.cpp
@@ -62,15 +62,9 @@ MainWindow::MainWindow( QWidget *parent, const char *name, WFlags f ) :
62 packageListServers.update(); 62 packageListServers.update();
63 pvDebug(9,"packageListDocLnk.update"); 63 pvDebug(9,"packageListDocLnk.update");
64 pvDebug(0,"no UPDATE of DocLnk");
65 packageListDocLnk.update(); 64 packageListDocLnk.update();
66 pvDebug(9,"makeMenu"); 65 pvDebug(9,"makeMenu");
67 makeMenu(); 66 makeMenu();
68 makeChannel(); 67 makeChannel();
69 //opie is hardcoded default ;) 68
70 //pvDebug(9,"section->setCurrentItem");
71// for (int i=0;i<section->count();i++)
72 // if (section->text(i)=="opie")
73 // section->setCurrentItem(i);
74// sectionChanged();
75 69
76 connect( section, SIGNAL(activated(int)), SLOT(sectionChanged()) ); 70 connect( section, SIGNAL(activated(int)), SLOT(sectionChanged()) );
@@ -152,10 +146,16 @@ void MainWindow::makeMenu()
152 addToolBar( sectionBar, "Section", QMainWindow::Top, TRUE ); 146 addToolBar( sectionBar, "Section", QMainWindow::Top, TRUE );
153 sectionBar->setHorizontalStretchable( true ); 147 sectionBar->setHorizontalStretchable( true );
154 QLabel *label = new QLabel( tr("Section: "), sectionBar ); 148 QLabel *label = new QLabel( sectionBar, "section" );
155 label->setBackgroundColor( sectionBar->backgroundColor() ); 149// label->setBackgroundMode( NoBackground );
150 label->font().setPointSize( 8 );
151 label->setText( tr( "Section:" ) );
152 sectionBar->setStretchableWidget( label );
156 section = new QComboBox( false, sectionBar ); 153 section = new QComboBox( false, sectionBar );
154 section->font().setPointSize( 8 );
157 label = new QLabel( " / ", sectionBar ); 155 label = new QLabel( " / ", sectionBar );
158 label->setBackgroundColor( sectionBar->backgroundColor() ); 156 label->font().setPointSize( 8 );
157// label->setBackgroundMode( PaletteForeground );
159 subsection = new QComboBox( false, sectionBar ); 158 subsection = new QComboBox( false, sectionBar );
159 subsection->font().setPointSize( 8 );
160 a = new QAction( tr( "Close Section" ), Resource::loadPixmap( "close" ), QString::null, 0, this, 0 ); 160 a = new QAction( tr( "Close Section" ), Resource::loadPixmap( "close" ), QString::null, 0, this, 0 );
161 connect( a, SIGNAL( activated() ), this, SLOT( sectionClose() ) ); 161 connect( a, SIGNAL( activated() ), this, SLOT( sectionClose() ) );
@@ -167,5 +167,5 @@ void MainWindow::makeMenu()
167 sectionAction->setToggleAction( true ); 167 sectionAction->setToggleAction( true );
168 sectionAction->addTo( viewMenu ); 168 sectionAction->addTo( viewMenu );
169 sectionBar->setStretchableWidget( section ); 169 // sectionBar->setStretchableWidget( section );
170 170
171 //FIND 171 //FIND
@@ -173,5 +173,5 @@ void MainWindow::makeMenu()
173 addToolBar( findBar, "Filter", QMainWindow::Top, TRUE ); 173 addToolBar( findBar, "Filter", QMainWindow::Top, TRUE );
174 label = new QLabel( tr("Filter: "), findBar ); 174 label = new QLabel( tr("Filter: "), findBar );
175 label->setBackgroundColor( findBar->backgroundColor() ); 175// label->setBackgroundMode( PaletteForeground );
176 findBar->setHorizontalStretchable( TRUE ); 176 findBar->setHorizontalStretchable( TRUE );
177 findEdit = new QLineEdit( findBar, "findEdit" ); 177 findEdit = new QLineEdit( findBar, "findEdit" );
@@ -194,5 +194,5 @@ void MainWindow::makeMenu()
194 addToolBar( searchBar, "Search", QMainWindow::Top, TRUE ); 194 addToolBar( searchBar, "Search", QMainWindow::Top, TRUE );
195 label = new QLabel( tr("ipkgfind: "), searchBar ); 195 label = new QLabel( tr("ipkgfind: "), searchBar );
196 label->setBackgroundColor( searchBar->backgroundColor() ); 196// label->setBackgroundMode( PaletteForeground );
197 searchBar->setHorizontalStretchable( TRUE ); 197 searchBar->setHorizontalStretchable( TRUE );
198 searchEdit = new QLineEdit( searchBar, "seachEdit" ); 198 searchEdit = new QLineEdit( searchBar, "seachEdit" );
@@ -218,5 +218,5 @@ void MainWindow::makeMenu()
218 addToolBar( destBar, "Destination", QMainWindow::Top, TRUE ); 218 addToolBar( destBar, "Destination", QMainWindow::Top, TRUE );
219 label = new QLabel( tr("Destination: "), destBar ); 219 label = new QLabel( tr("Destination: "), destBar );
220 label->setBackgroundColor( destBar->backgroundColor() ); 220// label->setBackgroundMode( PaletteForeground );
221 destBar->setHorizontalStretchable( TRUE ); 221 destBar->setHorizontalStretchable( TRUE );
222 destination = new QComboBox( false, destBar ); 222 destination = new QComboBox( false, destBar );
@@ -226,7 +226,7 @@ void MainWindow::makeMenu()
226 settings, SLOT(activeDestinationChange(int)) ); 226 settings, SLOT(activeDestinationChange(int)) );
227 spacer = new QLabel( " ", destBar ); 227 spacer = new QLabel( " ", destBar );
228 spacer->setBackgroundColor( destBar->backgroundColor() ); 228// spacer->setBackgroundMode( PaletteForeground );
229 CheckBoxLink = new QCheckBox( tr("Link"), destBar); 229 CheckBoxLink = new QCheckBox( tr("Link"), destBar);
230 CheckBoxLink->setBackgroundColor( destBar->backgroundColor() ); 230// CheckBoxLink->setBackgroundMode( PaletteForeground );
231 CheckBoxLink->setChecked( settings->createLinks() ); 231 CheckBoxLink->setChecked( settings->createLinks() );
232 connect( CheckBoxLink, SIGNAL(toggled(bool)), 232 connect( CheckBoxLink, SIGNAL(toggled(bool)),
@@ -286,4 +286,6 @@ void MainWindow::makeMenu()
286 sectionShow( cfg.readBoolEntry( "sectionBar", true ) ); 286 sectionShow( cfg.readBoolEntry( "sectionBar", true ) );
287 destShow( cfg.readBoolEntry( "destBar", false ) ); 287 destShow( cfg.readBoolEntry( "destBar", false ) );
288 setComboName(section,cfg.readEntry("default_section"));
289 sectionChanged();
288} 290}
289 291
@@ -296,4 +298,5 @@ MainWindow::~MainWindow()
296 cfg.writeEntry( "sectionBar", !sectionBar->isHidden() ); 298 cfg.writeEntry( "sectionBar", !sectionBar->isHidden() );
297 cfg.writeEntry( "destBar", !destBar->isHidden() ); 299 cfg.writeEntry( "destBar", !destBar->isHidden() );
300 cfg.writeEntry( "default_section", section->currentText() );
298 301
299} 302}
diff --git a/noncore/unsupported/oipkg/pmipkg.cpp b/noncore/unsupported/oipkg/pmipkg.cpp
index de1f162..4a8a389 100644
--- a/noncore/unsupported/oipkg/pmipkg.cpp
+++ b/noncore/unsupported/oipkg/pmipkg.cpp
@@ -68,4 +68,5 @@ bool PmIpkg::runIpkg(const QString& args, const QString& dest )
68 QString cmd = "/usr/bin/ipkg "; 68 QString cmd = "/usr/bin/ipkg ";
69#ifdef OPROCESS 69#ifdef OPROCESS
70 ipkgProcess->kill();
70 ipkgProcess->clearArguments(); 71 ipkgProcess->clearArguments();
71 *ipkgProcess << "/usr/bin/ipkg "; 72 *ipkgProcess << "/usr/bin/ipkg ";
@@ -100,4 +101,6 @@ bool PmIpkg::runIpkg(const QString& args, const QString& dest )
100 101
101//debug 102//debug
103 delete ipkgProcess;
104 ipkgProcess = new OProcess();
102 ipkgProcess->clearArguments(); 105 ipkgProcess->clearArguments();
103 *ipkgProcess << "/bin/ls "; 106 *ipkgProcess << "/bin/ls ";
@@ -171,5 +174,5 @@ QStringList* PmIpkg::getList( QString packFileName, QString d )
171 QString dest = settings->getDestinationUrlByName( d ); 174 QString dest = settings->getDestinationUrlByName( d );
172 dest = dest==""?d:dest; 175 dest = dest==""?d:dest;
173 if (dest == "/" ) return 0; 176 // if (dest == "/" ) return 0;
174 { 177 {
175 Config cfg( "oipkg", Config::User ); 178 Config cfg( "oipkg", Config::User );
@@ -177,11 +180,17 @@ QStringList* PmIpkg::getList( QString packFileName, QString d )
177 QString statusDir = cfg.readEntry( "statusDir", "" ); 180 QString statusDir = cfg.readEntry( "statusDir", "" );
178 } 181 }
179 packFileName = dest+"/"+statusDir+"/info/"+packFileName+".list"; 182 QString packFileDir = dest+"/"+statusDir+"/info/"+packFileName+".list";
180 QFile f( packFileName ); 183 QFile f( packFileName );
181 if ( ! f.open(IO_ReadOnly) ) 184 if ( ! f.open(IO_ReadOnly) )
182 { 185 {
183 pvDebug(1," Panik! Could not open"); 186 out( "Could not open:\n"+packFileDir );
184 out( "Panik!\n Could not open:\n"+packFileName ); 187 f.close();
185 return (QStringList*)0; 188 packFileDir = "/"+statusDir+"/info/"+packFileName+".list";
189 f.setName( packFileDir );
190 if ( ! f.open(IO_ReadOnly) )
191 {
192 qDebug(" Panik! Could not open"+packFileDir);
193 out( "Could not open:\n"+packFileDir+"\n Panik!" );
194 }
186 } 195 }
187 QStringList *fileList = new QStringList(); 196 QStringList *fileList = new QStringList();
@@ -191,4 +200,5 @@ QStringList* PmIpkg::getList( QString packFileName, QString d )
191 *fileList += t.readLine(); 200 *fileList += t.readLine();
192 } 201 }
202 f.close();
193 return fileList; 203 return fileList;
194} 204}
@@ -196,4 +206,5 @@ QStringList* PmIpkg::getList( QString packFileName, QString d )
196void PmIpkg::linkPackage( QString packFileName, QString dest ) 206void PmIpkg::linkPackage( QString packFileName, QString dest )
197{ 207{
208 if (dest == "root" || dest == "/" ) return;
198 QStringList *fileList = getList( packFileName, dest ); 209 QStringList *fileList = getList( packFileName, dest );
199 processFileList( fileList, dest ); 210 processFileList( fileList, dest );
diff --git a/noncore/unsupported/oipkg/utils.cpp b/noncore/unsupported/oipkg/utils.cpp
index 66dcf10..6821343 100644
--- a/noncore/unsupported/oipkg/utils.cpp
+++ b/noncore/unsupported/oipkg/utils.cpp
@@ -1,11 +1,3 @@
1/*************************************************************************** 1/***************************************************************************
2 utils.cpp - description
3 -------------------
4 begin : Sun Apr 28 2002
5 copyright : (C) 2002 by tille
6 email : tille@handhelds.org
7 ***************************************************************************/
8
9/***************************************************************************
10 * * 2 * *
11 * This program is free software; you can redistribute it and/or modify * 3 * This program is free software; you can redistribute it and/or modify *
@@ -15,4 +7,5 @@
15 * * 7 * *
16 ***************************************************************************/ 8 ***************************************************************************/
9// (c) 2002 Patrick S. Vogt <tille@handhelds.org>
17 10
18#include <qcombobox.h> 11#include <qcombobox.h>
diff --git a/noncore/unsupported/oipkg/utils.h b/noncore/unsupported/oipkg/utils.h
index ecc70dc..da33eda 100644
--- a/noncore/unsupported/oipkg/utils.h
+++ b/noncore/unsupported/oipkg/utils.h
@@ -1,11 +1,3 @@
1/*************************************************************************** 1/***************************************************************************
2 utils.h - description
3 -------------------
4 begin : Sun Apr 28 2002
5 copyright : (C) 2002 by tille
6 email : tille@handhelds.org
7 ***************************************************************************/
8
9/***************************************************************************
10 * * 2 * *
11 * This program is free software; you can redistribute it and/or modify * 3 * This program is free software; you can redistribute it and/or modify *
@@ -15,4 +7,5 @@
15 * * 7 * *
16 ***************************************************************************/ 8 ***************************************************************************/
9// (c) 2002 Patrick S. Vogt <tille@handhelds.org>
17 10
18void setComboName( QComboBox*, QString ); 11void setComboName( QComboBox*, QString );