Beispiel #1
0
        /// <summary>
        /// 更改动态静态标签
        /// </summary>
        /// <param name="isstatic"></param>
        private void SetLabelType(bool isstatic)
        {
            List <TreeListNode> nodes = new List <TreeListNode>();

            if (treeList1.Focused)
            {
                nodes = GetcheckList(treeList1);
            }
            else
            {
                nodes = GetcheckList(treeList2);
            }
            List <int> ids = GetTypeLabels(nodes).Select(t => t.Id).ToList();

            if (!LabelData.SetLabelType(ids, isstatic))
            {
                MessageBox.Show("更改类型失败");
            }
            GetLabels(RefreshType.None);
        }