From 20332788152516f83eb4861fcb2bac7a68667be7 Mon Sep 17 00:00:00 2001 From: Peter Penz Date: Fri, 30 Jan 2009 06:13:11 +0000 Subject: minor coding style fixes (http://techbase.kde.org/Policies/Kdelibs_Coding_Style): * use spaces instead of tabs * correct braces CCMAIL: predator106@gmail.com svn path=/trunk/KDE/kdebase/apps/; revision=918537 --- src/dolphinmainwindow.cpp | 19 ++++++++----------- src/dolphinmainwindow.h | 4 ++-- 2 files changed, 10 insertions(+), 13 deletions(-) (limited to 'src') diff --git a/src/dolphinmainwindow.cpp b/src/dolphinmainwindow.cpp index 077005c0f..f623d5eba 100644 --- a/src/dolphinmainwindow.cpp +++ b/src/dolphinmainwindow.cpp @@ -266,15 +266,12 @@ void DolphinMainWindow::slotSelectionChanged(const KFileItemList& selection) emit selectionChanged(selection); } -void DolphinMainWindow::slotWheelMoved(int wheeldelta) -{ - if (wheeldelta > 0) - { - //Non-negative, wheel is going forwards, so the tab goes backwards (focuses left) - activatePrevTab(); - } else - { - activateNextTab(); +void DolphinMainWindow::slotWheelMoved(int wheelDelta) +{ + if (wheelDelta > 0) { + activatePrevTab(); + } else { + activateNextTab(); } } @@ -908,9 +905,9 @@ void DolphinMainWindow::init() this, SLOT(openNewTab())); connect(m_tabBar, SIGNAL(testCanDecode(const QDragMoveEvent*, bool&)), this, SLOT(slotTestCanDecode(const QDragMoveEvent*, bool&))); - connect(m_tabBar, SIGNAL(wheelDelta(int)), + connect(m_tabBar, SIGNAL(wheelDelta(int)), this, SLOT(slotWheelMoved(int))); - + m_tabBar->blockSignals(true); // signals get unblocked after at least 2 tabs are open QWidget* centralWidget = new QWidget(this); diff --git a/src/dolphinmainwindow.h b/src/dolphinmainwindow.h index f9eb5cced..885610b9f 100644 --- a/src/dolphinmainwindow.h +++ b/src/dolphinmainwindow.h @@ -287,7 +287,7 @@ private slots: * we look to see if it's negative (backwards) or positive (forwards). * Enables changing of tabs via mouse wheel. */ - void slotWheelMoved(int wheeldelta); + void slotWheelMoved(int wheelDelta); /** Emits the signal requestItemInfo(). */ void slotRequestItemInfo(const KFileItem&); @@ -349,7 +349,7 @@ private slots: */ void closeTab(int index); - + /** * Opens a context menu for the tab with the index \a index * on the position \a pos. -- cgit v1.3