[kupu-checkins] r45298 - in kupu/trunk/kupu/plone: . kupu_plone_layer
duncan at codespeak.net
duncan at codespeak.net
Tue Jul 24 12:38:54 CEST 2007
Author: duncan
Date: Tue Jul 24 12:38:54 2007
New Revision: 45298
Modified:
kupu/trunk/kupu/plone/body.kupu
kupu/trunk/kupu/plone/kupu_plone_layer/kupu_wysiwyg_support.html
Log:
Plone ticket 6739
Hide the "edit without visual editor" link when there is only one format available (and since we only show the link when editing html, by definition if there is one format it is text/html).
Modified: kupu/trunk/kupu/plone/body.kupu
==============================================================================
--- kupu/trunk/kupu/plone/body.kupu (original)
+++ kupu/trunk/kupu/plone/body.kupu Tue Jul 24 12:38:54 2007
@@ -65,8 +65,8 @@
<kupu:part name="suppress-kupu">
<div class="kupuoverride"
- tal:condition="python:exists('kupu_content') and len(kupu_content)==0"
- tal:define="floated widget/allow_file_upload | python:1;"
+ tal:condition="python:exists('kupu_content') and len(kupu_content)==0 and gAC and len(gAC(here))!=1"
+ tal:define="floated widget/allow_file_upload | python:1;gAC nocall:field/getAllowedContentTypes|nothing"
tal:attributes="style python:test(floated, 'float:left;;', '');"
><span class="discreet"><a class="forcekupu" href="#"
i18n:translate="suppress-kupu" i18n:attributes="title title_suppress_kupu;"
Modified: kupu/trunk/kupu/plone/kupu_plone_layer/kupu_wysiwyg_support.html
==============================================================================
--- kupu/trunk/kupu/plone/kupu_plone_layer/kupu_wysiwyg_support.html (original)
+++ kupu/trunk/kupu/plone/kupu_plone_layer/kupu_wysiwyg_support.html Tue Jul 24 12:38:54 2007
@@ -27,7 +27,7 @@
<!--$Id: drawers.kupu 44538 2007-06-26 10:46:28Z duncan $-->
<!--$Id: beforeunload.kupu 14546 2005-07-12 14:35:55Z duncan $-->
<!--$Id: sourceedit.kupu 44538 2007-06-26 10:46:28Z duncan $-->
- <!--$Id: wysiwyg_support.kupu 44538 2007-06-26 10:46:28Z duncan $-->
+ <!--$Id: wysiwyg_support.kupu 45010 2007-07-13 11:23:06Z duncan $-->
<div xmlns:metal="http://xml.zope.org/namespaces/metal" xmlns:tal="http://xml.zope.org/namespaces/tal" metal:define-macro="wysiwygEditorBox" id="kupu-editor" tal:define="name fieldName|inputname; editorid string:kupu-editor-${name}" tal:attributes="id editorid">
@@ -477,7 +477,7 @@
</textarea>
</div>
- <div class="kupuoverride" tal:condition="python:exists('kupu_content') and len(kupu_content)==0" tal:define="floated widget/allow_file_upload | python:1;" tal:attributes="style python:test(floated, 'float:left;;', '');"><span class="discreet"><a class="forcekupu" href="#" i18n:translate="suppress-kupu" i18n:attributes="title title_suppress_kupu;" tal:define="fs fieldset|nothing;fs python:test(fs,'&fieldset=%s'%fs,None);" tal:attributes="href string:${request/URL0}?kupu.suppress=${fieldName}${fs};" title="reload current page without kupu">
+ <div class="kupuoverride" tal:condition="python:exists('kupu_content') and len(kupu_content)==0 and gAC and len(gAC(here))!=1" tal:define="floated widget/allow_file_upload | python:1;gAC nocall:field/getAllowedContentTypes|nothing" tal:attributes="style python:test(floated, 'float:left;;', '');"><span class="discreet"><a class="forcekupu" href="#" i18n:translate="suppress-kupu" i18n:attributes="title title_suppress_kupu;" tal:define="fs fieldset|nothing;fs python:test(fs,'&fieldset=%s'%fs,None);" tal:attributes="href string:${request/URL0}?kupu.suppress=${fieldName}${fs};" title="reload current page without kupu">
Edit without visual editor
</a></span>
</div>
More information about the kupu-checkins
mailing list