templates/as3/org/rubyforge/dango/DangoClientFramework.as in dango_generator-0.3.5 vs templates/as3/org/rubyforge/dango/DangoClientFramework.as in dango_generator-0.3.6
- old
+ new
@@ -317,11 +317,12 @@
var crlf:String = "";
var temp_byta:ByteArray = new ByteArray;
socket.readBytes(receive_cache_byta, receive_cache_byta.length, socket.bytesAvailable); // データ読み込み
- while(true){
+// while(true){
+ for(var j:uint = 0; j < 5; j++){
// 長さ取得処理
if(receive_cache_do_phase == 0){
if(is_debug){ trace("DangoClientFramework:socket_read_push_cache:receive_cache_do_phase == 0:" + DangoUtil.now2str()); }
if(receive_cache_byta.length < 6){ break; } // 長さの読み込みが終わっていなければ
@@ -414,12 +415,13 @@
*/
public function recv_do_callback(evt:TimerEvent):void {
// if(is_debug){ trace("DangoClientFramework:recv_do_callback:" + DangoUtil.now2str()); }
// 前回から時間がかかりすぎている(処理落ちしかけている場合は)スキップ
- var start_date:Date = new Date();
- if(recv_do_last_date.time > start_date.time - (Number(recv_do_timer_msec) * 1.4)){
+// var start_date:Date = new Date();
+// if(recv_do_last_date.time > start_date.time - (Number(recv_do_timer_msec) * 1.4)){
+
if(recv_wait_do_cache.length > 0){
var recv_arr:Array = recv_wait_do_cache.shift();
var notice_name:String = recv_arr[0];
var recv_data:Object = recv_arr[1];
server_time = recv_arr[2];
@@ -434,12 +436,12 @@
this.dispatchEvent(new DangoReceiveEvent("dango__before_filter", recv_data, count_no));
this.dispatchEvent(new DangoReceiveEvent("dango_" + notice_name, recv_data, count_no));
this.dispatchEvent(new DangoReceiveEvent("dango__after_filter", recv_data, count_no));
}
}
- }
+// }
- recv_do_last_date = new Date(); // 前回の実行の終了時間の保持
+// recv_do_last_date = new Date(); // 前回の実行の終了時間の保持
}
/**
* polling_callback