/[suikacvs]/markup/html/whatpm/Whatpm/ContentChecker.pm
Suika

Diff of /markup/html/whatpm/Whatpm/ContentChecker.pm

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1.105 by wakaba, Fri Dec 12 11:50:47 2008 UTC revision 1.106 by wakaba, Fri Dec 12 12:59:17 2008 UTC
# Line 580  sub check_element ($$$;$) { Line 580  sub check_element ($$$;$) {
580    $self->{id} = {};    $self->{id} = {};
581    $self->{id_type} = {}; # 'form' / 'labelable' / 'menu'    $self->{id_type} = {}; # 'form' / 'labelable' / 'menu'
582    $self->{form} = {}; # form/@name    $self->{form} = {}; # form/@name
583      #$self->{has_autofocus};
584    $self->{idref} = []; # @form, @for, @contextmenu    $self->{idref} = []; # @form, @for, @contextmenu
585    $self->{term} = {};    $self->{term} = {};
586    $self->{usemap} = [];    $self->{usemap} = [];
# Line 799  next unless $code;## TODO: temp. Line 800  next unless $code;## TODO: temp.
800    }    }
801    
802    for (@{$self->{idref}}) {    for (@{$self->{idref}}) {
803      if ($self->{id}->{$_->[1]} and      if ($self->{id}->{$_->[1]} and $self->{id_type}->{$_->[1]} eq $_->[0]) {
804          $self->{id_type}->{$_->[1]} eq $_->[0]) {        #
805        } elsif ($_->[0] eq 'any' and $self->{id}->{$_->[1]}) {
806        #        #
807      } else {      } else {
808        $self->{onerror}->(node => $_->[2],        $self->{onerror}->(node => $_->[2],
809                           type => {                           type => {
810                                      any => 'no referenced element', ## TODOC: type
811                                    form => 'no referenced form',                                    form => 'no referenced form',
812                                    labelable => 'no referenced control',                                    labelable => 'no referenced control',
813                                    menu => 'no referenced menu',                                    menu => 'no referenced menu',
814                                    datalist => 'no referenced datalist', ## TODOC: type                                    datalist => 'no referenced datalist', ## TODOC: type
815                                   }->{$_->[0]},                                   }->{$_->[0]},
816                             value => $_->[1],
817                           level => $self->{level}->{must});                           level => $self->{level}->{must});
818      }      }
819    }    }
# Line 820  next unless $code;## TODO: temp. Line 824  next unless $code;## TODO: temp.
824    delete $self->{id};    delete $self->{id};
825    delete $self->{id_type};    delete $self->{id_type};
826    delete $self->{form};    delete $self->{form};
827      delete $self->{has_autofocus};
828    delete $self->{idref};    delete $self->{idref};
829    delete $self->{usemap};    delete $self->{usemap};
830    delete $self->{ref};    delete $self->{ref};

Legend:
Removed from v.1.105  
changed lines
  Added in v.1.106

admin@suikawiki.org
ViewVC Help
Powered by ViewVC 1.1.24