author | sudonix <sudonix> | 2004-02-14 20:48:48 (UTC) |
---|---|---|
committer | sudonix <sudonix> | 2004-02-14 20:48:48 (UTC) |
commit | b922593f1261a972752c825ba4f6c158aa7cc720 (patch) (unidiff) | |
tree | 90ab16a6472d2f3e118d95def2f5decd46595578 | |
parent | 9a9c6a2c813347a2a1f83333314b2fd07f34828a (diff) | |
download | opie-b922593f1261a972752c825ba4f6c158aa7cc720.zip opie-b922593f1261a972752c825ba4f6c158aa7cc720.tar.gz opie-b922593f1261a972752c825ba4f6c158aa7cc720.tar.bz2 |
A small typo corrected(found while translating)
-rw-r--r-- | noncore/comm/keypebble/krfbdecoder.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/noncore/comm/keypebble/krfbdecoder.cpp b/noncore/comm/keypebble/krfbdecoder.cpp index dc90d9c..c43aed5 100644 --- a/noncore/comm/keypebble/krfbdecoder.cpp +++ b/noncore/comm/keypebble/krfbdecoder.cpp | |||
@@ -98,97 +98,97 @@ static struct { | |||
98 | { 0xffc8, Qt::Key_F11 }, | 98 | { 0xffc8, Qt::Key_F11 }, |
99 | { 0xffc9, Qt::Key_F12 }, | 99 | { 0xffc9, Qt::Key_F12 }, |
100 | { 0xffe1, Qt::Key_Shift }, | 100 | { 0xffe1, Qt::Key_Shift }, |
101 | { 0xffe2, Qt::Key_Shift }, | 101 | { 0xffe2, Qt::Key_Shift }, |
102 | { 0xffe3, Qt::Key_Control }, | 102 | { 0xffe3, Qt::Key_Control }, |
103 | { 0xffe4, Qt::Key_Control }, | 103 | { 0xffe4, Qt::Key_Control }, |
104 | { 0xffe7, Qt::Key_Meta }, | 104 | { 0xffe7, Qt::Key_Meta }, |
105 | { 0xffe8, Qt::Key_Meta }, | 105 | { 0xffe8, Qt::Key_Meta }, |
106 | { 0xffe9, Qt::Key_Alt }, | 106 | { 0xffe9, Qt::Key_Alt }, |
107 | { 0xffea, Qt::Key_Alt }, | 107 | { 0xffea, Qt::Key_Alt }, |
108 | { 0, 0 } | 108 | { 0, 0 } |
109 | }; | 109 | }; |
110 | 110 | ||
111 | 111 | ||
112 | KRFBDecoder::KRFBDecoder( KRFBConnection *con ) | 112 | KRFBDecoder::KRFBDecoder( KRFBConnection *con ) |
113 | : QObject( con, "RFB Decoder" ) | 113 | : QObject( con, "RFB Decoder" ) |
114 | { | 114 | { |
115 | assert( con ); | 115 | assert( con ); |
116 | assert( con->state() == KRFBConnection::Connected ); | 116 | assert( con->state() == KRFBConnection::Connected ); |
117 | 117 | ||
118 | this->con = con; | 118 | this->con = con; |
119 | this->buf = 0; | 119 | this->buf = 0; |
120 | this->info = 0; | 120 | this->info = 0; |
121 | this->format = 0; | 121 | this->format = 0; |
122 | this->buttonMask = 0; | 122 | this->buttonMask = 0; |
123 | currentState = Idle; | 123 | currentState = Idle; |
124 | } | 124 | } |
125 | 125 | ||
126 | KRFBDecoder::~KRFBDecoder() | 126 | KRFBDecoder::~KRFBDecoder() |
127 | { | 127 | { |
128 | if ( info ) | 128 | if ( info ) |
129 | delete info; | 129 | delete info; |
130 | if ( format ) | 130 | if ( format ) |
131 | delete format; | 131 | delete format; |
132 | } | 132 | } |
133 | 133 | ||
134 | void KRFBDecoder::start() | 134 | void KRFBDecoder::start() |
135 | { | 135 | { |
136 | sendClientInit(); | 136 | sendClientInit(); |
137 | } | 137 | } |
138 | 138 | ||
139 | void KRFBDecoder::sendClientInit() | 139 | void KRFBDecoder::sendClientInit() |
140 | { | 140 | { |
141 | con->write( &( con->options()->shared ), 1 ); | 141 | con->write( &( con->options()->shared ), 1 ); |
142 | 142 | ||
143 | // Wait for server init | 143 | // Wait for server init |
144 | qWarning( "Waiting for server init" ); | 144 | qWarning( "Waiting for server init" ); |
145 | 145 | ||
146 | static QString statusMsg = tr( "Waiting for server initialisation..." ); | 146 | static QString statusMsg = tr( "Waiting for server initialization..." ); |
147 | emit status( statusMsg ); | 147 | emit status( statusMsg ); |
148 | 148 | ||
149 | currentState = AwaitingServerInit; | 149 | currentState = AwaitingServerInit; |
150 | connect( con, SIGNAL( gotEnoughData() ), SLOT( gotServerInit() ) ); | 150 | connect( con, SIGNAL( gotEnoughData() ), SLOT( gotServerInit() ) ); |
151 | con->waitForData( ServerInitLength ); | 151 | con->waitForData( ServerInitLength ); |
152 | } | 152 | } |
153 | 153 | ||
154 | void KRFBDecoder::gotServerInit() | 154 | void KRFBDecoder::gotServerInit() |
155 | { | 155 | { |
156 | qWarning( "Got server init" ); | 156 | qWarning( "Got server init" ); |
157 | disconnect( con, SIGNAL( gotEnoughData() ), this, SLOT( gotServerInit() ) ); | 157 | disconnect( con, SIGNAL( gotEnoughData() ), this, SLOT( gotServerInit() ) ); |
158 | 158 | ||
159 | if ( info ) | 159 | if ( info ) |
160 | delete info; | 160 | delete info; |
161 | info = new KRFBServerInfo; | 161 | info = new KRFBServerInfo; |
162 | CHECK_PTR( info ); | 162 | CHECK_PTR( info ); |
163 | 163 | ||
164 | con->read( &(info->width), 2 ); | 164 | con->read( &(info->width), 2 ); |
165 | info->width = Swap16IfLE( info->width ); | 165 | info->width = Swap16IfLE( info->width ); |
166 | con->read( &info->height, 2 ); | 166 | con->read( &info->height, 2 ); |
167 | info->height = Swap16IfLE( info->height ); | 167 | info->height = Swap16IfLE( info->height ); |
168 | 168 | ||
169 | con->read( &(info->bpp), 1 ); | 169 | con->read( &(info->bpp), 1 ); |
170 | con->read( &(info->depth), 1 ); | 170 | con->read( &(info->depth), 1 ); |
171 | con->read( &(info->bigEndian), 1 ); | 171 | con->read( &(info->bigEndian), 1 ); |
172 | con->read( &(info->trueColor), 1 ); | 172 | con->read( &(info->trueColor), 1 ); |
173 | 173 | ||
174 | con->read( &(info->redMax), 2 ); | 174 | con->read( &(info->redMax), 2 ); |
175 | info->redMax = Swap16IfLE( info->redMax ); | 175 | info->redMax = Swap16IfLE( info->redMax ); |
176 | con->read( &(info->greenMax), 2 ); | 176 | con->read( &(info->greenMax), 2 ); |
177 | info->greenMax = Swap16IfLE( info->greenMax ); | 177 | info->greenMax = Swap16IfLE( info->greenMax ); |
178 | con->read( &(info->blueMax), 2 ); | 178 | con->read( &(info->blueMax), 2 ); |
179 | info->blueMax = Swap16IfLE( info->blueMax ); | 179 | info->blueMax = Swap16IfLE( info->blueMax ); |
180 | 180 | ||
181 | con->read( &(info->redShift), 1 ); | 181 | con->read( &(info->redShift), 1 ); |
182 | con->read( &(info->greenShift), 1 ); | 182 | con->read( &(info->greenShift), 1 ); |
183 | con->read( &(info->blueShift), 1 ); | 183 | con->read( &(info->blueShift), 1 ); |
184 | 184 | ||
185 | con->read( info->padding, 3 ); | 185 | con->read( info->padding, 3 ); |
186 | 186 | ||
187 | con->read( &(info->nameLength), 4 ); | 187 | con->read( &(info->nameLength), 4 ); |
188 | info->nameLength = Swap32IfLE( info->nameLength ); | 188 | info->nameLength = Swap32IfLE( info->nameLength ); |
189 | 189 | ||
190 | qWarning( "Width = %d, Height = %d", info->width, info->height ); | 190 | qWarning( "Width = %d, Height = %d", info->width, info->height ); |
191 | qWarning( "Bpp = %d, Depth = %d, Big = %d, True = %d", | 191 | qWarning( "Bpp = %d, Depth = %d, Big = %d, True = %d", |
192 | info->bpp, info->depth, info->bigEndian, info->trueColor ); | 192 | info->bpp, info->depth, info->bigEndian, info->trueColor ); |
193 | qWarning( "RedMax = %d, GreenMax = %d, BlueMax = %d", | 193 | qWarning( "RedMax = %d, GreenMax = %d, BlueMax = %d", |
194 | info->redMax, info->greenMax, info->blueMax ); | 194 | info->redMax, info->greenMax, info->blueMax ); |