| author | Maciej Bendkowski | 2012-08-08 11:36:37 (EDT) |
|---|---|---|
| committer | Malgorzata Janczarska | 2012-08-08 11:37:26 (EDT) |
| commit | d9d86325b792eea59050bcf9082c6c699e41a178 (patch) (side-by-side diff) | |
| tree | 474e21b30e2922ba932255ea42b0022c4c8b1f16 | |
| parent | 73356fdf34ec1bc59928d55fe3eb67b81e034dc3 (diff) | |
| download | org.eclipse.orion.client-d9d86325b792eea59050bcf9082c6c699e41a178.zip org.eclipse.orion.client-d9d86325b792eea59050bcf9082c6c699e41a178.tar.gz org.eclipse.orion.client-d9d86325b792eea59050bcf9082c6c699e41a178.tar.bz2 | |
Bug 381929 -"Search" unexternalized
3 files changed, 7 insertions, 5 deletions
diff --git a/bundles/org.eclipse.orion.client.core/web/orion/commonHTMLFragments.js b/bundles/org.eclipse.orion.client.core/web/orion/commonHTMLFragments.js index 133d9cf..2344b2d 100644 --- a/bundles/org.eclipse.orion.client.core/web/orion/commonHTMLFragments.js +++ b/bundles/org.eclipse.orion.client.core/web/orion/commonHTMLFragments.js @@ -32,7 +32,7 @@ define(['i18n!orion/nls/messages', 'require'], '<div class="layoutRight">' + //$NON-NLS-0$ '<div id="globalActions" class="spacingLeft layoutLeft"></div>' + //$NON-NLS-0$ '<div id="relatedLinks" class="spacingLeft layoutLeft" style="padding-top:1px;"></div>' + //$NON-NLS-0$ - '<input type="text" id="search" placeholder="Search" title="'+messages['Type a keyword or wild card to search in root']+'" class="layoutLeft spacingLeft searchbox" role="search">' + //$NON-NLS-2$ //$NON-NLS-0$ + '<input type="text" id="search" placeholder="'+messages['Search']+'" title="'+messages['Type a keyword or wild card to search in root']+'" class="layoutLeft spacingLeft searchbox" role="search">' + //$NON-NLS-2$ //$NON-NLS-0$ // '<div id="userInfo" style= "display:none;" class="layoutLeft primaryNav"></div>' + //$NON-NLS-0$ '<div id="userMenu" class="spacingLeft layoutLeft"></div>' + //$NON-NLS-0$ '</div>' + //$NON-NLS-0$ diff --git a/bundles/org.eclipse.orion.client.core/web/orion/search/nls/root/messages.js b/bundles/org.eclipse.orion.client.core/web/orion/search/nls/root/messages.js index 252f383..826fb50 100644 --- a/bundles/org.eclipse.orion.client.core/web/orion/search/nls/root/messages.js +++ b/bundles/org.eclipse.orion.client.core/web/orion/search/nls/root/messages.js @@ -32,7 +32,7 @@ define({ " matches": " matches", "Replaced ": "Replaced ", "Nothing replaced": "Nothing replaced", - "Search ": "Search ", + "Search ${0}": "Search ${0}", "Type a keyword or wild card to search in ": "Type a keyword or wild card to search in ", "Search failed.": "Search failed.", "No matches found for ": "No matches found for ", diff --git a/bundles/org.eclipse.orion.client.core/web/orion/searchClient.js b/bundles/org.eclipse.orion.client.core/web/orion/searchClient.js index fa92f96..a97e920 100644 --- a/bundles/org.eclipse.orion.client.core/web/orion/searchClient.js +++ b/bundles/org.eclipse.orion.client.core/web/orion/searchClient.js @@ -118,10 +118,12 @@ function(messages, require, dojo, dijit, mAuth, mUtil, mSearchUtils, mSearchCraw } if(searchInputDom && searchInputDom.placeholder){ searchInputDom.value = ""; - if(locationName.length > 23){ - searchInputDom.placeholder = messages["Search "] + locationName.substring(0, 20) + "..."; //$NON-NLS-1$ + var placeHolder = dojo.string.substitute(messages["Search ${0}"], [locationName]); + + if(placeHolder.length > 30){ + searchInputDom.placeholder = placeHolder.substring(0, 27) + "..."; //$NON-NLS-1$ } else { - searchInputDom.placeholder = messages['Search '] + locationName; + searchInputDom.placeholder = dojo.string.substitute(messages["Search ${0}"], [locationName]); } } if(searchInputDom && searchInputDom.title){ |

