The network view's warning names Eject; now dtfile has it. The Selected
menu carries "Eject" (mnemonic E) after "Put in Trash", and Command+E is
bound in the drawing area's translation block (Mod4<Key>e:McdeKey(@,eject)).
Both call McdeEjectSelection(): it takes the selected folders, asks
mcde_sys_disks for the mounted volume whose mountpoint is one of them, and
unmounts it through mcde_sys_disk_unmount -- never a shell, and McdeSys
refuses what the computer runs from. No selection or no mounted volume gets
a sentence instead; a refused unmount shows mcde_sys_error() (as a user,
udisksctl asks polkit and fails without an agent -- measured).
The menu table is a fixed XtCalloc(menuItemCount): the new item made it 69
entries, so menuItemCount goes from 68 to 69 (51 to 52 without the Trash
menu). Without that, opening the Selected menu crashed the window (the
overflow was found by the menu click, not by the build).
Catalog: set 20 messages 173 "Eject", 174 "E", 175/176 the two answers, in
dtfile.msg and the German copy. The desktop's warning now says "Eject in
the file manager (Command+E) or Unmount in the Disk Utility"; its screenshot
docs/screenshots/leopard/Device-Removal-mcde.png is renewed.
Measured (Xvfb, a 32 MB image with one ext4 partition on /dev/loop0p1):
- as the user on :82: the Selected menu shows "Eject" and the window
survives (0x60002d, 213x218); Command+E opens the Eject message
"/usr/bin/udisksctl did not succeed (status 1)." -- the key reaches the
call, polkit refuses a user.
- as root under a root ttsession on :83 (ttsession -c dtfile): selecting the
mounted folder and Selected > Eject unmounts; findmnt then prints
"UNMOUNTED" for /tmp/opencode/ejecttest/mnt.
- after that Eject, a simulated removal of loop0p1 in dtwm
(MCDE_DESK_TEST_DEVICE) logs only "desktop: loop0p1 (remove)" and opens
0 dialogs -- a volume that was put away stays quiet.
- make mcde-linux MCDE_DIRS="install programs/dtfile" and "install
programs/localized/C/msg" exit=0; gencat reads both catalogs;
MCDE_DIRS=plist "mcde-plist-check: ok".
The menu bar is File, Selected, View, Go, Help now. The Go menu carries the
reference's entries: Back (Cmd+[), Forward (Cmd+]), Enclosing Folder
(Cmd+Up), Computer, Home, Desktop, Network and Applications (Shift+Cmd+C, H,
D, K, A), Go to Folder... (Shift+Cmd+G) and Connect to Server... (Cmd+K).
Back, Forward and the places go through the window's own navigation
(_McdeNavKey, the same code the keys use), Enclosing Folder and Home are
CDE's own callbacks, Go to Folder opens the dialog of GoToFolder.c and
Connect to Server the one of Connect.c.
The keys keep working through translations_da; the entries show them as
accelerator texts only (Dtfile), so that a key is not handled twice. The
new labels and mnemonics are in dtfile.msg (162-172).
Measured under Xvfb: the menu opens with every entry and its key
(docs/screenshots/leopard/finder-go-menu-mcde.png), "Home" takes the window
to $HOME (title "File Manager - home", the icons of ~).
Open: the File menu still carries its own Go Home, Go Up and Go To...
(the move is a second step, so that the menu-state code that names their
widgets is changed with it), "Recent Folders" and the icons in the menu are
not there (a submenu of the history and Motif's text-only menus), and the
menu's keys are the work area's translations, so they do not fire while the
focus is in the path field.
File > Get Info (Cmd+I) opens the reference's Info window instead of the
CDE permissions dialog: the name, its size and date, then sections that
open and close with a click -- General (kind, size, on disk, where,
created, modified, locked), Permissions (owner, group, everyone: read and
write, read only, none), Comment (an extended attribute) and Preview (the
miniature of McdeThumb). One window per file manager: Cmd+I again replaces
what it shows and the sections keep their state. The old "Change
Permissions..." item stays in the menu, without the key.
Two new McdeSys calls, because a program does not touch the file system's
specialties itself (ext/src/mcde/AGENTS.md): mcde_sys_file_comment_get/set
(user.mcde.comment on Linux, EXTATTR_NAMESPACE_USER "mcde.comment" on
NetBSD, MCDE_SYS_ENOTSUP where there are none) and
mcde_sys_file_locked_get/set (FS_IMMUTABLE_FL on Linux, chflags(2)
UF_IMMUTABLE on NetBSD; a normal user may not set it on Linux, the box then
stays as it was). "Created" says "not known" where POSIX has no birth time
(Linux); NetBSD shows st_birthtime.
Measured under Xvfb with xdotool: Cmd+I on Bild.png opens the window with
General/Permissions/Comment/Preview (docs/screenshots/leopard/
finder-get-info-mcde.png, the comment read back from the attribute); the
Owner menu to "Read only" on a 0664 file leaves -r--rw-r-- (chmod 0464);
the Comment field saved "Wichtig" and
python3 -c "os.getxattr(..., 'user.mcde.comment')" returns b'Wichtig';
clicking "General" collapses it to ">" and the sections below move up.
Open: "Open with" and the label colours of the reference are not there yet
(the action list and a user.dt mapping are a task of their own); the
program's icon is missing in the development session (t0194, no data
types), the sections are ASCII arrows, and dtwm places the window at the
corner (the picture moves it with xdotool).
File > Go to Folder... (Shift+Cmd+G, the resource of the old item, its name
kept) opens the reference's dialog instead of CDE's wide "Go To" with a list
of hosts: the title "Go to Folder", "Go to the folder:", one field, Cancel
and Go (Cancel left of Go; Return goes, Escape cancels). A column of parts,
not a form -- a form whose hidden candidate list sat between two attachments
collapsed to its minimum (measured).
The path: "~" and "~user" through getpwnam, no shell. Tab completes from
the folder named so far: a unique name is added (and a folder gets its "/"),
otherwise the part all candidates agree on is added and the next Tab shows
the candidates in a list under the field, from which one can be taken. A
path that is not a folder leaves the dialog open with "There is no folder of
that name." under the field; Go remembers the path in ~/.dt/last-folder, so
the next dialog starts there.
Measured under Xvfb with xdotool (home with Documents, Downloads, Bilder):
Shift+Cmd+G opens it; "~/Doc" + Tab -> "~/Documents/", Return -> the window
shows ~/Documents (docs/screenshots/leopard/finder-go-to-mcde.png);
"~/D" + Tab + Tab -> the candidates "~/Documents", "~/Downloads", a click
takes one and Return opens it (~/Downloads); "~/Nope" + Return -> the error
under the field and the dialog stays; after a Go the next dialog opens with
the last path.
Open: the dialog is placed at the screen's corner by dtwm (as the Trash
question; tried with XmNtransientFor); the CDE "Go To" code stays in the
tree for the restored-dialog path (FileMgr.c), no menu item leads to it now.
The CDE "Shred File(s)" question is replaced by the reference's dialog: the
title "Empty Trash", the question with the number of objects ("Remove the 3
items in the Trash permanently?"), "You cannot undo this action." under it,
and the buttons "Empty Trash" (the default) and "Cancel"; no Help button.
The question carries the rendition tag "bold" -- CDE's app-defaults define
no rendition tags, so the tag falls back to the dialog's font (measured in
the screenshot) until a render table defines one. The count is read from
~/.dt/Trash when the dialog opens, not from a list a view filled.
The Trash also reaches the File menu of every window (Open Trash, Empty
Trash...), which the CDE source had behind an undefined ADD_SHOW_TRASH and
whose ShowTrash still called the old five-argument handler; the menu now
compiles and calls the current one. Shift+Cmd+Delete is the menu item's
accelerator (text in Dtfile, the key as a translation of the work area, so
that it also works with the focus in the path field). The Trash is
initialized on first use, as the trash view does it.
Measured under Xvfb with xdotool, three objects in ~/.dt/Trash:
docs/screenshots/leopard/finder-empty-trash-mcde.png shows the dialog;
"Empty Trash" leaves ~/.dt/Trash empty (ls -A: nothing, .trashinfo gone);
"Cancel" and Escape leave all three files and .trashinfo in place.
tools/mcde-shot.sh exports DTDATABASESEARCHPATH as dtsession would.
Open: the dialog is placed in the screen's corner, not centered over the
window (dtwm's placement, tried with XmNtransientFor and XmNx/XmNy);
Motif's button order puts "Empty Trash" left of "Cancel", the reference has
Cancel left; the bold question waits for a rendition tag in the CDE theme.
cde-2.5.3.tar.gz, SHA512 a01b413b... as in pkgsrc distinfo; recipe from
pkgsrc 3c1118e94432. Added with -f: CDE's .gitignore hides 612 files of
the archive.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>