(uri: Uri)
| 90 | } |
| 91 | |
| 92 | function getFilename(uri: Uri) { |
| 93 | const pieces = uri.fsPath.split(/[/\\]/g); |
| 94 | if (pieces[pieces.length - 1].length === 0) { |
| 95 | pieces.pop(); |
| 96 | } |
| 97 | if (pieces.length > 0) { |
| 98 | return pieces[pieces.length - 1]; |
| 99 | } |
| 100 | return ""; |
| 101 | } |
| 102 | |
| 103 | function toHashKey(b: KeyBinding) { |
| 104 | return `${b.key}${b.command}${b.when ?? ""}`; |