mirror of
https://github.com/xcp-ng/xenadmin.git
synced 2024-11-23 20:36:33 +01:00
CP-6856: Visual tweaks and other final changes (PR-1675)
# HG changeset patch # User Mihaela Stoica <Mihaela.Stoica@citrix.com> # Date 1383649813 0 # Tue Nov 05 11:10:13 2013 +0000 # Node ID 3db3c618115569e1b5bda10f2bf0c75ec387d9d4 # Parent e95bbc4697c45471e1732ae577249379dccdeb4e Signed-off-by: Konstantina Chremmou <konstantina.chremmou@citrix.com>
This commit is contained in:
parent
e7d951353a
commit
9aa03cd8c4
@ -253,7 +253,7 @@ namespace XenAdmin.Controls.Ballooning
|
||||
}
|
||||
}
|
||||
|
||||
protected Rectangle barRect
|
||||
protected virtual Rectangle barRect
|
||||
{
|
||||
get
|
||||
{
|
||||
|
20
XenAdmin/Controls/GPU/GpuRow.Designer.cs
generated
20
XenAdmin/Controls/GPU/GpuRow.Designer.cs
generated
@ -43,7 +43,6 @@
|
||||
this.shinyBarsContainerPanel = new System.Windows.Forms.TableLayoutPanel();
|
||||
this.editButton = new System.Windows.Forms.Button();
|
||||
this.multipleSelectionPanel = new System.Windows.Forms.Panel();
|
||||
this.editSelectedGpusButton = new System.Windows.Forms.Button();
|
||||
this.clearAllButton = new System.Windows.Forms.Button();
|
||||
this.selectAllButton = new System.Windows.Forms.Button();
|
||||
this.panelWithBorder.SuspendLayout();
|
||||
@ -105,6 +104,7 @@
|
||||
// allowedTypesGrid
|
||||
//
|
||||
this.allowedTypesGrid.AllowUserToResizeColumns = false;
|
||||
this.allowedTypesGrid.BackgroundColor = System.Drawing.SystemColors.Window;
|
||||
this.allowedTypesGrid.BorderStyle = System.Windows.Forms.BorderStyle.None;
|
||||
this.allowedTypesGrid.CellBorderStyle = System.Windows.Forms.DataGridViewCellBorderStyle.None;
|
||||
this.allowedTypesGrid.ColumnHeadersBorderStyle = System.Windows.Forms.DataGridViewHeaderBorderStyle.None;
|
||||
@ -114,16 +114,16 @@
|
||||
this.ImageColumn,
|
||||
this.TextColumn});
|
||||
dataGridViewCellStyle1.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleLeft;
|
||||
dataGridViewCellStyle1.BackColor = System.Drawing.Color.Transparent;
|
||||
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.SystemColors.Window;
|
||||
dataGridViewCellStyle1.SelectionForeColor = System.Drawing.SystemColors.ControlText;
|
||||
dataGridViewCellStyle1.WrapMode = System.Windows.Forms.DataGridViewTriState.False;
|
||||
this.allowedTypesGrid.DefaultCellStyle = dataGridViewCellStyle1;
|
||||
resources.ApplyResources(this.allowedTypesGrid, "allowedTypesGrid");
|
||||
this.allowedTypesGrid.GridColor = System.Drawing.SystemColors.Control;
|
||||
this.allowedTypesGrid.HideSelection = true;
|
||||
resources.ApplyResources(this.allowedTypesGrid, "allowedTypesGrid");
|
||||
this.allowedTypesGrid.Name = "allowedTypesGrid";
|
||||
this.allowedTypesGrid.ReadOnly = true;
|
||||
this.allowedTypesGrid.TabStop = false;
|
||||
@ -155,28 +155,19 @@
|
||||
//
|
||||
// editButton
|
||||
//
|
||||
this.editButton.BackColor = System.Drawing.Color.Transparent;
|
||||
resources.ApplyResources(this.editButton, "editButton");
|
||||
this.editButton.BackColor = System.Drawing.Color.Transparent;
|
||||
this.editButton.Name = "editButton";
|
||||
this.editButton.UseVisualStyleBackColor = false;
|
||||
this.editButton.Click += new System.EventHandler(this.editButton_Click);
|
||||
//
|
||||
// multipleSelectionPanel
|
||||
//
|
||||
this.multipleSelectionPanel.Controls.Add(this.editSelectedGpusButton);
|
||||
this.multipleSelectionPanel.Controls.Add(this.clearAllButton);
|
||||
this.multipleSelectionPanel.Controls.Add(this.selectAllButton);
|
||||
resources.ApplyResources(this.multipleSelectionPanel, "multipleSelectionPanel");
|
||||
this.multipleSelectionPanel.Name = "multipleSelectionPanel";
|
||||
//
|
||||
// editSelectedGpusButton
|
||||
//
|
||||
resources.ApplyResources(this.editSelectedGpusButton, "editSelectedGpusButton");
|
||||
this.editSelectedGpusButton.BackColor = System.Drawing.Color.Transparent;
|
||||
this.editSelectedGpusButton.Name = "editSelectedGpusButton";
|
||||
this.editSelectedGpusButton.UseVisualStyleBackColor = false;
|
||||
this.editSelectedGpusButton.Click += new System.EventHandler(this.editButton_Click);
|
||||
//
|
||||
// clearAllButton
|
||||
//
|
||||
resources.ApplyResources(this.clearAllButton, "clearAllButton");
|
||||
@ -223,8 +214,7 @@
|
||||
private System.Windows.Forms.Button selectAllButton;
|
||||
private PanelWithBorder panelWithBorder;
|
||||
protected System.Windows.Forms.Panel multipleSelectionPanel;
|
||||
protected System.Windows.Forms.Button editButton;
|
||||
protected System.Windows.Forms.Button editSelectedGpusButton;
|
||||
private System.Windows.Forms.TableLayoutPanel tableLayoutPanel1;
|
||||
private System.Windows.Forms.Button editButton;
|
||||
}
|
||||
}
|
||||
|
@ -42,14 +42,17 @@ namespace XenAdmin.Controls.GPU
|
||||
var oldControls = new List<Control>(shinyBarsContainerPanel.Controls.Count);
|
||||
oldControls.AddRange(shinyBarsContainerPanel.Controls.Cast<Control>());
|
||||
|
||||
bool showingHostLabel = connection.Cache.Hosts.Length > 1;
|
||||
|
||||
int index = 1;
|
||||
XenRef<Host> hostRef = null;
|
||||
|
||||
foreach (PGPU pgpu in pGpuList)
|
||||
{
|
||||
var host = connection.Resolve(pgpu.host);
|
||||
|
||||
// add host label if needed
|
||||
if (hostRef == null || pgpu.host.opaque_ref != hostRef.opaque_ref)
|
||||
if (showingHostLabel && (hostRef == null || pgpu.host.opaque_ref != hostRef.opaque_ref))
|
||||
{
|
||||
AddHostLabel(new Label { Text = String.Format(Messages.GPU_ON_HOST_LABEL, host.Name)}, ref index);
|
||||
hostRef = pgpu.host;
|
||||
@ -80,7 +83,7 @@ namespace XenAdmin.Controls.GPU
|
||||
{
|
||||
shinyBarsContainerPanel.Controls.Add(checkBox, 0, index);
|
||||
checkBox.Dock = DockStyle.Fill;
|
||||
checkBox.Margin = new Padding(3, 30, 0, 0);
|
||||
checkBox.Margin = new Padding(3, 14, 0, 0);
|
||||
checkBox.CheckedChanged += CheckedChanged;
|
||||
checkBox.Checked = true;
|
||||
}
|
||||
@ -108,7 +111,7 @@ namespace XenAdmin.Controls.GPU
|
||||
private void SetupPage()
|
||||
{
|
||||
multipleSelectionPanel.Visible = (pGpus.Count > 1);
|
||||
editButton.Visible = !multipleSelectionPanel.Visible;
|
||||
editButton.Text = (pGpus.Count > 1) ? "&Edit Selected GPUs..." : "&Edit...";
|
||||
}
|
||||
|
||||
private GpuShinyBar FindGpuShinyBar(PGPU pGpu)
|
||||
@ -177,7 +180,7 @@ namespace XenAdmin.Controls.GPU
|
||||
|
||||
private void CheckedChanged(object sender, EventArgs e)
|
||||
{
|
||||
editSelectedGpusButton.Enabled = clearAllButton.Enabled =
|
||||
editButton.Enabled = clearAllButton.Enabled =
|
||||
(pGpus.Values.Where(checkBox => checkBox != null).Any(checkBox => checkBox.Checked));
|
||||
selectAllButton.Enabled =
|
||||
(pGpus.Values.Where(checkBox => checkBox != null).Any(checkBox => !checkBox.Checked));
|
||||
@ -200,6 +203,7 @@ namespace XenAdmin.Controls.GPU
|
||||
orderby vGpuType.Capacity ascending
|
||||
select new VGpuTypeRow(vGpuType, enabledType)).ToArray());
|
||||
}
|
||||
allowedTypesGrid.Height = allowedTypesGrid.Rows[0].Height * (allowedTypesGrid.RowCount);
|
||||
}
|
||||
finally
|
||||
{
|
||||
|
@ -125,7 +125,7 @@
|
||||
AAEAAAD/////AQAAAAAAAAAMAgAAAFdTeXN0ZW0uV2luZG93cy5Gb3JtcywgVmVyc2lvbj0yLjAuMC4w
|
||||
LCBDdWx0dXJlPW5ldXRyYWwsIFB1YmxpY0tleVRva2VuPWI3N2E1YzU2MTkzNGUwODkFAQAAACZTeXN0
|
||||
ZW0uV2luZG93cy5Gb3Jtcy5JbWFnZUxpc3RTdHJlYW1lcgEAAAAERGF0YQcCAgAAAAkDAAAADwMAAABY
|
||||
CQAAAk1TRnQBSQFMAgEBAgEAAcgBAgHIAQIBEAEAARABAAT/AQkBAAj/AUIBTQE2AQQGAAE2AQQCAAEo
|
||||
CQAAAk1TRnQBSQFMAgEBAgEAAQgBAwEIAQMBEAEAARABAAT/AQkBAAj/AUIBTQE2AQQGAAE2AQQCAAEo
|
||||
AwABQAMAARADAAEBAQABCAYAAQQYAAGAAgABgAMAAoABAAGAAwABgAEAAYABAAKAAgADwAEAAcAB3AHA
|
||||
AQAB8AHKAaYBAAEzBQABMwEAATMBAAEzAQACMwIAAxYBAAMcAQADIgEAAykBAANVAQADTQEAA0IBAAM5
|
||||
AQABgAF8Af8BAAJQAf8BAAGTAQAB1gEAAf8B7AHMAQABxgHWAe8BAAHWAucBAAGQAakBrQIAAf8BMwMA
|
||||
@ -195,10 +195,10 @@
|
||||
<value>NoControl</value>
|
||||
</data>
|
||||
<data name="allowedTypesLabel.Location" type="System.Drawing.Point, System.Drawing">
|
||||
<value>460, 6</value>
|
||||
<value>470, 6</value>
|
||||
</data>
|
||||
<data name="allowedTypesLabel.Margin" type="System.Windows.Forms.Padding, System.Windows.Forms">
|
||||
<value>6, 6, 6, 0</value>
|
||||
<value>6, 6, 0, 3</value>
|
||||
</data>
|
||||
<data name="allowedTypesLabel.Size" type="System.Drawing.Size, System.Drawing">
|
||||
<value>217, 16</value>
|
||||
@ -234,13 +234,13 @@
|
||||
<value>NoControl</value>
|
||||
</data>
|
||||
<data name="pGpuLabel.Location" type="System.Drawing.Point, System.Drawing">
|
||||
<value>34, 6</value>
|
||||
<value>25, 6</value>
|
||||
</data>
|
||||
<data name="pGpuLabel.Margin" type="System.Windows.Forms.Padding, System.Windows.Forms">
|
||||
<value>6, 6, 6, 6</value>
|
||||
<value>3, 6, 3, 3</value>
|
||||
</data>
|
||||
<data name="pGpuLabel.Size" type="System.Drawing.Size, System.Drawing">
|
||||
<value>414, 16</value>
|
||||
<value>436, 16</value>
|
||||
</data>
|
||||
<data name="pGpuLabel.TabIndex" type="System.Int32, mscorlib">
|
||||
<value>16</value>
|
||||
@ -261,10 +261,10 @@
|
||||
<value>NoControl</value>
|
||||
</data>
|
||||
<data name="pGpuPictureBox.Location" type="System.Drawing.Point, System.Drawing">
|
||||
<value>6, 6</value>
|
||||
<value>3, 6</value>
|
||||
</data>
|
||||
<data name="pGpuPictureBox.Margin" type="System.Windows.Forms.Padding, System.Windows.Forms">
|
||||
<value>6, 6, 6, 6</value>
|
||||
<value>3, 6, 3, 3</value>
|
||||
</data>
|
||||
<data name="pGpuPictureBox.Size" type="System.Drawing.Size, System.Drawing">
|
||||
<value>16, 16</value>
|
||||
@ -305,17 +305,14 @@
|
||||
<data name="TextColumn.Width" type="System.Int32, mscorlib">
|
||||
<value>190</value>
|
||||
</data>
|
||||
<data name="allowedTypesGrid.Dock" type="System.Windows.Forms.DockStyle, System.Windows.Forms">
|
||||
<value>Fill</value>
|
||||
</data>
|
||||
<data name="allowedTypesGrid.Location" type="System.Drawing.Point, System.Drawing">
|
||||
<value>460, 28</value>
|
||||
<value>470, 25</value>
|
||||
</data>
|
||||
<data name="allowedTypesGrid.Margin" type="System.Windows.Forms.Padding, System.Windows.Forms">
|
||||
<value>6, 0, 6, 0</value>
|
||||
<value>6, 0, 0, 0</value>
|
||||
</data>
|
||||
<data name="allowedTypesGrid.Size" type="System.Drawing.Size, System.Drawing">
|
||||
<value>217, 93</value>
|
||||
<value>217, 59</value>
|
||||
</data>
|
||||
<data name="allowedTypesGrid.TabIndex" type="System.Int32, mscorlib">
|
||||
<value>21</value>
|
||||
@ -345,7 +342,10 @@
|
||||
<value>Fill</value>
|
||||
</data>
|
||||
<data name="shinyBarsContainerPanel.Location" type="System.Drawing.Point, System.Drawing">
|
||||
<value>3, 31</value>
|
||||
<value>1, 26</value>
|
||||
</data>
|
||||
<data name="shinyBarsContainerPanel.Margin" type="System.Windows.Forms.Padding, System.Windows.Forms">
|
||||
<value>1, 1, 1, 1</value>
|
||||
</data>
|
||||
<data name="shinyBarsContainerPanel.Padding" type="System.Windows.Forms.Padding, System.Windows.Forms">
|
||||
<value>1, 1, 1, 1</value>
|
||||
@ -354,7 +354,7 @@
|
||||
<value>1</value>
|
||||
</data>
|
||||
<data name="shinyBarsContainerPanel.Size" type="System.Drawing.Size, System.Drawing">
|
||||
<value>448, 121</value>
|
||||
<value>462, 95</value>
|
||||
</data>
|
||||
<data name="shinyBarsContainerPanel.TabIndex" type="System.Int32, mscorlib">
|
||||
<value>23</value>
|
||||
@ -372,19 +372,22 @@
|
||||
<value>4</value>
|
||||
</data>
|
||||
<data name="shinyBarsContainerPanel.LayoutSettings" type="System.Windows.Forms.TableLayoutSettings, System.Windows.Forms">
|
||||
<value><?xml version="1.0" encoding="utf-16"?><TableLayoutSettings><Controls /><Columns Styles="Absolute,24,AutoSize,0" /><Rows Styles="AutoSize,0" /></TableLayoutSettings></value>
|
||||
<value><?xml version="1.0" encoding="utf-16"?><TableLayoutSettings><Controls /><Columns Styles="Absolute,20,AutoSize,0" /><Rows Styles="AutoSize,0" /></TableLayoutSettings></value>
|
||||
</data>
|
||||
<data name="editButton.AutoSize" type="System.Boolean, mscorlib">
|
||||
<value>True</value>
|
||||
</data>
|
||||
<data name="editButton.ImeMode" type="System.Windows.Forms.ImeMode, System.Windows.Forms">
|
||||
<value>NoControl</value>
|
||||
</data>
|
||||
<data name="editButton.Location" type="System.Drawing.Point, System.Drawing">
|
||||
<value>460, 127</value>
|
||||
<value>470, 90</value>
|
||||
</data>
|
||||
<data name="editButton.Margin" type="System.Windows.Forms.Padding, System.Windows.Forms">
|
||||
<value>6, 6, 6, 6</value>
|
||||
</data>
|
||||
<data name="editButton.Size" type="System.Drawing.Size, System.Drawing">
|
||||
<value>66, 22</value>
|
||||
<value>66, 23</value>
|
||||
</data>
|
||||
<data name="editButton.TabIndex" type="System.Int32, mscorlib">
|
||||
<value>19</value>
|
||||
@ -414,7 +417,7 @@
|
||||
<value>3</value>
|
||||
</data>
|
||||
<data name="tableLayoutPanel1.Size" type="System.Drawing.Size, System.Drawing">
|
||||
<value>683, 155</value>
|
||||
<value>687, 122</value>
|
||||
</data>
|
||||
<data name="tableLayoutPanel1.TabIndex" type="System.Int32, mscorlib">
|
||||
<value>1</value>
|
||||
@ -432,40 +435,7 @@
|
||||
<value>0</value>
|
||||
</data>
|
||||
<data name="tableLayoutPanel1.LayoutSettings" type="System.Windows.Forms.TableLayoutSettings, System.Windows.Forms">
|
||||
<value><?xml version="1.0" encoding="utf-16"?><TableLayoutSettings><Controls><Control Name="allowedTypesLabel" Row="0" RowSpan="1" Column="2" ColumnSpan="1" /><Control Name="pGpuLabel" Row="0" RowSpan="1" Column="1" ColumnSpan="1" /><Control Name="pGpuPictureBox" Row="0" RowSpan="1" Column="0" ColumnSpan="1" /><Control Name="allowedTypesGrid" Row="1" RowSpan="1" Column="2" ColumnSpan="1" /><Control Name="shinyBarsContainerPanel" Row="1" RowSpan="2" Column="0" ColumnSpan="2" /><Control Name="editButton" Row="2" RowSpan="1" Column="2" ColumnSpan="1" /></Controls><Columns Styles="AutoSize,0,Percent,100,AutoSize,0" /><Rows Styles="AutoSize,0,AutoSize,0,AutoSize,0,Absolute,20" /></TableLayoutSettings></value>
|
||||
</data>
|
||||
<data name="editSelectedGpusButton.Anchor" type="System.Windows.Forms.AnchorStyles, System.Windows.Forms">
|
||||
<value>Top, Right</value>
|
||||
</data>
|
||||
<data name="editSelectedGpusButton.ImeMode" type="System.Windows.Forms.ImeMode, System.Windows.Forms">
|
||||
<value>NoControl</value>
|
||||
</data>
|
||||
<data name="editSelectedGpusButton.Location" type="System.Drawing.Point, System.Drawing">
|
||||
<value>460, 4</value>
|
||||
</data>
|
||||
<data name="editSelectedGpusButton.Margin" type="System.Windows.Forms.Padding, System.Windows.Forms">
|
||||
<value>6, 6, 6, 6</value>
|
||||
</data>
|
||||
<data name="editSelectedGpusButton.Size" type="System.Drawing.Size, System.Drawing">
|
||||
<value>130, 22</value>
|
||||
</data>
|
||||
<data name="editSelectedGpusButton.TabIndex" type="System.Int32, mscorlib">
|
||||
<value>27</value>
|
||||
</data>
|
||||
<data name="editSelectedGpusButton.Text" xml:space="preserve">
|
||||
<value>&Edit Selected GPUs...</value>
|
||||
</data>
|
||||
<data name=">>editSelectedGpusButton.Name" xml:space="preserve">
|
||||
<value>editSelectedGpusButton</value>
|
||||
</data>
|
||||
<data name=">>editSelectedGpusButton.Type" xml:space="preserve">
|
||||
<value>System.Windows.Forms.Button, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
</data>
|
||||
<data name=">>editSelectedGpusButton.Parent" xml:space="preserve">
|
||||
<value>multipleSelectionPanel</value>
|
||||
</data>
|
||||
<data name=">>editSelectedGpusButton.ZOrder" xml:space="preserve">
|
||||
<value>0</value>
|
||||
<value><?xml version="1.0" encoding="utf-16"?><TableLayoutSettings><Controls><Control Name="allowedTypesLabel" Row="0" RowSpan="1" Column="2" ColumnSpan="1" /><Control Name="pGpuLabel" Row="0" RowSpan="1" Column="1" ColumnSpan="1" /><Control Name="pGpuPictureBox" Row="0" RowSpan="1" Column="0" ColumnSpan="1" /><Control Name="allowedTypesGrid" Row="1" RowSpan="1" Column="2" ColumnSpan="1" /><Control Name="shinyBarsContainerPanel" Row="1" RowSpan="2" Column="0" ColumnSpan="2" /><Control Name="editButton" Row="2" RowSpan="1" Column="2" ColumnSpan="1" /></Controls><Columns Styles="AutoSize,0,Percent,100,AutoSize,0" /><Rows Styles="AutoSize,0,AutoSize,0,AutoSize,58,Absolute,20" /></TableLayoutSettings></value>
|
||||
</data>
|
||||
<data name="clearAllButton.ImeMode" type="System.Windows.Forms.ImeMode, System.Windows.Forms">
|
||||
<value>NoControl</value>
|
||||
@ -492,7 +462,7 @@
|
||||
<value>multipleSelectionPanel</value>
|
||||
</data>
|
||||
<data name=">>clearAllButton.ZOrder" xml:space="preserve">
|
||||
<value>1</value>
|
||||
<value>0</value>
|
||||
</data>
|
||||
<data name="selectAllButton.ImeMode" type="System.Windows.Forms.ImeMode, System.Windows.Forms">
|
||||
<value>NoControl</value>
|
||||
@ -519,16 +489,16 @@
|
||||
<value>multipleSelectionPanel</value>
|
||||
</data>
|
||||
<data name=">>selectAllButton.ZOrder" xml:space="preserve">
|
||||
<value>2</value>
|
||||
<value>1</value>
|
||||
</data>
|
||||
<data name="multipleSelectionPanel.Dock" type="System.Windows.Forms.DockStyle, System.Windows.Forms">
|
||||
<value>Bottom</value>
|
||||
</data>
|
||||
<data name="multipleSelectionPanel.Location" type="System.Drawing.Point, System.Drawing">
|
||||
<value>1, 156</value>
|
||||
<value>1, 123</value>
|
||||
</data>
|
||||
<data name="multipleSelectionPanel.Size" type="System.Drawing.Size, System.Drawing">
|
||||
<value>683, 31</value>
|
||||
<value>687, 31</value>
|
||||
</data>
|
||||
<data name="multipleSelectionPanel.TabIndex" type="System.Int32, mscorlib">
|
||||
<value>26</value>
|
||||
@ -558,7 +528,7 @@
|
||||
<value>1, 1, 1, 1</value>
|
||||
</data>
|
||||
<data name="panelWithBorder.Size" type="System.Drawing.Size, System.Drawing">
|
||||
<value>685, 188</value>
|
||||
<value>689, 155</value>
|
||||
</data>
|
||||
<data name="panelWithBorder.TabIndex" type="System.Int32, mscorlib">
|
||||
<value>3</value>
|
||||
@ -588,7 +558,7 @@
|
||||
<value>True</value>
|
||||
</data>
|
||||
<data name="$this.Size" type="System.Drawing.Size, System.Drawing">
|
||||
<value>685, 188</value>
|
||||
<value>689, 155</value>
|
||||
</data>
|
||||
<data name=">>allowedTypesImageList.Name" xml:space="preserve">
|
||||
<value>allowedTypesImageList</value>
|
||||
|
@ -109,6 +109,14 @@ namespace XenAdmin.Controls.GPU
|
||||
return 40;
|
||||
}
|
||||
}
|
||||
|
||||
protected override Rectangle barRect
|
||||
{
|
||||
get
|
||||
{
|
||||
return new Rectangle(10, 20, this.Width - 25, barHeight);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
public static class GpuShinyBarColors
|
||||
|
@ -125,7 +125,7 @@
|
||||
<value>96, 96</value>
|
||||
</data>
|
||||
<data name="$this.Size" type="System.Drawing.Size, System.Drawing">
|
||||
<value>500, 77</value>
|
||||
<value>500, 70</value>
|
||||
</data>
|
||||
<data name=">>$this.Name" xml:space="preserve">
|
||||
<value>GpuShinyBar</value>
|
||||
|
@ -86,7 +86,7 @@ namespace XenAPI
|
||||
if (supported_on_PGPUs != null && supported_on_PGPUs.Count > 0)
|
||||
{
|
||||
PGPU pgpu = Connection.Resolve(supported_on_PGPUs[0]);
|
||||
if (pgpu.supported_VGPU_max_capacities != null)
|
||||
if (pgpu.supported_VGPU_max_capacities != null && pgpu.supported_VGPU_max_capacities.Count > 0)
|
||||
{
|
||||
capacity = pgpu.supported_VGPU_max_capacities[new XenRef<VGPU_type>(this)];
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user