swap
Fri Mar 15 2024 11:05:15 GMT+0000 (Coordinated Universal Time)
Saved by
@Simetra
private void CheckSuppExhPosition()
{
Point XtraTopLocation = new Point(xtraTabControl1.Location.X, xtraTabControl1.Location.Y);
Point XtraButtomLocation = new Point(xtraTabControl2.Location.X, xtraTabControl2.Location.Y);
Point GroupTopLocation = new Point(groupControl1.Location.X, groupControl1.Location.Y);
Point GrouoButtomLocation = new Point(groupControl2.Location.X, groupControl2.Location.Y);
if (Settings.GetUnit.SupplyPosition == "Top" || Settings.GetUnit.SupplyPosition == "Back")
{
xtraTabControl1.Location = XtraTopLocation;
xtraTabControl2.Location = XtraButtomLocation;
groupControl1.Location = GroupTopLocation;
groupControl2.Location = GrouoButtomLocation;
}
else if (Settings.GetUnit.SupplyPosition == "Bottom" || Settings.GetUnit.SupplyPosition == "Front")
{
xtraTabControl1.Location = XtraButtomLocation;
xtraTabControl2.Location = XtraTopLocation;
groupControl1.Location = GrouoButtomLocation;
groupControl2.Location = GroupTopLocation;
}
//refactor
if (Settings.GetUnit.SupplyPosition == "Bottom" || Settings.GetUnit.SupplyPosition == "Front")
{
(xtraTabControl1.Location, xtraTabControl2.Location) = (xtraTabControl2.Location, xtraTabControl1.Location);
(groupControl1.Location, groupControl2.Location) = (groupControl2.Location, groupControl1.Location);
}
}
content_copyCOPY
Comments