Changeset 125701 in webkit


Ignore:
Timestamp:
Aug 15, 2012 1:40:04 PM (12 years ago)
Author:
mifenton@rim.com
Message:

[BlackBerry] Use the unconverted attribute instead of composing when deciding to how to handle key input.
https://bugs.webkit.org/show_bug.cgi?id=94132

Reviewed by Rob Buis.

PR 139838.

Switch direct key input handling to be based on the unconverted
attribute being present. Converted keys, even during composition
are now input directly.

Reviewed Internally by Nima Ghanavatian.

  • WebKitSupport/InputHandler.cpp:

(BlackBerry::WebKit::InputHandler::setText):

Location:
trunk/Source/WebKit/blackberry
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/Source/WebKit/blackberry/ChangeLog

    r125690 r125701  
     12012-08-15  Mike Fenton  <mifenton@rim.com>
     2
     3        [BlackBerry] Use the unconverted attribute instead of composing when deciding to how to handle key input.
     4        https://bugs.webkit.org/show_bug.cgi?id=94132
     5
     6        Reviewed by Rob Buis.
     7
     8        PR 139838.
     9
     10        Switch direct key input handling to be based on the unconverted
     11        attribute being present.  Converted keys, even during composition
     12        are now input directly.
     13
     14        Reviewed Internally by Nima Ghanavatian.
     15
     16        * WebKitSupport/InputHandler.cpp:
     17        (BlackBerry::WebKit::InputHandler::setText):
     18
    1192012-08-15  Joshua Netterfield  <jnetterfield@rim.com>
    220
  • trunk/Source/WebKit/blackberry/WebKitSupport/InputHandler.cpp

    r125676 r125701  
    20142014
    20152015    if (isTrailingSingleCharacter(changedSpan, textLength, composingTextLength)) {
    2016         // Handle the case where text is being composed.
    2017         if (firstSpanInString(spannableString, COMPOSED_TEXT_ATTRIB)) {
    2018             InputLog(LogLevelInfo, "InputHandler::setText Single trailing character detected.  Text is being composed.");
     2016        // If the text is unconverted, do not allow JS processing as it is not a "real"
     2017        // character in the field.
     2018        if (firstSpanInString(spannableString, UNCONVERTED_TEXT_ATTRIB)) {
     2019            InputLog(LogLevelInfo, "InputHandler::setText Single trailing character detected.  Text is unconverted.");
    20192020            return editor->command("InsertText").execute(textToInsert.right(1));
    20202021        }
    2021         InputLog(LogLevelInfo, "InputHandler::setText Single trailing character detected. Text is not being composed.");
     2022        InputLog(LogLevelInfo, "InputHandler::setText Single trailing character detected.");
    20222023        return handleKeyboardInput(Platform::KeyboardEvent(textToInsert[textLength - 1], Platform::KeyboardEvent::KeyChar, 0), false /* changeIsPartOfComposition */);
    20232024    }
Note: See TracChangeset for help on using the changeset viewer.