private void UserInit() { if (ApplicationManager.Instance.User != null && !ApplicationManager.Instance.User.IsAdmin()) { this.Items.Remove(this.ConfigTabItem); this.Items.Remove(this.LeftTabItem); this.Items.Remove(this.RightTabItem); this.Items.Remove(this.BottomTabItem); //this.LeftGrid.NameTextBox.IsReadOnly = true; //this.LeftGrid.CommentTextBlock.IsEnabled = false; //this.RightGrid.NameTextBox.IsReadOnly = true; //this.RightGrid.CommentTextBlock.IsEnabled = false; } else { this.LeftGridProperties.InputGridPropertiesPanel.GroupPanel.Visibility = System.Windows.Visibility.Collapsed; this.LeftGridProperties.InputGridPropertiesPanel.gridEachLoop.Visibility = System.Windows.Visibility.Collapsed; this.RightGridProperties.InputGridPropertiesPanel.GroupPanel.Visibility = System.Windows.Visibility.Collapsed; this.RightGridProperties.InputGridPropertiesPanel.gridEachLoop.Visibility = System.Windows.Visibility.Collapsed; this.BottomGridProperties.InputGridPropertiesPanel.GroupPanel.Visibility = System.Windows.Visibility.Collapsed; this.BottomGridProperties.InputGridPropertiesPanel.gridEachLoop.Visibility = System.Windows.Visibility.Collapsed; this.AdministrationBar = new AdministrationBar(this.SubjectType); } }
public void InitializeComponents() { this.TransformationTreePropertiePanel = new TransformationTreePropertiePanel(); this.TransformationTreeDiagramView = new TransformationTreeDiagram(); this.Children.Add(this.TransformationTreeDiagramView); if (ApplicationManager.Instance.User.IsAdmin()) { this.AdministrationBar = new AdministrationBar(this.SubjectType); } }
protected virtual void InitializeComponents() { this.Background = null; this.BorderBrush = null; this.TabStripPlacement = Dock.Bottom; ItemsPanelTemplate temp = this.ItemsPanel; Uri rd1 = new Uri("../Resources/Styles/TabControl.xaml", UriKind.Relative); this.Resources.MergedDictionaries.Add(Application.LoadComponent(rd1) as ResourceDictionary); designTabItem = new TabItem(); designTabItem.Header = "Design"; designTabItem.Background = null; designTabItem.BorderBrush = null; auditTabItem = new TabItem(); auditTabItem.Header = "Audit"; auditTabItem.Background = null; auditTabItem.BorderBrush = null; this.TablePropertiesPanel = new TablePropertiesPanel(); this.TableCellParameterPanel = new TableCellParameterPanel(); this.AllocationForm = new AllocationForm(); this.AllocationPropertiesPanel = new AllocationPropertiesPanel(); //this.AllocationForm.TransformationTreeService = InputTableService.TransformationTreeService; this.CellPropertyGrid = new CellPropertyGrid(); this.CellPropertyGrid.hideContextMenu(); try { if (Misp.Kernel.Application.ApplicationManager.Instance.User.IsAdmin()) { this.AdministrationBar = new AdministrationBar(this.SubjectType); } this.SpreadSheet = new DESpreadsheet(); designTabItem.Content = this.SpreadSheet; } catch (Exception e) { Console.Out.WriteLine(e); } auditTabItem.Content = CellPropertyGrid; this.Items.Add(designTabItem); this.Items.Add(auditTabItem); this.SelectionChanged += onSelectTabChancged; }
protected virtual void InitializeComponents() { StructuredReportPropertiesPanel = new StructuredReportPropertiesPanel(); // StructuredReportPropertiesPanel.visibleInShortcutCheckbox.Visibility = System.Windows.Visibility.Hidden; this.Background = System.Windows.Media.Brushes.White; this.BorderBrush = System.Windows.Media.Brushes.White; Uri rd1 = new Uri("../Resources/Styles/TabControl.xaml", UriKind.Relative); this.Resources.MergedDictionaries.Add(Application.LoadComponent(rd1) as ResourceDictionary); try { if (Misp.Kernel.Application.ApplicationManager.Instance.User.IsAdmin()) { this.AdministrationBar = new AdministrationBar(this.SubjectType); } this.SpreadSheet = new DESheetPanel(); this.Content = this.SpreadSheet; } catch (Exception e) { Console.Out.WriteLine(e); } //try //{ // this.SpreadSheet = new SheetPanel(); // this.SpreadSheet.CreateNewExcelFile(); // this.SpreadSheet.BuildSheetPanelMethod(); // this.SpreadSheet.RemoveTempFiles(); // WindowsFormsHost host = new WindowsFormsHost(); // host.Child = SpreadSheet; // this.Content = host; //} //catch (Exception) { } }
protected virtual void InitializeComponent() { this.Background = Brushes.White; this.TabStripPlacement = Dock.Bottom; AuditTabItem = new TabItem(); ConfigurationTabItem = new TabItem(); GridForm = new GrilleBrowserForm(this.SubjectType); InputGridSheetForm = new InputGridSheetForm(this.SubjectType); AuditTabItem.Header = "Grid"; AuditTabItem.Background = Brushes.White; AuditTabItem.Content = GridForm; ConfigurationTabItem.Header = "Configuration"; ConfigurationTabItem.Background = Brushes.White; ConfigurationTabItem.Content = InputGridSheetForm; if (ApplicationManager.Instance.User.IsAdmin()) { this.AdministrationBar = new AdministrationBar(this.SubjectType); } this.Items.Add(AuditTabItem); this.Items.Add(ConfigurationTabItem); }
protected virtual void InitializeComponents() { DesignerPropertiesPanel = new DesignerPropertiesPanel(); this.Background = Brushes.White; this.BorderBrush = Brushes.White; Uri rd1 = new Uri("../Resources/Styles/TabControl.xaml", UriKind.Relative); this.Resources.MergedDictionaries.Add(Application.LoadComponent(rd1) as ResourceDictionary); try { if (Misp.Kernel.Application.ApplicationManager.Instance.User.IsAdmin()) { this.AdministrationBar = new AdministrationBar(this.SubjectType); } this.SpreadSheet = new DESheetPanel(); this.SpreadSheet.CreateNewExcelFile(); this.Content = SpreadSheet; } catch (Exception) { } }