1
0
Fork 0
mirror of https://github.com/beefytech/Beef.git synced 2025-06-10 12:32:20 +02:00

Show error for editing binary file

This commit is contained in:
Brian Fiete 2020-10-01 14:43:36 -07:00
parent f6c42b561a
commit a355f32c1e

View file

@ -525,7 +525,9 @@ namespace IDE.ui
}
if (mSourceViewPanel != null)
{
if ((!sReadOnlyErrorShown) && (mSourceViewPanel.[Friend]mCurrentVersionPanel != null))
if (mSourceViewPanel.mIsBinary)
IDEApp.sApp.Fail("Cannot edit binary file.");
else if ((!sReadOnlyErrorShown) && (mSourceViewPanel.[Friend]mCurrentVersionPanel != null))
IDEApp.sApp.Fail("Switch to the current version of this file to edit it.");
else
IDEApp.Beep(IDEApp.MessageBeepType.Error);