summaryrefslogtreecommitdiffstats
path: root/perl-install
diff options
context:
space:
mode:
authorThierry Vignaud <tvignaud@mandriva.org>2004-03-11 11:24:25 +0000
committerThierry Vignaud <tvignaud@mandriva.org>2004-03-11 11:24:25 +0000
commitb7402b8da1aee6fe2434d92de169e256517cb627 (patch)
tree6fa8cc571b1a06b8cf2b372ea9eca63220900b8b /perl-install
parent964bc57b0e1eb14ff400c9ec59fd6b9bda674268 (diff)
downloaddrakx-b7402b8da1aee6fe2434d92de169e256517cb627.tar
drakx-b7402b8da1aee6fe2434d92de169e256517cb627.tar.gz
drakx-b7402b8da1aee6fe2434d92de169e256517cb627.tar.bz2
drakx-b7402b8da1aee6fe2434d92de169e256517cb627.tar.xz
drakx-b7402b8da1aee6fe2434d92de169e256517cb627.zip
(text_append) fix second run (on next filling, we shall not create
tags with name of existing ones)
Diffstat (limited to 'perl-install')
-rwxr-xr-xperl-install/standalone/logdrake7
1 files changed, 4 insertions, 3 deletions
diff --git a/perl-install/standalone/logdrake b/perl-install/standalone/logdrake
index 0d31b2345..d2db74eee 100755
--- a/perl-install/standalone/logdrake
+++ b/perl-install/standalone/logdrake
@@ -292,7 +292,8 @@ sub parse_file {
sub text_append {
my ($textview, $t, %opts) = @_;
my $buffer = $textview->get_buffer;
- my %gtk_tags;
+ $buffer->{tags} ||= {};
+ my $gtk_tags = $buffer->{tags};
if (ref($t) eq 'ARRAY') {
foreach my $token (@$t) {
my $iter1 = $buffer->get_end_iter;
@@ -302,8 +303,8 @@ sub text_append {
}
if ($token->[1]) {
my $tag = $token->[1];
- $gtk_tags{$tag} ||= $buffer->create_tag($tag, %{$tags{$token->[1]}});
- $buffer->insert_with_tags($iter1, $token->[0], $gtk_tags{$tag});
+ $gtk_tags->{$tag} ||= $buffer->create_tag($tag, %{$tags{$token->[1]}});
+ $buffer->insert_with_tags($iter1, $token->[0], $gtk_tags->{$tag});
} else {
$buffer->insert($iter1, $token->[0]);
}