ViewVC Help
View File | Revision Log | Show Annotations | Download File
/cvs/deliantra/server/ext/item-worldmap.ext
(Generate patch)

Comparing deliantra/server/ext/item-worldmap.ext (file contents):
Revision 1.9 by root, Mon Jul 23 23:38:17 2007 UTC vs.
Revision 1.10 by root, Mon Jul 23 23:46:03 2007 UTC

25 my $label = $ws->new (Label => 25 my $label = $ws->new (Label =>
26 text => $k, 26 text => $k,
27 fontsize => 0.2, 27 fontsize => 0.2,
28 ); 28 );
29 29
30 my $marker = cf::face::find "res/map-arrow.png";
31 $ws->{ns}->send_face ($marker);
32 $ws->{ns}->flush_fx;
33 $marker = $ws->new (Face => 30 my $marker = $ws->new (Face =>
34 size_w => undef, 31 size_w => undef,
35 size_h => undef, 32 size_h => undef,
36 face => $marker, 33 face => $ws->{ns}->find_face ("res/map-arrow.png"),
37 ); 34 );
38 my $children = [$label, $marker]; 35 my $children = [$label, $marker];
39 36
40 $ws->{canvas}->add (my $vbox = $ws->new (VBox => 37 $ws->{canvas}->add (my $vbox = $ws->new (VBox =>
41 children => $children, 38 children => $children,
79 $_[0]{visibility} = $_[1]; 76 $_[0]{visibility} = $_[1];
80 update_worldmap $_[0]{ws} if $_[1]; 77 update_worldmap $_[0]{ws} if $_[1];
81 }, 78 },
82 ); 79 );
83 80
84 my $face = cf::face::find "res/worldmap.jpg";
85 $ns->send_face ($face);
86 $ns->flush_fx;
87
88 $w->add (my $sw = $ws->{window} = $ws->new (ScrolledWindow => scroll_x => 1, scroll_y => 1)); 81 $w->add (my $sw = $ws->{window} = $ws->new (ScrolledWindow => scroll_x => 1, scroll_y => 1));
89 $sw->add (my $canvas = $ws->{canvas} = $ws->new (Canvas => expand => 1)); 82 $sw->add (my $canvas = $ws->{canvas} = $ws->new (Canvas => expand => 1));
90 83
91 $ws->{mapface} = $ws->new (Face => 84 $ws->{mapface} = $ws->new (Face =>
92 expand => 1, 85 expand => 1,
93 size_w => undef, 86 size_w => undef,
94 size_h => undef, 87 size_h => undef,
95 face => $face, 88 face => $ws->{ns}->find_face ("res/worldmap.jpg"),
96 ); 89 );
97 90
98 $ws->{canvas}->add ($ws->{mapface}); 91 $ws->{canvas}->add ($ws->{mapface});
99 92
100 $ws 93 $ws

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines