Tag rooms via context menu

This commit is contained in:
Nicolas Werner 2020-05-18 03:30:04 +02:00
parent fca85bea39
commit 7de1fc62e8
18 changed files with 747 additions and 117 deletions

View file

@ -332,7 +332,7 @@ if(USE_BUNDLED_MTXCLIENT)
FetchContent_Declare(
MatrixClient
GIT_REPOSITORY https://github.com/Nheko-Reborn/mtxclient.git
GIT_TAG 1018c0822b80cdfc5d6b589fe94d1fd759113ef6
GIT_TAG f5c78f4331b62a1e25a2d839cb38b07bb9bd7829
)
FetchContent_MakeAvailable(MatrixClient)
else()

View file

@ -146,9 +146,9 @@
"name": "mtxclient",
"sources": [
{
"sha256": "537f4e6b280f351ad950cd6598c2407505a55f0d6c856b4ff97a9c59fc6fdb7a",
"sha256": "16203a92b03c488178b31bedca9d9015b1d406443f7e5363a2e09171e50f8dfc",
"type": "archive",
"url": "https://github.com/Nheko-Reborn/mtxclient/archive/1018c0822b80cdfc5d6b589fe94d1fd759113ef6.tar.gz"
"url": "https://github.com/Nheko-Reborn/mtxclient/archive/f5c78f4331b62a1e25a2d839cb38b07bb9bd7829.tar.gz"
}
]
},

View file

@ -445,12 +445,58 @@ Beispiel: https://mein.server:8787</translation>
<context>
<name>RoomInfoListItem</name>
<message>
<location filename="../../src/RoomInfoListItem.cpp" line="+98"/>
<location filename="../../src/RoomInfoListItem.cpp" line="+102"/>
<source>Leave room</source>
<translation>Raum verlassen</translation>
</message>
<message>
<location line="+160"/>
<location line="+7"/>
<source>Tag room as:</source>
<translation type="unfinished"></translation>
</message>
<message>
<location line="+7"/>
<source>Favourite</source>
<comment>Standard matrix tag for favourites</comment>
<translation type="unfinished"></translation>
</message>
<message>
<location line="+3"/>
<source>Low Priority</source>
<comment>Standard matrix tag for low priority rooms</comment>
<translation type="unfinished"></translation>
</message>
<message>
<location line="+3"/>
<source>Server Notice</source>
<comment>Standard matrix tag for server notices</comment>
<translation type="unfinished"></translation>
</message>
<message>
<location line="+13"/>
<source>Adds or removes the specified tag.</source>
<comment>WhatsThis hint for tag menu actions</comment>
<translation type="unfinished"></translation>
</message>
<message>
<location line="+38"/>
<source>New tag...</source>
<comment>Add a new tag to the room</comment>
<translation type="unfinished"></translation>
</message>
<message>
<location line="+3"/>
<source>New Tag</source>
<comment>Tag name prompt title</comment>
<translation type="unfinished"></translation>
</message>
<message>
<location line="+0"/>
<source>Tag:</source>
<translation type="unfinished"></translation>
</message>
<message>
<location line="+173"/>
<source>Accept</source>
<translation>Akzeptieren</translation>
</message>
@ -751,7 +797,7 @@ Beispiel: https://mein.server:8787</translation>
<context>
<name>TimelineRow</name>
<message>
<location filename="../qml/TimelineRow.qml" line="+88"/>
<location filename="../qml/TimelineRow.qml" line="+92"/>
<source>Reply</source>
<translation>Antworten</translation>
</message>
@ -764,7 +810,7 @@ Beispiel: https://mein.server:8787</translation>
<context>
<name>TimelineView</name>
<message>
<location filename="../qml/TimelineView.qml" line="+53"/>
<location filename="../qml/TimelineView.qml" line="+54"/>
<source>Reply</source>
<translation>Antworten</translation>
</message>
@ -804,7 +850,7 @@ Beispiel: https://mein.server:8787</translation>
<translation>Kein Raum geöffnet</translation>
</message>
<message>
<location line="+256"/>
<location line="+257"/>
<source>Close</source>
<translation>Schließen</translation>
</message>
@ -866,7 +912,7 @@ Beispiel: https://mein.server:8787</translation>
<context>
<name>UserSettingsPage</name>
<message>
<location filename="../../src/UserSettingsPage.cpp" line="+335"/>
<location filename="../../src/UserSettingsPage.cpp" line="+339"/>
<source>Minimize to tray</source>
<translation>Ins Benachrichtigungsfeld minimieren</translation>
</message>
@ -920,6 +966,11 @@ Beispiel: https://mein.server:8787</translation>
<source>Desktop notifications</source>
<translation>Desktopbenachrichtigungen</translation>
</message>
<message>
<location line="+1"/>
<source>Highlight message on hover</source>
<translation type="unfinished"></translation>
</message>
<message>
<location line="+5"/>
<source>Scale factor</source>
@ -951,7 +1002,7 @@ Beispiel: https://mein.server:8787</translation>
<translation>Gerätefingerabdruck</translation>
</message>
<message>
<location line="-59"/>
<location line="-60"/>
<source>Session Keys</source>
<translation>Sitzungsschlüssel</translation>
</message>
@ -971,22 +1022,22 @@ Beispiel: https://mein.server:8787</translation>
<translation>VERSCHLÜSSELUNG</translation>
</message>
<message>
<location line="-63"/>
<location line="-64"/>
<source>GENERAL</source>
<translation>ALLGEMEINES</translation>
</message>
<message>
<location line="+25"/>
<location line="+26"/>
<source>INTERFACE</source>
<translation>OBERFLÄCHE</translation>
</message>
<message>
<location line="+108"/>
<location line="+109"/>
<source>Emoji Font Family</source>
<translation>Emojischriftart</translation>
</message>
<message>
<location line="+158"/>
<location line="+163"/>
<source>Open Sessions File</source>
<translation>Öffne Sessions Datei</translation>
</message>

View file

