author | harlekin <harlekin> | 2002-10-17 17:39:06 (UTC) |
---|---|---|
committer | harlekin <harlekin> | 2002-10-17 17:39:06 (UTC) |
commit | ec202e5d2956f2cde0f2a6be5c452bd67347e21f (patch) (side-by-side diff) | |
tree | 54d5868f9c71ad953360b911f9c50ff21e070d03 | |
parent | fb44c86f420d9a77d7364ac8b8bbd25b0f6ab09a (diff) | |
download | opie-ec202e5d2956f2cde0f2a6be5c452bd67347e21f.zip opie-ec202e5d2956f2cde0f2a6be5c452bd67347e21f.tar.gz opie-ec202e5d2956f2cde0f2a6be5c452bd67347e21f.tar.bz2 |
only show connection tab in profile config dialog if the current layer has connections - for local console mode
-rw-r--r-- | noncore/apps/opie-console/profileeditordialog.cpp | 8 | ||||
-rw-r--r-- | noncore/apps/opie-console/profileeditordialog.h | 2 | ||||
-rw-r--r-- | noncore/apps/opie-console/serialconfigwidget.cpp | 2 |
3 files changed, 7 insertions, 5 deletions
diff --git a/noncore/apps/opie-console/profileeditordialog.cpp b/noncore/apps/opie-console/profileeditordialog.cpp index b709cf3..5c5c2b3 100644 --- a/noncore/apps/opie-console/profileeditordialog.cpp +++ b/noncore/apps/opie-console/profileeditordialog.cpp @@ -8,4 +8,2 @@ -#include <opie/otabwidget.h> - #include "profileeditorplugins.h" @@ -59,3 +57,3 @@ void ProfileEditorDialog::initUI() QVBoxLayout *mainLayout = new QVBoxLayout( this ); - OTabWidget *tabWidget = new OTabWidget( this ); + tabWidget = new OTabWidget( this ); tabWidget->setTabStyle(OTabWidget::TextTab); @@ -175,5 +173,7 @@ void ProfileEditorDialog::slotConActivated( const QString& str ) { - if (m_con ) { + if ( m_con ) { m_con->load( m_prof ); m_layCon->addWidget( m_con ); + } else { + tabWidget->removePage( m_tabCon ); } diff --git a/noncore/apps/opie-console/profileeditordialog.h b/noncore/apps/opie-console/profileeditordialog.h index 3b67bb3..6fde839 100644 --- a/noncore/apps/opie-console/profileeditordialog.h +++ b/noncore/apps/opie-console/profileeditordialog.h @@ -4,2 +4,3 @@ #include <qdialog.h> +#include <opie/otabwidget.h> @@ -48,2 +49,3 @@ private: QHBoxLayout *m_layCon, *m_layTerm; + OTabWidget *tabWidget; }; diff --git a/noncore/apps/opie-console/serialconfigwidget.cpp b/noncore/apps/opie-console/serialconfigwidget.cpp index d216c92..1e97a24 100644 --- a/noncore/apps/opie-console/serialconfigwidget.cpp +++ b/noncore/apps/opie-console/serialconfigwidget.cpp @@ -58,3 +58,3 @@ void SerialConfigWidget::load( const Profile& prof ) { } else { - m_base->setFlow( IOLayerBase::None ); + m_base->setFlow( IOLayerBase::None ); } |