mirror of
https://github.com/MidnightCommander/mc
synced 2024-12-23 12:56:51 +03:00
src/filemanager/panel.c: cleanup -Wcast-qual warning.
Signed-off-by: Andreas Mohr <and@gmx.li> Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
This commit is contained in:
parent
3e7695619f
commit
6005a63cad
@ -805,7 +805,7 @@ panel_listing_box (WPanel * panel, int num, char **userp, char **minip, int *use
|
||||
const panel_field_t *
|
||||
sort_box (dir_sort_options_t * op, const panel_field_t * sort_field)
|
||||
{
|
||||
const char **sort_orders_names;
|
||||
char **sort_orders_names;
|
||||
gsize i;
|
||||
gsize sort_names_num = 0;
|
||||
int sort_idx = 0;
|
||||
@ -824,7 +824,7 @@ sort_box (dir_sort_options_t * op, const panel_field_t * sort_field)
|
||||
quick_widget_t quick_widgets[] = {
|
||||
/* *INDENT-OFF* */
|
||||
QUICK_START_COLUMNS,
|
||||
QUICK_RADIO (sort_names_num, sort_orders_names, &sort_idx, NULL),
|
||||
QUICK_RADIO (sort_names_num, (const char **) sort_orders_names, &sort_idx, NULL),
|
||||
QUICK_NEXT_COLUMN,
|
||||
QUICK_CHECKBOX (N_("Executable &first"), &op->exec_first, NULL),
|
||||
QUICK_CHECKBOX (N_("Cas&e sensitive"), &op->case_sensitive, NULL),
|
||||
@ -848,7 +848,7 @@ sort_box (dir_sort_options_t * op, const panel_field_t * sort_field)
|
||||
result = sort_field;
|
||||
}
|
||||
|
||||
g_strfreev ((gchar **) sort_orders_names);
|
||||
g_strfreev (sort_orders_names);
|
||||
|
||||
return result;
|
||||
}
|
||||
|
@ -1068,7 +1068,8 @@ display_total_marked_size (const WPanel * panel, int y, int x, gboolean size_onl
|
||||
{
|
||||
const Widget *w = CONST_WIDGET (panel);
|
||||
|
||||
char buffer[BUF_SMALL], b_bytes[BUF_SMALL], *buf;
|
||||
char buffer[BUF_SMALL], b_bytes[BUF_SMALL];
|
||||
const char *buf;
|
||||
int cols;
|
||||
|
||||
if (panel->marked <= 0)
|
||||
@ -1090,7 +1091,7 @@ display_total_marked_size (const WPanel * panel, int y, int x, gboolean size_onl
|
||||
b_bytes, panel->marked);
|
||||
|
||||
/* don't forget spaces around buffer content */
|
||||
buf = (char *) str_trunc (buf, cols - 4);
|
||||
buf = str_trunc (buf, cols - 4);
|
||||
|
||||
if (x < 0)
|
||||
/* center in panel */
|
||||
@ -4852,7 +4853,7 @@ panel_get_num_of_sortable_fields (void)
|
||||
|
||||
/* --------------------------------------------------------------------------------------------- */
|
||||
|
||||
const char **
|
||||
char **
|
||||
panel_get_sortable_fields (gsize * array_size)
|
||||
{
|
||||
char **ret;
|
||||
@ -4873,7 +4874,7 @@ panel_get_sortable_fields (gsize * array_size)
|
||||
if (panel_fields[i].is_user_choice)
|
||||
ret[lc_index++] = g_strdup (_(panel_fields[i].title_hotkey));
|
||||
|
||||
return (const char **) ret;
|
||||
return ret;
|
||||
}
|
||||
|
||||
/* --------------------------------------------------------------------------------------------- */
|
||||
@ -4940,7 +4941,7 @@ panel_get_num_of_user_possible_fields (void)
|
||||
|
||||
/* --------------------------------------------------------------------------------------------- */
|
||||
|
||||
const char **
|
||||
char **
|
||||
panel_get_user_possible_fields (gsize * array_size)
|
||||
{
|
||||
char **ret;
|
||||
@ -4961,7 +4962,7 @@ panel_get_user_possible_fields (gsize * array_size)
|
||||
if (panel_fields[i].use_in_user_format)
|
||||
ret[lc_index++] = g_strdup (_(panel_fields[i].title_hotkey));
|
||||
|
||||
return (const char **) ret;
|
||||
return ret;
|
||||
}
|
||||
|
||||
/* --------------------------------------------------------------------------------------------- */
|
||||
|
@ -180,12 +180,12 @@ void do_file_mark (WPanel * panel, int idx, int val);
|
||||
gboolean do_panel_cd (WPanel * panel, const vfs_path_t * new_dir_vpath, enum cd_enum cd_type);
|
||||
|
||||
gsize panel_get_num_of_sortable_fields (void);
|
||||
const char **panel_get_sortable_fields (gsize *);
|
||||
char **panel_get_sortable_fields (gsize *);
|
||||
const panel_field_t *panel_get_field_by_id (const char *);
|
||||
const panel_field_t *panel_get_field_by_title (const char *);
|
||||
const panel_field_t *panel_get_field_by_title_hotkey (const char *);
|
||||
gsize panel_get_num_of_user_possible_fields (void);
|
||||
const char **panel_get_user_possible_fields (gsize *);
|
||||
char **panel_get_user_possible_fields (gsize *);
|
||||
void panel_set_cwd (WPanel * panel, const vfs_path_t * vpath);
|
||||
void panel_set_lwd (WPanel * panel, const vfs_path_t * vpath);
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user