New issue
Advanced search Search tips

Issue 676296 link

Starred by 1 user

Issue metadata

Status: Fixed
Owner:
Closed: Jan 2017
Components:
EstimatedDays: ----
NextAction: ----
OS: Mac
Pri: 3
Type: Bug



Sign in to add a comment

MacViews: Right clicking on an unfocused text view should select all its text.

Project Member Reported by karandeepb@chromium.org, Dec 21 2016

Issue description

Chrome Version: 57.0.2958.0
OS: Mac

What steps will reproduce the problem?
(1) Enable chrome://flags/#secondary-ui-md.
(2) Open bookmark bubble.
(3) Enter multiple words in the Name textfield and ensure cursor is at the end.
(4) Press Tab to focus on the Folder dropdown/combobox.
(5) Right click inside the Name textfield.

What is the expected result?
All the text inside the Name textfield should be selected. This is the Cocoa behavior.

What happens instead?
It isn't.

 
Summary: MacViews: Right clicking on an unfocused text view should select all its text. (was: MacViews: Right clicking on an unfocused textfield should select all the text in the textfield.)
Project Member

Comment 2 by bugdroid1@chromium.org, Jan 27 2017

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

commit 81dc16e8871f33d24d0e12b0020491ee6ca18399
Author: karandeepb <karandeepb@chromium.org>
Date: Fri Jan 27 04:12:45 2017

MacViews: Select all text on right clicking an unfocused text view.

When an unfocused Cocoa text view is right clicked, all its text is selected.
This CL implements this behavior on MacViews for views::Textfield and
views::Label. A new variable kSelectAllOnRightClickWhenUnfocused is introduced
to the PlatformStyle class to account for the platform specific differences.
SelectionController::OnMousePressed is also modified to take the initial focus
state of its client view as an argument. A test is also added to
textfield_unittest.cc.

BUG= 676296 

Review-Url: https://codereview.chromium.org/2650963002
Cr-Commit-Position: refs/heads/master@{#446588}

[modify] https://crrev.com/81dc16e8871f33d24d0e12b0020491ee6ca18399/ui/views/controls/label.cc
[modify] https://crrev.com/81dc16e8871f33d24d0e12b0020491ee6ca18399/ui/views/controls/textfield/textfield.cc
[modify] https://crrev.com/81dc16e8871f33d24d0e12b0020491ee6ca18399/ui/views/controls/textfield/textfield_unittest.cc
[modify] https://crrev.com/81dc16e8871f33d24d0e12b0020491ee6ca18399/ui/views/selection_controller.cc
[modify] https://crrev.com/81dc16e8871f33d24d0e12b0020491ee6ca18399/ui/views/selection_controller.h
[modify] https://crrev.com/81dc16e8871f33d24d0e12b0020491ee6ca18399/ui/views/style/platform_style.cc
[modify] https://crrev.com/81dc16e8871f33d24d0e12b0020491ee6ca18399/ui/views/style/platform_style.h
[modify] https://crrev.com/81dc16e8871f33d24d0e12b0020491ee6ca18399/ui/views/style/platform_style_mac.mm

Status: Fixed (was: Assigned)

Sign in to add a comment