Skip to content

Instantly share code, notes, and snippets.

set debugfd [open "debug.txt" w]
rename proc _proc
_proc proc {name arglist body} {
uplevel 1 [list _proc $name $arglist $body]
uplevel 1 [list trace add execution $name enterstep [list ::proc_start $name]]
}
_proc proc_start {name command op} {
global debugfd
puts $debugfd "$name >> $command"
@dscho
dscho / Recorder_Likes_DialogListeners.java
Created May 8, 2015 08:01
A simple test for the claim that `Plugin`s with `DialogListener`s are not macro-recordable.
import ij.IJ;
import ij.gui.DialogListener;
import ij.gui.GenericDialog;
import ij.plugin.PlugIn;
import java.awt.AWTEvent;
/**
* A simple test for the claim that {@link Plugin}s with a
* {@link DialogListener} are not macro-recordable.
@dscho
dscho / ao_coreaudio.c.patch
Created February 25, 2014 15:07
Patch for MPlayer's C99 for loops declaring variables
diff --git a/libao2/ao_coreaudio.c b/libao2/ao_coreaudio.c
index 34374f4..ce587db 100644
--- a/libao2/ao_coreaudio.c
+++ b/libao2/ao_coreaudio.c
@@ -368,7 +368,7 @@ static void print_help(void)
{
OSStatus err;
UInt32 i_param_size;
- int num_devices;
+ int num_devices, i;