Skip to content

Commit

Permalink
Removed transform field, no message displayed anymore.
Browse files Browse the repository at this point in the history
  • Loading branch information
DocMoebiuz committed Sep 1, 2023
1 parent 9eddf53 commit a6b4cbc
Show file tree
Hide file tree
Showing 7 changed files with 5 additions and 219 deletions.
4 changes: 0 additions & 4 deletions UI/Panels/Config/FsuipcConfigPanel.cs
Original file line number Diff line number Diff line change
Expand Up @@ -183,7 +183,6 @@ private void updateByteSizeComboBox()
fsuipcSizeComboBox.Enabled = true;
fsuipcSizeComboBox.Visible = true;
maskAndBcdPanel.Visible = true;
transformOptionsGroup1.ShowMultiplyPanel(true && OutputPanelMode);

if ((fsuipcOffsetTypeComboBox.SelectedItem as ListItem).Value == FSUIPCOffsetType.Integer.ToString())
{
Expand Down Expand Up @@ -224,9 +223,6 @@ private void updateByteSizeComboBox()

// mask doesn't make sense for strings
maskAndBcdPanel.Visible = false;

// multiply doesn't make sense for strings
transformOptionsGroup1.ShowMultiplyPanel(true && OutputPanelMode);
}
}

Expand Down
15 changes: 0 additions & 15 deletions UI/Panels/Config/SimConnectPanel.Designer.cs

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

8 changes: 0 additions & 8 deletions UI/Panels/Config/SimConnectPanel.cs
Original file line number Diff line number Diff line change
Expand Up @@ -11,11 +11,6 @@ public SimConnectPanel()
{
InitializeComponent();

transformOptionsGroup1.setMode(true);
transformOptionsGroup1.ModifyTabLink += (s, e) => {
ModifyTabLink?.Invoke(this, e);
};

HubHopPresetPanel.Mode = Config.HubHopPanelMode.Output;
HubHopPresetPanel.FlightSimType = FlightSimType.MSFS2020;
HubHopPresetPanel.LoadPresets();
Expand All @@ -24,13 +19,10 @@ public SimConnectPanel()
internal void syncToConfig(OutputConfigItem config)
{
HubHopPresetPanel.syncToConfig(config);
transformOptionsGroup1.syncToConfig(config);
}

internal void syncFromConfig(OutputConfigItem config)
{
// Sync the transform panel
transformOptionsGroup1.syncFromConfig(config);
HubHopPresetPanel.syncFromConfig(config);
}
}
Expand Down
39 changes: 0 additions & 39 deletions UI/Panels/Config/TransformOptionsGroup.Designer.cs

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

10 changes: 2 additions & 8 deletions UI/Panels/Config/TransformOptionsGroup.cs
Original file line number Diff line number Diff line change
Expand Up @@ -23,25 +23,19 @@ public TransformOptionsGroup()
public void setMode(bool isOutputPanel)
{
PanelMode = isOutputPanel;
// the transform field only is visible
// if we are dealing with outputs
MultiplyPanel.Visible = PanelMode;

// and the value panel vice versa
// only if we deal with inputs
ValuePanel.Visible = !PanelMode;
fsuipcMoreOptionsGroupBox.Visible = !PanelMode;

AutoSize = isOutputPanel;
}

public void ShowMultiplyPanel(bool visible)
{
MultiplyPanel.Visible = visible;
}

public void ShowValuePanel(bool visible)
{
ValuePanel.Visible = visible;
fsuipcMoreOptionsGroupBox.Visible = visible;
}

internal void syncFromConfig(OutputConfigItem config)
Expand Down
147 changes: 3 additions & 144 deletions UI/Panels/Config/TransformOptionsGroup.resx
Original file line number Diff line number Diff line change
Expand Up @@ -217,7 +217,7 @@
<value>Top</value>
</data>
<data name="ValuePanel.Location" type="System.Drawing.Point, System.Drawing">
<value>3, 38</value>
<value>3, 16</value>
</data>
<data name="ValuePanel.Size" type="System.Drawing.Size, System.Drawing">
<value>344, 62</value>
Expand All @@ -237,155 +237,14 @@
<data name="&gt;&gt;ValuePanel.ZOrder" xml:space="preserve">
<value>0</value>
</data>
<data name="MultiplyPanel.AutoSize" type="System.Boolean, mscorlib">
<value>True</value>
</data>
<data name="MultiplyPanel.AutoSizeMode" type="System.Windows.Forms.AutoSizeMode, System.Windows.Forms">
<value>GrowAndShrink</value>
</data>
<data name="label1.AutoSize" type="System.Boolean, mscorlib">
<value>True</value>
</data>
<data name="label1.Dock" type="System.Windows.Forms.DockStyle, System.Windows.Forms">
<value>Fill</value>
</data>
<data name="label1.ImageAlign" type="System.Drawing.ContentAlignment, System.Drawing">
<value>MiddleRight</value>
</data>
<data name="label1.ImeMode" type="System.Windows.Forms.ImeMode, System.Windows.Forms">
<value>NoControl</value>
</data>
<data name="label1.Location" type="System.Drawing.Point, System.Drawing">
<value>3, 0</value>
</data>
<data name="label1.Margin" type="System.Windows.Forms.Padding, System.Windows.Forms">
<value>3, 0, 0, 0</value>
</data>
<data name="label1.Size" type="System.Drawing.Size, System.Drawing">
<value>124, 13</value>
</data>
<data name="label1.TabIndex" type="System.Int32, mscorlib">
<value>19</value>
</data>
<data name="label1.Text" xml:space="preserve">
<value>Transform has moved to </value>
</data>
<data name="label1.TextAlign" type="System.Drawing.ContentAlignment, System.Drawing">
<value>MiddleLeft</value>
</data>
<data name="&gt;&gt;label1.Name" xml:space="preserve">
<value>label1</value>
</data>
<data name="&gt;&gt;label1.Type" xml:space="preserve">
<value>System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</data>
<data name="&gt;&gt;label1.Parent" xml:space="preserve">
<value>flowLayoutPanel1</value>
</data>
<data name="&gt;&gt;label1.ZOrder" xml:space="preserve">
<value>0</value>
</data>
<data name="label2.AutoSize" type="System.Boolean, mscorlib">
<value>True</value>
</data>
<data name="label2.ImageAlign" type="System.Drawing.ContentAlignment, System.Drawing">
<value>MiddleRight</value>
</data>
<data name="label2.ImeMode" type="System.Windows.Forms.ImeMode, System.Windows.Forms">
<value>NoControl</value>
</data>
<data name="label2.Location" type="System.Drawing.Point, System.Drawing">
<value>127, 0</value>
</data>
<data name="label2.Margin" type="System.Windows.Forms.Padding, System.Windows.Forms">
<value>0, 0, 0, 0</value>
</data>
<data name="label2.Size" type="System.Drawing.Size, System.Drawing">
<value>60, 13</value>
</data>
<data name="label2.TabIndex" type="System.Int32, mscorlib">
<value>20</value>
</data>
<data name="label2.Text" xml:space="preserve">
<value>Modify-Tab</value>
</data>
<data name="label2.TextAlign" type="System.Drawing.ContentAlignment, System.Drawing">
<value>MiddleLeft</value>
</data>
<data name="&gt;&gt;label2.Name" xml:space="preserve">
<value>label2</value>
</data>
<data name="&gt;&gt;label2.Type" xml:space="preserve">
<value>System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</data>
<data name="&gt;&gt;label2.Parent" xml:space="preserve">
<value>flowLayoutPanel1</value>
</data>
<data name="&gt;&gt;label2.ZOrder" xml:space="preserve">
<value>1</value>
</data>
<data name="flowLayoutPanel1.Dock" type="System.Windows.Forms.DockStyle, System.Windows.Forms">
<value>Top</value>
</data>
<data name="flowLayoutPanel1.Location" type="System.Drawing.Point, System.Drawing">
<value>150, 0</value>
</data>
<data name="flowLayoutPanel1.Size" type="System.Drawing.Size, System.Drawing">
<value>194, 22</value>
</data>
<data name="flowLayoutPanel1.TabIndex" type="System.Int32, mscorlib">
<value>21</value>
</data>
<data name="&gt;&gt;flowLayoutPanel1.Name" xml:space="preserve">
<value>flowLayoutPanel1</value>
</data>
<data name="&gt;&gt;flowLayoutPanel1.Type" xml:space="preserve">
<value>System.Windows.Forms.FlowLayoutPanel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</data>
<data name="&gt;&gt;flowLayoutPanel1.Parent" xml:space="preserve">
<value>MultiplyPanel</value>
</data>
<data name="&gt;&gt;flowLayoutPanel1.ZOrder" xml:space="preserve">
<value>0</value>
</data>
<data name="MultiplyPanel.Dock" type="System.Windows.Forms.DockStyle, System.Windows.Forms">
<value>Top</value>
</data>
<data name="MultiplyPanel.Location" type="System.Drawing.Point, System.Drawing">
<value>3, 16</value>
</data>
<data name="MultiplyPanel.MinimumSize" type="System.Drawing.Size, System.Drawing">
<value>0, 20</value>
</data>
<data name="MultiplyPanel.Padding" type="System.Windows.Forms.Padding, System.Windows.Forms">
<value>150, 0, 0, 0</value>
</data>
<data name="MultiplyPanel.Size" type="System.Drawing.Size, System.Drawing">
<value>344, 22</value>
</data>
<data name="MultiplyPanel.TabIndex" type="System.Int32, mscorlib">
<value>15</value>
</data>
<data name="&gt;&gt;MultiplyPanel.Name" xml:space="preserve">
<value>MultiplyPanel</value>
</data>
<data name="&gt;&gt;MultiplyPanel.Type" xml:space="preserve">
<value>System.Windows.Forms.Panel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</data>
<data name="&gt;&gt;MultiplyPanel.Parent" xml:space="preserve">
<value>fsuipcMoreOptionsGroupBox</value>
</data>
<data name="&gt;&gt;MultiplyPanel.ZOrder" xml:space="preserve">
<value>1</value>
</data>
<data name="fsuipcMoreOptionsGroupBox.Dock" type="System.Windows.Forms.DockStyle, System.Windows.Forms">
<value>Top</value>
</data>
<data name="fsuipcMoreOptionsGroupBox.Location" type="System.Drawing.Point, System.Drawing">
<value>0, 0</value>
</data>
<data name="fsuipcMoreOptionsGroupBox.Size" type="System.Drawing.Size, System.Drawing">
<value>350, 103</value>
<value>350, 81</value>
</data>
<data name="fsuipcMoreOptionsGroupBox.TabIndex" type="System.Int32, mscorlib">
<value>22</value>
Expand Down Expand Up @@ -421,7 +280,7 @@
<value>350, 0</value>
</data>
<data name="$this.Size" type="System.Drawing.Size, System.Drawing">
<value>350, 103</value>
<value>350, 81</value>
</data>
<data name="&gt;&gt;$this.Name" xml:space="preserve">
<value>TransformOptionsGroup</value>
Expand Down
1 change: 0 additions & 1 deletion UI/Panels/Config/VariablePanel.cs
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,6 @@ internal void syncFromConfig(OutputConfigItem config)

private void TypeComboBox_SelectedIndexChanged(object sender, EventArgs e)
{
transformOptionsGroup1.ShowMultiplyPanel(MobiFlightVariable.TYPE_NUMBER == (sender as ComboBox).SelectedValue.ToString());
}

private void NameTextBox_SelectedValueChanged(object sender, EventArgs e)
Expand Down

0 comments on commit a6b4cbc

Please sign in to comment.