diff options
| author | Lucas Faria Mendes <lucas.fariamo08@gmail.com> | 2026-03-30 13:38:18 +0000 |
|---|---|---|
| committer | Lucas Faria Mendes <lucas.fariamo08@gmail.com> | 2026-03-30 13:38:18 +0000 |
| commit | 1f4e14b2e973ee7de337fd4866d9a5ceff5cb6d1 (patch) | |
| tree | e1c3b20ea08f0cf71122a1e73f0d395f8fd83874 /Gestor.Application/Componentes/DialogInstalacoes.cs | |
| parent | 674ca83ba9243a9e95a7568c797668dab6aee26a (diff) | |
| download | gestor-1f4e14b2e973ee7de337fd4866d9a5ceff5cb6d1.tar.gz gestor-1f4e14b2e973ee7de337fd4866d9a5ceff5cb6d1.zip | |
chore: location
Diffstat (limited to 'Gestor.Application/Componentes/DialogInstalacoes.cs')
| -rw-r--r-- | Gestor.Application/Componentes/DialogInstalacoes.cs | 125 |
1 files changed, 0 insertions, 125 deletions
diff --git a/Gestor.Application/Componentes/DialogInstalacoes.cs b/Gestor.Application/Componentes/DialogInstalacoes.cs deleted file mode 100644 index 48ecc7e..0000000 --- a/Gestor.Application/Componentes/DialogInstalacoes.cs +++ /dev/null @@ -1,125 +0,0 @@ -using Gestor.Model.License;
-using MaterialDesignThemes.Wpf;
-using System;
-using System.CodeDom.Compiler;
-using System.Collections;
-using System.Collections.Generic;
-using System.ComponentModel;
-using System.Diagnostics;
-using System.Linq;
-using System.Runtime.CompilerServices;
-using System.Windows;
-using System.Windows.Controls;
-using System.Windows.Controls.Primitives;
-using System.Windows.Input;
-using System.Windows.Markup;
-
-namespace Gestor.Application.Componentes
-{
- public class DialogInstalacoes : UserControl, IComponentConnector
- {
- internal DataGrid InstalacoesView;
-
- internal Button ValidarButton;
-
- internal Button FecharButton;
-
- internal MaterialDesignThemes.Wpf.Snackbar Snackbar;
-
- private bool _contentLoaded;
-
- public DialogInstalacoes(List<Instalacao> instalacoes)
- {
- IEnumerable list;
- this.InitializeComponent();
- DataGrid instalacoesView = this.InstalacoesView;
- IEnumerable<Instalacao> instalacaos =
- from i in instalacoes
- where !string.IsNullOrEmpty(i.get_Gerenciador())
- select i;
- if (instalacaos != null)
- {
- list = instalacaos.ToList<Instalacao>();
- }
- else
- {
- list = null;
- }
- instalacoesView.ItemsSource = list;
- this.InstalacoesView.SelectedIndex = -1;
- }
-
- private void FecharButton_OnClick(object sender, RoutedEventArgs e)
- {
- DialogHost.CloseDialogCommand.Execute(null, this.FecharButton);
- }
-
- [DebuggerNonUserCode]
- [GeneratedCode("PresentationBuildTasks", "4.0.0.0")]
- public void InitializeComponent()
- {
- if (this._contentLoaded)
- {
- return;
- }
- this._contentLoaded = true;
- System.Windows.Application.LoadComponent(this, new Uri("/Gestor.Application;component/componentes/dialoginstalacoes.xaml", UriKind.Relative));
- }
-
- private void SnackbarMessage_ActionClick(object sender, RoutedEventArgs e)
- {
- this.Snackbar.get_Message().Content = "";
- this.Snackbar.set_IsActive(false);
- }
-
- [DebuggerNonUserCode]
- [EditorBrowsable(EditorBrowsableState.Never)]
- [GeneratedCode("PresentationBuildTasks", "4.0.0.0")]
- void System.Windows.Markup.IComponentConnector.Connect(int connectionId, object target)
- {
- switch (connectionId)
- {
- case 1:
- {
- this.InstalacoesView = (DataGrid)target;
- return;
- }
- case 2:
- {
- this.ValidarButton = (Button)target;
- this.ValidarButton.Click += new RoutedEventHandler(this.ValidarButton_OnClick);
- return;
- }
- case 3:
- {
- this.FecharButton = (Button)target;
- this.FecharButton.Click += new RoutedEventHandler(this.FecharButton_OnClick);
- return;
- }
- case 4:
- {
- this.Snackbar = (MaterialDesignThemes.Wpf.Snackbar)target;
- return;
- }
- case 5:
- {
- ((SnackbarMessage)target).add_ActionClick(new RoutedEventHandler(this.SnackbarMessage_ActionClick));
- return;
- }
- }
- this._contentLoaded = true;
- }
-
- private void ValidarButton_OnClick(object sender, RoutedEventArgs e)
- {
- object selectedItem = this.InstalacoesView.SelectedItem;
- if (selectedItem != null)
- {
- DialogHost.CloseDialogCommand.Execute((Instalacao)selectedItem, this.ValidarButton);
- return;
- }
- this.Snackbar.get_Message().Content = "SELECIONE A INSTALAÇÃO A SER SUBSTITUÍDA";
- this.Snackbar.set_IsActive(true);
- }
- }
-}
\ No newline at end of file |