public IssueBrowserWindow(IssueMonitor IssueMonitor, string ServerAndPort, string UserName, TimeSpan?ServerTimeOffset, TextWriter Log, string CurrentStream, Dictionary <string, Func <IssueData, bool> > CustomFilters, string FilterName)
        {
            this.IssueMonitor     = IssueMonitor;
            this.ServerAndPort    = ServerAndPort;
            this.UserName         = UserName;
            this.ServerTimeOffset = ServerTimeOffset;
            this.Log           = Log;
            this.CurrentStream = CurrentStream;
            this.FilterName    = FilterName;
            this.CustomFilters = CustomFilters;
            this.MainThreadSynchronizationContext = SynchronizationContext.Current;

            IssueMonitor.AddRef();

            InitializeComponent();

            using (Graphics Graphics = Graphics.FromHwnd(IntPtr.Zero))
            {
                float DpiScaleX = Graphics.DpiX / 96.0f;
                foreach (ColumnHeader Column in IssueListView.Columns)
                {
                    Column.Width = (int)(Column.Width * DpiScaleX);
                }
            }

            System.Reflection.PropertyInfo DoubleBufferedProperty = typeof(Control).GetProperty("DoubleBuffered", System.Reflection.BindingFlags.NonPublic | System.Reflection.BindingFlags.Instance);
            DoubleBufferedProperty.SetValue(IssueListView, true, null);
        }
Пример #2
0
        public IssueBrowserWindow(IssueMonitor IssueMonitor, string ServerAndPort, string UserName, TimeSpan?ServerTimeOffset, TextWriter Log, string CurrentStream)
        {
            this.IssueMonitor     = IssueMonitor;
            this.ServerAndPort    = ServerAndPort;
            this.UserName         = UserName;
            this.ServerTimeOffset = ServerTimeOffset;
            this.Log           = Log;
            this.CurrentStream = CurrentStream;

            IssueMonitor.AddRef();

            InitializeComponent();

            System.Reflection.PropertyInfo DoubleBufferedProperty = typeof(Control).GetProperty("DoubleBuffered", System.Reflection.BindingFlags.NonPublic | System.Reflection.BindingFlags.Instance);
            DoubleBufferedProperty.SetValue(IssueListView, true, null);
        }