summaryrefslogtreecommitdiff
authorllornkcor <llornkcor>2002-03-17 01:44:37 (UTC)
committer llornkcor <llornkcor>2002-03-17 01:44:37 (UTC)
commit624a283591094628425c94fedfdd62941ad7c853 (patch) (unidiff)
tree092b96fa04b16eae5e9702a7a83c67e1cb6a7e60
parent2fe80a98551e89b45798369f1bf91f0368382ba6 (diff)
downloadopie-624a283591094628425c94fedfdd62941ad7c853.zip
opie-624a283591094628425c94fedfdd62941ad7c853.tar.gz
opie-624a283591094628425c94fedfdd62941ad7c853.tar.bz2
added checks on the 'View' menu for which tab is current
Diffstat (more/less context) (show whitespace changes)
-rw-r--r--noncore/net/opieftp/opieftp.cpp10
1 files changed, 10 insertions, 0 deletions
diff --git a/noncore/net/opieftp/opieftp.cpp b/noncore/net/opieftp/opieftp.cpp
index 6a3a64d..118275b 100644
--- a/noncore/net/opieftp/opieftp.cpp
+++ b/noncore/net/opieftp/opieftp.cpp
@@ -104,6 +104,7 @@ OpieFtp::OpieFtp( )
104 tabMenu->insertItem( tr( "Switch to Local" ), this, SLOT( switchToLocalTab() )); 104 tabMenu->insertItem( tr( "Switch to Local" ), this, SLOT( switchToLocalTab() ));
105 tabMenu->insertItem( tr( "Switch to Remote" ), this, SLOT( switchToRemoteTab() )); 105 tabMenu->insertItem( tr( "Switch to Remote" ), this, SLOT( switchToRemoteTab() ));
106 tabMenu->insertItem( tr( "Switch to Config" ), this, SLOT( switchToConfigTab() )); 106 tabMenu->insertItem( tr( "Switch to Config" ), this, SLOT( switchToConfigTab() ));
107 tabMenu->setCheckable(TRUE);
107 108
108 TabWidget = new QTabWidget( this, "TabWidget" ); 109 TabWidget = new QTabWidget( this, "TabWidget" );
109 layout->addMultiCellWidget( TabWidget, 1, 1, 0, 3 ); 110 layout->addMultiCellWidget( TabWidget, 1, 1, 0, 3 );
@@ -260,11 +261,20 @@ void OpieFtp::tabChanged(QWidget *w)
260{ 261{
261 if (TabWidget->currentPageIndex() == 0) { 262 if (TabWidget->currentPageIndex() == 0) {
262 currentPathEdit->setText( currentDir.canonicalPath()); 263 currentPathEdit->setText( currentDir.canonicalPath());
264 tabMenu->setItemChecked(tabMenu->idAt(0),TRUE);
265 tabMenu->setItemChecked(tabMenu->idAt(1),FALSE);
266 tabMenu->setItemChecked(tabMenu->idAt(2),FALSE);
263 } 267 }
264 if (TabWidget->currentPageIndex() == 1) { 268 if (TabWidget->currentPageIndex() == 1) {
265 currentPathEdit->setText( currentRemoteDir ); 269 currentPathEdit->setText( currentRemoteDir );
270 tabMenu->setItemChecked(tabMenu->idAt(1),TRUE);
271 tabMenu->setItemChecked(tabMenu->idAt(0),FALSE);
272 tabMenu->setItemChecked(tabMenu->idAt(2),FALSE);
266 } 273 }
267 if (TabWidget->currentPageIndex() == 2) { 274 if (TabWidget->currentPageIndex() == 2) {
275 tabMenu->setItemChecked(tabMenu->idAt(2),TRUE);
276 tabMenu->setItemChecked(tabMenu->idAt(0),FALSE);
277 tabMenu->setItemChecked(tabMenu->idAt(1),FALSE);
268 } 278 }
269} 279}
270 280