@ -441,12 +441,58 @@ Example: https://server.my:8787</source>
<context>
<name>RoomInfoListItem</name>
<message>
<location filename="../../src/RoomInfoListItem.cpp" line="+98"/>
<location filename="../../src/RoomInfoListItem.cpp" line="+102"/>
<source>Leave room</source>
<translation>Βγές</translation>
</message>
<message>
<location line="+160"/>
<location line="+7"/>
<source>Tag room as:</source>
<translation type="unfinished"></translation>
</message>
<message>
<location line="+7"/>
<source>Favourite</source>
<comment>Standard matrix tag for favourites</comment>
<translation type="unfinished"></translation>
</message>
<message>
<location line="+3"/>
<source>Low Priority</source>
<comment>Standard matrix tag for low priority rooms</comment>
<translation type="unfinished"></translation>
</message>
<message>
<location line="+3"/>
<source>Server Notice</source>
<comment>Standard matrix tag for server notices</comment>
<translation type="unfinished"></translation>
</message>
<message>
<location line="+13"/>
<source>Adds or removes the specified tag.</source>
<comment>WhatsThis hint for tag menu actions</comment>
<translation type="unfinished"></translation>
</message>
<message>
<location line="+38"/>
<source>New tag...</source>
<comment>Add a new tag to the room</comment>
<translation type="unfinished"></translation>
</message>
<message>
<location line="+3"/>
<source>New Tag</source>
<comment>Tag name prompt title</comment>
<translation type="unfinished"></translation>
</message>
<message>
<location line="+0"/>
<source>Tag:</source>
<translation type="unfinished"></translation>
</message>
<message>
<location line="+173"/>
<source>Accept</source>
<translation>Αποδοχή</translation>
</message>
@ -747,7 +793,7 @@ Example: https://server.my:8787</source>
<context>
<name>TimelineRow</name>
<message>
<location filename="../qml/TimelineRow.qml" line="+88"/>
<location filename="../qml/TimelineRow.qml" line="+92"/>
<source>Reply</source>
<translation type="unfinished"></translation>
</message>
@ -760,7 +806,7 @@ Example: https://server.my:8787</source>
<context>
<name>TimelineView</name>
<message>
<location filename="../qml/TimelineView.qml" line="+53"/>
<location filename="../qml/TimelineView.qml" line="+54"/>
<source>Reply</source>
<translation type="unfinished"></translation>
</message>
@ -800,7 +846,7 @@ Example: https://server.my:8787</source>
<translation type="unfinished"></translation>
</message>
<message>
<location line="+256"/>
<location line="+257"/>
<source>Close</source>
<translation type="unfinished"></translation>
</message>
@ -862,7 +908,7 @@ Example: https://server.my:8787</source>
<context>
<name>UserSettingsPage</name>
<message>
<location filename="../../src/UserSettingsPage.cpp" line="+335"/>
<location filename="../../src/UserSettingsPage.cpp" line="+339"/>
<source>Minimize to tray</source>
<translation>Ελαχιστοποίηση</translation>
</message>
@ -916,6 +962,11 @@ Example: https://server.my:8787</source>
<source>Desktop notifications</source>
<translation type="unfinished"></translation>
</message>
<message>
<location line="+1"/>
<source>Highlight message on hover</source>
<translation type="unfinished"></translation>
</message>
<message>
<location line="+5"/>
<source>Scale factor</source>
@ -947,7 +998,7 @@ Example: https://server.my:8787</source>
<translation type="unfinished"></translation>
</message>
<message>
<location line="-59"/>
<location line="-60"/>
<source>Session Keys</source>
<translation type="unfinished"></translation>
</message>
@ -967,22 +1018,22 @@ Example: https://server.my:8787</source>
<translation type="unfinished"></translation>
</message>
<message>
<location line="-63"/>
<location line="-64"/>
<source>GENERAL</source>
<translation>ΓΕΝΙΚΑ</translation>
</message>
<message>
<location line="+25"/>
<location line="+26"/>
<source>INTERFACE</source>
<translation type="unfinished"></translation>
</message>
<message>
<location line="+108"/>
<location line="+109"/>
<source>Emoji Font Family</source>
<translation type="unfinished"></translation>
</message>
<message>
<location line="+158"/>
<location line="+163"/>
<source>Open Sessions File</source>
<translation type="unfinished"></translation>
</message>

View file

@ -445,12 +445,58 @@ Example: https://server.my:8787</translation>
<context>
<name>RoomInfoListItem</name>
<message>
<location filename="../../src/RoomInfoListItem.cpp" line="+98"/>
<location filename="../../src/RoomInfoListItem.cpp" line="+102"/>
<source>Leave room</source>
<translation>Leave room</translation>
</message>
<message>
<location line="+160"/>
<location line="+7"/>
<source>Tag room as:</source>
<translation type="unfinished"></translation>
</message>
<message>
<location line="+7"/>
<source>Favourite</source>
<comment>Standard matrix tag for favourites</comment>
<translation type="unfinished"></translation>
</message>
<message>
<location line="+3"/>
<source>Low Priority</source>
<comment>Standard matrix tag for low priority rooms</comment>
<translation type="unfinished"></translation>
</message>
<message>
<location line="+3"/>
<source>Server Notice</source>
<comment>Standard matrix tag for server notices</comment>
<translation type="unfinished"></translation>
</message>
<message>
<location line="+13"/>
<source>Adds or removes the specified tag.</source>
<comment>WhatsThis hint for tag menu actions</comment>
<translation type="unfinished"></translation>
</message>
<message>
<location line="+38"/>
<source>New tag...</source>
<comment>Add a new tag to the room</comment>
<translation type="unfinished"></translation>
</message>
<message>
<location line="+3"/>
<source>New Tag</source>
<comment>Tag name prompt title</comment>
<translation type="unfinished"></translation>
</message>
<message>
<location line="+0"/>
<source>Tag:</source>
<translation type="unfinished"></translation>
</message>
<message>
<location line="+173"/>
<source>Accept</source>
<translation>Accept</translation>
</message>
@ -751,7 +797,7 @@ Example: https://server.my:8787</translation>
<context>
<name>TimelineRow</name>
<message>
<location filename="../qml/TimelineRow.qml" line="+88"/>
<location filename="../qml/TimelineRow.qml" line="+92"/>
<source>Reply</source>
<translation>Reply</translation>
</message>
@ -764,7 +810,7 @@ Example: https://server.my:8787</translation>
<context>
<name>TimelineView</name>
<message>
<location filename="../qml/TimelineView.qml" line="+53"/>
<location filename="../qml/TimelineView.qml" line="+54"/>
<source>Reply</source>
<translation>Reply</translation>
</message>
@ -804,7 +850,7 @@ Example: https://server.my:8787</translation>
<translation>No room open</translation>
</message>
<message>
<location line="+256"/>
<location line="+257"/>
<source>Close</source>
<translation>Close</translation>
</message>
@ -866,7 +912,7 @@ Example: https://server.my:8787</translation>
<context>
<name>UserSettingsPage</name>
<message>
<location filename="../../src/UserSettingsPage.cpp" line="+335"/>
<location filename="../../src/UserSettingsPage.cpp" line="+339"/>
<source>Minimize to tray</source>
<translation>Minimize to tray</translation>
</message>
@ -920,6 +966,11 @@ Example: https://server.my:8787</translation>
<source>Desktop notifications</source>
<translation>Desktop notifications</translation>
</message>
<message>
<location line="+1"/>
<source>Highlight message on hover</source>
<translation type="unfinished"></translation>
</message>
<message>
<location line="+5"/>
<source>Scale factor</source>
@ -951,7 +1002,7 @@ Example: https://server.my:8787</translation>
<translation>Device Fingerprint</translation>
</message>
<message>
<location line="-59"/>
<location line="-60"/>
<source>Session Keys</source>
<translation>Session Keys</translation>
</message>
@ -971,22 +1022,22 @@ Example: https://server.my:8787</translation>
<translation>ENCRYPTION</translation>
</message>
<message>
<location line="-63"/>
<location line="-64"/>
<source>GENERAL</source>
<translation>GENERAL</translation>
</message>
<message>
<location line="+25"/>
<location line="+26"/>
<source>INTERFACE</source>
<translation>INTERFACE</translation>
</message>
<message>
<location line="+108"/>
<location line="+109"/>
<source>Emoji Font Family</source>
<translation>Emoji Font Family</translation>
</message>
<message>
<location line="+158"/>
<location line="+163"/>
<source>Open Sessions File</source>
<translation>Open Sessions File</translation>
</message>

