From 1f106a8b44ae659f30361588f53354e8f1985974 Mon Sep 17 00:00:00 2001 From: josef Date: Sun, 20 Oct 2002 16:39:25 +0000 Subject: - fix focus handling: If a new session is created, it gets the focus. Likewise, if we switch the session. Before the patch, one had to click inside the term window to be able to type. --- diff --git a/noncore/apps/opie-console/mainwindow.cpp b/noncore/apps/opie-console/mainwindow.cpp index 49f9653..afac542 100644 --- a/noncore/apps/opie-console/mainwindow.cpp +++ b/noncore/apps/opie-console/mainwindow.cpp @@ -435,6 +435,9 @@ void MainWindow::create( const Profile& prof ) { if (prof.autoConnect()) { slotConnect(); } + + QWidget *w = currentSession()->widget(); + if(w) w->setFocus(); } void MainWindow::slotTransfer() @@ -479,6 +482,9 @@ void MainWindow::slotSessionChanged( Session* ses ) { m_connect->setEnabled( true ); m_disconnect->setEnabled( false ); } + + QWidget *w = m_curSession->widget(); + if(w) w->setFocus(); } } -- cgit v0.9.0.2