Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Allow custom hints in XGUI for time parameters #224

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Next Next commit
Remove hardcoded XGUI hint name for time arguments
Time arguments can be used for things other than ban lengths, but
having it like this would always show the hint in XGUI of
"Ban Length:".
  • Loading branch information
JoshuaLeivers committed Jul 2, 2024
commit 506797935ba582d00fc20af9081b8c62ca935806
2 changes: 1 addition & 1 deletion lua/ulx/modules/cl/xgui_helpers.lua
Original file line number Diff line number Diff line change
@@ -236,7 +236,7 @@ function xgui.load_helpers()
local max = restrictions.max or 10 * 60 * 24 * 365 --default slider max 10 years

local outPanel = xlib.makepanel{ h=40, parent=parent }
xlib.makelabel{ x=5, y=3, label="Ban Length:", parent=outPanel }
xlib.makelabel{ x=5, y=3, label=arg.hint or "Time:", parent=outPanel }
outPanel.interval = xlib.makecombobox{ x=90, w=75, parent=outPanel }
outPanel.val = xlib.makeslider{ w=165, y=20, label="<--->", min=min, max=max, value=min, decimal=0, parent=outPanel }