View file

@ -441,12 +441,58 @@ Example: https://server.my:8787</source>
<context>
<name>RoomInfoListItem</name>
<message>
<location filename="../../src/RoomInfoListItem.cpp" line="+98"/>
<location filename="../../src/RoomInfoListItem.cpp" line="+102"/>
<source>Leave room</source>
<translation>Poistu huoneesta</translation>
</message>
<message>
<location line="+160"/>
<location line="+7"/>
<source>Tag room as:</source>
<translation type="unfinished"></translation>
</message>
<message>
<location line="+7"/>
<source>Favourite</source>
<comment>Standard matrix tag for favourites</comment>
<translation type="unfinished"></translation>
</message>
<message>
<location line="+3"/>
<source>Low Priority</source>
<comment>Standard matrix tag for low priority rooms</comment>
<translation type="unfinished"></translation>
</message>
<message>
<location line="+3"/>
<source>Server Notice</source>
<comment>Standard matrix tag for server notices</comment>
<translation type="unfinished"></translation>
</message>
<message>
<location line="+13"/>
<source>Adds or removes the specified tag.</source>
<comment>WhatsThis hint for tag menu actions</comment>
<translation type="unfinished"></translation>
</message>
<message>
<location line="+38"/>
<source>New tag...</source>
<comment>Add a new tag to the room</comment>
<translation type="unfinished"></translation>
</message>
<message>
<location line="+3"/>
<source>New Tag</source>
<comment>Tag name prompt title</comment>
<translation type="unfinished"></translation>
</message>
<message>
<location line="+0"/>
<source>Tag:</source>
<translation type="unfinished"></translation>
</message>
<message>
<location line="+173"/>
<source>Accept</source>
<translation>Hyväksy</translation>
</message>
@ -747,7 +793,7 @@ Example: https://server.my:8787</source>
<context>
<name>TimelineRow</name>
<message>
<location filename="../qml/TimelineRow.qml" line="+88"/>
<location filename="../qml/TimelineRow.qml" line="+92"/>
<source>Reply</source>
<translation type="unfinished"></translation>
</message>
@ -760,7 +806,7 @@ Example: https://server.my:8787</source>
<context>
<name>TimelineView</name>
<message>
<location filename="../qml/TimelineView.qml" line="+53"/>
<location filename="../qml/TimelineView.qml" line="+54"/>
<source>Reply</source>
<translation type="unfinished"></translation>
</message>
@ -800,7 +846,7 @@ Example: https://server.my:8787</source>
<translation type="unfinished"></translation>
</message>
<message>
<location line="+256"/>
<location line="+257"/>
<source>Close</source>
<translation type="unfinished">Sulje</translation>
</message>
@ -862,7 +908,7 @@ Example: https://server.my:8787</source>
<context>
<name>UserSettingsPage</name>
<message>
<location filename="../../src/UserSettingsPage.cpp" line="+335"/>
<location filename="../../src/UserSettingsPage.cpp" line="+339"/>
<source>Minimize to tray</source>
<translation>Pienennä ilmoitusalueelle</translation>
</message>
@ -916,6 +962,11 @@ Example: https://server.my:8787</source>
<source>Desktop notifications</source>
<translation>Työpöytäilmoitukset</translation>
</message>
<message>
<location line="+1"/>
<source>Highlight message on hover</source>
<translation type="unfinished"></translation>
</message>
<message>
<location line="+5"/>
<source>Scale factor</source>
@ -947,7 +998,7 @@ Example: https://server.my:8787</source>
<translation>Laitteen sormenjälki</translation>
</message>
<message>
<location line="-59"/>
<location line="-60"/>
<source>Session Keys</source>
<translation>Istunnon avaimet</translation>
</message>
@ -967,22 +1018,22 @@ Example: https://server.my:8787</source>
<translation>SALAUS</translation>
</message>
<message>
<location line="-63"/>
<location line="-64"/>
<source>GENERAL</source>
<translation>YLEISET ASETUKSET</translation>
</message>
<message>
<location line="+25"/>
<location line="+26"/>
<source>INTERFACE</source>
<translation type="unfinished"></translation>
</message>
<message>
<location line="+108"/>
<location line="+109"/>
<source>Emoji Font Family</source>
<translation type="unfinished"></translation>
</message>
<message>
<location line="+158"/>
<location line="+163"/>
<source>Open Sessions File</source>
<translation>Avaa Istuntoavaintiedosto</translation>
</message>

View file

