This repository has been archived on 2025-09-26. You can view files and clone it. You cannot open issues or pull requests or push a commit.
Files
Password-Manager-Legacy/Password Manager/PasswordManagerForm.cs

29 lines
1.6 KiB
C#
Raw Normal View History

2023-03-27 09:17:06 +02:00
namespace Password_Manager
{
public delegate void ProfileChange(string profileName); //Fires when we want to change the CurrentProfile field of ProfileHandler based on the combobox selection
public delegate string[] ProfileList(); //Fires when we need a list of Profile names, like for the combobox items
public delegate void Save(); //Fire whenever we want to save the current state of profiles
public delegate void NewProfile(string profileName, string profilePath); //Fires whenever a NewProfileForm has requested the creation of a new profile. This just forwards that request to ProfileHandler
public abstract class PasswordManagerForm : Form
{
2023-03-27 09:30:41 +02:00
protected abstract ComboBox ProfileSelection { get; set; }
protected abstract PasswordListBox ResultList { get; set; }
protected abstract TextBox SearchBox { get; set; }
protected abstract Button AddProfile { get; set; }
protected abstract Button DeleteProfile { get; set; }
protected abstract Button GeneratePassword { get; set; }
2023-03-27 09:17:06 +02:00
public abstract event ProfileDataRequest CurrentProfilePathRequest;
public abstract event ProfileDataRequest CurrentProfileNameRequest;
public abstract event ProfileList CurrentProfileListRequest;
public abstract event ProfileChange CurrentProfileChanged;
public abstract event Save SaveRequest;
public abstract event NewProfile NewProfileRequest;
2023-03-27 09:30:41 +02:00
protected abstract void ChangeProfile(object sender, EventArgs e);
public abstract void RefreshCurrentProfile();
2023-03-27 09:17:06 +02:00
}
}