-rw-r--r-- | core/pim/todo/tableview.cpp | 14 | ||||
-rw-r--r-- | core/pim/todo/tableview.h | 2 | ||||
-rw-r--r-- | core/pim/todo/todoview.cpp | 4 |
3 files changed, 17 insertions, 3 deletions
diff --git a/core/pim/todo/tableview.cpp b/core/pim/todo/tableview.cpp index 6299113..743deb7 100644 --- a/core/pim/todo/tableview.cpp +++ b/core/pim/todo/tableview.cpp @@ -28,2 +28,3 @@ #include <stdlib.h> +#include <cmath> @@ -34,2 +35,4 @@ +#include <qpe/config.h> + #include "mainwindow.h" @@ -46,2 +49,8 @@ namespace { +void TableView::initConfig() { + Config config( "todo" ); + config.setGroup( "Options" ); + m_completeStrokeWidth = config.readNumEntry( "CompleteStrokeWidth", 8 ); +} + TableView::TableView( MainWindow* window, QWidget* wid ) @@ -98,2 +107,5 @@ TableView::TableView( MainWindow* window, QWidget* wid ) m_first = true; + + /* now let's init the config */ + initConfig(); } @@ -490,3 +502,3 @@ void TableView::contentsMouseReleaseEvent( QMouseEvent* e) { if ( row == rowAt( e->y() ) && row != -1 ) { - if ( abs( m_prevP.x() - e->x() ) >= 8 ) { + if ( ::abs( m_prevP.x() - e->x() ) >= m_completeStrokeWidth ) { qWarning("current row %d", row ); diff --git a/core/pim/todo/tableview.h b/core/pim/todo/tableview.h index 0c3e865..e47b38f 100644 --- a/core/pim/todo/tableview.h +++ b/core/pim/todo/tableview.h @@ -100,2 +100,4 @@ private slots: private: + void initConfig(); + int m_completeStrokeWidth; bool m_row : 1; diff --git a/core/pim/todo/todoview.cpp b/core/pim/todo/todoview.cpp index 639fa66..4cf7d30 100644 --- a/core/pim/todo/todoview.cpp +++ b/core/pim/todo/todoview.cpp @@ -73,6 +73,6 @@ void TodoView::setAscending( bool b ) { } -void TodoView::update(int uid, const SmallTodo& to ) { +void TodoView::update(int, const SmallTodo& ) { //m_main->slotUpate1( uid, to ); } -void TodoView::update(int uid, const OTodo& ev ) { +void TodoView::update(int , const OTodo& ev ) { m_main->updateTodo( ev ); |