@ -441,12 +441,58 @@ Example: https://server.my:8787</source>
<context>
<name>RoomInfoListItem</name>
<message>
<location filename="../../src/RoomInfoListItem.cpp" line="+98"/>
<location filename="../../src/RoomInfoListItem.cpp" line="+102"/>
<source>Leave room</source>
<translation>Quitter le salon</translation>
</message>
<message>
<location line="+160"/>
<location line="+7"/>
<source>Tag room as:</source>
<translation type="unfinished"></translation>
</message>
<message>
<location line="+7"/>
<source>Favourite</source>
<comment>Standard matrix tag for favourites</comment>
<translation type="unfinished"></translation>
</message>
<message>
<location line="+3"/>
<source>Low Priority</source>
<comment>Standard matrix tag for low priority rooms</comment>
<translation type="unfinished"></translation>
</message>
<message>
<location line="+3"/>
<source>Server Notice</source>
<comment>Standard matrix tag for server notices</comment>
<translation type="unfinished"></translation>
</message>
<message>
<location line="+13"/>
<source>Adds or removes the specified tag.</source>
<comment>WhatsThis hint for tag menu actions</comment>
<translation type="unfinished"></translation>
</message>
<message>
<location line="+38"/>
<source>New tag...</source>
<comment>Add a new tag to the room</comment>
<translation type="unfinished"></translation>
</message>
<message>
<location line="+3"/>
<source>New Tag</source>
<comment>Tag name prompt title</comment>
<translation type="unfinished"></translation>
</message>
<message>
<location line="+0"/>
<source>Tag:</source>
<translation type="unfinished"></translation>
</message>
<message>
<location line="+173"/>
<source>Accept</source>
<translation>Accepter</translation>
</message>
@ -747,7 +793,7 @@ Example: https://server.my:8787</source>
<context>
<name>TimelineRow</name>
<message>
<location filename="../qml/TimelineRow.qml" line="+88"/>
<location filename="../qml/TimelineRow.qml" line="+92"/>
<source>Reply</source>
<translation type="unfinished"></translation>
</message>
@ -760,7 +806,7 @@ Example: https://server.my:8787</source>
<context>
<name>TimelineView</name>
<message>
<location filename="../qml/TimelineView.qml" line="+53"/>
<location filename="../qml/TimelineView.qml" line="+54"/>
<source>Reply</source>
<translation type="unfinished"></translation>
</message>
@ -800,7 +846,7 @@ Example: https://server.my:8787</source>
<translation type="unfinished"></translation>
</message>
<message>
<location line="+256"/>
<location line="+257"/>
<source>Close</source>
<translation type="unfinished"></translation>
</message>
@ -862,7 +908,7 @@ Example: https://server.my:8787</source>
<context>
<name>UserSettingsPage</name>
<message>
<location filename="../../src/UserSettingsPage.cpp" line="+335"/>
<location filename="../../src/UserSettingsPage.cpp" line="+339"/>
<source>Minimize to tray</source>
<translation>Réduire à la barre des tâches</translation>
</message>
@ -916,6 +962,11 @@ Example: https://server.my:8787</source>
<source>Desktop notifications</source>
<translation type="unfinished"></translation>
</message>
<message>
<location line="+1"/>
<source>Highlight message on hover</source>
<translation type="unfinished"></translation>
</message>
<message>
<location line="+5"/>
<source>Scale factor</source>
@ -947,7 +998,7 @@ Example: https://server.my:8787</source>
<translation type="unfinished"></translation>
</message>
<message>
<location line="-59"/>
<location line="-60"/>
<source>Session Keys</source>
<translation type="unfinished"></translation>
</message>
@ -967,22 +1018,22 @@ Example: https://server.my:8787</source>
<translation type="unfinished"></translation>
</message>
<message>
<location line="-63"/>
<location line="-64"/>
<source>GENERAL</source>
<translation>GÉNÉRAL</translation>
</message>
<message>
<location line="+25"/>
<location line="+26"/>
<source>INTERFACE</source>
<translation type="unfinished"></translation>
</message>
<message>
<location line="+108"/>
<location line="+109"/>
<source>Emoji Font Family</source>
<translation type="unfinished"></translation>
</message>
<message>
<location line="+158"/>
<location line="+163"/>
<source>Open Sessions File</source>
<translation type="unfinished"></translation>
</message>

View file

@ -441,12 +441,58 @@ Example: https://server.my:8787</source>
<context>
<name>RoomInfoListItem</name>
<message>
<location filename="../../src/RoomInfoListItem.cpp" line="+98"/>
<location filename="../../src/RoomInfoListItem.cpp" line="+102"/>
<source>Leave room</source>
<translation></translation>
</message>
<message>
<location line="+160"/>
<location line="+7"/>
<source>Tag room as:</source>
<translation type="unfinished"></translation>
</message>
<message>
<location line="+7"/>
<source>Favourite</source>
<comment>Standard matrix tag for favourites</comment>
<translation type="unfinished"></translation>
</message>
<message>
<location line="+3"/>
<source>Low Priority</source>
<comment>Standard matrix tag for low priority rooms</comment>
<translation type="unfinished"></translation>
</message>
<message>
<location line="+3"/>
<source>Server Notice</source>
<comment>Standard matrix tag for server notices</comment>
<translation type="unfinished"></translation>
</message>
<message>
<location line="+13"/>
<source>Adds or removes the specified tag.</source>
<comment>WhatsThis hint for tag menu actions</comment>
<translation type="unfinished"></translation>
</message>
<message>
<location line="+38"/>
<source>New tag...</source>
<comment>Add a new tag to the room</comment>
<translation type="unfinished"></translation>
</message>
<message>
<location line="+3"/>
<source>New Tag</source>
<comment>Tag name prompt title</comment>
<translation type="unfinished"></translation>
</message>
<message>
<location line="+0"/>
<source>Tag:</source>
<translation type="unfinished"></translation>
</message>
<message>
<location line="+173"/>
<source>Accept</source>
<translation></translation>
</message>
@ -746,7 +792,7 @@ Example: https://server.my:8787</source>
<context>
<name>TimelineRow</name>
<message>
<location filename="../qml/TimelineRow.qml" line="+88"/>
<location filename="../qml/TimelineRow.qml" line="+92"/>
<source>Reply</source>
<translation></translation>
</message>
@ -759,7 +805,7 @@ Example: https://server.my:8787</source>
<context>
<name>TimelineView</name>
<message>
<location filename="../qml/TimelineView.qml" line="+53"/>
<location filename="../qml/TimelineView.qml" line="+54"/>
<source>Reply</source>
<translation type="unfinished"></translation>
</message>
@ -799,7 +845,7 @@ Example: https://server.my:8787</source>
<translation></translation>
</message>
<message>
<location line="+256"/>
<location line="+257"/>
<source>Close</source>
<translation></translation>
</message>
@ -861,7 +907,7 @@ Example: https://server.my:8787</source>
<context>
<name>UserSettingsPage</name>
<message>
<location filename="../../src/UserSettingsPage.cpp" line="+335"/>
<location filename="../../src/UserSettingsPage.cpp" line="+339"/>
<source>Minimize to tray</source>
<translation></translation>
</message>
@ -915,6 +961,11 @@ Example: https://server.my:8787</source>
<source>Desktop notifications</source>
<translation></translation>
</message>
<message>
<location line="+1"/>
<source>Highlight message on hover</source>
<translation type="unfinished"></translation>
</message>
<message>
<location line="+5"/>
<source>Scale factor</source>
@ -946,7 +997,7 @@ Example: https://server.my:8787</source>
<translation></translation>
</message>
<message>
<location line="-59"/>
<location line="-60"/>
<source>Session Keys</source>
<translation></translation>
</message>
@ -966,22 +1017,22 @@ Example: https://server.my:8787</source>
<translation></translation>
</message>
<message>
<location line="-63"/>
<location line="-64"/>
<source>GENERAL</source>
<translation></translation>
</message>
<message>
<location line="+25"/>
<location line="+26"/>
<source>INTERFACE</source>
<translation type="unfinished"></translation>
</message>
<message>
<location line="+108"/>
<location line="+109"/>
<source>Emoji Font Family</source>
<translation type="unfinished"></translation>
</message>
<message>
<location line="+158"/>
<location line="+163"/>
<source>Open Sessions File</source>
<translation></translation>
</message>

View file

@ -441,12 +441,58 @@ Example: https://server.my:8787</source>
<context>
<name>RoomInfoListItem</name>
<message>
<location filename="../../src/RoomInfoListItem.cpp" line="+98"/>
<location filename="../../src/RoomInfoListItem.cpp" line="+102"/>
<source>Leave room</source>
<translation>Kamer verlaten</translation>
</message>
<message>
<location line="+160"/>
<location line="+7"/>
<source>Tag room as:</source>
<translation type="unfinished"></translation>
</message>
<message>
<location line="+7"/>
<source>Favourite</source>
<comment>Standard matrix tag for favourites</comment>
<translation type="unfinished"></translation>
</message>
<message>
<location line="+3"/>
<source>Low Priority</source>
<comment>Standard matrix tag for low priority rooms</comment>
<translation type="unfinished"></translation>
</message>
<message>
<location line="+3"/>
<source>Server Notice</source>
<comment>Standard matrix tag for server notices</comment>
<translation type="unfinished"></translation>
</message>
<message>
<location line="+13"/>
<source>Adds or removes the specified tag.</source>
<comment>WhatsThis hint for tag menu actions</comment>
<translation type="unfinished"></translation>
</message>
<message>
<location line="+38"/>
<source>New tag...</source>
<comment>Add a new tag to the room</comment>
<translation type="unfinished"></translation>
</message>
<message>
<location line="+3"/>
<source>New Tag</source>
<comment>Tag name prompt title</comment>
<translation type="unfinished"></translation>
</message>
<message>
<location line="+0"/>
<source>Tag:</source>
<translation type="unfinished"></translation>
</message>
<message>
<location line="+173"/>
<source>Accept</source>
<translation>Accepteren</translation>
</message>
@ -747,7 +793,7 @@ Example: https://server.my:8787</source>
<context>
<name>TimelineRow</name>
<message>
<location filename="../qml/TimelineRow.qml" line="+88"/>
<location filename="../qml/TimelineRow.qml" line="+92"/>
<source>Reply</source>
<translation type="unfinished"></translation>
</message>
@ -760,7 +806,7 @@ Example: https://server.my:8787</source>
<context>
<name>TimelineView</name>
<message>
<location filename="../qml/TimelineView.qml" line="+53"/>
<location filename="../qml/TimelineView.qml" line="+54"/>
<source>Reply</source>
<translation type="unfinished"></translation>
</message>
@ -800,7 +846,7 @@ Example: https://server.my:8787</source>
<translation type="unfinished"></translation>
</message>
<message>
<location line="+256"/>
<location line="+257"/>
<source>Close</source>
<translation type="unfinished"></translation>
</message>
@ -862,7 +908,7 @@ Example: https://server.my:8787</source>
<context>
<name>UserSettingsPage</name>
<message>
<location filename="../../src/UserSettingsPage.cpp" line="+335"/>
<location filename="../../src/UserSettingsPage.cpp" line="+339"/>
<source>Minimize to tray</source>
<translation>Minimaliseren naar systeemvak</translation>
</message>
@ -916,6 +962,11 @@ Example: https://server.my:8787</source>
<source>Desktop notifications</source>
<translation type="unfinished"></translation>
</message>
<message>
<location line="+1"/>
<source>Highlight message on hover</source>
<translation type="unfinished"></translation>
</message>
<message>
<location line="+5"/>
<source>Scale factor</source>
@ -947,7 +998,7 @@ Example: https://server.my:8787</source>
<translation type="unfinished"></translation>
</message>
<message>
<location line="-59"/>
<location line="-60"/>
<source>Session Keys</source>
<translation type="unfinished"></translation>
</message>
@ -967,22 +1018,22 @@ Example: https://server.my:8787</source>
<translation type="unfinished"></translation>
</message>
<message>
<location line="-63"/>
<location line="-64"/>
<source>GENERAL</source>
<translation>ALGEMEEN</translation>
</message>
<message>
<location line="+25"/>
<location line="+26"/>
<source>INTERFACE</source>
<translation type="unfinished"></translation>
</message>
<message>
<location line="+108"/>
<location line="+109"/>
<source>Emoji Font Family</source>
<translation type="unfinished"></translation>
</message>
<message>
<location line="+158"/>
<location line="+163"/>
<source>Open Sessions File</source>
<translation type="unfinished"></translation>
</message>

View file

