New issue
Advanced search Search tips
Note: Color blocks (like or ) mean that a user may not be available. Tooltip shows the reason.

Issue 901490 link

Starred by 2 users

Issue metadata

Status: Fixed
Owner:
Closed: Jan 4
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: Mac
Pri: 1
Type: Bug

Blocking:
issue 859152



Sign in to add a comment

RemoteMacViews: Text fields in views don't work

Project Member Reported by ccameron@chromium.org, Nov 2

Issue description

Text fields in RemoteMacViews are not implemented yet.

The only example of a text field in the PWA UI is the find in page UI (3-dot -> find).

This is because BridgedConentView's textInputClient has not been mojo-ified yet.
 
Labels: proj-MacPwa
Components: UI>Browser>WebAppInstalls
Labels: -proj-MacPwa
Labels: -Pri-3 M-73 Pri-1
Of note is that the only text field in PWAs that I know of is the "Find in page" dialog.

This should be easy to "mostly" fix, but it might leave rough edges in more IME-heavy languages.
Labels: Pri-2
Bulk downgrading some bugs to P2.
Owner: sdy@chromium.org
Labels: -Pri-2 Pri-1
P1 but the quick fix could be just to disable find-in-page.
Project Member

Comment 9 by bugdroid1@chromium.org, Dec 31

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/6fb35256c2faeab990e02053097866ab0aea5aac

commit 6fb35256c2faeab990e02053097866ab0aea5aac
Author: Christopher Cameron <ccameron@chromium.org>
Date: Mon Dec 31 22:48:39 2018

RemoteMacViews: Store ui::TextInputClient in views::TextInputHost

There is currently a ui::TextInputClient* stored in BridgedContentView.
This is problematic because the ui::TextInputClient lives in the
browser process while the BridgedContentView lives in the app process.

Cut-and-paste-move textInputClient_ and pendingTextInputClient_  from
BridgedContentView to TextInputHost, and make it a member of the
BridgedNativeWidgetHostImpl class, using the views_bridge_mac::
BridgedNativeWidgetHostHelper structure to close the gap between the
two.

This leaves many direct accesses of the ui::TextInputClient from the
app process, which we can now replace one-by-one with mojo calls in
subsequent patches.

