w3m

Unnamed repository; edit this file to name it for gitweb.
git clone https://logand.com/git/w3m.git/
Log | Files | Refs | README

commit fecd38242cddf2e00bbf7dd6b9db63e081e0ac32
parent c56f45f87fb12ce20224d2d629c9c22ce75f7fff
Author: ukai <ukai>
Date:   Mon, 12 May 2003 16:24:50 +0000

[w3m-dev 03895] type=image support of pre_form
* form.c (loadPreFOrm): add image
	(preFormUpdateBuffer): add FORM_INPUT_IMAGE
* doc/README.pre_form: update
* doc-jp/README.pre_form: ditto
From: Hironori SAKAMOTO <h-saka@lsi.nec.co.jp>

Diffstat:
MChangeLog | 8++++++++
Mdoc-jp/README.pre_form | 9+++++----
Mdoc/README.pre_form | 10++++++----
Mform.c | 6+++++-
4 files changed, 24 insertions(+), 9 deletions(-)

diff --git a/ChangeLog b/ChangeLog @@ -1,3 +1,11 @@ +2003-05-13 Hironori SAKAMOTO <h-saka@lsi.nec.co.jp> + + * [w3m-dev 03895] type=image support of pre_form + * form.c (loadPreFOrm): add image + (preFormUpdateBuffer): add FORM_INPUT_IMAGE + * doc/README.pre_form: update + * doc-jp/README.pre_form: ditto + 2003-05-11 Fumitoshi UKAI <ukai@debian.or.jp> * [w3m-dev 03891] Re: urimethodmap and relative URL diff --git a/doc-jp/README.pre_form b/doc-jp/README.pre_form @@ -14,7 +14,8 @@ password <name> <value> checkbox <name> <value> [<checked>] radio <name> <value> section <name> <value> -submit [<name>] +submit [<name> [<value>]] +image [<name> [<value>]] textarea <name> <value> : @@ -28,7 +29,7 @@ input, select $B$^$?$O(B textarea $BMWAG$N(B value $BB0@-$r@_Dj$7$^$9!#(B checkbox, radio $B$O(B name $BB0@-$H(B value $BB0@-$,0lCW$9$k(B input $BMWAG$r(B check $B$7$^$9!#(B <checked> $B$,(B 0$B!"(Bno $B$^$?$O(B off $B$N>l9g$O(B checkbox $B$N(B check $B$r30$7$^$9!#(B -submit $B$N>l9g!"(B<name> $B$,@_Dj$7$F$"$k;~$O!"0lCW$9$k(B name $BB0@-$r;}$D(B -input $BMWAG$r(B submit $B$7$^$9!#(B<name> $B$,@_Dj$7$F$$$J$$>l9g$O!":G8e$N(B -input type=submit $BMWAG$r(B submit $B$7$^$9!#(B +submit, image $B$N>l9g!"(B<name> $B$,@_Dj$7$F$"$k;~$O!"0lCW$9$k(B name $BB0@-(B +($B$H(B value $BB0@-(B)$B$r;}$D(B input $BMWAG$r(B submit $B$7$^$9!#(B<name> $B$r@_Dj$7$F(B +$B$$$J$$>l9g$O!":G8e$N(B input type=submit $BMWAG$r(B submit $B$7$^$9!#(B <name> $B$d(B <value> $B$O!"%7%'%k$NMM$K(B \,'$B!A(B',"$B!A(B" $B$G%/%)!<%H2DG=$G$9!#(B diff --git a/doc/README.pre_form b/doc/README.pre_form @@ -16,7 +16,8 @@ password <name> <value> checkbox <name> <value> [<checked>] radio <name> <value> section <name> <value> -submit [<name>] +submit [<name> [<value>]] +image [<name> [<value>]] textarea <name> <value> : @@ -33,9 +34,10 @@ The line beginning with checkbox, radio means that it will check input element which name and value attribute matches with <name> and <value> respectively. If <checked> is 0, no, or off, disable check of the checkbox. -The line beginning with submit means that it will submit input element which -name attribute matches with <name>, or submit last <input type=submit> -element if no <name> specified. +The line beginning with submit or image means that it will submit input +element which name attribute matches with <name> (and value attribute +matches with <value>), or submit last <input type=submit> element if no +<name> specified. You quote \, ' (single-quote) or " (double quote) as you do in shell. diff --git a/form.c b/form.c @@ -727,6 +727,7 @@ add_pre_form_item(struct pre_form *pf, struct pre_form_item *prev, int type, * radio <name> <value> * select <name> <value> * submit [<name> [<value>]] + * image [<name> [<value>]] * textarea <name> * <value> * /textarea @@ -810,6 +811,8 @@ loadPreForm(void) type = FORM_INPUT_RADIO; else if (!strcmp(s, "submit")) type = FORM_INPUT_SUBMIT; + else if (!strcmp(s, "image")) + type = FORM_INPUT_IMAGE; else if (!strcmp(s, "select")) type = FORM_SELECT; else if (!strcmp(s, "textarea")) { @@ -873,7 +876,8 @@ preFormUpdateBuffer(Buffer *buf) for (pi = pf->item; pi; pi = pi->next) { if (pi->type != fi->type) continue; - if (pi->type == FORM_INPUT_SUBMIT) { + if (pi->type == FORM_INPUT_SUBMIT || + pi->type == FORM_INPUT_IMAGE) { if ((!pi->name || !*pi->name || (fi->name && !Strcmp_charp(fi->name, pi->name))) && (!pi->value || !*pi->value ||