@ -441,12 +441,58 @@ Example: https://server.my:8787</source>
<context>
<name>RoomInfoListItem</name>
<message>
<location filename="../../src/RoomInfoListItem.cpp" line="+98"/>
<location filename="../../src/RoomInfoListItem.cpp" line="+102"/>
<source>Leave room</source>
<translation>Opuść pokój</translation>
</message>
<message>
<location line="+160"/>
<location line="+7"/>
<source>Tag room as:</source>
<translation type="unfinished"></translation>
</message>
<message>
<location line="+7"/>
<source>Favourite</source>
<comment>Standard matrix tag for favourites</comment>
<translation type="unfinished"></translation>
</message>
<message>
<location line="+3"/>
<source>Low Priority</source>
<comment>Standard matrix tag for low priority rooms</comment>
<translation type="unfinished"></translation>
</message>
<message>
<location line="+3"/>
<source>Server Notice</source>
<comment>Standard matrix tag for server notices</comment>
<translation type="unfinished"></translation>
</message>
<message>
<location line="+13"/>
<source>Adds or removes the specified tag.</source>
<comment>WhatsThis hint for tag menu actions</comment>
<translation type="unfinished"></translation>
</message>
<message>
<location line="+38"/>
<source>New tag...</source>
<comment>Add a new tag to the room</comment>
<translation type="unfinished"></translation>
</message>
<message>
<location line="+3"/>
<source>New Tag</source>
<comment>Tag name prompt title</comment>
<translation type="unfinished"></translation>
</message>
<message>
<location line="+0"/>
<source>Tag:</source>
<translation type="unfinished"></translation>
</message>
<message>
<location line="+173"/>
<source>Accept</source>
<translation>Akceptuj</translation>
</message>
@ -748,7 +794,7 @@ Example: https://server.my:8787</source>
<context>
<name>TimelineRow</name>
<message>
<location filename="../qml/TimelineRow.qml" line="+88"/>
<location filename="../qml/TimelineRow.qml" line="+92"/>
<source>Reply</source>
<translation type="unfinished"></translation>
</message>
@ -761,7 +807,7 @@ Example: https://server.my:8787</source>
<context>
<name>TimelineView</name>
<message>
<location filename="../qml/TimelineView.qml" line="+53"/>
<location filename="../qml/TimelineView.qml" line="+54"/>
<source>Reply</source>
<translation type="unfinished"></translation>
</message>
@ -801,7 +847,7 @@ Example: https://server.my:8787</source>
<translation type="unfinished"></translation>
</message>
<message>
<location line="+256"/>
<location line="+257"/>
<source>Close</source>
<translation type="unfinished"></translation>
</message>
@ -863,7 +909,7 @@ Example: https://server.my:8787</source>
<context>
<name>UserSettingsPage</name>
<message>
<location filename="../../src/UserSettingsPage.cpp" line="+335"/>
<location filename="../../src/UserSettingsPage.cpp" line="+339"/>
<source>Minimize to tray</source>
<translation>Zminimalizuj do paska zadań</translation>
</message>
@ -917,6 +963,11 @@ Example: https://server.my:8787</source>
<source>Desktop notifications</source>
<translation>Powiadomienia na pulpicie</translation>
</message>
<message>
<location line="+1"/>
<source>Highlight message on hover</source>
<translation type="unfinished"></translation>
</message>
<message>
<location line="+5"/>
<source>Scale factor</source>
@ -948,7 +999,7 @@ Example: https://server.my:8787</source>
<translation>Odcisk palca urządzenia</translation>
</message>
<message>
<location line="-59"/>
<location line="-60"/>
<source>Session Keys</source>
<translation type="unfinished"></translation>
</message>
@ -968,22 +1019,22 @@ Example: https://server.my:8787</source>
<translation>SZYFROWANIE</translation>
</message>
<message>
<location line="-63"/>
<location line="-64"/>
<source>GENERAL</source>
<translation>OGÓLNE</translation>
</message>
<message>
<location line="+25"/>
<location line="+26"/>
<source>INTERFACE</source>
<translation type="unfinished"></translation>
</message>
<message>
<location line="+108"/>
<location line="+109"/>
<source>Emoji Font Family</source>
<translation type="unfinished"></translation>
</message>
<message>
<location line="+158"/>
<location line="+163"/>
<source>Open Sessions File</source>
<translation type="unfinished"></translation>
</message>

View file

@ -441,12 +441,58 @@ Example: https://server.my:8787</source>
<context>
<name>RoomInfoListItem</name>
<message>
<location filename="../../src/RoomInfoListItem.cpp" line="+98"/>
<location filename="../../src/RoomInfoListItem.cpp" line="+102"/>
<source>Leave room</source>
<translation>Покинуть комнату</translation>
</message>
<message>
<location line="+160"/>
<location line="+7"/>
<source>Tag room as:</source>
<translation type="unfinished"></translation>
</message>
<message>
<location line="+7"/>
<source>Favourite</source>
<comment>Standard matrix tag for favourites</comment>
<translation type="unfinished"></translation>
</message>
<message>
<location line="+3"/>
<source>Low Priority</source>
<comment>Standard matrix tag for low priority rooms</comment>
<translation type="unfinished"></translation>
</message>
<message>
<location line="+3"/>
<source>Server Notice</source>
<comment>Standard matrix tag for server notices</comment>
<translation type="unfinished"></translation>
</message>
<message>
<location line="+13"/>
<source>Adds or removes the specified tag.</source>
<comment>WhatsThis hint for tag menu actions</comment>
<translation type="unfinished"></translation>
</message>
<message>
<location line="+38"/>
<source>New tag...</source>
<comment>Add a new tag to the room</comment>
<translation type="unfinished"></translation>
</message>
<message>
<location line="+3"/>
<source>New Tag</source>
<comment>Tag name prompt title</comment>
<translation type="unfinished"></translation>
</message>
<message>
<location line="+0"/>
<source>Tag:</source>
<translation type="unfinished"></translation>
</message>
<message>
<location line="+173"/>
<source>Accept</source>
<translation>Принять</translation>
</message>
@ -748,7 +794,7 @@ Example: https://server.my:8787</source>
<context>
<name>TimelineRow</name>
<message>
<location filename="../qml/TimelineRow.qml" line="+88"/>
<location filename="../qml/TimelineRow.qml" line="+92"/>
<source>Reply</source>
<translation type="unfinished"></translation>
</message>
@ -761,7 +807,7 @@ Example: https://server.my:8787</source>
<context>
<name>TimelineView</name>
<message>
<location filename="../qml/TimelineView.qml" line="+53"/>
<location filename="../qml/TimelineView.qml" line="+54"/>
<source>Reply</source>
<translation type="unfinished"></translation>
</message>
@ -801,7 +847,7 @@ Example: https://server.my:8787</source>
<translation type="unfinished"></translation>
</message>
<message>
<location line="+256"/>
<location line="+257"/>
<source>Close</source>
<translation type="unfinished">Закрыть</translation>
</message>
@ -863,7 +909,7 @@ Example: https://server.my:8787</source>
<context>
<name>UserSettingsPage</name>
<message>
<location filename="../../src/UserSettingsPage.cpp" line="+335"/>
<location filename="../../src/UserSettingsPage.cpp" line="+339"/>
<source>Minimize to tray</source>
<translation>Сворачивать в системную панель</translation>
</message>
@ -917,6 +963,11 @@ Example: https://server.my:8787</source>
<source>Desktop notifications</source>
<translation>Уведомления на рабочем столе</translation>
</message>
<message>
<location line="+1"/>
<source>Highlight message on hover</source>
<translation type="unfinished"></translation>
</message>
<message>
<location line="+5"/>
<source>Scale factor</source>
@ -948,7 +999,7 @@ Example: https://server.my:8787</source>
<translation>Отпечаток устройства</translation>
</message>
<message>
<location line="-59"/>
<location line="-60"/>
<source>Session Keys</source>
<translation>Ключи сеанса</translation>
</message>
@ -968,22 +1019,22 @@ Example: https://server.my:8787</source>
<translation>ШИФРОВАНИЕ</translation>
</message>
<message>
<location line="-63"/>
<location line="-64"/>
<source>GENERAL</source>
<translation>ГЛАВНОЕ</translation>
</message>
<message>
<location line="+25"/>
<location line="+26"/>
<source>INTERFACE</source>
<translation type="unfinished"></translation>
</message>
<message>
<location line="+108"/>
<location line="+109"/>
<source>Emoji Font Family</source>
<translation type="unfinished"></translation>
</message>
<message>
<location line="+158"/>
<location line="+163"/>
<source>Open Sessions File</source>
<translation>Открыть файл сеансов</translation>
</message>

