Big update to remove deprecation warning from Qt 5.15.0
That is need on MacOS build as travis log is bigger than 50k lines which breaks travis rules And by the way deprecations are real All file contains the same modification replace 0 to Qt::WindowFlags() when needed as the class needs to be instantiated Signed-off-by: vejmarie <jmverdun3@gmail.com>
This commit is contained in:
@@ -463,7 +463,7 @@ void DrawingView::onRelabel(Gui::Document *pDoc)
|
||||
|
||||
void DrawingView::printPdf()
|
||||
{
|
||||
Gui::FileOptionsDialog dlg(this, 0);
|
||||
Gui::FileOptionsDialog dlg(this, Qt::WindowFlags());
|
||||
dlg.setFileMode(QFileDialog::AnyFile);
|
||||
dlg.setAcceptMode(QFileDialog::AcceptSave);
|
||||
dlg.setWindowTitle(tr("Export PDF"));
|
||||
|
||||
@@ -37,7 +37,7 @@ class ImageGuiExport GLImageBox : public QOpenGLWidget
|
||||
|
||||
public:
|
||||
|
||||
GLImageBox(QWidget * parent = 0, Qt::WindowFlags f = 0);
|
||||
GLImageBox(QWidget * parent = 0, Qt::WindowFlags f = Qt::WindowFlags());
|
||||
~GLImageBox();
|
||||
|
||||
Image::ImageBase *getImageBasePtr() { return &_image; }
|
||||
|
||||
@@ -37,7 +37,7 @@ class VisualInspection : public QDialog
|
||||
Q_OBJECT
|
||||
|
||||
public:
|
||||
VisualInspection(QWidget* parent = 0, Qt::WindowFlags fl = 0);
|
||||
VisualInspection(QWidget* parent = 0, Qt::WindowFlags fl = Qt::WindowFlags());
|
||||
~ VisualInspection();
|
||||
|
||||
void accept();
|
||||
|
||||
@@ -36,7 +36,7 @@ class DlgDecimating : public QWidget
|
||||
Q_OBJECT
|
||||
|
||||
public:
|
||||
DlgDecimating(QWidget* parent = 0, Qt::WindowFlags fl = 0);
|
||||
DlgDecimating(QWidget* parent = 0, Qt::WindowFlags fl = Qt::WindowFlags());
|
||||
~DlgDecimating();
|
||||
void setNumberOfTriangles(int);
|
||||
double tolerance() const;
|
||||
|
||||
@@ -68,7 +68,7 @@ class DlgEvaluateMeshImp : public QDialog, public App::DocumentObserver
|
||||
Q_OBJECT
|
||||
|
||||
public:
|
||||
DlgEvaluateMeshImp(QWidget* parent = 0, Qt::WindowFlags fl = 0);
|
||||
DlgEvaluateMeshImp(QWidget* parent = 0, Qt::WindowFlags fl = Qt::WindowFlags());
|
||||
~DlgEvaluateMeshImp();
|
||||
|
||||
void setMesh(Mesh::Feature*);
|
||||
@@ -146,7 +146,7 @@ class DockEvaluateMeshImp : public DlgEvaluateMeshImp
|
||||
Q_OBJECT
|
||||
|
||||
protected:
|
||||
DockEvaluateMeshImp( QWidget* parent = 0, Qt::WindowFlags fl = 0 );
|
||||
DockEvaluateMeshImp( QWidget* parent = 0, Qt::WindowFlags fl = Qt::WindowFlags() );
|
||||
~DockEvaluateMeshImp();
|
||||
void closeEvent(QCloseEvent* e);
|
||||
|
||||
|
||||
@@ -38,7 +38,7 @@ class DlgEvaluateSettings : public QDialog
|
||||
Q_OBJECT
|
||||
|
||||
public:
|
||||
DlgEvaluateSettings(QWidget* parent = 0, Qt::WindowFlags fl = 0);
|
||||
DlgEvaluateSettings(QWidget* parent = 0, Qt::WindowFlags fl = Qt::WindowFlags());
|
||||
~DlgEvaluateSettings();
|
||||
|
||||
void setNonmanifoldPointsChecked(bool);
|
||||
|
||||
@@ -34,7 +34,7 @@ class DlgRegularSolidImp : public QDialog
|
||||
Q_OBJECT
|
||||
|
||||
public:
|
||||
DlgRegularSolidImp(QWidget* parent = 0, Qt::WindowFlags fl = 0);
|
||||
DlgRegularSolidImp(QWidget* parent = 0, Qt::WindowFlags fl = Qt::WindowFlags());
|
||||
~DlgRegularSolidImp();
|
||||
|
||||
public Q_SLOTS:
|
||||
|
||||
@@ -73,7 +73,7 @@ class MeshGuiExport SmoothingDialog : public QDialog
|
||||
Q_OBJECT
|
||||
|
||||
public:
|
||||
SmoothingDialog(QWidget* parent = 0, Qt::WindowFlags fl = 0);
|
||||
SmoothingDialog(QWidget* parent = 0, Qt::WindowFlags fl = Qt::WindowFlags());
|
||||
~SmoothingDialog();
|
||||
|
||||
int iterations() const
|
||||
|
||||
@@ -52,7 +52,7 @@ class MeshGuiExport GmshWidget : public QWidget
|
||||
Q_OBJECT
|
||||
|
||||
public:
|
||||
GmshWidget(QWidget* parent = 0, Qt::WindowFlags fl = 0);
|
||||
GmshWidget(QWidget* parent = 0, Qt::WindowFlags fl = Qt::WindowFlags());
|
||||
~GmshWidget();
|
||||
void accept();
|
||||
void reject();
|
||||
@@ -90,7 +90,7 @@ class MeshGuiExport RemeshGmsh : public GmshWidget
|
||||
Q_OBJECT
|
||||
|
||||
public:
|
||||
RemeshGmsh(Mesh::Feature* mesh, QWidget* parent = 0, Qt::WindowFlags fl = 0);
|
||||
RemeshGmsh(Mesh::Feature* mesh, QWidget* parent = 0, Qt::WindowFlags fl = Qt::WindowFlags());
|
||||
~RemeshGmsh();
|
||||
|
||||
protected:
|
||||
|
||||
@@ -42,7 +42,7 @@ class MeshGuiExport RemoveComponents : public QWidget
|
||||
Q_OBJECT
|
||||
|
||||
public:
|
||||
RemoveComponents(QWidget* parent = 0, Qt::WindowFlags fl = 0);
|
||||
RemoveComponents(QWidget* parent = 0, Qt::WindowFlags fl = Qt::WindowFlags());
|
||||
~RemoveComponents();
|
||||
void reject();
|
||||
void deleteSelection();
|
||||
@@ -78,7 +78,7 @@ class MeshGuiExport RemoveComponentsDialog : public QDialog
|
||||
Q_OBJECT
|
||||
|
||||
public:
|
||||
RemoveComponentsDialog(QWidget* parent = 0, Qt::WindowFlags fl = 0);
|
||||
RemoveComponentsDialog(QWidget* parent = 0, Qt::WindowFlags fl = Qt::WindowFlags());
|
||||
~RemoveComponentsDialog();
|
||||
void reject();
|
||||
|
||||
|
||||
@@ -37,7 +37,7 @@ class Ui_Segmentation;
|
||||
class MeshGuiExport Segmentation : public QWidget
|
||||
{
|
||||
public:
|
||||
Segmentation(Mesh::Feature* mesh, QWidget* parent = 0, Qt::WindowFlags fl = 0);
|
||||
Segmentation(Mesh::Feature* mesh, QWidget* parent = 0, Qt::WindowFlags fl = Qt::WindowFlags());
|
||||
~Segmentation();
|
||||
void accept();
|
||||
|
||||
|
||||
@@ -82,7 +82,7 @@ class MeshGuiExport SegmentationBestFit : public QWidget
|
||||
Q_OBJECT
|
||||
|
||||
public:
|
||||
SegmentationBestFit(Mesh::Feature* mesh, QWidget* parent = 0, Qt::WindowFlags fl = 0);
|
||||
SegmentationBestFit(Mesh::Feature* mesh, QWidget* parent = 0, Qt::WindowFlags fl = Qt::WindowFlags());
|
||||
~SegmentationBestFit();
|
||||
void accept();
|
||||
|
||||
|
||||
@@ -44,7 +44,7 @@ class CrossSections : public QDialog
|
||||
enum Plane { XY, XZ, YZ };
|
||||
|
||||
public:
|
||||
CrossSections(const Base::BoundBox3d& bb, QWidget* parent = 0, Qt::WindowFlags fl = 0);
|
||||
CrossSections(const Base::BoundBox3d& bb, QWidget* parent = 0, Qt::WindowFlags fl = Qt::WindowFlags());
|
||||
~CrossSections();
|
||||
void accept();
|
||||
void apply();
|
||||
|
||||
@@ -47,7 +47,7 @@ class Mesh2ShapeGmsh : public MeshGui::GmshWidget
|
||||
Q_OBJECT
|
||||
|
||||
public:
|
||||
Mesh2ShapeGmsh(QWidget* parent = 0, Qt::WindowFlags fl = 0);
|
||||
Mesh2ShapeGmsh(QWidget* parent = 0, Qt::WindowFlags fl = Qt::WindowFlags());
|
||||
~Mesh2ShapeGmsh();
|
||||
|
||||
void process(App::Document* doc, const std::list<App::SubObjectT>&);
|
||||
|
||||
@@ -44,7 +44,7 @@ class CrossSections : public QDialog
|
||||
enum Plane { XY, XZ, YZ };
|
||||
|
||||
public:
|
||||
CrossSections(const Base::BoundBox3d& bb, QWidget* parent = 0, Qt::WindowFlags fl = 0);
|
||||
CrossSections(const Base::BoundBox3d& bb, QWidget* parent = 0, Qt::WindowFlags fl = Qt::WindowFlags());
|
||||
~CrossSections();
|
||||
void accept();
|
||||
void apply();
|
||||
|
||||
@@ -39,7 +39,7 @@ class DlgExtrusion : public QDialog, public Gui::SelectionObserver
|
||||
Q_OBJECT
|
||||
|
||||
public:
|
||||
DlgExtrusion(QWidget* parent = 0, Qt::WindowFlags fl = 0);
|
||||
DlgExtrusion(QWidget* parent = 0, Qt::WindowFlags fl = Qt::WindowFlags());
|
||||
~DlgExtrusion();
|
||||
void accept();
|
||||
void apply();
|
||||
|
||||
@@ -81,7 +81,7 @@ class DlgFilletEdges : public QWidget, public Gui::SelectionObserver
|
||||
public:
|
||||
enum FilletType { FILLET, CHAMFER };
|
||||
|
||||
DlgFilletEdges(FilletType type, Part::FilletBase*, QWidget* parent = 0, Qt::WindowFlags fl = 0);
|
||||
DlgFilletEdges(FilletType type, Part::FilletBase*, QWidget* parent = 0, Qt::WindowFlags fl = Qt::WindowFlags());
|
||||
~DlgFilletEdges();
|
||||
bool accept();
|
||||
|
||||
@@ -121,7 +121,7 @@ class FilletEdgesDialog : public QDialog
|
||||
Q_OBJECT
|
||||
|
||||
public:
|
||||
FilletEdgesDialog(DlgFilletEdges::FilletType type, Part::FilletBase* fillet, QWidget* parent = 0, Qt::WindowFlags fl = 0);
|
||||
FilletEdgesDialog(DlgFilletEdges::FilletType type, Part::FilletBase* fillet, QWidget* parent = 0, Qt::WindowFlags fl = Qt::WindowFlags());
|
||||
~FilletEdgesDialog();
|
||||
void accept();
|
||||
|
||||
@@ -134,7 +134,7 @@ class DlgChamferEdges : public DlgFilletEdges
|
||||
Q_OBJECT
|
||||
|
||||
public:
|
||||
DlgChamferEdges(Part::FilletBase*, QWidget* parent = 0, Qt::WindowFlags fl = 0);
|
||||
DlgChamferEdges(Part::FilletBase*, QWidget* parent = 0, Qt::WindowFlags fl = Qt::WindowFlags());
|
||||
~DlgChamferEdges();
|
||||
|
||||
protected:
|
||||
|
||||
@@ -34,7 +34,7 @@ class DlgPartBoxImp : public Gui::LocationDialogUiImp
|
||||
Q_OBJECT
|
||||
|
||||
public:
|
||||
DlgPartBoxImp(QWidget* parent = 0, Qt::WindowFlags fl = 0);
|
||||
DlgPartBoxImp(QWidget* parent = 0, Qt::WindowFlags fl = Qt::WindowFlags());
|
||||
~DlgPartBoxImp();
|
||||
};
|
||||
|
||||
|
||||
@@ -34,7 +34,7 @@ class DlgPartCylinderImp : public Gui::LocationDialogUiImp
|
||||
Q_OBJECT
|
||||
|
||||
public:
|
||||
DlgPartCylinderImp(QWidget* parent = 0, Qt::WindowFlags fl = 0);
|
||||
DlgPartCylinderImp(QWidget* parent = 0, Qt::WindowFlags fl = Qt::WindowFlags());
|
||||
~DlgPartCylinderImp();
|
||||
|
||||
double getRadius() const;
|
||||
|
||||
@@ -33,7 +33,7 @@ class DlgPartImportIgesImp : public QDialog
|
||||
Q_OBJECT
|
||||
|
||||
public:
|
||||
DlgPartImportIgesImp( QWidget* parent = 0, Qt::WindowFlags fl = 0 );
|
||||
DlgPartImportIgesImp( QWidget* parent = 0, Qt::WindowFlags fl = Qt::WindowFlags() );
|
||||
~DlgPartImportIgesImp();
|
||||
|
||||
public Q_SLOTS:
|
||||
|
||||
@@ -34,7 +34,7 @@ class DlgPartImportStepImp : public QDialog
|
||||
Q_OBJECT
|
||||
|
||||
public:
|
||||
DlgPartImportStepImp( QWidget* parent = 0, Qt::WindowFlags fl = 0 );
|
||||
DlgPartImportStepImp( QWidget* parent = 0, Qt::WindowFlags fl = Qt::WindowFlags() );
|
||||
~DlgPartImportStepImp();
|
||||
|
||||
public Q_SLOTS:
|
||||
|
||||
@@ -36,7 +36,7 @@ class DlgRevolution : public QDialog, public Gui::SelectionObserver
|
||||
Q_OBJECT
|
||||
|
||||
public:
|
||||
DlgRevolution(QWidget* parent = 0, Qt::WindowFlags fl = 0);
|
||||
DlgRevolution(QWidget* parent = 0, Qt::WindowFlags fl = Qt::WindowFlags());
|
||||
~DlgRevolution();
|
||||
void accept();
|
||||
|
||||
|
||||
@@ -38,7 +38,7 @@ class DlgPointsReadImp : public QDialog
|
||||
Q_OBJECT
|
||||
|
||||
public:
|
||||
DlgPointsReadImp(const char *FileName, QWidget* parent = nullptr, Qt::WindowFlags fl = 0 );
|
||||
DlgPointsReadImp(const char *FileName, QWidget* parent = nullptr, Qt::WindowFlags fl = Qt::WindowFlags() );
|
||||
~DlgPointsReadImp();
|
||||
|
||||
private:
|
||||
|
||||
@@ -41,7 +41,7 @@ class Segmentation : public QWidget
|
||||
Q_OBJECT
|
||||
|
||||
public:
|
||||
Segmentation(Mesh::Feature* mesh, QWidget* parent = 0, Qt::WindowFlags fl = 0);
|
||||
Segmentation(Mesh::Feature* mesh, QWidget* parent = 0, Qt::WindowFlags fl = Qt::WindowFlags());
|
||||
~Segmentation();
|
||||
void accept();
|
||||
|
||||
|
||||
@@ -43,7 +43,7 @@ class SegmentationManual : public QWidget
|
||||
Q_OBJECT
|
||||
|
||||
public:
|
||||
SegmentationManual(QWidget* parent = 0, Qt::WindowFlags fl = 0);
|
||||
SegmentationManual(QWidget* parent = 0, Qt::WindowFlags fl = Qt::WindowFlags());
|
||||
~SegmentationManual();
|
||||
void reject();
|
||||
void createSegment();
|
||||
|
||||
@@ -85,35 +85,35 @@ void StartGui::Workbench::loadStartPage()
|
||||
std::string escapedstr = Base::Tools::escapedUnicodeFromUtf8(utf8Title);
|
||||
QByteArray cmd;
|
||||
QTextStream str(&cmd);
|
||||
str << "import WebGui,sys,Start" << endl;
|
||||
str << "from StartPage import StartPage" << endl;
|
||||
str << "import WebGui,sys,Start" << Qt::endl;
|
||||
str << "from StartPage import StartPage" << Qt::endl;
|
||||
str << endl;
|
||||
str << "class WebPage(object):" << endl;
|
||||
str << " def __init__(self):" << endl;
|
||||
str << " self.browser=WebGui.openBrowserWindow(u'" << escapedstr.c_str() << "')" << endl;
|
||||
str << "class WebPage(object):" << Qt::endl;
|
||||
str << " def __init__(self):" << Qt::endl;
|
||||
str << " self.browser=WebGui.openBrowserWindow(u'" << escapedstr.c_str() << "')" << Qt::endl;
|
||||
#if defined(FC_OS_WIN32)
|
||||
str << " self.browser.setHtml(StartPage.handle(), App.getResourceDir() + 'Mod/Start/StartPage/')" << endl;
|
||||
str << " self.browser.setHtml(StartPage.handle(), App.getResourceDir() + 'Mod/Start/StartPage/')" << Qt::endl;
|
||||
#else
|
||||
str << " self.browser.setHtml(StartPage.handle(), 'file://' + App.getResourceDir() + 'Mod/Start/StartPage/')" << endl;
|
||||
str << " self.browser.setHtml(StartPage.handle(), 'file://' + App.getResourceDir() + 'Mod/Start/StartPage/')" << Qt::endl;
|
||||
#endif
|
||||
str << " def onChange(self, par, reason):" << endl;
|
||||
str << " if reason == 'RecentFiles':" << endl;
|
||||
str << " def onChange(self, par, reason):" << Qt::endl;
|
||||
str << " if reason == 'RecentFiles':" << Qt::endl;
|
||||
#if defined(FC_OS_WIN32)
|
||||
str << " self.browser.setHtml(StartPage.handle(), App.getResourceDir() + 'Mod/Start/StartPage/')" << endl;
|
||||
str << " self.browser.setHtml(StartPage.handle(), App.getResourceDir() + 'Mod/Start/StartPage/')" << Qt::endl;
|
||||
#else
|
||||
str << " self.browser.setHtml(StartPage.handle(), 'file://' + App.getResourceDir() + 'Mod/Start/StartPage/')" << endl;
|
||||
str << " self.browser.setHtml(StartPage.handle(), 'file://' + App.getResourceDir() + 'Mod/Start/StartPage/')" << Qt::endl;
|
||||
#endif
|
||||
str << Qt::endl;
|
||||
str << "class WebView(object):" << Qt::endl;
|
||||
str << " def __init__(self):" << Qt::endl;
|
||||
str << " self.pargrp = FreeCAD.ParamGet('User parameter:BaseApp/Preferences/RecentFiles')" << Qt::endl;
|
||||
str << " self.webPage = WebPage()" << Qt::endl;
|
||||
str << " self.pargrp.Attach(self.webPage)" << Qt::endl;
|
||||
str << " def __del__(self):" << Qt::endl;
|
||||
str << " self.pargrp.Detach(self.webPage)" << Qt::endl;
|
||||
str << endl;
|
||||
str << "class WebView(object):" << endl;
|
||||
str << " def __init__(self):" << endl;
|
||||
str << " self.pargrp = FreeCAD.ParamGet('User parameter:BaseApp/Preferences/RecentFiles')" << endl;
|
||||
str << " self.webPage = WebPage()" << endl;
|
||||
str << " self.pargrp.Attach(self.webPage)" << endl;
|
||||
str << " def __del__(self):" << endl;
|
||||
str << " self.pargrp.Detach(self.webPage)" << endl;
|
||||
str << endl;
|
||||
str << "webView=WebView()" << endl;
|
||||
str << "StartPage.checkPostOpenStartPage()" << endl;
|
||||
str << "webView=WebView()" << Qt::endl;
|
||||
str << "StartPage.checkPostOpenStartPage()" << Qt::endl;
|
||||
|
||||
Base::Interpreter().runString(cmd);
|
||||
// Gui::Command::runCommand(Gui::Command::Gui, cmd);
|
||||
|
||||
@@ -60,7 +60,7 @@ public:
|
||||
static bool hasInstance();
|
||||
|
||||
protected:
|
||||
UnitTestDialog(QWidget* parent = 0, Qt::WindowFlags f = 0);
|
||||
UnitTestDialog(QWidget* parent = 0, Qt::WindowFlags f = Qt::WindowFlags());
|
||||
~UnitTestDialog();
|
||||
void setProgressColor(const QColor& col);
|
||||
|
||||
|
||||
@@ -380,7 +380,7 @@ void WebView::triggerContextMenuAction(int id)
|
||||
* name 'name'.
|
||||
*/
|
||||
BrowserView::BrowserView(QWidget* parent)
|
||||
: MDIView(0,parent,0),
|
||||
: MDIView(0,parent,Qt::WindowFlags()),
|
||||
WindowParameter( "Browser" ),
|
||||
isLoading(false)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user