I haven't Files|Internal Associations in my custom menu. So I confused with "Associate with..." command.
I have no idea why TC doesn't show internal icons

I'm not sure whether it possible at all
Moderators: Hacker, petermad, Stefan2, white
Code: Select all
int __stdcall FsExtractCustomIconW(WCHAR* RemoteName, int ExtractFlags, HICON* TheIcon) {
int l=lstrlen(RemoteName), result=FS_ICON_USEDEFAULT;
if (l>=4&&!lstrcmp(RemoteName+l-4, L"\\..\\")) return result;
...
if (<virtual file can't be found>) return result;
...
bool script=*name=='<', exists=!*name || script || GetFileAttributes(name)!=INVALID_FILE_ATTRIBUTES, has_own_icon=0;
if (!exists) {
bool folder=(fd.Data.dwFileAttributes&FILE_ATTRIBUTE_DIRECTORY)!=0;
*TheIcon=vfile_icon[folder ? fit_FolderRemoved : fit_FileRemoved][ExtractFlags&FS_ICONFLAG_SMALL ? 0 : 1];
if (*TheIcon) lstrcpy(RemoteName, folder ? L".\\?" : L".?");
return *TheIcon ? FS_ICON_EXTRACTED : FS_ICON_USEDEFAULT;
}
if (!script&&l>4) {
if (!strbegini(name+l-4, L".exe") || !strbegini(name+l-4, L".lnk")) has_own_icon=1;
}
if (ExtractFlags&FS_ICONFLAG_BACKGROUND) {
if (script) {
...
if (p&&ExtractFileIcon(p, ExtractFlags&FS_ICONFLAG_SMALL ? 0 : TheIcon, ExtractFlags&FS_ICONFLAG_SMALL ? TheIcon : 0)) return FS_ICON_EXTRACTED_DESTROY;
}
else {
SHFILEINFO sfi;
if (!SHGetFileInfo(name, 0, &sfi, sizeof(sfi), SHGFI_ICON|SHGFI_ADDOVERLAYS|(ExtractFlags&FS_ICONFLAG_SMALL ? SHGFI_SMALLICON : 0))) return FS_ICON_USEDEFAULT;
*TheIcon=sfi.hIcon;
result=FS_ICON_EXTRACTED_DESTROY;
}
}
else if (script || has_own_icon) return FS_ICON_DELAYED;
if (script) {
*TheIcon=vfile_icon[fit_Command][ExtractFlags&FS_ICONFLAG_SMALL ? 0 : 1];
if (TheIcon) { lstrcpy(RemoteName, L".>"); return FS_ICON_EXTRACTED; }
}
else if (!l&&(fd.Data.dwFileAttributes&FILE_ATTRIBUTE_DIRECTORY)) {
*TheIcon=vfile_icon[fit_Folder][ExtractFlags&FS_ICONFLAG_SMALL ? 0 : 1];
if (TheIcon) { lstrcpy(RemoteName, L".\\"); return FS_ICON_EXTRACTED; }
}
return result;
}
Code: Select all
[plugininstall]
description=BranchViewEx 1.02: Branch view with subfolder sizes (http://www.ghisler.ch/board/viewtopic.php?t=24238)
type=wfx
file=BranchViewEx.wfx
defaultdir=BranchViewEx
Great, now it is possible to view properfies of file(s) and to view/edit files directly from plugin panel.+ Added temporary file plugin functions
Link points to version 1.01 please update.kotlomoy wrote:version 1.02 released:
http://cid-9a15473c9a985119.office.live.com/self.aspx/!work/BranchViewEx.wfx
Changes:
+ Added temporary file plugin functions
+ Added VERSION_INFO
Icons problem is not solved in version 1.02.sgp wrote:Link points to version 1.01 please update.kotlomoy wrote:version 1.02 released:
http://cid-9a15473c9a985119.office.live.com/self.aspx/!work/BranchViewEx.wfx
Changes:
+ Added temporary file plugin functions
+ Added VERSION_INFO
Can you also check that v.1.02 deals with file type .ico properly? It should, but double-checking is good.
File type .ico icons should display as the actual icon graphics.
My plugin is one 80k file. So "reduce distributive size" is not very actual problem, I think.MVV wrote:Little suggestion - you can compress plugin to ZIP, RAR or 7Z to reduce distributive size, and add to archive self-installation file pluginst.inf like this one:
kotlomoy wrote:2MVV
Does it work for internal icons?
I've added icons for .gid, .bak and .mnu types:MVV wrote:Yes, of course, I wrote more than twice about it in your topic. Smile
I've made a little typo in dll version, sorrysgp wrote:it does not. it points to a copy of 1.01. please update. thanks.kotlomoy wrote:2sqp
Indeed, it's the same link. But now it points to version 1.02.
dll version info says: name=BranchViewExtended file system plugin for Total Commander; product version=1, 0, 1, 0
Code: Select all
20.01.10 Release Total Commander 7.51 beta 1
...
22.12.09 Added: Temp panel plugin: Show icons for internal associations and per file associations if the plugin returns FS_ICON_USEDEFAULT
I can confirm that internally associated icons display OK for me in MVV's virtual panel.kotlomoy wrote: What I saw (my test dir), left - TC, right - Virtual Panel:
Image: http://img189.imageshack.us/img189/4159/86675854.png
No icons for .gid and .bak, default icons for .mnu