From 6c63633545c254dc085402e0f927a6826d1dd229 Mon Sep 17 00:00:00 2001 From: Akinori Ito Date: Fri, 9 Nov 2001 04:59:17 +0000 Subject: Updates from 0.2.1 into 0.2.1-inu-1.5 --- map.c | 41 ++++++++++++++++++++++++----------------- 1 file changed, 24 insertions(+), 17 deletions(-) (limited to 'map.c') diff --git a/map.c b/map.c index 906d3ba..c4e06ae 100644 --- a/map.c +++ b/map.c @@ -72,11 +72,11 @@ follow_map_panel(Buffer * buf, struct parsed_tagarg *arg) t = t->next, s = s->next) { parseURL2(t->ptr, &pu, baseURL(buf)); Strcat_charp(mappage, "ptr)); + Strcat_charp(mappage, html_quote(parsedURL2Str(&pu)->ptr)); Strcat_charp(mappage, "\">"); - Strcat_charp(mappage, htmlquote_str(s->ptr)); + Strcat_charp(mappage, html_quote(s->ptr)); Strcat_charp(mappage, " "); - Strcat_charp(mappage, htmlquote_str(t->ptr)); + Strcat_charp(mappage, html_quote(t->ptr)); Strcat_charp(mappage, "
\n"); } Strcat_charp(mappage, ""); @@ -87,9 +87,9 @@ follow_map_panel(Buffer * buf, struct parsed_tagarg *arg) /* append frame URL */ static void -append_frame_info(Str html, struct frameset *set, int level) +append_frame_info(Buffer *buf, Str html, struct frameset *set, int level) { - char *q; + char *p, *q; int i, j; if (!set) @@ -105,17 +105,24 @@ append_frame_info(Str html, struct frameset *set, int level) break; for (j = 0; j < level; j++) Strcat_charp(html, " "); - q = htmlquote_str(frame.body->url); + q = html_quote(frame.body->url); Strcat_charp(html, ""); - Strcat_charp(html, htmlquote_str(frame.body->name)); + if (frame.body->name) { + p = file_unquote(frame.body->name); +#ifdef JP_CHARSET + p = conv(p, buf->document_code, InnerCode)->ptr; +#endif + p = html_quote(p); + Strcat_charp(html, p); + } Strcat_charp(html, " "); Strcat_charp(html, q); Strcat_charp(html, "\n"); break; case F_FRAMESET: - append_frame_info(html, frame.set, level + 1); + append_frame_info(buf, html, frame.set, level + 1); break; } } @@ -141,16 +148,16 @@ page_info_panel(Buffer * buf) if (buf == NULL) goto end; Strcat_charp(tmp, "Title"); - Strcat_charp(tmp, htmlquote_str(buf->buffername)); + Strcat_charp(tmp, html_quote(buf->buffername)); Strcat_charp(tmp, "Current URL"); - Strcat_charp(tmp, htmlquote_str(parsedURL2Str(&buf->currentURL)->ptr)); + Strcat_charp(tmp, html_quote(parsedURL2Str(&buf->currentURL)->ptr)); Strcat_charp(tmp, "Document Type"); if (buf->real_type) Strcat_charp(tmp, buf->real_type); else Strcat_charp(tmp, "unknown"); Strcat_charp(tmp, "Last Modified"); - Strcat_charp(tmp, htmlquote_str(last_modified(buf))); + Strcat_charp(tmp, html_quote(last_modified(buf))); #ifdef JP_CHARSET Strcat_charp(tmp, "Document Code"); Strcat_charp(tmp, code_to_str(buf->document_code)); @@ -168,7 +175,7 @@ page_info_panel(Buffer * buf) parseURL2(a->url, &pu, baseURL(buf)); s = parsedURL2Str(&pu); Strcat_charp(tmp, "URL of current anchor"); - Strcat_charp(tmp, htmlquote_str(s->ptr)); + Strcat_charp(tmp, html_quote(s->ptr)); } a = retrieveCurrentImg(buf); if (a != NULL) { @@ -176,23 +183,23 @@ page_info_panel(Buffer * buf) s = parsedURL2Str(&pu); Strcat_charp(tmp, "URL of current image"); Strcat_charp(tmp, "ptr)); + Strcat_charp(tmp, html_quote(s->ptr)); Strcat_charp(tmp, "\">"); - Strcat_charp(tmp, htmlquote_str(s->ptr)); + Strcat_charp(tmp, html_quote(s->ptr)); Strcat_charp(tmp, ""); } a = retrieveCurrentForm(buf); if (a != NULL) { s = Strnew_charp(form2str((FormItemList *) a->url)); Strcat_charp(tmp, "Method/type of current form"); - Strcat_charp(tmp, htmlquote_str(s->ptr)); + Strcat_charp(tmp, html_quote(s->ptr)); } Strcat_charp(tmp, "\n"); if (buf->document_header != NULL) { Strcat_charp(tmp, "
\n"); Strcat_charp(tmp, "

Header information

\n"); for (ti = buf->document_header->first; ti != NULL; ti = ti->next) { - Strcat_charp(tmp, htmlquote_str(ti->ptr)); + Strcat_charp(tmp, html_quote(ti->ptr)); Strcat_charp(tmp, "
"); } } @@ -205,7 +212,7 @@ page_info_panel(Buffer * buf) if (f_set) { Strcat_charp(tmp, "

Frame information

");
-	append_frame_info(tmp, f_set, 0);
+	append_frame_info(buf, tmp, f_set, 0);
 	Strcat_charp(tmp, "
"); } #ifdef USE_SSL -- cgit v1.2.3