Esempio n. 1
0
 public PackageImportTreeView(PackageImport packageImport, TreeViewState treeViewState, Rect startRect)
 {
     this.m_PackageImport = packageImport;
     this.m_TreeView      = new TreeView((EditorWindow)this.m_PackageImport, treeViewState);
     PackageImportTreeView.PackageImportTreeViewDataSource treeViewDataSource = new PackageImportTreeView.PackageImportTreeViewDataSource(this.m_TreeView, this);
     PackageImportTreeView.PackageImportTreeViewGUI        importTreeViewGui  = new PackageImportTreeView.PackageImportTreeViewGUI(this.m_TreeView, this);
     this.m_TreeView.Init(startRect, (ITreeViewDataSource)treeViewDataSource, (ITreeViewGUI)importTreeViewGui, (ITreeViewDragging)null);
     this.m_TreeView.ReloadData();
     this.m_TreeView.selectionChangedCallback += new System.Action <int[]>(this.SelectionChanged);
     importTreeViewGui.itemWasToggled         += new System.Action <PackageImportTreeView.PackageImportTreeViewItem>(this.ItemWasToggled);
     this.ComputeEnabledStateForFolders();
 }
 public PackageImportTreeView(PackageImport packageImport, TreeViewState treeViewState, Rect startRect)
 {
   this.m_PackageImport = packageImport;
   this.m_TreeView = new TreeView((EditorWindow) this.m_PackageImport, treeViewState);
   PackageImportTreeView.PackageImportTreeViewDataSource treeViewDataSource = new PackageImportTreeView.PackageImportTreeViewDataSource(this.m_TreeView, this);
   PackageImportTreeView.PackageImportTreeViewGUI importTreeViewGui = new PackageImportTreeView.PackageImportTreeViewGUI(this.m_TreeView, this);
   this.m_TreeView.Init(startRect, (ITreeViewDataSource) treeViewDataSource, (ITreeViewGUI) importTreeViewGui, (ITreeViewDragging) null);
   this.m_TreeView.ReloadData();
   this.m_TreeView.selectionChangedCallback += new System.Action<int[]>(this.SelectionChanged);
   importTreeViewGui.itemWasToggled += new System.Action<PackageImportTreeView.PackageImportTreeViewItem>(this.ItemWasToggled);
   this.ComputeEnabledStateForFolders();
 }
        public PackageImportTreeView(AssetsItem[] items, List <string> enabledFolders, TreeViewState treeViewState, PackageImport packageImportWindow, Rect startRect)
        {
            this.m_TreeView = new TreeView(packageImportWindow, treeViewState);
            PackageImportTreeView.PackageImportTreeViewDataSource data = new PackageImportTreeView.PackageImportTreeViewDataSource(this.m_TreeView, items, enabledFolders);
            PackageImportTreeView.PackageImportTreeViewGUI        packageImportTreeViewGUI = new PackageImportTreeView.PackageImportTreeViewGUI(this.m_TreeView);
            this.m_TreeView.Init(startRect, data, packageImportTreeViewGUI, null);
            this.m_TreeView.ReloadData();
            TreeView expr_5A = this.m_TreeView;

            expr_5A.selectionChangedCallback = (Action <int[]>)Delegate.Combine(expr_5A.selectionChangedCallback, new Action <int[]>(this.SelectionChanged));
            PackageImportTreeView.PackageImportTreeViewGUI expr_7C = packageImportTreeViewGUI;
            expr_7C.itemWasToggled = (Action <PackageImportTreeView.PackageImportTreeViewItem>)Delegate.Combine(expr_7C.itemWasToggled, new Action <PackageImportTreeView.PackageImportTreeViewItem>(this.ItemWasToggled));
            this.ComputeEnabledStateForFolders();
        }
        public PackageImportTreeView(PackageImport packageImport, TreeViewState treeViewState, Rect startRect)
        {
            this.m_PackageImport = packageImport;
            this.m_TreeView      = new TreeViewController(this.m_PackageImport, treeViewState);
            PackageImportTreeView.PackageImportTreeViewDataSource data = new PackageImportTreeView.PackageImportTreeViewDataSource(this.m_TreeView, this);
            PackageImportTreeView.PackageImportTreeViewGUI        packageImportTreeViewGUI = new PackageImportTreeView.PackageImportTreeViewGUI(this.m_TreeView, this);
            this.m_TreeView.Init(startRect, data, packageImportTreeViewGUI, null);
            this.m_TreeView.ReloadData();
            TreeViewController expr_65 = this.m_TreeView;

            expr_65.selectionChangedCallback = (Action <int[]>)Delegate.Combine(expr_65.selectionChangedCallback, new Action <int[]>(this.SelectionChanged));
            PackageImportTreeView.PackageImportTreeViewGUI expr_87 = packageImportTreeViewGUI;
            expr_87.itemWasToggled = (Action <PackageImportTreeView.PackageImportTreeViewItem>)Delegate.Combine(expr_87.itemWasToggled, new Action <PackageImportTreeView.PackageImportTreeViewItem>(this.ItemWasToggled));
            this.ComputeEnabledStateForFolders();
        }
		public PackageImportTreeView(AssetsItem[] items, List<string> enabledFolders, TreeViewState treeViewState, PackageImport packageImportWindow, Rect startRect)
		{
			this.m_TreeView = new TreeView(packageImportWindow, treeViewState);
			PackageImportTreeView.PackageImportTreeViewDataSource data = new PackageImportTreeView.PackageImportTreeViewDataSource(this.m_TreeView, items, enabledFolders);
			PackageImportTreeView.PackageImportTreeViewGUI packageImportTreeViewGUI = new PackageImportTreeView.PackageImportTreeViewGUI(this.m_TreeView);
			this.m_TreeView.Init(startRect, data, packageImportTreeViewGUI, null);
			this.m_TreeView.ReloadData();
			TreeView expr_5A = this.m_TreeView;
			expr_5A.selectionChangedCallback = (Action<int[]>)Delegate.Combine(expr_5A.selectionChangedCallback, new Action<int[]>(this.SelectionChanged));
			PackageImportTreeView.PackageImportTreeViewGUI expr_7C = packageImportTreeViewGUI;
			expr_7C.itemWasToggled = (Action<PackageImportTreeView.PackageImportTreeViewItem>)Delegate.Combine(expr_7C.itemWasToggled, new Action<PackageImportTreeView.PackageImportTreeViewItem>(this.ItemWasToggled));
			this.ComputeEnabledStateForFolders();
		}