3.7 X11 collission with variable 'g'
This commit is contained in:
@@ -2583,12 +2583,12 @@ init_standard_windows()
|
|||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
nh_XtPopup(w, g, childwid)
|
nh_XtPopup(w, grb, childwid)
|
||||||
Widget w; /* widget */
|
Widget w; /* widget */
|
||||||
int g; /* type of grab */
|
int grb; /* type of grab */
|
||||||
Widget childwid; /* child to receive focus (can be None) */
|
Widget childwid; /* child to receive focus (can be None) */
|
||||||
{
|
{
|
||||||
XtPopup(w, (XtGrabKind) g);
|
XtPopup(w, (XtGrabKind) grb);
|
||||||
XSetWMProtocols(XtDisplay(w), XtWindow(w), &wm_delete_window, 1);
|
XSetWMProtocols(XtDisplay(w), XtWindow(w), &wm_delete_window, 1);
|
||||||
if (appResources.autofocus)
|
if (appResources.autofocus)
|
||||||
XtSetKeyboardFocus(toplevel, childwid);
|
XtSetKeyboardFocus(toplevel, childwid);
|
||||||
|
|||||||
@@ -500,7 +500,7 @@ X11_player_selection_randomize()
|
|||||||
{
|
{
|
||||||
int nrole = plsel_n_roles;
|
int nrole = plsel_n_roles;
|
||||||
int nrace = plsel_n_races;
|
int nrace = plsel_n_races;
|
||||||
int ro, ra, a, g;
|
int ro, ra, al, ge;
|
||||||
boolean fully_specified_role, choose_race_first;
|
boolean fully_specified_role, choose_race_first;
|
||||||
boolean picksomething = (flags.initrole == ROLE_NONE
|
boolean picksomething = (flags.initrole == ROLE_NONE
|
||||||
|| flags.initrace == ROLE_NONE
|
|| flags.initrace == ROLE_NONE
|
||||||
@@ -543,7 +543,7 @@ X11_player_selection_randomize()
|
|||||||
choose_race_first = TRUE;
|
choose_race_first = TRUE;
|
||||||
}
|
}
|
||||||
|
|
||||||
while (!validrace(ro,ra)) {
|
while (!validrace(ro, ra)) {
|
||||||
if (choose_race_first) {
|
if (choose_race_first) {
|
||||||
ro = rn2(nrole);
|
ro = rn2(nrole);
|
||||||
if (flags.initrole != ROLE_RANDOM) {
|
if (flags.initrole != ROLE_RANDOM) {
|
||||||
@@ -557,26 +557,26 @@ X11_player_selection_randomize()
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
g = flags.initgend;
|
ge = flags.initgend;
|
||||||
if (g == ROLE_NONE) {
|
if (ge == ROLE_NONE) {
|
||||||
g = rn2(ROLE_GENDERS);
|
ge = rn2(ROLE_GENDERS);
|
||||||
fully_specified_role = FALSE;
|
fully_specified_role = FALSE;
|
||||||
}
|
}
|
||||||
while (!validgend(ro,ra,g)) {
|
while (!validgend(ro, ra, ge)) {
|
||||||
g = rn2(ROLE_GENDERS);
|
ge = rn2(ROLE_GENDERS);
|
||||||
}
|
}
|
||||||
|
|
||||||
a = flags.initalign;
|
al = flags.initalign;
|
||||||
if (a == ROLE_NONE) {
|
if (al == ROLE_NONE) {
|
||||||
a = rn2(ROLE_ALIGNS);
|
al = rn2(ROLE_ALIGNS);
|
||||||
fully_specified_role = FALSE;
|
fully_specified_role = FALSE;
|
||||||
}
|
}
|
||||||
while (!validalign(ro,ra,a)) {
|
while (!validalign(ro, ra, al)) {
|
||||||
a = rn2(ROLE_ALIGNS);
|
al = rn2(ROLE_ALIGNS);
|
||||||
}
|
}
|
||||||
|
|
||||||
XawToggleSetCurrent(plsel_gend_radios[0], i2xtp(g + 1));
|
XawToggleSetCurrent(plsel_gend_radios[0], i2xtp(ge + 1));
|
||||||
XawToggleSetCurrent(plsel_align_radios[0], i2xtp(a + 1));
|
XawToggleSetCurrent(plsel_align_radios[0], i2xtp(al + 1));
|
||||||
XawToggleSetCurrent(plsel_race_radios[0], i2xtp(ra + 1));
|
XawToggleSetCurrent(plsel_race_radios[0], i2xtp(ra + 1));
|
||||||
XawToggleSetCurrent(plsel_role_radios[0], i2xtp(ro + 1));
|
XawToggleSetCurrent(plsel_role_radios[0], i2xtp(ro + 1));
|
||||||
plsel_set_sensitivities(FALSE);
|
plsel_set_sensitivities(FALSE);
|
||||||
|
|||||||
Reference in New Issue
Block a user