[Nuxeo-tickets] [Nuxeo Repository] #1758: CPSDocument.FlexibleTypeInformation.flexibleDelWidgets don't recognize compound widgets

Nuxeo Repository trac at nuxeo.com
Tue Oct 10 03:16:50 CEST 2006


#1758: CPSDocument.FlexibleTypeInformation.flexibleDelWidgets don't recognize
compound widgets
-------------------------+--------------------------------------------------
 Reporter:  tracguest    |       Owner:  fguillaume
     Type:  defect       |      Status:  new       
 Priority:  P2           |   Milestone:            
Component:  CPSDocument  |     Version:  TRUNK     
 Severity:  normal       |    Keywords:            
-------------------------+--------------------------------------------------
 Hi,

 CPS Compound Widget's meta_type is 'Compound Widget', not 'CPS Compound
 Widget'. Or using flexibleAddWidget code:

 {{{
 Index: CPSDocument/FlexibleTypeInformation.py
 ===================================================================
 --- CPSDocument/FlexibleTypeInformation.py      (revision 49441)
 +++ CPSDocument/FlexibleTypeInformation.py      (working copy)
 @@ -443,7 +443,7 @@
          new_widget_ids = []
          for widget_id in widget_ids:
              widget = layout[widget_id]
 -            if widget.meta_type == 'CPS Compound Widget':
 +            if isinstance(widget, CPSCompoundWidget):
                  new_widget_ids.extend(widget.widget_ids)
              new_widget_ids.append(widget_id)
 }}}

 Yves Bastide

-- 
Ticket URL: <http://svn.nuxeo.org/trac/pub/ticket/1758>
Nuxeo Repository <http://www.cps-project.org/>
Nuxeo Repository



This list archive provided by Nuxeo, the leaders of open source ECM. Check out the Nuxeo 5 open source, standards-based ECM project.