From 60ce1bf638ee20b0ac107c5750a666e44806c3b7 Mon Sep 17 00:00:00 2001 From: Maximilian Steinert <71747937+iradraconis@users.noreply.github.com> Date: Tue, 8 Oct 2024 21:26:27 +0200 Subject: [PATCH] added "from" to compose call --- .../jlawyer/client/mail/SendEmailDialog.java | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/j-lawyer-client/src/com/jdimension/jlawyer/client/mail/SendEmailDialog.java b/j-lawyer-client/src/com/jdimension/jlawyer/client/mail/SendEmailDialog.java index 6b024cdd5..972eac01f 100755 --- a/j-lawyer-client/src/com/jdimension/jlawyer/client/mail/SendEmailDialog.java +++ b/j-lawyer-client/src/com/jdimension/jlawyer/client/mail/SendEmailDialog.java @@ -2629,6 +2629,12 @@ private void cmdOpenTbActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIR JOptionPane.showMessageDialog(this, "Thunderbird wurde nicht gefunden."); return; } + // Absender ermitteln + String from = ""; + MailboxSetup fromMailbox = getSelectedMailbox(); + if (fromMailbox != null) { + from = fromMailbox.getEmailAddress(); + } // Empfänger, CC, BCC und Betreff aus den Textfeldern holen String to = this.txtTo.getText().trim(); @@ -2656,9 +2662,11 @@ private void cmdOpenTbActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIR command.add("-compose"); StringBuilder composeCommand = new StringBuilder(); + + composeCommand.append("from='").append(from).append("'"); if (!to.isEmpty()) { - composeCommand.append("to='").append(to).append("'"); + composeCommand.append(",to='").append(to).append("'"); } else { JOptionPane.showMessageDialog(this, "Empfänger ist erforderlich."); return;