[Po4a-commits] "po4a/lib/Locale/Po4a Xml.pm,1.92,1.93"

Nicolas FRANCOIS nekral-guest at alioth.debian.org
Sun Feb 22 10:12:00 UTC 2009


Update of /cvsroot/po4a/po4a/lib/Locale/Po4a
In directory alioth:/tmp/cvs-serv8757/lib/Locale/Po4a

Modified Files:
	Xml.pm 
Log Message:
	* lib/Locale/Po4a/Xml.pm: Remove the translate argument from
	translate_paragraph(). It is not used anymore.


Index: Xml.pm
===================================================================
RCS file: /cvsroot/po4a/po4a/lib/Locale/Po4a/Xml.pm,v
retrieving revision 1.92
retrieving revision 1.93
diff -u -d -r1.92 -r1.93
--- Xml.pm	22 Feb 2009 10:10:42 -0000	1.92
+++ Xml.pm	22 Feb 2009 10:11:57 -0000	1.93
@@ -1356,7 +1356,7 @@
 						# Now translate this paragraph if needed.
 						# This will call pushline and append the
 						# translation to the current holder's translation.
-						$self->translate_paragraph($translate, @paragraph);
+						$self->translate_paragraph(@paragraph);
 						pop @path;
 
 						# Now that this holder is closed, we can remove
@@ -1444,7 +1444,7 @@
 	# Translate the string when needed
 	# This will either push the translation in the translated document or
 	# in the current holder translation.
-	$self->translate_paragraph($translate, @paragraph);
+	$self->translate_paragraph(@paragraph);
 
 	# Push the trailing blanks
 	if ($blank ne "") {
@@ -1457,10 +1457,9 @@
 # The $translate argument indicates if the strings must be translated or
 # just pushed
 sub translate_paragraph {
-# TODO: remove the translate parameter
-	my ($self, $translate) = (shift, shift);
+	my $self = shift;
 	my @paragraph = @_;
-	$translate = $self->get_translate_options($self->get_path);
+	my $translate = $self->get_translate_options($self->get_path);
 
 	while (    (scalar @paragraph)
 	       and ($paragraph[0] =~ m/^\s*\n/s)) {
@@ -1496,8 +1495,7 @@
 			# Thus do not try to match "include ".
 			if ($t =~ m/^#[ \t]*(if |endif|undef |include|else|ifdef |ifndef |define )/si) {
 				if (@paragraph) {
-					$self->translate_paragraph($translate,
-					                           @paragraph);
+					$self->translate_paragraph(@paragraph);
 					@paragraph = ();
 					$self->pushline("\n");
 				}




More information about the Po4a-commits mailing list