mirror of
https://github.com/chatmail/core.git
synced 2026-05-19 14:56:33 +03:00
integration @r10s' additions
This commit is contained in:
@@ -60,8 +60,6 @@
|
|||||||
- Document accounts manager #3837
|
- Document accounts manager #3837
|
||||||
- If a classical-email-user sends an email to a group and adds new recipients,
|
- If a classical-email-user sends an email to a group and adds new recipients,
|
||||||
add the new recipients as group members #3781
|
add the new recipients as group members #3781
|
||||||
|
|
||||||
### API-Changes
|
|
||||||
- Remove `pytest-async` plugin #3846
|
- Remove `pytest-async` plugin #3846
|
||||||
- Only send the message about ephemeral timer change if the chat is promoted #3847
|
- Only send the message about ephemeral timer change if the chat is promoted #3847
|
||||||
- Use relative paths in `accounts.toml` #3838
|
- Use relative paths in `accounts.toml` #3838
|
||||||
|
|||||||
@@ -1088,7 +1088,7 @@ char* dc_get_webxdc_status_updates (dc_context_t* context, uint32_t msg_id, uint
|
|||||||
|
|
||||||
* @param context The context object.
|
* @param context The context object.
|
||||||
* @param msg_id The ID of the message with the webxdc instance.
|
* @param msg_id The ID of the message with the webxdc instance.
|
||||||
* @return 1=contact ID is member of chat ID, 0=contact is not in chat
|
* @return 1 = webxdc is updating , 0 = webxdc is not updating
|
||||||
*/
|
*/
|
||||||
int dc_is_webxdc_updating (dc_context_t* context, uint32_t msg_id);
|
int dc_is_webxdc_updating (dc_context_t* context, uint32_t msg_id);
|
||||||
|
|
||||||
@@ -5892,7 +5892,7 @@ void dc_event_unref(dc_event_t* event);
|
|||||||
* @param data1 (int) msg_id
|
* @param data1 (int) msg_id
|
||||||
* @param data1 (int) is_sending
|
* @param data1 (int) is_sending
|
||||||
*/
|
*/
|
||||||
#define DC_EVENT_WEBXDC_UPDATE_STATE_CHANGED 2017
|
#define DC_EVENT_WEBXDC_UPDATE_STATE_CHANGED 2122
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @}
|
* @}
|
||||||
|
|||||||
@@ -521,7 +521,7 @@ pub unsafe extern "C" fn dc_event_get_id(event: *mut dc_event_t) -> libc::c_int
|
|||||||
EventType::SelfavatarChanged => 2110,
|
EventType::SelfavatarChanged => 2110,
|
||||||
EventType::WebxdcStatusUpdate { .. } => 2120,
|
EventType::WebxdcStatusUpdate { .. } => 2120,
|
||||||
EventType::WebxdcInstanceDeleted { .. } => 2121,
|
EventType::WebxdcInstanceDeleted { .. } => 2121,
|
||||||
EventType::WebxdcUpdateStateChanged { .. } => 2017,
|
EventType::WebxdcUpdateStateChanged { .. } => 2122,
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -621,7 +621,7 @@ pub unsafe extern "C" fn dc_event_get_data2_int(event: *mut dc_event_t) -> libc:
|
|||||||
..
|
..
|
||||||
} => status_update_serial.to_u32() as libc::c_int,
|
} => status_update_serial.to_u32() as libc::c_int,
|
||||||
EventType::WebxdcUpdateStateChanged {
|
EventType::WebxdcUpdateStateChanged {
|
||||||
is_sending: is_send,
|
has_pending_updates: is_send,
|
||||||
..
|
..
|
||||||
} => *is_send as libc::c_int,
|
} => *is_send as libc::c_int,
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -324,6 +324,6 @@ pub enum EventType {
|
|||||||
/// Informs that the webxdc changed its update sending state
|
/// Informs that the webxdc changed its update sending state
|
||||||
WebxdcUpdateStateChanged {
|
WebxdcUpdateStateChanged {
|
||||||
msg_id: MsgId,
|
msg_id: MsgId,
|
||||||
is_sending: bool,
|
has_pending_updates: bool,
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -21,7 +21,6 @@ use crate::oauth2::get_oauth2_access_token;
|
|||||||
use crate::provider::Socket;
|
use crate::provider::Socket;
|
||||||
use crate::socks::Socks5Config;
|
use crate::socks::Socks5Config;
|
||||||
use crate::sql;
|
use crate::sql;
|
||||||
|
|
||||||
use crate::{context::Context, scheduler::connectivity::ConnectivityStore};
|
use crate::{context::Context, scheduler::connectivity::ConnectivityStore};
|
||||||
|
|
||||||
/// SMTP write and read timeout in seconds.
|
/// SMTP write and read timeout in seconds.
|
||||||
|
|||||||
@@ -405,11 +405,6 @@ impl Context {
|
|||||||
)
|
)
|
||||||
.await?;
|
.await?;
|
||||||
|
|
||||||
self.emit_event(EventType::WebxdcUpdateStateChanged {
|
|
||||||
msg_id: instance.id,
|
|
||||||
is_sending: true,
|
|
||||||
});
|
|
||||||
|
|
||||||
if send_now {
|
if send_now {
|
||||||
self.sql.insert(
|
self.sql.insert(
|
||||||
"INSERT INTO smtp_status_updates (msg_id, first_serial, last_serial, descr) VALUES(?, ?, ?, ?)
|
"INSERT INTO smtp_status_updates (msg_id, first_serial, last_serial, descr) VALUES(?, ?, ?, ?)
|
||||||
@@ -417,6 +412,12 @@ impl Context {
|
|||||||
DO UPDATE SET last_serial=excluded.last_serial, descr=excluded.descr",
|
DO UPDATE SET last_serial=excluded.last_serial, descr=excluded.descr",
|
||||||
paramsv![instance.id, status_update_serial, status_update_serial, descr],
|
paramsv![instance.id, status_update_serial, status_update_serial, descr],
|
||||||
).await?;
|
).await?;
|
||||||
|
|
||||||
|
self.emit_event(EventType::WebxdcUpdateStateChanged {
|
||||||
|
msg_id: instance.id,
|
||||||
|
has_pending_updates: true,
|
||||||
|
});
|
||||||
|
|
||||||
self.interrupt_smtp(InterruptInfo::new(false)).await;
|
self.interrupt_smtp(InterruptInfo::new(false)).await;
|
||||||
}
|
}
|
||||||
Ok(())
|
Ok(())
|
||||||
@@ -477,7 +478,7 @@ impl Context {
|
|||||||
for msg_id in update_needed.difference(&update_needed_after_sending) {
|
for msg_id in update_needed.difference(&update_needed_after_sending) {
|
||||||
self.emit_event(EventType::WebxdcUpdateStateChanged {
|
self.emit_event(EventType::WebxdcUpdateStateChanged {
|
||||||
msg_id: *msg_id,
|
msg_id: *msg_id,
|
||||||
is_sending: false,
|
has_pending_updates: false,
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
Ok(())
|
Ok(())
|
||||||
@@ -2456,7 +2457,7 @@ sth_for_the = "future""#
|
|||||||
matches!(
|
matches!(
|
||||||
evt,
|
evt,
|
||||||
EventType::WebxdcUpdateStateChanged {
|
EventType::WebxdcUpdateStateChanged {
|
||||||
is_sending: true,
|
has_pending_updates: true,
|
||||||
..
|
..
|
||||||
}
|
}
|
||||||
)
|
)
|
||||||
@@ -2471,7 +2472,7 @@ sth_for_the = "future""#
|
|||||||
matches!(
|
matches!(
|
||||||
evt,
|
evt,
|
||||||
EventType::WebxdcUpdateStateChanged {
|
EventType::WebxdcUpdateStateChanged {
|
||||||
is_sending: false,
|
has_pending_updates: false,
|
||||||
..
|
..
|
||||||
}
|
}
|
||||||
)
|
)
|
||||||
|
|||||||
Reference in New Issue
Block a user