1
0
Fork 0
mirror of https://github.com/eclipse-cdt/cdt synced 2025-07-16 13:35:22 +02:00

Bug 136206: Suppress Resumed events when processing solib events.

This commit is contained in:
Mikhail Khodjaiants 2006-04-12 19:06:40 +00:00
parent 2abef07854
commit 310afa2c6b
5 changed files with 32 additions and 2 deletions

View file

@ -1,3 +1,10 @@
2006-04-12 Mikhail Khodjaiants
Bug 136206: Suppress Resumed events when processing solib events.
* EventManager.java
* RxThread.java
* Command.java
* MIEvent.java
2006-04-12 Mikhail Khodjaiants
Bug 119740: allow to specify only a subset of shared objects that we want symbols to be loaded for.
Support for deferred breakpoints.

View file

@ -399,9 +399,10 @@ public class EventManager extends SessionObject implements ICDIEventManager, Obs
break;
case MIRunningEvent.RETURN:
lastUserCommand = factory.createMIExecReturn();
break;
break;
case MIRunningEvent.CONTINUE: {
MIExecContinue cont = factory.createMIExecContinue();
cont.setQuiet(true);
try {
miSession.postCommand(cont);
MIInfo info = cont.getMIInfo();
@ -462,6 +463,7 @@ public class EventManager extends SessionObject implements ICDIEventManager, Obs
if (miLevel >= 0) {
MIStackSelectFrame selectFrame = factory.createMIStackSelectFrame(miLevel);
MIExecFinish finish = factory.createMIExecFinish();
finish.setQuiet(true);
try {
miSession.postCommand(selectFrame);
miSession.postCommand(finish);
@ -473,6 +475,7 @@ public class EventManager extends SessionObject implements ICDIEventManager, Obs
// for example the StopEventLib was on a different thread
// redo the last command.
Command cmd = lastUserCommand;
cmd.setQuiet(true);
lastUserCommand = null;
try {
miSession.postCommand(cmd);
@ -483,6 +486,7 @@ public class EventManager extends SessionObject implements ICDIEventManager, Obs
return true;
} else if (lastUserCommand != null) {
Command cmd = lastUserCommand;
cmd.setQuiet(true);
lastUserCommand = null;
try {
miSession.postCommand(cmd);
@ -516,7 +520,7 @@ public class EventManager extends SessionObject implements ICDIEventManager, Obs
currentTarget.setSupended(false);
// Bailout early if we do not want to process any events.
if (!isAllowingProcessingEvents()) {
if (!isAllowingProcessingEvents() || !running.propagate()) {
return false;
}

View file

@ -201,6 +201,8 @@ public class RxThread extends Thread {
}
session.getMIInferior().setRunning();
MIEvent event = new MIRunningEvent(session, id, type);
if (cmd.isQuiet())
event.setPropagate(false);
list.add(event);
} else if ("exit".equals(state)) { //$NON-NLS-1$
// No need to do anything, terminate() will.

View file

@ -27,6 +27,7 @@ public abstract class Command
int token = 0;
MIOutput output;
boolean quiet = false;
/**
* A global counter for all command, the token
@ -104,4 +105,11 @@ public abstract class Command
throw new MIException(mesg, details);
}
public boolean isQuiet() {
return this.quiet;
}
public void setQuiet( boolean quiet ) {
this.quiet = quiet;
}
}

View file

@ -19,6 +19,7 @@ import org.eclipse.cdt.debug.mi.core.MISession;
public abstract class MIEvent extends EventObject {
int token;
boolean propagate = true;
public MIEvent(MISession session, int token) {
super(session);
@ -32,4 +33,12 @@ public abstract class MIEvent extends EventObject {
public MISession getMISession() {
return (MISession)getSource();
}
public boolean propagate() {
return propagate;
}
public void setPropagate( boolean propagate ) {
this.propagate = propagate;
}
}