Page MenuHomePhorge

Handle matrix uri
Needs ReviewPublic

Authored by nannanko on Sat, Sep 6, 10:24 AM.
Tags
None
Referenced Files
F7755627: D229.1758359829.diff
Fri, Sep 19, 2:17 AM
F7754125: D229.1758328379.diff
Thu, Sep 18, 5:32 PM
F7753809: D229.1758320860.diff
Thu, Sep 18, 3:27 PM
F7753788: D229.1758320653.diff
Thu, Sep 18, 3:24 PM
F7752972: D229.1758293700.diff
Thu, Sep 18, 7:55 AM
F7752801: D229.1758289317.diff
Thu, Sep 18, 6:41 AM
Subscribers
None

Details

Reviewers
tusooa
Group Reviewers
O1: the Kazv Project
Maniphest Tasks
T29: Parse matrix links
Summary

Handle matrix uri in kazv.(Includes Matrix URI scheme uri matrix.to navigation)

Require D226.

Type: add

Test Plan

Diff Detail

Repository
rK kazv
Branch
nannanko/handle-matrix-uri
Lint
No Lint Coverage
Unit
No Test Coverage
Build Status
Buildable 430
Build 843: GitLab CI for kazv
Build 842: arc lint + arc unit

Event Timeline

Please add a changelog type to the summary, using the following format:

Type: (add|remove|skip|security|fix)

Tests has not been written yet.

nannanko edited the summary of this revision. (Show Details)
nannanko removed a reviewer: servant.
tusooa requested changes to this revision.Mon, Sep 8, 7:50 PM
tusooa added inline comments.
src/matrix-room-list.hpp
48

I think it's better called contains

src/matrix-sdk.cpp
462–471

I think it's not the way to do it, because (as I mentioned earlier in another patch) directRoomMap contains the map from room id to user id. Since you want a map from user id to room ids, you should be using the m.direct account data directly.

src/matrix-sdk.hpp
104

Use a meaningful name, and write in capitalized camel case. e.g. DirectRoomMap.

105

Because of comments below, this might not be needed. LAGER_QT_READER is only needed if you need to access the property from qml.

This revision now requires changes to proceed.Mon, Sep 8, 7:50 PM

Use Client::accountData() instead of MatrixSdk::directRoomMap() in MatrixSdk::directRoomIds().

Improved code of openLink(), and fixed tests.

tusooa requested changes to this revision.Sat, Sep 13, 7:26 PM
tusooa added inline comments.
src/contents/ui/event-types/TextTemplate.qml
138–143

The return only gets you out of the inner lambda (roomId) => { ... }, not the outer function. You might want to use for (roomId of matrixSdk.directRoomIds(userId)) { ... } instead.

167–168

cannot handle alias

src/tests/quick-tests/tst_MatrixLink.qml
30

does not conform to actual situation

This revision now requires changes to proceed.Sat, Sep 13, 7:26 PM

Use for instead of forEach.

nannanko marked an inline comment as done.

Handle matrix link to a room alias.

Fix some incorrect variable name