-rw-r--r-- | core/pim/todo/tableview.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/core/pim/todo/tableview.cpp b/core/pim/todo/tableview.cpp index def0efb..3daf370 100644 --- a/core/pim/todo/tableview.cpp +++ b/core/pim/todo/tableview.cpp | |||
@@ -76,65 +76,65 @@ void TableView::initConfig() { | |||
76 | Config config( "todo" ); | 76 | Config config( "todo" ); |
77 | config.setGroup( "Options" ); | 77 | config.setGroup( "Options" ); |
78 | m_completeStrokeWidth = config.readNumEntry( "CompleteStrokeWidth", 8 ); | 78 | m_completeStrokeWidth = config.readNumEntry( "CompleteStrokeWidth", 8 ); |
79 | for (int i = 0; i < numCols(); i++ ) { | 79 | for (int i = 0; i < numCols(); i++ ) { |
80 | int width = config.readNumEntry("Width"+QString::number(i), -1 ); | 80 | int width = config.readNumEntry("Width"+QString::number(i), -1 ); |
81 | setColumnWidth(i, width == -1 ? columnWidth(i) : width ); | 81 | setColumnWidth(i, width == -1 ? columnWidth(i) : width ); |
82 | } | 82 | } |
83 | } | 83 | } |
84 | 84 | ||
85 | TableView::TableView( MainWindow* window, QWidget* wid ) | 85 | TableView::TableView( MainWindow* window, QWidget* wid ) |
86 | : QTable( wid ), TodoView( window ) { | 86 | : QTable( wid ), TodoView( window ) { |
87 | 87 | ||
88 | setName("TableView"); | 88 | setName("TableView"); |
89 | // Load icons | 89 | // Load icons |
90 | // TODO - probably should be done globally somewhere else, | 90 | // TODO - probably should be done globally somewhere else, |
91 | // see also quickeditimpl.cpp/h, taskeditoroverview.cpp/h | 91 | // see also quickeditimpl.cpp/h, taskeditoroverview.cpp/h |
92 | m_pic_completed = Resource::loadPixmap( "todo/completed" ); | 92 | m_pic_completed = Resource::loadPixmap( "todo/completed" ); |
93 | QString namestr; | 93 | QString namestr; |
94 | for ( unsigned int i = 1; i < 6; i++ ) { | 94 | for ( unsigned int i = 1; i < 6; i++ ) { |
95 | namestr = "todo/priority"; | 95 | namestr = "todo/priority"; |
96 | namestr.append( QString::number( i ) ); | 96 | namestr.append( QString::number( i ) ); |
97 | m_pic_priority[ i - 1 ] = Resource::loadPixmap( namestr ); | 97 | m_pic_priority[ i - 1 ] = Resource::loadPixmap( namestr ); |
98 | } | 98 | } |
99 | 99 | ||
100 | setUpdatesEnabled( false ); | 100 | setUpdatesEnabled( false ); |
101 | viewport()->setUpdatesEnabled( false ); | 101 | viewport()->setUpdatesEnabled( false ); |
102 | m_enablePaint = false; | 102 | m_enablePaint = false; |
103 | setNumRows(0); | 103 | setNumRows(0); |
104 | setNumCols(4); | 104 | setNumCols(4); |
105 | 105 | ||
106 | horizontalHeader()->setLabel( 0, QWidget::tr("C.") ); | 106 | horizontalHeader()->setLabel( 0, QWidget::tr("C.") ); |
107 | horizontalHeader()->setLabel( 1, QWidget::tr("Priority") ); | 107 | horizontalHeader()->setLabel( 1, QWidget::tr("Priority") ); |
108 | horizontalHeader()->setLabel( 2, QWidget::tr("Description" ) ); | 108 | horizontalHeader()->setLabel( 2, QWidget::tr("Summary" ) ); |
109 | horizontalHeader()->setLabel( 3, QWidget::tr("Deadline") ); | 109 | horizontalHeader()->setLabel( 3, QWidget::tr("Deadline") ); |
110 | 110 | ||
111 | setShowDeadline( todoWindow()->showDeadline() ); | 111 | setShowDeadline( todoWindow()->showDeadline() ); |
112 | 112 | ||
113 | setSorting( TRUE ); | 113 | setSorting( TRUE ); |
114 | setSelectionMode( NoSelection ); | 114 | setSelectionMode( NoSelection ); |
115 | 115 | ||
116 | setLeftMargin( 0 ); | 116 | setLeftMargin( 0 ); |
117 | verticalHeader()->hide(); | 117 | verticalHeader()->hide(); |
118 | 118 | ||
119 | connect((QTable*)this, SIGNAL( clicked( int, int, int, const QPoint& ) ), | 119 | connect((QTable*)this, SIGNAL( clicked( int, int, int, const QPoint& ) ), |
120 | this, SLOT( slotClicked(int, int, int, const QPoint& ) ) ); | 120 | this, SLOT( slotClicked(int, int, int, const QPoint& ) ) ); |
121 | connect((QTable*)this, SIGNAL( pressed( int, int, int, const QPoint& ) ), | 121 | connect((QTable*)this, SIGNAL( pressed( int, int, int, const QPoint& ) ), |
122 | this, SLOT( slotPressed(int, int, int, const QPoint& ) ) ); | 122 | this, SLOT( slotPressed(int, int, int, const QPoint& ) ) ); |
123 | connect((QTable*)this, SIGNAL(valueChanged(int, int) ), | 123 | connect((QTable*)this, SIGNAL(valueChanged(int, int) ), |
124 | this, SLOT( slotValueChanged(int, int) ) ); | 124 | this, SLOT( slotValueChanged(int, int) ) ); |
125 | connect((QTable*)this, SIGNAL(currentChanged(int, int) ), | 125 | connect((QTable*)this, SIGNAL(currentChanged(int, int) ), |
126 | this, SLOT( slotCurrentChanged(int, int) ) ); | 126 | this, SLOT( slotCurrentChanged(int, int) ) ); |
127 | 127 | ||
128 | m_menuTimer = new QTimer( this ); | 128 | m_menuTimer = new QTimer( this ); |
129 | connect( m_menuTimer, SIGNAL(timeout()), | 129 | connect( m_menuTimer, SIGNAL(timeout()), |
130 | this, SLOT(slotShowMenu()) ); | 130 | this, SLOT(slotShowMenu()) ); |
131 | 131 | ||
132 | /* now let's init the config */ | 132 | /* now let's init the config */ |
133 | initConfig(); | 133 | initConfig(); |
134 | 134 | ||
135 | 135 | ||
136 | m_enablePaint = true; | 136 | m_enablePaint = true; |
137 | setUpdatesEnabled( true ); | 137 | setUpdatesEnabled( true ); |
138 | viewport()->setUpdatesEnabled( true ); | 138 | viewport()->setUpdatesEnabled( true ); |
139 | viewport()->update(); | 139 | viewport()->update(); |
140 | setSortOrder( 0 ); | 140 | setSortOrder( 0 ); |