Bug 515665 - show full path when download conflict.

Change-Id: I534ffda96ea9b453819217d8a46cd76219d5988c
Signed-off-by: ashi <Aijun.Shi@windriver.com>
diff --git a/target_explorer/plugins/org.eclipse.tcf.te.tcf.filesystem.ui/src/org/eclipse/tcf/te/tcf/filesystem/ui/internal/handlers/MoveCopyCallback.java b/target_explorer/plugins/org.eclipse.tcf.te.tcf.filesystem.ui/src/org/eclipse/tcf/te/tcf/filesystem/ui/internal/handlers/MoveCopyCallback.java
index b47d4e8..b7059ff 100644
--- a/target_explorer/plugins/org.eclipse.tcf.te.tcf.filesystem.ui/src/org/eclipse/tcf/te/tcf/filesystem/ui/internal/handlers/MoveCopyCallback.java
+++ b/target_explorer/plugins/org.eclipse.tcf.te.tcf.filesystem.ui/src/org/eclipse/tcf/te/tcf/filesystem/ui/internal/handlers/MoveCopyCallback.java
@@ -44,6 +44,7 @@
 	@Override
 	public int confirms(Object object) {
 		final boolean isDirectory = isDirectory(object);
+		final String path = getAbsolutePath(object);
 		final String name = getName(object);
 		final int[] results = new int[1];
 		Display display = PlatformUI.getWorkbench().getDisplay();
@@ -52,7 +53,7 @@
 			public void run() {
 				Shell parent = PlatformUI.getWorkbench().getActiveWorkbenchWindow().getShell();
 				String title = isDirectory ? Messages.FSOperation_ConfirmFolderReplaceTitle : Messages.FSOperation_ConfirmFileReplace;
-				String message = NLS.bind(isDirectory ? Messages.FSOperation_ConfirmFolderReplaceMessage : Messages.FSOperation_ConfirmFileReplaceMessage, name);
+				String message = NLS.bind(isDirectory ? Messages.FSOperation_ConfirmFolderReplaceMessage : Messages.FSOperation_ConfirmFileReplaceMessage, path, name);
 				final Image titleImage = UIPlugin.getImage(ImageConsts.REPLACE_FOLDER_CONFIRM);
 				MessageDialog qDialog = new MessageDialog(parent, title, null, message, MessageDialog.QUESTION, new String[] { Messages.FSOperation_ConfirmDialogYes, Messages.FSOperation_ConfirmDialogYesToAll, Messages.FSOperation_ConfirmDialogNo, Messages.FSOperation_ConfirmDialogCancel }, 0) {
 					@Override
@@ -74,6 +75,14 @@
 	    return String.valueOf(object);
     }
 
+	private String getAbsolutePath(Object object) {
+		if (object instanceof IFSTreeNode)
+			return ((IFSTreeNode) object).getLocation();
+		if (object instanceof File)
+			return ((File) object).getAbsolutePath();
+	    return String.valueOf(object);
+    }
+
 	private boolean isDirectory(Object object) {
 		if (object instanceof IFSTreeNode)
 			return ((IFSTreeNode) object).isDirectory();
diff --git a/target_explorer/plugins/org.eclipse.tcf.te.tcf.filesystem.ui/src/org/eclipse/tcf/te/tcf/filesystem/ui/nls/Messages.properties b/target_explorer/plugins/org.eclipse.tcf.te.tcf.filesystem.ui/src/org/eclipse/tcf/te/tcf/filesystem/ui/nls/Messages.properties
index b3feec3..e96bc0f 100644
--- a/target_explorer/plugins/org.eclipse.tcf.te.tcf.filesystem.ui/src/org/eclipse/tcf/te/tcf/filesystem/ui/nls/Messages.properties
+++ b/target_explorer/plugins/org.eclipse.tcf.te.tcf.filesystem.ui/src/org/eclipse/tcf/te/tcf/filesystem/ui/nls/Messages.properties
@@ -77,8 +77,8 @@
 FSOperation_ConfirmDialogYes=&Yes
 FSOperation_ConfirmDialogYesToAll=Yes to &All
 FSOperation_ConfirmFileReplace=Confirm File Replace
-FSOperation_ConfirmFileReplaceMessage=This folder already contains a file named {0}.\n\n If the files in the existing folder have the same name as files in the folder you are moving or copying, they will be replaced. Do you still want to move or copy the file?
-FSOperation_ConfirmFolderReplaceMessage=This folder already contains a folder named {0}.\n\n If the files in the existing folder have the same name as files in the folder you are moving or copying, they will be replaced. Do you still want to move or copy the folder?
+FSOperation_ConfirmFileReplaceMessage=Folder ''{0}'' already contains a file named ''{1}''.\n\nIf the files in the existing folder have the same name as files in the folder you are moving or copying, they will be replaced. Do you still want to move or copy the file?
+FSOperation_ConfirmFolderReplaceMessage=Folder ''{0}'' already contains a folder named ''{1}''.\n\nIf the files in the existing folder have the same name as files in the folder you are moving or copying, they will be replaced. Do you still want to move or copy the folder?
 FSOperation_ConfirmFolderReplaceTitle=Confirm Folder Replace
 OpenFileHandler_OpeningBinaryNotSupported=Opening a binary file is not supported yet.
 OpenFileHandler_Warning=Warning