Bug:  901490 
Change-Id: Ib4497afd4dd7a4e41541eaab170157e1c7eeb90e
Reviewed-on: https://chromium-review.googlesource.com/c/1391879
Commit-Queue: ccameron <ccameron@chromium.org>
Reviewed-by: Sidney San Martín <sdy@chromium.org>
Cr-Commit-Position: refs/heads/master@{#619321}
[modify] https://crrev.com/6fb35256c2faeab990e02053097866ab0aea5aac/ui/views/BUILD.gn
[modify] https://crrev.com/6fb35256c2faeab990e02053097866ab0aea5aac/ui/views/cocoa/bridged_native_widget_host_impl.h
[modify] https://crrev.com/6fb35256c2faeab990e02053097866ab0aea5aac/ui/views/cocoa/bridged_native_widget_host_impl.mm
[modify] https://crrev.com/6fb35256c2faeab990e02053097866ab0aea5aac/ui/views/cocoa/bridged_native_widget_unittest.mm
[add] https://crrev.com/6fb35256c2faeab990e02053097866ab0aea5aac/ui/views/cocoa/text_input_host.h
[add] https://crrev.com/6fb35256c2faeab990e02053097866ab0aea5aac/ui/views/cocoa/text_input_host.mm
[modify] https://crrev.com/6fb35256c2faeab990e02053097866ab0aea5aac/ui/views_bridge_mac/bridge_factory_impl.mm
[modify] https://crrev.com/6fb35256c2faeab990e02053097866ab0aea5aac/ui/views_bridge_mac/bridged_content_view.h
[modify] https://crrev.com/6fb35256c2faeab990e02053097866ab0aea5aac/ui/views_bridge_mac/bridged_content_view.mm
[modify] https://crrev.com/6fb35256c2faeab990e02053097866ab0aea5aac/ui/views_bridge_mac/bridged_native_widget_host_helper.h
[modify] https://crrev.com/6fb35256c2faeab990e02053097866ab0aea5aac/ui/views_bridge_mac/bridged_native_widget_impl.h
[modify] https://crrev.com/6fb35256c2faeab990e02053097866ab0aea5aac/ui/views_bridge_mac/bridged_native_widget_impl.mm

Owner: ccameron@chromium.org
Working now (with IME, cut-paste, etc).
keyboard.mov
2.2 MB View Download
Project Member

Comment 11 by bugdroid1@chromium.org, Jan 4

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/feb0040e46151c39faafe5945ed7772398af86b2

commit feb0040e46151c39faafe5945ed7772398af86b2
Author: Christopher Cameron <ccameron@chromium.org>
Date: Fri Jan 04 20:13:18 2019

RemoteMacViews: Make text fields work (mostly)

Route (almost) all access to the focused views::View's
ui::TextInputClient in BridgedContentView to go through a
views_bridge_mac::mojom::TextInputHost interface.

Initialize this interface in the same way that BridgedNativeWidgetHost
is initialized (by pointer for in-process windows and via the factory
for out-of-process windows).

Cut-and-paste helper methods to the new file.

Leave unfixed (for now) the IsTextEditCommandEnabled and
SetTextEditCommandForNextKeyEvent methods, because they require
mojo-ifying enums (better for a separate patch).

Bug:  901490 
Change-Id: Ic40a42ec38ad9ed71a4c14cc8aa55485d72d0b59
Reviewed-on: https://chromium-review.googlesource.com/c/1394429
Reviewed-by: Robert Sesek <rsesek@chromium.org>
Reviewed-by: Sidney San Martín <sdy@chromium.org>
Commit-Queue: ccameron <ccameron@chromium.org>
Cr-Commit-Position: refs/heads/master@{#620043}
[modify] https://crrev.com/feb0040e46151c39faafe5945ed7772398af86b2/ui/views/cocoa/bridged_native_widget_host_impl.h
[modify] https://crrev.com/feb0040e46151c39faafe5945ed7772398af86b2/ui/views/cocoa/bridged_native_widget_host_impl.mm
[modify] https://crrev.com/feb0040e46151c39faafe5945ed7772398af86b2/ui/views/cocoa/text_input_host.h
[modify] https://crrev.com/feb0040e46151c39faafe5945ed7772398af86b2/ui/views/cocoa/text_input_host.mm
[modify] https://crrev.com/feb0040e46151c39faafe5945ed7772398af86b2/ui/views_bridge_mac/BUILD.gn
[modify] https://crrev.com/feb0040e46151c39faafe5945ed7772398af86b2/ui/views_bridge_mac/bridge_factory_impl.h
[modify] https://crrev.com/feb0040e46151c39faafe5945ed7772398af86b2/ui/views_bridge_mac/bridge_factory_impl.mm
[modify] https://crrev.com/feb0040e46151c39faafe5945ed7772398af86b2/ui/views_bridge_mac/bridged_content_view.mm
[modify] https://crrev.com/feb0040e46151c39faafe5945ed7772398af86b2/ui/views_bridge_mac/bridged_native_widget_host_helper.h
[modify] https://crrev.com/feb0040e46151c39faafe5945ed7772398af86b2/ui/views_bridge_mac/bridged_native_widget_impl.h
[modify] https://crrev.com/feb0040e46151c39faafe5945ed7772398af86b2/ui/views_bridge_mac/bridged_native_widget_impl.mm
[modify] https://crrev.com/feb0040e46151c39faafe5945ed7772398af86b2/ui/views_bridge_mac/mojo/bridge_factory.mojom
[add] https://crrev.com/feb0040e46151c39faafe5945ed7772398af86b2/ui/views_bridge_mac/mojo/text_input_host.mojom

This is working enough now to not be a P1 anymore (IME, etc, etc, work).
Status: Fixed (was: Assigned)
Split off issue 919186 as a P2, closing this block-ship issue.
Cc: santhoshkumar@chromium.org
Labels: TE-Verified-M73 TE-Verified-73.0.3664.0
Able to verify the fix on latest chrome #73.0.3664.0 using Mac OS 10.13 by following steps as per comment#0.
Attached screenshots for reference.
Observed that able to see the text inputs in find in page dialog.
Hence, the fix is working as expected.
Adding the verified labels.

Thanks...!!
901490.mp4
899 KB View Download

Sign in to add a comment