Skip to content

Commit

Permalink
Allowing duration property of pause actions to be omitted for IE
Browse files Browse the repository at this point in the history
  • Loading branch information
jimevans committed Oct 10, 2018
1 parent 65364c5 commit addf70b
Show file tree
Hide file tree
Showing 6 changed files with 28 additions and 12 deletions.
8 changes: 4 additions & 4 deletions cpp/iedriver/IEDriver.rc
Original file line number Diff line number Diff line change
Expand Up @@ -50,8 +50,8 @@ END
//

VS_VERSION_INFO VERSIONINFO
FILEVERSION 3,14,0,11
PRODUCTVERSION 3,14,0,11
FILEVERSION 3,14,0,12
PRODUCTVERSION 3,14,0,12
FILEFLAGSMASK 0x3fL
#ifdef _DEBUG
FILEFLAGS 0x1L
Expand All @@ -68,12 +68,12 @@ BEGIN
BEGIN
VALUE "CompanyName", "Software Freedom Conservancy"
VALUE "FileDescription", "Driver library for the IE driver"
VALUE "FileVersion", "3.14.0.11"
VALUE "FileVersion", "3.14.0.12"
VALUE "InternalName", "IEDriver.dll"
VALUE "LegalCopyright", "Copyright (C) 2018"
VALUE "OriginalFilename", "IEDriver.dll"
VALUE "ProductName", "Selenium WebDriver"
VALUE "ProductVersion", "3.14.0.11"
VALUE "ProductVersion", "3.14.0.12"
END
END
BLOCK "VarFileInfo"
Expand Down
11 changes: 7 additions & 4 deletions cpp/iedriver/InputManager.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -198,9 +198,9 @@ int InputManager::GetTicks(const Json::Value& sequences, Json::Value* ticks) {
if (action.isMember("type") &&
action["type"].isString() &&
action["type"].asString() == "pause") {
if (!action.isMember("duration") ||
action["duration"].type() != Json::ValueType::intValue ||
action["duration"].asInt() < 0) {
if (action.isMember("duration") &&
(action["duration"].type() != Json::ValueType::intValue ||
action["duration"].asInt() < 0)) {
return EINVALIDARGUMENT;
}
if (device_type == "key") {
Expand Down Expand Up @@ -631,7 +631,10 @@ bool InputManager::IsSingleKey(const std::wstring& input) {
int InputManager::Pause(BrowserHandle browser_wrapper,
const Json::Value& pause_action) {
int status_code = 0;
int duration = pause_action["duration"].asInt();
int duration = 0;
if (pause_action.isMember("duration")) {
duration = pause_action["duration"].asInt();
}
if (duration > 0) {
this->AddPauseInput(browser_wrapper->GetContentWindowHandle(), duration);
}
Expand Down
13 changes: 13 additions & 0 deletions cpp/iedriverserver/CHANGELOG
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,19 @@ available via the project downloads page. Changes in "revision" field indicate
private releases checked into the prebuilts directory of the source tree, but
not made generally available on the downloads page.

v3.14.0.12
==========
* Allowed duration property of pause actions to be omitted.
* Cleaned up variant copying for getElementAttribute command.
* Expanded inline element detection for obscured elements. This commit
expands on the hack that was introduced in 3.14.0.11. It turns out
that <label> elements are not the only ones to suffer from issues
with elementsFromPoint. Rather, we now check for all types of inline
elements. This change also refactors the calculation of the hit-
testing point for calling elementsFromPoint in the first place, as
it only makes sense to call from within the context of the element's
document (omitting frames).

v3.14.0.11
==========
* Added hack to obscured element check for label elements. As per the
Expand Down
8 changes: 4 additions & 4 deletions cpp/iedriverserver/IEDriverServer.rc
Original file line number Diff line number Diff line change
Expand Up @@ -50,8 +50,8 @@ END
//

VS_VERSION_INFO VERSIONINFO
FILEVERSION 3,14,0,11
PRODUCTVERSION 3,14,0,11
FILEVERSION 3,14,0,12
PRODUCTVERSION 3,14,0,12
FILEFLAGSMASK 0x3fL
#ifdef _DEBUG
FILEFLAGS 0x1L
Expand All @@ -68,12 +68,12 @@ BEGIN
BEGIN
VALUE "CompanyName", "Software Freedom Conservancy"
VALUE "FileDescription", "Command line server for the IE driver"
VALUE "FileVersion", "3.14.0.11"
VALUE "FileVersion", "3.14.0.12"
VALUE "InternalName", "IEDriverServer.exe"
VALUE "LegalCopyright", "Copyright (C) 2018"
VALUE "OriginalFilename", "IEDriverServer.exe"
VALUE "ProductName", "Selenium WebDriver"
VALUE "ProductVersion", "3.14.0.11"
VALUE "ProductVersion", "3.14.0.12"
END
END
BLOCK "VarFileInfo"
Expand Down
Binary file modified cpp/prebuilt/Win32/Release/IEDriverServer.exe
Binary file not shown.
Binary file modified cpp/prebuilt/x64/Release/IEDriverServer.exe
Binary file not shown.

0 comments on commit addf70b

Please sign in to comment.