Fix compilation on Windows, fix glitch that could cause windows to appear off the actual screen with no way to get them back.
This commit is contained in:
@@ -66,7 +66,7 @@ void DBCComparatorWindow::readSettings()
|
||||
if (settings.value("Main/SaveRestorePositions", false).toBool())
|
||||
{
|
||||
resize(settings.value("DBCComparator/WindowSize", QSize(720, 631)).toSize());
|
||||
move(settings.value("DBCComparator/WindowPos", QPoint(50, 50)).toPoint());
|
||||
move(Utility::constrainedWindowPos(settings.value("DBCComparator/WindowPos", QPoint(50, 50)).toPoint()));
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -198,7 +198,7 @@ void DiscreteStateWindow::readSettings()
|
||||
if (settings.value("Main/SaveRestorePositions", false).toBool())
|
||||
{
|
||||
resize(settings.value("DiscreteState/WindowSize", QSize(400, 300)).toSize());
|
||||
move(settings.value("DiscreteState/WindowPos", QPoint(50, 50)).toPoint());
|
||||
move(Utility::constrainedWindowPos(settings.value("DiscreteState/WindowPos", QPoint(50, 50)).toPoint()));
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@@ -64,7 +64,7 @@ void FileComparatorWindow::readSettings()
|
||||
if (settings.value("Main/SaveRestorePositions", false).toBool())
|
||||
{
|
||||
resize(settings.value("FileComparator/WindowSize", QSize(720, 631)).toSize());
|
||||
move(settings.value("FileComparator/WindowPos", QPoint(50, 50)).toPoint());
|
||||
move(Utility::constrainedWindowPos(settings.value("FileComparator/WindowPos", QPoint(50, 50)).toPoint()));
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -158,7 +158,7 @@ void FlowViewWindow::readSettings()
|
||||
if (settings.value("Main/SaveRestorePositions", false).toBool())
|
||||
{
|
||||
resize(settings.value("FlowView/WindowSize", QSize(1078, 621)).toSize());
|
||||
move(settings.value("FlowView/WindowPos", QPoint(50, 50)).toPoint());
|
||||
move(Utility::constrainedWindowPos(settings.value("FlowView/WindowPos", QPoint(50, 50)).toPoint()));
|
||||
}
|
||||
|
||||
if (settings.value("FlowView/AutoRef", false).toBool())
|
||||
|
||||
@@ -170,7 +170,7 @@ void FrameInfoWindow::readSettings()
|
||||
if (settings.value("Main/SaveRestorePositions", false).toBool())
|
||||
{
|
||||
resize(settings.value("FrameInfo/WindowSize", QSize(794, 694)).toSize());
|
||||
move(settings.value("FrameInfo/WindowPos", QPoint(50, 50)).toPoint());
|
||||
move(Utility::constrainedWindowPos(settings.value("FrameInfo/WindowPos", QPoint(50, 50)).toPoint()));
|
||||
}
|
||||
useOpenGL = settings.value("Main/UseOpenGL", false).toBool();
|
||||
|
||||
|
||||
@@ -125,7 +125,7 @@ void GraphingWindow::readSettings()
|
||||
if (settings.value("Main/SaveRestorePositions", false).toBool())
|
||||
{
|
||||
resize(settings.value("Graphing/WindowSize", QSize(800, 600)).toSize());
|
||||
move(settings.value("Graphing/WindowPos", QPoint(50, 50)).toPoint());
|
||||
move(Utility::constrainedWindowPos(settings.value("Graphing/WindowPos", QPoint(50, 50)).toPoint()));
|
||||
}
|
||||
secondsMode = settings.value("Main/TimeSeconds", false).toBool();
|
||||
useOpenGL = settings.value("Main/UseOpenGL", false).toBool();
|
||||
|
||||
@@ -112,7 +112,7 @@ void ISOTP_InterpreterWindow::readSettings()
|
||||
if (settings.value("Main/SaveRestorePositions", false).toBool())
|
||||
{
|
||||
resize(settings.value("ISODecodeWindow/WindowSize", this->size()).toSize());
|
||||
move(settings.value("ISODecodeWindow/WindowPos", QPoint(50, 50)).toPoint());
|
||||
move(Utility::constrainedWindowPos(settings.value("ISODecodeWindow/WindowPos", QPoint(50, 50)).toPoint()));
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -126,7 +126,7 @@ void RangeStateWindow::readSettings()
|
||||
if (settings.value("Main/SaveRestorePositions", false).toBool())
|
||||
{
|
||||
resize(settings.value("RangeStateView/WindowSize", QSize(765, 615)).toSize());
|
||||
move(settings.value("RangeStateView/WindowPos", QPoint(50, 50)).toPoint());
|
||||
move(Utility::constrainedWindowPos(settings.value("RangeStateView/WindowPos", QPoint(50, 50)).toPoint()));
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -6,6 +6,7 @@
|
||||
#include "helpwindow.h"
|
||||
#include "connections/canconmanager.h"
|
||||
#include "SnifferDelegate.h"
|
||||
#include "utility.h"
|
||||
|
||||
SnifferWindow::SnifferWindow(QWidget *parent) :
|
||||
QDialog(parent),
|
||||
@@ -73,7 +74,7 @@ void SnifferWindow::readSettings()
|
||||
if (settings.value("Main/SaveRestorePositions", false).toBool())
|
||||
{
|
||||
resize(settings.value("Sniffer/WindowSize", QSize(1100, 750)).toSize());
|
||||
move(settings.value("Sniffer/WindowPos", QPoint(50, 50)).toPoint());
|
||||
move(Utility::constrainedWindowPos(settings.value("Sniffer/WindowPos", QPoint(50, 50)).toPoint()));
|
||||
ui->treeView->setColumnWidth(0, settings.value("Sniffer/DeltaColumn", 110).toUInt());
|
||||
ui->treeView->setColumnWidth(1, settings.value("Sniffer/IDColumn", 70).toUInt());
|
||||
ui->treeView->setColumnWidth(2, settings.value("Sniffer/Data0Column", 92).toUInt());
|
||||
|
||||
@@ -91,7 +91,7 @@ void TemporalGraphWindow::readSettings()
|
||||
if (settings.value("Main/SaveRestorePositions", false).toBool())
|
||||
{
|
||||
resize(settings.value("Temporal/WindowSize", QSize(800, 600)).toSize());
|
||||
move(settings.value("Temporal/WindowPos", QPoint(50, 50)).toPoint());
|
||||
move(Utility::constrainedWindowPos(settings.value("Temporal/WindowPos", QPoint(50, 50)).toPoint()));
|
||||
}
|
||||
useOpenGL = settings.value("Main/UseOpenGL", false).toBool();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user