aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--pd/extra/expr~/makefile4
-rw-r--r--pd/extra/makefile4
-rw-r--r--pd/portaudio/pa_win_wdmks/pa_win_wdmks.c2
-rw-r--r--pd/portaudio/pablio/ringbuffer.c2
-rw-r--r--pd/portaudio/pablio/ringbuffer.h2
-rw-r--r--pd/portmidi/pm_mac/pmmacosxcm.c2
-rw-r--r--pd/src/g_editor.c10
-rw-r--r--pd/src/g_text.c6
-rw-r--r--pd/src/m_binbuf.c2
-rw-r--r--pd/src/m_pd.h2
-rw-r--r--pd/src/notes.txt4
-rw-r--r--pd/src/s_audio.c19
-rw-r--r--pd/src/s_audio_pablio.c3
-rw-r--r--pd/src/s_main.c5
-rw-r--r--pd/src/s_midi.c4
-rw-r--r--pd/src/u_main.tk43
16 files changed, 67 insertions, 47 deletions
diff --git a/pd/extra/expr~/makefile b/pd/extra/expr~/makefile
index 28329408..7d033b7c 100644
--- a/pd/extra/expr~/makefile
+++ b/pd/extra/expr~/makefile
@@ -77,7 +77,7 @@ SGIINCLUDE = -I/usr/people/msp/pd/pd/src
LINUXOBJ = vexp.pd_linux_o vexp_fun.pd_linux_o vexp_if.pd_linux_o
.SUFFIXES: .pd_linux_o
-LINUXCFLAGS = -DPD -O2 -funroll-loops -fomit-frame-pointer -fPIC \
+LINUXCFLAGS = -DPD -O2 -funroll-loops -fomit-frame-pointer -fPIC -m32 \
-Wall -W -Wshadow -Wstrict-prototypes \
-Wno-unused -Wno-parentheses -Wno-switch
@@ -87,7 +87,7 @@ LINUXINCLUDE = -I../../src
$(CC) -g $(LINUXCFLAGS) $(LINUXINCLUDE) -o $*.pd_linux_o -c $*.c
expr.pd_linux: $(LINUXOBJ)
- ld -export_dynamic -shared -o expr.pd_linux $(LINUXOBJ) -lc -lm
+ $(CC) -m32 -export_dynamic -shared -o expr.pd_linux $(LINUXOBJ) -lc -lm
strip --strip-unneeded expr.pd_linux
expr~.pd_linux: expr.pd_linux
diff --git a/pd/extra/makefile b/pd/extra/makefile
index c2f573a0..a328d919 100644
--- a/pd/extra/makefile
+++ b/pd/extra/makefile
@@ -57,7 +57,7 @@ pd_linux: $(NAME).pd_linux
.SUFFIXES: .pd_linux
-LINUXCFLAGS = -DPD -O2 -funroll-loops -fomit-frame-pointer -fPIC \
+LINUXCFLAGS = -DPD -O2 -funroll-loops -fomit-frame-pointer -fPIC -m32 \
-Wall -W -Wshadow -Wstrict-prototypes \
-Wno-unused -Wno-parentheses -Wno-switch $(CFLAGS)
@@ -65,7 +65,7 @@ LINUXINCLUDE = -I../../src
.c.pd_linux:
$(CC) $(LINUXCFLAGS) $(LINUXINCLUDE) -o $*.o -c $*.c
- ld -export_dynamic -shared -o $*.pd_linux $*.o -lc -lm
+ $(CC) -m32 -export_dynamic -shared -o $*.pd_linux $*.o -lc -lm
strip --strip-unneeded $*.pd_linux
rm -f $*.o
diff --git a/pd/portaudio/pa_win_wdmks/pa_win_wdmks.c b/pd/portaudio/pa_win_wdmks/pa_win_wdmks.c
index e4344f7f..22e67a71 100644
--- a/pd/portaudio/pa_win_wdmks/pa_win_wdmks.c
+++ b/pd/portaudio/pa_win_wdmks/pa_win_wdmks.c
@@ -1,5 +1,5 @@
/*
- * $Id: pa_win_wdmks.c,v 1.13 2006-09-19 22:30:32 millerpuckette Exp $
+ * $Id: pa_win_wdmks.c,v 1.14 2006-10-04 19:35:06 millerpuckette Exp $
* PortAudio Windows WDM-KS interface
*
* Author: Andrew Baldwin
diff --git a/pd/portaudio/pablio/ringbuffer.c b/pd/portaudio/pablio/ringbuffer.c
index d954eb69..70fa5e32 100644
--- a/pd/portaudio/pablio/ringbuffer.c
+++ b/pd/portaudio/pablio/ringbuffer.c
@@ -1,5 +1,5 @@
/*
- * $Id: ringbuffer.c,v 1.12 2006-09-19 22:30:33 millerpuckette Exp $
+ * $Id: ringbuffer.c,v 1.13 2006-10-04 19:35:06 millerpuckette Exp $
* ringbuffer.c
* Ring Buffer utility..
*
diff --git a/pd/portaudio/pablio/ringbuffer.h b/pd/portaudio/pablio/ringbuffer.h
index 08cf1818..012e6856 100644
--- a/pd/portaudio/pablio/ringbuffer.h
+++ b/pd/portaudio/pablio/ringbuffer.h
@@ -6,7 +6,7 @@ extern "C"
#endif /* __cplusplus */
/*
- * $Id: ringbuffer.h,v 1.13 2006-09-19 22:30:33 millerpuckette Exp $
+ * $Id: ringbuffer.h,v 1.14 2006-10-04 19:35:06 millerpuckette Exp $
* ringbuffer.h
* Ring Buffer utility..
*
diff --git a/pd/portmidi/pm_mac/pmmacosxcm.c b/pd/portmidi/pm_mac/pmmacosxcm.c
index ccb48598..c1e3d371 100644
--- a/pd/portmidi/pm_mac/pmmacosxcm.c
+++ b/pd/portmidi/pm_mac/pmmacosxcm.c
@@ -5,7 +5,7 @@
* and subsequent work by Andrew Zeldis and Zico Kolter
* and Roger B. Dannenberg
*
- * $Id: pmmacosxcm.c,v 1.13 2006-09-19 22:30:33 millerpuckette Exp $
+ * $Id: pmmacosxcm.c,v 1.14 2006-10-04 19:35:06 millerpuckette Exp $
*/
/* Notes:
diff --git a/pd/src/g_editor.c b/pd/src/g_editor.c
index 8b146fc1..cbc9e1d7 100644
--- a/pd/src/g_editor.c
+++ b/pd/src/g_editor.c
@@ -1027,12 +1027,6 @@ static void canvas_done_popup(t_canvas *x, float which, float xpos, float ypos)
#define ALTMOD 4
#define RIGHTCLICK 8
-/* on one-button-mouse machines, you can use double click to
- mean right click (which gets the popup menu.) Do this for Mac. */
-#ifdef __APPLE__
-#define SIMULATERIGHTCLICK
-#endif
-
static double canvas_upclicktime;
static int canvas_upx, canvas_upy;
#define DCLICKINTERVAL 0.25
@@ -1067,11 +1061,7 @@ void canvas_doclick(t_canvas *x, int xpos, int ypos, int which,
if (doit && !runmode && xpos == canvas_upx && ypos == canvas_upy &&
sys_getrealtime() - canvas_upclicktime < DCLICKINTERVAL)
-#ifdef SIMULATERIGHTCLICK
- rightclick = 1;
-#else
doublemod = 1;
-#endif
x->gl_editor->e_lastmoved = 0;
if (doit)
{
diff --git a/pd/src/g_text.c b/pd/src/g_text.c
index a146ae91..fa28f70e 100644
--- a/pd/src/g_text.c
+++ b/pd/src/g_text.c
@@ -359,7 +359,11 @@ static void message_adddollar(t_message *x, t_floatarg f)
static void message_adddollsym(t_message *x, t_symbol *s)
{
t_atom a;
- SETDOLLSYM(&a, s);
+ char buf[MAXPDSTRING];
+ buf[0] = '$';
+ strncpy(buf+1, s->s_name, MAXPDSTRING-2);
+ buf[MAXPDSTRING-1] = 0;
+ SETDOLLSYM(&a, gensym(buf));
binbuf_add(x->m_text.te_binbuf, 1, &a);
glist_retext(x->m_glist, &x->m_text);
}
diff --git a/pd/src/m_binbuf.c b/pd/src/m_binbuf.c
index 3d417560..e12bad5f 100644
--- a/pd/src/m_binbuf.c
+++ b/pd/src/m_binbuf.c
@@ -359,7 +359,7 @@ void binbuf_restore(t_binbuf *x, int argc, t_atom *argv)
if (!strcmp(str, ";")) SETSEMI(ap);
else if (!strcmp(str, ",")) SETCOMMA(ap);
else if ((str2 = strchr(str, '$')) && str2[1] >= '0'
- & str2[1] <= '9')
+ && str2[1] <= '9')
{
int dollsym = 0;
if (*str != '$')
diff --git a/pd/src/m_pd.h b/pd/src/m_pd.h
index e76b541e..d733a6cd 100644
--- a/pd/src/m_pd.h
+++ b/pd/src/m_pd.h
@@ -11,7 +11,7 @@ extern "C" {
#define PD_MAJOR_VERSION 0
#define PD_MINOR_VERSION 40
#define PD_BUGFIX_VERSION 0
-#define PD_TEST_VERSION "test08"
+#define PD_TEST_VERSION ""
/* old name for "MSW" flag -- we have to take it for the sake of many old
"nmakefiles" for externs, which will define NT and not MSW */
diff --git a/pd/src/notes.txt b/pd/src/notes.txt
index bdf362bb..363741f9 100644
--- a/pd/src/notes.txt
+++ b/pd/src/notes.txt
@@ -1,5 +1,9 @@
---------------- dolist --------------------
check bug reports on sourceforge
+double-click fix on mac?
+http://sourceforge.net/tracker/index.php?
+func=detail&aid=1564617&group_id=55736&atid=478072
+
PC device counting problem (first device invoked by -audiodev 0)
test:
diff --git a/pd/src/s_audio.c b/pd/src/s_audio.c
index 623b073b..f33a135b 100644
--- a/pd/src/s_audio.c
+++ b/pd/src/s_audio.c
@@ -607,11 +607,6 @@ static void audio_getdevs(char *indevlist, int *nindevs,
}
}
-#ifdef MSW
-#define DEVONSET 0 /* microsoft device list starts at 0 (the "mapper"). */
-#else /* (see also MSW ifdef in sys_parsedevlist(), s_main.c) */
-#define DEVONSET 1 /* To agree with command line flags, normally start at 1 */
-#endif
static void sys_listaudiodevs(void )
{
@@ -625,17 +620,23 @@ static void sys_listaudiodevs(void )
post("no audio input devices found");
else
{
- post("input devices:");
+ /* To agree with command line flags, normally start at 1 */
+ /* But microsoft "MMIO" device list starts at 0 (the "mapper"). */
+ /* (see also sys_mmio variable in s_main.c) */
+
+ post("audio input devices:");
for (i = 0; i < nindevs; i++)
- post("%d. %s", i + DEVONSET, indevlist + i * DEVDESCSIZE);
+ post("%d. %s", i + (sys_audioapi != API_MMIO),
+ indevlist + i * DEVDESCSIZE);
}
if (!noutdevs)
post("no audio output devices found");
else
{
- post("output devices:");
+ post("audio output devices:");
for (i = 0; i < noutdevs; i++)
- post("%d. %s", i + DEVONSET, outdevlist + i * DEVDESCSIZE);
+ post("%d. %s", i + (sys_audioapi != API_MMIO),
+ outdevlist + i * DEVDESCSIZE);
}
post("API number %d\n", sys_audioapi);
}
diff --git a/pd/src/s_audio_pablio.c b/pd/src/s_audio_pablio.c
index a7d1a4fe..5827533f 100644
--- a/pd/src/s_audio_pablio.c
+++ b/pd/src/s_audio_pablio.c
@@ -222,10 +222,11 @@ PaError OpenAudioStream( PABLIO_Stream **rwblPtr, double sampleRate,
long doWrite = 0;
PaError err;
PABLIO_Stream *aStream;
- long minNumBuffers;
long numFrames;
#ifdef PA19
PaStreamParameters instreamparams, outstreamparams; /* MSP */
+#else
+ long minNumBuffers;
#endif
/* fprintf(stderr,
diff --git a/pd/src/s_main.c b/pd/src/s_main.c
index dd4e7cb7..a7156c20 100644
--- a/pd/src/s_main.c
+++ b/pd/src/s_main.c
@@ -61,6 +61,7 @@ int sys_midioutdevlist[MAXMIDIOUTDEV] = {1};
char sys_font[100] = "courier"; /* tb: font name */
static int sys_main_srate;
static int sys_main_advance;
+static int sys_listplease;
int sys_externalschedlib;
char sys_externalschedlibname[MAXPDSTRING];
@@ -800,7 +801,7 @@ int sys_argparse(int argc, char **argv)
}
else if (!strcmp(*argv, "-listdev"))
{
- sys_listdevs();
+ sys_listplease = 1;
argc--; argv++;
}
else if (!strcmp(*argv, "-schedlib"))
@@ -920,6 +921,8 @@ static void sys_afterargparse(void)
sys_midiindevlist[i]--;
for (i = 0; i < sys_nmidiout; i++)
sys_midioutdevlist[i]--;
+ if (sys_listplease)
+ sys_listdevs();
/* get the current audio parameters. These are set
by the preferences mechanism (sys_loadpreferences()) or
diff --git a/pd/src/s_midi.c b/pd/src/s_midi.c
index 12c31258..508b3ff2 100644
--- a/pd/src/s_midi.c
+++ b/pd/src/s_midi.c
@@ -576,7 +576,7 @@ void sys_listmididevs(void )
post("no midi input devices found");
else
{
- post("input devices:");
+ post("MIDI input devices:");
for (i = 0; i < nindevs; i++)
post("%d. %s", i+1, indevlist + i * DEVDESCSIZE);
}
@@ -584,7 +584,7 @@ void sys_listmididevs(void )
post("no midi output devices found");
else
{
- post("output devices:");
+ post("MIDI output devices:");
for (i = 0; i < noutdevs; i++)
post("%d. %s", i+DEVONSET, outdevlist + i * DEVDESCSIZE);
}
diff --git a/pd/src/u_main.tk b/pd/src/u_main.tk
index e8a57f10..97fc77b4 100644
--- a/pd/src/u_main.tk
+++ b/pd/src/u_main.tk
@@ -432,15 +432,6 @@ proc menu_doc_browser {dir} {
}
proc doc_make_listbox {base dir count} {
- global pd_guidir
- if {![file isdirectory $dir]} {
- regsub -- $pd_guidir [file dirname $dir] "" subdir
- set file [file tail $dir]
- if { [catch {menu_doc_open $subdir $file} fid] } {
- puts stderr "Could not open $pd_guidir/$subdir/$file\n"
- }
- return;
- }
# check for [file readable]?
if { [info tclversion] >= 8.5 } {
# requires Tcl 8.5 but probably deals with special chars better
@@ -461,14 +452,36 @@ proc doc_make_listbox {base dir count} {
[lsort -dictionary [glob -directory $dir -nocomplain -types {f} -- *]]] {
$current_listbox insert end "[file tail $item][expr {[file isdirectory $item] ? {/} : {}}]"
}
- bind $current_listbox <Button-1> [list doc_navigate $dir [incr count] %W %x %y]
+ bind $current_listbox <Button-1> [list doc_navigate $dir $count %W %x %y]
+ bind $current_listbox <Double-Button-1> [list doc_double_button $dir $count %W %x %y]
}
proc doc_navigate {dir count width x y} {
- if {[set subdir [$width get [$width index "@$x,$y"]]] eq {}} {
+ if {[set newdir [$width get [$width index "@$x,$y"]]] eq {}} {
+ return
+ }
+ set dir_to_open [file join $dir $newdir]
+ if {[file isdirectory $dir_to_open]} {
+ doc_make_listbox [winfo parent $width] $dir_to_open [incr count]
+ }
+}
+
+proc doc_double_button {dir count width x y} {
+ global pd_guidir
+ if {[set newdir [$width get [$width index "@$x,$y"]]] eq {}} {
return
}
- doc_make_listbox [winfo parent $width] [file join $dir $subdir] $count
+ set dir_to_open [file join $dir $newdir]
+ if {[file isdirectory $dir_to_open]} {
+ doc_navigate $dir $count $width $x $y
+ } else {
+ regsub -- $pd_guidir [file dirname $dir_to_open] "" subdir
+ set file [file tail $dir_to_open]
+ if { [catch {menu_doc_open $subdir $file} fid] } {
+ puts stderr "Could not open $pd_guidir/$subdir/$file\n"
+ }
+ return;
+ }
}
############# routine to add media, help, and apple menu items ###############
@@ -3413,7 +3426,11 @@ proc pdtk_openpanel {target localdir} {
}
proc pdtk_savepanel {target localdir} {
- set filename [tk_getSaveFile -initialdir $localdir]
+ if {$localdir == ""} {
+ set filename [tk_getSaveFile]
+ } else {
+ set filename [tk_getSaveFile -initialdir $localdir]
+ }
if {$filename != ""} {
pd [concat $target callback [pdtk_enquote $filename] \;]
}