using System; using System.CodeDom.Compiler; using System.Collections; using System.Collections.Generic; using System.Collections.ObjectModel; using System.ComponentModel; using System.Diagnostics; using System.Linq; using System.Threading.Tasks; using System.Windows; using System.Windows.Controls; using System.Windows.Controls.Primitives; using System.Windows.Input; using System.Windows.Markup; using System.Windows.Media; using System.Windows.Threading; using Gestor.Application.Drawers; using Gestor.Application.Helpers; using Gestor.Application.Servicos; using Gestor.Application.ViewModels; using Gestor.Application.ViewModels.Seguros; using Gestor.Application.ViewModels.Seguros.Itens; using Gestor.Application.Views.Generic; using Gestor.Common.Validation; using Gestor.Model.Common; using Gestor.Model.Domain.Generic; using Gestor.Model.Domain.Seguros; namespace Gestor.Application.Views.Seguros.Itens; public class VidaView : BaseUserControl, IComponentConnector, IStyleConnector { public VidaViewModel ViewModel; private readonly MenuItemViewModel _menuItemViewModel; private bool _salvando; internal MenuItem IncluirItemButton; internal MenuItem SinistroButton; internal TextBox PlanoBox; internal RadioButton CoberturasRadioButton; internal RadioButton MaisInformacoesRadioButton; internal Menu BotoesTitulares; internal Separator SeparadorMaisInformacoes; internal ContentControl ContentControl; internal DataGrid DataGridTitulares; private bool _contentLoaded; public VidaView(MenuItemViewModel menuItemViewModel, bool lockInsert = false, bool substituir = false, ManutencaoItem manutencao = null, Item itemSelecionado = null, Ramo ramo = null, bool endossoRenovacao = false) { _menuItemViewModel = menuItemViewModel; ViewModel = new VidaViewModel(substituir, manutencao, itemSelecionado, ramo, endossoRenovacao); ((FrameworkElement)this).DataContext = ViewModel; InitializeComponent(); Dispatcher dispatcher = ((DispatcherObject)this).Dispatcher; if (dispatcher != null) { dispatcher.BeginInvoke((DispatcherPriority)7, (Delegate)new Action(ContentLoad)); } if (lockInsert) { ((UIElement)IncluirItemButton).IsEnabled = false; ((UIElement)SinistroButton).Visibility = (Visibility)2; } } public async Task Selecionar(Item item) { await ViewModel.SelecionaItem(item); } public void Manter(ManutencaoItem manutencao) { ViewModel.Manter(ConsultaViewModel.ItemSelecionado, manutencao); } public void Substituir() { ViewModel.Substituir(ConsultaViewModel.ItemSelecionado); } private void ContentLoad() { //IL_000d: Unknown result type (might be due to invalid IL or missing references) //IL_0017: Expected O, but got Unknown //IL_0024: Unknown result type (might be due to invalid IL or missing references) //IL_002e: Expected O, but got Unknown ((ToggleButton)CoberturasRadioButton).Checked += new RoutedEventHandler(Documento_OnChecked); ((ToggleButton)MaisInformacoesRadioButton).Checked += new RoutedEventHandler(Documento_OnChecked); } private void Documento_OnChecked(object sender, RoutedEventArgs e) { //IL_0001: Unknown result type (might be due to invalid IL or missing references) //IL_0007: Expected O, but got Unknown RadioButton val = (RadioButton)sender; if (!string.IsNullOrEmpty(val.GroupName)) { ViewModel.Descarregar(); ((UIElement)ContentControl).Visibility = (Visibility)2; ((UIElement)DataGridTitulares).Visibility = (Visibility)2; ((UIElement)SeparadorMaisInformacoes).Visibility = (Visibility)2; ((UIElement)BotoesTitulares).Visibility = (Visibility)2; ((DependencyObject)(object)DataGridTitulares).ClearInvalid(); ((DependencyObject)(object)ContentControl).ClearInvalid(); if (!(((FrameworkElement)val).Name == "MaisInformacoesRadioButton")) { ((UIElement)ContentControl).Visibility = (Visibility)0; ViewModel.CarregaCobertura(); } else { ((UIElement)SeparadorMaisInformacoes).Visibility = (Visibility)0; ((UIElement)DataGridTitulares).Visibility = (Visibility)0; ((UIElement)BotoesTitulares).Visibility = (Visibility)0; } } } private async void Incluir_OnClick(object sender, RoutedEventArgs e) { await ViewModel.Incluir(); List> errorMessages = ViewModel.SelectedItem.Validate(); ((DependencyObject)(object)this).ValidateFields(errorMessages); } private async void IncluirTitular_OnClick(object sender, RoutedEventArgs e) { TitularesVida val = ((IEnumerable)((ItemsControl)DataGridTitulares).Items).Cast().FirstOrDefault(); if (val != null && !val.Inicio.HasValue && !val.Fim.HasValue && val.Nome == null && val.Fatura == null && val.Cpf == null && !val.Tipo.HasValue && val.Observacao == null) { await ViewModel.ShowMessage("JÁ EXISTE UM CAMPO DE CADASTRO DE TITULAR CRIADO"); return; } ViewModel.IncluirTitular(); UpdateAutocompleteDependente(((IEnumerable)((ItemsControl)DataGridTitulares).Items).Cast().First(), scroll: false); } private void ExcluirTitular_OnClick(object sender, RoutedEventArgs e) { ViewModel.ExcluirTitular(); } private async void ImportarTitulares_OnClick(object sender, RoutedEventArgs e) { await ViewModel.ImportarTitulares(); } private async void Excluir_OnClick(object sender, RoutedEventArgs e) { if (await ViewModel.Excluir()) { _menuItemViewModel?.RecarregarItens(null); } } private void Cancelar_OnClick(object sender, RoutedEventArgs e) { ViewModel.CancelarAlteracao(); } public async void Salvar_OnClick(object sender, RoutedEventArgs e) { _salvando = true; ViewModel.Loading(isLoading: true); ViewModel.SelectedItem.Vida.Plano = PlanoBox.Text; ((UIElement)DataGridTitulares).Focus(); List> list = await ViewModel.Salvar(((IEnumerable)((ItemsControl)DataGridTitulares).Items).Cast().ToList()); ((DependencyObject)(object)this).ValidateFields(list); bool num = list == null || list.Count == 0; ViewModel.Loading(isLoading: false); _salvando = false; if (num) { if (((DomainBase)ViewModel.SelectedItem).Id > 0) { _menuItemViewModel?.RecarregarItens(ViewModel.SelectedItem); } } else { await ViewModel.ShowMessage(list, ViewModel.ErroCamposInvalidos, "OK"); } } private void Alterar_OnClick(object sender, RoutedEventArgs e) { ViewModel.Alterar(alterar: true); } private async void AbrirAquivoDigital_Click(object sender, RoutedEventArgs e) { if (!new PermissaoArquivoDigitalServico().BuscarPermissao(Recursos.Usuario, (TipoArquivoDigital)4).Consultar) { await ViewModel.ShowMessage("VOCÊ NÃO POSSUI PERMISSÃO PARA ACESSAR\nARQUIVO DIGITAL DE " + ValidationHelper.GetDescription((Enum)(object)(TipoArquivoDigital)4) + "."); return; } FiltroArquivoDigital filtro = new FiltroArquivoDigital { Id = ((DomainBase)ViewModel.SelectedItem).Id, IdApolice = ((DomainBase)ViewModel.SelectedItem.Documento).Id, Tipo = (TipoArquivoDigital)4, Parente = ViewModel.SelectedItem }; ViewModel.ShowDrawer(new ArquivoDigitalDrawer(filtro), 0, close: false); } private void AbrirLog_OnClick(object sender, RoutedEventArgs e) { ViewModel.AbrirLog((TipoTela)3, ((DomainBase)ViewModel.SelectedItem).Id); } private void AbrirLogEmail_OnClick(object sender, RoutedEventArgs e) { ViewModel.AbrirLogEmail((TipoTela)3, ((DomainBase)ViewModel.SelectedItem).Id); } private void BotoesTitulares_OnIsEnabledChanged(object sender, DependencyPropertyChangedEventArgs e) { //IL_0001: Unknown result type (might be due to invalid IL or missing references) //IL_0044: Unknown result type (might be due to invalid IL or missing references) if (!((UIElement)(Menu)sender).IsEnabled) { ViewModel.AlteracaoTitularesVisibility = (Visibility)2; } DataGrid dataGridTitulares = DataGridTitulares; if (((dataGridTitulares != null) ? dataGridTitulares.Columns.First() : null) != null) { DataGridTitulares.Columns.First().Visibility = (Visibility)((!((UIElement)(Menu)sender).IsEnabled) ? 2 : 0); } } private void AlterarTitular_OnClick(object sender, RoutedEventArgs e) { ViewModel.AlterarTitular(); } private void AplicarTitular_OnClick(object sender, RoutedEventArgs e) { ViewModel.AplicarTitular(); } private void DataGridTitulares_OnCellEditEnding(object sender, DataGridCellEditEndingEventArgs e) { if (!(e.EditingElement is TextBox)) { return; } FrameworkElement editingElement = e.EditingElement; TextBox val = (TextBox)(object)((editingElement is TextBox) ? editingElement : null); string stringFormat = e.Column.ClipboardContentBinding.StringFormat; if (!(stringFormat == "d")) { if (!(stringFormat == "c")) { if (!string.IsNullOrEmpty((val != null) ? val.Text : null)) { if (e.Column.SortMemberPath == "Cpf") { val.Text = ValidationHelper.FormatDocument(val.Text); } } else if (val != null) { val.Text = null; } } else if (!string.IsNullOrEmpty((val != null) ? val.Text : null)) { val.Text = ValidationHelper.FormatCurrency(val.Text); } else if (val != null) { val.Text = null; } } else if (!string.IsNullOrEmpty((val != null) ? val.Text : null)) { val.Text = ValidationHelper.FormatDate(val.Text); } else if (val != null) { val.Text = null; } } private void AutoCompleteBox_Populating(object sender, PopulatingEventArgs e) { if (e.Parameter.Trim().Length < 3) { return; } e.Cancel = true; ViewModel.BuscarTitulares(ValidationHelper.RemoveDiacritics(e.Parameter.Trim())).ContinueWith(delegate(Task> searchResult) { //IL_000f: Unknown result type (might be due to invalid IL or missing references) //IL_0014: Unknown result type (might be due to invalid IL or missing references) if (searchResult.Result != null) { AutoCompleteBox val = (AutoCompleteBox)sender; val.ItemsSource = searchResult.Result; val.PopulateComplete(); } }, TaskScheduler.FromCurrentSynchronizationContext()); } private async void TipoComboBoxSelectionChanged(object sender, SelectionChangedEventArgs e) { ComboBox val = (ComboBox)sender; if ((((int)val != 0) ? ((FrameworkElement)val).DataContext : null) != null) { if ((int)((TitularesVida)((FrameworkElement)(ComboBox)sender).DataContext).Tipo.GetValueOrDefault() == 2 && !_salvando && ((DomainBase)ViewModel.SelectedItem.Documento.Controle.Ramo).Id != 6 && !ViewModel.Titulares.Any((TitularesVida x) => (int)x.Tipo.GetValueOrDefault() == 1 || x.Tipo == (TipoTitular?)0)) { ((Selector)(ComboBox)sender).SelectedIndex = -1; ((TitularesVida)((FrameworkElement)(ComboBox)sender).DataContext).Tipo = null; await ViewModel.ShowMessage("É NECESSÁRIO ADICIONAR PELO MENOS UM TITULAR DO TIPO SÓCIO OU FUNCIONÁRIO\nANTES DE ADICIONAR UM DEPENDENTE."); } else { UpdateAutocompleteDependente((TitularesVida)((FrameworkElement)(ComboBox)sender).DataContext, scroll: false); } } } private void UpdateAutocompleteDependente(TitularesVida item, bool scroll = true) { //IL_005a: Unknown result type (might be due to invalid IL or missing references) //IL_0060: Expected O, but got Unknown //IL_0076: Unknown result type (might be due to invalid IL or missing references) //IL_0084: Unknown result type (might be due to invalid IL or missing references) //IL_008a: Invalid comparison between Unknown and I4 if (scroll) { DataGridTitulares.ScrollIntoView((object)item, DataGridTitulares.Columns.First((DataGridColumn x) => (string)x.Header == "TITULAR DEPENDENTE")); } ((UIElement)DataGridTitulares).UpdateLayout(); DataGridRow val = (DataGridRow)((ItemsControl)DataGridTitulares).ItemContainerGenerator.ContainerFromItem((object)item); if (val != null) { ((UIElement)(DataGridCell)((ItemsControl)DataGridExtensions.GetVisualChild((Visual)(object)val)).ItemContainerGenerator.ContainerFromIndex(12)).Visibility = (Visibility)(((int)item.Tipo.GetValueOrDefault() != 2) ? 2 : 0); if (scroll) { DataGridTitulares.ScrollIntoView((object)item, DataGridTitulares.Columns.First()); } ((UIElement)DataGridTitulares).UpdateLayout(); } } private void Dependente_CellLoaded(object sender, RoutedEventArgs e) { //IL_0005: Unknown result type (might be due to invalid IL or missing references) //IL_000b: Unknown result type (might be due to invalid IL or missing references) //IL_0015: Unknown result type (might be due to invalid IL or missing references) //IL_001a: Unknown result type (might be due to invalid IL or missing references) //IL_0029: Unknown result type (might be due to invalid IL or missing references) //IL_002f: Invalid comparison between Unknown and I4 if (sender != null) { DataGridCell val = (DataGridCell)sender; TitularesVida val2 = (TitularesVida)((FrameworkElement)(DataGridCell)sender).DataContext; ((UIElement)val).Visibility = (Visibility)(((int)val2 == 0 || (int)val2.Tipo.GetValueOrDefault() != 2) ? 2 : 0); } } private void MenuItem_OnClick(object sender, RoutedEventArgs e) { ((Window)new HosterWindow((ContentControl)(object)new SinistroView(ViewModel.SelectedItem, attached: false), "CADASTRO DE SINISTROS - " + ViewModel.SelectedItem.Descricao)).ShowDialog(); _menuItemViewModel?.RecarregarItens(ViewModel.SelectedItem); } private void CopyCodItem(object sender, MouseButtonEventArgs e) { ViewModel.CodigoItem.CopyToClipboard(); ViewModel.ToggleSnackBar("COPIADO - " + ViewModel.CodigoItem); } [DebuggerNonUserCode] [GeneratedCode("PresentationBuildTasks", "4.0.0.0")] public void InitializeComponent() { if (!_contentLoaded) { _contentLoaded = true; Uri uri = new Uri("/Gestor.Application;component/views/seguros/itens/vidaview.xaml", UriKind.Relative); Application.LoadComponent((object)this, uri); } } [DebuggerNonUserCode] [GeneratedCode("PresentationBuildTasks", "4.0.0.0")] internal Delegate _CreateDelegate(Type delegateType, string handler) { return Delegate.CreateDelegate(delegateType, this, handler); } [DebuggerNonUserCode] [GeneratedCode("PresentationBuildTasks", "4.0.0.0")] [EditorBrowsable(EditorBrowsableState.Never)] void IComponentConnector.Connect(int connectionId, object target) { //IL_0077: Unknown result type (might be due to invalid IL or missing references) //IL_0081: Expected O, but got Unknown //IL_008e: Unknown result type (might be due to invalid IL or missing references) //IL_0098: Expected O, but got Unknown //IL_009a: Unknown result type (might be due to invalid IL or missing references) //IL_00a6: Unknown result type (might be due to invalid IL or missing references) //IL_00b0: Expected O, but got Unknown //IL_00b2: Unknown result type (might be due to invalid IL or missing references) //IL_00be: Unknown result type (might be due to invalid IL or missing references) //IL_00c8: Expected O, but got Unknown //IL_00ca: Unknown result type (might be due to invalid IL or missing references) //IL_00d6: Unknown result type (might be due to invalid IL or missing references) //IL_00e0: Expected O, but got Unknown //IL_00e2: Unknown result type (might be due to invalid IL or missing references) //IL_00ee: Unknown result type (might be due to invalid IL or missing references) //IL_00f8: Expected O, but got Unknown //IL_00fa: Unknown result type (might be due to invalid IL or missing references) //IL_0106: Unknown result type (might be due to invalid IL or missing references) //IL_0110: Expected O, but got Unknown //IL_0112: Unknown result type (might be due to invalid IL or missing references) //IL_011e: Unknown result type (might be due to invalid IL or missing references) //IL_0128: Expected O, but got Unknown //IL_012b: Unknown result type (might be due to invalid IL or missing references) //IL_0135: Expected O, but got Unknown //IL_0142: Unknown result type (might be due to invalid IL or missing references) //IL_014c: Expected O, but got Unknown //IL_014e: Unknown result type (might be due to invalid IL or missing references) //IL_015a: Unknown result type (might be due to invalid IL or missing references) //IL_0164: Expected O, but got Unknown //IL_0166: Unknown result type (might be due to invalid IL or missing references) //IL_0172: Unknown result type (might be due to invalid IL or missing references) //IL_017c: Expected O, but got Unknown //IL_017f: Unknown result type (might be due to invalid IL or missing references) //IL_0189: Expected O, but got Unknown //IL_018c: Unknown result type (might be due to invalid IL or missing references) //IL_0196: Expected O, but got Unknown //IL_0199: Unknown result type (might be due to invalid IL or missing references) //IL_01a3: Expected O, but got Unknown //IL_01a6: Unknown result type (might be due to invalid IL or missing references) //IL_01b0: Expected O, but got Unknown //IL_01bd: Unknown result type (might be due to invalid IL or missing references) //IL_01c7: Expected O, but got Unknown //IL_01c9: Unknown result type (might be due to invalid IL or missing references) //IL_01d5: Unknown result type (might be due to invalid IL or missing references) //IL_01df: Expected O, but got Unknown //IL_01e1: Unknown result type (might be due to invalid IL or missing references) //IL_01ed: Unknown result type (might be due to invalid IL or missing references) //IL_01f7: Expected O, but got Unknown //IL_01f9: Unknown result type (might be due to invalid IL or missing references) //IL_0205: Unknown result type (might be due to invalid IL or missing references) //IL_020f: Expected O, but got Unknown //IL_0211: Unknown result type (might be due to invalid IL or missing references) //IL_021d: Unknown result type (might be due to invalid IL or missing references) //IL_0227: Expected O, but got Unknown //IL_022a: Unknown result type (might be due to invalid IL or missing references) //IL_0234: Expected O, but got Unknown //IL_0236: Unknown result type (might be due to invalid IL or missing references) //IL_0242: Unknown result type (might be due to invalid IL or missing references) //IL_024c: Expected O, but got Unknown //IL_024d: Unknown result type (might be due to invalid IL or missing references) //IL_0259: Unknown result type (might be due to invalid IL or missing references) //IL_0263: Expected O, but got Unknown //IL_0264: Unknown result type (might be due to invalid IL or missing references) //IL_0270: Unknown result type (might be due to invalid IL or missing references) //IL_027a: Expected O, but got Unknown //IL_027c: Unknown result type (might be due to invalid IL or missing references) //IL_0288: Unknown result type (might be due to invalid IL or missing references) //IL_0292: Expected O, but got Unknown //IL_0293: Unknown result type (might be due to invalid IL or missing references) //IL_029f: Unknown result type (might be due to invalid IL or missing references) //IL_02a9: Expected O, but got Unknown //IL_02aa: Unknown result type (might be due to invalid IL or missing references) //IL_02b6: Unknown result type (might be due to invalid IL or missing references) //IL_02c0: Expected O, but got Unknown //IL_02c2: Unknown result type (might be due to invalid IL or missing references) //IL_02ce: Unknown result type (might be due to invalid IL or missing references) //IL_02d8: Expected O, but got Unknown //IL_02d9: Unknown result type (might be due to invalid IL or missing references) //IL_02e5: Unknown result type (might be due to invalid IL or missing references) //IL_02ef: Expected O, but got Unknown //IL_02f0: Unknown result type (might be due to invalid IL or missing references) //IL_02fc: Unknown result type (might be due to invalid IL or missing references) //IL_0306: Expected O, but got Unknown //IL_0308: Unknown result type (might be due to invalid IL or missing references) //IL_0315: Unknown result type (might be due to invalid IL or missing references) //IL_031f: Expected O, but got Unknown //IL_0320: Unknown result type (might be due to invalid IL or missing references) //IL_032d: Unknown result type (might be due to invalid IL or missing references) //IL_0337: Expected O, but got Unknown //IL_0339: Unknown result type (might be due to invalid IL or missing references) //IL_0345: Unknown result type (might be due to invalid IL or missing references) //IL_034f: Expected O, but got Unknown //IL_0352: Unknown result type (might be due to invalid IL or missing references) //IL_035c: Expected O, but got Unknown //IL_035f: Unknown result type (might be due to invalid IL or missing references) //IL_0369: Expected O, but got Unknown switch (connectionId) { case 1: IncluirItemButton = (MenuItem)target; IncluirItemButton.Click += new RoutedEventHandler(Incluir_OnClick); break; case 2: ((MenuItem)target).Click += new RoutedEventHandler(Alterar_OnClick); break; case 3: ((MenuItem)target).Click += new RoutedEventHandler(Salvar_OnClick); break; case 4: ((MenuItem)target).Click += new RoutedEventHandler(Cancelar_OnClick); break; case 5: ((MenuItem)target).Click += new RoutedEventHandler(Excluir_OnClick); break; case 6: ((Control)(TextBox)target).MouseDoubleClick += new MouseButtonEventHandler(CopyCodItem); break; case 7: ((MenuItem)target).Click += new RoutedEventHandler(AbrirAquivoDigital_Click); break; case 8: SinistroButton = (MenuItem)target; SinistroButton.Click += new RoutedEventHandler(MenuItem_OnClick); break; case 9: ((MenuItem)target).Click += new RoutedEventHandler(AbrirLog_OnClick); break; case 10: ((MenuItem)target).Click += new RoutedEventHandler(AbrirLogEmail_OnClick); break; case 11: PlanoBox = (TextBox)target; break; case 12: CoberturasRadioButton = (RadioButton)target; break; case 13: MaisInformacoesRadioButton = (RadioButton)target; break; case 14: BotoesTitulares = (Menu)target; ((UIElement)BotoesTitulares).IsEnabledChanged += new DependencyPropertyChangedEventHandler(BotoesTitulares_OnIsEnabledChanged); break; case 15: ((MenuItem)target).Click += new RoutedEventHandler(IncluirTitular_OnClick); break; case 16: ((MenuItem)target).Click += new RoutedEventHandler(AlterarTitular_OnClick); break; case 17: ((MenuItem)target).Click += new RoutedEventHandler(ExcluirTitular_OnClick); break; case 18: ((MenuItem)target).Click += new RoutedEventHandler(ImportarTitulares_OnClick); break; case 19: SeparadorMaisInformacoes = (Separator)target; break; case 20: ((UIElement)(DatePicker)target).LostKeyboardFocus += new KeyboardFocusChangedEventHandler(base.DatePicker_OnLostKeyboardFocus); ((UIElement)(DatePicker)target).PreviewKeyDown += new KeyEventHandler(base.DatePicker_PreviewKeyDown); ((Control)(DatePicker)target).MouseDoubleClick += new MouseButtonEventHandler(base.DataAtual_OnDoubleClick); break; case 21: ((UIElement)(DatePicker)target).LostKeyboardFocus += new KeyboardFocusChangedEventHandler(base.DatePicker_OnLostKeyboardFocus); ((UIElement)(DatePicker)target).PreviewKeyDown += new KeyEventHandler(base.DatePicker_PreviewKeyDown); ((Control)(DatePicker)target).MouseDoubleClick += new MouseButtonEventHandler(base.DataAtual_OnDoubleClick); break; case 22: ((UIElement)(DatePicker)target).LostKeyboardFocus += new KeyboardFocusChangedEventHandler(base.DatePicker_OnLostKeyboardFocus); ((UIElement)(DatePicker)target).PreviewKeyDown += new KeyEventHandler(base.DatePicker_PreviewKeyDown); ((Control)(DatePicker)target).MouseDoubleClick += new MouseButtonEventHandler(base.DataAtual_OnDoubleClick); break; case 23: ((UIElement)(TextBox)target).LostFocus += new RoutedEventHandler(FormatarDocumento); ((UIElement)(TextBox)target).PreviewTextInput += new TextCompositionEventHandler(SomenteNumeros); break; case 24: ((MenuItem)target).Click += new RoutedEventHandler(AplicarTitular_OnClick); break; case 25: ContentControl = (ContentControl)target; break; case 26: DataGridTitulares = (DataGrid)target; DataGridTitulares.CellEditEnding += DataGridTitulares_OnCellEditEnding; break; default: _contentLoaded = true; break; } } [DebuggerNonUserCode] [GeneratedCode("PresentationBuildTasks", "4.0.0.0")] [EditorBrowsable(EditorBrowsableState.Never)] void IStyleConnector.Connect(int connectionId, object target) { //IL_0027: Unknown result type (might be due to invalid IL or missing references) //IL_0033: Unknown result type (might be due to invalid IL or missing references) //IL_003d: Expected O, but got Unknown //IL_003e: Unknown result type (might be due to invalid IL or missing references) //IL_004a: Unknown result type (might be due to invalid IL or missing references) //IL_0054: Expected O, but got Unknown //IL_0055: Unknown result type (might be due to invalid IL or missing references) //IL_0061: Unknown result type (might be due to invalid IL or missing references) //IL_006b: Expected O, but got Unknown //IL_006d: Unknown result type (might be due to invalid IL or missing references) //IL_0079: Unknown result type (might be due to invalid IL or missing references) //IL_0083: Expected O, but got Unknown //IL_0084: Unknown result type (might be due to invalid IL or missing references) //IL_0090: Unknown result type (might be due to invalid IL or missing references) //IL_009a: Expected O, but got Unknown //IL_009b: Unknown result type (might be due to invalid IL or missing references) //IL_00a7: Unknown result type (might be due to invalid IL or missing references) //IL_00b1: Expected O, but got Unknown //IL_00b3: Unknown result type (might be due to invalid IL or missing references) //IL_00bf: Unknown result type (might be due to invalid IL or missing references) //IL_00c9: Expected O, but got Unknown //IL_00ca: Unknown result type (might be due to invalid IL or missing references) //IL_00d6: Unknown result type (might be due to invalid IL or missing references) //IL_00e0: Expected O, but got Unknown //IL_00e1: Unknown result type (might be due to invalid IL or missing references) //IL_00ed: Unknown result type (might be due to invalid IL or missing references) //IL_00f7: Expected O, but got Unknown //IL_00f9: Unknown result type (might be due to invalid IL or missing references) //IL_0106: Unknown result type (might be due to invalid IL or missing references) //IL_0110: Expected O, but got Unknown //IL_0111: Unknown result type (might be due to invalid IL or missing references) //IL_011e: Unknown result type (might be due to invalid IL or missing references) //IL_0128: Expected O, but got Unknown //IL_012a: Unknown result type (might be due to invalid IL or missing references) //IL_0136: Unknown result type (might be due to invalid IL or missing references) //IL_0140: Expected O, but got Unknown //IL_0142: Unknown result type (might be due to invalid IL or missing references) //IL_014e: Unknown result type (might be due to invalid IL or missing references) //IL_0158: Expected O, but got Unknown //IL_0159: Unknown result type (might be due to invalid IL or missing references) //IL_015f: Expected O, but got Unknown //IL_0172: Unknown result type (might be due to invalid IL or missing references) //IL_017c: Expected O, but got Unknown //IL_017d: Unknown result type (might be due to invalid IL or missing references) switch (connectionId) { case 27: ((UIElement)(DatePicker)target).LostKeyboardFocus += new KeyboardFocusChangedEventHandler(base.DatePicker_OnLostKeyboardFocus); ((UIElement)(DatePicker)target).PreviewKeyDown += new KeyEventHandler(base.DatePicker_PreviewKeyDown); ((Control)(DatePicker)target).MouseDoubleClick += new MouseButtonEventHandler(base.DataAtual_OnDoubleClick); break; case 28: ((UIElement)(DatePicker)target).LostKeyboardFocus += new KeyboardFocusChangedEventHandler(base.DatePicker_OnLostKeyboardFocus); ((UIElement)(DatePicker)target).PreviewKeyDown += new KeyEventHandler(base.DatePicker_PreviewKeyDown); ((Control)(DatePicker)target).MouseDoubleClick += new MouseButtonEventHandler(base.DataAtual_OnDoubleClick); break; case 29: ((UIElement)(DatePicker)target).LostKeyboardFocus += new KeyboardFocusChangedEventHandler(base.DatePicker_OnLostKeyboardFocus); ((UIElement)(DatePicker)target).PreviewKeyDown += new KeyEventHandler(base.DatePicker_PreviewKeyDown); ((Control)(DatePicker)target).MouseDoubleClick += new MouseButtonEventHandler(base.DataAtual_OnDoubleClick); break; case 30: ((UIElement)(TextBox)target).LostFocus += new RoutedEventHandler(FormatarDocumento); ((UIElement)(TextBox)target).PreviewTextInput += new TextCompositionEventHandler(SomenteNumeros); break; case 31: ((Selector)(ComboBox)target).SelectionChanged += new SelectionChangedEventHandler(TipoComboBoxSelectionChanged); break; case 32: ((AutoCompleteBox)target).Populating += new PopulatingEventHandler(AutoCompleteBox_Populating); break; case 33: { EventSetter val = new EventSetter(); val.Event = FrameworkElement.LoadedEvent; val.Handler = (Delegate)new RoutedEventHandler(Dependente_CellLoaded); ((Collection)(object)((Style)target).Setters).Add((SetterBase)(object)val); break; } } } }