Skip to content

Commit 731f438

Browse files
committed
Improve DeleteFileForm UX and update version numbers
Refactored DeleteFileForm.Display to use a standard message box when CanFill is False, simplifying the user experience for simple confirmations. Updated LblCaption margin for better layout. Bumped application revision and file version numbers.
1 parent caaa94c commit 731f438

File tree

4 files changed

+18
-6
lines changed

4 files changed

+18
-6
lines changed

DiskImageTool/DiskImageTool.vbproj

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@
3030
<TargetCulture>en-US</TargetCulture>
3131
<ProductName>DiskImageTool</ProductName>
3232
<PublisherName>Digitoxin</PublisherName>
33-
<ApplicationRevision>1</ApplicationRevision>
33+
<ApplicationRevision>2</ApplicationRevision>
3434
<ApplicationVersion>2.34.0.%2a</ApplicationVersion>
3535
<UseApplicationTrust>false</UseApplicationTrust>
3636
<PublishWizardCompleted>true</PublishWizardCompleted>

DiskImageTool/Forms/DeleteFileform.Designer.vb

Lines changed: 1 addition & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

DiskImageTool/Forms/DeleteFileform.vb

Lines changed: 15 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -37,10 +37,21 @@
3737
End Property
3838

3939
Public Shared Function Display(Caption As String, Title As String, CanFill As Boolean) As DeleteFileFormResult
40-
Using Form As New DeleteFileForm(Caption, Title, CanFill)
41-
Form.ShowDialog()
42-
Return Form.Result
43-
End Using
40+
If CanFill Then
41+
Using Form As New DeleteFileForm(Caption, Title, CanFill)
42+
Form.ShowDialog()
43+
Return Form.Result
44+
End Using
45+
Else
46+
Dim MsgBoxResult = MsgBox(Caption, MsgBoxStyle.YesNo Or MsgBoxStyle.Question Or MsgBoxStyle.DefaultButton2, Title)
47+
Dim Result As New DeleteFileFormResult With {
48+
.Clear = False,
49+
.FillChar = &H0,
50+
.Cancelled = (MsgBoxResult = MsgBoxResult.No)
51+
}
52+
53+
Return Result
54+
End If
4455
End Function
4556

4657
Private Sub SetResult(Cancelled As Boolean)

DiskImageTool/My Project/AssemblyInfo.vb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,4 +31,4 @@ Imports System.Runtime.InteropServices
3131
' <Assembly: AssemblyVersion("1.0.*")>
3232

3333
<Assembly: AssemblyVersion("1.0.0.0")>
34-
<Assembly: AssemblyFileVersion("2.34.0.1")>
34+
<Assembly: AssemblyFileVersion("2.34.0.2")>

0 commit comments

Comments
 (0)