Merge lp:~michael-sheldon/oxide/fix-1384357 into lp:~osomon/oxide/non-ime-initiated-text-edit

Proposed by Michael Sheldon on 2015-05-18
Status: Merged
Merged at revision: 1029
Proposed branch: lp:~michael-sheldon/oxide/fix-1384357
Merge into: lp:~osomon/oxide/non-ime-initiated-text-edit
Diff against target: 33 lines (+21/-0)
2 files modified
patches/series (+1/-0)
patches/update-selection-on-non-ime-text-change.patch (+20/-0)
To merge this branch: bzr merge lp:~michael-sheldon/oxide/fix-1384357
Reviewer Review Type Date Requested Status
Olivier Tilloy 2015-05-18 Pending
Review via email: mp+259382@code.launchpad.net

Commit message

Update the surrounding text reported to the keyboard when a text field is changed programmatically

Description of the change

Update the surrounding text reported to the keyboard when a text field is changed programmatically

To post a comment you must log in.
1077. By Michael Sheldon on 2015-05-18

Merge from non-ime-initiated-text-edit and resolve conflicts

Olivier Tilloy (osomon) wrote :

This works well and fixes the original issue tracked by bug #1384357.

However I’m seeing a similar issue (that was mentioned in https://bugs.launchpad.net/oxide/+bug/1384357/comments/5): after clearing the text field with the X, swiping the app away from the right edge to reveal the app previews restores the preedit text.

Michael Sheldon (michael-sheldon) wrote :

I think we can go ahead and land this as it is, it looks like the fix for the other issue will either be in maliit-framework or ubuntu-keyboard (I have a working patch for maliit-framework already, but I'd like to see if it can be done in a less invasive way via ubuntu-keyboard first)

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'patches/series'
2--- patches/series 2015-05-18 14:31:37 +0000
3+++ patches/series 2015-05-18 15:05:09 +0000
4@@ -31,3 +31,4 @@
5 pulse-audio-role.patch
6 enable-accelerated-canvas-on-arale.patch
7 notify-text-updates.patch
8+update-selection-on-non-ime-text-change.patch
9
10=== added file 'patches/update-selection-on-non-ime-text-change.patch'
11--- patches/update-selection-on-non-ime-text-change.patch 1970-01-01 00:00:00 +0000
12+++ patches/update-selection-on-non-ime-text-change.patch 2015-05-18 15:05:09 +0000
13@@ -0,0 +1,20 @@
14+# Description: Update the surrounding text reported to the input method
15+# framework when text has been changed programmatically
16+# Bug: https://launchpad.net/bugs/1384357
17+# Author: Michael Sheldon <michael.sheldon@canonical.com>
18+diff --git a/content/renderer/render_widget.cc b/content/renderer/render_widget.cc
19+--- a/content/renderer/render_widget.cc
20++++ b/content/renderer/render_widget.cc
21+@@ -1986,8 +1986,11 @@ void RenderWidget::UpdateTextInputState(
22+ #endif
23+ p.is_non_ime_change = (change_source == FROM_NON_IME) ||
24+ text_field_is_dirty_;
25+- if (p.is_non_ime_change)
26++ if (p.is_non_ime_change) {
27+ IncrementOutstandingImeEventAcks();
28++ FOR_EACH_OBSERVER(RenderFrameImpl, render_frames_,
29++ didChangeSelection(false));
30++ }
31+ text_field_is_dirty_ = false;
32+ #if defined(USE_AURA)
33+ Send(new ViewHostMsg_TextInputTypeChanged(routing_id(),

Subscribers

People subscribed via source and target branches