diff options
author | link2xt <link2xt@testrun.org> | 2021-08-07 21:36:51 +0000 |
---|---|---|
committer | link2xt <link2xt@testrun.org> | 2021-08-07 21:36:51 +0000 |
commit | 80856b853b49b53322425a90ae801bca760cf740 (patch) | |
tree | c6eedce43d428d728fbd122ad43057b35138028f /qml | |
parent | 541cfbdad5596e55b686abd02a93638f0a7f75f6 (diff) | |
download | kdeltachat-80856b853b49b53322425a90ae801bca760cf740.tar.gz kdeltachat-80856b853b49b53322425a90ae801bca760cf740.zip |
Use `dc_send_msg` to send messages
`dc_send_text_msg` is too limited as it can only send text without attachments.
Diffstat (limited to 'qml')
-rw-r--r-- | qml/ComposePane.qml | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/qml/ComposePane.qml b/qml/ComposePane.qml index 5ba77f5..dab07f1 100644 --- a/qml/ComposePane.qml +++ b/qml/ComposePane.qml @@ -48,7 +48,12 @@ Pane { text: qsTr("Send") enabled: messageField.length > 0 onClicked: { - root.context.sendTextMessage(chatId, messageField.text) + let DC_MSG_TEXT = 10; + + let msg = root.context.newMessage(DC_MSG_TEXT); + msg.setText(messageField.text) + root.context.sendMessage(root.chatId, msg) + messageField.text = "" root.context.setDraft(chatId, null) } |