toIdx = 0
stp = -1
End If
+
+ Dim posts As Dictionary(Of Long, PostClass)
If Not Tab.IsInnerStorageTabType Then
- For i As Integer = StartIdx To toIdx Step stp
- If Not _statuses(Tab.GetId(i)).IsRead Then
- Tab.OldestUnreadId = Tab.GetId(i)
- Exit For
- End If
- Next
+ posts = _statuses
Else
- For i As Integer = StartIdx To toIdx Step stp
- If Not Tab.Posts(Tab.GetId(i)).IsRead Then
- Tab.OldestUnreadId = Tab.GetId(i)
- Exit For
- End If
- Next
+ posts = Tab.Posts
End If
+
+ For i As Integer = StartIdx To toIdx Step stp
+ Dim id As Long = Tab.GetId(i)
+ If id > -1 AndAlso Not posts(id).IsRead Then
+ Tab.OldestUnreadId = id
+ Exit For
+ End If
+ Next
End Sub
Public Function DistributePosts() As Integer
End Sub
Private Sub PostBrowser_StatusTextChanged(ByVal sender As Object, ByVal e As EventArgs) Handles PostBrowser.StatusTextChanged
- If PostBrowser.StatusText.StartsWith("http") OrElse PostBrowser.StatusText.StartsWith("ftp") _
- OrElse PostBrowser.StatusText.StartsWith("data") Then
- StatusLabelUrl.Text = PostBrowser.StatusText.Replace("&", "&&")
- End If
- If PostBrowser.StatusText = "" Then
- SetStatusLabelUrl()
- End If
+ Try
+ If PostBrowser.StatusText.StartsWith("http") OrElse PostBrowser.StatusText.StartsWith("ftp") _
+ OrElse PostBrowser.StatusText.StartsWith("data") Then
+ StatusLabelUrl.Text = PostBrowser.StatusText.Replace("&", "&&")
+ End If
+ If PostBrowser.StatusText = "" Then
+ SetStatusLabelUrl()
+ End If
+ Catch ex As Exception
+ End Try
End Sub
Private Sub StatusText_KeyPress(ByVal sender As Object, ByVal e As System.Windows.Forms.KeyPressEventArgs) Handles StatusText.KeyPress
End If
Catch ex As System.Runtime.InteropServices.COMException
'原因不明
+ Catch ex As UriFormatException
+ PostBrowser.DocumentText = dTxt
Finally
PostBrowser.Visible = True
End Try