Increase scroll bars size for easier usage

This commit is contained in:
2021-07-15 21:57:34 +02:00
parent 4f03acb149
commit 2354bc9f4d
2 changed files with 3 additions and 8 deletions
+2 -2
View File
@@ -401,7 +401,7 @@ namespace FlaxEngine.GUI
if (VScrollBar != null)
{
float height = Height;
bool vScrollEnabled = (controlsBounds.Bottom > height + 0.01f || controlsBounds.Y < 0.0f) && height > ScrollBar.DefaultMinimumSize;
bool vScrollEnabled = (controlsBounds.Bottom > height + 0.01f || controlsBounds.Y < 0.0f) && height > ScrollBar.DefaultSize;
if (VScrollBar.Enabled != vScrollEnabled)
{
@@ -428,7 +428,7 @@ namespace FlaxEngine.GUI
if (HScrollBar != null)
{
float width = Width;
bool hScrollEnabled = (controlsBounds.Right > width + 0.01f || controlsBounds.X < 0.0f) && width > ScrollBar.DefaultMinimumSize;
bool hScrollEnabled = (controlsBounds.Right > width + 0.01f || controlsBounds.X < 0.0f) && width > ScrollBar.DefaultSize;
if (HScrollBar.Enabled != hScrollEnabled)
{
+1 -6
View File
@@ -14,18 +14,13 @@ namespace FlaxEngine.GUI
/// <summary>
/// The default size.
/// </summary>
public const int DefaultSize = 12;
public const int DefaultSize = 14;
/// <summary>
/// The default minimum opacity.
/// </summary>
public const float DefaultMinimumOpacity = 0.7f;
/// <summary>
/// The default minimum size.
/// </summary>
public const int DefaultMinimumSize = 12;
// Scrolling
private float _clickChange = 20, _scrollChange = 30;