View file

@ -441,12 +441,58 @@ Example: https://server.my:8787</source>
<context>
<name>RoomInfoListItem</name>
<message>
<location filename="../../src/RoomInfoListItem.cpp" line="+98"/>
<location filename="../../src/RoomInfoListItem.cpp" line="+102"/>
<source>Leave room</source>
<translation></translation>
</message>
<message>
<location line="+160"/>
<location line="+7"/>
<source>Tag room as:</source>
<translation type="unfinished"></translation>
</message>
<message>
<location line="+7"/>
<source>Favourite</source>
<comment>Standard matrix tag for favourites</comment>
<translation type="unfinished"></translation>
</message>
<message>
<location line="+3"/>
<source>Low Priority</source>
<comment>Standard matrix tag for low priority rooms</comment>
<translation type="unfinished"></translation>
</message>
<message>
<location line="+3"/>
<source>Server Notice</source>
<comment>Standard matrix tag for server notices</comment>
<translation type="unfinished"></translation>
</message>
<message>
<location line="+13"/>
<source>Adds or removes the specified tag.</source>
<comment>WhatsThis hint for tag menu actions</comment>
<translation type="unfinished"></translation>
</message>
<message>
<location line="+38"/>
<source>New tag...</source>
<comment>Add a new tag to the room</comment>
<translation type="unfinished"></translation>
</message>
<message>
<location line="+3"/>
<source>New Tag</source>
<comment>Tag name prompt title</comment>
<translation type="unfinished"></translation>
</message>
<message>
<location line="+0"/>
<source>Tag:</source>
<translation type="unfinished"></translation>
</message>
<message>
<location line="+173"/>
<source>Accept</source>
<translation></translation>
</message>
@ -746,7 +792,7 @@ Example: https://server.my:8787</source>
<context>
<name>TimelineRow</name>
<message>
<location filename="../qml/TimelineRow.qml" line="+88"/>
<location filename="../qml/TimelineRow.qml" line="+92"/>
<source>Reply</source>
<translation type="unfinished"></translation>
</message>
@ -759,7 +805,7 @@ Example: https://server.my:8787</source>
<context>
<name>TimelineView</name>
<message>
<location filename="../qml/TimelineView.qml" line="+53"/>
<location filename="../qml/TimelineView.qml" line="+54"/>
<source>Reply</source>
<translation type="unfinished"></translation>
</message>
@ -799,7 +845,7 @@ Example: https://server.my:8787</source>
<translation type="unfinished"></translation>
</message>
<message>
<location line="+256"/>
<location line="+257"/>
<source>Close</source>
<translation type="unfinished"></translation>
</message>
@ -861,7 +907,7 @@ Example: https://server.my:8787</source>
<context>
<name>UserSettingsPage</name>
<message>
<location filename="../../src/UserSettingsPage.cpp" line="+335"/>
<location filename="../../src/UserSettingsPage.cpp" line="+339"/>
<source>Minimize to tray</source>
<translation></translation>
</message>
@ -915,6 +961,11 @@ Example: https://server.my:8787</source>
<source>Desktop notifications</source>
<translation></translation>
</message>
<message>
<location line="+1"/>
<source>Highlight message on hover</source>
<translation type="unfinished"></translation>
</message>
<message>
<location line="+5"/>
<source>Scale factor</source>
@ -946,7 +997,7 @@ Example: https://server.my:8787</source>
<translation></translation>
</message>
<message>
<location line="-59"/>
<location line="-60"/>
<source>Session Keys</source>
<translation></translation>
</message>
@ -966,22 +1017,22 @@ Example: https://server.my:8787</source>
<translation></translation>
</message>
<message>
<location line="-63"/>
<location line="-64"/>
<source>GENERAL</source>
<translation></translation>
</message>
<message>
<location line="+25"/>
<location line="+26"/>
<source>INTERFACE</source>
<translation type="unfinished"></translation>
</message>
<message>
<location line="+108"/>
<location line="+109"/>
<source>Emoji Font Family</source>
<translation type="unfinished"></translation>
</message>
<message>
<location line="+158"/>
<location line="+163"/>
<source>Open Sessions File</source>
<translation></translation>
</message>

View file

