[Jifty-commit] r1349 - in jifty/trunk: lib/Jifty/Web/Form
lib/Jifty/Web/Form/Field
jifty-commit at lists.jifty.org
jifty-commit at lists.jifty.org
Thu Jun 22 15:09:56 EDT 2006
Author: seanmil
Date: Thu Jun 22 15:09:51 2006
New Revision: 1349
Modified:
jifty/trunk/ (props changed)
jifty/trunk/lib/Jifty/Web/Form/Field.pm
jifty/trunk/lib/Jifty/Web/Form/Field/Combobox.pm
jifty/trunk/lib/Jifty/Web/Form/Field/Password.pm
Log:
r566 at pc102: sean | 2006-06-22 12:51:57 -0400
* Remove apparently unused 'autocomplete' attribute from tags
* Subclass render_autocomplete to make sure Combobox and Password
never provide an autocompleter.
Modified: jifty/trunk/lib/Jifty/Web/Form/Field.pm
==============================================================================
--- jifty/trunk/lib/Jifty/Web/Form/Field.pm (original)
+++ jifty/trunk/lib/Jifty/Web/Form/Field.pm Thu Jun 22 15:09:51 2006
@@ -408,12 +408,12 @@
=head2 other_widget_properties
-If your widget subclass has other properties it wants to insert into the html of the main widget and you haven't subclassed render_widget,
-
-just stick them in your local sub render_widget.
-
-We use this for marking password fields as not-autocomplete
+If your widget subclass has other properties it wants to insert into the html
+of the main widget and you haven't subclassed render_widget you can subclass
+this to do so.
+Otherwise, if you have already subclassed render_widget, just stick them in
+your local sub render_widget.
=cut
Modified: jifty/trunk/lib/Jifty/Web/Form/Field/Combobox.pm
==============================================================================
--- jifty/trunk/lib/Jifty/Web/Form/Field/Combobox.pm (original)
+++ jifty/trunk/lib/Jifty/Web/Form/Field/Combobox.pm Thu Jun 22 15:09:51 2006
@@ -23,7 +23,7 @@
value="@{[ $self->current_value ]}"
type="text"
size="30"
- autocomplete="off" /><span id="@{[ $self->element_id ]}_Button"
+ /><span id="@{[ $self->element_id ]}_Button"
@{[ $self->_widget_class('combo-button')]}
></span></span><span style="display: none"></span><select
name="@{[ $self->input_name ]}"
@@ -61,4 +61,12 @@
'';
}
+=head2 render_autocomplete
+
+Never render anything for autocomplete.
+
+=cut
+
+sub render_autocomplete {''}
+
1;
Modified: jifty/trunk/lib/Jifty/Web/Form/Field/Password.pm
==============================================================================
--- jifty/trunk/lib/Jifty/Web/Form/Field/Password.pm (original)
+++ jifty/trunk/lib/Jifty/Web/Form/Field/Password.pm Thu Jun 22 15:09:51 2006
@@ -21,16 +21,13 @@
sub current_value {''}
+=head2 render_autocomplete
-=head2 other_widget_properties
-
-No completion in password fields ;)
+Never render anything for autocompletion.
=cut
-sub other_widget_properties {
- return q{autocomplete="off"};
-}
+sub render_autocomplete {''}
=head2 render_value
More information about the Jifty-commit
mailing list