[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Emacs-diffs] Changes to emacs/src/emacs.c,v
From: |
Adrian Robert |
Subject: |
[Emacs-diffs] Changes to emacs/src/emacs.c,v |
Date: |
Tue, 15 Jul 2008 18:15:39 +0000 |
CVSROOT: /sources/emacs
Module name: emacs
Changes by: Adrian Robert <arobert> 08/07/15 18:15:19
Index: src/emacs.c
===================================================================
RCS file: /sources/emacs/emacs/src/emacs.c,v
retrieving revision 1.431
retrieving revision 1.432
diff -u -b -r1.431 -r1.432
--- src/emacs.c 11 Jul 2008 02:29:40 -0000 1.431
+++ src/emacs.c 15 Jul 2008 18:15:12 -0000 1.432
@@ -46,6 +46,11 @@
#include "w32heap.h" /* for prototype of sbrk */
#endif
+#ifdef NS_IMPL_GNUSTEP
+/* At least under Debian, GSConfig is in a subdirectory. --Stef */
+#include <GNUstepBase/GSConfig.h>
+#endif
+
#include "lisp.h"
#include "commands.h"
#include "intervals.h"
@@ -193,7 +198,7 @@
extern int inherited_pgroup;
#endif
-#ifdef HAVE_X_WINDOWS
+#if defined(HAVE_X_WINDOWS) || defined(HAVE_NS)
/* If non-zero, -d was specified, meaning we're using some window system. */
int display_arg;
#endif
@@ -838,7 +843,7 @@
run_time_remap (argv[0]);
#endif
-#ifdef MAC_OSX
+#if defined (MAC_OSX) || defined (NS_IMPL_COCOA)
if (!initialized)
unexec_init_emacs_zone ();
#endif
@@ -1410,6 +1415,38 @@
no_loadup
= argmatch (argv, argc, "-nl", "--no-loadup", 6, NULL, &skip_args);
+#ifdef HAVE_NS
+ ns_alloc_autorelease_pool();
+ if (!noninteractive)
+ {
+ char *tmp;
+ display_arg = 4;
+#ifdef NS_IMPL_COCOA
+ if (skip_args < argc)
+ {
+ if (!strncmp(argv[skip_args], "-psn", 4))
+ {
+ skip_args += 1;
+ }
+ else
+ {
+ if (skip_args+1 < argc && !strncmp(argv[skip_args+1], "-psn", 4))
+ skip_args += 2;
+ }
+ }
+#endif
+ /* This used for remote operation.. not fully implemented yet. */
+ if (argmatch (argv, argc, "-_NSMachLaunch", 0, 3, &tmp, &skip_args))
+ display_arg = 4;
+ else if (argmatch (argv, argc, "-MachLaunch", 0, 3, &tmp, &skip_args))
+ display_arg = 4;
+ else if (argmatch (argv, argc, "-macosx", 0, 2, NULL, &skip_args))
+ display_arg = 4;
+ else if (argmatch (argv, argc, "-NSHost", 0, 3, &tmp, &skip_args))
+ display_arg = 4;
+ }
+#endif /* HAVE_NS */
+
#ifdef HAVE_X_WINDOWS
/* Stupid kludge to catch command-line display spec. We can't
handle this argument entirely in window system dependent code
@@ -1487,6 +1524,13 @@
init_mac_osx_environment ();
#endif
+#ifdef HAVE_NS
+#ifndef CANNOT_DUMP
+ if (initialized)
+#endif
+ ns_init_paths ();
+#endif
+
/* egetenv is a pretty low-level facility, which may get called in
many circumstances; it seems flimsy to put off initializing it
until calling init_callproc. */
@@ -1588,6 +1632,7 @@
#ifdef HAVE_X_WINDOWS
syms_of_xterm ();
syms_of_xfns ();
+ syms_of_xmenu ();
syms_of_fontset ();
#ifdef HAVE_X_SM
syms_of_xsmfns ();
@@ -1599,13 +1644,6 @@
syms_of_menu ();
-#ifndef HAVE_NTGUI
-#ifndef MAC_OS
- /* Called before init_window_once for Mac OS Classic. */
- syms_of_xmenu ();
-#endif
-#endif
-
#ifdef HAVE_NTGUI
syms_of_w32term ();
syms_of_w32fns ();
@@ -1622,6 +1660,14 @@
syms_of_fontset ();
#endif /* MAC_OSX && HAVE_CARBON */
+#ifdef HAVE_NS
+ syms_of_nsterm ();
+ syms_of_nsfns ();
+ syms_of_nsmenu ();
+ syms_of_nsselect ();
+ syms_of_fontset ();
+#endif /* HAVE_NS */
+
#ifdef HAVE_DBUS
syms_of_dbusbind ();
#endif /* HAVE_DBUS */
@@ -1843,6 +1889,15 @@
{ "-color", "--color", 5, 0},
{ "-no-splash", "--no-splash", 3, 0 },
{ "-no-desktop", "--no-desktop", 3, 0 },
+#ifdef HAVE_NS
+ { "-NSAutoLaunch", 0, 5, 1 },
+ { "-NXAutoLaunch", 0, 5, 1 },
+ { "-disable-font-backend", "--disable-font-backend", 65, 0 },
+ { "-_NSMachLaunch", 0, 85, 1 },
+ { "-MachLaunch", 0, 85, 1 },
+ { "-macosx", 0, 85, 0 },
+ { "-NSHost", 0, 85, 1 },
+#endif
/* These have the same priority as ordinary file name args,
so they are not reordered with respect to those. */
{ "-L", "--directory", 0, 1 },
@@ -1862,6 +1917,13 @@
{ "-visit", "--visit", 0, 1 },
{ "-file", "--file", 0, 1 },
{ "-insert", "--insert", 0, 1 },
+#ifdef HAVE_NS
+ { "-NXOpen", 0, 0, 1 },
+ { "-NXOpenTemp", 0, 0, 1 },
+ { "-NSOpen", 0, 0, 1 },
+ { "-NSOpenTemp", 0, 0, 1 },
+ { "-GSFilePath", 0, 0, 1 },
+#endif
/* This should be processed after ordinary file name args and the like. */
{ "-kill", "--kill", -10, 0 },
};
@@ -2158,6 +2220,10 @@
#ifdef MSDOS
dos_cleanup ();
#endif
+
+#ifdef HAVE_NS
+ ns_term_shutdown (sig);
+#endif
}
- [Emacs-diffs] Changes to emacs/src/emacs.c,v, Dan Nicolaescu, 2008/07/10
- [Emacs-diffs] Changes to emacs/src/emacs.c,v,
Adrian Robert <=
- [Emacs-diffs] Changes to emacs/src/emacs.c,v, Glenn Morris, 2008/07/15
- [Emacs-diffs] Changes to emacs/src/emacs.c,v, Dan Nicolaescu, 2008/07/16
- [Emacs-diffs] Changes to emacs/src/emacs.c,v, Dan Nicolaescu, 2008/07/23
- [Emacs-diffs] Changes to emacs/src/emacs.c,v, Dan Nicolaescu, 2008/07/23
- [Emacs-diffs] Changes to emacs/src/emacs.c,v, Dan Nicolaescu, 2008/07/23
- [Emacs-diffs] Changes to emacs/src/emacs.c,v, Dan Nicolaescu, 2008/07/27
- [Emacs-diffs] Changes to emacs/src/emacs.c,v, Dan Nicolaescu, 2008/07/31