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

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

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

revision 1.136 by wakaba, Sat May 24 04:26:26 2008 UTC revision 1.137 by wakaba, Sat May 24 09:59:52 2008 UTC
# Line 4329  sub _reset_insertion_mode ($) { Line 4329  sub _reset_insertion_mode ($) {
4329        if ($self->{open_elements}->[0]->[0] eq $node->[0]) {        if ($self->{open_elements}->[0]->[0] eq $node->[0]) {
4330          $last = 1;          $last = 1;
4331          if (defined $self->{inner_html_node}) {          if (defined $self->{inner_html_node}) {
4332            if ($self->{inner_html_node}->[1] & TABLE_CELL_EL) {            
4333                          $node = $self->{inner_html_node};
4334              #          } else {
4335            } else {            die "_reset_insertion_mode: t27";
               
             $node = $self->{inner_html_node};  
           }  
4336          }          }
4337        }        }
4338              
4339      ## Step 4..14        ## Step 4..14
4340      my $new_mode;        my $new_mode;
4341      if ($node->[1] & FOREIGN_EL) {        if ($node->[1] & FOREIGN_EL) {
4342        ## NOTE: Strictly spaking, the line below only applies to MathML and          
4343        ## SVG elements.  Currently the HTML syntax supports only MathML and          ## NOTE: Strictly spaking, the line below only applies to MathML and
4344        ## SVG elements as foreigners.          ## SVG elements.  Currently the HTML syntax supports only MathML and
4345        $new_mode = $self->{insertion_mode} | IN_FOREIGN_CONTENT_IM;          ## SVG elements as foreigners.
4346        ## ISSUE: What is set as the secondary insertion mode?          $new_mode = $self->{insertion_mode} | IN_FOREIGN_CONTENT_IM;
4347      } else {          ## ISSUE: What is set as the secondary insertion mode?
4348        $new_mode = {        } elsif ($node->[1] & TABLE_CELL_EL) {
4349            if ($last) {
4350              
4351              #
4352            } else {
4353              
4354              $new_mode = IN_CELL_IM;
4355            }
4356          } else {
4357            
4358            $new_mode = {
4359                        select => IN_SELECT_IM,                        select => IN_SELECT_IM,
4360                        ## NOTE: |option| and |optgroup| do not set                        ## NOTE: |option| and |optgroup| do not set
4361                        ## insertion mode to "in select" by themselves.                        ## insertion mode to "in select" by themselves.
                       td => IN_CELL_IM,  
                       th => IN_CELL_IM,  
4362                        tr => IN_ROW_IM,                        tr => IN_ROW_IM,
4363                        tbody => IN_TABLE_BODY_IM,                        tbody => IN_TABLE_BODY_IM,
4364                        thead => IN_TABLE_BODY_IM,                        thead => IN_TABLE_BODY_IM,
# Line 4365  sub _reset_insertion_mode ($) { Line 4370  sub _reset_insertion_mode ($) {
4370                        body => IN_BODY_IM,                        body => IN_BODY_IM,
4371                        frameset => IN_FRAMESET_IM,                        frameset => IN_FRAMESET_IM,
4372                       }->{$node->[0]->manakai_local_name};                       }->{$node->[0]->manakai_local_name};
4373      }        }
4374      $self->{insertion_mode} = $new_mode and return if defined $new_mode;        $self->{insertion_mode} = $new_mode and return if defined $new_mode;
4375                
4376        ## Step 15        ## Step 15
4377        if ($node->[1] & HTML_EL) {        if ($node->[1] & HTML_EL) {

Legend:
Removed from v.1.136  
changed lines
  Added in v.1.137

[email protected]
ViewVC Help
Powered by ViewVC 1.1.24