Download
Getting Started
Members
Projects
Community
Marketplace
Events
Planet Eclipse
Newsletter
Videos
Participate
Report a Bug
Forums
Mailing Lists
Wiki
IRC
How to Contribute
Working Groups
Automotive
Internet of Things
LocationTech
Long-Term Support
PolarSys
Science
OpenMDM
More
Community
Marketplace
Events
Planet Eclipse
Newsletter
Videos
Participate
Report a Bug
Forums
Mailing Lists
Wiki
IRC
How to Contribute
Working Groups
Automotive
Internet of Things
LocationTech
Long-Term Support
PolarSys
Science
OpenMDM
Toggle navigation
Bugzilla – Attachment 148038 Details for
Bug 284447
[Workbench] Add custom workspace name in front of the Workbench window title
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
Log In
[x]
|
Terms of Use
|
Copyright Agent
Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read
this important communication.
[patch]
Patch
bug284447_showLoc.diff.txt (text/plain), 3.18 KB, created by
Martin Oberhuber
on 2009-09-24 13:37:16 EDT
(
hide
)
Description:
Patch
Filename:
MIME Type:
Creator:
Martin Oberhuber
Created:
2009-09-24 13:37:16 EDT
Size:
3.18 KB
patch
obsolete
>### Eclipse Workspace Patch 1.0 >#P org.eclipse.ui.ide.application >Index: src/org/eclipse/ui/internal/ide/application/IDEWorkbenchAdvisor.java >=================================================================== >RCS file: /cvsroot/eclipse/org.eclipse.ui.ide.application/src/org/eclipse/ui/internal/ide/application/IDEWorkbenchAdvisor.java,v >retrieving revision 1.23 >diff -u -r1.23 IDEWorkbenchAdvisor.java >--- src/org/eclipse/ui/internal/ide/application/IDEWorkbenchAdvisor.java 20 May 2009 16:10:35 -0000 1.23 >+++ src/org/eclipse/ui/internal/ide/application/IDEWorkbenchAdvisor.java 24 Sep 2009 17:36:52 -0000 >@@ -7,6 +7,7 @@ > * > * Contributors: > * IBM Corporation - initial API and implementation >+ * Martin Oberhuber (Wind River) - bug 284447: Prepend showlocation in title > *******************************************************************************/ > package org.eclipse.ui.internal.ide.application; > >@@ -179,7 +180,7 @@ > if (cmdLineArgs.length > i + 1) { > name = cmdLineArgs[i + 1]; > } >- if (name != null && name.indexOf("-") == -1) { //$NON-NLS-1$ >+ if (name != null) { > workspaceLocation = name; > } else { > workspaceLocation = Platform.getLocation().toOSString(); >Index: src/org/eclipse/ui/internal/ide/application/IDEWorkbenchWindowAdvisor.java >=================================================================== >RCS file: /cvsroot/eclipse/org.eclipse.ui.ide.application/src/org/eclipse/ui/internal/ide/application/IDEWorkbenchWindowAdvisor.java,v >retrieving revision 1.10 >diff -u -r1.10 IDEWorkbenchWindowAdvisor.java >--- src/org/eclipse/ui/internal/ide/application/IDEWorkbenchWindowAdvisor.java 25 May 2009 20:51:57 -0000 1.10 >+++ src/org/eclipse/ui/internal/ide/application/IDEWorkbenchWindowAdvisor.java 24 Sep 2009 17:36:52 -0000 >@@ -7,9 +7,11 @@ > * > * Contributors: > * IBM Corporation - initial API and implementation >+ * Martin Oberhuber (Wind River) - bug 284447: Prepend showlocation in title > *******************************************************************************/ > package org.eclipse.ui.internal.ide.application; > >+import java.io.File; > import java.net.URL; > import java.util.ArrayList; > import java.util.Iterator; >@@ -299,7 +301,7 @@ > }); > } > >- private String computeTitle() { >+ protected String computeTitle() { > IWorkbenchWindowConfigurer configurer = getWindowConfigurer(); > IWorkbenchPage currentPage = configurer.getWindow().getActivePage(); > IEditorPart activeEditor = null; >@@ -341,8 +343,16 @@ > > String workspaceLocation = wbAdvisor.getWorkspaceLocation(); > if (workspaceLocation != null) { >- title = NLS.bind(IDEWorkbenchMessages.WorkbenchWindow_shellTitle, >- title, workspaceLocation); >+ //Bug 284447: Prepend workspace name set by -showlocation >+ if (new File(workspaceLocation).isAbsolute()) { >+ //a real workspace location -- append at the end >+ title = NLS.bind(IDEWorkbenchMessages.WorkbenchWindow_shellTitle, >+ title, workspaceLocation); >+ } else { >+ //a name set by -showlocation -- prepend at the start >+ title = NLS.bind(IDEWorkbenchMessages.WorkbenchWindow_shellTitle, >+ workspaceLocation, title); >+ } > } > > return title;
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 284447
:
148038
|
157641