当前位置: 首页>>代码示例>>C#>>正文


C# BrightIdeasSoftware.ObjectListView类代码示例

本文整理汇总了C#中BrightIdeasSoftware.ObjectListView的典型用法代码示例。如果您正苦于以下问题:C# ObjectListView类的具体用法?C# ObjectListView怎么用?C# ObjectListView使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。


ObjectListView类属于BrightIdeasSoftware命名空间,在下文中一共展示了ObjectListView类的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。

示例1: OLVDataObject

 /// <summary>
 /// Create a data object which operates on the given model objects
 /// in the given ObjectListView
 /// </summary>
 /// <param name="olv">The source of the data object</param>
 /// <param name="modelObjects">The model objects to be put into the data object</param>
 public OLVDataObject(ObjectListView olv, IList modelObjects) {
     this.objectListView = olv;
     this.modelObjects = modelObjects;
     this.includeHiddenColumns = olv.IncludeHiddenColumnsInDataTransfer;
     this.includeColumnHeaders = olv.IncludeColumnHeadersInCopy;
     this.CreateTextFormats();
 }
开发者ID:Warpten,项目名称:ADBC2,代码行数:13,代码来源:OLVDataObject.cs

示例2: AddListColumn

 /// <summary>
 /// Helper method for GenerateListColumns()
 /// </summary>
 /// <param name="objectListView"></param>
 /// <param name="data"></param>
 public static void AddListColumn(ObjectListView objectListView, string name, string aspect)
 {
     OLVColumn columnHeader = new OLVColumn();
     columnHeader.Text = name;
     columnHeader.AspectName = aspect;
     objectListView.Columns.Add(columnHeader);
 }
开发者ID:woanware,项目名称:snorbert,代码行数:12,代码来源:Helper.cs

示例3: OLVExporter

        /// <summary>
        /// Create an exporter that will export all the given rows from the given ObjectListView
        /// </summary>
        /// <param name="olv"></param>
        /// <param name="objectsToExport"></param>
        public OLVExporter(ObjectListView olv, IEnumerable objectsToExport) {
            if (olv == null) throw new ArgumentNullException("olv");
            if (objectsToExport == null) throw new ArgumentNullException("objectsToExport");

            this.ListView = olv;
            this.ModelObjects = ObjectListView.EnumerableToArray(objectsToExport, true);
        }
开发者ID:Warpten,项目名称:ADBC2,代码行数:12,代码来源:OLVExporter.cs

示例4: DataSourceAdapter

        /// <summary>
        /// Make a DataSourceAdapter
        /// </summary>
        public DataSourceAdapter(ObjectListView olv)
        {
            Debug.Assert(olv != null);

            ListView = olv;
            BindListView(ListView);
        }
开发者ID:rxantos,项目名称:tesv-snip,代码行数:10,代码来源:DataSourceAdapter.cs

示例5: AddColumnForOlv

 public static void AddColumnForOlv(Type type, ObjectListView olv)
 {
     olv.Columns.Clear();
     olv.AllColumns.Clear();
     var lColumn = ReflectionUtils.PropertysFromType(type);
     var i = 0;
     foreach (var colN in lColumn)
     {
         var col = new OLVColumn();
         col.AspectName = colN.Name;
         col.DisplayIndex = i++;
         col.Text = colN.Name;
         col.IsEditable = true;
         if (colN.PropertyType.FullName == "System.Boolean")
         {
             col.CheckBoxes = true;
         }
         if (colN.PropertyType.FullName == "System.Single")
         {
             var colName = colN.Name;
             col.AspectPutter = delegate(Object row, Object newvalue)
             {
                 ReflectionUtils.SetPropertyInternal(row, colName, float.Parse(newvalue.ToString()));
             };
         }
         olv.AllColumns.Add(col);
         olv.Columns.Add(col);
     }
 }
开发者ID:windwp,项目名称:mytool,代码行数:29,代码来源:ObjectListViewHelper.cs

示例6: InitList

        /// <summary>
        /// 2.4.初始化List显示
        /// </summary>
        private void InitList()
        {
            this._RecordListView = new FastObjectListView();
            this._RecordListView.VirtualMode = true;
            this._RecordListView.Cursor = System.Windows.Forms.Cursors.Default;
            this._RecordListView.Dock = System.Windows.Forms.DockStyle.Fill;
            this._RecordListView.GridLines = true;
            this._RecordListView.FullRowSelect = true;
            this._RecordListView.HeaderUsesThemes = false;
            this._RecordListView.HeaderWordWrap = true;
            this._RecordListView.HideSelection = false;
            this._RecordListView.Location = new System.Drawing.Point(0, 110);
            this._RecordListView.Name = "PInfoListView";
            this._RecordListView.ShowGroups = false;
            this._RecordListView.UseCompatibleStateImageBehavior = false;
            this._RecordListView.UseHotItem = true;
            this._RecordListView.View = System.Windows.Forms.View.Details;
            this._RecordListView.OwnerDraw = true;
            this._RecordListView.MultiSelect = false;

            List<ListColumnInfo> ColumnArray = new List<ListColumnInfo>();
            ColumnArray.Add(new ListColumnInfo("NO", "OrderNumber", 80, HorizontalAlignment.Left, true));
            ColumnArray.Add(new ListColumnInfo("文件名称", "BackDataFileName",200, HorizontalAlignment.Left, true));
            ColumnArray.Add(new ListColumnInfo("备份时间", "DataBackTime", 120, HorizontalAlignment.Left, true));

            this.InitializedListColumn(ColumnArray);//初始化栏位信息
            groupBox2.Controls.Add(this._RecordListView);
            this._RecordListView.ContextMenuStrip = this.contextMenuStrip1;
        }
开发者ID:qq5013,项目名称:StockControl_KPS,代码行数:32,代码来源:DataBackRevFrm.cs

示例7: DataSourceAdapter

        /// <summary>
        /// Make a DataSourceAdapter
        /// </summary>
        public DataSourceAdapter(ObjectListView olv)
        {
            if (olv == null) throw new ArgumentNullException("olv");

            this.ListView = olv;
            this.BindListView(this.ListView);
        }
开发者ID:FOSBOS,项目名称:diNo,代码行数:10,代码来源:DataSourceAdapter.cs

示例8: DataSourceAdapter

        /// <summary>
        /// Make a DataSourceAdapter
        /// </summary>
        public DataSourceAdapter(ObjectListView olv) {
            if (olv == null) throw new ArgumentNullException("olv");

            this.ListView = olv;
            // ReSharper disable once DoNotCallOverridableMethodsInConstructor
            this.BindListView(this.ListView);
        }
开发者ID:ToughBill,项目名称:NanCrm,代码行数:10,代码来源:DataSourceAdapter.cs

示例9: updateStatusLine

        public void updateStatusLine(ObjectListView olv)
        {
            IList objects = olv.Objects as IList;
            int rows = theQueue.dt.Rows.Count;

            this.label1.Text = String.Format("{0} patients", olv.Items.Count);
        }
开发者ID:mahitosh,项目名称:HRA4,代码行数:7,代码来源:HighRiskFollowupView.cs

示例10: AddColumnsToListVIew

 /// <summary>
 /// 1.3. 向ListView 中添加栏位
 /// </summary>
 /// <param name="_ColumnList"></param>
 private void AddColumnsToListVIew(ObjectListView _Listview, List<OLVColumn> _ColumnList)
 {
     if (_ColumnList != null && _ColumnList.Count > 0)
     {
         foreach (OLVColumn _Column in _ColumnList)
         {
             _Listview.Columns.Add(_Column);
         }
     }
 }
开发者ID:qq5013,项目名称:StockControl_KPS,代码行数:14,代码来源:InitListViewColumnManager.cs

示例11: GetHeaders

 private static string GetHeaders(ObjectListView listView, string[] values)
 {
     var columns = listView.ColumnsInDisplayOrder;
     int nbCol = columns.Count;
     for (int i = 0; i < nbCol; i++)
     {
         var col = columns[i];
         values[i] = col.Text;
     }
     return string.Join("\t", values);
 }
开发者ID:fremag,项目名称:MemoScope.Net,代码行数:11,代码来源:ListViewHelpers.cs

示例12: ChangeEditable

 private void ChangeEditable(ObjectListView objectListView, ComboBox comboBox)
 {
     if (comboBox.Text == "No")
         objectListView.CellEditActivation = ObjectListView.CellEditActivateMode.None;
     else if (comboBox.Text == "Single Click")
         objectListView.CellEditActivation = ObjectListView.CellEditActivateMode.SingleClick;
     else if (comboBox.Text == "Double Click")
         objectListView.CellEditActivation = ObjectListView.CellEditActivateMode.DoubleClick;
     else
         objectListView.CellEditActivation = ObjectListView.CellEditActivateMode.F2Only;
 }
开发者ID:Cubio,项目名称:Hauli,代码行数:11,代码来源:ContestantWrongInfo.cs

示例13: GenerateColumns

        /// <summary>
        /// Replace all columns of the given ObjectListView with columns generated
        /// from the first member of the given enumerable. If the enumerable is 
        /// empty or null, the ObjectListView will be cleared.
        /// </summary>
        /// <param name="olv">The ObjectListView to modify</param>
        /// <param name="enumerable">The collection whose first element will be used to generate columns.</param>
        static public void GenerateColumns(ObjectListView olv, IEnumerable enumerable) {
            // Generate columns based on the type of the first model in the collection and then quit
            if (enumerable != null) {
                foreach (object model in enumerable) {
                    Generator.GenerateColumns(olv, model.GetType());
                    return;
                }
            }

            // If we reach here, the collection was empty, so we clear the list
            Generator.ReplaceColumns(olv, new List<OLVColumn>());
        }
开发者ID:justdanpo,项目名称:DriverStoreExplorer,代码行数:19,代码来源:Generator.cs

示例14: StringListPutHelper

 private void StringListPutHelper(ObjectListView list_view, List<string> l, object row_object, object value)
 {
   for (int i = 0, count = l.Count; i < count; ++i)
   {
     if (Object.ReferenceEquals(row_object, l[i]))
     {
       l[i] = (string)value;
       break;
     }
   }
   list_view.SetObjects(l, true);
 }
开发者ID:corefan,项目名称:ig-memtrace,代码行数:12,代码来源:OptionsDialog.cs

示例15: SetBusy

        public void SetBusy(ObjectListView lv,bool busy)
        {
            if (busy)
            {

                lv.OverlayText = GenerateOverlay();
            }
            else
            {
                lv.OverlayText = null;
            }
        }
开发者ID:maxpiva,项目名称:AnimeOfflineDownloader,代码行数:12,代码来源:MainForm.cs


注:本文中的BrightIdeasSoftware.ObjectListView类示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。