diff --git a/Dialogs/Settings/TabSettingsSounds.cs b/Dialogs/Settings/TabSettingsSounds.cs index a12ee40f..6227bf24 100644 --- a/Dialogs/Settings/TabSettingsSounds.cs +++ b/Dialogs/Settings/TabSettingsSounds.cs @@ -72,6 +72,14 @@ private void btnBrowseSound_Click(object sender, EventArgs e){ }; if (dialog.ShowDialog() == DialogResult.OK){ + try{ + if (new FileInfo(dialog.FileName).Length > (1024 * 1024) && !FormMessage.Warning("Sound Notification", "The sound file is larger than 1 MB, this will cause increased memory usage. Use this file anyway?", FormMessage.Yes, FormMessage.No)){ + return; + } + }catch{ + // ignore + } + tbCustomSound.Text = dialog.FileName; } }