mirror of
http://shenjack.top:5100/shenjack/icalingua-python-bot.git
synced 2024-11-23 20:45:06 +08:00
啊?
This commit is contained in:
parent
38d9988cdc
commit
4b1ed03b9a
|
@ -89,12 +89,7 @@ pub enum SendingFile {
|
||||||
None,
|
None,
|
||||||
/// 需要生成
|
/// 需要生成
|
||||||
/// [img height=1329 width=1918]{BACKEND}/static/files/6602e20d7b8d10675758e36b/8db505b87bdf9fb309467abcec4d8e2a.png[/img]
|
/// [img height=1329 width=1918]{BACKEND}/static/files/6602e20d7b8d10675758e36b/8db505b87bdf9fb309467abcec4d8e2a.png[/img]
|
||||||
Image {
|
Image { file: Vec<u8>, name: String },
|
||||||
file: Vec<u8>,
|
|
||||||
name: String,
|
|
||||||
width: u32,
|
|
||||||
height: u32,
|
|
||||||
},
|
|
||||||
/// [card type=file url={BACKEND}/static/files/6602e20d7b8d10675758e36b/9df28943d17b9713cb0ea9625f37d015.wav]Engine.wav[/card]
|
/// [card type=file url={BACKEND}/static/files/6602e20d7b8d10675758e36b/9df28943d17b9713cb0ea9625f37d015.wav]Engine.wav[/card]
|
||||||
File { file: Vec<u8>, name: String },
|
File { file: Vec<u8>, name: String },
|
||||||
}
|
}
|
||||||
|
|
|
@ -3,7 +3,7 @@ use pyo3::prelude::*;
|
||||||
use rust_socketio::asynchronous::Client;
|
use rust_socketio::asynchronous::Client;
|
||||||
use tracing::{debug, info, warn};
|
use tracing::{debug, info, warn};
|
||||||
|
|
||||||
use crate::data_struct::tailchat::messages::{ReceiveMessage, SendingMessage};
|
use crate::data_struct::tailchat::messages::{ReceiveMessage, SendingFile, SendingMessage};
|
||||||
use crate::data_struct::tailchat::{ConverseId, GroupId, MessageId, UserId};
|
use crate::data_struct::tailchat::{ConverseId, GroupId, MessageId, UserId};
|
||||||
use crate::tailchat::client::send_message;
|
use crate::tailchat::client::send_message;
|
||||||
|
|
||||||
|
@ -124,7 +124,11 @@ impl TailchatSendingMessagePy {
|
||||||
self.message.content = content;
|
self.message.content = content;
|
||||||
self.clone()
|
self.clone()
|
||||||
}
|
}
|
||||||
// pub fn set_img(&mut self, file: Vec<u8>, file_type: String) {
|
pub fn set_img(&mut self, file: Vec<u8>, file_name: String) {
|
||||||
// self.message.add_img(file, file_type, as_sticker);
|
let file = SendingFile::Image {
|
||||||
// }
|
file,
|
||||||
|
name: file_name,
|
||||||
|
};
|
||||||
|
self.message.add_img(file);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue
Block a user