#include "PreserveChdir.h"\r
#include "UnicodeUtils.h"\r
#include "GitStatus.h"\r
-//#include "..\TSVNCache\CacheInterface.h"\r
+#include "..\TGitCache\CacheInterface.h"\r
\r
// "The Shell calls IShellIconOverlayIdentifier::GetOverlayInfo to request the\r
// location of the handler's icon overlay. The icon overlay handler returns\r
{\r
case ShellCache::exe:\r
{\r
-#if 0\r
TSVNCacheResponse itemStatus;\r
SecureZeroMemory(&itemStatus, sizeof(itemStatus));\r
if (m_remoteCacheLink.GetStatusFromRemoteCache(CTGitPath(pPath), &itemStatus, true))\r
{\r
status = GitStatus::GetMoreImportant(itemStatus.m_status.text_status, itemStatus.m_status.prop_status);\r
- if ((itemStatus.m_kind == git_node_file)&&(status == git_wc_status_normal)&&((itemStatus.m_needslock && itemStatus.m_owner[0]==0)||(itemStatus.m_readonly)))\r
+/* if ((itemStatus.m_kind == git_node_file)&&(status == git_wc_status_normal)&&((itemStatus.m_needslock && itemStatus.m_owner[0]==0)||(itemStatus.m_readonly)))\r
readonlyoverlay = true;\r
if (itemStatus.m_owner[0]!=0)\r
- lockedoverlay = true;\r
+ lockedoverlay = true;*/\r
}\r
-#endif\r
}\r
break;\r
case ShellCache::dll:\r
+ case ShellCache::dllFull:\r
{\r
// Look in our caches for this item \r
const FileStatusCacheEntry * s = m_CachedStatus.GetCachedItem(CTGitPath(pPath));\r
lockedoverlay = true;\r
}\r
\r
+ // index based version does not enumerate unversioned files, so default to unversioned\r
+ if (g_ShellCache.GetCacheType() == ShellCache::dll\r
+ && status == git_wc_status_none && g_ShellCache.HasSVNAdminDir(pPath, true))\r
+ status = git_wc_status_unversioned;\r
break;\r
default:\r
case ShellCache::none:\r
//as it seems that if one handler returns S_OK then that handler is used, no matter\r
//if other handlers would return S_OK too (they're never called on my machine!)\r
//So we return S_OK for ONLY ONE handler!\r
+\r
switch (status)\r
{\r
// note: we can show other overlays if due to lack of enough free overlay\r
}\r
case git_wc_status_replaced:\r
case git_wc_status_modified:\r
- case git_wc_status_merged:\r
if (m_State == FileStateModified)\r
{\r
g_filepath.clear();\r
}\r
else\r
return S_FALSE;\r
+ case git_wc_status_merged:\r
+ if (m_State == FileStateReadOnly)\r
+ {\r
+ g_filepath.clear();\r
+ return S_OK;\r
+ }\r
+ else\r
+ return S_FALSE;\r
case git_wc_status_added:\r
if (g_addedovlloaded)\r
{\r