Fixes 80% of the bugs reported by Elliot on his last email.
This does not fix some major "problems", which require some bigger changes to the program. Miguel.
Этот коммит содержится в:
родитель
8a6020da6b
Коммит
0f31fb67d0
@ -1,5 +1,31 @@
|
|||||||
1998-04-16 Miguel de Icaza <miguel@nuclecu.unam.mx>
|
1998-04-16 Miguel de Icaza <miguel@nuclecu.unam.mx>
|
||||||
|
|
||||||
|
* glayout.c (assign_other): Keep track of all of the opened
|
||||||
|
panels. We were never removing them from the containers list.
|
||||||
|
This fixes a number of problems.
|
||||||
|
|
||||||
|
* gwidget.c (x_dialog_stop): Only call gtk_main_quit if this
|
||||||
|
dialog did not inlcude the DLG_GNOME_APP flag, as those windows
|
||||||
|
did not launch a gtk_main event loop.
|
||||||
|
|
||||||
|
* gcmd.c: Try various terminal programs in the PATH before giving
|
||||||
|
up
|
||||||
|
|
||||||
|
* glayout.c: Unselect command is unselect_cmd, not select_cmd
|
||||||
|
|
||||||
|
* gcmd.c (gnome_quit_cmd): Add quit confirmation.
|
||||||
|
|
||||||
|
* gdesktop.c (perform_drop_manually): Check the type for the
|
||||||
|
source file (directory/file) and perform the proper operation.
|
||||||
|
Before this we always did a *_file_file operation.
|
||||||
|
(perform_drop_manually): Use copy_dir_dir correctly
|
||||||
|
(desktop_setup_default): Use copy_dir_dir correctly
|
||||||
|
|
||||||
|
* gwidget.c (x_create_label): Remove debugging labels.
|
||||||
|
|
||||||
|
* gscreen.c: Do not show the view/view unfiltered if the
|
||||||
|
selectioned item is a directory.
|
||||||
|
|
||||||
* gwidget.c (x_radio_toggle): Never commit non-compilable code.
|
* gwidget.c (x_radio_toggle): Never commit non-compilable code.
|
||||||
|
|
||||||
1998-04-15 Miguel de Icaza <miguel@nuclecu.unam.mx>
|
1998-04-15 Miguel de Icaza <miguel@nuclecu.unam.mx>
|
||||||
|
34
gnome/gcmd.c
34
gnome/gcmd.c
@ -1,3 +1,10 @@
|
|||||||
|
/*
|
||||||
|
* Various Menu-invoked Command implementations specific to the GNOME port
|
||||||
|
*
|
||||||
|
* Copyright (C) 1998 the Free Software Foundation
|
||||||
|
*
|
||||||
|
* Author: Miguel de Icaza (miguel@kernel.org)
|
||||||
|
*/
|
||||||
#include <config.h>
|
#include <config.h>
|
||||||
#include "x.h"
|
#include "x.h"
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
@ -40,7 +47,19 @@ gnome_compare_panels (void)
|
|||||||
void
|
void
|
||||||
gnome_open_terminal (void)
|
gnome_open_terminal (void)
|
||||||
{
|
{
|
||||||
my_system (1, shell, "nxterm");
|
char *p;
|
||||||
|
|
||||||
|
if (!(p = gnome_is_program_in_path ("gnome-terminal")))
|
||||||
|
if (!(p = gnome_is_program_in_path ("dtterm")))
|
||||||
|
if (!(p = gnome_is_program_in_path ("nxterm")))
|
||||||
|
if (!(p = gnome_is_program_in_path ("color-xterm")))
|
||||||
|
if (!(p = gnome_is_program_in_path ("rxvt")))
|
||||||
|
p = gnome_is_program_in_path ("xterm");
|
||||||
|
|
||||||
|
if (p)
|
||||||
|
my_system (1, shell, p);
|
||||||
|
else
|
||||||
|
message (1, MSG_ERROR, " Could not start a terminal ");
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
@ -65,7 +84,17 @@ gnome_about_cmd (void)
|
|||||||
void
|
void
|
||||||
gnome_quit_cmd (void)
|
gnome_quit_cmd (void)
|
||||||
{
|
{
|
||||||
gtk_main_quit ();
|
int q = 0;
|
||||||
|
|
||||||
|
if (!confirm_exit)
|
||||||
|
q = 1;
|
||||||
|
else if (query_dialog (_(" The Midnight Commander "),
|
||||||
|
_(" Do you really want to quit the Midnight Commander? "),
|
||||||
|
0, 2, _("&Yes"), _("&No")) == 0)
|
||||||
|
q = 1;
|
||||||
|
|
||||||
|
if (q == 1)
|
||||||
|
gtk_main_quit ();
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
@ -89,5 +118,6 @@ gnome_close_panel (GtkWidget *widget, WPanel *panel)
|
|||||||
destroy_widget (panel->filter_w);
|
destroy_widget (panel->filter_w);
|
||||||
destroy_widget ((void *)panel);
|
destroy_widget ((void *)panel);
|
||||||
|
|
||||||
|
layout_panel_gone (panel);
|
||||||
return TRUE;
|
return TRUE;
|
||||||
}
|
}
|
||||||
|
@ -423,6 +423,7 @@ perform_drop_on_directory (WPanel *source_panel, int operation, char *dest)
|
|||||||
static void
|
static void
|
||||||
perform_drop_manually (int operation, GdkEventDropDataAvailable *event, char *dest)
|
perform_drop_manually (int operation, GdkEventDropDataAvailable *event, char *dest)
|
||||||
{
|
{
|
||||||
|
struct stat buf;
|
||||||
int count = event->data_numbytes;
|
int count = event->data_numbytes;
|
||||||
char *p = event->data;
|
char *p = event->data;
|
||||||
int len;
|
int len;
|
||||||
@ -440,6 +441,7 @@ perform_drop_manually (int operation, GdkEventDropDataAvailable *event, char *de
|
|||||||
|
|
||||||
do {
|
do {
|
||||||
char *tmpf;
|
char *tmpf;
|
||||||
|
int res, v;
|
||||||
|
|
||||||
len = 1 + strlen (event->data);
|
len = 1 + strlen (event->data);
|
||||||
count -= len;
|
count -= len;
|
||||||
@ -447,15 +449,37 @@ perform_drop_manually (int operation, GdkEventDropDataAvailable *event, char *de
|
|||||||
switch (operation){
|
switch (operation){
|
||||||
case OPER_COPY:
|
case OPER_COPY:
|
||||||
tmpf = concat_dir_and_file (dest, x_basename (p));
|
tmpf = concat_dir_and_file (dest, x_basename (p));
|
||||||
copy_file_file (p, tmpf, 1);
|
do {
|
||||||
|
res = mc_stat (p, &buf);
|
||||||
|
if (res != 0){
|
||||||
|
v = file_error (" Could not stat %s \n %s ", tmpf);
|
||||||
|
if (v != FILE_RETRY)
|
||||||
|
res = 0;
|
||||||
|
} else {
|
||||||
|
if (S_ISDIR (buf.st_mode))
|
||||||
|
copy_dir_dir (p, tmpf, 1, 0, 0, 0);
|
||||||
|
else
|
||||||
|
copy_file_file (p, tmpf, 1);
|
||||||
|
}
|
||||||
|
} while (res != 0);
|
||||||
free (tmpf);
|
free (tmpf);
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case OPER_MOVE:
|
case OPER_MOVE:
|
||||||
create_op_win (OP_MOVE, 0);
|
|
||||||
file_mask_defaults ();
|
|
||||||
tmpf = concat_dir_and_file (dest, x_basename (p));
|
tmpf = concat_dir_and_file (dest, x_basename (p));
|
||||||
move_file_file (p, tmpf);
|
do {
|
||||||
|
res = mc_stat (p, &buf);
|
||||||
|
if (res != 0){
|
||||||
|
v = file_error (" Could not stat %s \n %s ", tmpf);
|
||||||
|
if (v != FILE_RETRY)
|
||||||
|
res = 0;
|
||||||
|
} else {
|
||||||
|
if (S_ISDIR (buf.st_mode))
|
||||||
|
move_dir_dir (p, tmpf);
|
||||||
|
else
|
||||||
|
move_file_file (p, tmpf);
|
||||||
|
}
|
||||||
|
} while (res != 0);
|
||||||
free (tmpf);
|
free (tmpf);
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
@ -1255,7 +1279,7 @@ desktop_setup_default (char *desktop_dir)
|
|||||||
if (exist_file (mc_desktop_dir)){
|
if (exist_file (mc_desktop_dir)){
|
||||||
create_op_win (OP_COPY, 0);
|
create_op_win (OP_COPY, 0);
|
||||||
file_mask_defaults ();
|
file_mask_defaults ();
|
||||||
copy_dir_dir (mc_desktop_dir, desktop_dir);
|
copy_dir_dir (mc_desktop_dir, desktop_dir, 1, 0, 0, 0);
|
||||||
destroy_op_win ();
|
destroy_op_win ();
|
||||||
} else
|
} else
|
||||||
mkdir (desktop_dir, 0777);
|
mkdir (desktop_dir, 0777);
|
||||||
|
@ -13,6 +13,7 @@
|
|||||||
#include "panel.h"
|
#include "panel.h"
|
||||||
#include "gscreen.h"
|
#include "gscreen.h"
|
||||||
#include "main.h"
|
#include "main.h"
|
||||||
|
#include "gmain.h"
|
||||||
#include "cmd.h"
|
#include "cmd.h"
|
||||||
#include "boxes.h"
|
#include "boxes.h"
|
||||||
#include "panelize.h"
|
#include "panelize.h"
|
||||||
@ -35,7 +36,10 @@ PanelContainer *current_panel_ptr, *other_panel_ptr;
|
|||||||
WPanel *
|
WPanel *
|
||||||
get_current_panel (void)
|
get_current_panel (void)
|
||||||
{
|
{
|
||||||
return current_panel_ptr->panel;
|
if (current_panel_ptr)
|
||||||
|
return current_panel_ptr->panel;
|
||||||
|
else
|
||||||
|
return NULL;
|
||||||
}
|
}
|
||||||
|
|
||||||
WPanel *
|
WPanel *
|
||||||
@ -91,7 +95,9 @@ set_new_current_panel (WPanel *panel)
|
|||||||
{
|
{
|
||||||
GList *p;
|
GList *p;
|
||||||
|
|
||||||
other_panel_ptr = current_panel_ptr;
|
if (g_list_length (containers) > 1)
|
||||||
|
other_panel_ptr = current_panel_ptr;
|
||||||
|
|
||||||
for (p = containers; p; p = p->next){
|
for (p = containers; p; p = p->next){
|
||||||
if (((PanelContainer *)p->data)->panel == panel){
|
if (((PanelContainer *)p->data)->panel == panel){
|
||||||
current_panel_ptr = p->data;
|
current_panel_ptr = p->data;
|
||||||
@ -99,6 +105,81 @@ set_new_current_panel (WPanel *panel)
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/*
|
||||||
|
* Tries to assign other_panel (ie, if there is anything to assign to
|
||||||
|
*/
|
||||||
|
static void
|
||||||
|
assign_other (void)
|
||||||
|
{
|
||||||
|
GList *p;
|
||||||
|
|
||||||
|
other_panel_ptr = NULL;
|
||||||
|
for (p = containers; p; p = p->next)
|
||||||
|
if (p->data != current_panel_ptr){
|
||||||
|
other_panel_ptr = p->data;
|
||||||
|
printf ("PANEL: Found another other\n");
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/*
|
||||||
|
* This keeps track of the current_panel_ptr and other_panel_ptr as
|
||||||
|
* well as the list of active containers
|
||||||
|
*/
|
||||||
|
void
|
||||||
|
layout_panel_gone (WPanel *panel)
|
||||||
|
{
|
||||||
|
PanelContainer *pc_holder = 0;
|
||||||
|
int len = g_list_length (containers);
|
||||||
|
GList *p;
|
||||||
|
|
||||||
|
for (p = containers; p; p = p->next){
|
||||||
|
PanelContainer *pc = p->data;
|
||||||
|
|
||||||
|
if (pc->panel == panel){
|
||||||
|
pc_holder = pc;
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
printf ("PANEL: Going away [%d]\n", len);
|
||||||
|
if (len > 1){
|
||||||
|
containers = g_list_remove (containers, pc_holder);
|
||||||
|
printf ("PANEL: extra panels left\n");
|
||||||
|
}
|
||||||
|
|
||||||
|
/* Check if this is not the current panel */
|
||||||
|
if (current_panel_ptr->panel == panel){
|
||||||
|
printf ("PANEL: was current panel\n");
|
||||||
|
if (other_panel_ptr){
|
||||||
|
current_panel_ptr = other_panel_ptr;
|
||||||
|
assign_other ();
|
||||||
|
printf ("PANEL: setting current to other\n");
|
||||||
|
} else {
|
||||||
|
current_panel_ptr = NULL;
|
||||||
|
printf ("PANEL: No current panel now\n");
|
||||||
|
}
|
||||||
|
} else if (other_panel_ptr->panel == panel){
|
||||||
|
/* Check if it was the other panel */
|
||||||
|
printf ("PANEL: was the other panel\n");
|
||||||
|
if (len == 1){
|
||||||
|
other_panel_ptr = 0;
|
||||||
|
printf ("PANEL: We are left without other\n");
|
||||||
|
} else
|
||||||
|
assign_other ();
|
||||||
|
} else {
|
||||||
|
printf ("PANEL: was some other panel\n");
|
||||||
|
}
|
||||||
|
|
||||||
|
if (len == 1){
|
||||||
|
g_free (containers->data);
|
||||||
|
g_list_free (containers);
|
||||||
|
containers = NULL;
|
||||||
|
printf ("PANEL: It was the last one\n");
|
||||||
|
} else
|
||||||
|
g_free (pc_holder);
|
||||||
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
set_hintbar (char *str)
|
set_hintbar (char *str)
|
||||||
{
|
{
|
||||||
@ -202,7 +283,7 @@ GnomeUIInfo gnome_panel_file_menu [] = {
|
|||||||
{ GNOME_APP_UI_ITEM, N_("View raw"), N_("View the file without further processing"),panel_action_view_unfiltered},
|
{ GNOME_APP_UI_ITEM, N_("View raw"), N_("View the file without further processing"),panel_action_view_unfiltered},
|
||||||
{ GNOME_APP_UI_SEPARATOR },
|
{ GNOME_APP_UI_SEPARATOR },
|
||||||
{ GNOME_APP_UI_ITEM, N_("Select group"), N_("Selects a group of files"), select_cmd },
|
{ GNOME_APP_UI_ITEM, N_("Select group"), N_("Selects a group of files"), select_cmd },
|
||||||
{ GNOME_APP_UI_ITEM, N_("Unselect group"), N_("Un-selects a group of marked files"), select_cmd },
|
{ GNOME_APP_UI_ITEM, N_("Unselect group"), N_("Un-selects a group of marked files"), unselect_cmd },
|
||||||
{ GNOME_APP_UI_ITEM, N_("Reverse selection"), N_("Reverses the list of tagged files"), reverse_selection_cmd },
|
{ GNOME_APP_UI_ITEM, N_("Reverse selection"), N_("Reverses the list of tagged files"), reverse_selection_cmd },
|
||||||
{ GNOME_APP_UI_SEPARATOR },
|
{ GNOME_APP_UI_SEPARATOR },
|
||||||
{ GNOME_APP_UI_ITEM, N_("Close"), N_("Close this panel"), gnome_close_panel },
|
{ GNOME_APP_UI_ITEM, N_("Close"), N_("Close this panel"), gnome_close_panel },
|
||||||
@ -359,11 +440,10 @@ void
|
|||||||
new_panel_at (char *dir)
|
new_panel_at (char *dir)
|
||||||
{
|
{
|
||||||
WPanel *panel;
|
WPanel *panel;
|
||||||
Dlg_head *h = current_panel_ptr->panel->widget.parent;
|
|
||||||
|
|
||||||
mc_chdir (dir);
|
mc_chdir (dir);
|
||||||
panel = create_container (h, dir);
|
panel = create_container (desktop_dlg, dir);
|
||||||
add_widget (h, panel);
|
add_widget (desktop_dlg, panel);
|
||||||
|
|
||||||
set_new_current_panel (panel);
|
set_new_current_panel (panel);
|
||||||
}
|
}
|
||||||
|
@ -41,6 +41,9 @@ char *default_edition_colors =
|
|||||||
"menuhotsel=cyan,black:"
|
"menuhotsel=cyan,black:"
|
||||||
"special=black";
|
"special=black";
|
||||||
|
|
||||||
|
/* The Dlg_head for the whole desktop */
|
||||||
|
Dlg_head *desktop_dlg;
|
||||||
|
|
||||||
void
|
void
|
||||||
init_pair (int index, GdkColor *fore, GdkColor *back)
|
init_pair (int index, GdkColor *fore, GdkColor *back)
|
||||||
{
|
{
|
||||||
@ -381,7 +384,6 @@ dialog_panel_callback (struct Dlg_head *h, int id, int msg)
|
|||||||
void
|
void
|
||||||
create_panels (void)
|
create_panels (void)
|
||||||
{
|
{
|
||||||
Dlg_head *h;
|
|
||||||
WPanel *panel;
|
WPanel *panel;
|
||||||
|
|
||||||
start_desktop ();
|
start_desktop ();
|
||||||
@ -390,13 +392,13 @@ create_panels (void)
|
|||||||
|
|
||||||
gnome_init_panels ();
|
gnome_init_panels ();
|
||||||
|
|
||||||
h = create_dlg (0, 0, 24, 80, 0, dialog_panel_callback, "[panel]", "midnight", DLG_NO_TED);
|
desktop_dlg = create_dlg (0, 0, 24, 80, 0, dialog_panel_callback, "[panel]", "midnight", DLG_NO_TED);
|
||||||
|
|
||||||
panel = create_container (h, "My Panel");
|
panel = create_container (desktop_dlg, "My Panel");
|
||||||
add_widget (h, panel);
|
add_widget (desktop_dlg, panel);
|
||||||
|
|
||||||
set_current_panel (0);
|
set_current_panel (0);
|
||||||
run_dlg (h);
|
run_dlg (desktop_dlg);
|
||||||
|
|
||||||
/* shutdown gnome specific bits of midnight commander */
|
/* shutdown gnome specific bits of midnight commander */
|
||||||
stop_desktop ();
|
stop_desktop ();
|
||||||
|
@ -7,25 +7,25 @@
|
|||||||
int xtoolkit_init (int *argc, char *argv []);
|
int xtoolkit_init (int *argc, char *argv []);
|
||||||
int xtoolkit_end (void);
|
int xtoolkit_end (void);
|
||||||
|
|
||||||
|
extern Dlg_head *desktop_dlg;
|
||||||
|
|
||||||
/* Required by the standard code */
|
/* Required by the standard code */
|
||||||
widget_data xtoolkit_create_dialog (Dlg_head *h, int with_grid);
|
widget_data xtoolkit_create_dialog (Dlg_head *h, int with_grid);
|
||||||
widget_data xtoolkit_get_main_dialog (Dlg_head *h);
|
widget_data xtoolkit_get_main_dialog (Dlg_head *h);
|
||||||
void x_dlg_set_window (Dlg_head *h, GtkWidget *win);
|
void x_dlg_set_window (Dlg_head *h, GtkWidget *win);
|
||||||
widget_data x_create_panel_container (int which);
|
widget_data x_create_panel_container (int which);
|
||||||
void x_panel_container_show (widget_data wdata);
|
void x_panel_container_show (widget_data wdata);
|
||||||
|
void x_destroy_cmd (void *);
|
||||||
void x_destroy_cmd (void *);
|
int x_create_radio (Dlg_head *h, widget_data parent, WRadio *r);
|
||||||
|
int x_create_check (Dlg_head *h, widget_data parent, WCheck *c);
|
||||||
int x_create_radio (Dlg_head *h, widget_data parent, WRadio *r);
|
int x_create_label (Dlg_head *h, widget_data parent, WLabel *l);
|
||||||
int x_create_check (Dlg_head *h, widget_data parent, WCheck *c);
|
int x_create_input (Dlg_head *h, widget_data parent, WInput *in);
|
||||||
int x_create_label (Dlg_head *h, widget_data parent, WLabel *l);
|
int x_create_listbox (Dlg_head *h, widget_data parent, WListbox *l);
|
||||||
int x_create_input (Dlg_head *h, widget_data parent, WInput *in);
|
int x_create_buttonbar (Dlg_head *h, widget_data parent, WButtonBar *bb);
|
||||||
int x_create_listbox (Dlg_head *h, widget_data parent, WListbox *l);
|
void x_filter_changed (WPanel *panel);
|
||||||
int x_create_buttonbar (Dlg_head *h, widget_data parent, WButtonBar *bb);
|
void x_list_insert (WListbox *l, WLEntry *p, WLEntry *e);
|
||||||
void x_filter_changed (WPanel *panel);
|
void x_redefine_label (WButtonBar *bb, int idx);
|
||||||
void x_list_insert (WListbox *l, WLEntry *p, WLEntry *e);
|
void x_add_widget (Dlg_head *h, Widget_Item *w);
|
||||||
void x_redefine_label (WButtonBar *bb, int idx);
|
|
||||||
void x_add_widget (Dlg_head *h, Widget_Item *w);
|
|
||||||
|
|
||||||
struct gmc_color_pairs_s {
|
struct gmc_color_pairs_s {
|
||||||
GdkColor *fore, *back;
|
GdkColor *fore, *back;
|
||||||
|
@ -3,20 +3,24 @@
|
|||||||
IMPORTANTE:
|
IMPORTANTE:
|
||||||
|
|
||||||
>>>>> properties change on desktop object dont lead to refresh <<<<<
|
>>>>> properties change on desktop object dont lead to refresh <<<<<
|
||||||
|
>>>>> When something is dragged, the panel is not being refreshed <<<<
|
||||||
drags onto desktop dont seem to be refreshed when link complete Also,
|
|
||||||
panel drag originated in is trashed by shaped window moving around in it during drag event
|
|
||||||
|
|
||||||
file actions dont cause panels to be refreshed automatically
|
file actions dont cause panels to be refreshed automatically
|
||||||
|
|
||||||
All:
|
All:
|
||||||
|
|
||||||
- It leaks objects.
|
|
||||||
- Session management
|
- Session management
|
||||||
|
|
||||||
Desktop:
|
|
||||||
|
EXTENSIONS:
|
||||||
|
|
||||||
- Add special destkop entries ("Network neighborhood")
|
- Add special destkop entries ("Network neighborhood")
|
||||||
|
- In the find-file results, it would be nice if 'chdir' popped up a new
|
||||||
|
panel instead of changing the directory of the present one (optionally).
|
||||||
|
- (Cool but low priority) it would be nice if 'Arrange icons'
|
||||||
|
were configurable to allow stacking the icons along a particular edge
|
||||||
|
OR if gmc could automatically find areas of free screen (i.e. no windows
|
||||||
|
on them) and then place icons there.
|
||||||
|
|
||||||
Panels:
|
Panels:
|
||||||
|
|
||||||
@ -42,20 +46,6 @@ DND:
|
|||||||
- Get sopwith to fix the random motion of his dnd icons.
|
- Get sopwith to fix the random motion of his dnd icons.
|
||||||
- Check the purify stuff.
|
- Check the purify stuff.
|
||||||
|
|
||||||
Observations from Dr Mike:
|
|
||||||
|
|
||||||
From msf@redhat.com Wed Apr 1 15:12:58 1998
|
|
||||||
Return-Path: <msf@redhat.com>
|
|
||||||
To: Miguel de Icaza <miguel@nuclecu.unam.mx>
|
|
||||||
cc: msf@redhat.com, marc@redhat.com
|
|
||||||
Subject: gmc observations
|
|
||||||
Mime-Version: 1.0
|
|
||||||
Content-Type: text/plain; charset=us-ascii
|
|
||||||
Date: Wed, 01 Apr 1998 16:14:50 -0500
|
|
||||||
From: Michael Fulbright <msf@redhat.com>
|
|
||||||
|
|
||||||
Ok you asked for it...
|
|
||||||
|
|
||||||
General Comments
|
General Comments
|
||||||
----------------
|
----------------
|
||||||
|
|
||||||
@ -109,24 +99,13 @@ Panel comments
|
|||||||
- I didnt get an error message when I tried to change the file modes
|
- I didnt get an error message when I tried to change the file modes
|
||||||
on a file I didnt own.
|
on a file I didnt own.
|
||||||
|
|
||||||
- double clicking on a file object seemed to try to push an artificial drag
|
|
||||||
sometimes, I thought it would try to open it or something.
|
|
||||||
|
|
||||||
- when selecting 'Copy' from the right click menu, it would be nice to
|
|
||||||
have a browsable tree to select the destination from.
|
|
||||||
|
|
||||||
- i couldnt seem to drag things onto the root window
|
|
||||||
|
|
||||||
|
|
||||||
Configure Options
|
Configure Options
|
||||||
-----------------
|
-----------------
|
||||||
|
|
||||||
- need some sort of help for all these options, they aren't too intuitive.
|
- need some sort of help for all these options, they aren't too intuitive.
|
||||||
We can't assume people are going to read the man page.
|
We can't assume people are going to read the man page.
|
||||||
|
|
||||||
- 'Find File' dialog - the Tree button needs a pixmap
|
- Also, during a find, the dialog violently resizes as it lists the
|
||||||
|
|
||||||
Also, during a find, the dialog violently resizes as it lists the
|
|
||||||
directories it is searching through. Seems like the label showing
|
directories it is searching through. Seems like the label showing
|
||||||
the currently searched dir needs to be a separate container or something.
|
the currently searched dir needs to be a separate container or something.
|
||||||
It looks like its in the first column of the table of buttons below it.
|
It looks like its in the first column of the table of buttons below it.
|
||||||
@ -140,4 +119,25 @@ VFS Options
|
|||||||
of feedback while grabbing a ls listing from a ftp server would be
|
of feedback while grabbing a ls listing from a ftp server would be
|
||||||
cool.
|
cool.
|
||||||
|
|
||||||
|
NEW BUG LIST:
|
||||||
|
|
||||||
|
- In the properties dialog, permissions tab, the user & group drop-downs
|
||||||
|
list the same users/groups multiple times.
|
||||||
|
- Why use a GnomeEntry *everywhere* when a lot of the places don't need
|
||||||
|
the history that it provides? Only when the user changes an entry
|
||||||
|
box often and needs a history should GnomeEntry be used...?
|
||||||
|
- Find file is pretty cool, but you might want to force-set a maximum size
|
||||||
|
during the search (and then unset it after the search is done) to stop
|
||||||
|
it from dancing around while it displays all the files that it's
|
||||||
|
checking in that label below the GtkCList.
|
||||||
|
- Hidden directories don't have the right-mouse-button 'Start XTerm
|
||||||
|
here'/'Make a tarball' menu options.
|
||||||
|
|
||||||
|
OPEN ISSUES:
|
||||||
|
- Selection of multiple files is somewhat confusing in general
|
||||||
|
|
||||||
|
- Also if you have multi-file selection, is there a way to get a popup
|
||||||
|
menu of the operations that are applicable to all those files, instead
|
||||||
|
of an empty one?
|
||||||
|
- The text in a lot of text entries disappears as soon as I start typing
|
||||||
|
in them.
|
||||||
|
@ -63,6 +63,7 @@ typedef void (*context_menu_callback)(GtkWidget *, WPanel *);
|
|||||||
#define F_REGULAR 2
|
#define F_REGULAR 2
|
||||||
#define F_SYMLINK 4
|
#define F_SYMLINK 4
|
||||||
#define F_SINGLE 8
|
#define F_SINGLE 8
|
||||||
|
#define F_NOTDIR 16
|
||||||
|
|
||||||
void
|
void
|
||||||
repaint_file (WPanel *panel, int file_index, int move, int attr, int isstatus)
|
repaint_file (WPanel *panel, int file_index, int move, int attr, int isstatus)
|
||||||
@ -361,8 +362,8 @@ static struct {
|
|||||||
{ "", F_SINGLE, NULL },
|
{ "", F_SINGLE, NULL },
|
||||||
{ N_("Open"), F_ALL, panel_action_open },
|
{ N_("Open"), F_ALL, panel_action_open },
|
||||||
{ N_("Open with"), F_ALL, panel_action_open_with },
|
{ N_("Open with"), F_ALL, panel_action_open_with },
|
||||||
{ N_("View"), F_ALL, panel_action_view },
|
{ N_("View"), F_NOTDIR, panel_action_view },
|
||||||
{ N_("View unfiltered"), F_ALL, panel_action_view_unfiltered },
|
{ N_("View unfiltered"), F_NOTDIR, panel_action_view_unfiltered },
|
||||||
{ "", 0, NULL },
|
{ "", 0, NULL },
|
||||||
{ N_("Link..."), F_REGULAR | F_SINGLE, (context_menu_callback) link_cmd },
|
{ N_("Link..."), F_REGULAR | F_SINGLE, (context_menu_callback) link_cmd },
|
||||||
{ N_("Symlink..."), F_SINGLE, (context_menu_callback) symlink_cmd },
|
{ N_("Symlink..."), F_SINGLE, (context_menu_callback) symlink_cmd },
|
||||||
@ -405,6 +406,17 @@ create_popup_submenu (WPanel *panel, int row, char *filename)
|
|||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/* Items with F_NOTDIR requiere that the selection is not a directory */
|
||||||
|
if (file_actions [i].flags & F_NOTDIR){
|
||||||
|
struct stat *s = &panel->dir.list [row].buf;
|
||||||
|
|
||||||
|
if (panel->dir.list [row].f.link_to_dir)
|
||||||
|
break;
|
||||||
|
|
||||||
|
if (S_ISDIR (s->st_mode))
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
|
||||||
/* Items with F_REGULAR do not accept any strange file types */
|
/* Items with F_REGULAR do not accept any strange file types */
|
||||||
if (file_actions [i].flags & F_REGULAR){
|
if (file_actions [i].flags & F_REGULAR){
|
||||||
struct stat *s = &panel->dir.list [row].buf;
|
struct stat *s = &panel->dir.list [row].buf;
|
||||||
@ -983,15 +995,6 @@ panel_create_cwd (Dlg_head *h, WPanel *panel, void **entry)
|
|||||||
return GTK_WIDGET (in->widget.wdata);
|
return GTK_WIDGET (in->widget.wdata);
|
||||||
}
|
}
|
||||||
|
|
||||||
static void
|
|
||||||
panel_change_filter (GtkWidget *entry, WPanel *panel)
|
|
||||||
{
|
|
||||||
char *reg_exp;
|
|
||||||
|
|
||||||
reg_exp = ((WInput *)panel->filter_w)->buffer;
|
|
||||||
set_panel_filter_to (panel, strdup (reg_exp));
|
|
||||||
}
|
|
||||||
|
|
||||||
/* FIXME: for now, this list is hardcoded. We want a way to let the user configure it. */
|
/* FIXME: for now, this list is hardcoded. We want a way to let the user configure it. */
|
||||||
|
|
||||||
static struct filter_item {
|
static struct filter_item {
|
||||||
@ -1276,8 +1279,8 @@ void
|
|||||||
x_create_panel (Dlg_head *h, widget_data parent, WPanel *panel)
|
x_create_panel (Dlg_head *h, widget_data parent, WPanel *panel)
|
||||||
{
|
{
|
||||||
GtkWidget *status_line, *filter, *vbox;
|
GtkWidget *status_line, *filter, *vbox;
|
||||||
GtkWidget *frame, *cwd, *back, *home, *fwd, *back_p, *fwd_p;
|
GtkWidget *frame, *cwd, *back_p, *fwd_p;
|
||||||
GtkWidget *very_top, *display;
|
GtkWidget *display;
|
||||||
|
|
||||||
panel->xwindow = gtk_widget_get_toplevel (GTK_WIDGET (panel->widget.wdata));
|
panel->xwindow = gtk_widget_get_toplevel (GTK_WIDGET (panel->widget.wdata));
|
||||||
|
|
||||||
|
@ -17,6 +17,7 @@
|
|||||||
#include "wtools.h"
|
#include "wtools.h"
|
||||||
#include "dialog.h"
|
#include "dialog.h"
|
||||||
#include "color.h"
|
#include "color.h"
|
||||||
|
#include "gmain.h"
|
||||||
|
|
||||||
Dlg_head *last_query_dlg;
|
Dlg_head *last_query_dlg;
|
||||||
static int sel_pos;
|
static int sel_pos;
|
||||||
|
@ -48,10 +48,9 @@
|
|||||||
#include <X11/Xlib.h>
|
#include <X11/Xlib.h>
|
||||||
#include <gdk/gdkprivate.h>
|
#include <gdk/gdkprivate.h>
|
||||||
|
|
||||||
int my_system (int as_shell_command, const char *shell, const char *command)
|
int my_system_get_child_pid (int as_shell_command, const char *shell, const char *command, pid_t *pid)
|
||||||
{
|
{
|
||||||
struct sigaction ignore, save_intr, save_quit, save_stop;
|
struct sigaction ignore, save_intr, save_quit, save_stop;
|
||||||
pid_t pid;
|
|
||||||
int status = 0, i;
|
int status = 0, i;
|
||||||
|
|
||||||
ignore.sa_handler = SIG_IGN;
|
ignore.sa_handler = SIG_IGN;
|
||||||
@ -61,11 +60,11 @@ int my_system (int as_shell_command, const char *shell, const char *command)
|
|||||||
sigaction (SIGINT, &ignore, &save_intr);
|
sigaction (SIGINT, &ignore, &save_intr);
|
||||||
sigaction (SIGQUIT, &ignore, &save_quit);
|
sigaction (SIGQUIT, &ignore, &save_quit);
|
||||||
|
|
||||||
if ((pid = fork ()) < 0){
|
if ((*pid = fork ()) < 0){
|
||||||
fprintf (stderr, "\n\nfork () = -1\n");
|
fprintf (stderr, "\n\nfork () = -1\n");
|
||||||
return -1;
|
return -1;
|
||||||
}
|
}
|
||||||
if (pid == 0){
|
if (*pid == 0){
|
||||||
const int top = max_open_files ();
|
const int top = max_open_files ();
|
||||||
sigaction (SIGINT, &save_intr, NULL);
|
sigaction (SIGINT, &save_intr, NULL);
|
||||||
sigaction (SIGQUIT, &save_quit, NULL);
|
sigaction (SIGQUIT, &save_quit, NULL);
|
||||||
@ -91,6 +90,13 @@ int my_system (int as_shell_command, const char *shell, const char *command)
|
|||||||
return WEXITSTATUS(status);
|
return WEXITSTATUS(status);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
int my_system (int as_shell_command, const char *shell, const char *command)
|
||||||
|
{
|
||||||
|
pid_t pid;
|
||||||
|
|
||||||
|
return my_system_get_child_pid (as_shell_command, shell, command, &pid);
|
||||||
|
}
|
||||||
|
|
||||||
int
|
int
|
||||||
exec_direct (char *path, char *argv [])
|
exec_direct (char *path, char *argv [])
|
||||||
{
|
{
|
||||||
|
@ -80,7 +80,7 @@ scrollbar_moved (GtkAdjustment *adj, WView *view)
|
|||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
view_percent (WView *view, int p)
|
view_percent (WView *view, int p, int w)
|
||||||
{
|
{
|
||||||
int percent;
|
int percent;
|
||||||
char buffer [40];
|
char buffer [40];
|
||||||
@ -127,9 +127,9 @@ view_status (WView *view)
|
|||||||
gtk_label_set (GTK_LABEL (view->gtk_bytes), buffer);
|
gtk_label_set (GTK_LABEL (view->gtk_bytes), buffer);
|
||||||
|
|
||||||
if (view->hex_mode)
|
if (view->hex_mode)
|
||||||
view_percent (view, view->edit_cursor - view->first);
|
view_percent (view, view->edit_cursor - view->first, 0);
|
||||||
else
|
else
|
||||||
view_percent (view, view->start_display - view->first);
|
view_percent (view, view->start_display - view->first, 0);
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
@ -323,6 +323,13 @@ GnomeUIInfo gview_top_menu [] = {
|
|||||||
{ GNOME_APP_UI_ENDOFINFO, 0, 0 }
|
{ GNOME_APP_UI_ENDOFINFO, 0, 0 }
|
||||||
};
|
};
|
||||||
|
|
||||||
|
static int
|
||||||
|
quit_view (GtkWidget *widget, GdkEvent *event, WView *view)
|
||||||
|
{
|
||||||
|
gview_quit (widget, view);
|
||||||
|
return TRUE;
|
||||||
|
}
|
||||||
|
|
||||||
int
|
int
|
||||||
view (char *_command, char *_file, int *move_dir_p, int start_line)
|
view (char *_command, char *_file, int *move_dir_p, int start_line)
|
||||||
{
|
{
|
||||||
@ -378,6 +385,9 @@ view (char *_command, char *_file, int *move_dir_p, int start_line)
|
|||||||
scrollbar = gtk_vscrollbar_new (wview->sadj);
|
scrollbar = gtk_vscrollbar_new (wview->sadj);
|
||||||
gtk_signal_connect (GTK_OBJECT (wview->sadj), "value_changed",
|
gtk_signal_connect (GTK_OBJECT (wview->sadj), "value_changed",
|
||||||
GTK_SIGNAL_FUNC(scrollbar_moved), wview);
|
GTK_SIGNAL_FUNC(scrollbar_moved), wview);
|
||||||
|
|
||||||
|
gtk_signal_connect (GTK_OBJECT (toplevel), "delete_event",
|
||||||
|
GTK_SIGNAL_FUNC (quit_view), wview);
|
||||||
|
|
||||||
hbox = gtk_hbox_new (0, 0);
|
hbox = gtk_hbox_new (0, 0);
|
||||||
gtk_box_pack_start (GTK_BOX (vbox), hbox, 1, 1, 0);
|
gtk_box_pack_start (GTK_BOX (vbox), hbox, 1, 1, 0);
|
||||||
|
@ -30,6 +30,8 @@ get_gtk_widget (Widget_Item *p)
|
|||||||
void
|
void
|
||||||
x_dialog_stop (Dlg_head *h)
|
x_dialog_stop (Dlg_head *h)
|
||||||
{
|
{
|
||||||
|
if (h->grided & DLG_GNOME_APP)
|
||||||
|
return;
|
||||||
gtk_main_quit ();
|
gtk_main_quit ();
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -456,9 +458,12 @@ x_create_label (Dlg_head *g, widget_data parent, WLabel *l)
|
|||||||
GtkWidget *label;
|
GtkWidget *label;
|
||||||
|
|
||||||
/* Tempo-hack */
|
/* Tempo-hack */
|
||||||
if (*l->text == 0)
|
if (*l->text == 0){
|
||||||
label = gtk_label_new (l->widget.tkname);
|
if (0)
|
||||||
else
|
label = gtk_label_new (l->widget.tkname);
|
||||||
|
else
|
||||||
|
label = gtk_label_new ("");
|
||||||
|
} else
|
||||||
label = gtk_label_new (l->text);
|
label = gtk_label_new (l->text);
|
||||||
gtk_widget_show (label);
|
gtk_widget_show (label);
|
||||||
l->widget.wdata = (widget_data) label;
|
l->widget.wdata = (widget_data) label;
|
||||||
|
@ -1,5 +1,14 @@
|
|||||||
1998-04-16 Miguel de Icaza <miguel@nuclecu.unam.mx>
|
1998-04-16 Miguel de Icaza <miguel@nuclecu.unam.mx>
|
||||||
|
|
||||||
|
* file.h: Added prototype for copy_dir_dir.
|
||||||
|
|
||||||
|
* file.c (real_do_file_error): use the proper flags, this is not a
|
||||||
|
D_INSERT dialog box, for what it is worth. Important bug fix.
|
||||||
|
|
||||||
|
* utilunix.c (get_owner): Declare.
|
||||||
|
|
||||||
|
* widget.h: Added various missing prototypes for the X edition.
|
||||||
|
* view.h: Added various missing prototypes for the X edition.
|
||||||
* widget.c (x_radio_toggle): New per-port variable: PORT_HAS_RADIO_TOGGLE
|
* widget.c (x_radio_toggle): New per-port variable: PORT_HAS_RADIO_TOGGLE
|
||||||
|
|
||||||
1998-04-15 Miguel de Icaza <miguel@nuclecu.unam.mx>
|
1998-04-15 Miguel de Icaza <miguel@nuclecu.unam.mx>
|
||||||
|
@ -29,6 +29,7 @@
|
|||||||
#include <sys/param.h>
|
#include <sys/param.h>
|
||||||
#include <malloc.h>
|
#include <malloc.h>
|
||||||
#include <signal.h>
|
#include <signal.h>
|
||||||
|
#include <ctype.h>
|
||||||
#include "global.h"
|
#include "global.h"
|
||||||
#include "mad.h" /* The great mad */
|
#include "mad.h" /* The great mad */
|
||||||
#include "util.h" /* Required by panel.h */
|
#include "util.h" /* Required by panel.h */
|
||||||
|
@ -80,6 +80,7 @@
|
|||||||
#include "user.h"
|
#include "user.h"
|
||||||
#include "setup.h"
|
#include "setup.h"
|
||||||
#include "x.h"
|
#include "x.h"
|
||||||
|
#include "profile.h"
|
||||||
|
|
||||||
#define MIDNIGHT
|
#define MIDNIGHT
|
||||||
#ifdef USE_INTERNAL_EDIT
|
#ifdef USE_INTERNAL_EDIT
|
||||||
@ -1404,7 +1405,11 @@ save_setup_cmd (void)
|
|||||||
sync_profiles ();
|
sync_profiles ();
|
||||||
str = copy_strings ( _(" Setup saved to ~/"), PROFILE_NAME, NULL);
|
str = copy_strings ( _(" Setup saved to ~/"), PROFILE_NAME, NULL);
|
||||||
|
|
||||||
|
#ifdef HAVE_GNOME
|
||||||
|
set_hintbar (str);
|
||||||
|
#else
|
||||||
message (0, _(" Setup "), str);
|
message (0, _(" Setup "), str);
|
||||||
|
#endif
|
||||||
free (str);
|
free (str);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -345,10 +345,11 @@ int remove_widget (Dlg_head *h, void *what)
|
|||||||
}
|
}
|
||||||
h->count--;
|
h->count--;
|
||||||
free (p);
|
free (p);
|
||||||
return;
|
return 1;
|
||||||
}
|
}
|
||||||
p = p->next;
|
p = p->next;
|
||||||
} while (p != first);
|
} while (p != first);
|
||||||
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
int destroy_widget (Widget *w)
|
int destroy_widget (Widget *w)
|
||||||
@ -357,6 +358,7 @@ int destroy_widget (Widget *w)
|
|||||||
if (w->destroy)
|
if (w->destroy)
|
||||||
w->destroy (w);
|
w->destroy (w);
|
||||||
free (w);
|
free (w);
|
||||||
|
return 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
int add_widget (Dlg_head *where, void *what)
|
int add_widget (Dlg_head *where, void *what)
|
||||||
|
12
src/file.c
12
src/file.c
@ -916,7 +916,7 @@ copy_file_file (char *src_path, char *dst_path, int ask_overwrite)
|
|||||||
retry_dst_stat:
|
retry_dst_stat:
|
||||||
if (mc_stat (dst_path, &sb2) == 0){
|
if (mc_stat (dst_path, &sb2) == 0){
|
||||||
if (S_ISDIR (sb2.st_mode)){
|
if (S_ISDIR (sb2.st_mode)){
|
||||||
return_status = file_error (_(" Cannot overwrite directory \"%s\" "),
|
return_status = file_error (_(" Cannot overwrite directory \"%s\" \n %s "),
|
||||||
dst_path);
|
dst_path);
|
||||||
if (return_status == FILE_RETRY)
|
if (return_status == FILE_RETRY)
|
||||||
goto retry_dst_stat;
|
goto retry_dst_stat;
|
||||||
@ -1334,7 +1334,7 @@ copy_dir_dir (char *s, char *d, int toplevel, int move_over, int delete,
|
|||||||
}
|
}
|
||||||
|
|
||||||
if (!S_ISDIR (cbuf.st_mode)){
|
if (!S_ISDIR (cbuf.st_mode)){
|
||||||
return_status = file_error (_(" Source directory \"%s\" is not a directory "), s);
|
return_status = file_error (_(" Source directory \"%s\" is not a directory \n %s "), s);
|
||||||
if (return_status == FILE_RETRY)
|
if (return_status == FILE_RETRY)
|
||||||
goto retry_src_stat;
|
goto retry_src_stat;
|
||||||
return return_status;
|
return return_status;
|
||||||
@ -1647,9 +1647,9 @@ move_dir_dir (char *s, char *d)
|
|||||||
goto oktoret;
|
goto oktoret;
|
||||||
} else {
|
} else {
|
||||||
if (S_ISDIR (destbuf.st_mode))
|
if (S_ISDIR (destbuf.st_mode))
|
||||||
return_status = file_error (_(" Cannot overwrite directory \"%s\" "), destdir);
|
return_status = file_error (_(" Cannot overwrite directory \"%s\" %s "), destdir);
|
||||||
else
|
else
|
||||||
return_status = file_error (_(" Cannot overwrite file \"%s\" "), destdir);
|
return_status = file_error (_(" Cannot overwrite file \"%s\" %s "), destdir);
|
||||||
if (return_status == FILE_RETRY)
|
if (return_status == FILE_RETRY)
|
||||||
goto retry_dst_stat;
|
goto retry_dst_stat;
|
||||||
}
|
}
|
||||||
@ -2227,7 +2227,7 @@ panel_operate (void *source_panel, int operation, char *thedefault)
|
|||||||
retry_many_dst_stat:
|
retry_many_dst_stat:
|
||||||
dst_result = mc_stat (dest, &dst_stat);
|
dst_result = mc_stat (dest, &dst_stat);
|
||||||
if (dst_result == 0 && !S_ISDIR (dst_stat.st_mode)){
|
if (dst_result == 0 && !S_ISDIR (dst_stat.st_mode)){
|
||||||
if (file_error (_(" Destination \"%s\" must be a directory "), dest) == FILE_RETRY)
|
if (file_error (_(" Destination \"%s\" must be a directory \n %s "), dest) == FILE_RETRY)
|
||||||
goto retry_many_dst_stat;
|
goto retry_many_dst_stat;
|
||||||
goto clean_up;
|
goto clean_up;
|
||||||
}
|
}
|
||||||
@ -2352,7 +2352,7 @@ real_do_file_error (enum OperationMode mode, char *error)
|
|||||||
char *msg;
|
char *msg;
|
||||||
|
|
||||||
msg = mode == Foreground ? MSG_ERROR : _(" Background process error ");
|
msg = mode == Foreground ? MSG_ERROR : _(" Background process error ");
|
||||||
result = query_dialog (msg, error, 3, 3, _("&Skip"), _("&Retry"), _("&Abort"));
|
result = query_dialog (msg, error, D_ERROR, 3, _("&Skip"), _("&Retry"), _("&Abort"));
|
||||||
|
|
||||||
switch (result){
|
switch (result){
|
||||||
case 0:
|
case 0:
|
||||||
|
@ -7,11 +7,14 @@ enum { FILE_CONT, FILE_RETRY, FILE_SKIP, FILE_ABORT };
|
|||||||
extern int verbose;
|
extern int verbose;
|
||||||
extern int know_not_what_am_i_doing;
|
extern int know_not_what_am_i_doing;
|
||||||
|
|
||||||
|
struct link;
|
||||||
|
|
||||||
int copy_file_file (char *s, char *d, int ask_overwrite);
|
int copy_file_file (char *s, char *d, int ask_overwrite);
|
||||||
int move_file_file (char *s, char *d);
|
int move_file_file (char *s, char *d);
|
||||||
int erase_dir (char *s);
|
int erase_dir (char *s);
|
||||||
int erase_dir_iff_empty (char *s);
|
int erase_dir_iff_empty (char *s);
|
||||||
int move_dir_dir (char *s, char *d);
|
int move_dir_dir (char *s, char *d);
|
||||||
|
int copy_dir_dir (char *s, char *d, int toplevel, int move_over, int delete, struct link *parent_dirs);
|
||||||
|
|
||||||
void create_op_win (int op, int with_eta);
|
void create_op_win (int op, int with_eta);
|
||||||
void destroy_op_win (void);
|
void destroy_op_win (void);
|
||||||
|
27
src/main.h
27
src/main.h
@ -148,18 +148,18 @@ enum cd_enum {
|
|||||||
cd_exact
|
cd_exact
|
||||||
};
|
};
|
||||||
|
|
||||||
int do_cd (char *new_dir, enum cd_enum cd_type); /* For find.c */
|
int do_cd (char *new_dir, enum cd_enum cd_type); /* For find.c */
|
||||||
void change_panel (void);
|
void change_panel (void);
|
||||||
void init_sigchld (void); /* For subshell.c */
|
void init_sigchld (void); /* For subshell.c */
|
||||||
int load_prompt (int fd, void *unused);
|
int load_prompt (int fd, void *unused);
|
||||||
void save_cwds_stat (void);
|
void save_cwds_stat (void);
|
||||||
void copy_prog_name (void);
|
void copy_prog_name (void);
|
||||||
int quiet_quit_cmd (void); /* For cmd.c and command.c */
|
int quiet_quit_cmd (void); /* For cmd.c and command.c */
|
||||||
int quit_cmd (void);
|
int quit_cmd (void);
|
||||||
|
|
||||||
void untouch_bar (void);
|
void untouch_bar (void);
|
||||||
void touch_bar (void);
|
void touch_bar (void);
|
||||||
void load_hint (void);
|
void load_hint (void);
|
||||||
|
|
||||||
void print_vfs_message(char *msg, ...);
|
void print_vfs_message(char *msg, ...);
|
||||||
|
|
||||||
@ -179,6 +179,15 @@ extern WLabel *process_status;
|
|||||||
extern WMenu *the_menubar;
|
extern WMenu *the_menubar;
|
||||||
|
|
||||||
extern Dlg_head *midnight_dlg;
|
extern Dlg_head *midnight_dlg;
|
||||||
|
|
||||||
|
/* Back hack to define the following routines only if the client code
|
||||||
|
* has included panel.h
|
||||||
|
*/
|
||||||
|
#ifdef __PANEL_H
|
||||||
|
void directory_history_add (WPanel *panel, char *s);
|
||||||
|
int do_panel_cd (WPanel *panel, char *new_dir, enum cd_enum cd_type);
|
||||||
|
#endif
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#ifdef OS2_NT
|
#ifdef OS2_NT
|
||||||
|
@ -1103,7 +1103,7 @@ void tree_copy (WTree *tree, char *default_dest)
|
|||||||
}
|
}
|
||||||
create_op_win (OP_COPY, 0);
|
create_op_win (OP_COPY, 0);
|
||||||
file_mask_defaults ();
|
file_mask_defaults ();
|
||||||
copy_dir_dir (tree->selected_ptr->name, dest, 1, 0);
|
copy_dir_dir (tree->selected_ptr->name, dest, 1, 0, 0, 0);
|
||||||
destroy_op_win ();
|
destroy_op_win ();
|
||||||
free (dest);
|
free (dest);
|
||||||
}
|
}
|
||||||
|
@ -105,6 +105,7 @@ void close_error_pipe (int error, char *text);
|
|||||||
/* Process spawning */
|
/* Process spawning */
|
||||||
void my_putenv (char*, char*);
|
void my_putenv (char*, char*);
|
||||||
int my_system (int as_shell_command, const char *shell, const char *command);
|
int my_system (int as_shell_command, const char *shell, const char *command);
|
||||||
|
int my_system_get_child_pid (int as_shell_command, const char *shell, const char *command, pid_t *pid);
|
||||||
void save_stop_handler (void);
|
void save_stop_handler (void);
|
||||||
extern struct sigaction startup_handler;
|
extern struct sigaction startup_handler;
|
||||||
|
|
||||||
|
@ -200,7 +200,7 @@ char *get_owner (int uid)
|
|||||||
struct passwd *pwd;
|
struct passwd *pwd;
|
||||||
static char ibuf [8];
|
static char ibuf [8];
|
||||||
char *name;
|
char *name;
|
||||||
static uid_last;
|
static int uid_last;
|
||||||
|
|
||||||
if ((name = i_cache_match (uid, uid_cache, UID_CACHE_SIZE)) != NULL)
|
if ((name = i_cache_match (uid, uid_cache, UID_CACHE_SIZE)) != NULL)
|
||||||
return name;
|
return name;
|
||||||
|
@ -670,7 +670,7 @@ view_init (WView *view, char *_command, char *_file, int start_line)
|
|||||||
/* {{{ Screen update functions */
|
/* {{{ Screen update functions */
|
||||||
|
|
||||||
#ifndef HAVE_X
|
#ifndef HAVE_X
|
||||||
static void
|
void
|
||||||
view_percent (WView *view, int p, int w)
|
view_percent (WView *view, int p, int w)
|
||||||
{
|
{
|
||||||
int percent;
|
int percent;
|
||||||
@ -690,7 +690,7 @@ view_percent (WView *view, int p, int w)
|
|||||||
printw ("%3d%% ", percent);
|
printw ("%3d%% ", percent);
|
||||||
}
|
}
|
||||||
|
|
||||||
static void
|
void
|
||||||
view_status (WView *view)
|
view_status (WView *view)
|
||||||
{
|
{
|
||||||
int w = view->widget.cols - (view->have_frame * 2);
|
int w = view->widget.cols - (view->have_frame * 2);
|
||||||
|
29
src/view.h
29
src/view.h
@ -117,17 +117,19 @@ int view_init (WView *view, char *_command, char *_file, int start_line);
|
|||||||
int view_file (char *filename, int normal, int internal);
|
int view_file (char *filename, int normal, int internal);
|
||||||
|
|
||||||
/* Internal view routines */
|
/* Internal view routines */
|
||||||
void view_update (WView *view);
|
void view_status (WView *);
|
||||||
void view_labels (WView *view);
|
void view_percent (WView *, int, int);
|
||||||
int view_event (WView *view, Gpm_Event *event,int *result);
|
void view_update (WView *view);
|
||||||
void toggle_wrap_mode (WView *);
|
void view_labels (WView *view);
|
||||||
void toggle_hex_mode (WView *);
|
int view_event (WView *view, Gpm_Event *event,int *result);
|
||||||
void goto_line (WView *);
|
void toggle_wrap_mode (WView *);
|
||||||
void regexp_search_cmd (WView *);
|
void toggle_hex_mode (WView *);
|
||||||
void normal_search_cmd (WView *);
|
void goto_line (WView *);
|
||||||
void continue_search (WView *);
|
void regexp_search_cmd (WView *);
|
||||||
void change_nroff (WView *view);
|
void normal_search_cmd (WView *);
|
||||||
void set_monitor (WView *view, int set_on);
|
void continue_search (WView *);
|
||||||
|
void change_nroff (WView *view);
|
||||||
|
void set_monitor (WView *view, int set_on);
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
/* Command: view a file, if _command != NULL we use popen on _command */
|
/* Command: view a file, if _command != NULL we use popen on _command */
|
||||||
@ -172,6 +174,11 @@ void view_display_clean (WView *view, int h, int w);
|
|||||||
void view_move_backward (WView *view, int i);
|
void view_move_backward (WView *view, int i);
|
||||||
void view_move_forward (WView *view, int i);
|
void view_move_forward (WView *view, int i);
|
||||||
|
|
||||||
|
void x_destroy_view (WView *);
|
||||||
|
void x_create_viewer (WView *);
|
||||||
|
void x_focus_view (WView *);
|
||||||
|
void x_init_view (WView *);
|
||||||
|
|
||||||
#ifdef PORT_HAS_VIEW_FREEZE
|
#ifdef PORT_HAS_VIEW_FREEZE
|
||||||
void view_freeze (WView *view);
|
void view_freeze (WView *view);
|
||||||
void view_thaw (WView *view);
|
void view_thaw (WView *view);
|
||||||
|
13
src/widget.h
13
src/widget.h
@ -217,4 +217,17 @@ void redraw_labels (Dlg_head *h, Widget *paneletc);
|
|||||||
WButtonBar *find_buttonbar (Dlg_head *h, Widget *paneletc);
|
WButtonBar *find_buttonbar (Dlg_head *h, Widget *paneletc);
|
||||||
void buttonbar_hint (WButtonBar *bb, char *s);
|
void buttonbar_hint (WButtonBar *bb, char *s);
|
||||||
|
|
||||||
|
#ifdef HAVE_X
|
||||||
|
int x_create_radio (Dlg_head *h, widget_data parent, WRadio *r);
|
||||||
|
int x_create_check (Dlg_head *h, widget_data parent, WCheck *c);
|
||||||
|
int x_create_label (Dlg_head *h, widget_data parent, WLabel *l);
|
||||||
|
int x_create_input (Dlg_head *h, widget_data parent, WInput *in);
|
||||||
|
int x_create_listbox (Dlg_head *h, widget_data parent, WListbox *l);
|
||||||
|
int x_create_buttonbar (Dlg_head *h, widget_data parent, WButtonBar *bb);
|
||||||
|
|
||||||
|
void x_listbox_select_nth (WListbox *, int);
|
||||||
|
void x_list_insert (WListbox *, WLEntry *, WLEntry *);
|
||||||
|
void x_redefine_label (WButtonBar *, int);
|
||||||
|
#endif
|
||||||
|
|
||||||
#endif /* __WIDGET_H */
|
#endif /* __WIDGET_H */
|
||||||
|
Загрузка…
x
Ссылка в новой задаче
Block a user