Can now select a data storage.

This commit is contained in:
Fey 2026-01-25 22:57:06 +01:00
parent 7094ae45d2
commit c83d69a200
4 changed files with 558 additions and 462 deletions

View File

@ -12,6 +12,7 @@ namespace Voile.Storage.Sqlite
{
[VoilePlugin]
[VoilePluginId(3)]
[DisplayName("SQLite")]
public class SqliteDataStorageFactory : IVoileDataStorageFactory
{
public IVoileDataStorage CreateDataStorage()

View File

@ -18,296 +18,332 @@
components.Dispose();
}
base.Dispose(disposing);
}
#region Windows Form Designer generated code
/// <summary>
/// Required method for Designer support - do not modify
/// the contents of this method with the code editor.
/// </summary>
private void InitializeComponent()
{
System.ComponentModel.ComponentResourceManager resources = new System.ComponentModel.ComponentResourceManager(typeof(FirstRunWizard));
pictureBox1 = new PictureBox();
tabControl1 = new TabControl();
tabPageWelcome = new TabPage();
label2 = new Label();
label1 = new Label();
radioButtonAmExpert = new RadioButton();
radioButtonAmBegginer = new RadioButton();
tabPageLicense = new TabPage();
pictureBox2 = new PictureBox();
label4 = new Label();
radioButtonNoLicense = new RadioButton();
buttonLoadLicenseFile = new Button();
buttonValidateLicense = new Button();
textBox1 = new TextBox();
radioButtonHasLicense = new RadioButton();
label3 = new Label();
buttonNext = new Button();
buttonBack = new Button();
openFileDialogCertificate = new OpenFileDialog();
tabPage1 = new TabPage();
label5 = new Label();
((System.ComponentModel.ISupportInitialize)pictureBox1).BeginInit();
tabControl1.SuspendLayout();
tabPageWelcome.SuspendLayout();
tabPageLicense.SuspendLayout();
((System.ComponentModel.ISupportInitialize)pictureBox2).BeginInit();
tabPage1.SuspendLayout();
SuspendLayout();
//
// pictureBox1
//
pictureBox1.Image = Properties.Resources.technlgy;
pictureBox1.Location = new Point(12, 12);
pictureBox1.Name = "pictureBox1";
pictureBox1.Size = new Size(120, 90);
pictureBox1.SizeMode = PictureBoxSizeMode.Zoom;
pictureBox1.TabIndex = 0;
pictureBox1.TabStop = false;
//
// tabControl1
//
tabControl1.Controls.Add(tabPageWelcome);
tabControl1.Controls.Add(tabPageLicense);
tabControl1.Controls.Add(tabPage1);
tabControl1.Location = new Point(138, 12);
tabControl1.Name = "tabControl1";
tabControl1.SelectedIndex = 0;
tabControl1.Size = new Size(356, 412);
tabControl1.TabIndex = 1;
//
// tabPageWelcome
//
tabPageWelcome.Controls.Add(label2);
tabPageWelcome.Controls.Add(label1);
tabPageWelcome.Controls.Add(radioButtonAmExpert);
tabPageWelcome.Controls.Add(radioButtonAmBegginer);
tabPageWelcome.Location = new Point(4, 24);
tabPageWelcome.Name = "tabPageWelcome";
tabPageWelcome.Padding = new Padding(3);
tabPageWelcome.Size = new Size(348, 384);
tabPageWelcome.TabIndex = 0;
tabPageWelcome.Text = "Welcome!";
tabPageWelcome.UseVisualStyleBackColor = true;
//
// label2
//
label2.AutoSize = true;
label2.Location = new Point(6, 3);
label2.Name = "label2";
label2.Size = new Size(328, 240);
label2.TabIndex = 3;
label2.Text = resources.GetString("label2.Text");
//
// label1
//
label1.AutoSize = true;
label1.Location = new Point(6, 308);
label1.Name = "label1";
label1.Size = new Size(202, 15);
label1.TabIndex = 2;
label1.Text = "(You can change these options later!)";
//
// radioButtonAmExpert
//
radioButtonAmExpert.AutoSize = true;
radioButtonAmExpert.Location = new Point(6, 271);
radioButtonAmExpert.Name = "radioButtonAmExpert";
radioButtonAmExpert.Size = new Size(299, 34);
radioButtonAmExpert.TabIndex = 1;
radioButtonAmExpert.Text = "Im an expert. Let me choose my own database and \r\nstorage options.";
radioButtonAmExpert.UseVisualStyleBackColor = true;
radioButtonAmExpert.CheckedChanged += radioButtonAmExpert_CheckedChanged;
//
// radioButtonAmBegginer
//
radioButtonAmBegginer.AutoSize = true;
radioButtonAmBegginer.Location = new Point(6, 246);
radioButtonAmBegginer.Name = "radioButtonAmBegginer";
radioButtonAmBegginer.Size = new Size(298, 19);
radioButtonAmBegginer.TabIndex = 0;
radioButtonAmBegginer.Text = "Im a beginner. Set things up for me automatically. ";
radioButtonAmBegginer.UseVisualStyleBackColor = true;
radioButtonAmBegginer.CheckedChanged += radioButtonAmBegginer_CheckedChanged;
//
// tabPageLicense
//
tabPageLicense.Controls.Add(pictureBox2);
tabPageLicense.Controls.Add(label4);
tabPageLicense.Controls.Add(radioButtonNoLicense);
tabPageLicense.Controls.Add(buttonLoadLicenseFile);
tabPageLicense.Controls.Add(buttonValidateLicense);
tabPageLicense.Controls.Add(textBox1);
tabPageLicense.Controls.Add(radioButtonHasLicense);
tabPageLicense.Controls.Add(label3);
tabPageLicense.Location = new Point(4, 24);
tabPageLicense.Name = "tabPageLicense";
tabPageLicense.Padding = new Padding(3);
tabPageLicense.Size = new Size(348, 384);
tabPageLicense.TabIndex = 1;
tabPageLicense.Text = "License";
tabPageLicense.UseVisualStyleBackColor = true;
//
// pictureBox2
//
pictureBox2.Image = Properties.Resources.SETUPAPI_18_1_32x32x4;
pictureBox2.Location = new Point(127, 262);
pictureBox2.Name = "pictureBox2";
pictureBox2.Size = new Size(32, 32);
pictureBox2.TabIndex = 7;
pictureBox2.TabStop = false;
pictureBox2.Click += pictureBox2_Click;
//
// label4
//
label4.AutoSize = true;
label4.Location = new Point(22, 344);
label4.Name = "label4";
label4.Size = new Size(299, 30);
label4.TabIndex = 6;
label4.Text = "(You can also change between Licensed and Shareware \r\nmode later!)";
//
// radioButtonNoLicense
//
radioButtonNoLicense.AutoSize = true;
radioButtonNoLicense.Location = new Point(6, 307);
radioButtonNoLicense.Name = "radioButtonNoLicense";
radioButtonNoLicense.Size = new Size(309, 34);
radioButtonNoLicense.TabIndex = 5;
radioButtonNoLicense.Text = "No license yet — Id like to use the shareware version, \r\nor request a license later.";
radioButtonNoLicense.UseVisualStyleBackColor = true;
radioButtonNoLicense.CheckedChanged += radioButtonNoLicense_CheckedChanged;
//
// buttonLoadLicenseFile
//
buttonLoadLicenseFile.Enabled = false;
buttonLoadLicenseFile.Location = new Point(246, 262);
buttonLoadLicenseFile.Name = "buttonLoadLicenseFile";
buttonLoadLicenseFile.Size = new Size(75, 39);
buttonLoadLicenseFile.TabIndex = 4;
buttonLoadLicenseFile.Text = "Load License File";
buttonLoadLicenseFile.UseVisualStyleBackColor = true;
buttonLoadLicenseFile.Click += buttonLoadLicenseFile_Click;
//
// buttonValidateLicense
//
buttonValidateLicense.Enabled = false;
buttonValidateLicense.Location = new Point(165, 262);
buttonValidateLicense.Name = "buttonValidateLicense";
buttonValidateLicense.Size = new Size(75, 39);
buttonValidateLicense.TabIndex = 3;
buttonValidateLicense.Text = "Validate License";
buttonValidateLicense.UseVisualStyleBackColor = true;
buttonValidateLicense.Click += buttonValidateLicense_Click;
//
// textBox1
//
textBox1.Enabled = false;
textBox1.Location = new Point(17, 233);
textBox1.Name = "textBox1";
textBox1.Size = new Size(304, 23);
textBox1.TabIndex = 2;
//
// radioButtonHasLicense
//
radioButtonHasLicense.AutoSize = true;
radioButtonHasLicense.Location = new Point(3, 208);
radioButtonHasLicense.Name = "radioButtonHasLicense";
radioButtonHasLicense.Size = new Size(189, 19);
radioButtonHasLicense.TabIndex = 1;
radioButtonHasLicense.Text = "Yes, I have a license file to load.";
radioButtonHasLicense.UseVisualStyleBackColor = true;
radioButtonHasLicense.CheckedChanged += radioButton3_CheckedChanged;
//
// label3
//
label3.AutoSize = true;
label3.Location = new Point(6, 3);
label3.Name = "label3";
label3.Size = new Size(337, 120);
label3.TabIndex = 0;
label3.Text = resources.GetString("label3.Text");
//
// buttonNext
//
buttonNext.Enabled = false;
buttonNext.Location = new Point(419, 430);
buttonNext.Name = "buttonNext";
buttonNext.Size = new Size(75, 23);
buttonNext.TabIndex = 2;
buttonNext.Text = "Next >";
buttonNext.UseVisualStyleBackColor = true;
buttonNext.Click += buttonNext_Click;
//
// buttonBack
//
buttonBack.Enabled = false;
buttonBack.Location = new Point(338, 430);
buttonBack.Name = "buttonBack";
buttonBack.Size = new Size(75, 23);
buttonBack.TabIndex = 3;
buttonBack.Text = "< Back";
buttonBack.UseVisualStyleBackColor = true;
//
// openFileDialogCertificate
//
openFileDialogCertificate.DefaultExt = "cer";
openFileDialogCertificate.FileName = "openFileDialog1";
openFileDialogCertificate.Filter = "X.509 Certificate (*.cer)|*.cer";
openFileDialogCertificate.Title = "Open Voile License File";
//
// tabPage1
//
tabPage1.Controls.Add(label5);
tabPage1.Location = new Point(4, 24);
tabPage1.Name = "tabPage1";
tabPage1.Size = new Size(348, 384);
tabPage1.TabIndex = 2;
tabPage1.Text = "Pick Data Storage";
tabPage1.UseVisualStyleBackColor = true;
//
// label5
//
label5.AutoSize = true;
label5.Location = new Point(3, 0);
label5.Name = "label5";
label5.Size = new Size(347, 165);
label5.TabIndex = 0;
label5.Text = resources.GetString("label5.Text");
//
// FirstRunWizard
//
AutoScaleDimensions = new SizeF(7F, 15F);
AutoScaleMode = AutoScaleMode.Font;
ClientSize = new Size(502, 465);
Controls.Add(buttonBack);
Controls.Add(buttonNext);
Controls.Add(tabControl1);
Controls.Add(pictureBox1);
FormBorderStyle = FormBorderStyle.FixedSingle;
MaximizeBox = false;
MinimizeBox = false;
Name = "FirstRunWizard";
ShowIcon = false;
Text = "Voile - First Run Wizard";
((System.ComponentModel.ISupportInitialize)pictureBox1).EndInit();
tabControl1.ResumeLayout(false);
tabPageWelcome.ResumeLayout(false);
tabPageWelcome.PerformLayout();
tabPageLicense.ResumeLayout(false);
tabPageLicense.PerformLayout();
((System.ComponentModel.ISupportInitialize)pictureBox2).EndInit();
tabPage1.ResumeLayout(false);
tabPage1.PerformLayout();
ResumeLayout(false);
}
#endregion
private PictureBox pictureBox1;
}
#region Windows Form Designer generated code
/// <summary>
/// Required method for Designer support - do not modify
/// the contents of this method with the code editor.
/// </summary>
private void InitializeComponent()
{
System.ComponentModel.ComponentResourceManager resources = new System.ComponentModel.ComponentResourceManager(typeof(FirstRunWizard));
pictureBox1 = new PictureBox();
tabControl1 = new TabControl();
tabPageWelcome = new TabPage();
label2 = new Label();
label1 = new Label();
radioButtonAmExpert = new RadioButton();
radioButtonAmBegginer = new RadioButton();
tabPageLicense = new TabPage();
pictureBox2 = new PictureBox();
label4 = new Label();
radioButtonNoLicense = new RadioButton();
buttonLoadLicenseFile = new Button();
buttonValidateLicense = new Button();
textBox1 = new TextBox();
radioButtonHasLicense = new RadioButton();
label3 = new Label();
tabPagePickDataStorage = new TabPage();
labelDataStorageHint = new Label();
label5 = new Label();
buttonNext = new Button();
buttonBack = new Button();
openFileDialogCertificate = new OpenFileDialog();
tabPageConfigureDataStorage = new TabPage();
label6 = new Label();
((System.ComponentModel.ISupportInitialize)pictureBox1).BeginInit();
tabControl1.SuspendLayout();
tabPageWelcome.SuspendLayout();
tabPageLicense.SuspendLayout();
((System.ComponentModel.ISupportInitialize)pictureBox2).BeginInit();
tabPagePickDataStorage.SuspendLayout();
tabPageConfigureDataStorage.SuspendLayout();
SuspendLayout();
//
// pictureBox1
//
pictureBox1.Image = Properties.Resources.technlgy;
pictureBox1.Location = new Point(12, 12);
pictureBox1.Name = "pictureBox1";
pictureBox1.Size = new Size(120, 90);
pictureBox1.SizeMode = PictureBoxSizeMode.Zoom;
pictureBox1.TabIndex = 0;
pictureBox1.TabStop = false;
//
// tabControl1
//
tabControl1.Controls.Add(tabPageWelcome);
tabControl1.Controls.Add(tabPageLicense);
tabControl1.Controls.Add(tabPagePickDataStorage);
tabControl1.Controls.Add(tabPageConfigureDataStorage);
tabControl1.Location = new Point(138, 12);
tabControl1.Name = "tabControl1";
tabControl1.SelectedIndex = 0;
tabControl1.Size = new Size(356, 412);
tabControl1.TabIndex = 1;
//
// tabPageWelcome
//
tabPageWelcome.Controls.Add(label2);
tabPageWelcome.Controls.Add(label1);
tabPageWelcome.Controls.Add(radioButtonAmExpert);
tabPageWelcome.Controls.Add(radioButtonAmBegginer);
tabPageWelcome.Location = new Point(4, 24);
tabPageWelcome.Name = "tabPageWelcome";
tabPageWelcome.Padding = new Padding(3);
tabPageWelcome.Size = new Size(348, 384);
tabPageWelcome.TabIndex = 0;
tabPageWelcome.Text = "Welcome!";
tabPageWelcome.UseVisualStyleBackColor = true;
//
// label2
//
label2.AutoSize = true;
label2.Location = new Point(6, 3);
label2.Name = "label2";
label2.Size = new Size(329, 240);
label2.TabIndex = 3;
label2.Text = resources.GetString("label2.Text");
//
// label1
//
label1.AutoSize = true;
label1.Location = new Point(6, 308);
label1.Name = "label1";
label1.Size = new Size(202, 15);
label1.TabIndex = 2;
label1.Text = "(You can change these options later!)";
//
// radioButtonAmExpert
//
radioButtonAmExpert.AutoSize = true;
radioButtonAmExpert.Location = new Point(6, 271);
radioButtonAmExpert.Name = "radioButtonAmExpert";
radioButtonAmExpert.Size = new Size(298, 34);
radioButtonAmExpert.TabIndex = 1;
radioButtonAmExpert.Text = "Im an expert. Let me choose my own database and \r\nstorage options.";
radioButtonAmExpert.UseVisualStyleBackColor = true;
radioButtonAmExpert.CheckedChanged += radioButtonAmExpert_CheckedChanged;
//
// radioButtonAmBegginer
//
radioButtonAmBegginer.AutoSize = true;
radioButtonAmBegginer.Location = new Point(6, 246);
radioButtonAmBegginer.Name = "radioButtonAmBegginer";
radioButtonAmBegginer.Size = new Size(298, 19);
radioButtonAmBegginer.TabIndex = 0;
radioButtonAmBegginer.Text = "Im a beginner. Set things up for me automatically. ";
radioButtonAmBegginer.UseVisualStyleBackColor = true;
radioButtonAmBegginer.CheckedChanged += radioButtonAmBegginer_CheckedChanged;
//
// tabPageLicense
//
tabPageLicense.Controls.Add(pictureBox2);
tabPageLicense.Controls.Add(label4);
tabPageLicense.Controls.Add(radioButtonNoLicense);
tabPageLicense.Controls.Add(buttonLoadLicenseFile);
tabPageLicense.Controls.Add(buttonValidateLicense);
tabPageLicense.Controls.Add(textBox1);
tabPageLicense.Controls.Add(radioButtonHasLicense);
tabPageLicense.Controls.Add(label3);
tabPageLicense.Location = new Point(4, 24);
tabPageLicense.Name = "tabPageLicense";
tabPageLicense.Padding = new Padding(3);
tabPageLicense.Size = new Size(348, 384);
tabPageLicense.TabIndex = 1;
tabPageLicense.Text = "License";
tabPageLicense.UseVisualStyleBackColor = true;
//
// pictureBox2
//
pictureBox2.Image = Properties.Resources.SETUPAPI_18_1_32x32x4;
pictureBox2.Location = new Point(127, 262);
pictureBox2.Name = "pictureBox2";
pictureBox2.Size = new Size(32, 32);
pictureBox2.TabIndex = 7;
pictureBox2.TabStop = false;
pictureBox2.Click += pictureBox2_Click;
//
// label4
//
label4.AutoSize = true;
label4.Location = new Point(22, 344);
label4.Name = "label4";
label4.Size = new Size(299, 30);
label4.TabIndex = 6;
label4.Text = "(You can also change between Licensed and Shareware \r\nmode later!)";
//
// radioButtonNoLicense
//
radioButtonNoLicense.AutoSize = true;
radioButtonNoLicense.Location = new Point(6, 307);
radioButtonNoLicense.Name = "radioButtonNoLicense";
radioButtonNoLicense.Size = new Size(309, 34);
radioButtonNoLicense.TabIndex = 5;
radioButtonNoLicense.Text = "No license yet — Id like to use the shareware version, \r\nor request a license later.";
radioButtonNoLicense.UseVisualStyleBackColor = true;
radioButtonNoLicense.CheckedChanged += radioButtonNoLicense_CheckedChanged;
//
// buttonLoadLicenseFile
//
buttonLoadLicenseFile.Enabled = false;
buttonLoadLicenseFile.Location = new Point(246, 262);
buttonLoadLicenseFile.Name = "buttonLoadLicenseFile";
buttonLoadLicenseFile.Size = new Size(75, 39);
buttonLoadLicenseFile.TabIndex = 4;
buttonLoadLicenseFile.Text = "Load License File";
buttonLoadLicenseFile.UseVisualStyleBackColor = true;
buttonLoadLicenseFile.Click += buttonLoadLicenseFile_Click;
//
// buttonValidateLicense
//
buttonValidateLicense.Enabled = false;
buttonValidateLicense.Location = new Point(165, 262);
buttonValidateLicense.Name = "buttonValidateLicense";
buttonValidateLicense.Size = new Size(75, 39);
buttonValidateLicense.TabIndex = 3;
buttonValidateLicense.Text = "Validate License";
buttonValidateLicense.UseVisualStyleBackColor = true;
buttonValidateLicense.Click += buttonValidateLicense_Click;
//
// textBox1
//
textBox1.Enabled = false;
textBox1.Location = new Point(17, 233);
textBox1.Name = "textBox1";
textBox1.Size = new Size(304, 23);
textBox1.TabIndex = 2;
//
// radioButtonHasLicense
//
radioButtonHasLicense.AutoSize = true;
radioButtonHasLicense.Location = new Point(3, 208);
radioButtonHasLicense.Name = "radioButtonHasLicense";
radioButtonHasLicense.Size = new Size(189, 19);
radioButtonHasLicense.TabIndex = 1;
radioButtonHasLicense.Text = "Yes, I have a license file to load.";
radioButtonHasLicense.UseVisualStyleBackColor = true;
radioButtonHasLicense.CheckedChanged += radioButton3_CheckedChanged;
//
// label3
//
label3.AutoSize = true;
label3.Location = new Point(6, 3);
label3.Name = "label3";
label3.Size = new Size(337, 120);
label3.TabIndex = 0;
label3.Text = resources.GetString("label3.Text");
//
// tabPagePickDataStorage
//
tabPagePickDataStorage.Controls.Add(labelDataStorageHint);
tabPagePickDataStorage.Controls.Add(label5);
tabPagePickDataStorage.Location = new Point(4, 24);
tabPagePickDataStorage.Name = "tabPagePickDataStorage";
tabPagePickDataStorage.Size = new Size(348, 384);
tabPagePickDataStorage.TabIndex = 2;
tabPagePickDataStorage.Text = "Pick Data Storage";
tabPagePickDataStorage.UseVisualStyleBackColor = true;
//
// labelDataStorageHint
//
labelDataStorageHint.AutoSize = true;
labelDataStorageHint.Location = new Point(3, 165);
labelDataStorageHint.Name = "labelDataStorageHint";
labelDataStorageHint.Size = new Size(124, 15);
labelDataStorageHint.TabIndex = 1;
labelDataStorageHint.Text = "DATA_STORAGE_HINT";
//
// label5
//
label5.AutoSize = true;
label5.Location = new Point(3, 0);
label5.Name = "label5";
label5.Size = new Size(347, 165);
label5.TabIndex = 0;
label5.Text = resources.GetString("label5.Text");
//
// buttonNext
//
buttonNext.Enabled = false;
buttonNext.Location = new Point(419, 430);
buttonNext.Name = "buttonNext";
buttonNext.Size = new Size(75, 23);
buttonNext.TabIndex = 2;
buttonNext.Text = "Next >";
buttonNext.UseVisualStyleBackColor = true;
buttonNext.Click += buttonNext_Click;
//
// buttonBack
//
buttonBack.Enabled = false;
buttonBack.Location = new Point(338, 430);
buttonBack.Name = "buttonBack";
buttonBack.Size = new Size(75, 23);
buttonBack.TabIndex = 3;
buttonBack.Text = "< Back";
buttonBack.UseVisualStyleBackColor = true;
//
// openFileDialogCertificate
//
openFileDialogCertificate.DefaultExt = "cer";
openFileDialogCertificate.FileName = "openFileDialog1";
openFileDialogCertificate.Filter = "X.509 Certificate (*.cer)|*.cer";
openFileDialogCertificate.Title = "Open Voile License File";
//
// tabPageConfigureDataStorage
//
tabPageConfigureDataStorage.Controls.Add(label6);
tabPageConfigureDataStorage.Location = new Point(4, 24);
tabPageConfigureDataStorage.Name = "tabPageConfigureDataStorage";
tabPageConfigureDataStorage.Size = new Size(348, 384);
tabPageConfigureDataStorage.TabIndex = 3;
tabPageConfigureDataStorage.Text = "Configure Date Storage";
tabPageConfigureDataStorage.UseVisualStyleBackColor = true;
//
// label6
//
label6.AutoSize = true;
label6.Location = new Point(3, 0);
label6.Name = "label6";
label6.Size = new Size(38, 15);
label6.TabIndex = 0;
label6.Text = "label6";
//
// FirstRunWizard
//
AutoScaleDimensions = new SizeF(7F, 15F);
AutoScaleMode = AutoScaleMode.Font;
ClientSize = new Size(502, 465);
Controls.Add(buttonBack);
Controls.Add(buttonNext);
Controls.Add(tabControl1);
Controls.Add(pictureBox1);
FormBorderStyle = FormBorderStyle.FixedSingle;
MaximizeBox = false;
MinimizeBox = false;
Name = "FirstRunWizard";
ShowIcon = false;
Text = "Voile - First Run Wizard";
((System.ComponentModel.ISupportInitialize)pictureBox1).EndInit();
tabControl1.ResumeLayout(false);
tabPageWelcome.ResumeLayout(false);
tabPageWelcome.PerformLayout();
tabPageLicense.ResumeLayout(false);
tabPageLicense.PerformLayout();
((System.ComponentModel.ISupportInitialize)pictureBox2).EndInit();
tabPagePickDataStorage.ResumeLayout(false);
tabPagePickDataStorage.PerformLayout();
tabPageConfigureDataStorage.ResumeLayout(false);
tabPageConfigureDataStorage.PerformLayout();
ResumeLayout(false);
}
#endregion
private PictureBox pictureBox1;
private TabControl tabControl1;
private TabPage tabPageWelcome;
private TabPage tabPageLicense;
@ -326,7 +362,10 @@
private Label label4;
private PictureBox pictureBox2;
private OpenFileDialog openFileDialogCertificate;
private TabPage tabPage1;
private Label label5;
}
private TabPage tabPagePickDataStorage;
private Label label5;
private Label labelDataStorageHint;
private TabPage tabPageConfigureDataStorage;
private Label label6;
}
}

