#102 FIX#772
#102 FIX#772TikhomirovSergey merged 4 commits intoappium:masterappium/java-client:masterfrom TikhomirovSergey:masterCopy head branch name to clipboard
Conversation
|
| } else if (size == 1) { | ||
| } else { | ||
| //android doesn't like having multi-touch actions with only a single TouchAction... | ||
| performsTouchActions.performTouchAction(actions.build().get(0)); |
There was a problem hiding this comment.
perhaps touchActions.get(0) ?
There was a problem hiding this comment.
yes. Will improve soon
| checkArgument(touchActions.size() > 0, | ||
| "MultiTouch action must have at least one TouchAction added before it can be performed"); | ||
| if (touchActions.size() > 1) { | ||
| performsTouchActions.performMultiTouchAction(this); |
There was a problem hiding this comment.
you can returns this immediately here, so then else block is not needed
There was a problem hiding this comment.
@mykola-mokhnach
I can't understand how to do it
performsTouchActions.performMultiTouchAction(this);is void
performsTouchActions.performTouchAction(touchActions.get(0));returns TouchAction
There was a problem hiding this comment.
if (touchActions.size() > 1) {
performsTouchActions.performMultiTouchAction(this);
return this;
}
//android doesn't like having multi-touch actions with only a single TouchAction...
performsTouchActions.performTouchAction(touchActions.get(0));
return this;| touchActions.forEach(action -> { | ||
| listOfActionChains.add(action.getParameters().get("actions")); | ||
| }); | ||
| touchActions.forEach(action -> |
There was a problem hiding this comment.
why not to replace it with something like ImmutableList.Builder<Object> listOfActionChains = ImmutableList.copyOf(touchActions.stream().map(x -> x.getParameters().get("actions"))); ?
|
@mykola-mokhnach There is one more change. |
Change list
IllegalArgumentExceptionwhen no action is defined.#102
Types of changes