OSDN Git Service

Fix Drop Move\rename problem.
authorFrank Li <lznuaa@gmail.com>
Sun, 20 Sep 2009 14:22:58 +0000 (22:22 +0800)
committerFrank Li <lznuaa@gmail.com>
Sun, 20 Sep 2009 14:22:58 +0000 (22:22 +0800)
Actually it do nothing when drop move file

Signed-off-by: Frank Li <lznuaa@gmail.com>
src/TortoiseProc/Commands/DropMoveCommand.cpp

index da7b2f1..6307fd2 100644 (file)
@@ -30,7 +30,7 @@ bool DropMoveCommand::Execute()
 {\r
        CString droppath = parser.GetVal(_T("droptarget"));\r
        CString ProjectTop;\r
-       if (CTGitPath(droppath).HasAdminDir(&ProjectTop))\r
+       if (!CTGitPath(droppath).HasAdminDir(&ProjectTop))\r
                return FALSE;\r
        \r
        if (ProjectTop != g_Git.m_CurrentDir )\r
@@ -39,7 +39,7 @@ bool DropMoveCommand::Execute()
                return FALSE;\r
        }\r
 \r
-       droppath.Right(droppath.GetLength()-ProjectTop.GetLength()-1);\r
+       droppath = droppath.Right(droppath.GetLength()-ProjectTop.GetLength()-1);\r
 \r
        unsigned long count = 0;\r
        pathList.RemoveAdminPaths();\r