Ignore:
Timestamp:
10 Feb 2015, 09:37:53 (10 years ago)
Author:
Henrik Bettermann
Message:

The regular height of text widgets should be 3.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • main/waeup.ikoba/trunk/src/waeup/ikoba/browser/layout.py

    r12235 r12576  
    190190    hide_hint = True
    191191
     192def large_text_field(widget):
     193    for i in  ('body', 'frontpage', 'multilingual', 'condition'):
     194        if i in widget.name:
     195            return True
     196    return False
     197
    192198class IkobaEditFormPage(UtilityView,EditForm):
    193199    """A megrok.layout.EditForm with additional methods.
     
    199205        super(IkobaEditFormPage,self).setUpWidgets(ignore_request)
    200206        for widget in self.widgets:
    201             if 'address' in widget.name or \
    202                 'comment' in widget.name or \
    203                 'description' in widget.name or \
    204                 'notice' in widget.name:
     207            if not large_text_field(widget):
    205208                widget.height = 3
    206209
     
    214217        super(IkobaAddFormPage,self).setUpWidgets(ignore_request)
    215218        for widget in self.widgets:
    216             if 'address' in widget.name or \
    217                 'comment' in widget.name or \
    218                 'description' in widget.name or \
    219                 'notice' in widget.name:
     219            if not large_text_field(widget):
    220220                widget.height = 3
    221221
Note: See TracChangeset for help on using the changeset viewer.