summaryrefslogtreecommitdiff
path: root/noncore/apps/opie-console
authorerik <erik>2007-01-29 21:53:48 (UTC)
committer erik <erik>2007-01-29 21:53:48 (UTC)
commit02ef45be75a3024df11365956e1cce6392d9103c (patch) (side-by-side diff)
tree42fd5c909d67a473f57a607e01d32e01b3dd2511 /noncore/apps/opie-console
parentb2c306a99b8dc82c981390f02db859149fac8cf0 (diff)
downloadopie-02ef45be75a3024df11365956e1cce6392d9103c.zip
opie-02ef45be75a3024df11365956e1cce6392d9103c.tar.gz
opie-02ef45be75a3024df11365956e1cce6392d9103c.tar.bz2
Each file in this commit has an issue where the initial value of a variable
is assumed to be something but no initial value is given. This commit changes that by either assigning an initial value or removing the assumption on an initial value (usually the former).
Diffstat (limited to 'noncore/apps/opie-console') (more/less context) (ignore whitespace changes)
-rw-r--r--noncore/apps/opie-console/io_irda.cpp1
-rw-r--r--noncore/apps/opie-console/mainwindow.cpp10
2 files changed, 4 insertions, 7 deletions
diff --git a/noncore/apps/opie-console/io_irda.cpp b/noncore/apps/opie-console/io_irda.cpp
index 9d27c85..a0f72ae 100644
--- a/noncore/apps/opie-console/io_irda.cpp
+++ b/noncore/apps/opie-console/io_irda.cpp
@@ -35,6 +35,7 @@ bool IOIrda::open() {
// emit error!!!
delete m_attach;
m_attach = 0l;
+ ret = false;
}
return ret;
}
diff --git a/noncore/apps/opie-console/mainwindow.cpp b/noncore/apps/opie-console/mainwindow.cpp
index aba7244..a884179 100644
--- a/noncore/apps/opie-console/mainwindow.cpp
+++ b/noncore/apps/opie-console/mainwindow.cpp
@@ -707,15 +707,11 @@ void MainWindow::slotFullscreen() {
void MainWindow::slotScrollbarSelected(int index)
{
- int loc;
+ int loc = 0;
Config cfg( "Konsole" );
cfg.setGroup("ScrollBar");
- if(index == sm_none)
- {
- loc = 0;
- }
- else if(index == sm_left)
+ if(index == sm_left)
{
loc = 1;
}
@@ -724,7 +720,7 @@ void MainWindow::slotScrollbarSelected(int index)
loc = 2;
}
- cfg.writeEntry("Position", loc);
+ cfg.writeEntry("Position", loc);
if (currentSession()) {
currentSession()->emulationHandler()->setScrollbarLocation(loc);