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

Unified Diff: content/common/gpu/gpu_channel_manager.cc

Issue 634313002: Add mouse input forwarding to gpu service (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: IPC passes ValueState Created 6 years, 1 month 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 side-by-side diff with in-line comments
Download patch
Index: content/common/gpu/gpu_channel_manager.cc
diff --git a/content/common/gpu/gpu_channel_manager.cc b/content/common/gpu/gpu_channel_manager.cc
index a073e20151edce4dc033a6d9e54bf3c0196b214a..3c64bc28966f161a5e63cebfaf60604c43239c89 100644
--- a/content/common/gpu/gpu_channel_manager.cc
+++ b/content/common/gpu/gpu_channel_manager.cc
@@ -12,6 +12,7 @@
#include "content/common/gpu/gpu_messages.h"
#include "content/common/gpu/sync_point_manager.h"
#include "content/common/message_router.h"
+#include "gpu/command_buffer/common/value_state.h"
#include "gpu/command_buffer/service/feature_info.h"
#include "gpu/command_buffer/service/gpu_switches.h"
#include "gpu/command_buffer/service/mailbox_manager_impl.h"
@@ -162,6 +163,7 @@ bool GpuChannelManager::OnMessageReceived(const IPC::Message& msg) {
OnCreateViewCommandBuffer)
IPC_MESSAGE_HANDLER(GpuMsg_DestroyGpuMemoryBuffer, OnDestroyGpuMemoryBuffer)
IPC_MESSAGE_HANDLER(GpuMsg_LoadedShader, OnLoadedShader)
+ IPC_MESSAGE_HANDLER(GpuMsg_UpdateValueState, OnUpdateValueState)
IPC_MESSAGE_UNHANDLED(handled = false)
IPC_END_MESSAGE_MAP()
return handled;
@@ -276,6 +278,16 @@ void GpuChannelManager::OnDestroyGpuMemoryBuffer(
}
}
+void GpuChannelManager::OnUpdateValueState(
+ int client_id, unsigned int target, const gpu::ValueState& state) {
+ // Only pass updated state to the channel corresponding to the
+ // render_widget_host where the event originated
+ GpuChannelMap::const_iterator iter = gpu_channels_.find(client_id);
Ken Russell (switch to Gerrit) 2014/11/17 23:19:32 Again it would be nicer if this didn't involve a s
orglofch 2014/11/20 02:16:21 Agreed, however, there doesn't appear to be anothe
brianderson 2014/11/20 21:11:26 Seems okay to me. At least gpu_channels_ is a hash
+ if (iter != gpu_channels_.end()) {
+ iter->second->HandleUpdateValueState(target, state);
+ }
+}
+
void GpuChannelManager::OnLoadedShader(std::string program_proto) {
if (program_cache())
program_cache()->LoadProgram(program_proto);

Powered by Google App Engine
This is Rietveld 408576698