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.7 by elmex, Fri Apr 7 20:04:59 2006 UTC vs.
Revision 1.8 by root, Fri Apr 7 20:08:57 2006 UTC

1package Crossfire::Client::Widget; 1package Crossfire::Client::Widget;
2
2use strict; 3use strict;
3 4
4our $FOCUS; # the widget with current focus 5our $FOCUS; # the widget with current focus
5our %ACTIVE_WIDGETS; 6our %ACTIVE_WIDGETS;
6 7
59} 60}
60 61
61package Client::TextView; 62package Client::TextView;
62 63
63use strict; 64use strict;
65
64our @ISA = qw/Client::Widget/; 66our @ISA = qw/Client::Widget/;
65 67
66use SDL::OpenGL; 68use SDL::OpenGL;
67use SDL::OpenGL::Constants; 69use SDL::OpenGL::Constants;
68 70
90} 92}
91 93
92sub key_up { 94sub key_up {
93} 95}
94 96
95my $x;
96
97sub draw { 97sub draw {
98 glEnable GL_TEXTURE_2D; 98 glEnable GL_TEXTURE_2D;
99 glEnable GL_BLEND; 99 glEnable GL_BLEND;
100
101 glPushMatrix;
102 100
103 my $map = $::CONN->{map}; 101 my $map = $::CONN->{map};
104 102
105 for my $x (0 .. $::CONN->{mapw} - 1) { 103 for my $x (0 .. $::CONN->{mapw} - 1) {
106 for my $y (0 .. $::CONN->{maph} - 1) { 104 for my $y (0 .. $::CONN->{maph} - 1) {
124 glEnd; 122 glEnd;
125 } 123 }
126 } 124 }
127 } 125 }
128 126
129 glPopMatrix;
130
131 glDisable GL_TEXTURE_2D; 127 glDisable GL_TEXTURE_2D;
132 glDisable GL_BLEND; 128 glDisable GL_BLEND;
133} 129}
134 130
1351; 1311;

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines