Back to index

fet  5.18.0
tablewidgetupdatebug.cpp
Go to the documentation of this file.
00001 /***************************************************************************
00002                           tablewidgetupdatebug.cpp  -  description
00003                              -------------------
00004     begin                : 2009
00005     copyright            : (C) 2009 by Lalescu Liviu
00006     email                : Please see http://lalescu.ro/liviu/ for details about contacting Liviu Lalescu (in particular, you can find here the e-mail address)
00007  ***************************************************************************/
00008 
00009 /***************************************************************************
00010  *                                                                         *
00011  *   This program is free software; you can redistribute it and/or modify  *
00012  *   it under the terms of the GNU General Public License as published by  *
00013  *   the Free Software Foundation; either version 2 of the License, or     *
00014  *   (at your option) any later version.                                   *
00015  *                                                                         *
00016  ***************************************************************************/
00017 
00018 #include "tablewidgetupdatebug.h"
00019 
00020 #include <QtGlobal>
00021 #include <QString>
00022 
00023 #include <QWidget>
00024 
00025 void tableWidgetUpdateBug(QTableWidget* table)
00026 {
00027        //this is for a bug appeared in Qt 4.5.3. The bug seems to be solved in Qt subsequent versions.
00028 
00029        QString buggy1=QString("4.5.3");
00030        QString crtVersion=qVersion();
00031        if(crtVersion==buggy1){
00032               if(table->viewport())
00033                      table->viewport()->update();
00034        }
00035 }