uitest: Rename the "SET" to "TYPE" for Edit boxes + implement the real "SET".

To be consistent with the other controls: "TYPE" actually enters the
characters one by one, while "SET" sets it as a whole.

Change-Id: I967dc270b1d92fe76107732a511cc3e70d3d65c0
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/104435
Tested-by: Andras Timar <andras.timar@collabora.com>
Reviewed-by: Andras Timar <andras.timar@collabora.com>
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/105739
Tested-by: Jenkins
This commit is contained in:
Jan Holesovsky
2020-11-15 15:41:56 +01:00
committed by Andras Timar
parent ea3cda0813
commit 706aff5098
2 changed files with 13 additions and 2 deletions
@@ -35,7 +35,7 @@ class ConfigureDialog(UITestCase):
initialEntryCount = get_state_as_dict(xfunc)["Children"]
self.assertTrue(initialEntryCount != 0)
xSearch.executeAction("SET", mkPropertyValues({"TEXT":"format"}))
xSearch.executeAction("TYPE", mkPropertyValues({"TEXT":"format"}))
# Wait for the search/filter op to be completed
timeout = time.time() + 1
+12 -1
View File
@@ -720,7 +720,7 @@ void EditUIObject::execute(const OUString& rAction,
const StringMap& rParameters)
{
bool bHandled = true;
if (rAction == "SET")
if (rAction == "TYPE")
{
if (rParameters.find("TEXT") != rParameters.end())
{
@@ -743,6 +743,17 @@ void EditUIObject::execute(const OUString& rAction,
bHandled = false;
}
}
else if (rAction == "SET")
{
auto it = rParameters.find("TEXT");
if (it != rParameters.end())
{
mxEdit->SetText(it->second);
mxEdit->Modify();
}
else
bHandled = false;
}
else if (rAction == "SELECT")
{
if (rParameters.find("FROM") != rParameters.end() &&