mirror of
https://github.com/OPM/ResInsight.git
synced 2025-02-25 18:55:39 -06:00
Make sure all plot windows are resized to predefined size
This commit is contained in:
parent
4b92427a4d
commit
7d5df167fd
@ -18,8 +18,8 @@
|
||||
|
||||
#include "RiaRegressionTestRunner.h"
|
||||
|
||||
#include "RiaGuiApplication.h"
|
||||
#include "RiaGitDiff.h"
|
||||
#include "RiaGuiApplication.h"
|
||||
#include "RiaImageCompareReporter.h"
|
||||
#include "RiaImageFileCompare.h"
|
||||
#include "RiaLogging.h"
|
||||
@ -199,7 +199,7 @@ void RiaRegressionTestRunner::runRegressionTest()
|
||||
|
||||
regressionTestConfigureProject();
|
||||
|
||||
resizeMaximizedPlotWindows();
|
||||
resizePlotWindows();
|
||||
|
||||
QString fullPathGeneratedFolder = testCaseFolder.absoluteFilePath(generatedFolderName);
|
||||
RicSnapshotAllViewsToFileFeature::exportSnapshotOfAllViewsIntoFolder(fullPathGeneratedFolder);
|
||||
@ -499,7 +499,7 @@ void RiaRegressionTestRunner::regressionTestConfigureProject()
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
///
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
void RiaRegressionTestRunner::resizeMaximizedPlotWindows()
|
||||
void RiaRegressionTestRunner::resizePlotWindows()
|
||||
{
|
||||
RimProject* proj = RiaApplication::instance()->project();
|
||||
if (!proj) return;
|
||||
@ -515,20 +515,16 @@ void RiaRegressionTestRunner::resizeMaximizedPlotWindows()
|
||||
{
|
||||
if (viewWindow->isMdiWindow())
|
||||
{
|
||||
RimMdiWindowGeometry wndGeo = viewWindow->mdiWindowGeometry();
|
||||
if (wndGeo.isMaximized)
|
||||
QWidget* viewWidget = viewWindow->viewWidget();
|
||||
|
||||
if (viewWidget)
|
||||
{
|
||||
QWidget* viewWidget = viewWindow->viewWidget();
|
||||
|
||||
if (viewWidget)
|
||||
QMdiSubWindow* mdiWindow = plotMainWindow->findMdiSubWindow(viewWidget);
|
||||
if (mdiWindow)
|
||||
{
|
||||
QMdiSubWindow* mdiWindow = plotMainWindow->findMdiSubWindow(viewWidget);
|
||||
if (mdiWindow)
|
||||
{
|
||||
mdiWindow->showNormal();
|
||||
mdiWindow->showNormal();
|
||||
|
||||
viewWidget->resize(RiaRegressionTestRunner::regressionDefaultImageSize());
|
||||
}
|
||||
viewWidget->resize(RiaRegressionTestRunner::regressionDefaultImageSize());
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -603,8 +599,7 @@ QFileInfoList RiaRegressionTestRunner::subDirectoriesForTestExecution(const QDir
|
||||
for (const auto& s : m_testFilter)
|
||||
{
|
||||
QString trimmed = s.trimmed();
|
||||
if ((m_appendAllTestsAfterLastItemInFilter && anyMatchFound) ||
|
||||
baseName.contains(trimmed, Qt::CaseInsensitive))
|
||||
if ((m_appendAllTestsAfterLastItemInFilter && anyMatchFound) || baseName.contains(trimmed, Qt::CaseInsensitive))
|
||||
{
|
||||
foldersMatchingTestFilter.push_back(fi);
|
||||
anyMatchFound = true;
|
||||
|
@ -60,7 +60,7 @@ private:
|
||||
const QDir& testDir);
|
||||
|
||||
static void removeDirectoryWithContent(QDir& dirToDelete);
|
||||
static void resizeMaximizedPlotWindows();
|
||||
static void resizePlotWindows();
|
||||
static QSize regressionDefaultImageSize();
|
||||
static QString diff2htmlHeaderText(const QString& testRootPath);
|
||||
QFileInfoList subDirectoriesForTestExecution(const QDir& directory);
|
||||
|
Loading…
Reference in New Issue
Block a user