Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feature Request: API for adding before/after blocks #4

Open
LinqLover opened this issue Sep 10, 2020 · 2 comments
Open

Feature Request: API for adding before/after blocks #4

LinqLover opened this issue Sep 10, 2020 · 2 comments

Comments

@LinqLover
Copy link
Contributor

Something like this:

MessageSendRecorder new
	watchPackageNamed: #Morphic;
	setMessageSend: [m fullBounds];
	setBefore: {} after: {[:record :rcvr | record halt extent: b extent]};
	recordAllObjects;
	browse

is not going to work as one might expect at the moment. MSR is lacking some protocol such as #addBefore: aBlock and #addAfter: aBlock. This would also be more convenient if you do not want to set both blocks at once.

@marceltaeumel
Copy link
Contributor

The example you provided does work, right? It uses #setBefore:after:. Maybe I don't understand your description correctly.

@LinqLover
Copy link
Contributor Author

Sorry for the bad description. #setBefore:after: removes any previously added blocks. The given example overrides all existing blocks in #setRecordAllObjects. I am seeking for a protocol that allows me to sequentially add new blocks to the recorder without removing existing ones.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants