ViewVC Help
View File | Revision Log | Show Annotations | Download File
/cvs/deliantra/Deliantra-Client/DC/UI.pm
(Generate patch)

Comparing deliantra/Deliantra-Client/DC/UI.pm (file contents):
Revision 1.141 by root, Thu Apr 20 07:12:57 2006 UTC vs.
Revision 1.143 by root, Thu Apr 20 21:28:51 2006 UTC

1502} 1502}
1503 1503
1504sub size_request { 1504sub size_request {
1505 my ($self) = @_; 1505 my ($self) = @_;
1506 1506
1507 my $tex = $tex{$self->{type}}[0]; 1507 #my $tex = $tex{$self->{type}}[0];
1508
1509 @$tex{qw(w h)} 1508 #@$tex{qw(w h)}
1509 (0, 0)
1510} 1510}
1511 1511
1512sub set_max { 1512sub set_max {
1513 my ($self, $max) = @_; 1513 my ($self, $max) = @_;
1514 1514
1531 my ($self) = @_; 1531 my ($self) = @_;
1532 1532
1533 my $tex = $tex{$self->{type}}; 1533 my $tex = $tex{$self->{type}};
1534 1534
1535 my ($w, $h) = ($self->{w}, $self->{h}); 1535 my ($w, $h) = ($self->{w}, $self->{h});
1536
1537 if ($self->{vertical}) {
1538 glRotate 90, 0, 0, 1;
1539 glTranslate 0, -$self->{w}, 0;
1540
1541 ($w, $h) = ($h, $w);
1542 }
1536 1543
1537 my $ycut = $self->{val} / ($self->{max_val} || 1); 1544 my $ycut = $self->{val} / ($self->{max_val} || 1);
1538 $ycut = 1 if $self->{val} > $self->{max_val}; 1545 $ycut = 1 if $self->{val} > $self->{max_val};
1539 1546
1540 my $t1 = $tex->[0]; 1547 my $t1 = $tex->[0];

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines