Improve jobs screen UX (#13657)
This commit is contained in:
@@ -410,7 +410,8 @@ namespace Content.Client.Preferences.UI
|
||||
new Label
|
||||
{
|
||||
Text = Loc.GetString("humanoid-profile-editor-department-jobs-label",
|
||||
("departmentName", departmentName))
|
||||
("departmentName", departmentName)),
|
||||
Margin = new Thickness(5f, 0, 0, 0)
|
||||
}
|
||||
}
|
||||
});
|
||||
@@ -1111,7 +1112,8 @@ namespace Content.Client.Preferences.UI
|
||||
ButtonStyle = StyleBase.ButtonOpenBoth,
|
||||
LastButtonStyle = StyleBase.ButtonOpenLeft
|
||||
};
|
||||
|
||||
//Override default radio option button width
|
||||
_optionButton.GenerateItem = GenerateButton;
|
||||
// Text, Value
|
||||
_optionButton.AddItem(Loc.GetString("humanoid-profile-editor-job-priority-high-button"), (int) JobPriority.High);
|
||||
_optionButton.AddItem(Loc.GetString("humanoid-profile-editor-job-priority-medium-button"), (int) JobPriority.Medium);
|
||||
@@ -1159,8 +1161,9 @@ namespace Content.Client.Preferences.UI
|
||||
|
||||
_jobTitle = new Label()
|
||||
{
|
||||
Margin = new Thickness(5f,0,5f,0),
|
||||
Text = job.LocalizedName,
|
||||
MinSize = (175, 0),
|
||||
MinSize = (180, 0),
|
||||
MouseFilter = MouseFilterMode.Stop
|
||||
};
|
||||
|
||||
@@ -1197,6 +1200,16 @@ namespace Content.Client.Preferences.UI
|
||||
_lockStripe.Visible = false;
|
||||
_optionButton.Visible = true;
|
||||
}
|
||||
|
||||
private Button GenerateButton(string text, int value)
|
||||
{
|
||||
var btn = new Button
|
||||
{
|
||||
Text = text,
|
||||
MinWidth = 90
|
||||
};
|
||||
return btn;
|
||||
}
|
||||
}
|
||||
|
||||
private void UpdateAntagPreferences()
|
||||
|
||||
Reference in New Issue
Block a user