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

Issue 171103: A quick fix for Issue 19421.... (Closed)

Created:
11 years, 4 months ago by Hironori Bono
Modified:
9 years, 7 months ago
CC:
chromium-reviews_googlegroups.com, Ben Goodger (Google)
Visibility:
Public.

Description

A quick fix for Issue 19421. This issue is caused by AutocompleteEditViewMac::SetText() that updates the value of an AutocompleteEditField instance while an input method is composing text. Same as Windows, NSTextView finishes an ongoing composition when we update the value of an AutocompleteEditField object. To fix this issue, we check whether or not NSTextView has marked text and exit if it has. BUG=19421 "Korean IME does not work in the omnibox" TEST=Select Korean 2-set keyboard, type 'g', 'k', 's', 'r', 'm', 'f' keys, and verify we can see two Korean syllables. +rohitrao for reviewers since shess is out for the week Committed: http://src.chromium.org/viewvc/chrome?view=rev&revision=23702

Patch Set 1 #

Total comments: 2
Unified diffs Side-by-side diffs Delta from patch set Stats (+12 lines, -0 lines) Patch
M chrome/browser/autocomplete/autocomplete_edit_view_mac.mm View 1 chunk +12 lines, -0 lines 2 comments Download

Messages

Total messages: 11 (0 generated)
Hironori Bono
11 years, 4 months ago (2009-08-18 09:40:48 UTC) #1
John Grabowski
Rohit: please review for Scott.
11 years, 4 months ago (2009-08-18 20:08:18 UTC) #2
rohitrao (ping after 24h)
LGTM http://codereview.chromium.org/171103/diff/1/2 File chrome/browser/autocomplete/autocomplete_edit_view_mac.mm (right): http://codereview.chromium.org/171103/diff/1/2#newcode365 Line 365: // Exit if an input method is ...
11 years, 4 months ago (2009-08-18 21:42:35 UTC) #3
Hironori Bono
Thank you for your review and comment. http://codereview.chromium.org/171103/diff/1/2 File chrome/browser/autocomplete/autocomplete_edit_view_mac.mm (right): http://codereview.chromium.org/171103/diff/1/2#newcode365 Line 365: // ...
11 years, 4 months ago (2009-08-19 05:23:38 UTC) #4
Scott Hess - ex-Googler
Overriding SetText() is pretty deep - would it be possible to just catch it in ...
11 years, 4 months ago (2009-08-23 14:10:53 UTC) #5
Hironori Bono
Hi Scott, Thank you for your comment and sorry for my slow response. If we ...
11 years, 4 months ago (2009-08-25 03:08:00 UTC) #6
Scott Hess - ex-Googler
My concern is that SetText() is being called for a reason - are you positive ...
11 years, 4 months ago (2009-08-25 05:31:23 UTC) #7
Hironori Bono
Hi Scott, Thank you for your comments. I'm very sorry if my last comment made ...
11 years, 4 months ago (2009-08-25 06:47:49 UTC) #8
Scott Hess - ex-Googler
Sorry about the delayed response. My concern about overriding SetText() or SetWindowTextAndCaretPos() is that I ...
11 years, 3 months ago (2009-09-03 21:38:10 UTC) #9
Hironori Bono
Thank you for your comments and suggestions. I have reverted this change to investigate the ...
11 years, 3 months ago (2009-09-04 11:27:27 UTC) #10
Scott Hess - ex-Googler
11 years, 3 months ago (2009-09-08 19:42:38 UTC) #11
Again, is there anything wrong with adding the following to the
beginning of -controlTextDidChange:?

- (void)controlTextDidChange:(NSNotification*)aNotification {
  // Don't autocomplete when the user is composing a character.
  NSText* editor = [[aNotification userInfo] objectForKey:@"NSFieldEditor"];
  if ([editor hasMarkedText]) {
    return;
  }
...

While this might not solve every possible situation where this problem
comes up, it does solve the case in question, so the user experience
is improved while other changes are being considered.

-scott



On Fri, Sep 4, 2009 at 4:27 AM, <hbono@chromium.org> wrote:
> Thank you for your comments and suggestions.
> I have reverted this change to investigate the better places to check if
> there is a marked text since it is not so easy to solve this issue
> without regressions on Mac as I did for Windows.
> I will send another review request when I find the better solutions.
>
> Regards,
>
> Hironori Bono
>
> http://codereview.chromium.org/171103
>

Powered by Google App Engine
This is Rietveld 408576698