Skip to main content
summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/internal/tasks/ui/editors/TaskEditorAttachmentPart.java9
-rw-r--r--org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/editors/AbstractTaskEditorPart.java3
2 files changed, 7 insertions, 5 deletions
diff --git a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/internal/tasks/ui/editors/TaskEditorAttachmentPart.java b/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/internal/tasks/ui/editors/TaskEditorAttachmentPart.java
index 8d0cc7d04..bbc8b2a4a 100644
--- a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/internal/tasks/ui/editors/TaskEditorAttachmentPart.java
+++ b/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/internal/tasks/ui/editors/TaskEditorAttachmentPart.java
@@ -24,6 +24,7 @@ import org.eclipse.jface.action.Action;
import org.eclipse.jface.action.IAction;
import org.eclipse.jface.action.IMenuListener;
import org.eclipse.jface.action.IMenuManager;
+import org.eclipse.jface.action.LegacyActionTools;
import org.eclipse.jface.action.MenuManager;
import org.eclipse.jface.action.ToolBarManager;
import org.eclipse.jface.layout.GridDataFactory;
@@ -268,7 +269,7 @@ public class TaskEditorAttachmentPart extends AbstractTaskEditorPart {
initialize();
section = createSection(parent, toolkit, hasIncoming);
- section.setText(getPartName() + " (" + attachmentAttributes.size() + ")"); //$NON-NLS-1$ //$NON-NLS-2$
+ updateSectionTitle();
if (hasIncoming) {
expandSection(toolkit, section);
} else {
@@ -376,10 +377,10 @@ public class TaskEditorAttachmentPart extends AbstractTaskEditorPart {
private void updateSectionTitle() {
if (tableFilter.isFilterDeprecatedEnabled()) {
section.setText(NLS.bind(Messages.TaskEditorAttachmentPart_Attachment_Section_Title_X_of_Y, new Object[] {
- getPartName(), nonDeprecatedCount, attachmentAttributes.size() }));
+ LegacyActionTools.escapeMnemonics(getPartName()), nonDeprecatedCount, attachmentAttributes.size() }));
} else {
- section.setText(NLS.bind(Messages.TaskEditorAttachmentPart_Attachment_Section_Title_X, getPartName(),
- attachmentAttributes.size()));
+ section.setText(NLS.bind(Messages.TaskEditorAttachmentPart_Attachment_Section_Title_X,
+ LegacyActionTools.escapeMnemonics(getPartName()), attachmentAttributes.size()));
}
}
diff --git a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/editors/AbstractTaskEditorPart.java b/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/editors/AbstractTaskEditorPart.java
index 48053afa8..b1c45ba8e 100644
--- a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/editors/AbstractTaskEditorPart.java
+++ b/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/editors/AbstractTaskEditorPart.java
@@ -12,6 +12,7 @@
package org.eclipse.mylyn.tasks.ui.editors;
import org.eclipse.jface.action.Action;
+import org.eclipse.jface.action.LegacyActionTools;
import org.eclipse.jface.action.ToolBarManager;
import org.eclipse.jface.resource.JFaceResources;
import org.eclipse.jface.viewers.ISelection;
@@ -79,7 +80,7 @@ public abstract class AbstractTaskEditorPart extends AbstractFormPart {
protected Section createSection(Composite parent, FormToolkit toolkit, int style) {
Section section = toolkit.createSection(parent, style);
- section.setText(getPartName());
+ section.setText(LegacyActionTools.escapeMnemonics(getPartName()));
return section;
}

Back to the top