OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #include "remoting/client/plugin/chromoting_instance.h" | 5 #include "remoting/client/plugin/chromoting_instance.h" |
6 | 6 |
7 #include <string> | 7 #include <string> |
8 #include <vector> | 8 #include <vector> |
9 | 9 |
10 #include <nacl_io/nacl_io.h> | 10 #include <nacl_io/nacl_io.h> |
(...skipping 22 matching lines...) Expand all Loading... |
33 #include "ppapi/cpp/input_event.h" | 33 #include "ppapi/cpp/input_event.h" |
34 #include "ppapi/cpp/private/uma_private.h" | 34 #include "ppapi/cpp/private/uma_private.h" |
35 #include "ppapi/cpp/rect.h" | 35 #include "ppapi/cpp/rect.h" |
36 #include "ppapi/cpp/var_array_buffer.h" | 36 #include "ppapi/cpp/var_array_buffer.h" |
37 #include "ppapi/cpp/var_dictionary.h" | 37 #include "ppapi/cpp/var_dictionary.h" |
38 #include "remoting/base/constants.h" | 38 #include "remoting/base/constants.h" |
39 #include "remoting/base/util.h" | 39 #include "remoting/base/util.h" |
40 #include "remoting/client/chromoting_client.h" | 40 #include "remoting/client/chromoting_client.h" |
41 #include "remoting/client/normalizing_input_filter_cros.h" | 41 #include "remoting/client/normalizing_input_filter_cros.h" |
42 #include "remoting/client/normalizing_input_filter_mac.h" | 42 #include "remoting/client/normalizing_input_filter_mac.h" |
| 43 #include "remoting/client/normalizing_input_filter_win.h" |
43 #include "remoting/client/plugin/delegating_signal_strategy.h" | 44 #include "remoting/client/plugin/delegating_signal_strategy.h" |
44 #include "remoting/client/plugin/pepper_audio_player.h" | 45 #include "remoting/client/plugin/pepper_audio_player.h" |
45 #include "remoting/client/plugin/pepper_main_thread_task_runner.h" | 46 #include "remoting/client/plugin/pepper_main_thread_task_runner.h" |
46 #include "remoting/client/plugin/pepper_mouse_locker.h" | 47 #include "remoting/client/plugin/pepper_mouse_locker.h" |
47 #include "remoting/client/plugin/pepper_port_allocator.h" | 48 #include "remoting/client/plugin/pepper_port_allocator.h" |
48 #include "remoting/client/plugin/pepper_video_renderer_2d.h" | 49 #include "remoting/client/plugin/pepper_video_renderer_2d.h" |
49 #include "remoting/client/plugin/pepper_video_renderer_3d.h" | 50 #include "remoting/client/plugin/pepper_video_renderer_3d.h" |
50 #include "remoting/client/software_video_renderer.h" | 51 #include "remoting/client/software_video_renderer.h" |
51 #include "remoting/client/token_fetcher_proxy.h" | 52 #include "remoting/client/token_fetcher_proxy.h" |
52 #include "remoting/protocol/connection_to_host.h" | 53 #include "remoting/protocol/connection_to_host.h" |
(...skipping 572 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
625 std::string key_filter; | 626 std::string key_filter; |
626 if (!data.GetString("keyFilter", &key_filter)) { | 627 if (!data.GetString("keyFilter", &key_filter)) { |
627 NOTREACHED(); | 628 NOTREACHED(); |
628 normalizing_input_filter_.reset(new protocol::InputFilter(&key_mapper_)); | 629 normalizing_input_filter_.reset(new protocol::InputFilter(&key_mapper_)); |
629 } else if (key_filter == "mac") { | 630 } else if (key_filter == "mac") { |
630 normalizing_input_filter_.reset( | 631 normalizing_input_filter_.reset( |
631 new NormalizingInputFilterMac(&key_mapper_)); | 632 new NormalizingInputFilterMac(&key_mapper_)); |
632 } else if (key_filter == "cros") { | 633 } else if (key_filter == "cros") { |
633 normalizing_input_filter_.reset( | 634 normalizing_input_filter_.reset( |
634 new NormalizingInputFilterCros(&key_mapper_)); | 635 new NormalizingInputFilterCros(&key_mapper_)); |
| 636 } else if (key_filter == "windows") { |
| 637 normalizing_input_filter_.reset( |
| 638 new NormalizingInputFilterWin(&key_mapper_)); |
635 } else { | 639 } else { |
636 DCHECK(key_filter.empty()); | 640 DCHECK(key_filter.empty()); |
637 normalizing_input_filter_.reset(new protocol::InputFilter(&key_mapper_)); | 641 normalizing_input_filter_.reset(new protocol::InputFilter(&key_mapper_)); |
638 } | 642 } |
639 input_handler_.set_input_stub(normalizing_input_filter_.get()); | 643 input_handler_.set_input_stub(normalizing_input_filter_.get()); |
640 | 644 |
641 // Try initializing 3D video renderer. | 645 // Try initializing 3D video renderer. |
642 video_renderer_.reset(new PepperVideoRenderer3D()); | 646 video_renderer_.reset(new PepperVideoRenderer3D()); |
643 if (!video_renderer_->Initialize(this, context_, this, &perf_tracker_)) | 647 if (!video_renderer_->Initialize(this, context_, this, &perf_tracker_)) |
644 video_renderer_.reset(); | 648 video_renderer_.reset(); |
(...skipping 496 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1141 if (is_custom_counts_histogram) { | 1145 if (is_custom_counts_histogram) { |
1142 uma.HistogramCustomCounts(histogram_name, value, histogram_min, | 1146 uma.HistogramCustomCounts(histogram_name, value, histogram_min, |
1143 histogram_max, histogram_buckets); | 1147 histogram_max, histogram_buckets); |
1144 } else { | 1148 } else { |
1145 uma.HistogramCustomTimes(histogram_name, value, histogram_min, | 1149 uma.HistogramCustomTimes(histogram_name, value, histogram_min, |
1146 histogram_max, histogram_buckets); | 1150 histogram_max, histogram_buckets); |
1147 } | 1151 } |
1148 } | 1152 } |
1149 | 1153 |
1150 } // namespace remoting | 1154 } // namespace remoting |
OLD | NEW |