mirror of
https://github.com/openhardwaremonitor/openhardwaremonitor
synced 2025-09-04 08:15:09 +00:00
Added support for sensor parameters. Fixed Core and Thread count detection for Intel Core i7 CPUs with disabled HyperThreading.
This commit is contained in:
5
GUI/AboutBox.Designer.cs
generated
5
GUI/AboutBox.Designer.cs
generated
@@ -122,9 +122,9 @@ namespace OpenHardwareMonitor.GUI {
|
||||
this.label3.Location = new System.Drawing.Point(86, 36);
|
||||
this.label3.Margin = new System.Windows.Forms.Padding(12, 0, 12, 0);
|
||||
this.label3.Name = "label3";
|
||||
this.label3.Size = new System.Drawing.Size(99, 15);
|
||||
this.label3.Size = new System.Drawing.Size(132, 15);
|
||||
this.label3.TabIndex = 4;
|
||||
this.label3.Text = "Version " + System.Windows.Forms.Application.ProductVersion + " Beta";
|
||||
this.label3.Text = "Version 9.0.30729.1 Beta";
|
||||
//
|
||||
// label4
|
||||
//
|
||||
@@ -189,6 +189,7 @@ namespace OpenHardwareMonitor.GUI {
|
||||
this.MaximizeBox = false;
|
||||
this.MinimizeBox = false;
|
||||
this.Name = "AboutBox";
|
||||
this.ShowInTaskbar = false;
|
||||
this.StartPosition = System.Windows.Forms.FormStartPosition.CenterParent;
|
||||
this.Text = "About";
|
||||
((System.ComponentModel.ISupportInitialize)(this.pictureBox1)).EndInit();
|
||||
|
23
GUI/MainForm.Designer.cs
generated
23
GUI/MainForm.Designer.cs
generated
@@ -103,12 +103,12 @@ namespace OpenHardwareMonitor.GUI {
|
||||
this.aboutToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
|
||||
this.timer = new System.Windows.Forms.Timer(this.components);
|
||||
this.splitContainer = new System.Windows.Forms.SplitContainer();
|
||||
this.plotPanel = new OpenHardwareMonitor.GUI.PlotPanel();
|
||||
this.notifyContextMenuStrip = new System.Windows.Forms.ContextMenuStrip(this.components);
|
||||
this.restoreToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
|
||||
this.toolStripMenuItem2 = new System.Windows.Forms.ToolStripSeparator();
|
||||
this.exitToolStripMenuItem1 = new System.Windows.Forms.ToolStripMenuItem();
|
||||
this.sensorContextMenuStrip = new System.Windows.Forms.ContextMenuStrip(this.components);
|
||||
this.plotPanel = new OpenHardwareMonitor.GUI.PlotPanel();
|
||||
this.columnsContextMenuStrip.SuspendLayout();
|
||||
this.menuStrip.SuspendLayout();
|
||||
this.splitContainer.Panel1.SuspendLayout();
|
||||
@@ -148,6 +148,7 @@ namespace OpenHardwareMonitor.GUI {
|
||||
this.treeView.TabIndex = 0;
|
||||
this.treeView.Text = "treeView";
|
||||
this.treeView.UseColumns = true;
|
||||
this.treeView.NodeMouseDoubleClick += new System.EventHandler<Aga.Controls.Tree.TreeNodeAdvMouseEventArgs>(this.treeView_NodeMouseDoubleClick);
|
||||
this.treeView.Click += new System.EventHandler(this.treeView_Click);
|
||||
//
|
||||
// sensor
|
||||
@@ -501,6 +502,16 @@ namespace OpenHardwareMonitor.GUI {
|
||||
this.splitContainer.SplitterWidth = 3;
|
||||
this.splitContainer.TabIndex = 3;
|
||||
//
|
||||
// plotPanel
|
||||
//
|
||||
this.plotPanel.BorderStyle = System.Windows.Forms.BorderStyle.Fixed3D;
|
||||
this.plotPanel.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||
this.plotPanel.Font = new System.Drawing.Font("Segoe UI", 9F);
|
||||
this.plotPanel.Location = new System.Drawing.Point(0, 0);
|
||||
this.plotPanel.Name = "plotPanel";
|
||||
this.plotPanel.Size = new System.Drawing.Size(478, 198);
|
||||
this.plotPanel.TabIndex = 0;
|
||||
//
|
||||
// notifyContextMenuStrip
|
||||
//
|
||||
this.notifyContextMenuStrip.Items.AddRange(new System.Windows.Forms.ToolStripItem[] {
|
||||
@@ -535,16 +546,6 @@ namespace OpenHardwareMonitor.GUI {
|
||||
this.sensorContextMenuStrip.Name = "sensorContextMenuStrip";
|
||||
this.sensorContextMenuStrip.Size = new System.Drawing.Size(61, 4);
|
||||
//
|
||||
// plotPanel
|
||||
//
|
||||
this.plotPanel.BorderStyle = System.Windows.Forms.BorderStyle.Fixed3D;
|
||||
this.plotPanel.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||
this.plotPanel.Font = new System.Drawing.Font("Segoe UI", 9F);
|
||||
this.plotPanel.Location = new System.Drawing.Point(0, 0);
|
||||
this.plotPanel.Name = "plotPanel";
|
||||
this.plotPanel.Size = new System.Drawing.Size(478, 198);
|
||||
this.plotPanel.TabIndex = 0;
|
||||
//
|
||||
// MainForm
|
||||
//
|
||||
this.AutoScaleDimensions = new System.Drawing.SizeF(7F, 15F);
|
||||
|
@@ -63,7 +63,7 @@ namespace OpenHardwareMonitor.GUI {
|
||||
InitializeComponent();
|
||||
this.Font = SystemFonts.MessageBoxFont;
|
||||
treeView.Font = SystemFonts.MessageBoxFont;
|
||||
plotPanel.Font = SystemFonts.MessageBoxFont;
|
||||
plotPanel.Font = SystemFonts.MessageBoxFont;
|
||||
|
||||
nodeCheckBox.IsVisibleValueNeeded +=
|
||||
new EventHandler<NodeControlValueEventArgs>(
|
||||
@@ -320,6 +320,13 @@ namespace OpenHardwareMonitor.GUI {
|
||||
if (node != null && node.Sensor != null) {
|
||||
|
||||
sensorContextMenuStrip.Items.Clear();
|
||||
if (node.Sensor.Parameters.Length > 0) {
|
||||
ToolStripMenuItem item = new ToolStripMenuItem("Parameters...");
|
||||
item.Click += delegate(object obj, EventArgs args) {
|
||||
ShowParameterForm(node.Sensor);
|
||||
};
|
||||
sensorContextMenuStrip.Items.Add(item);
|
||||
}
|
||||
if (sensorSystemTray.Contains(node.Sensor)) {
|
||||
ToolStripMenuItem item = new ToolStripMenuItem("Remove From Tray");
|
||||
item.Click += delegate(object obj, EventArgs args) {
|
||||
@@ -398,5 +405,21 @@ namespace OpenHardwareMonitor.GUI {
|
||||
|
||||
sensorSystemTray.Remove(sensor);
|
||||
}
|
||||
|
||||
private void ShowParameterForm(ISensor sensor) {
|
||||
ParameterForm form = new ParameterForm();
|
||||
form.Parameters = sensor.Parameters;
|
||||
form.captionLabel.Text = sensor.Name;
|
||||
form.ShowDialog();
|
||||
}
|
||||
|
||||
private void treeView_NodeMouseDoubleClick(object sender,
|
||||
TreeNodeAdvMouseEventArgs e) {
|
||||
SensorNode node = e.Node.Tag as SensorNode;
|
||||
if (node != null && node.Sensor != null &&
|
||||
node.Sensor.Parameters.Length > 0) {
|
||||
ShowParameterForm(node.Sensor);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
188
GUI/ParameterForm.Designer.cs
generated
Normal file
188
GUI/ParameterForm.Designer.cs
generated
Normal file
@@ -0,0 +1,188 @@
|
||||
namespace OpenHardwareMonitor.GUI {
|
||||
partial class ParameterForm {
|
||||
/// <summary>
|
||||
/// Required designer variable.
|
||||
/// </summary>
|
||||
private System.ComponentModel.IContainer components = null;
|
||||
|
||||
/// <summary>
|
||||
/// Clean up any resources being used.
|
||||
/// </summary>
|
||||
/// <param name="disposing">true if managed resources should be disposed; otherwise, false.</param>
|
||||
protected override void Dispose(bool disposing) {
|
||||
if (disposing && (components != null)) {
|
||||
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() {
|
||||
this.components = new System.ComponentModel.Container();
|
||||
System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle1 = new System.Windows.Forms.DataGridViewCellStyle();
|
||||
this.okButton = new System.Windows.Forms.Button();
|
||||
this.cancelButton = new System.Windows.Forms.Button();
|
||||
this.captionLabel = new System.Windows.Forms.Label();
|
||||
this.dataGridView = new System.Windows.Forms.DataGridView();
|
||||
this.NameColumn = new System.Windows.Forms.DataGridViewTextBoxColumn();
|
||||
this.Default = new System.Windows.Forms.DataGridViewCheckBoxColumn();
|
||||
this.ValueColumn = new System.Windows.Forms.DataGridViewTextBoxColumn();
|
||||
this.bindingSource = new System.Windows.Forms.BindingSource(this.components);
|
||||
this.descriptionLabel = new System.Windows.Forms.Label();
|
||||
((System.ComponentModel.ISupportInitialize)(this.dataGridView)).BeginInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.bindingSource)).BeginInit();
|
||||
this.SuspendLayout();
|
||||
//
|
||||
// okButton
|
||||
//
|
||||
this.okButton.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right)));
|
||||
this.okButton.DialogResult = System.Windows.Forms.DialogResult.OK;
|
||||
this.okButton.Location = new System.Drawing.Point(186, 213);
|
||||
this.okButton.Name = "okButton";
|
||||
this.okButton.Size = new System.Drawing.Size(75, 23);
|
||||
this.okButton.TabIndex = 2;
|
||||
this.okButton.Text = "OK";
|
||||
this.okButton.UseVisualStyleBackColor = true;
|
||||
this.okButton.Click += new System.EventHandler(this.okButton_Click);
|
||||
//
|
||||
// cancelButton
|
||||
//
|
||||
this.cancelButton.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right)));
|
||||
this.cancelButton.DialogResult = System.Windows.Forms.DialogResult.Cancel;
|
||||
this.cancelButton.Location = new System.Drawing.Point(267, 213);
|
||||
this.cancelButton.Name = "cancelButton";
|
||||
this.cancelButton.Size = new System.Drawing.Size(75, 23);
|
||||
this.cancelButton.TabIndex = 3;
|
||||
this.cancelButton.Text = "Canel";
|
||||
this.cancelButton.UseVisualStyleBackColor = true;
|
||||
//
|
||||
// captionLabel
|
||||
//
|
||||
this.captionLabel.AutoSize = true;
|
||||
this.captionLabel.Font = new System.Drawing.Font("Microsoft Sans Serif", 8.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
|
||||
this.captionLabel.Location = new System.Drawing.Point(12, 9);
|
||||
this.captionLabel.Name = "captionLabel";
|
||||
this.captionLabel.Size = new System.Drawing.Size(80, 13);
|
||||
this.captionLabel.TabIndex = 4;
|
||||
this.captionLabel.Text = "captionLabel";
|
||||
//
|
||||
// dataGridView
|
||||
//
|
||||
this.dataGridView.AllowUserToAddRows = false;
|
||||
this.dataGridView.AllowUserToDeleteRows = false;
|
||||
this.dataGridView.AllowUserToResizeRows = false;
|
||||
this.dataGridView.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
|
||||
| System.Windows.Forms.AnchorStyles.Left)
|
||||
| System.Windows.Forms.AnchorStyles.Right)));
|
||||
this.dataGridView.AutoGenerateColumns = false;
|
||||
this.dataGridView.AutoSizeColumnsMode = System.Windows.Forms.DataGridViewAutoSizeColumnsMode.Fill;
|
||||
this.dataGridView.BackgroundColor = System.Drawing.SystemColors.Window;
|
||||
this.dataGridView.BorderStyle = System.Windows.Forms.BorderStyle.Fixed3D;
|
||||
this.dataGridView.ColumnHeadersHeightSizeMode = System.Windows.Forms.DataGridViewColumnHeadersHeightSizeMode.AutoSize;
|
||||
this.dataGridView.Columns.AddRange(new System.Windows.Forms.DataGridViewColumn[] {
|
||||
this.NameColumn,
|
||||
this.Default,
|
||||
this.ValueColumn});
|
||||
this.dataGridView.DataSource = this.bindingSource;
|
||||
dataGridViewCellStyle1.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleLeft;
|
||||
dataGridViewCellStyle1.BackColor = System.Drawing.SystemColors.Window;
|
||||
dataGridViewCellStyle1.Font = new System.Drawing.Font("Microsoft Sans Serif", 8.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
|
||||
dataGridViewCellStyle1.ForeColor = System.Drawing.SystemColors.ControlText;
|
||||
dataGridViewCellStyle1.SelectionBackColor = System.Drawing.Color.FromArgb(((int)(((byte)(240)))), ((int)(((byte)(240)))), ((int)(((byte)(240)))));
|
||||
dataGridViewCellStyle1.SelectionForeColor = System.Drawing.SystemColors.ControlText;
|
||||
dataGridViewCellStyle1.WrapMode = System.Windows.Forms.DataGridViewTriState.False;
|
||||
this.dataGridView.DefaultCellStyle = dataGridViewCellStyle1;
|
||||
this.dataGridView.Location = new System.Drawing.Point(15, 30);
|
||||
this.dataGridView.MultiSelect = false;
|
||||
this.dataGridView.Name = "dataGridView";
|
||||
this.dataGridView.RowHeadersVisible = false;
|
||||
this.dataGridView.SelectionMode = System.Windows.Forms.DataGridViewSelectionMode.FullRowSelect;
|
||||
this.dataGridView.ShowRowErrors = false;
|
||||
this.dataGridView.Size = new System.Drawing.Size(327, 121);
|
||||
this.dataGridView.TabIndex = 0;
|
||||
this.dataGridView.RowEnter += new System.Windows.Forms.DataGridViewCellEventHandler(this.dataGridView_RowEnter);
|
||||
this.dataGridView.CellValidating += new System.Windows.Forms.DataGridViewCellValidatingEventHandler(this.dataGridView_CellValidating);
|
||||
this.dataGridView.CellEndEdit += new System.Windows.Forms.DataGridViewCellEventHandler(this.dataGridView_CellEndEdit);
|
||||
this.dataGridView.CurrentCellDirtyStateChanged += new System.EventHandler(this.dataGridView_CurrentCellDirtyStateChanged);
|
||||
//
|
||||
// NameColumn
|
||||
//
|
||||
this.NameColumn.DataPropertyName = "Name";
|
||||
this.NameColumn.HeaderText = "Name";
|
||||
this.NameColumn.Name = "NameColumn";
|
||||
this.NameColumn.ReadOnly = true;
|
||||
this.NameColumn.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.NotSortable;
|
||||
//
|
||||
// Default
|
||||
//
|
||||
this.Default.AutoSizeMode = System.Windows.Forms.DataGridViewAutoSizeColumnMode.ColumnHeader;
|
||||
this.Default.DataPropertyName = "Default";
|
||||
this.Default.HeaderText = "Default";
|
||||
this.Default.Name = "Default";
|
||||
this.Default.Width = 47;
|
||||
//
|
||||
// ValueColumn
|
||||
//
|
||||
this.ValueColumn.DataPropertyName = "Value";
|
||||
this.ValueColumn.HeaderText = "Value";
|
||||
this.ValueColumn.Name = "ValueColumn";
|
||||
this.ValueColumn.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.NotSortable;
|
||||
//
|
||||
// bindingSource
|
||||
//
|
||||
this.bindingSource.AllowNew = false;
|
||||
//
|
||||
// descriptionLabel
|
||||
//
|
||||
this.descriptionLabel.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left)
|
||||
| System.Windows.Forms.AnchorStyles.Right)));
|
||||
this.descriptionLabel.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle;
|
||||
this.descriptionLabel.Location = new System.Drawing.Point(15, 154);
|
||||
this.descriptionLabel.Name = "descriptionLabel";
|
||||
this.descriptionLabel.Padding = new System.Windows.Forms.Padding(2);
|
||||
this.descriptionLabel.Size = new System.Drawing.Size(327, 50);
|
||||
this.descriptionLabel.TabIndex = 6;
|
||||
this.descriptionLabel.Text = "descriptionLabel";
|
||||
//
|
||||
// ParameterForm
|
||||
//
|
||||
this.AcceptButton = this.okButton;
|
||||
this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
|
||||
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
|
||||
this.ClientSize = new System.Drawing.Size(354, 248);
|
||||
this.Controls.Add(this.descriptionLabel);
|
||||
this.Controls.Add(this.dataGridView);
|
||||
this.Controls.Add(this.captionLabel);
|
||||
this.Controls.Add(this.cancelButton);
|
||||
this.Controls.Add(this.okButton);
|
||||
this.Name = "ParameterForm";
|
||||
this.ShowIcon = false;
|
||||
this.ShowInTaskbar = false;
|
||||
this.StartPosition = System.Windows.Forms.FormStartPosition.CenterParent;
|
||||
this.Text = "Parameters";
|
||||
((System.ComponentModel.ISupportInitialize)(this.dataGridView)).EndInit();
|
||||
((System.ComponentModel.ISupportInitialize)(this.bindingSource)).EndInit();
|
||||
this.ResumeLayout(false);
|
||||
this.PerformLayout();
|
||||
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
private System.Windows.Forms.Button okButton;
|
||||
private System.Windows.Forms.Button cancelButton;
|
||||
public System.Windows.Forms.Label captionLabel;
|
||||
private System.Windows.Forms.DataGridView dataGridView;
|
||||
private System.Windows.Forms.Label descriptionLabel;
|
||||
private System.Windows.Forms.BindingSource bindingSource;
|
||||
private System.Windows.Forms.DataGridViewTextBoxColumn NameColumn;
|
||||
private System.Windows.Forms.DataGridViewCheckBoxColumn Default;
|
||||
private System.Windows.Forms.DataGridViewTextBoxColumn ValueColumn;
|
||||
|
||||
}
|
||||
}
|
122
GUI/ParameterForm.cs
Normal file
122
GUI/ParameterForm.cs
Normal file
@@ -0,0 +1,122 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.ComponentModel;
|
||||
using System.Text;
|
||||
using System.Windows.Forms;
|
||||
using OpenHardwareMonitor.Hardware;
|
||||
using OpenHardwareMonitor.Utilities;
|
||||
|
||||
namespace OpenHardwareMonitor.GUI {
|
||||
public partial class ParameterForm : Form {
|
||||
|
||||
private IReadOnlyArray<IParameter> parameters;
|
||||
private BindingList<ParameterRow> parameterRows;
|
||||
|
||||
public ParameterForm() {
|
||||
InitializeComponent();
|
||||
}
|
||||
|
||||
public IReadOnlyArray<IParameter> Parameters {
|
||||
get {
|
||||
return parameters;
|
||||
}
|
||||
set {
|
||||
parameters = value;
|
||||
parameterRows = new BindingList<ParameterRow>();
|
||||
foreach (IParameter parameter in parameters)
|
||||
parameterRows.Add(new ParameterRow(parameter));
|
||||
bindingSource.DataSource = parameterRows;
|
||||
}
|
||||
}
|
||||
|
||||
private class ParameterRow : INotifyPropertyChanged {
|
||||
public IParameter parameter;
|
||||
private float value;
|
||||
public bool isDefault;
|
||||
|
||||
public event PropertyChangedEventHandler PropertyChanged;
|
||||
|
||||
private void NotifyPropertyChanged(String propertyName) {
|
||||
if (PropertyChanged != null) {
|
||||
PropertyChanged(this, new PropertyChangedEventArgs(propertyName));
|
||||
}
|
||||
}
|
||||
|
||||
public ParameterRow(IParameter parameter){
|
||||
this.parameter = parameter;
|
||||
this.value = parameter.Value;
|
||||
this.isDefault = parameter.IsDefault;
|
||||
}
|
||||
|
||||
public string Name {
|
||||
get { return parameter.Name; }
|
||||
}
|
||||
|
||||
public float Value {
|
||||
get { return value; }
|
||||
set {
|
||||
this.isDefault = false;
|
||||
this.value = value;
|
||||
NotifyPropertyChanged("Default");
|
||||
NotifyPropertyChanged("Value");
|
||||
}
|
||||
}
|
||||
|
||||
public bool Default {
|
||||
get { return isDefault; }
|
||||
set {
|
||||
isDefault = value;
|
||||
if (value)
|
||||
this.value = parameter.DefaultValue;
|
||||
NotifyPropertyChanged("Default");
|
||||
NotifyPropertyChanged("Value");
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
private void dataGridView_RowEnter(object sender,
|
||||
DataGridViewCellEventArgs e)
|
||||
{
|
||||
if (e.RowIndex >= 0 && e.RowIndex < parameters.Length)
|
||||
descriptionLabel.Text = parameters[e.RowIndex].Description;
|
||||
else
|
||||
descriptionLabel.Text = "";
|
||||
}
|
||||
|
||||
private void dataGridView_CellValidating(object sender,
|
||||
DataGridViewCellValidatingEventArgs e)
|
||||
{
|
||||
float value;
|
||||
if (e.ColumnIndex == 2 &&
|
||||
!float.TryParse(e.FormattedValue.ToString(), out value)) {
|
||||
dataGridView.Rows[e.RowIndex].Cells[0].ErrorText =
|
||||
"Invalid value";
|
||||
e.Cancel = true;
|
||||
}
|
||||
}
|
||||
|
||||
private void dataGridView_CellEndEdit(object sender,
|
||||
DataGridViewCellEventArgs e) {
|
||||
dataGridView.Rows[e.RowIndex].Cells[0].ErrorText = "";
|
||||
}
|
||||
|
||||
private void okButton_Click(object sender, EventArgs e) {
|
||||
foreach (ParameterRow row in parameterRows) {
|
||||
if (row.Default) {
|
||||
row.parameter.IsDefault = true;
|
||||
} else {
|
||||
row.parameter.Value = row.Value;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
private void dataGridView_CurrentCellDirtyStateChanged(object sender,
|
||||
EventArgs e) {
|
||||
if (dataGridView.CurrentCell is DataGridViewCheckBoxCell ||
|
||||
dataGridView.CurrentCell is DataGridViewComboBoxCell)
|
||||
{
|
||||
dataGridView.CommitEdit(DataGridViewDataErrorContexts.Commit);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
132
GUI/ParameterForm.resx
Normal file
132
GUI/ParameterForm.resx
Normal file
@@ -0,0 +1,132 @@
|
||||
<?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=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
</resheader>
|
||||
<resheader name="writer">
|
||||
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
</resheader>
|
||||
<metadata name="NameColumn.UserAddedColumn" type="System.Boolean, mscorlib, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
|
||||
<value>True</value>
|
||||
</metadata>
|
||||
<metadata name="Default.UserAddedColumn" type="System.Boolean, mscorlib, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
|
||||
<value>True</value>
|
||||
</metadata>
|
||||
<metadata name="ValueColumn.UserAddedColumn" type="System.Boolean, mscorlib, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
|
||||
<value>True</value>
|
||||
</metadata>
|
||||
<metadata name="bindingSource.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
|
||||
<value>17, 17</value>
|
||||
</metadata>
|
||||
</root>
|
Reference in New Issue
Block a user