OSDN Git Service

Diff Dialog Okay
[tortoisegit/TortoiseGitJp.git] / src / TortoiseProc / LogDlgHelper.h
index d4d15cb..d31d9e6 100644 (file)
@@ -22,7 +22,9 @@
 #include "GitStatus.h"\r
 #include "ILogReceiver.h"\r
 #include "lanes.h"\r
-\r
+#include <set> \r
+#include "GitHash.h"\r
+#include "GitLogCache.h"\r
 class CLogDlg;\r
 \r
 /**\r
@@ -30,7 +32,7 @@ class CLogDlg;
  * Instances of CStoreSelection save the selection of the CLogDlg. When the instance\r
  * is deleted the destructor restores the selection.\r
  */\r
-typedef std::map<CString, int> MAP_HASH_REV;\r
+typedef std::map<CGitHash, int> MAP_HASH_REV;\r
 \r
 class CStoreSelection\r
 {\r
@@ -48,27 +50,50 @@ protected:
  * Helper class for the log dialog, handles all the log entries, including\r
  * sorting.\r
  */\r
-class CLogDataVector :         public std::vector<GitRev>\r
+class CLogDataVector :         public std::vector<CGitHash>\r
 {\r
 public:\r
+       CLogCache *m_pLogCache;\r
        /// De-allocates log items.\r
+       CLogDataVector(CLogCache *pLogCache)\r
+       {\r
+               m_pLogCache=pLogCache;\r
+               m_FirstFreeLane=0;\r
+       }\r
        CLogDataVector()\r
        {\r
+               m_pLogCache=NULL;\r
                m_FirstFreeLane=0;\r
        }\r
+       void SetLogCache(CLogCache *pLogCache)\r
+       {\r
+               m_pLogCache = pLogCache;\r
+       }\r
+       GitRev & GetGitRevAt(int i)\r
+       {\r
+               ASSERT(i<size());\r
+               return  m_pLogCache->m_HashMap[(*this)[i]];\r
+       }\r
        void ClearAll();\r
-       int  ParserFromLog();\r
-       int ParserShortLog();\r
+       int  ParserFromLog(CTGitPath *path =NULL,int count = -1,int infomask=CGit::LOG_INFO_STAT|CGit::LOG_INFO_FILESTATE|CGit::LOG_INFO_SHOW_MERGEDFILE,\r
+                                                                                        CString *from=NULL,CString *to=NULL);\r
+\r
+       int  FetchShortLog(CTGitPath *path , CString &hash,int count=-1 ,int mask=CGit::LOG_INFO_ONLY_HASH, int showWC=0 );\r
+       int  ParserShortLog(CTGitPath *path ,CString &hash,int count=-1 ,int mask=CGit::LOG_INFO_ONLY_HASH );\r
+\r
+       int  ParserFromRefLog(CString ref);\r
+\r
        int FetchFullInfo(int i);\r
+//     void AddFullInfo(\r
 \r
-       Lanes m_Lanes;\r
+       Lanes m_Lns;\r
        int      m_FirstFreeLane;\r
        MAP_HASH_REV m_HashMap;\r
-       void updateLanes(GitRev& c, Lanes& lns, CString &sha) ;\r
-       void setLane(CString& sha) ;\r
-       \r
-       \r
+       void updateLanes(GitRev& c, Lanes& lns, CGitHash &sha) ;\r
+       void setLane(CGitHash& sha) ;\r
 \r
+       BYTE_VECTOR              m_RawlogData;\r
+       std::vector<int> m_RawLogStart;\r
 \r
 #if 0\r
        /// Ascending date sorting.\r