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 236351 Details for
Bug 419154
Global search: Default search page can not recognize current file system as scope.
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 file
patch419154.txt (text/plain), 3.60 KB, created by
libing wang
on 2013-10-10 15:50:56 EDT
(
hide
)
Description:
Patch file
Filename:
MIME Type:
Creator:
libing wang
Created:
2013-10-10 15:50:56 EDT
Size:
3.60 KB
patch
obsolete
>diff --git a/bundles/org.eclipse.orion.client.ui/web/orion/PageLinks.js b/bundles/org.eclipse.orion.client.ui/web/orion/PageLinks.js >index 0cc0b74..5e02bae 100644 >--- a/bundles/org.eclipse.orion.client.ui/web/orion/PageLinks.js >+++ b/bundles/org.eclipse.orion.client.ui/web/orion/PageLinks.js >@@ -8,7 +8,7 @@ > * > ******************************************************************************/ > /*global define document window URL*/ >-define(["require", "orion/Deferred", "orion/PageUtil", "orion/URITemplate", "orion/i18nUtil", "orion/URL-shim"], function(require, Deferred, PageUtil, URITemplate, i18nUtil) { >+define(["require", "orion/Deferred", "orion/PageUtil", "orion/URITemplate", "orion/i18nUtil", 'orion/fileClient', "orion/URL-shim"], function(require, Deferred, PageUtil, URITemplate, i18nUtil, mFileClient) { > > /** > * Returns the value of the <code>{OrionHome}</code> variable. >@@ -39,11 +39,16 @@ > // required attribute: id - the id of the navigation link > // required attribute: uriTemplate - the URL for the navigation link > // optional attribute: image - a URL to an icon representing the link (currently not used, may use in future) >+ // optional attribute: useRootLocation - a boolean attribute that decides if a location is used in the url template, the root of teh location should be used or not. > var navLinks= serviceRegistry.getServiceReferences(serviceName); //$NON-NLS-0$ > var params = PageUtil.matchResourceParameters(window.location.href); > // TODO: should not be necessary, see bug https://bugs.eclipse.org/bugs/show_bug.cgi?id=373450 > var orionHome = getOrionHome(); > var locationObject = {OrionHome: orionHome, Location: params.resource}; >+ var locationRootObject = null; >+ if(params.resource) { >+ locationRootObject = {OrionHome: orionHome, Location: new mFileClient.FileClient(serviceRegistry).fileServiceRootURL(params.resource)}; >+ } > var infos = []; > navLinks.forEach(function(navLink) { > var info = {}; >@@ -54,7 +59,7 @@ > var d = new Deferred(); > i18nUtil.getMessageBundle(info.nls).then(function(commandMessages) { > var uriTemplate = new URITemplate(info.uriTemplate); >- var expandedHref = window.decodeURIComponent(uriTemplate.expand(locationObject)); >+ var expandedHref = window.decodeURIComponent(uriTemplate.expand( (info.useRootLocation && locationRootObject) ? locationRootObject : locationObject)); > expandedHref = PageUtil.validateURLScheme(expandedHref); > > info.href = expandedHref; >@@ -64,7 +69,7 @@ > infos.push(d); > } else if (info.uriTemplate && info.name) { > var uriTemplate = new URITemplate(info.uriTemplate); >- var expandedHref = window.decodeURIComponent(uriTemplate.expand(locationObject)); >+ var expandedHref = window.decodeURIComponent(uriTemplate.expand((info.useRootLocation && locationRootObject) ? locationRootObject : locationObject)); > expandedHref = PageUtil.validateURLScheme(expandedHref); > > info.href = expandedHref; >diff --git a/bundles/org.eclipse.orion.client.ui/web/plugins/pageLinksPlugin.js b/bundles/org.eclipse.orion.client.ui/web/plugins/pageLinksPlugin.js >index 36aabb8..2993263 100644 >--- a/bundles/org.eclipse.orion.client.ui/web/plugins/pageLinksPlugin.js >+++ b/bundles/org.eclipse.orion.client.ui/web/plugins/pageLinksPlugin.js >@@ -49,7 +49,8 @@ > nameKey: "Search", > id: "orion.Search", > nls: "orion/nls/messages", >- uriTemplate: "{OrionHome}/search/search.html" >+ useRootLocation:true, >+ uriTemplate: "{OrionHome}/search/search.html#{Location}" > }); > provider.registerService("orion.page.link", null, { > nameKey: "Editor",
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 Raw
Actions:
View
Attachments on
bug 419154
: 236351 |
236375