r13434 - in Products.Archetypes/trunk/Products/Archetypes/skins/archetypes/widgets: . js
"Matt Barkau" <[email protected]>
| Newsgroups | gmane.comp.web.zope.plone.archetypes.cvs |
|---|---|
| Message-ID | <[email protected]> |
Author: rmattb
Date: Tue Jan 25 04:25:17 2011
New Revision: 13434
Modified:
Products.Archetypes/trunk/Products/Archetypes/skins/archetypes/widgets/js/keywordmultiselect.js
Products.Archetypes/trunk/Products/Archetypes/skins/archetypes/widgets/keyword.pt
Log:
Move help text from template's js call to separate dom elements, to prepare for i18n. Refs #11017.
Modified: Products.Archetypes/trunk/Products/Archetypes/skins/archetypes/widgets/js/keywordmultiselect.js
==============================================================================
--- Products.Archetypes/trunk/Products/Archetypes/skins/archetypes/widgets/js/keywordmultiselect.js (original)
+++ Products.Archetypes/trunk/Products/Archetypes/skins/archetypes/widgets/js/keywordmultiselect.js Tue Jan 25 04:25:17 2011
@@ -337,11 +337,11 @@
});
if( i == 0 ) {
- $("#selectedTagsHeading").html( o.noneSelected );
+ $("#selectedTagsHeading").html( $("#noTagsSelected").text() );
$("#selectedTags").text('');
} else {
$("#selectedTags").html( display )
- $("#selectedTagsHeading").html( o.oneOrMoreSelected.replace('%', i) );
+ $("#selectedTagsHeading").html( $("#oneOrMoreTagsSelected").text().replace('%', i) );
}
}
Modified: Products.Archetypes/trunk/Products/Archetypes/skins/archetypes/widgets/keyword.pt
==============================================================================
--- Products.Archetypes/trunk/Products/Archetypes/skins/archetypes/widgets/keyword.pt (original)
+++ Products.Archetypes/trunk/Products/Archetypes/skins/archetypes/widgets/keyword.pt Tue Jan 25 04:25:17 2011
@@ -51,7 +51,7 @@
However, on touch-driven devices, vertical hover typically
scrolls the page, so horizontal hover is necessary to enable this.
Alternatively, clicking any of the tags also enables type-to-skip.
- So the text could techichally be extended to handle this special case
+ So the text could technically be extended to handle this special case
as "Hover or click and type the first letter to skip through tags.",
but I think this would be confusing to the majority of users.
</tal:comment>
@@ -72,6 +72,11 @@
</option>
</select>
<tal:comment tal:replace="nothing">
+ These spans are hidden by css, and used by the JavaScript called below.
+ </tal:comment>
+ <span id="noTagsSelected">No tags currently selected.</span>
+ <span id="oneOrMoreTagsSelected">% tags currently selected.</span>
+ <tal:comment tal:replace="nothing">
Call js to modify this widget with both a scrollbar and checkboxes.
There may be a better place to put this js call;
examples exist in others' widget.py and js files,
@@ -82,8 +87,6 @@
<script type="text/javascript">
jq(document).ready( function() {
jq("#subject").multiSelect({
- noneSelected: 'No tags currently selected.',
- oneOrMoreSelected: '% tags currently selected.',
listHeightPx: '120'
});
});
------------------------------------------------------------------------------
Special Offer-- Download ArcSight Logger for FREE (a $49 USD value)!
Finally, a world-class log management solution at an even better price-free!
Download using promo code Free_Logger_4_Dev2Dev. Offer expires
February 28th, so secure your free ArcSight Logger TODAY!
http://p.sf.net/sfu/arcsight-sfd2d