Skip to content

Commit

Permalink
QInputDialog::getInteger() is obsolete in Qt4. Replace it with getInt().
Browse files Browse the repository at this point in the history
This change is Qt4/Qt5 neutral.
  • Loading branch information
f3nix authored and wwmayer committed Dec 22, 2015
1 parent e6379ea commit 99ca18f
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions src/Gui/DlgParameterImp.cpp
Expand Up @@ -662,7 +662,7 @@ void ParameterValue::onCreateIntItem()
}
}

int val = QInputDialog::getInteger(this, QObject::tr("New integer item"), QObject::tr("Enter your number:"),
int val = QInputDialog::getInt(this, QObject::tr("New integer item"), QObject::tr("Enter your number:"),
0, -2147483647, 2147483647, 1, &ok);

if ( ok )
Expand Down Expand Up @@ -946,7 +946,7 @@ ParameterInt::~ParameterInt()
void ParameterInt::changeValue()
{
bool ok;
int num = QInputDialog::getInteger(treeWidget(), QObject::tr("Change value"), QObject::tr("Enter your number:"),
int num = QInputDialog::getInt(treeWidget(), QObject::tr("Change value"), QObject::tr("Enter your number:"),
text(2).toInt(), -2147483647, 2147483647, 1, &ok);
if ( ok )
{
Expand Down
2 changes: 1 addition & 1 deletion src/Mod/Mesh/Gui/Command.cpp
Expand Up @@ -1540,7 +1540,7 @@ void CmdMeshFillupHoles::activated(int iMsg)
{
std::vector<App::DocumentObject*> meshes = getSelection().getObjectsOfType(Mesh::Feature::getClassTypeId());
bool ok;
int FillupHolesOfLength = QInputDialog::getInteger(Gui::getMainWindow(), QObject::tr("Fill holes"),
int FillupHolesOfLength = QInputDialog::getInt(Gui::getMainWindow(), QObject::tr("Fill holes"),
QObject::tr("Fill holes with maximum number of edges:"), 3, 3, 10000, 1, &ok);
if (!ok) return;
openCommand("Fill up holes");
Expand Down

0 comments on commit 99ca18f

Please sign in to comment.