дзеркало
https://github.com/l0ng-ai/openidea.git
синхронізовано 2026-11-08 19:02:17 +02:00
feat(debugger): Browse the debug console history and open diff settings from the keyboard (#162)
- Debug console: typed expressions are kept per project, and Browse Console History (⌥⌘E / Ctrl+Alt+E) lists them, most recent first, to put one back into the input. - Diff viewer: Diff Settings (⇧⌘D / Ctrl+Shift+D) opens the viewer options (side-by-side / unified, whitespace, highlighting, collapsing, scroll sync) as a popup menu.
Цей коміт міститься в:
1 джерело
a28600c55a
коміт
aeb190ffda
10 files changed
+142
-10
No files matched your search
@@ -1,10 +1,10 @@
|
||||
/**
|
||||
* Per-project history of expressions typed into the debugger (breakpoint
|
||||
* conditions, Evaluate), most recent first, as IDEA keeps them.
|
||||
* conditions, Evaluate, the debug console), most recent first, as IDEA keeps them.
|
||||
*/
|
||||
import { useProject } from "@/platform/project";
|
||||
|
||||
export type HistoryKind = "condition" | "evaluate";
|
||||
export type HistoryKind = "condition" | "evaluate" | "console";
|
||||
|
||||
const PREFIX = "openidea.debugger.history.";
|
||||
const MAX = 50;
|
||||
@@ -36,3 +36,16 @@ export function pushHistory(kind: HistoryKind, expression: string) {
|
||||
// Storage unavailable: no history.
|
||||
}
|
||||
}
|
||||
|
||||
/** Browse History (⌥⌘E) of the focused debug console input, while one has focus. */
|
||||
let browseConsoleHistory: (() => void) | null = null;
|
||||
|
||||
export function setConsoleHistoryBrowser(fn: (() => void) | null) {
|
||||
browseConsoleHistory = fn;
|
||||
}
|
||||
|
||||
export function browseFocusedConsoleHistory(): boolean {
|
||||
if (!browseConsoleHistory) return false;
|
||||
browseConsoleHistory();
|
||||
return true;
|
||||
}
|
||||
Reference in new issue
Заблокувати користувача