OSDN Git Service

C# 8.0 のnull許容参照型を有効化
[opentween/open-tween.git] / OpenTween / EventViewerDialog.cs
index 95c01c6..0e135d8 100644 (file)
@@ -24,6 +24,8 @@
 // the Free Software Foundation, Inc., 51 Franklin Street - Fifth Floor,
 // Boston, MA 02110-1301, USA.
 
+#nullable enable
+
 using System;
 using System.Collections.Generic;
 using System.ComponentModel;
@@ -43,14 +45,14 @@ namespace OpenTween
 {
     public partial class EventViewerDialog : OTBaseForm
     {
-        public List<Twitter.FormattedEvent> EventSource { get; set; }
+        public List<Twitter.FormattedEvent> EventSource { get; set; } = new List<Twitter.FormattedEvent>();
 
-        private Twitter.FormattedEvent[] _filterdEventSource;
+        private Twitter.FormattedEvent[] _filterdEventSource = Array.Empty<Twitter.FormattedEvent>();
 
-        private ListViewItem[] _ItemCache = null;
+        private ListViewItem[]? _ItemCache = null;
         private int _itemCacheIndex;
 
-        private TabPage _curTab = null;
+        private TabPage _curTab = null!;
 
         public EventViewerDialog()
         {