[SMS app] Mask regex special characters in search box
ClosedPublic

Authored by nicolasfella on Aug 5 2018, 10:48 PM.

Details

Summary

QSortFilterProxyModel filters based on a regex. When the user inserts regex special characters things go bad.

Diff Detail

Repository
R224 KDE Connect
Branch
nogregex
Lint
Lint OK
Unit
No Unit Test Coverage
Build Status
Buildable 1552
Build 1570: arc lint + arc unit
nicolasfella created this revision.Aug 5 2018, 10:48 PM
Restricted Application added a project: KDE Connect. · View Herald TranscriptAug 5 2018, 10:48 PM
Restricted Application added a subscriber: kdeconnect. · View Herald Transcript
nicolasfella requested review of this revision.Aug 5 2018, 10:48 PM
  • Add a comment
broulik added a subscriber: broulik.Aug 6 2018, 7:07 AM

How about using

view.model.filterCaseSensitivity = Qt.CaseInsensitive;
view.model.setFilterFixedString(filter.text); // is not a property for some reason
  • Use Kai's suggestion
apol accepted this revision.Aug 6 2018, 10:54 AM
apol added a subscriber: apol.
apol added inline comments.
smsapp/qml/ConversationList.qml
71 ↗(On Diff #39158)

This can probably be set declaratively.

This revision is now accepted and ready to land.Aug 6 2018, 10:54 AM
nicolasfella marked an inline comment as done.Aug 6 2018, 11:07 AM
This revision was automatically updated to reflect the committed changes.