using System; using System.CodeDom.Compiler; using System.Collections.Generic; using System.ComponentModel; using System.Diagnostics; using System.Windows; using System.Windows.Controls; using System.Windows.Input; using System.Windows.Markup; using System.Windows.Media; using System.Windows.Shapes; using Gestor.Application.ViewModels.Financeiro; using Gestor.Application.Views.Generic; using Gestor.Model.Domain.Financeiro; namespace Gestor.Application.Views.Financeiro; public class InfoExtratoView : BaseUserControl, IComponentConnector { private bool _buttonClickable; private bool _contentLoaded; public InfoExtratoViewModel ViewModel { get; set; } public InfoExtratoView(Saldo saldo, bool telaBancos = false) { ViewModel = new InfoExtratoViewModel(telaBancos); ((FrameworkElement)this).DataContext = ViewModel; ViewModel.SelectedSaldo = saldo; InitializeComponent(); } private void TopControls_OnMouseLeftButtonDown(object sender, MouseButtonEventArgs e) { //IL_0008: Unknown result type (might be due to invalid IL or missing references) //IL_000e: Unknown result type (might be due to invalid IL or missing references) //IL_0030: Unknown result type (might be due to invalid IL or missing references) //IL_0035: Unknown result type (might be due to invalid IL or missing references) //IL_0024: 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_003f: Expected O, but got Unknown _buttonClickable = true; ((Panel)(Grid)sender).Background = (Brush)((((FrameworkElement)(Grid)sender).Name == "CloseButton") ? new SolidColorBrush(Colors.Red) : new SolidColorBrush(Colors.DimGray)); } private void TopControls_OnMouseLeftButtonUp(object sender, MouseButtonEventArgs e) { //IL_000f: Unknown result type (might be due to invalid IL or missing references) if (_buttonClickable) { ((object)this).GetType().GetMethod(((FrameworkElement)(Grid)sender).Name + "_Click")?.Invoke(this, null); } } private static void TopControls_OnMouseEnter(object sender, MouseEventArgs e) { //IL_0001: Unknown result type (might be due to invalid IL or missing references) //IL_0007: 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_002e: Unknown result type (might be due to invalid IL or missing references) //IL_001d: Unknown result type (might be due to invalid IL or missing references) //IL_0022: Unknown result type (might be due to invalid IL or missing references) //IL_0038: Expected O, but got Unknown //IL_0039: Unknown result type (might be due to invalid IL or missing references) //IL_0044: Expected O, but got Unknown //IL_004e: Unknown result type (might be due to invalid IL or missing references) //IL_0053: Unknown result type (might be due to invalid IL or missing references) //IL_005d: Expected O, but got Unknown ((Panel)(Grid)sender).Background = (Brush)((((FrameworkElement)(Grid)sender).Name == "CloseButton") ? new SolidColorBrush(Colors.IndianRed) : new SolidColorBrush(Colors.Gray)); DependencyObject child = VisualTreeHelper.GetChild((DependencyObject)(Grid)sender, 0); Path val = (Path)(object)((child is Path) ? child : null); if (val != null) { ((Shape)val).Stroke = (Brush)new SolidColorBrush(Colors.White); } } private void TopControls_OnMouseLeave(object sender, MouseEventArgs e) { //IL_0008: Unknown result type (might be due to invalid IL or missing references) //IL_000d: Unknown result type (might be due to invalid IL or missing references) //IL_0012: Unknown result type (might be due to invalid IL or missing references) //IL_001c: Expected O, but got Unknown //IL_001d: Unknown result type (might be due to invalid IL or missing references) //IL_0028: Expected O, but got Unknown //IL_0032: Unknown result type (might be due to invalid IL or missing references) //IL_0037: Unknown result type (might be due to invalid IL or missing references) //IL_0041: Expected O, but got Unknown _buttonClickable = false; ((Panel)(Grid)sender).Background = (Brush)new SolidColorBrush(Colors.Transparent); DependencyObject child = VisualTreeHelper.GetChild((DependencyObject)(Grid)sender, 0); Path val = (Path)(object)((child is Path) ? child : null); if (val != null) { ((Shape)val).Stroke = (Brush)new SolidColorBrush(Colors.White); } } private async void Salvar_OnClick(object sender, RoutedEventArgs e) { ViewModel.Loading(isLoading: true); List> list = await ViewModel.Salvar(); bool num = list == null || list.Count == 0; ViewModel.Loading(isLoading: false); if (!num) { await ViewModel.ShowMessage(list, ViewModel.ErroCamposInvalidos, "OK"); } } [DebuggerNonUserCode] [GeneratedCode("PresentationBuildTasks", "4.0.0.0")] public void InitializeComponent() { if (!_contentLoaded) { _contentLoaded = true; Uri uri = new Uri("/Gestor.Application;component/views/financeiro/infoextratoview.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_0005: Unknown result type (might be due to invalid IL or missing references) //IL_0011: Unknown result type (might be due to invalid IL or missing references) //IL_001b: Expected O, but got Unknown if (connectionId == 1) { ((MenuItem)target).Click += new RoutedEventHandler(Salvar_OnClick); } else { _contentLoaded = true; } } }