-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 | |||
@@ -122,49 +122,49 @@ KRFBDecoder::KRFBDecoder( KRFBConnection *con ) | |||
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 ); |