Mercurial > hg > RemoteEditor > REPSessionManager
comparison rep/handler/Editor.java @ 451:fa7d9ec2008e
too much blocking
author | one |
---|---|
date | Thu, 23 Sep 2010 19:51:19 +0900 |
parents | 21cb16b7f3df |
children | d0d2449000f5 |
comparison
equal
deleted
inserted
replaced
450:21cb16b7f3df | 451:fa7d9ec2008e |
---|---|
244 } | 244 } |
245 return true; | 245 return true; |
246 } | 246 } |
247 | 247 |
248 private void startMerge(REPCommand command) { | 248 private void startMerge(REPCommand command) { |
249 ServerMainLoop.logger.writeLog("Editor"+eid+": startMerge "+command); | |
249 preMergeCommand = new REPCommand(command); | 250 preMergeCommand = new REPCommand(command); |
250 // merge は必須だが、EditorのCommand実装をテストするには邪魔なので、off に出来るようにする。 | 251 // merge は必須だが、EditorのCommand実装をテストするには邪魔なので、off に出来るようにする。 |
251 if (noMergeMode) { | 252 if (noMergeMode) { |
252 checkQuit(); | 253 checkQuit(); |
253 endMerge(); | 254 endMerge(); |
406 * write command to the editor | 407 * write command to the editor |
407 * called from another Editor instance such as next.send(command) | 408 * called from another Editor instance such as next.send(command) |
408 */ | 409 */ |
409 @Override | 410 @Override |
410 public void write(REPCommand command) { | 411 public void write(REPCommand command) { |
411 if ( !waitingRequired(command,channel)) { | 412 if (merging) { |
413 addWaitingCommand(new PacketSet(this, new REPCommand(command))); | |
414 return; | |
415 } | |
416 if (!waitingRequired(command,channel)) { | |
412 if (isMergeCommand(command)) { | 417 if (isMergeCommand(command)) { |
413 merging = true; | 418 merging = true; |
414 } | 419 } |
415 super.write(command); | 420 super.write(command); |
416 } | 421 } |