Skip to content

Commit 1f24aba

Browse files
author
Iakov Senatov
committed
ВтВ Fix (do not works)
1 parent 4489593 commit 1f24aba

File tree

18 files changed

+1246
-1004
lines changed

18 files changed

+1246
-1004
lines changed

GUI/Resources/Localizable.xcstrings

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -283,6 +283,10 @@
283283
},
284284
"All keyboard shortcuts will be reset to factory defaults. This cannot be undone." : {
285285

286+
},
287+
"All Shortcuts" : {
288+
"comment" : "A button that filters the list of keyboard shortcuts to show all of them.",
289+
"isCommentAutoGenerated" : true
286290
},
287291
"Already Exists" : {
288292
"comment" : "Already exists error title",
@@ -1468,6 +1472,9 @@
14681472
},
14691473
"List view" : {
14701474

1475+
},
1476+
"Loading…" : {
1477+
14711478
},
14721479
"Location:" : {
14731480
"comment" : "Location label",

GUI/Sources/BreadCrumbNav/PathAutoCompleteField.swift

Lines changed: 380 additions & 374 deletions
Large diffs are not rendered by default.

GUI/Sources/ContextMenu/Services/Coordinator/PanelBackgroundActionsHandler.swift

Lines changed: 5 additions & 28 deletions
Original file line numberDiff line numberDiff line change
@@ -83,19 +83,11 @@ extension ContextMenuCoordinator {
8383

8484
// MARK: - Navigation
8585

86-
/// Navigate panel to specified path
86+
/// Navigate panel to specified path (with retry + spinner for slow volumes)
8787
func navigateTo(_ url: URL, panel: PanelSide, appState: AppState) {
8888
log.debug("\(#function) url='\(url.path)' panel=\(panel)")
8989
Task { @MainActor in
90-
appState.updatePath(url.path, for: panel)
91-
if panel == .left {
92-
await appState.scanner.setLeftDirectory(pathStr: url.path)
93-
await appState.scanner.refreshFiles(currSide: .left)
94-
} else {
95-
await appState.scanner.setRightDirectory(pathStr: url.path)
96-
await appState.scanner.refreshFiles(currSide: .right)
97-
}
98-
log.debug("\(#function) navigation completed")
90+
await appState.navigateToDirectory(url.path, on: panel)
9991
}
10092
}
10193

@@ -116,25 +108,10 @@ extension ContextMenuCoordinator {
116108
return appState.focusedPanel
117109
}
118110

119-
/// Create new folder in directory, then select it
111+
/// Show Create Folder dialog so the user can enter a name
120112
func performNewFolder(in directory: URL, appState: AppState) {
121-
log.debug("\(#function) directory='\(directory.path)'")
122-
123-
let baseName = "New Folder"
124-
let newFolderURL = generateUniqueName(baseName: baseName, in: directory, isDirectory: true)
125-
126-
do {
127-
try FileManager.default.createDirectory(at: newFolderURL, withIntermediateDirectories: false)
128-
let createdName = newFolderURL.lastPathComponent
129-
let panel = panelForPath(directory.path, appState: appState)
130-
log.info("\(#function) SUCCESS created folder '\(createdName)' → selecting on \(panel)")
131-
Task { @MainActor in
132-
await appState.refreshAndSelect(name: createdName, on: panel)
133-
}
134-
} catch {
135-
log.error("\(#function) FAILED: \(error.localizedDescription)")
136-
activeDialog = .error(title: "Create Folder Failed", message: error.localizedDescription)
137-
}
113+
log.debug("\(#function) showing dialog for directory='\(directory.path)'")
114+
activeDialog = .createFolder(parentURL: directory)
138115
}
139116

140117
/// Create new empty file in directory, then select it

0 commit comments

Comments
 (0)