changeset 1360:6668c52d94e2

don't appear to need WordAfterLI anymore
author corvid <corvid@lavabit.com>
date Sat, 24 Oct 2009 00:27:08 +0000
parents b60ff98205cb
children 18d540ca1780
files src/html.cc src/html_common.hh
diffstat 2 files changed, 1 insertions(+), 12 deletions(-) [+]
line wrap: on
line diff
--- a/src/html.cc	Fri Oct 23 22:57:05 2009 +0000
+++ b/src/html.cc	Sat Oct 24 00:27:08 2009 +0000
@@ -1213,8 +1213,6 @@
       if (Pword == word2)
          dFree(Pword);
    }
-   if (html->InFlags & IN_LI)
-      html->WordAfterLI = true;
 }
 
 /*
@@ -1792,13 +1790,7 @@
    a_Html_tag_set_align_attr (html, &props, tag, tagsize);
    html->styleEngine->inheritBackgroundColor ();
    html->styleEngine->setNonCssHints (&props);
-
-   if ((html->InFlags & IN_LI) && !html->WordAfterLI) {
-      /* ignore first parbreak after an empty <LI> */
-      html->WordAfterLI = true;
-   } else {
-      HT2TB(html)->addParbreak (9, html->styleEngine->wordStyle ());
-   }
+   HT2TB(html)->addParbreak (9, html->styleEngine->wordStyle ());
 }
 
 /*
@@ -2639,7 +2631,6 @@
       BUG_MSG("<li> outside <ul> or <ol>\n");
 
    html->InFlags |= IN_LI;
-   html->WordAfterLI = false;
 
    /* Get our parent tag's variables (used as state storage) */
    list_number = &html->stack->getRef(html->stack->size()-2)->list_number;
@@ -2680,7 +2671,6 @@
 static void Html_tag_close_li(DilloHtml *html, int TagIdx)
 {
    html->InFlags &= ~IN_LI;
-   html->WordAfterLI = false;
    ((ListItem *)html->dw)->flush ();
 }
 
--- a/src/html_common.hh	Fri Oct 23 22:57:05 2009 +0000
+++ b/src/html_common.hh	Sat Oct 24 00:27:08 2009 +0000
@@ -171,7 +171,6 @@
    bool PrevWasSPC;       /* Flag to help handling collapsing white space */
    bool InVisitedLink;    /* used to 'contrast_visited_colors' */
    bool ReqTagClose;      /* Flag to help handling bad-formed HTML */
-   bool WordAfterLI;      /* Flag to help ignoring the 1st <P> after <LI> */
    bool TagSoup;          /* Flag to enable the parser's cleanup functions */
    bool loadCssFromStash; /* current stash content should be loaded as CSS */