Diffstat (limited to 'noncore/apps/opie-console/profileeditordialog.cpp') (more/less context) (ignore whitespace changes)
-rw-r--r-- | noncore/apps/opie-console/profileeditordialog.cpp | 21 |
1 files changed, 12 insertions, 9 deletions
diff --git a/noncore/apps/opie-console/profileeditordialog.cpp b/noncore/apps/opie-console/profileeditordialog.cpp index 6b607df..e2501a6 100644 --- a/noncore/apps/opie-console/profileeditordialog.cpp +++ b/noncore/apps/opie-console/profileeditordialog.cpp @@ -33,15 +33,15 @@ ProfileEditorDialog::ProfileEditorDialog( MetaFactory* fact, ProfileEditorDialog::ProfileEditorDialog( MetaFactory* fact ) : QDialog(0, 0, TRUE), m_fact( fact ) { - // Default profile - m_prof = Profile("New Profile", "serial", "default", Profile::Black, Profile::White, Profile::VT102); + // Default profile + m_prof = Profile(tr("New Profile"), "serial", "default", Profile::Black, Profile::White, Profile::VT102); - initUI(); + initUI(); - // Apply current profile - // plugin_plugin->load(profile); + // Apply current profile + // plugin_plugin->load(profile); } Profile ProfileEditorDialog::profile() const { @@ -122,13 +122,13 @@ void ProfileEditorDialog::initUI() } // load profile values m_name->setText(m_prof.name()); - slotConActivated( m_fact->external(m_prof.ioLayerName() ) ); - slotTermActivated( m_fact->external(m_prof.terminalName() ) ); slotKeyActivated( "Default Keyboard" ); setCurrent( m_fact->external(m_prof.ioLayerName() ), m_conCmb ); setCurrent( m_fact->external(m_prof.terminalName() ), m_termCmb ); + slotConActivated( m_fact->external(m_prof.ioLayerName() ) ); + slotTermActivated( m_fact->external(m_prof.terminalName() ) ); m_autoConnect->setChecked(m_prof.autoConnect()); // signal and slots @@ -198,12 +198,15 @@ void ProfileEditorDialog::slotConActivated( const QString& str ) { } // FIXME ugly hack right. Right solution would be to look into the layer and see if it // supports auto connect and then set it as prefered - //if ( ( )->layer()->supports()[0] == 1 ) { if ( m_conCmb ->currentText() == tr("Local Console") ) { m_autoConnect->setChecked( true ); + m_prof.writeEntry("Terminal", Profile::Linux ); + slotTermActivated( m_fact->external (m_prof.terminalName() ) ); } else { + m_prof.writeEntry("Terminal", Profile::VT102 ); + slotTermActivated( m_fact->external (m_prof.terminalName() ) ); m_autoConnect->setChecked( false ); } m_con->load( m_prof ); @@ -219,9 +222,9 @@ void ProfileEditorDialog::slotTermActivated( const QString& str ) { delete m_term; m_term = m_fact->newTerminalPlugin( str, m_svTerm->viewport() ); - if (m_term) { + if ( m_term ) { m_term->load( m_prof ); m_svTerm->addChild( m_term ); } } |