@ -915,8 +915,8 @@ Cache::saveState(const mtx::responses::Sync &res)
bool has_new_tags = false;
for (const auto &evt : room.second.account_data.events) {
// for now only fetch tag events
if (std::holds_alternative<Event<account_data::Tag>>(evt)) {
auto tags_evt = std::get<Event<account_data::Tag>>(evt);
if (std::holds_alternative<Event<account_data::Tags>>(evt)) {
auto tags_evt = std::get<Event<account_data::Tags>>(evt);
has_new_tags = true;
for (const auto &tag : tags_evt.content.tags) {
updatedInfo.tags.push_back(tag.first);
@ -1081,7 +1081,7 @@ Cache::roomsWithTagUpdates(const mtx::responses::Sync &res)
for (const auto &room : res.rooms.join) {
bool hasUpdates = false;
for (const auto &evt : room.second.account_data.events) {
if (std::holds_alternative<Event<account_data::Tag>>(evt)) {
if (std::holds_alternative<Event<account_data::Tags>>(evt)) {
hasUpdates = true;
}
}

View file

@ -77,6 +77,8 @@ public:
QSharedPointer<UserSettings> userSettings() { return userSettings_; }
void deleteConfigs();
CommunitiesList *communitiesList() { return communitiesList_; }
//! Calculate the width of the message timeline.
uint64_t timelineWidth();
bool isSideBarExpanded();

View file

@ -257,6 +257,18 @@ CommunitiesList::roomList(const QString &id) const
return {};
}
std::vector<std::string>
CommunitiesList::currentTags() const
{
std::vector<std::string> tags;
for (auto &entry : communities_) {
CommunitiesListItem *item = entry.second.data();
if (item->is_tag())
tags.push_back(entry.first.mid(4).toStdString());
}
return tags;
}
void
CommunitiesList::sortEntries()
{

View file

@ -28,6 +28,7 @@ public:
void syncTags(const std::map<QString, RoomInfo> &info);
void setTagsForRoom(const QString &id, const std::vector<std::string> &tags);
std::vector<std::string> currentTags() const;
signals:
void communityChanged(const QString &id);

View file

@ -137,6 +137,8 @@ CommunitiesListItem::updateTooltip()
setToolTip(tr("Favourite rooms"));
else if (tag == "m.lowpriority")
setToolTip(tr("Low priority rooms"));
else if (tag == "m.server_notice")
setToolTip(tr("Server Notices", "Tag translation for m.server_notice"));
else if (tag.startsWith("u."))
setToolTip(tag.right(tag.size() - 2) + tr(" (tag)"));
else

View file

@ -16,6 +16,7 @@
*/
#include <QDateTime>
#include <QInputDialog>
#include <QMouseEvent>
#include <QPainter>
#include <QSettings>
@ -23,7 +24,10 @@
#include "AvatarProvider.h"
#include "Cache.h"
#include "ChatPage.h"
#include "Config.h"
#include "Logging.h"
#include "MatrixClient.h"
#include "RoomInfoListItem.h"
#include "Splitter.h"
#include "UserSettingsPage.h"
@ -97,7 +101,106 @@ RoomInfoListItem::init(QWidget *parent)
menu_ = new Menu(this);
leaveRoom_ = new QAction(tr("Leave room"), this);
connect(leaveRoom_, &QAction::triggered, this, [this]() { emit leaveRoom(roomId_); });
menu_->addAction(leaveRoom_);
connect(menu_, &QMenu::aboutToShow, this, [this]() {
menu_->clear();
menu_->addAction(leaveRoom_);
menu_->addSection(QIcon(":/icons/icons/ui/tag.png"), tr("Tag room as:"));
auto roomInfo = cache::singleRoomInfo(roomId_.toStdString());
auto tags = ChatPage::instance()->communitiesList()->currentTags();
// add default tag, remove server notice tag
if (std::find(tags.begin(), tags.end(), "m.favourite") == tags.end())
tags.push_back("m.favourite");
if (std::find(tags.begin(), tags.end(), "m.lowpriority") == tags.end())
tags.push_back("m.lowpriority");
if (auto it = std::find(tags.begin(), tags.end(), "m.server_notice");
it != tags.end())
tags.erase(it);
for (const auto &tag : tags) {
QString tagName;
if (tag == "m.favourite")
tagName = tr("Favourite", "Standard matrix tag for favourites");
else if (tag == "m.lowpriority")
tagName =
tr("Low Priority", "Standard matrix tag for low priority rooms");
else if (tag == "m.server_notice")
tagName =
tr("Server Notice", "Standard matrix tag for server notices");
else if ((tag.size() > 2 && tag.substr(0, 2) == "u.") ||
tag.find(".") !=
std::string::npos) // tag manager creates tags without u., which
// is wrong, but we still want to display them
tagName = QString::fromStdString(tag.substr(2));
if (tagName.isEmpty())
continue;
auto tagAction = menu_->addAction(tagName);
tagAction->setCheckable(true);
tagAction->setWhatsThis(tr("Adds or removes the specified tag.",
"WhatsThis hint for tag menu actions"));
for (const auto &riTag : roomInfo.tags)
if (riTag == tag) {
tagAction->setChecked(true);
break;
}
connect(tagAction, &QAction::triggered, this, [this, tag](bool checked) {
if (checked)
http::client()->put_tag(
roomId_.toStdString(),
tag,
{},
[tag](mtx::http::RequestErr err) {
if (err) {
nhlog::ui()->error(
"Failed to add tag: {}, {}",
tag,
err->matrix_error.error);
}
});
else
http::client()->delete_tag(
roomId_.toStdString(),
tag,
[tag](mtx::http::RequestErr err) {
if (err) {
nhlog::ui()->error(
"Failed to delete tag: {}, {}",
tag,
err->matrix_error.error);
}
});
});
}
auto newTagAction = menu_->addAction(tr("New tag...", "Add a new tag to the room"));
connect(newTagAction, &QAction::triggered, this, [this]() {
QString tagName =
QInputDialog::getText(this,
tr("New Tag", "Tag name prompt title"),
tr("Tag:", "Tag name prompt"));
if (tagName.isEmpty())
return;
std::string tag = "u." + tagName.toStdString();
http::client()->put_tag(
roomId_.toStdString(), tag, {}, [tag](mtx::http::RequestErr err) {
if (err) {
nhlog::ui()->error("Failed to add tag: {}, {}",
tag,
err->matrix_error.error);
}
});
});
});
}
RoomInfoListItem::RoomInfoListItem(QString room_id,