Fix #177
This commit is contained in:
Generated
+1
@@ -49,6 +49,7 @@ Partial Class frmChooseGame
|
||||
'lstGameBox
|
||||
'
|
||||
Me.lstGameBox.FormattingEnabled = True
|
||||
Me.lstGameBox.HorizontalScrollbar = True
|
||||
Me.lstGameBox.Location = New System.Drawing.Point(15, 34)
|
||||
Me.lstGameBox.Name = "lstGameBox"
|
||||
Me.lstGameBox.Size = New System.Drawing.Size(228, 95)
|
||||
|
||||
@@ -26,11 +26,19 @@ Public Class frmChooseGame
|
||||
End Property
|
||||
|
||||
Private Sub FillComboBox()
|
||||
Dim sTags As String
|
||||
Dim sName As String
|
||||
lstGameBox.ValueMember = "Key"
|
||||
lstGameBox.DisplayMember = "Value"
|
||||
|
||||
For Each o As clsGame In Process.DuplicateList
|
||||
lstGameBox.Items.Add(New KeyValuePair(Of String, String)(o.ID, o.Name))
|
||||
sTags = mgrGameTags.PrintTagsbyID(o.ID)
|
||||
If sTags <> String.Empty Then
|
||||
sName = o.Name & " (" & sTags & ")"
|
||||
Else
|
||||
sName = o.Name
|
||||
End If
|
||||
lstGameBox.Items.Add(New KeyValuePair(Of String, String)(o.ID, sName))
|
||||
oGamesHash.Add(o.ID, o)
|
||||
Next
|
||||
|
||||
|
||||
@@ -706,13 +706,13 @@ Public Class frmGameManager
|
||||
|
||||
If eCurrentMode = eModes.Add Then
|
||||
oTagsToSave = frm.TagList
|
||||
FillTagsbyList(frm.TagList)
|
||||
lblTags.Text = mgrGameTags.PrintTagsbyList(frm.TagList)
|
||||
Else
|
||||
'Sync
|
||||
mgrMonitorList.SyncMonitorLists(Settings)
|
||||
|
||||
'Only update visible tags if one item is selected
|
||||
If lstGames.SelectedItems.Count = 1 Then FillTagsbyID(CurrentGame.ID)
|
||||
If lstGames.SelectedItems.Count = 1 Then lblTags.Text = mgrGameTags.PrintTagsbyID(CurrentGame.ID)
|
||||
|
||||
'If a tag filter is enabled, reload list to reflect changes
|
||||
If optCustom.Checked Then
|
||||
@@ -954,7 +954,7 @@ Public Class frmGameManager
|
||||
txtVersion.Text = oApp.Version
|
||||
txtIcon.Text = oApp.Icon
|
||||
|
||||
FillTagsbyID(oData.Key)
|
||||
lblTags.Text = mgrGameTags.PrintTagsbyID(oData.Key)
|
||||
|
||||
'Icon
|
||||
If IO.File.Exists(oApp.Icon) Then
|
||||
@@ -973,33 +973,6 @@ Public Class frmGameManager
|
||||
IsLoading = False
|
||||
End Sub
|
||||
|
||||
Private Sub FillTagsbyID(ByVal sID As String)
|
||||
Dim slTags As SortedList
|
||||
Dim oTag As clsTag
|
||||
Dim sTags As String = String.Empty
|
||||
Dim cTrim() As Char = {",", " "}
|
||||
|
||||
slTags = mgrGameTags.GetTagsByGame(sID)
|
||||
|
||||
For Each de As DictionaryEntry In slTags
|
||||
oTag = DirectCast(de.Value, clsTag)
|
||||
sTags &= "#" & oTag.Name & ", "
|
||||
Next
|
||||
|
||||
lblTags.Text = sTags.TrimEnd(cTrim)
|
||||
End Sub
|
||||
|
||||
Private Sub FillTagsbyList(ByVal oList As List(Of KeyValuePair(Of String, String)))
|
||||
Dim sTags As String = String.Empty
|
||||
Dim cTrim() As Char = {",", " "}
|
||||
|
||||
For Each kp As KeyValuePair(Of String, String) In oList
|
||||
sTags &= "#" & kp.Value & ", "
|
||||
Next
|
||||
|
||||
lblTags.Text = sTags.TrimEnd(cTrim)
|
||||
End Sub
|
||||
|
||||
Private Sub DirtyCheck_ValueChanged(sender As Object, e As EventArgs)
|
||||
If Not IsLoading And Not eCurrentMode = eModes.MultiSelect Then
|
||||
IsDirty = True
|
||||
|
||||
Reference in New Issue
Block a user