+(defcustom desktop-buffer-file-name nil
+ "When desktop creates a buffer, this holds the file name to visit."
+ :type '(choice file (const nil))
+ :group 'desktop)
+
+(defcustom desktop-buffer-name nil
+ "When desktop creates a buffer, this holds the desired buffer name."
+ :type '(choice string (const nil))
+ :group 'desktop)
+
+(defvar desktop-buffer-misc nil
+ "When desktop creates a buffer, this holds a list of misc info.
+It is used by the `desktop-buffer-handlers' functions.")
+
+(defcustom desktop-buffer-misc-functions
+ '(desktop-buffer-info-misc-data
+ desktop-buffer-dired-misc-data)
+ "*Functions used to determine auxiliary information for a buffer.
+These functions are called in order, with no arguments. If a function
+returns non-nil, its value is saved along with the desktop buffer for
+which it was called; no further functions will be called.
+
+Later, when desktop.el restores the buffers it has saved, each of the
+`desktop-buffer-handlers' functions will have access to a buffer local
+variable, named `desktop-buffer-misc', whose value is what the
+\"misc\" function returned previously."
+ :type '(repeat function)
+ :group 'desktop)
+
+(defcustom desktop-buffer-handlers