| Index: plugins/org.chromium.sdk/src/org/chromium/sdk/JsVariable.java
|
| diff --git a/plugins/org.chromium.sdk/src/org/chromium/sdk/JsVariable.java b/plugins/org.chromium.sdk/src/org/chromium/sdk/JsVariable.java
|
| index a291a028b89fe40ecc9f354fe8f745f7f4fdd573..341edcb799d39b216d831449c74101872f018f68 100755
|
| --- a/plugins/org.chromium.sdk/src/org/chromium/sdk/JsVariable.java
|
| +++ b/plugins/org.chromium.sdk/src/org/chromium/sdk/JsVariable.java
|
| @@ -10,15 +10,6 @@ package org.chromium.sdk;
|
| public interface JsVariable {
|
|
|
| /**
|
| - * A callback to use while setting a variable value.
|
| - */
|
| - interface SetValueCallback {
|
| - void success();
|
| -
|
| - void failure(String errorMessage);
|
| - }
|
| -
|
| - /**
|
| * @return whether it is possible to read this variable
|
| */
|
| boolean isReadable();
|
| @@ -54,13 +45,35 @@ public interface JsVariable {
|
| *
|
| * @param newValue to set
|
| * @param callback to report the operation result to
|
| + * @param syncCallback to report the end of any processing
|
| * @see #isMutable()
|
| * @throws UnsupportedOperationException if this variable is not mutable
|
| */
|
| - void setValue(String newValue, SetValueCallback callback)
|
| + RelayOk setValue(JsValue newValue, SetValueCallback callback, SyncCallback syncCallback)
|
| throws UnsupportedOperationException;
|
|
|
| /**
|
| + * A callback to use while setting a variable value.
|
| + */
|
| + interface SetValueCallback {
|
| + /**
|
| + * Variable is successfully updated. New value is available in {@link JsVariable#getValue()}.
|
| + */
|
| + void success();
|
| +
|
| + /**
|
| + * Variable hasn't been updated because exception was thrown. Most probably this exception was
|
| + * thrown from setter function.
|
| + */
|
| + void exceptionThrown(JsValue exception);
|
| +
|
| + /**
|
| + * Variable hasn't been updated for unknown reason.
|
| + */
|
| + void failure(Exception cause);
|
| + }
|
| +
|
| + /**
|
| * Returns object property data if variable is an object property and its descriptor
|
| * is available.
|
| */
|
|
|