From ca49ad736a06aa796610f068f6419c39b8535251 Mon Sep 17 00:00:00 2001 From: callum_linden Date: Fri, 10 Jul 2015 01:01:07 +0100 Subject: Initial support for keyboard (in progress) but includes many viewer changes to plumb in Key Up events --- indra/newview/llviewermediafocus.cpp | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'indra/newview/llviewermediafocus.cpp') diff --git a/indra/newview/llviewermediafocus.cpp b/indra/newview/llviewermediafocus.cpp index aa019dfdd8..1265ca0a70 100755 --- a/indra/newview/llviewermediafocus.cpp +++ b/indra/newview/llviewermediafocus.cpp @@ -352,6 +352,13 @@ BOOL LLViewerMediaFocus::handleKey(KEY key, MASK mask, BOOL called_from_parent) return true; } +BOOL LLViewerMediaFocus::handleKeyUp(KEY key, MASK mask, BOOL called_from_parent) +{ + return true; +} + + + BOOL LLViewerMediaFocus::handleUnicodeChar(llwchar uni_char, BOOL called_from_parent) { LLViewerMediaImpl* media_impl = getFocusedMediaImpl(); -- cgit v1.2.3 From 9833a50260fb45d5f0033200ae756834c0cc9940 Mon Sep 17 00:00:00 2001 From: Rider Linden Date: Tue, 27 Oct 2015 15:17:12 -0700 Subject: MAINT-5754: For MoaP and MediaCtrls forward all events including KEYUP and KEYDOWN to the CEF plugin. --- indra/newview/llviewermediafocus.cpp | 17 ++++++++++++++++- 1 file changed, 16 insertions(+), 1 deletion(-) (limited to 'indra/newview/llviewermediafocus.cpp') diff --git a/indra/newview/llviewermediafocus.cpp b/indra/newview/llviewermediafocus.cpp index 1265ca0a70..7b4df3d3da 100755 --- a/indra/newview/llviewermediafocus.cpp +++ b/indra/newview/llviewermediafocus.cpp @@ -354,7 +354,12 @@ BOOL LLViewerMediaFocus::handleKey(KEY key, MASK mask, BOOL called_from_parent) BOOL LLViewerMediaFocus::handleKeyUp(KEY key, MASK mask, BOOL called_from_parent) { - return true; + LLViewerMediaImpl* media_impl = getFocusedMediaImpl(); + if (media_impl) + { + media_impl->handleKeyUpHere(key, mask); + } + return true; } @@ -610,3 +615,13 @@ LLUUID LLViewerMediaFocus::getControlsMediaID() return LLUUID::null; } + +bool LLViewerMediaFocus::wantsKeyUpKeyDown() const +{ + return true; +} + +bool LLViewerMediaFocus::wantsReturnKey() const +{ + return true; +} -- cgit v1.2.3