Merge lp://staging/~zsombi/ubuntu-ui-toolkit/textinput-text-selection into lp://staging/ubuntu-ui-toolkit

Proposed by Zsombor Egri
Status: Superseded
Proposed branch: lp://staging/~zsombi/ubuntu-ui-toolkit/textinput-text-selection
Merge into: lp://staging/ubuntu-ui-toolkit
Diff against target: 2647 lines (+1489/-457)
19 files modified
components.api (+2/-2)
modules/Ubuntu/Components/InputHandler.qml (+297/-0)
modules/Ubuntu/Components/TextArea.qml (+42/-130)
modules/Ubuntu/Components/TextCursor.qml (+1/-1)
modules/Ubuntu/Components/TextField.qml (+80/-133)
modules/Ubuntu/Components/Themes/Ambiance/TextAreaStyle.qml (+5/-5)
modules/Ubuntu/Components/plugin/ucmousefilters.cpp (+13/-3)
modules/Ubuntu/Components/qmldir (+1/-0)
modules/Ubuntu/Test/UbuntuTestCase.qml (+69/-1)
modules/Ubuntu/Test/deployment.pri (+6/-1)
tests/resources/inputs/TextInputs.qml (+85/-0)
tests/unit/runtest.sh (+1/-1)
tests/unit_x11/tst_components/tst_textarea.qml (+286/-60)
tests/unit_x11/tst_components/tst_textarea_in_flickable.qml (+58/-37)
tests/unit_x11/tst_components/tst_textfield.qml (+282/-63)
tests/unit_x11/tst_mousefilters/HoverEvent.qml (+38/-0)
tests/unit_x11/tst_mousefilters/tst_mousefilters.pro (+2/-1)
tests/unit_x11/tst_mousefilters/tst_mousefilterstest.cpp (+118/-4)
tests/unit_x11/tst_test/tst_ubuntutestcase.qml (+103/-15)
To merge this branch: bzr merge lp://staging/~zsombi/ubuntu-ui-toolkit/textinput-text-selection
Reviewer Review Type Date Requested Status
PS Jenkins bot continuous-integration Needs Fixing
Cris Dywan Needs Fixing
Review via email: mp+213983@code.staging.launchpad.net

This proposal has been superseded by a proposal from 2014-04-09.

Commit message

TextField and TextArea selection fixes. Also fixes scrolling for both.

To post a comment you must log in.
Revision history for this message
PS Jenkins bot (ps-jenkins) wrote :
review: Needs Fixing (continuous-integration)
Revision history for this message
PS Jenkins bot (ps-jenkins) wrote :
review: Needs Fixing (continuous-integration)
Revision history for this message
PS Jenkins bot (ps-jenkins) wrote :
review: Needs Fixing (continuous-integration)
Revision history for this message
PS Jenkins bot (ps-jenkins) wrote :
review: Needs Fixing (continuous-integration)
999. By Zsombor Egri

prereq merge

1000. By Zsombor Egri

event buffer flush

1001. By Zsombor Egri

prereq merge

Revision history for this message
PS Jenkins bot (ps-jenkins) wrote :
review: Needs Fixing (continuous-integration)
Revision history for this message
PS Jenkins bot (ps-jenkins) wrote :
review: Needs Fixing (continuous-integration)
1002. By Zsombor Egri

test case fix

1003. By Zsombor Egri

prereq merge

1004. By Zsombor Egri

test cases cleanup

1005. By Zsombor Egri

default checking test cases fixed

Revision history for this message
PS Jenkins bot (ps-jenkins) wrote :
review: Needs Fixing (continuous-integration)
Revision history for this message
Cris Dywan (kalikiana) wrote :

I see the same test failure here as J locally.
> tests/unit_x11/tst_components/tst_textarea_in_flickable.qml(72)
> tryCompare(moveSpy, "count", 1, 200);
Why not moveSpy.wait(); here? That seems to fix it for me.

When using select and context menu a few times it's possible to change the selection after the menu opens but before letting go of the mouse button. So I don't get what I selected or worst case nothing.

