mirror of
https://github.com/gryf/pentadactyl-pm.git
synced 2025-12-29 08:42:27 +01:00
Display an error when calling :tabdetach on the only tab in a window.
This commit is contained in:
@@ -588,7 +588,13 @@ function Tabs() //{{{
|
||||
|
||||
commands.add(["tabde[tach]"],
|
||||
"Detach current tab to its own window",
|
||||
function () { tabs.detachTab(null); },
|
||||
function ()
|
||||
{
|
||||
if (tabs.count == 1)
|
||||
return void liberator.echoerr("Can't detach the last tab");
|
||||
|
||||
tabs.detachTab(null);
|
||||
},
|
||||
{ argCount: "0" });
|
||||
|
||||
commands.add(["tabdu[plicate]"],
|
||||
|
||||
Reference in New Issue
Block a user