mirror of
https://github.com/MidnightCommander/mc
synced 2024-12-22 20:36:50 +03:00
Wow! The file manager looks so slick!
Today: - New Menu layout! Weeee!. - More mc commands exposed to the GNOME edition. - Use gnome stock pixmap buttons. - Use gnome stock for the menus. - Now it is possible to quit the program :-) - Various other bits. If you can test it, I would appreciate it. -Miguel.
This commit is contained in:
parent
1ee3e159aa
commit
791b34236c
@ -1,3 +1,15 @@
|
||||
Thu Mar 12 21:29:33 1998 Miguel de Icaza <miguel@nuclecu.unam.mx>
|
||||
|
||||
* gwidget.c (listbox_select): Fix for the listbox selection with
|
||||
the mouse.
|
||||
(x_create_button): Use stock pixmaps.
|
||||
|
||||
* gcmd.c: Moved all of the _cmd routines from glayout to this
|
||||
place.
|
||||
(save_panel_types): Provide GNOME implementation.
|
||||
|
||||
* glayout.c: New and improved menu layout. Use stock pixmaps.
|
||||
|
||||
1998-03-12 Federico Mena Quintero <federico@nuclecu.unam.mx>
|
||||
|
||||
* gmc-chargrid.c (gmc_char_grid_draw): Someone teach me how to
|
||||
|
@ -28,6 +28,7 @@ GNOMESRCS = \
|
||||
gutil.c \
|
||||
gtrans.c \
|
||||
gview.c \
|
||||
gcmd.c \
|
||||
gmc-chargrid.c
|
||||
|
||||
GNOMEHDRS = \
|
||||
@ -35,6 +36,7 @@ GNOMEHDRS = \
|
||||
gscreen.h \
|
||||
gwidget.h \
|
||||
gconf.h \
|
||||
gcmd.h \
|
||||
gmc-chargrid.h
|
||||
|
||||
#
|
||||
@ -54,8 +56,21 @@ OOBJS = main.o dlg.o screen.o widget.o wtools.o info.o boxes.o \
|
||||
option.o cmd.o utilunix.o dirhist.o popt.o xslint.o
|
||||
|
||||
OBJS = $(LOBJS) $(OOBJS) \
|
||||
gkey.o gmain.o gscreen.o gwidget.o gmenu.o ghelp.o ginfo.o \
|
||||
glayout.o gtools.o gdesktop.o gtrans.o gutil.o gmc-chargrid.o gview.o
|
||||
gkey.o \
|
||||
gmain.o \
|
||||
gscreen.o \
|
||||
gwidget.o \
|
||||
gmenu.o \
|
||||
ghelp.o \
|
||||
ginfo.o \
|
||||
glayout.o \
|
||||
gtools.o \
|
||||
gdesktop.o \
|
||||
gtrans.o \
|
||||
gutil.o \
|
||||
gcmd.o \
|
||||
gmc-chargrid.o \
|
||||
gview.o
|
||||
|
||||
#
|
||||
# Distribution variables
|
||||
|
@ -1,4 +1,120 @@
|
||||
/* XPM */
|
||||
static char * xpm_new[] = {
|
||||
"24 24 89 1",
|
||||
" c None",
|
||||
". c #000000",
|
||||
"+ c #ADAD9C",
|
||||
"@ c #959585",
|
||||
"# c #DCDCC5",
|
||||
"$ c #DFDFC8",
|
||||
"% c #242424",
|
||||
"& c #A7A796",
|
||||
"* c #D7D7C1",
|
||||
"= c #D9D9C3",
|
||||
"- c #DCDCC4",
|
||||
"; c #DDDDC7",
|
||||
"> c #E1E1CA",
|
||||
", c #A6A694",
|
||||
"' c #D6D6BF",
|
||||
") c #D8D8C2",
|
||||
"! c #DBDBC4",
|
||||
"~ c #DFDFC7",
|
||||
"{ c #E3E3CB",
|
||||
"] c #B2B29F",
|
||||
"^ c #7C7C7C",
|
||||
"/ c #646464",
|
||||
"( c #D5D5BD",
|
||||
"_ c #D5D5BF",
|
||||
": c #D7D7C0",
|
||||
"< c #DADAC3",
|
||||
"[ c #DEDEC6",
|
||||
"} c #E1E1C9",
|
||||
"| c #E5E5CD",
|
||||
"1 c #E9E9D1",
|
||||
"2 c #343434",
|
||||
"3 c #E7E7E7",
|
||||
"4 c #373736",
|
||||
"5 c #B8B8A6",
|
||||
"6 c #D3D3BC",
|
||||
"7 c #D9D9C2",
|
||||
"8 c #DDDDC5",
|
||||
"9 c #E0E0C8",
|
||||
"0 c #E8E8D0",
|
||||
"a c #ECECD4",
|
||||
"b c #EEEED5",
|
||||
"c c #ECECEC",
|
||||
"d c #EDEDED",
|
||||
"e c #3D3D37",
|
||||
"f c #CECEB7",
|
||||
"g c #E6E6CE",
|
||||
"h c #EAEAD2",
|
||||
"i c #F1F1D8",
|
||||
"j c #A5A594",
|
||||
"k c #EEEEE5",
|
||||
"l c #3C3C3C",
|
||||
"m c #8F8F80",
|
||||
"n c #D0D0B9",
|
||||
"o c #E4E4CB",
|
||||
"p c #EAEAD1",
|
||||
"q c #ECECD3",
|
||||
"r c #EFEFD6",
|
||||
"s c #F2F2D9",
|
||||
"t c #F3F3DA",
|
||||
"u c #EEEEE6",
|
||||
"v c #505050",
|
||||
"w c #929282",
|
||||
"x c #D1D1B9",
|
||||
"y c #E7E7CF",
|
||||
"z c #EBEBD2",
|
||||
"A c #F4F4DB",
|
||||
"B c #F5F5DC",
|
||||
"C c #969686",
|
||||
"D c #D2D2BC",
|
||||
"E c #E0E0C9",
|
||||
"F c #E9E9D0",
|
||||
"G c #EDEDD4",
|
||||
"H c #F0F0D7",
|
||||
"I c #BEBEAB",
|
||||
"J c #797973",
|
||||
"K c #D8D8C1",
|
||||
"L c #DDDDC6",
|
||||
"M c #98988F",
|
||||
"N c #E4E4CC",
|
||||
"O c #818174",
|
||||
"P c #E2E2CA",
|
||||
"Q c #BEBEAE",
|
||||
"R c #4E4E4E",
|
||||
"S c #828274",
|
||||
"T c #EBEBD3",
|
||||
"U c #BBBBA8",
|
||||
"V c #CDCDB8",
|
||||
"W c #4D4D45",
|
||||
"X c #A6A696",
|
||||
" ",
|
||||
" ",
|
||||
" . ",
|
||||
" ..+. ",
|
||||
" ..@#$% ",
|
||||
" ..&*=-;>. ",
|
||||
" ..,'**)!~{]. ",
|
||||
" .^/'(_:<[}|12 ",
|
||||
" .3456*789|0ab. ",
|
||||
" .cdef_!9g0hbij. ",
|
||||
" .kklmn9opqrist. ",
|
||||
" .uvwx-}yzbittAB. ",
|
||||
" ..CD!E{FGHtAABBI. ",
|
||||
" .JK7L>ypbitBBBBB). ",
|
||||
" .M!#$NyzbitBBBBBO. ",
|
||||
" .~9P|1qrsABBBB.. ",
|
||||
" .Q||0hGHtABB<. ",
|
||||
" R01hGrstAsS. ",
|
||||
" .TaGriss<. ",
|
||||
" .rHis1j. ",
|
||||
" .UstVW. ",
|
||||
" .tX. ",
|
||||
" .. ",
|
||||
" "};
|
||||
/* XPM */
|
||||
static char * directory_xpm[] = {
|
||||
"16 13 5 1",
|
||||
" c None",
|
||||
@ -19,3 +135,4 @@ static char * directory_xpm[] = {
|
||||
".XooooooooooooO.",
|
||||
".oOOOOOOOOOOOOO.",
|
||||
"................"};
|
||||
|
||||
|
@ -22,6 +22,7 @@
|
||||
#define PORT_NOT_UNFOCUS_UNSELECT_ITEM 1
|
||||
#define PORT_WANTS_VIEW 1
|
||||
#define PORT_HAS_VIEW_FREEZE 1
|
||||
#define PORT_HAS_SAVE_PANEL_TYPES 1
|
||||
|
||||
#define mi_getch() fprintf (stderr, "mi_getch is not implemented in this port\n")
|
||||
#define frontend_run_dlg(x) gtkrundlg_event (x)
|
||||
|
113
gnome/glayout.c
113
gnome/glayout.c
@ -1,3 +1,10 @@
|
||||
/*
|
||||
* Layout routines for the GNOME edition of the GNU Midnight Commander
|
||||
*
|
||||
* (C) 1998 the Free Software Foundation
|
||||
*
|
||||
* Author: Miguel de Icaza (miguel@kernel.org)
|
||||
*/
|
||||
#include <config.h>
|
||||
#include "x.h"
|
||||
#include <stdio.h>
|
||||
@ -8,6 +15,8 @@
|
||||
#include "main.h"
|
||||
#include "cmd.h"
|
||||
#include "boxes.h"
|
||||
#include "panelize.h"
|
||||
#include "gcmd.h"
|
||||
|
||||
#define UNDEFINED_INDEX -1
|
||||
|
||||
@ -159,45 +168,93 @@ get_panel_widget (int index)
|
||||
return (Widget *) ((PanelContainer *)p->data)->panel;
|
||||
}
|
||||
|
||||
void
|
||||
gnome_listing_cmd (GtkWidget *widget, WPanel *panel)
|
||||
/* FIXME: This routine is wrong. It should follow what the original save_panel_types
|
||||
* does. I can not remember which problem the original routine was trying to address
|
||||
* when I did the "New {Left|Rigth} Panel" sections.
|
||||
*/
|
||||
void save_panel_types (void)
|
||||
{
|
||||
GtkAllocation *alloc = >K_WIDGET (panel->list)->allocation;
|
||||
int view_type, use_msformat;
|
||||
char *user, *status;
|
||||
GList *p;
|
||||
|
||||
view_type = display_box (panel, &user, &status, &use_msformat, get_current_index ());
|
||||
|
||||
if (view_type == -1)
|
||||
return;
|
||||
for (p = containers; p; p = p->next){
|
||||
PanelContainer *pc = p->data;
|
||||
|
||||
configure_panel_listing (panel, view_type, use_msformat, user, status);
|
||||
panel_save_setup (pc->panel, pc->panel->panel_name);
|
||||
}
|
||||
}
|
||||
|
||||
void configure_box (void);
|
||||
|
||||
GnomeUIInfo gnome_panel_filemenu [] = {
|
||||
{ GNOME_APP_UI_ITEM, "Network link...", NULL, netlink_cmd },
|
||||
{ GNOME_APP_UI_ITEM, "FTP link...", NULL, ftplink_cmd },
|
||||
{ GNOME_APP_UI_ITEM, "Display mode...", NULL, gnome_listing_cmd },
|
||||
{ GNOME_APP_UI_ITEM, "Sort order...", NULL, sort_cmd },
|
||||
{ GNOME_APP_UI_ITEM, "Filter...", NULL, filter_cmd },
|
||||
{ GNOME_APP_UI_ITEM, "Rescan", NULL, reread_cmd },
|
||||
{ GNOME_APP_UI_ITEM, "Find", NULL, find_cmd },
|
||||
{ GNOME_APP_UI_ITEM, "Hotlist", NULL, quick_chdir_cmd },
|
||||
#ifdef USE_VFS
|
||||
{ GNOME_APP_UI_ITEM, "Active VFS", NULL, reselect_vfs },
|
||||
#endif
|
||||
{ GNOME_APP_UI_ITEM, "Confirmation", NULL, confirm_box },
|
||||
{ GNOME_APP_UI_ITEM, "Options", NULL, configure_box },
|
||||
{ GNOME_APP_UI_ITEM, "Virtual FS", NULL, configure_vfs },
|
||||
{ GNOME_APP_UI_ITEM, "Save setup", NULL, save_setup_cmd },
|
||||
{ GNOME_APP_UI_ITEM, "Mkdir", NULL, mkdir_cmd },
|
||||
GnomeUIInfo gnome_panel_file_menu [] = {
|
||||
{ GNOME_APP_UI_ITEM, "Open Terminal", "Opens a terminal", gnome_open_terminal },
|
||||
{ GNOME_APP_UI_ITEM, "Copy", "Copy files", copy_cmd },
|
||||
{ GNOME_APP_UI_ITEM, "Rename/Move", "Rename or move files", ren_cmd },
|
||||
{ GNOME_APP_UI_ITEM, "Mkdir", "Creates a new folder", mkdir_cmd },
|
||||
{ GNOME_APP_UI_ITEM, "Delete", "Delete files from disk", delete_cmd },
|
||||
{ GNOME_APP_UI_SEPARATOR },
|
||||
{ GNOME_APP_UI_ITEM, "Select group", "Selects a group of files", select_cmd },
|
||||
{ GNOME_APP_UI_ITEM, "Unselect group", "Un-selects a group of marked files", select_cmd },
|
||||
{ GNOME_APP_UI_ITEM, "Reverse selection", "Reverses the list of tagged files", reverse_selection_cmd },
|
||||
{ GNOME_APP_UI_SEPARATOR },
|
||||
{ GNOME_APP_UI_ITEM, "Exit", "Exit program", gnome_quit_cmd, NULL, NULL,
|
||||
GNOME_APP_PIXMAP_STOCK, GNOME_STOCK_MENU_EXIT },
|
||||
{ GNOME_APP_UI_ENDOFINFO, 0, 0 }
|
||||
};
|
||||
|
||||
GnomeUIInfo gnome_panel_panel_menu [] = {
|
||||
{ GNOME_APP_UI_ITEM, "Display mode...", "Set the display mode for the panel", gnome_listing_cmd },
|
||||
{ GNOME_APP_UI_ITEM, "Sort order...", "Changes the sort order of the files", sort_cmd },
|
||||
{ GNOME_APP_UI_ITEM, "Filter...", "Set a filter for the files", filter_cmd },
|
||||
{ GNOME_APP_UI_ITEM, "Rescan", "Rescan the directory contents", reread_cmd },
|
||||
{ GNOME_APP_UI_SEPARATOR },
|
||||
#ifdef USE_NETCODE
|
||||
{ GNOME_APP_UI_ITEM, "Network link...", "Connect to a remote machine", netlink_cmd },
|
||||
{ GNOME_APP_UI_ITEM, "FTP link...", "Connect to a remote machine with FTP", ftplink_cmd },
|
||||
#endif
|
||||
{ GNOME_APP_UI_ENDOFINFO, 0, 0 }
|
||||
};
|
||||
|
||||
GnomeUIInfo gnome_panel_options_menu [] = {
|
||||
{ GNOME_APP_UI_ITEM, "Confirmation", "Confirmation settings", confirm_box },
|
||||
{ GNOME_APP_UI_ITEM, "Options", "Global option settings", configure_box, NULL, NULL,
|
||||
GNOME_APP_PIXMAP_STOCK, GNOME_STOCK_MENU_PROP },
|
||||
#ifdef USE_VFS
|
||||
{ GNOME_APP_UI_ITEM, "Virtual FS", "Virtual File System settings", configure_vfs },
|
||||
#endif
|
||||
{ GNOME_APP_UI_SEPARATOR },
|
||||
{ GNOME_APP_UI_ITEM, "Save setup", NULL, save_setup_cmd },
|
||||
{ GNOME_APP_UI_ENDOFINFO, 0, 0 }
|
||||
};
|
||||
|
||||
GnomeUIInfo gnome_panel_commands_menu [] = {
|
||||
{ GNOME_APP_UI_ITEM, "Find", "Locate files on disk", find_cmd },
|
||||
{ GNOME_APP_UI_ITEM, "Hotlist", "List of favorite sites", quick_chdir_cmd },
|
||||
{ GNOME_APP_UI_ITEM, "Compare panels", "Compare panel contents", gnome_compare_panels },
|
||||
{ GNOME_APP_UI_ITEM, "External panelize", NULL, external_panelize },
|
||||
#ifdef USE_VFS
|
||||
{ GNOME_APP_UI_ITEM, "Active VFS list", "List of active virtual file systems", reselect_vfs },
|
||||
#endif
|
||||
#ifdef USE_EXT2FSLIB
|
||||
{ GNOME_APP_UI_ITEM, "Undelete files (ext2fs only)", "Recover deleted files", undelete_cmd },
|
||||
#endif
|
||||
#ifdef WITH_BACKGROUND
|
||||
{ GNOME_APP_UI_ITEM, "Background jobs", "List of background operations", jobs_cmd },
|
||||
#endif
|
||||
{ GNOME_APP_UI_ENDOFINFO, 0, 0 }
|
||||
};
|
||||
|
||||
GnomeUIInfo gnome_panel_about_menu [] = {
|
||||
GNOMEUIINFO_ITEM ("About", "Information on this program", gnome_about_cmd, NULL),
|
||||
GNOMEUIINFO_HELP ("midnight-commander"),
|
||||
GNOMEUIINFO_END
|
||||
};
|
||||
|
||||
GnomeUIInfo gnome_panel_menu [] = {
|
||||
{ GNOME_APP_UI_SUBTREE, "This is a temporal menu, it will go away", NULL, &gnome_panel_filemenu },
|
||||
{ GNOME_APP_UI_SUBTREE, "File", NULL, &gnome_panel_file_menu },
|
||||
{ GNOME_APP_UI_SUBTREE, "Panel", NULL, &gnome_panel_panel_menu },
|
||||
{ GNOME_APP_UI_SUBTREE, "Commands", NULL, &gnome_panel_commands_menu },
|
||||
{ GNOME_APP_UI_SUBTREE, "Options", NULL, &gnome_panel_options_menu },
|
||||
{ GNOME_APP_UI_SUBTREE, "Help", NULL, &gnome_panel_about_menu },
|
||||
{ GNOME_APP_UI_ENDOFINFO, 0, 0 }
|
||||
};
|
||||
|
||||
|
@ -317,8 +317,10 @@ static struct {
|
||||
int flags;
|
||||
context_menu_callback callback;
|
||||
} file_actions [] = {
|
||||
#if 0
|
||||
{ "Info", 0, NULL },
|
||||
{ "", 0, NULL },
|
||||
#endif
|
||||
{ "Open", F_ALL, panel_action_open },
|
||||
{ "Open with", F_ALL, panel_action_open_with },
|
||||
{ "View", F_ALL, panel_action_view },
|
||||
@ -555,6 +557,7 @@ panel_file_list_compute_lines (GtkCList *file_list, WPanel *panel, int height)
|
||||
static void
|
||||
panel_file_list_size_allocate_hook (GtkWidget *file_list, GtkAllocation *allocation, WPanel *panel)
|
||||
{
|
||||
printf ("%d %d\n", allocation->width, allocation->height);
|
||||
gtk_signal_handler_block_by_data (GTK_OBJECT (file_list), panel);
|
||||
panel_file_list_configure_contents (file_list, panel, allocation->width, allocation->height);
|
||||
gtk_signal_handler_unblock_by_data (GTK_OBJECT (file_list), panel);
|
||||
@ -760,7 +763,7 @@ fixed_gtk_widget_dnd_drag_set (GtkCList *clist, int drag_enable, gchar **type_ac
|
||||
static void
|
||||
panel_drag_begin (GtkWidget *widget, GdkEvent *event, WPanel *panel)
|
||||
{
|
||||
GdkPoint hotspot = { 5, 5 };
|
||||
GdkPoint hotspot = { 15, 15 };
|
||||
|
||||
printf ("Drag starting\n");
|
||||
if (panel->marked){
|
||||
@ -1026,7 +1029,7 @@ x_create_panel (Dlg_head *h, widget_data parent, WPanel *panel)
|
||||
GTK_EXPAND | GTK_FILL, GTK_SHRINK, 0, 0);
|
||||
|
||||
gtk_table_attach (GTK_TABLE (panel->table), statusbar, 0, 1, 2, 3,
|
||||
GTK_EXPAND | GTK_FILL | GTK_SHRINK,
|
||||
GTK_EXPAND | GTK_FILL,
|
||||
0, 0, 0);
|
||||
|
||||
gtk_widget_show (panel->table);
|
||||
@ -1078,7 +1081,7 @@ load_hint (void)
|
||||
set_hintbar (hint);
|
||||
free (hint);
|
||||
} else
|
||||
set_hintbar ("The GNOME Midnight Commander " VERSION " (C) 1995-1998 the FSF");
|
||||
set_hintbar ("The GNOME File Manager " VERSION);
|
||||
|
||||
}
|
||||
|
||||
|
@ -1,5 +1,5 @@
|
||||
/*
|
||||
* The GNOME file viewer backend
|
||||
* The GNOME file viewer frontend
|
||||
* (C) The Free Software Foundation
|
||||
*
|
||||
* Author: Miguel de Icaza (miguel@gnu.org)
|
||||
|
@ -56,9 +56,29 @@ int
|
||||
x_create_button (Dlg_head *h, widget_data parent, WButton *b)
|
||||
{
|
||||
GtkWidget *button;
|
||||
char *stock;
|
||||
int tag;
|
||||
|
||||
if (strcasecmp (b->text, "ok") == 0)
|
||||
stock = GNOME_STOCK_BUTTON_OK;
|
||||
else if (strcasecmp (b->text, "cancel") == 0)
|
||||
stock = GNOME_STOCK_BUTTON_CANCEL;
|
||||
else if (strcasecmp (b->text, "help") == 0)
|
||||
stock = GNOME_STOCK_BUTTON_HELP;
|
||||
else if (strcasecmp (b->text, "yes") == 0)
|
||||
stock = GNOME_STOCK_BUTTON_YES;
|
||||
else if (strcasecmp (b->text, "no") == 0)
|
||||
stock = GNOME_STOCK_BUTTON_NO;
|
||||
else if (strcasecmp (b->text, "exit") == 0)
|
||||
stock = GNOME_STOCK_BUTTON_CLOSE;
|
||||
else
|
||||
stock = 0;
|
||||
|
||||
if (stock){
|
||||
button = gnome_stock_button (stock);
|
||||
} else
|
||||
button = gtk_button_new_with_label (b->text);
|
||||
|
||||
button = gtk_button_new_with_label (b->text);
|
||||
gtk_widget_show (button);
|
||||
tag = gtk_signal_connect (GTK_OBJECT(button), "clicked", (GtkSignalFunc) gbutton_callback, b);
|
||||
gtk_object_set_data (GTK_OBJECT (button), "click-signal-tag", (void *) tag);
|
||||
@ -241,7 +261,12 @@ listbox_select (GtkWidget *widget, int row, int column, GdkEvent *event, WListbo
|
||||
|
||||
listbox_select_by_number (l, row);
|
||||
|
||||
if (event && event->type == GDK_2BUTTON_PRESS){
|
||||
if (!event){
|
||||
inside = 0;
|
||||
return;
|
||||
}
|
||||
|
||||
if (event->type == GDK_2BUTTON_PRESS){
|
||||
printf ("Activando\n");
|
||||
switch (l->action){
|
||||
case listbox_nothing:
|
||||
@ -259,6 +284,9 @@ listbox_select (GtkWidget *widget, int row, int column, GdkEvent *event, WListbo
|
||||
return;
|
||||
}
|
||||
}
|
||||
}
|
||||
if (event->type = GDK_BUTTON_PRESS){
|
||||
|
||||
}
|
||||
inside = 0;
|
||||
}
|
||||
@ -334,7 +362,8 @@ x_create_label (Dlg_head *g, widget_data parent, WLabel *l)
|
||||
void
|
||||
x_label_set_text (WLabel *label, char *text)
|
||||
{
|
||||
gtk_label_set (GTK_LABEL (label->widget.wdata), text);
|
||||
if (label->widget.wdata)
|
||||
gtk_label_set (GTK_LABEL (label->widget.wdata), text);
|
||||
}
|
||||
|
||||
/* Buttonbar */
|
||||
|
69
gnome/layout
69
gnome/layout
@ -615,3 +615,72 @@ flags=ew
|
||||
[quick_symlink-Widget-cancel]
|
||||
geometry=4,6,1,1
|
||||
flags=
|
||||
|
||||
[panelize-Widget-l]
|
||||
geometry=1,4,1,1
|
||||
flags=
|
||||
|
||||
[panelize-Widget-r]
|
||||
geometry=2,4,1,1
|
||||
flags=
|
||||
|
||||
[panelize-Widget-a]
|
||||
geometry=3,4,1,1
|
||||
flags=
|
||||
|
||||
[panelize-Widget-c]
|
||||
geometry=4,4,1,1
|
||||
flags=
|
||||
|
||||
[panelize-Widget-li]
|
||||
geometry=0,0,6,1
|
||||
flags=ew
|
||||
|
||||
[panelize-Widget-label-command]
|
||||
geometry=0,1,1,1
|
||||
flags=w
|
||||
|
||||
[panelize-Widget-in]
|
||||
geometry=0,2,6,1
|
||||
flags=ew
|
||||
|
||||
[vfshot-Frame-Frame-0]
|
||||
geometry=0,2,8,5
|
||||
flags=snew
|
||||
text=Directory path
|
||||
|
||||
[vfshot-Widget-ct]
|
||||
geometry=2,7,1,1
|
||||
flags=
|
||||
|
||||
[vfshot-Widget-cc]
|
||||
geometry=4,7,1,1
|
||||
flags=
|
||||
|
||||
[vfshot-Widget-the-lab]
|
||||
geometry=2,5,4,1
|
||||
flags=w
|
||||
|
||||
[vfshot-Widget-listbox]
|
||||
geometry=1,0,5,1
|
||||
flags=ew
|
||||
|
||||
[jobs-Widget-button-ok]
|
||||
geometry=11,2,1,1
|
||||
flags=
|
||||
|
||||
[jobs-Widget-listbox]
|
||||
geometry=0,0,14,1
|
||||
flags=ew
|
||||
|
||||
[jobs-Widget-button-cont]
|
||||
geometry=2,2,1,1
|
||||
flags=
|
||||
|
||||
[jobs-Widget-button-kill]
|
||||
geometry=3,2,1,1
|
||||
flags=
|
||||
|
||||
[jobs-Widget-button-stop]
|
||||
geometry=1,2,1,1
|
||||
flags=
|
||||
|
@ -1,3 +1,17 @@
|
||||
Thu Mar 12 21:08:36 1998 Miguel de Icaza <miguel@nuclecu.unam.mx>
|
||||
|
||||
* setup.c (save_panel_types): Do not use if running on the gnome
|
||||
edition. This need a lot of fixing for making this work with
|
||||
gnome and session management.
|
||||
|
||||
* main.c (do_nc): DO not call setup_panels_and_run_mc as
|
||||
create_panels in gnome edition does all this.
|
||||
|
||||
(setup_mc): Skip part of the setup.
|
||||
|
||||
(do_execute): Do not Execute any of the pause code after
|
||||
run for gnome.
|
||||
|
||||
Wed Mar 12 17:46:09 1998 Norbert Warmuth <k3190@fh-sw.de>
|
||||
|
||||
* screen.c (chdir_other_panel, chdir_to_readlink): Use passed
|
||||
|
@ -793,7 +793,7 @@ jobs_cmd (void)
|
||||
bg_list = listbox_new (2, 3, JOBS_X-7, JOBS_Y-9, listbox_nothing, 0, "listbox");
|
||||
add_widget (jobs_dlg, bg_list);
|
||||
add_widget (jobs_dlg,
|
||||
button_new (JOBS_Y-4, 35, B_CANCEL, NORMAL_BUTTON, "&Ok", 0, 0, "button-kill"));
|
||||
button_new (JOBS_Y-4, 35, B_CANCEL, NORMAL_BUTTON, "&Ok", 0, 0, "button-ok"));
|
||||
add_widget (jobs_dlg,
|
||||
button_new (JOBS_Y-4, 23, B_KILL, NORMAL_BUTTON, "&Kill", task_cb, 0, "button-kill"));
|
||||
add_widget (jobs_dlg,
|
||||
|
17
src/main.c
17
src/main.c
@ -747,6 +747,7 @@ do_execute (const char *shell, const char *command, int internal_command)
|
||||
#endif
|
||||
my_system (!internal_command, shell, command);
|
||||
|
||||
#ifndef HAVE_GNOME
|
||||
if (!internal_command){
|
||||
/* .ado: ask Juan why CONSOLE_SAVE not work here */
|
||||
#ifndef _OS_NT
|
||||
@ -774,8 +775,8 @@ do_execute (const char *shell, const char *command, int internal_command)
|
||||
handle_console (CONSOLE_SAVE);
|
||||
}
|
||||
#endif
|
||||
|
||||
}
|
||||
#endif
|
||||
|
||||
edition_post_exec ();
|
||||
|
||||
@ -1808,6 +1809,10 @@ static void setup_mc (void)
|
||||
setup_pre ();
|
||||
init_menu ();
|
||||
create_panels ();
|
||||
|
||||
#ifdef HAVE_GNOME
|
||||
return;
|
||||
#endif
|
||||
setup_panels ();
|
||||
|
||||
#ifdef HAVE_SUBSHELL_SUPPORT
|
||||
@ -2159,8 +2164,10 @@ do_nc (void)
|
||||
|
||||
setup_mc ();
|
||||
|
||||
#ifndef HAVE_GNOME
|
||||
setup_panels_and_run_mc ();
|
||||
|
||||
#endif
|
||||
|
||||
/* Program end */
|
||||
midnight_shutdown = 1;
|
||||
|
||||
@ -2173,8 +2180,8 @@ do_nc (void)
|
||||
}
|
||||
done_mc ();
|
||||
|
||||
destroy_dlg (midnight_dlg);
|
||||
#ifndef HAVE_GNOME
|
||||
destroy_dlg (midnight_dlg);
|
||||
current_panel = 0;
|
||||
#endif
|
||||
done_mc_profile ();
|
||||
@ -2849,6 +2856,10 @@ int main (int argc, char *argv [])
|
||||
#else
|
||||
init_curses ();
|
||||
#endif
|
||||
|
||||
#ifdef HAVE_GNOME
|
||||
use_subshell = 0;
|
||||
#endif
|
||||
|
||||
# ifdef HAVE_SUBSHELL_SUPPORT
|
||||
/* Done here to ensure that the subshell doesn't */
|
||||
|
@ -155,6 +155,7 @@ int load_prompt (int fd, void *unused);
|
||||
void save_cwds_stat (void);
|
||||
void copy_prog_name (void);
|
||||
int quiet_quit_cmd (void); /* For cmd.c and command.c */
|
||||
int quit_cmd (void);
|
||||
|
||||
void untouch_bar (void);
|
||||
void touch_bar (void);
|
||||
|
@ -44,6 +44,7 @@
|
||||
#include "win.h" /* lookup_key */
|
||||
#include "cmd.h"
|
||||
#include "dirhist.h" /* Directory history routines */
|
||||
#include "x.h"
|
||||
|
||||
#include "../vfs/vfs.h"
|
||||
#ifdef USE_NETCODE
|
||||
@ -307,6 +308,7 @@ static void panel_save_type (char *section, int type)
|
||||
}
|
||||
}
|
||||
|
||||
#ifndef PORT_HAS_SAVE_PANEL_TYPES
|
||||
void save_panel_types ()
|
||||
{
|
||||
int type;
|
||||
@ -320,6 +322,7 @@ void save_panel_types ()
|
||||
if (type == view_listing)
|
||||
panel_save_setup (right_panel, right_panel->panel_name);
|
||||
}
|
||||
#endif
|
||||
|
||||
void save_setup (void)
|
||||
{
|
||||
|
@ -9,6 +9,7 @@ void done_setup (void);
|
||||
void panel_save_setup ();
|
||||
void panel_load_setup ();
|
||||
void load_key_defs (void);
|
||||
void save_panel_types (void);
|
||||
char *load_anon_passwd ();
|
||||
|
||||
extern char *profile_name;
|
||||
|
@ -1955,7 +1955,7 @@ change_nroff (WView *view)
|
||||
|
||||
/* Real view only */
|
||||
static void
|
||||
quit_cmd (WView *view)
|
||||
view_quit_cmd (WView *view)
|
||||
{
|
||||
if (view_ok_to_quit (view))
|
||||
view->widget.parent->running = 0;
|
||||
@ -1969,7 +1969,7 @@ view_labels (WView *view)
|
||||
|
||||
define_label (h, (Widget *) view, 1, "Help", help_cmd);
|
||||
|
||||
my_define (h, 10, "Quit", quit_cmd, view);
|
||||
my_define (h, 10, "Quit", view_quit_cmd, view);
|
||||
my_define (h, 4, view->hex_mode ?"Ascii":"Hex", toggle_hex_mode, view);
|
||||
my_define (h, 5, "Line", goto_line, view);
|
||||
my_define (h, 6, view->hex_mode ? "Save" : "RxSrch", regexp_search_cmd, view);
|
||||
@ -1989,7 +1989,7 @@ view_labels (WView *view)
|
||||
if (!view->have_frame){
|
||||
my_define (h, 9, view->viewer_nroff_flag ? "Unform" : "Format",
|
||||
change_nroff, view);
|
||||
my_define (h, 3, "Quit", quit_cmd, view);
|
||||
my_define (h, 3, "Quit", view_quit_cmd, view);
|
||||
}
|
||||
|
||||
redraw_labels (h, (Widget *) view);
|
||||
|
Loading…
Reference in New Issue
Block a user