Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1268)

Side by Side Diff: blimp/net/input_message_generator.h

Issue 1426993008: Serialize a subset of WebInputEvents to protobufs. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Re-add fatal log. Created 5 years ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « blimp/net/blimp_message_multiplexer_unittest.cc ('k') | blimp/net/input_message_generator.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
(Empty)
1 // Copyright 2015 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4
5 #ifndef BLIMP_NET_INPUT_MESSAGE_GENERATOR_H_
6 #define BLIMP_NET_INPUT_MESSAGE_GENERATOR_H_
7
8 #include "base/macros.h"
9 #include "base/memory/scoped_ptr.h"
10 #include "blimp/net/blimp_net_export.h"
11 #include "net/base/completion_callback.h"
12
13 namespace blink {
14 class WebInputEvent;
15 }
16
17 namespace blimp {
18
19 class BlimpMessage;
20 class BlimpMessageProcessor;
21
22 // Handles creating serialized InputMessage protos from a stream of
23 // WebInputEvents. This class may be stateful to optimize the size of the
24 // serialized transmission data. See InputMessageProcessor for the deserialize
25 // code.
26 class BLIMP_NET_EXPORT InputMessageGenerator {
27 public:
28 InputMessageGenerator();
29 ~InputMessageGenerator();
30
31 // Builds a BlimpMessage from |event| that has the basic input event fields
32 // populated. This might make use of state sent from previous
33 // BlimpMessage::INPUT messages. It is up to the caller to populate the
34 // non-input fields and to send the BlimpMessage.
35 scoped_ptr<BlimpMessage> GenerateMessage(const blink::WebInputEvent& event);
36
37 private:
38 DISALLOW_COPY_AND_ASSIGN(InputMessageGenerator);
39 };
40
41 } // namespace blimp
42
43 #endif // BLIMP_NET_INPUT_MESSAGE_GENERATOR_H_
OLDNEW
« no previous file with comments | « blimp/net/blimp_message_multiplexer_unittest.cc ('k') | blimp/net/input_message_generator.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698