mirror of
https://github.com/KeyKeeperApp/KeyKeeper.git
synced 2026-05-02 12:56:31 +03:00
Задать ограничения размеров окна #3
This commit is contained in:
@@ -12,6 +12,9 @@ public class AboutWindow : Window
|
|||||||
this.Width = 600;
|
this.Width = 600;
|
||||||
this.Height = 400;
|
this.Height = 400;
|
||||||
|
|
||||||
|
this.MinWidth = 450;
|
||||||
|
this.MinHeight = 250;
|
||||||
|
|
||||||
this.Background = new SolidColorBrush(Color.Parse("#2328c4"));
|
this.Background = new SolidColorBrush(Color.Parse("#2328c4"));
|
||||||
|
|
||||||
var AboutKeyKeeper = new TextBlock
|
var AboutKeyKeeper = new TextBlock
|
||||||
|
|||||||
@@ -8,6 +8,8 @@ public class SettingsWindow : Window
|
|||||||
public SettingsWindow()
|
public SettingsWindow()
|
||||||
{
|
{
|
||||||
this.Title = "Settings";
|
this.Title = "Settings";
|
||||||
|
this.MinWidth = 500;
|
||||||
|
this.MinHeight = 400;
|
||||||
this.Width = 400;
|
this.Width = 400;
|
||||||
this.Height = 300;
|
this.Height = 300;
|
||||||
var textBlock = new TextBlock
|
var textBlock = new TextBlock
|
||||||
|
|||||||
@@ -16,6 +16,8 @@ namespace KeyKeeper.Views
|
|||||||
public CreateVaultFileWindow()
|
public CreateVaultFileWindow()
|
||||||
{
|
{
|
||||||
InitializeComponent();
|
InitializeComponent();
|
||||||
|
MinWidth = 450;
|
||||||
|
MinHeight = 350;
|
||||||
#if DEBUG
|
#if DEBUG
|
||||||
this.AttachDevTools();
|
this.AttachDevTools();
|
||||||
#endif
|
#endif
|
||||||
|
|||||||
@@ -16,6 +16,10 @@ public partial class EntryEditWindow : Window
|
|||||||
public EntryEditWindow()
|
public EntryEditWindow()
|
||||||
{
|
{
|
||||||
InitializeComponent();
|
InitializeComponent();
|
||||||
|
|
||||||
|
MinWidth = 500;
|
||||||
|
MinHeight = 400;
|
||||||
|
|
||||||
if (PasswordEdit != null)
|
if (PasswordEdit != null)
|
||||||
{
|
{
|
||||||
PasswordEdit.TextChanged += PasswordTextChanged;
|
PasswordEdit.TextChanged += PasswordTextChanged;
|
||||||
|
|||||||
@@ -8,6 +8,8 @@ public partial class ErrorDialog : Window
|
|||||||
public ErrorDialog(string message)
|
public ErrorDialog(string message)
|
||||||
{
|
{
|
||||||
InitializeComponent();
|
InitializeComponent();
|
||||||
|
MinWidth = 400;
|
||||||
|
MinHeight = 200;
|
||||||
MessageText.Text = message;
|
MessageText.Text = message;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -18,6 +18,8 @@ namespace KeyKeeper.Views
|
|||||||
public MainWindow()
|
public MainWindow()
|
||||||
{
|
{
|
||||||
InitializeComponent();
|
InitializeComponent();
|
||||||
|
this.MinWidth = 550;
|
||||||
|
this.MinHeight = 350;
|
||||||
}
|
}
|
||||||
|
|
||||||
private async void CreateNewVault_Click(object sender, RoutedEventArgs e)
|
private async void CreateNewVault_Click(object sender, RoutedEventArgs e)
|
||||||
@@ -80,8 +82,7 @@ namespace KeyKeeper.Views
|
|||||||
{
|
{
|
||||||
WindowStartupLocation = WindowStartupLocation.CenterScreen
|
WindowStartupLocation = WindowStartupLocation.CenterScreen
|
||||||
};
|
};
|
||||||
|
repositoryWindow.Closed += (s, e) => this.Close();
|
||||||
repositoryWindow.Closed += (s, e) => this.Show();
|
|
||||||
repositoryWindow.Show();
|
repositoryWindow.Show();
|
||||||
this.Hide();
|
this.Hide();
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -18,6 +18,10 @@ public partial class RepositoryWindow : Window
|
|||||||
public RepositoryWindow(RepositoryWindowViewModel model)
|
public RepositoryWindow(RepositoryWindowViewModel model)
|
||||||
{
|
{
|
||||||
InitializeComponent();
|
InitializeComponent();
|
||||||
|
|
||||||
|
MinWidth = 650;
|
||||||
|
MinHeight = 500;
|
||||||
|
|
||||||
DataContext = model;
|
DataContext = model;
|
||||||
model.ShowErrorPopup = async (string message) =>
|
model.ShowErrorPopup = async (string message) =>
|
||||||
{
|
{
|
||||||
|
|||||||
Reference in New Issue
Block a user