public FolderEditor(string folder) : base() { _folderListItem = new FolderListItem(folder, FolderListItem.AllowSearch.None, true); _folderListItem.PathChanged += folderListItem_PathChanged; _folderListItem.Parent = this; }
//TODO: Seems to fail on the build machine - commented out temporarily //[Test, TestCaseSource("PathNameTestData")] public void CalculatePreferedSizes(TestData tc) { FolderListItem item = new FolderListItem(tc.Path, FolderListItem.AllowSearch.None, false){MaxWidth = 50}; Control parent = new Control {Font = new Font(FontFamily.GenericMonospace, 10)}; item.Parent = parent; Assert.That(item.PreferredSize.Width, Is.EqualTo(tc.ExpectedWidth), "Width"); Assert.That(item.Path, Is.EqualTo(tc.Path), "Path"); parent.Dispose(); }
public void AddEntry(string Key, FolderListItem Value, IEnumerable <ToolStripMenuItem> contextMenuItems) { // Special case for folders: CA-33311 if (!String.IsNullOrEmpty(Key)) { Key += Messages.GENERAL_PAGE_KVP_SEPARATOR; } DataGridViewExRow r = new DataGridViewExRow(); r.Cells.Add(new DataGridViewTextBoxCell()); r.Cells[0].Value = Key; r.Cells.Add(new FolderCell(Value)); r.Tag = contextMenuItems; AddRow(r); }
public void AddEntry(string Key, FolderListItem Value, IEnumerable<ToolStripMenuItem> contextMenuItems) { // Special case for folders: CA-33311 if (!String.IsNullOrEmpty(Key)) Key += Messages.GENERAL_PAGE_KVP_SEPARATOR; DataGridViewExRow r = new DataGridViewExRow(); r.Cells.Add(new DataGridViewTextBoxCell()); r.Cells[0].Value = Key; r.Cells.Add(new FolderCell(Value)); r.Tag = contextMenuItems; AddRow(r); }