public PainelDetalhesTabelas(UserControlCentro ucc, bool back) { InitializeComponent(); PainelCentro = ucc; tabela = new Tabela(); buttonsDetails = new Controls.ButtonsDetails(); gridFundo.Children.Add(buttonsDetails); buttonsDetails.SaveClick += new EventHandler(Add_Tabela); buttonsDetails.HomeClick += new EventHandler(Home); buttonsDetails.DeleteClick += new EventHandler(DeleteTabela); propertyGridComboBox.SelectedIndex = 2; ActualizaDataGrid(); try { var subtype = subtipo.getSubtipo(); ComboListSubtipo.Add(" "); foreach (Subtipos st in subtype) { ComboListSubtipo.Add(st.Nome); } types = tipo.getTipo(); ListTipo.Add(" "); foreach (Tipos t in types) { ListTipo.Add(t.Nome); } AutoComplete1.ItemsSource = AutoComplete2.ItemsSource = ListTipo; combo_subtipos.ItemsSource = ComboListSubtipo; } catch { } textEditor.TextArea.TextEntering += textEditor_TextArea_TextEntering; textEditor.TextArea.TextEntered += textEditor_TextArea_TextEntered; DispatcherTimer foldingUpdateTimer = new DispatcherTimer(); foldingUpdateTimer.Interval = TimeSpan.FromSeconds(2); foldingUpdateTimer.Tick += foldingUpdateTimer_Tick; foldingUpdateTimer.Start(); }