Index: remoting/client/plugin/chromoting_scriptable_object.cc |
diff --git a/remoting/client/plugin/chromoting_scriptable_object.cc b/remoting/client/plugin/chromoting_scriptable_object.cc |
index 51e1f5a6c93d65ca5fe50ea1d130ad7f4e7f4c4f..410a4e3dea05143169dca41283ccad69d78ba3de 100644 |
--- a/remoting/client/plugin/chromoting_scriptable_object.cc |
+++ b/remoting/client/plugin/chromoting_scriptable_object.cc |
@@ -102,6 +102,7 @@ void ChromotingScriptableObject::Init() { |
AddMethod("submitLoginInfo", &ChromotingScriptableObject::DoSubmitLogin); |
AddMethod("setScaleToFit", &ChromotingScriptableObject::DoSetScaleToFit); |
AddMethod("onIq", &ChromotingScriptableObject::DoOnIq); |
+ AddMethod("releaseAllKeys", &ChromotingScriptableObject::DoReleaseAllKeys); |
} |
bool ChromotingScriptableObject::HasProperty(const Var& name, Var* exception) { |
@@ -457,4 +458,14 @@ Var ChromotingScriptableObject::DoOnIq(const std::vector<Var>& args, |
return Var(); |
} |
+Var ChromotingScriptableObject::DoReleaseAllKeys( |
+ const std::vector<pp::Var>& args, pp::Var* exception) { |
+ if (args.size() != 0) { |
+ *exception = Var("Usage: DoReleaseAllKeys()"); |
+ return Var(); |
+ } |
+ instance_->ReleaseAllKeys(); |
+ return Var(); |
+} |
+ |
} // namespace remoting |