QmlDesigner: Use isInteger, isFloat in isNumber

Change-Id: I20b81b54c0f7758e9e864ff50174ac2d7527fb38
Reviewed-by: Knud Dollereder <knud.dollereder@qt.io>
Reviewed-by: Qt CI Patch Build Bot <ci_patchbuild_bot@qt.io>
This commit is contained in:
Thomas Hartmann
2023-11-02 15:24:27 +01:00
parent f466ac7ce2
commit 4d1a210060

View File

@@ -2600,10 +2600,7 @@ bool NodeMetaInfo::isNumber() const
return false; return false;
} }
auto type = simplifiedTypeName(); return isFloat() || isInteger();
return type == "int" || type == "uint" || type == "float" || type == "double"
|| type == "real";
} }
} }
@@ -3079,7 +3076,7 @@ bool NodeMetaInfo::isInteger() const
auto type = simplifiedTypeName(); auto type = simplifiedTypeName();
return type == "int" || type == "integer"; return type == "int" || type == "integer" || type == "uint";
} }
} }
@@ -3101,7 +3098,7 @@ bool NodeMetaInfo::isFloat() const
auto type = simplifiedTypeName(); auto type = simplifiedTypeName();
return type == "qreal" || type == "double" || type == "float"; return type == "qreal" || type == "double" || type == "float" || type == "real";
} }
} }