Chat Settings eingefügt (Visuell)

This commit is contained in:
Exudonze 2024-08-29 18:41:36 +02:00
parent 8b71f84284
commit fd2ebc5aaa
2 changed files with 36 additions and 0 deletions

View File

@ -90,6 +90,15 @@
<Image Source="/UI/logo - Copy.png" Stretch="Fill" Margin="-55,-118,499,0">
</Image>
<Button x:Name="ChatSettings" Content="⚙️" Click="MenuButton_Click" HorizontalAlignment="Left" Margin="634,2,0,0" VerticalAlignment="Top" Height="37" Width="26" Background="Transparent" BorderBrush="Transparent">
<Button.ContextMenu>
<ContextMenu x:Name="contextMenu" IsOpen="False">
<MenuItem x:Name="blockButton" Header="Blockieren" Click="BlockButton_Click"/>
<MenuItem x:Name="deleteChatButton" Header="Chat löschen" Click="DeleteChatButton_Click"/>
<MenuItem x:Name="removeFriendButton" Header="Freund entfernen" Click="RemoveFriendButton_Click"/>
</ContextMenu>
</Button.ContextMenu>
</Button>
</Grid>
<Grid Margin="76,17,339,176">

View File

@ -4,6 +4,7 @@ using System.Windows;
using System.Windows.Input;
using System.Windows.Threading;
using bib_talk.Business;
using System.Windows.Controls;
namespace bib_talk
{
@ -87,5 +88,31 @@ namespace bib_talk
await mwManager.UploadProfileImage(filePath);
}
}
// Chat Settings Logik
private void MenuButton_Click(object sender, RoutedEventArgs e)
{
// Öffnen Sie das Kontextmenü, wenn Sie auf den Drei-Punkte-Button klicken
contextMenu.IsOpen = true;
}
private void BlockButton_Click(object sender, RoutedEventArgs e)
{
// Logik zum Blockieren eines Benutzers
}
private void DeleteChatButton_Click(object sender, RoutedEventArgs e)
{
// Logik zum Löschen eines Chats
}
private void RemoveFriendButton_Click(object sender, RoutedEventArgs e)
{
// Logik zum Entfernen eines Freundes
}
private void SendButton_Click(object sender, RoutedEventArgs e)
{
// Logik zum Senden einer Nachricht
}
}
}