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.169 by elmex, Mon Apr 24 10:43:39 2006 UTC vs.
Revision 1.171 by root, Mon Apr 24 11:54:26 2006 UTC

246} 246}
247 247
248# return top left coordinates 248# return top left coordinates
249sub _topleft { 249sub _topleft {
250 my ($self, $x, $y) = @_; 250 my ($self, $x, $y) = @_;
251
252 $self->{parent}
253 or Carp::confess "no parent widget in _topleft\n";#d#
251 254
252 $self->{parent}->_topleft ($x + $self->{x}, $y + $self->{y}); 255 $self->{parent}->_topleft ($x + $self->{x}, $y + $self->{y});
253} 256}
254 257
255# translate global coordinates to local coordinate system 258# translate global coordinates to local coordinate system
1824 1827
1825sub new { 1828sub new {
1826 my ($class, %arg) = @_; 1829 my ($class, %arg) = @_;
1827 1830
1828 my $self = $class->SUPER::new ( 1831 my $self = $class->SUPER::new (
1829 tooltip => $arg{type}, 1832 tooltip => $arg{type},
1830 can_hover => 1, 1833 can_hover => 1,
1834 can_events => 1,
1831 %arg, 1835 %arg,
1832 ); 1836 );
1833 1837
1834 $self->add ($self->{value} = new CFClient::UI::Label valign => +1, align => 0, template => "999"); 1838 $self->add ($self->{value} = new CFClient::UI::Label valign => +1, align => 0, template => "999");
1835 $self->add ($self->{gauge} = new CFClient::UI::VGauge type => $self->{type}, expand => 1, can_hover => 1); 1839 $self->add ($self->{gauge} = new CFClient::UI::VGauge type => $self->{type}, expand => 1, can_hover => 1);

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines