Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
Synchronet
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package registry
Container registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Main
Synchronet
Commits
cc7261b1
Commit
cc7261b1
authored
19 years ago
by
deuce
Browse files
Options
Downloads
Patches
Plain Diff
Replace simple easy flag/exempt/restriction input boxes with a zillion
separate buttons.
parent
31923ac9
Branches
Branches containing commit
Tags
Tags containing commit
No related merge requests found
Changes
2
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
src/sbbs3/gtkuseredit/events.c
+63
-42
63 additions, 42 deletions
src/sbbs3/gtkuseredit/events.c
src/sbbs3/gtkuseredit/gtkuseredit.glade
+3173
-253
3173 additions, 253 deletions
src/sbbs3/gtkuseredit/gtkuseredit.glade
with
3236 additions
and
295 deletions
src/sbbs3/gtkuseredit/events.c
+
63
−
42
View file @
cc7261b1
...
@@ -242,57 +242,78 @@ void load_user(GtkWidget *wiggy, gpointer data)
...
@@ -242,57 +242,78 @@ void load_user(GtkWidget *wiggy, gpointer data)
}
}
/* Flag Sets */
/* Flag Sets */
w
=
glade_xml_get_widget
(
xml
,
"eFlagSet1"
);
strcpy
(
str
,
"tFlagSet1."
);
if
(
w
==
NULL
)
for
(
i
=
0
;
i
<
26
;
i
++
)
{
fprintf
(
stderr
,
"Cannot get the flag set 1 widget
\n
"
);
str
[
9
]
=
'A'
+
i
;
else
{
w
=
glade_xml_get_widget
(
xml
,
str
);
ltoaf
(
user
.
flags1
,
str
);
if
(
w
==
NULL
)
truncsp
(
str
);
fprintf
(
stderr
,
"Cannot get the %s widget
\n
"
,
str
);
gtk_entry_set_text
(
GTK_ENTRY
(
w
),
str
);
else
{
b
=
(
user
.
flags1
&
(
1L
<<
i
))
!=
0
;
gtk_toggle_button_set_active
(
GTK_TOGGLE_BUTTON
(
w
),
b
);
}
}
}
w
=
glade_xml_get_widget
(
xml
,
"eFlagSet2"
);
if
(
w
==
NULL
)
strcpy
(
str
,
"tFlagSet2."
);
fprintf
(
stderr
,
"Cannot get the flag set 2 widget
\n
"
);
for
(
i
=
0
;
i
<
26
;
i
++
)
{
else
{
str
[
9
]
=
'A'
+
i
;
ltoaf
(
user
.
flags2
,
str
);
w
=
glade_xml_get_widget
(
xml
,
str
);
truncsp
(
str
);
if
(
w
==
NULL
)
gtk_entry_set_text
(
GTK_ENTRY
(
w
),
str
);
fprintf
(
stderr
,
"Cannot get the %s widget
\n
"
,
str
);
else
{
b
=
(
user
.
flags2
&
(
1L
<<
i
))
!=
0
;
gtk_toggle_button_set_active
(
GTK_TOGGLE_BUTTON
(
w
),
b
);
}
}
}
w
=
glade_xml_get_widget
(
xml
,
"eFlagSet3"
);
if
(
w
==
NULL
)
strcpy
(
str
,
"tFlagSet3."
);
fprintf
(
stderr
,
"Cannot get the flag set 3 widget
\n
"
);
for
(
i
=
0
;
i
<
26
;
i
++
)
{
else
{
str
[
9
]
=
'A'
+
i
;
ltoaf
(
user
.
flags3
,
str
);
w
=
glade_xml_get_widget
(
xml
,
str
);
truncsp
(
str
);
if
(
w
==
NULL
)
gtk_entry_set_text
(
GTK_ENTRY
(
w
),
str
);
fprintf
(
stderr
,
"Cannot get the %s widget
\n
"
,
str
);
else
{
b
=
(
user
.
flags3
&
(
1L
<<
i
))
!=
0
;
gtk_toggle_button_set_active
(
GTK_TOGGLE_BUTTON
(
w
),
b
);
}
}
}
w
=
glade_xml_get_widget
(
xml
,
"eFlagSet4"
);
if
(
w
==
NULL
)
strcpy
(
str
,
"tFlagSet4."
);
fprintf
(
stderr
,
"Cannot get the flag set 4 widget
\n
"
);
for
(
i
=
0
;
i
<
26
;
i
++
)
{
else
{
str
[
9
]
=
'A'
+
i
;
ltoaf
(
user
.
flags4
,
str
);
w
=
glade_xml_get_widget
(
xml
,
str
);
truncsp
(
str
);
if
(
w
==
NULL
)
gtk_entry_set_text
(
GTK_ENTRY
(
w
),
str
);
fprintf
(
stderr
,
"Cannot get the %s widget
\n
"
,
str
);
else
{
b
=
(
user
.
flags4
&
(
1L
<<
i
))
!=
0
;
gtk_toggle_button_set_active
(
GTK_TOGGLE_BUTTON
(
w
),
b
);
}
}
}
/* Exemptions */
/* Exemptions */
w
=
glade_xml_get_widget
(
xml
,
"eExemptions"
);
strcpy
(
str
,
"tExemptions."
);
if
(
w
==
NULL
)
for
(
i
=
0
;
i
<
26
;
i
++
)
{
fprintf
(
stderr
,
"Cannot get the exemptions widget
\n
"
);
str
[
11
]
=
'A'
+
i
;
else
{
w
=
glade_xml_get_widget
(
xml
,
str
);
ltoaf
(
user
.
exempt
,
str
);
if
(
w
==
NULL
)
truncsp
(
str
);
fprintf
(
stderr
,
"Cannot get the %s widget
\n
"
,
str
);
gtk_entry_set_text
(
GTK_ENTRY
(
w
),
str
);
else
{
b
=
(
user
.
exempt
&
(
1L
<<
i
))
!=
0
;
gtk_toggle_button_set_active
(
GTK_TOGGLE_BUTTON
(
w
),
b
);
}
}
}
/* Restrictions */
/* Restrictions */
w
=
glade_xml_get_widget
(
xml
,
"eRestrictions"
);
strcpy
(
str
,
"tRestrictions."
);
if
(
w
==
NULL
)
for
(
i
=
0
;
i
<
26
;
i
++
)
{
fprintf
(
stderr
,
"Cannot get the restrictions widget
\n
"
);
str
[
13
]
=
'A'
+
i
;
else
{
w
=
glade_xml_get_widget
(
xml
,
str
);
ltoaf
(
user
.
rest
,
str
);
if
(
w
==
NULL
)
truncsp
(
str
);
fprintf
(
stderr
,
"Cannot get the %s widget
\n
"
,
str
);
gtk_entry_set_text
(
GTK_ENTRY
(
w
),
str
);
else
{
b
=
(
user
.
rest
&
(
1L
<<
i
))
!=
0
;
gtk_toggle_button_set_active
(
GTK_TOGGLE_BUTTON
(
w
),
b
);
}
}
}
/* Credits */
/* Credits */
...
...
This diff is collapsed.
Click to expand it.
src/sbbs3/gtkuseredit/gtkuseredit.glade
+
3173
−
253
View file @
cc7261b1
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment