From e573b110cfc91ca8bcf100f29d2a0f9acca5aa34 Mon Sep 17 00:00:00 2001 From: fukachan Date: Thu, 26 Feb 2004 13:19:37 +0000 Subject: implement set_language_hint(), get_language_hint(). get_accept_language_list() returns [] not [*] when no data. --- fml/lib/FML/Process/Utils.pm | 30 ++++++++++++++++++++++++++++-- 1 file changed, 28 insertions(+), 2 deletions(-) (limited to 'fml/lib') diff --git a/fml/lib/FML/Process/Utils.pm b/fml/lib/FML/Process/Utils.pm index f2f9f835..cf2dc4e8 100644 --- a/fml/lib/FML/Process/Utils.pm +++ b/fml/lib/FML/Process/Utils.pm @@ -4,7 +4,7 @@ # All rights reserved. This program is free software; you can # redistribute it and/or modify it under the same terms as Perl itself. # -# $FML: Utils.pm,v 1.104 2004/02/15 04:38:34 fukachan Exp $ +# $FML: Utils.pm,v 1.105 2004/02/26 08:07:00 fukachan Exp $ # package FML::Process::Utils; @@ -1510,6 +1510,32 @@ sub language_of_html_file } +# Descriptions: set the current charset hint. +# Arguments: OBJ($curproc) STR($category) STR($charset) +# Side Effects: none +# Return Value: none +sub set_language_hint +{ + my ($curproc, $category, $charset) = @_; + my $pcb = $curproc->pcb(); + + $pcb->set("language_hint", $category, $charset); +} + + +# Descriptions: get the current charset hint. +# Arguments: OBJ($curproc) STR($category) +# Side Effects: none +# Return Value: none +sub get_language_hint +{ + my ($curproc, $category) = @_; + my $pcb = $curproc->pcb(); + + $pcb->get("language_hint", $category); +} + + # Descriptions: set the current charset. # Arguments: OBJ($curproc) STR($category) STR($charset) # Side Effects: none @@ -1620,7 +1646,7 @@ sub get_accept_language_list return $pcb->get('incoming_message', 'accept-language'); } else { - return [ '*' ]; + return [ ]; } } -- cgit v1.2.1