Don't show special buffers, misc
This commit is contained in:
@@ -75,6 +75,24 @@ void Command_ShowCommands() {
|
||||
SelectRange(command_bar.view, GetBufferEndAsRange(command_bar.buffer));
|
||||
} RegisterCommand(Command_ShowCommands, "ctrl-shift-p");
|
||||
|
||||
void Command_ShowDebugBufferList() {
|
||||
if (ActiveWindowID == CommandBarWindowID && LastExecutedCommand == Command_ShowDebugBufferList) {
|
||||
ActiveWindowID = LastActiveLayoutWindowID;
|
||||
return;
|
||||
}
|
||||
|
||||
BSet command_bar = GetBSet(CommandBarWindowID);
|
||||
command_bar.window->visible = true;
|
||||
command_bar.window->eval_command = false;
|
||||
ActiveWindowID = command_bar.window->id;
|
||||
ResetBuffer(command_bar.buffer);
|
||||
For(Buffers) {
|
||||
RawAppendf(command_bar.buffer, "%-80S || %S\n", SkipToLastSlash(it->name), it->name);
|
||||
}
|
||||
command_bar.view->update_scroll = true;
|
||||
SelectRange(command_bar.view, GetBufferEndAsRange(command_bar.buffer));
|
||||
} RegisterCommand(Command_ShowDebugBufferList, "");
|
||||
|
||||
void Command_ShowBufferList() {
|
||||
if (ActiveWindowID == CommandBarWindowID && LastExecutedCommand == Command_ShowBufferList) {
|
||||
ActiveWindowID = LastActiveLayoutWindowID;
|
||||
@@ -87,6 +105,9 @@ void Command_ShowBufferList() {
|
||||
ActiveWindowID = command_bar.window->id;
|
||||
ResetBuffer(command_bar.buffer);
|
||||
For(Buffers) {
|
||||
if (it->special) {
|
||||
continue;
|
||||
}
|
||||
RawAppendf(command_bar.buffer, "%-80S || %S\n", SkipToLastSlash(it->name), it->name);
|
||||
}
|
||||
command_bar.view->update_scroll = true;
|
||||
|
||||
Reference in New Issue
Block a user