示例#1
0
        public QuickSearchProvider(RevisionDataGridView gridView, Func <string> getWorkingDir)
        {
            _gridView = gridView;

            _gitRevisionTester = new GitRevisionTester(new FullPathResolver(getWorkingDir));

            _label = new Label
            {
                Location    = new Point(0, 0),
                Padding     = new Padding(7, 5, 5, 5),
                BorderStyle = BorderStyle.None,
                ForeColor   = SystemColors.InfoText,
                BackColor   = SystemColors.Info,
                Font        = new Font(FontFamily.GenericSansSerif, 11, FontStyle.Bold),
                Visible     = false,
                UseMnemonic = false
            };

            _quickSearchTimer = new Timer {
                Interval = AppSettings.RevisionGridQuickSearchTimeout
            };
            _quickSearchTimer.Tick += (sender, e) =>
            {
                _quickSearchTimer.Stop();
                _quickSearchString = "";
                HideQuickSearchString();
            };

            _gridView.Controls.Add(_label);
        }
示例#2
0
        public BuildServerWatcher(RevisionGridControl revisionGrid, RevisionDataGridView revisionGridView, Func <GitModule> module)
        {
            _revisionGrid     = revisionGrid;
            _revisionGridView = revisionGridView;
            _module           = module;

            _repoNameExtractor = new RepoNameExtractor(_module);
            ColumnProvider     = new BuildStatusColumnProvider(revisionGrid, revisionGridView, _module);
        }
示例#3
0
        public BuildStatusColumnProvider(RevisionGridControl grid, RevisionDataGridView gridView, Func <GitModule> module)
            : base("Build Status")
        {
            _grid     = grid;
            _gridView = gridView;
            _module   = module;

            Column = new DataGridViewTextBoxColumn
            {
                HeaderText = "Build Status",
                ReadOnly   = true,
                SortMode   = DataGridViewColumnSortMode.NotSortable,
                Width      = DpiUtil.Scale(TextColumnWidth)
            };
        }
示例#4
0
        public AvatarColumnProvider(RevisionDataGridView revisionGridView, IAvatarProvider avatarProvider)
            : base("Avatar")
        {
            _revisionGridView = revisionGridView;
            _avatarProvider   = avatarProvider;

            _avatarProvider.CacheCleared += _revisionGridView.Invalidate;

            Column = new DataGridViewTextBoxColumn
            {
                AutoSizeMode = DataGridViewAutoSizeColumnMode.None,
                HeaderText   = "Avatar",
                ReadOnly     = true,
                SortMode     = DataGridViewColumnSortMode.NotSortable,
                Resizable    = DataGridViewTriState.False,
                Width        = DpiUtil.Scale(32)
            };
        }
        public AvatarColumnProvider(RevisionDataGridView revisionGridView, IAvatarProvider avatarProvider, IAvatarCacheCleaner avatarCacheCleaner)
            : base("Avatar")
        {
            _revisionGridView   = revisionGridView;
            _avatarProvider     = avatarProvider;
            _avatarCacheCleaner = avatarCacheCleaner;

            _avatarCacheCleaner.CacheCleared += (sender, args) => _revisionGridView.Invalidate();

            Column = new DataGridViewTextBoxColumn
            {
                AutoSizeMode = DataGridViewAutoSizeColumnMode.None,
                HeaderText   = "Avatar",
                ReadOnly     = true,
                SortMode     = DataGridViewColumnSortMode.NotSortable,
                Resizable    = DataGridViewTriState.False,
                Width        = DpiUtil.Scale(32),
                Visible      = AppSettings.ShowAuthorAvatarColumn
            };
        }
 public RevisionGridToolTipProvider(RevisionDataGridView gridView)
 {
     _gridView = gridView;
 }