summaryrefslogtreecommitdiff
authordrw <drw>2003-03-19 02:48:27 (UTC)
committer drw <drw>2003-03-19 02:48:27 (UTC)
commitf35989ef21fb5a27ebe6f6924ee2cc601318c1b8 (patch) (unidiff)
treef169286f925c01758d1456027eb43743bb0cd162
parent06ddd131a6f33d341290617e71a14006fc9957a1 (diff)
downloadopie-f35989ef21fb5a27ebe6f6924ee2cc601318c1b8.zip
opie-f35989ef21fb5a27ebe6f6924ee2cc601318c1b8.tar.gz
opie-f35989ef21fb5a27ebe6f6924ee2cc601318c1b8.tar.bz2
Fix for bug #741
Diffstat (more/less context) (ignore whitespace changes)
-rw-r--r--noncore/settings/aqpkg/installdlgimpl.cpp3
-rw-r--r--noncore/settings/aqpkg/installdlgimpl.h6
-rw-r--r--noncore/settings/aqpkg/mainwin.cpp29
-rw-r--r--noncore/settings/aqpkg/mainwin.h3
4 files changed, 33 insertions, 8 deletions
diff --git a/noncore/settings/aqpkg/installdlgimpl.cpp b/noncore/settings/aqpkg/installdlgimpl.cpp
index 1f0bb5f..2bb8b4d 100644
--- a/noncore/settings/aqpkg/installdlgimpl.cpp
+++ b/noncore/settings/aqpkg/installdlgimpl.cpp
@@ -184,5 +184,5 @@ void InstallDlgImpl :: init( bool displayextrainfo )
184 connect( btnInstall, SIGNAL( clicked() ), this, SLOT( installSelected() ) ); 184 connect( btnInstall, SIGNAL( clicked() ), this, SLOT( installSelected() ) );
185 185
186 btnOptions = new QPushButton( Resource::loadPixmap( "aqpkg/config" ), tr( "Options" ), this ); 186 btnOptions = new QPushButton( Resource::loadPixmap( "SettingsIcon" ), tr( "Options" ), this );
187 layout->addWidget( btnOptions, 3, 1 ); 187 layout->addWidget( btnOptions, 3, 1 );
188 connect( btnOptions, SIGNAL( clicked() ), this, SLOT( optionsSelected() ) ); 188 connect( btnOptions, SIGNAL( clicked() ), this, SLOT( optionsSelected() ) );
@@ -231,4 +231,5 @@ void InstallDlgImpl :: installSelected()
231 btnInstall->setText( tr( "Abort" ) ); 231 btnInstall->setText( tr( "Abort" ) );
232 btnInstall->setIconSet( Resource::loadPixmap( "close" ) ); 232 btnInstall->setIconSet( Resource::loadPixmap( "close" ) );
233
233 if ( pIpkg ) 234 if ( pIpkg )
234 { 235 {
diff --git a/noncore/settings/aqpkg/installdlgimpl.h b/noncore/settings/aqpkg/installdlgimpl.h
index d7509bb..c30963e 100644
--- a/noncore/settings/aqpkg/installdlgimpl.h
+++ b/noncore/settings/aqpkg/installdlgimpl.h
@@ -56,7 +56,7 @@ protected:
56private: 56private:
57 DataManager *dataMgr; 57 DataManager *dataMgr;
58 QList<InstallData> installList; 58 QList<InstallData> installList;
59 QList<InstallData> removeList; 59 QList<InstallData> removeList;
60 QList<InstallData> updateList; 60 QList<InstallData> updateList;
61 int flags; 61 int flags;
62 Ipkg *pIpkg; 62 Ipkg *pIpkg;
diff --git a/noncore/settings/aqpkg/mainwin.cpp b/noncore/settings/aqpkg/mainwin.cpp
index dfe6d9c..7fa311d 100644
--- a/noncore/settings/aqpkg/mainwin.cpp
+++ b/noncore/settings/aqpkg/mainwin.cpp
@@ -341,4 +341,21 @@ void MainWindow :: displaySettings()
341 delete dlg; 341 delete dlg;
342} 342}
343
344void MainWindow :: closeEvent( QCloseEvent *e )
345{
346 // If install dialog is visible, return to main view, otherwise close app
347 QWidget *widget = stack->visibleWidget();
348
349 if ( widget != networkPkgWindow && widget != progressWindow )
350 {
351 if ( widget ) delete widget;
352 stack->raiseWidget( networkPkgWindow );
353 e->ignore();
354 }
355 else
356 {
357 e->accept();
358 }
359}
343 360
344void MainWindow :: displayFindBar() 361void MainWindow :: displayFindBar()
@@ -780,5 +797,6 @@ void MainWindow :: updateServer()
780 tr( "Update lists" ) ); 797 tr( "Update lists" ) );
781 connect( dlg, SIGNAL( reloadData( InstallDlgImpl * ) ), this, SLOT( reloadData( InstallDlgImpl * ) ) ); 798 connect( dlg, SIGNAL( reloadData( InstallDlgImpl * ) ), this, SLOT( reloadData( InstallDlgImpl * ) ) );
782 dlg->showMaximized(); 799 stack->addWidget( dlg, 3 );
800 stack->raiseWidget( dlg );
783 801
784// delete progDlg; 802// delete progDlg;
@@ -809,5 +827,6 @@ void MainWindow :: upgradePackages()
809 tr ( "Upgrade" ) ); 827 tr ( "Upgrade" ) );
810 connect( dlg, SIGNAL( reloadData( InstallDlgImpl * ) ), this, SLOT( reloadData( InstallDlgImpl * ) ) ); 828 connect( dlg, SIGNAL( reloadData( InstallDlgImpl * ) ), this, SLOT( reloadData( InstallDlgImpl * ) ) );
811 dlg->showMaximized(); 829 stack->addWidget( dlg, 3 );
830 stack->raiseWidget( dlg );
812 } 831 }
813} 832}
@@ -950,5 +969,6 @@ void MainWindow :: downloadRemotePackage()
950 InstallDlgImpl *dlg = new InstallDlgImpl( workingPackages, mgr, tr( "Download" ) ); 969 InstallDlgImpl *dlg = new InstallDlgImpl( workingPackages, mgr, tr( "Download" ) );
951 connect( dlg, SIGNAL( reloadData( InstallDlgImpl * ) ), this, SLOT( reloadData( InstallDlgImpl * ) ) ); 970 connect( dlg, SIGNAL( reloadData( InstallDlgImpl * ) ), this, SLOT( reloadData( InstallDlgImpl * ) ) );
952 dlg->showMaximized(); 971 stack->addWidget( dlg, 3 );
972 stack->raiseWidget( dlg );
953} 973}
954 974
@@ -988,5 +1008,6 @@ void MainWindow :: applyChanges()
988 InstallDlgImpl *dlg = new InstallDlgImpl( workingPackages, mgr, tr( "Apply changes" ) ); 1008 InstallDlgImpl *dlg = new InstallDlgImpl( workingPackages, mgr, tr( "Apply changes" ) );
989 connect( dlg, SIGNAL( reloadData( InstallDlgImpl * ) ), this, SLOT( reloadData( InstallDlgImpl * ) ) ); 1009 connect( dlg, SIGNAL( reloadData( InstallDlgImpl * ) ), this, SLOT( reloadData( InstallDlgImpl * ) ) );
990 dlg->showMaximized(); 1010 stack->addWidget( dlg, 3 );
1011 stack->raiseWidget( dlg );
991} 1012}
992 1013
diff --git a/noncore/settings/aqpkg/mainwin.h b/noncore/settings/aqpkg/mainwin.h
index d75e5d2..b2de871 100644
--- a/noncore/settings/aqpkg/mainwin.h
+++ b/noncore/settings/aqpkg/mainwin.h
@@ -44,4 +44,7 @@ public:
44 ~MainWindow(); 44 ~MainWindow();
45 45
46protected:
47 void closeEvent( QCloseEvent* e );
48
46private: 49private:
47 DataManager *mgr; 50 DataManager *mgr;