| Index: content/renderer/gpu/actions_runner.h
|
| diff --git a/content/renderer/gpu/actions_runner.h b/content/renderer/gpu/actions_runner.h
|
| new file mode 100644
|
| index 0000000000000000000000000000000000000000..d302264ff6401b908717c5d4e9206c941129fcff
|
| --- /dev/null
|
| +++ b/content/renderer/gpu/actions_runner.h
|
| @@ -0,0 +1,55 @@
|
| +// Copyright (c) 2016 The Chromium Authors. All rights reserved.
|
| +// Use of this source code is governed by a BSD-style license that can be
|
| +// found in the LICENSE file.
|
| +
|
| +#ifndef CONTENT_RENDERER_GPU_ACTION_RUNNER_H_
|
| +#define CONTENT_RENDERER_GPU_ACTION_RUNNER_H_
|
| +
|
| +#include <cstddef>
|
| +#include <set>
|
| +#include <string>
|
| +
|
| +#include "content/common/input/synthetic_pointer_action_list_params.h"
|
| +
|
| +namespace base {
|
| +class DictionaryValue;
|
| +class ListValue;
|
| +} // namespace base
|
| +
|
| +namespace content {
|
| +
|
| +class ActionsRunner {
|
| + public:
|
| + ActionsRunner(base::Value* value);
|
| + virtual ~ActionsRunner();
|
| + bool ParseSources();
|
| + void Run();
|
| + size_t longest_action_sequence() { return longest_action_sequence_; }
|
| + std::string error_message() { return error_message_; }
|
| + std::unique_ptr<SyntheticPointerActionListParams> gesture_params() {
|
| + return std::move(gesture_params_);
|
| + }
|
| +
|
| + private:
|
| + bool ParsePointerActions(const base::DictionaryValue& pointer_actions);
|
| + bool ParseActions(const base::ListValue& actions);
|
| + bool ParseAction(const base::DictionaryValue& action,
|
| + SyntheticPointerActionListParams::ParamList& param_list);
|
| +
|
| + std::unique_ptr<SyntheticPointerActionListParams> gesture_params_;
|
| + std::vector<SyntheticPointerActionListParams::ParamList>
|
| + pointer_actions_list_;
|
| + size_t longest_action_sequence_;
|
| + std::set<int> ids_;
|
| + size_t i, j;
|
| + std::string error_message_;
|
| +
|
| + // XXX: this probably gets deleted with the v8 context, so be more careful
|
| + // about handling it
|
| + base::Value* value_;
|
| + int index_;
|
| +};
|
| +
|
| +} // namespace content
|
| +
|
| +#endif // CONTENT_RENDERER_GPU_ACTION_RUNNER_H_
|
|
|