1 | diff '--exclude=*.pyc' -r django-1.4/db/models/fields/related.py django-custom/db/models/fields/related.py
|
---|
2 | 1120,1122d1119
|
---|
3 | < msg = _('Hold down "Control", or "Command" on a Mac, to select more than one.')
|
---|
4 | < self.help_text = string_concat(self.help_text, ' ', msg)
|
---|
5 | <
|
---|
6 | diff '--exclude=*.pyc' -r django-1.4/forms/fields.py django-custom/forms/fields.py
|
---|
7 | 28c28
|
---|
8 | < from django.utils.translation import ugettext_lazy as _
|
---|
9 | ---
|
---|
10 | > from django.utils.translation import ugettext_lazy as _, string_concat
|
---|
11 | 696a697,710
|
---|
12 | >
|
---|
13 | > def _patch_help_text(self):
|
---|
14 | > '''function that appends the help text. implemented only for
|
---|
15 | > sub-classes that use the SelectMultiple widget should call this
|
---|
16 | > on their constructor'''
|
---|
17 | > if hasattr(self, '_multiselect_patched') :
|
---|
18 | > pass
|
---|
19 | > else :
|
---|
20 | > if type(self.widget) is SelectMultiple :
|
---|
21 | > msg = _('Hold down "Control", or "Command" on a Mac, to select more than one.')
|
---|
22 | > self.help_text = string_concat(self.help_text, ' ', msg)
|
---|
23 | > setattr(self,'_multiselect_patched',True)
|
---|
24 | > else :
|
---|
25 | > setattr(self,'_multiselect_patched',False)
|
---|
26 | 771a786,788
|
---|
27 | > def __init__(self,*arg,**kwarg):
|
---|
28 | > super(MultipleChoiceField,self).__init__(*arg,**kwarg)
|
---|
29 | > self._patch_help_text()
|
---|
30 | diff '--exclude=*.pyc' -r django-1.4/forms/models.py django-custom/forms/models.py
|
---|
31 | 930a931,933
|
---|
32 | >
|
---|
33 | > self._patch_help_text()
|
---|
34 | >
|
---|