Skip to content

Instantly share code, notes, and snippets.

Avatar

Gaku tablacus

View GitHub Profile
@tablacus
tablacus / newfolder.js
Last active May 18, 2022
New Folder dialog - Tablacus Explorer
View newfolder.js
const currentPath = api.GetDisplayNameOf(FV, SHGDN_FORPARSING);
InputDialog("New Folder", "", function (r) {
if (r) {
let path = r.replace(/^\s+/, "");
if (!/^[A-Z]:\\|^\\/i.test(path)) {
path = BuildPath(currentPath, path);
}
fso.CreateFolder(path);
}
});
@tablacus
tablacus / toggle_fullscreen.js
Created Feb 5, 2022
Toggle fullscreen - Tablacus Explorer
View toggle_fullscreen.js
ToggleFullscreen();
@tablacus
tablacus / copyaspath.js
Created Jan 11, 2022
Copy as path - Tablacus Explorer
View copyaspath.js
clipboardData.setData("text", (FV.FocusedItem || FV.FolderItem).Path);
@tablacus
tablacus / toggle_seletion.js
Created Dec 28, 2021
Toggles the selection of focused item - Tablacus Explorer
View toggle_seletion.js
const nFocused = FV.GetFocusedItem;
const bSelected = api.SendMessage(FV.hwndList, LVM_GETITEMSTATE, nFocused, LVIS_SELECTED);
FV.SelectItem(nFocused, bSelected ? SVSI_DESELECT : SVSI_SELECT);
@tablacus
tablacus / timeout.js
Created Dec 26, 2021
Switch add-ons after 500ms - Tablacus Explorer
View timeout.js
setTimeout(function () {
Exec(te, ["cmigemo,0", "filterlist,1"].join("\n"), "Addon switcher");
}, 500);
@tablacus
tablacus / toggle_selection_with_inline_renaming.js
Created Dec 18, 2021
Toggle selection with inline renaming - Tablacus Explorer
View toggle_selection_with_inline_renaming.js
const hEdit = api.SendMessage(FV.hwndList, LVM_GETEDITCONTROL, 0, 0);
const fn = api.GetWindowText(hEdit);
let start = api.SendMessage(hEdit, 0xB0, 0, 0);//EM_GETSEL
const end = Math.floor(start >> 16);
start &= 0xffff;
if (fn.indexOf(".") >= 0) {
if (start) {
api.SendMessage(hEdit, 0xB1, 0, fn.length);//EM_SETSEL
} else {
if (end == fn.length) {
@tablacus
tablacus / open_chrome_form_url_shortcut.js
Created Dec 17, 2021
Open chrome from url shortcut - Tablacus Explorer
View open_chrome_form_url_shortcut.js
const Selected = FV.SelectedItems();
if (Selected.Count != 1) {
return;
}
wsh.run('"C:\\Program Files (x86)\\Google\\Chrome\\Application\\chrome.exe "' + Selected.Item(0).ExtendedProperty("linktarget"));
@tablacus
tablacus / add_tabgroups.js
Created Nov 21, 2021
Add tabgroups * Reuire "tabgroups" - Tablacus Explorer
View add_tabgroups.js
Sync.Tabgroups.Add();
@tablacus
tablacus / top1bottom2.js
Last active Nov 22, 2021
Splut top1 bottom 2 - Tablacus Explorer * require split
View top1bottom2.js
const TC = [await te.Ctrl(CTRL_TC)];
await Addons.Split.Exec2(3, TC);
TC[0].Left = 0;
TC[0].Top = 0;
TC[0].Width = "100%";
TC[0].Height = "50%";
TC[1].Left = 0;
TC[1].Top = "50%";
TC[1].Width = "50%";
TC[1].Height = "50%";
@tablacus
tablacus / right1left2.js
Last active Nov 20, 2021
Split right 1 left 2 - Tablacus Explorer * require split
View right1left2.js
const TC = [await te.Ctrl(CTRL_TC)];
await Addons.Split.Exec2(3, TC);
TC[0].Left = 0;
TC[0].Top = 0;
TC[0].Width = "50%";
TC[0].Height = "50%";
TC[1].Left = 0;
TC[1].Top = "50%";
TC[1].Width = "50%";
TC[1].Height = "50%";