X-Git-Url: http://de.git.xonotic.org/?a=blobdiff_plain;f=qcsrc%2Fmenu%2Fxonotic%2Fdialog_settings_user.qc;h=fc6521c4d2b9a7bd03e9b567ceecb9dd6f9247d2;hb=42e255d014f2c6a1871177ea511f630624cdfb57;hp=93002ba02c5f4cf9b52576eee3f521486f01129f;hpb=7bcb3a89b3271e018da4d92437dc5ba125ea8698;p=xonotic%2Fxonotic-data.pk3dir.git diff --git a/qcsrc/menu/xonotic/dialog_settings_user.qc b/qcsrc/menu/xonotic/dialog_settings_user.qc index 93002ba02..fc6521c4d 100644 --- a/qcsrc/menu/xonotic/dialog_settings_user.qc +++ b/qcsrc/menu/xonotic/dialog_settings_user.qc @@ -1,16 +1,11 @@ -#ifndef DIALOG_SETTINGS_USER_H -#define DIALOG_SETTINGS_USER_H -#include "tab.qc" -CLASS(XonoticUserSettingsTab, XonoticTab) - METHOD(XonoticUserSettingsTab, fill, void(entity)); - ATTRIB(XonoticUserSettingsTab, intendedWidth, float, 0.9) - ATTRIB(XonoticUserSettingsTab, rows, float, 15.5) - ATTRIB(XonoticUserSettingsTab, columns, float, 6) -ENDCLASS(XonoticUserSettingsTab) -entity makeXonoticUserSettingsTab(); -#endif +#include "dialog_settings_user.qh" + +#include "commandbutton.qh" +#include "textlabel.qh" +#include "languagelist.qh" +#include "skinlist.qh" +#include "checkbox.qh" -#ifdef IMPLEMENTATION entity makeXonoticUserSettingsTab() { entity me; @@ -21,8 +16,9 @@ entity makeXonoticUserSettingsTab() void XonoticUserSettingsTab_fill(entity me) { - entity e; - entity sk; + entity e, sk; + entity userApplyButton = makeXonoticCommandButton(_("Apply immediately"), '0 0 0', "sendcvar cl_gentle;", COMMANDBUTTON_APPLY); + userApplyButton.disableOnClick = true; me.TR(me); me.TDempty(me, 0.25); @@ -77,9 +73,9 @@ void XonoticUserSettingsTab_fill(entity me) me.gotoRC(me, 11.5, 3.25); me.setFirstColumn(me, me.currentColumn); me.TD(me, 1, 2.5, e = makeXonoticCheckBox_T(0, "cl_gentle", _("Disable gore effects and harsh language"), _("Replace blood and gibs with content that does not have any gore effects (default: disabled)"))); + e.applyButton = userApplyButton; me.gotoRC(me, me.rows - 1, 0); - me.TD(me, 1, 6, makeXonoticCommandButton(_("Apply immediately"), '0 0 0', "sendcvar cl_gentle;", COMMANDBUTTON_APPLY)); + me.TD(me, 1, 6, userApplyButton); } -#endif