1
1

* achown.c (get_ownership): Simplified the code. Now it is

more independent of the WButton internals.
Этот коммит содержится в:
Roland Illig 2005-02-06 21:26:05 +00:00
родитель 3a40734373
Коммит c893d6e029
2 изменённых файлов: 10 добавлений и 11 удалений

Просмотреть файл

@ -1,3 +1,8 @@
2005-02-06 Roland Illig <roland.illig@gmx.de>
* achown.c (get_ownership): Simplified the code. Now it is
more independent of the WButton internals.
2005-02-05 Roland Illig <roland.illig@gmx.de>
* util.h (msglen): Converted from a function to a procedure.

Просмотреть файл

@ -69,8 +69,8 @@ static struct {
{ B_ENTER, DEFPUSH_BUTTON,4, 40, N_("&Set") },
{ B_SKIP, NORMAL_BUTTON, 4, 23, N_("S&kip") },
{ B_SETALL, NORMAL_BUTTON, 4, 0, N_("Set &all")},
{ B_ENTER, NARROW_BUTTON, 0, 47, " "},
{ B_ENTER, NARROW_BUTTON, 0, 29, " "},
{ B_ENTER, NARROW_BUTTON, 0, 47, ""},
{ B_ENTER, NARROW_BUTTON, 0, 29, ""},
{ B_ENTER, NARROW_BUTTON, 0, 19, " "},
{ B_ENTER, NARROW_BUTTON, 0, 11, " "},
{ B_ENTER, NARROW_BUTTON, 0, 3, " "}
@ -93,15 +93,9 @@ static int single_set;
static char *fname;
static void get_ownership (void)
{ /* set buttons - ownership */
const char *name_t;
name_t = name_trunc (get_owner (sf_stat->st_uid), 15);
memset (b_user->text, ' ', 15);
strncpy (b_user->text, name_t, strlen (name_t));
name_t = name_trunc (get_group (sf_stat->st_gid), 15);
memset (b_group->text, ' ', 15);
strncpy (b_group->text, name_t, strlen (name_t));
{
button_set_text (b_user, get_owner (sf_stat->st_uid));
button_set_text (b_group, get_group (sf_stat->st_gid));
}