From d1bb1b375d657f0821ccfebf18fa1c3873314690 Mon Sep 17 00:00:00 2001 From: Andrei Karas Date: Wed, 5 Sep 2012 15:55:55 +0300 Subject: Fix useless variables initialisations. --- src/gui/widgets/guitable.cpp | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) (limited to 'src/gui/widgets') diff --git a/src/gui/widgets/guitable.cpp b/src/gui/widgets/guitable.cpp index 0101ed974..4ffe8221f 100644 --- a/src/gui/widgets/guitable.cpp +++ b/src/gui/widgets/guitable.cpp @@ -145,7 +145,6 @@ void GuiTable::recomputeDimensions() const int rows_nr = mModel->getRows(); const int columns_nr = mModel->getColumns(); int width = 0; - int height = 0; if (mSelectedRow >= rows_nr) mSelectedRow = rows_nr - 1; @@ -156,10 +155,8 @@ void GuiTable::recomputeDimensions() for (int i = 0; i < columns_nr; i++) width += getColumnWidth(i); - height = getRowHeight() * rows_nr; - setWidth(width); - setHeight(height); + setHeight(getRowHeight() * rows_nr); } void GuiTable::setSelected(int row, int column) -- cgit v1.2.3-70-g09d2