mirror of
https://git.dev.opencascade.org/repos/occt.git
synced 2025-08-04 13:13:25 +03:00
0029310: Coding - multiple compiler warnings in Inspectors
1. Added specific header files to disable and restore compiler warnings: Standard_WarningsDisable.hxx, Standard_WarningsRestore.hxx. (Currently only MSVC compiler is handled.) 2. Inspector: compiler warnings are disabled for all includes of Qt headers. 3. Inspector: minor code correction to avoid warning due to use of floating point values in integer calculations.
This commit is contained in:
@@ -16,12 +16,14 @@
|
||||
#include <inspector/DFBrowserPane_TableView.hxx>
|
||||
#include <inspector/DFBrowserPane_Tools.hxx>
|
||||
|
||||
#include <Standard_WarningsDisable.hxx>
|
||||
#include <QAbstractTableModel>
|
||||
#include <QHeaderView>
|
||||
#include <QHBoxLayout>
|
||||
#include <QScrollBar>
|
||||
#include <QTableView>
|
||||
#include <QWidget>
|
||||
#include <Standard_WarningsRestore.hxx>
|
||||
|
||||
static const int DEFAULT_ROW_HEIGHT = 30;
|
||||
|
||||
@@ -68,7 +70,7 @@ void DFBrowserPane_TableView::SetModel (QAbstractTableModel* theModel)
|
||||
// =======================================================================
|
||||
void DFBrowserPane_TableView::SetFixedRowCount (const int theCount, QTableView* theView, const bool theScroll)
|
||||
{
|
||||
double aHeight = theView->verticalHeader()->defaultSectionSize()*theCount + DFBrowserPane_Tools::HeaderSectionMargin();
|
||||
int aHeight = theView->verticalHeader()->defaultSectionSize() * theCount + DFBrowserPane_Tools::HeaderSectionMargin();
|
||||
if (theScroll)
|
||||
aHeight += theView->horizontalScrollBar()->sizeHint().height();
|
||||
|
||||
|
Reference in New Issue
Block a user