View File

@ -33,8 +33,10 @@ namespace Voile
private int licenseState;
private X509Certificate licenseCertificate;
private bool sharewareMode;
private VoilePluginInfo selectedDataStorage;
private bool dataStorageRadioButtonsGenerated;
public void DisplayTabPage(int target, bool isGoingBack = false)
{
@ -113,22 +115,76 @@ namespace Voile
buttonNext.Enabled = (sharewareMode) | (licenseState == 6);
break;
case 2:
labelDataStorageHint.Text = " ";
if (!dataStorageRadioButtonsGenerated)
GenerateDataStorageRadioButtons();
GenerateDataStorageRadioButtons();
//TODO: Hier zusätzlich Lizenzvalidierung einfügen.
buttonNext.Enabled = selectedDataStorage != null;
break;
default:
MessageBox.Show("Could not find handler for the current tab page.");
return;
}
}
}
private bool dataStorageRadioButtonsGenerated;
private RadioButton[] dataStorageRadioButtons;
private void GenerateDataStorageRadioButtons()
{
VoilePluginManager pluginManager = VoilePluginManager.GetInstance();
IReadOnlyList<VoilePluginInfo> dataStoragePlugins = pluginManager.GetDataStorages();
//TODO: Finish generating the radio buttons for the data storage.
}
dataStorageRadioButtons = new RadioButton[dataStoragePlugins.Count];
int top = labelDataStorageHint.Top;
top += labelDataStorageHint.Height;
int left = labelDataStorageHint.Left;
for (int i = 0; i < dataStorageRadioButtons.Length; i++)
{
RadioButton childRadioButton = new RadioButton();
childRadioButton.Parent = tabPagePickDataStorage;
if (dataStoragePlugins[i].Incomplete)
childRadioButton.Enabled = false;
string radioButtonLabel = dataStoragePlugins[i].DisplayName;
if (dataStoragePlugins[i].NeededEntitlement.HasValue)
radioButtonLabel += " (needs license)";
childRadioButton.AutoSize = true;
childRadioButton.Text = radioButtonLabel;
if (selectedDataStorage != null)
childRadioButton.Checked = (selectedDataStorage.Id == dataStoragePlugins[i].Id);
childRadioButton.Top = top;
childRadioButton.Left = left;
childRadioButton.Tag = dataStoragePlugins[i];
top += childRadioButton.Height;
dataStorageRadioButtons[i] = childRadioButton;
dataStorageRadioButtons[i].CheckedChanged += OnDataStrorageSelected;
}
dataStorageRadioButtonsGenerated = true;
}
private void OnDataStrorageSelected(object? sender, EventArgs e)
{
RadioButton senderUnboxed = sender as RadioButton;
if (senderUnboxed == null)
throw new Voile.Common.VoileException("Could not unbox sender.");
VoilePluginInfo pluginInfo = senderUnboxed.Tag as VoilePluginInfo;
if (pluginInfo == null)
throw new Common.VoileException("Could not unbox plugin info");
selectedDataStorage = pluginInfo;
RefreshView();
}
private void radioButton3_CheckedChanged(object sender, EventArgs e)
{
RefreshView();

View File

@ -1,164 +1,164 @@
<?xml version="1.0" encoding="utf-8"?>
<root>
<!--
Microsoft ResX Schema
Version 2.0
The primary goals of this format is to allow a simple XML format
that is mostly human readable. The generation and parsing of the
various data types are done through the TypeConverter classes
associated with the data types.
Example:
... ado.net/XML headers & schema ...
<resheader name="resmimetype">text/microsoft-resx</resheader>
<resheader name="version">2.0</resheader>
<resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
<resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
<data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
<data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
<data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
<value>[base64 mime encoded serialized .NET Framework object]</value>
</data>
<data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
<value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>
<comment>This is a comment</comment>
</data>
There are any number of "resheader" rows that contain simple
name/value pairs.
Each data row contains a name, and value. The row also contains a
type or mimetype. Type corresponds to a .NET class that support
text/value conversion through the TypeConverter architecture.
Classes that don't support this are serialized and stored with the
mimetype set.
The mimetype is used for serialized objects, and tells the
ResXResourceReader how to depersist the object. This is currently not
extensible. For a given mimetype the value must be set accordingly:
Note - application/x-microsoft.net.object.binary.base64 is the format
that the ResXResourceWriter will generate, however the reader can
read any of the formats listed below.
mimetype: application/x-microsoft.net.object.binary.base64
value : The object must be serialized with
: System.Runtime.Serialization.Formatters.Binary.BinaryFormatter
: and then encoded with base64 encoding.
mimetype: application/x-microsoft.net.object.soap.base64
value : The object must be serialized with
: System.Runtime.Serialization.Formatters.Soap.SoapFormatter
: and then encoded with base64 encoding.
mimetype: application/x-microsoft.net.object.bytearray.base64
value : The object must be serialized into a byte array
: using a System.ComponentModel.TypeConverter
: and then encoded with base64 encoding.
-->
<xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
<xsd:import namespace="http://www.w3.org/XML/1998/namespace" />
<xsd:element name="root" msdata:IsDataSet="true">
<xsd:complexType>
<xsd:choice maxOccurs="unbounded">
<xsd:element name="metadata">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" />
</xsd:sequence>
<xsd:attribute name="name" use="required" type="xsd:string" />
<xsd:attribute name="type" type="xsd:string" />
<xsd:attribute name="mimetype" type="xsd:string" />
<xsd:attribute ref="xml:space" />
</xsd:complexType>
</xsd:element>
<xsd:element name="assembly">
<xsd:complexType>
<xsd:attribute name="alias" type="xsd:string" />
<xsd:attribute name="name" type="xsd:string" />
</xsd:complexType>
</xsd:element>
<xsd:element name="data">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
<xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" use="required" msdata:Ordinal="1" />
<xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
<xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
<xsd:attribute ref="xml:space" />
</xsd:complexType>
</xsd:element>
<xsd:element name="resheader">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" use="required" />
</xsd:complexType>
</xsd:element>
</xsd:choice>
</xsd:complexType>
</xsd:element>
</xsd:schema>
<resheader name="resmimetype">
<value>text/microsoft-resx</value>
</resheader>
<resheader name="version">
<value>2.0</value>
</resheader>
<resheader name="reader">
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<resheader name="writer">
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<data name="label5.Text" xml:space="preserve">
<value>Great — lets choose where Voile should store its
structured data.
Blindscan results, DVB table contents, and historical
scan information will all be kept in the storage option you select
below. Since youre using Expert Mode, you have full control
over the database backend. (In Beginner Mode, Voile would
simply use SQLite automatically.)
Feel free to pick the option that best fits your workflow or
existing infrastructure.</value>
</data>
<data name="label2.Text" xml:space="preserve">
<value>Welcome to Voile!
It looks like you're starting Voile for the first time.
Voile helps you catalogue and analyze your Transport Stream
(TS) recordings in a clear and organized way.
To store information about and manage your recordings
efficiently, Voile uses a database. If you also want Voile
to extract and save embedded files from your streams,
it can use a simple storage folder for that too.
No need to worry about the technical details.
If you're not familiar with databases, Voile can set everything
up automatically so you can start using the app right away.
How would you like to continue?</value>
</data>
<data name="label3.Text" xml:space="preserve">
<value>Before we continue, lets take a moment to set up your license.
Voile is available as shareware, which means you can use it
for free for personal, noncommercial projects. If youre using
Voile in a professional setting — or if youd simply like
to support the ongoing development — you can activate
a license. Some advanced features also become available
once a license is installed.</value>
</data>
<metadata name="openFileDialogCertificate.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
<value>17, 17</value>
</metadata>
<?xml version="1.0" encoding="utf-8"?>
<root>
<!--
Microsoft ResX Schema
Version 2.0
The primary goals of this format is to allow a simple XML format
that is mostly human readable. The generation and parsing of the
various data types are done through the TypeConverter classes
associated with the data types.
Example:
... ado.net/XML headers & schema ...
<resheader name="resmimetype">text/microsoft-resx</resheader>
<resheader name="version">2.0</resheader>
<resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
<resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
<data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
<data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
<data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
<value>[base64 mime encoded serialized .NET Framework object]</value>
</data>
<data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
<value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>
<comment>This is a comment</comment>
</data>
There are any number of "resheader" rows that contain simple
name/value pairs.
Each data row contains a name, and value. The row also contains a
type or mimetype. Type corresponds to a .NET class that support
text/value conversion through the TypeConverter architecture.
Classes that don't support this are serialized and stored with the
mimetype set.
The mimetype is used for serialized objects, and tells the
ResXResourceReader how to depersist the object. This is currently not
extensible. For a given mimetype the value must be set accordingly:
Note - application/x-microsoft.net.object.binary.base64 is the format
that the ResXResourceWriter will generate, however the reader can
read any of the formats listed below.
mimetype: application/x-microsoft.net.object.binary.base64
value : The object must be serialized with
: System.Runtime.Serialization.Formatters.Binary.BinaryFormatter
: and then encoded with base64 encoding.
mimetype: application/x-microsoft.net.object.soap.base64
value : The object must be serialized with
: System.Runtime.Serialization.Formatters.Soap.SoapFormatter
: and then encoded with base64 encoding.
mimetype: application/x-microsoft.net.object.bytearray.base64
value : The object must be serialized into a byte array
: using a System.ComponentModel.TypeConverter
: and then encoded with base64 encoding.
-->
<xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
<xsd:import namespace="http://www.w3.org/XML/1998/namespace" />
<xsd:element name="root" msdata:IsDataSet="true">
<xsd:complexType>
<xsd:choice maxOccurs="unbounded">
<xsd:element name="metadata">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" />
</xsd:sequence>
<xsd:attribute name="name" use="required" type="xsd:string" />
<xsd:attribute name="type" type="xsd:string" />
<xsd:attribute name="mimetype" type="xsd:string" />
<xsd:attribute ref="xml:space" />
</xsd:complexType>
</xsd:element>
<xsd:element name="assembly">
<xsd:complexType>
<xsd:attribute name="alias" type="xsd:string" />
<xsd:attribute name="name" type="xsd:string" />
</xsd:complexType>
</xsd:element>
<xsd:element name="data">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
<xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" use="required" msdata:Ordinal="1" />
<xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
<xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
<xsd:attribute ref="xml:space" />
</xsd:complexType>
</xsd:element>
<xsd:element name="resheader">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" use="required" />
</xsd:complexType>
</xsd:element>
</xsd:choice>
</xsd:complexType>
</xsd:element>
</xsd:schema>
<resheader name="resmimetype">
<value>text/microsoft-resx</value>
</resheader>
<resheader name="version">
<value>2.0</value>
</resheader>
<resheader name="reader">
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<resheader name="writer">
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<data name="label2.Text" xml:space="preserve">
<value>Welcome to Voile!
It looks like you're starting Voile for the first time.
Voile helps you catalogue and analyze your Transport Stream
(TS) recordings in a clear and organized way.
To store information about and manage your recordings
efficiently, Voile uses a database. If you also want Voile
to extract and save embedded files from your streams,
it can use a simple storage folder for that too.
No need to worry about the technical details.
If you're not familiar with databases, Voile can set everything
up automatically so you can start using the app right away.
How would you like to continue?</value>
</data>
<data name="label3.Text" xml:space="preserve">
<value>Before we continue, lets take a moment to set up your license.
Voile is available as shareware, which means you can use it
for free for personal, noncommercial projects. If youre using
Voile in a professional setting — or if youd simply like
to support the ongoing development — you can activate
a license. Some advanced features also become available
once a license is installed.</value>
</data>
<data name="label5.Text" xml:space="preserve">
<value>Great — lets choose where Voile should store its
structured data.
Blindscan results, DVB table contents, and historical
scan information will all be kept in the storage option you select
below. Since youre using Expert Mode, you have full control
over the database backend. (In Beginner Mode, Voile would
simply use SQLite automatically.)
Feel free to pick the option that best fits your workflow or
existing infrastructure.</value>
</data>
<metadata name="openFileDialogCertificate.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
<value>17, 17</value>
</metadata>
</root>