What I manually checked is that I can select, including scrolling, get a menu, copy, paste and so on, double click to select a word, all of these seem sold aside from the above issue.

FTR toggleFlickablesInteractive looks rather hackish… I guess Repeater doesn't support it, and PropertyChanges doesn't take a list either… but let's have it as-is for now.

Should maybe selectionTimeout.interval be added to modules/Ubuntu/Components/Themes/Ambiance/TextCursorStyle.qml:31

test_press_and_hold_over_selected_text etc. doesn't test the context menu. Especially given the above problem I found while using it, I think we need to test that it can be clicked and catches the right text. Possibly AP.

review: Needs Fixing
Revision history for this message
Zsombor Egri (zsombi) wrote :

> I see the same test failure here as J locally.
> > tests/unit_x11/tst_components/tst_textarea_in_flickable.qml(72)
> > tryCompare(moveSpy, "count", 1, 200);
> Why not moveSpy.wait(); here? That seems to fix it for me.

Ahh, right :) I'll fix it.

>
> When using select and context menu a few times it's possible to change the
> selection after the menu opens but before letting go of the mouse button. So I
> don't get what I selected or worst case nothing.

Let's do this in a separate branch..

>
> What I manually checked is that I can select, including scrolling, get a menu,
> copy, paste and so on, double click to select a word, all of these seem sold
> aside from the above issue.
>
> FTR toggleFlickablesInteractive looks rather hackish… I guess Repeater doesn't
> support it, and PropertyChanges doesn't take a list either… but let's have it
> as-is for now.

Well, limitation of PropertyChange, maybe we propose some Change component upstream to deal with a list of targets :).

>
> Should maybe selectionTimeout.interval be added to
> modules/Ubuntu/Components/Themes/Ambiance/TextCursorStyle.qml:31

I will put this in the TextFieldStyle/TextAreaStyle components rather than the cursor style.

>
> test_press_and_hold_over_selected_text etc. doesn't test the context menu.
> Especially given the above problem I found while using it, I think we need to
> test that it can be clicked and catches the right text. Possibly AP.

Yep, but let's get this in a separate branch as well.

Revision history for this message
Cris Dywan (kalikiana) wrote :

Filed bug 1304952 for testing the context menu.

1006. By Zsombor Egri

use spy's wait() function wherever is possible

1007. By Zsombor Egri

selection mode timeout configurable from theme

1008. By Zsombor Egri

text selection does not continue while context menu is open

1009. By Zsombor Egri

rogue typo removed

1010. By Zsombor Egri

prereq merge

Revision history for this message
PS Jenkins bot (ps-jenkins) wrote :
review: Needs Fixing (continuous-integration)
1011. By Zsombor Egri

unify the event buffer emptying timeout in TextArea test case with TextField

1012. By Zsombor Egri

prereq merge

1013. By Zsombor Egri

staging merged

1014. By Zsombor Egri

autopilot related fixes

1015. By Zsombor Egri

input handler should be inactive while context menu is open

1016. By Zsombor Egri

intermediate steps

1017. By Zsombor Egri

prerequisite merge

1018. By Zsombor Egri

TextArea test fixes

1019. By Zsombor Egri

prerequisite merge

1020. By Zsombor Egri

prereq merge

1021. By Zsombor Egri

cleanup

1022. By Zsombor Egri

more cleanup

1023. By Zsombor Egri

staging merge

1024. By Zsombor Egri

staging merge

1025. By Zsombor Egri

replace flick() with mouseDrag()

1026. By Zsombor Egri

change flick() with mouseDrag()

1027. By Zsombor Egri

versioning merge

1028. By Zsombor Egri

tests reworked for tst_textarea_in_flickable.qml

1029. By Zsombor Egri

staging merge

1030. By Zsombor Egri

staging merge

Unmerged revisions

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
The diff is not available at this time. You can reload the page or download it.

Subscribers

People subscribed via source and target branches

to status/vote changes: