コード例 #1
0
ファイル: frmStudentMgm.cs プロジェクト: zesus19/c5.v1
 public override ListViewItem GetMenuItem(ListViewGroupCollection groups)
 {
     System.Windows.Forms.ListViewItem listViewItem3 = new System.Windows.Forms.ListViewItem("学生管理", 6);
     listViewItem3.Group = groups.Cast<ListViewGroup>()
         .Where(l => l.Name.Equals("lvgSchool")).FirstOrDefault();
     listViewItem3.ToolTipText = "学生管理";
     return listViewItem3;
 }
コード例 #2
0
ファイル: frmSchoolInfo.cs プロジェクト: zesus19/c5.v1
 public override ListViewItem GetMenuItem(ListViewGroupCollection groups)
 {
     var listViewItem1 = new System.Windows.Forms.ListViewItem("基本信息", 4);
     listViewItem1.Group = groups.Cast<ListViewGroup>()
         .Where(l => l.Name.Equals("lvgSchool")).FirstOrDefault();
     listViewItem1.ToolTipText = "基本信息";
     return listViewItem1;
 }
コード例 #3
0
ファイル: frmUserMgm.cs プロジェクト: zesus19/c5.v1
 public override ListViewItem GetMenuItem(ListViewGroupCollection groups)
 {
     System.Windows.Forms.ListViewItem listViewItem7 = new System.Windows.Forms.ListViewItem("用户管理", 1);
     listViewItem7.Group = groups.Cast<ListViewGroup>()
         .Where(l => l.Name.Equals("lvgManage")).FirstOrDefault();
     listViewItem7.ToolTipText = "用户管理";
     return listViewItem7;
 }
コード例 #4
0
        public void AddRange(ListViewGroupCollection groups)
        {
            foreach (ListViewGroup group in groups)
            {
                AddGroup(group);
            }

            if (list_view_owner != null)
            {
                list_view_owner.Redraw(true);
            }
        }
コード例 #5
0
        /// <include file='doc\ListViewGroup.uex' path='docs/doc[@for="ListViewGroup.ListViewGroupCollection.AddRange2"]/*' />
        public void AddRange(ListViewGroupCollection groups)
        {
            if (groups == null)
            {
                throw new ArgumentNullException(nameof(groups));
            }

            for (int i = 0; i < groups.Count; i++)
            {
                Add(groups[i]);
            }
        }
コード例 #6
0
		public ListView ()
		{
			background_color = Color.White;//ThemeEngine.Current.ColorWindow;
			groups = new ListViewGroupCollection (this);
			items = new ListViewItemCollection (this);
			items.Changed += new CollectionChangedHandler (OnItemsChanged);
			checked_indices = new CheckedIndexCollection (this);
			checked_items = new CheckedListViewItemCollection (this);
			columns = new ColumnHeaderCollection (this);
			foreground_color = SystemColors.WindowText;
			selected_indices = new SelectedIndexCollection (this);
			selected_items = new SelectedListViewItemCollection (this);
			items_location = new Point [16];
			items_matrix_location = new ItemMatrixLocation [16];
			reordered_items_indices = new int [16];
			item_tooltip = new ToolTip ();
			item_tooltip.Active = false;
			insertion_mark = new ListViewInsertionMark (this);

			InternalBorderStyle = BorderStyle.Fixed3D;

			header_control = new HeaderControl (this);
			header_control.Visible = false;
			Controls.AddImplicit (header_control);

			item_control = new ItemControl (this);
			Controls.AddImplicit (item_control);

			h_marker = v_marker = 0;
			keysearch_tickcnt = 0;

			// scroll bars are disabled initially
			
			h_scroll.Visible = false;
			//h_scroll.ValueChanged += new EventHandler(HorizontalScroller);
			v_scroll.Visible = false;
			//v_scroll.ValueChanged += new EventHandler(VerticalScroller);

			// event handlers
			base.KeyDown += new KeyEventHandler(ListView_KeyDown);
			SizeChanged += new EventHandler (ListView_SizeChanged);
			//GotFocus += new EventHandler (FocusChanged);
			//LostFocus += new EventHandler (FocusChanged);
			//MouseWheel += new MouseEventHandler(ListView_MouseWheel);
			//MouseEnter += new EventHandler (ListView_MouseEnter);
			Invalidated += new InvalidateEventHandler (ListView_Invalidated);

			BackgroundImageTiled = false;

			this.SetStyle (ControlStyles.UserPaint | ControlStyles.StandardClick
				| ControlStyles.UseTextForAccessibility
				, false);
		}
 private string CreateListViewGroupName(ListViewGroupCollection lvgCollection)
 {
     string str = "ListViewGroup";
     INameCreationService service = base.GetService(typeof(INameCreationService)) as INameCreationService;
     IContainer container = base.GetService(typeof(IContainer)) as IContainer;
     if ((service != null) && (container != null))
     {
         str = service.CreateName(container, typeof(ListViewGroup));
     }
     while (char.IsDigit(str[str.Length - 1]))
     {
         str = str.Substring(0, str.Length - 1);
     }
     int num = 1;
     string str2 = str + num.ToString(CultureInfo.CurrentCulture);
     while (lvgCollection[str2] != null)
     {
         num++;
         str2 = str + num.ToString(CultureInfo.CurrentCulture);
     }
     return str2;
 }
コード例 #8
0
		public void AddRange(ListViewGroupCollection groups)
		{
			foreach (ListViewGroup group in groups)
				AddGroup (group);

			if (list_view_owner != null)
				list_view_owner.Redraw (true);
		}
コード例 #9
0
 protected List<Preset> GatherPresets(ListViewGroupCollection items)
 {
     var scripts = from item in listViewChain.Items.Cast<ListViewItem>()
                   select (Preset)item.Tag;
     return scripts.ToList();
 }
コード例 #10
0
		protected override void SetUp () {
			lv = new ListView ();
			grpCol = lv.Groups;
			base.SetUp ();
		}
コード例 #11
0
 public EditPropertyForm(string name, string value, string type, string group, ListViewGroupCollection groups)
 {
     InitializeComponent();
     Text = $"Edit \"{name}\" Property";
 }
コード例 #12
0
ファイル: ListViewGroup.cs プロジェクト: JianwenSun/cc
 /// <include file='doc\ListViewGroup.uex' path='docs/doc[@for="ListViewGroup.ListViewGroupCollection.AddRange2"]/*' />
 /// <devdoc>
 ///     To be supplied.
 /// </devdoc>
 public void AddRange(ListViewGroupCollection groups)
 {
     for(int i=0; i < groups.Count; i++) {
         Add(groups[i]);
     }
 }
コード例 #13
0
 public virtual ListViewItem GetMenuItem(ListViewGroupCollection groups) { throw new NotImplementedException(); }
コード例 #14
0
 public void AddRange(ListViewGroupCollection groups)
 {
     throw null;
 }