Closed nullgato closed 1 week ago
this pr seems to leak memory :(
Tragic :( This seems to be caused by MediaElement which is used to play multiple forms of media, but I was specifically using it for video embeds since Tenor gifs are sent as videos for some reason.
I was also having a hell of a time with this for other video attachments. Sadly video is going to be incredibly hard from what I've seen because there aren't many options for video and the ones I've found all have paths leading to memory leakage and have to be used very carefully.
Anyway, I think this PR is updated? Sorry for not being good with how PRs work. I removed the MediaElement causing the issue, but normal user-sent gifs should still work great.
Closed because I've gotten out of sync with latest, will remake
This PR adds .gif support for the chat windows as well as image previewer with the use of the XamlAnimatedGif library.
It also changes some code regarding variables for attachments where previously we check if something is a gif or otherwise, but in having support for other media I've replaced this with a new enum type called
MediaType
onAttachmentViewModel
andImagePreviewerViewModel
that sets the type based on a file's mime with the use of the MimeTypeMap library. It also usesMediaType
for bindings inChat.xaml
.