author | josef <josef> | 2002-10-14 18:36:44 (UTC) |
---|---|---|
committer | josef <josef> | 2002-10-14 18:36:44 (UTC) |
commit | 481d98eabc371d473fef7c640a710c5535637750 (patch) (unidiff) | |
tree | d9abf610d40d761109ced904a6b9618e28cd9022 | |
parent | 66e2630b56989e149a04159d5273ec5cc1661dff (diff) | |
download | opie-481d98eabc371d473fef7c640a710c5535637750.zip opie-481d98eabc371d473fef7c640a710c5535637750.tar.gz opie-481d98eabc371d473fef7c640a710c5535637750.tar.bz2 |
- display warning if connection cannot be established
-rw-r--r-- | noncore/apps/opie-console/mainwindow.cpp | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/noncore/apps/opie-console/mainwindow.cpp b/noncore/apps/opie-console/mainwindow.cpp index 02f8451..b143361 100644 --- a/noncore/apps/opie-console/mainwindow.cpp +++ b/noncore/apps/opie-console/mainwindow.cpp | |||
@@ -258,14 +258,18 @@ void MainWindow::slotRunScript() { | |||
258 | } | 258 | } |
259 | } | 259 | } |
260 | */ | 260 | */ |
261 | } | 261 | } |
262 | 262 | ||
263 | void MainWindow::slotConnect() { | 263 | void MainWindow::slotConnect() { |
264 | if ( currentSession() ) | 264 | if ( currentSession() ) { |
265 | currentSession()->layer()->open(); | 265 | bool ret = currentSession()->layer()->open(); |
266 | if(!ret) QMessageBox::warning(currentSession()->widgetStack(), | ||
267 | QObject::tr("Failed"), | ||
268 | QObject::tr("Connecting failed for this session.")); | ||
269 | } | ||
266 | } | 270 | } |
267 | 271 | ||
268 | void MainWindow::slotDisconnect() { | 272 | void MainWindow::slotDisconnect() { |
269 | if ( currentSession() ) | 273 | if ( currentSession() ) |
270 | currentSession()->layer()->close(); | 274 | currentSession()->layer()->close(); |
271 | } | 275 | } |