Add Alt-F to forward messages

This commit is contained in:
Nicolas Werner 2021-04-27 12:09:00 +02:00
parent 788131daf0
commit 5b6671f063
No known key found for this signature in database
GPG key ID: C8D75E610773F2D9

View file

@ -165,7 +165,19 @@ ScrollView {
sequence: "Alt+Down"
onActivated: {
var idx = chat.model.reply ? chat.model.idToIndex(chat.model.reply) - 1 : -1;
chat.model.reply = idx >= 0 ? chat.model.indexToId(idx) : undefined;
chat.model.reply = idx >= 0 ? chat.model.indexToId(idx) : null;
}
}
Shortcut {
sequence: "Alt+F"
onActivated: {
if (chat.model.reply) {
var forwardMess = forwardCompleterComponent.createObject(timelineRoot);
forwardMess.setMessageEventId(chat.model.reply);
forwardMess.open();
chat.model.reply = null;
}
}
}