Skip to content

Commit

Permalink
fix
Browse files Browse the repository at this point in the history
  • Loading branch information
marci1175 committed Aug 3, 2024
1 parent 0e538d8 commit 0f95d59
Show file tree
Hide file tree
Showing 17 changed files with 58 additions and 18 deletions.
5 changes: 4 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
@@ -1,4 +1,7 @@
/target
/dist
/vendor
build_info.szechat_build
/Installer/MatthiasSetup/Debug
/Installer/MatthiasSetup/Release
/Installer/.vs/
build_info.szechat_build
Binary file modified Installer/.vs/Matthias/v17/.suo
Binary file not shown.
Binary file not shown.
Binary file not shown.
12 changes: 12 additions & 0 deletions Installer/MatthiasSetup/.vs/MatthiasSetup/v17/DocumentLayout.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
{
"Version": 1,
"WorkspaceRootPath": "C:\\Users\\marci\\Desktop\\szeChat\\Installer\\MatthiasSetup\\",
"Documents": [],
"DocumentGroupContainers": [
{
"Orientation": 0,
"VerticalTabListWidth": 256,
"DocumentGroups": []
}
]
}
3 changes: 3 additions & 0 deletions Installer/MatthiasSetup/.vs/ProjectSettings.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
{
"CurrentProjectSetting": null
}
7 changes: 7 additions & 0 deletions Installer/MatthiasSetup/.vs/VSWorkspaceState.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
{
"ExpandedNodes": [
"\\Debug",
"\\Release"
],
"PreviewInSolutionExplorer": false
}
Binary file added Installer/MatthiasSetup/.vs/slnx.sqlite
Binary file not shown.
16 changes: 16 additions & 0 deletions Installer/MatthiasSetup/MatthiasSetup.vdproj
Original file line number Diff line number Diff line change
Expand Up @@ -141,6 +141,22 @@
}
}
}
"tst"
{
"DisplayName" = "8:tst"
"IsDebugOnly" = "11:FALSE"
"IsReleaseOnly" = "11:FALSE"
"OutputFilename" = "8:tst\\MatthiasSetup.msi"
"PackageFilesAs" = "3:2"
"PackageFileSize" = "3:-2147483648"
"CabType" = "3:1"
"Compression" = "3:2"
"SignOutput" = "11:FALSE"
"CertificateFile" = "8:"
"PrivateKeyFile" = "8:"
"TimeStampServer" = "8:"
"InstallerBootstrapper" = "3:2"
}
}
"Deployable"
{
Expand Down
Binary file modified Installer/MatthiasSetup/Release/MatthiasSetup.msi
Binary file not shown.
Binary file modified Installer/MatthiasSetup/Release/setup.exe
Binary file not shown.
2 changes: 1 addition & 1 deletion build_info.matthias_build
Original file line number Diff line number Diff line change
@@ -1 +1 @@
2024.08.03. 21:36
2024.08.03. 21:50
5 changes: 4 additions & 1 deletion src/app.rs
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,7 @@ impl eframe::App for backend::Application {
TODO: Restructure files
TODO: make custom urls open up the chat app and automaticly connect
TODO: Reowrk logging (We already have tracing for that, replace dbg!s)
TODO: Reowrk logging (We already have tracing for that, replace dbg!)
*/

//Check for startup args
Expand All @@ -118,6 +118,9 @@ impl eframe::App for backend::Application {
//Show settings window to alert user
self.settings_window = true;
}

//Reset startup args
self.startup_args = None;
}

//Display notifications
Expand Down
8 changes: 4 additions & 4 deletions src/app/lua.rs
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ use std::{

use egui::{Rect, Vec2};
use mlua::{Lua, Value::Nil};
use strum::{Display, ToString};
use strum::Display;

/// This function executes code provided, and if its a function adds it to the global register
pub fn execute_code(lua: &Lua, code: String) -> anyhow::Result<()> {
Expand Down Expand Up @@ -158,13 +158,13 @@ pub enum EventCall {

impl Extension {
pub fn event_call_extensions(&mut self, event: EventCall, lua: &Lua, arg: Option<String>) {
for mut ext in self.extension_list.iter_mut() {
for ext in self.extension_list.iter_mut() {
//If the extension should be running we skip that entry
if !ext.is_running {
continue;
}

match Self::load_and_call_function(lua, ext, &arg, String::from(event.to_string())) {
match Self::load_and_call_function(lua, ext, &arg, event.to_string()) {
Ok(_) => (),
Err(err) => {
//If the lua returned this error it means the callback couldnt be called
Expand All @@ -174,7 +174,7 @@ impl Extension {
return;
}

Self::add_msg_to_log(self.output.clone(), &mut ext, err.to_string());
Self::add_msg_to_log(self.output.clone(), ext, err.to_string());
}
};
}
Expand Down
3 changes: 1 addition & 2 deletions src/app/server.rs
Original file line number Diff line number Diff line change
Expand Up @@ -30,8 +30,7 @@ use crate::app::backend::{
ClientMessageType::{
FileRequestType, FileUpload, MessageEdit, NormalMessage, Reaction as ClientReaction,
SyncMessage, VoipConnection,
},
ClientReaction as ClientReactionStruct, ServerFileReply, ServerImageReply,
}, ServerFileReply, ServerImageReply,
};
use tokio::{
io::AsyncWrite,
Expand Down
14 changes: 6 additions & 8 deletions src/app/ui/client.rs
Original file line number Diff line number Diff line change
Expand Up @@ -836,7 +836,7 @@ impl Application {
.client_ui
.incoming_messages
.reaction_list
[reaction.message_index as usize]
[reaction.message_index]
.message_reactions
.iter()
.position(|item| {
Expand All @@ -848,16 +848,15 @@ impl Application {
self.client_ui
.incoming_messages
.reaction_list
[reaction.message_index
as usize]
[reaction.message_index]
.message_reactions[index]
.times += 1;
} else {
//If no, add a new reaction counter
self.client_ui
.incoming_messages
.reaction_list
[reaction.message_index as usize]
[reaction.message_index]
.message_reactions
.push(Reaction {
emoji_name: reaction
Expand All @@ -876,7 +875,7 @@ impl Application {
.client_ui
.incoming_messages
.reaction_list
[reaction.message_index as usize]
[reaction.message_index]
.message_reactions
.iter()
.position(|item| {
Expand All @@ -889,7 +888,7 @@ impl Application {
.client_ui
.incoming_messages
.reaction_list
[reaction.message_index as usize]
[reaction.message_index]
.message_reactions[index]
.times;

Expand All @@ -901,8 +900,7 @@ impl Application {
self.client_ui
.incoming_messages
.reaction_list
[reaction.message_index
as usize]
[reaction.message_index]
.message_reactions
.remove(index);
}
Expand Down
1 change: 0 additions & 1 deletion src/app/ui/client_ui/client_actions/audio_recording.rs
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,6 @@ use std::sync::mpsc::{self, Receiver};
use std::sync::{Arc, Mutex};
use std::thread::JoinHandle;
use std::time::Duration;
use tokio_util::sync::CancellationToken;

use crate::app::ui::client::VOIP_PACKET_BUFFER_LENGHT_MS;

Expand Down

0 comments on commit 0f95d59

Please sign in to comment.