... Reopens minor bug 543 as a won't-fix.
Bring back the shell script as a way to change environment for Audacity before
it starts.
Perhaps this fixes Bug 1703 too: double-click on .aup before Audacity starts
brings up an empty window.
... That is, put a little shell script in the application bundle, and invoke
it (in Release, though not Debug where it interferes with Xcode debugging)
See commit 07661c186f
The shell nulls the environment variable DYLD_LIBRARY_PATH and then executes
the main program.
This is needed because changes to DYLD_LIBRARY_PATH during the main program's
run fail to affect the loading of dynamic libraries afterward.
We need null in DYLD_LIBRARY_PATH to make absolute paths to libraries take
priority.
More info:
Documentation of workings of the macOS dynamic loader
https://developer.apple.com/library/content/documentation/DeveloperTools/Conceptual/DynamicLibraries/100-Articles/DynamicLibraryUsageGuidelines.html
The same problem and solution is discussed here
https://stackoverflow.com/questions/6713692/problems-with-using-setenv-and-then-making-the-dlopen-call
It is claimed there that Firefox did the same trick with a shell, which I do
not observe in my version, but GIMP 2.8.16 does this, as I can see by examining
package contents
Also note the mention in this commit's comments (where the script was removed
because bug543's fix left it unused), that the script also used to
interfere with signing. I hope that there will be a way around that.
98186b9317
This at once reverts fixes for bugs 543 and 290;
290 being a problem loading libraries,
543 being a minor problem with the fix for 290, resulting in a rewrite of the
fix, but this rewrite having bad consequences, as in bugs 1567 and 1703.
See discussion in bug 1702 for the detailed history
See also commits
a05d039055 (fork and crash)
36361a6b86 (introduced execve)
... This conservative fix depends on where you put the executable bundle.
Assuing the executable is in /Applications, and the other Audacity version
(past or future) is there too (either bundled as for 2.1.3 and later, or
in a folder as for 2.1.2 and previous):
The .ny files that are part of the other version's shipment are ignored, and
therefore the Effects menu avoids duplicates.
But the .cfg file is not rewritten to eliminate them, in case you want to
switch back to the other version. If that other version is 2.1.3 or earlier,
sorry but you will see duplicates.
Fix off by one error in size.
Git-bisect indicated a problem (on Mac only) caused by a change in an image file.
It's possible that this is an error in code that we have 'got away with' until now.
We always have an extra zero on the end of the image data and included it in the count of the
size of stream to unpack. For a particular image this may have triggered a memory corruption
problem.
Works by using the newer and better logic of ToolManager for remembering which
window to focus.
It seems, at least on Windows, that when the toolbar with the focused control
is docked after the end of a docking (of itself or another bar), then focus
remains.
If the bar with the focus is undocked and another bar docks or undocks, focus
is still lost.
I think the colours got faded because of colour blending when working with the images,
but I am not 100% sure. Colour blending should be off when doing such work. I recaptured
the unfaded colours from an older png.
The other themes seemed to have OK (unfaded) colours.
... Only the case that you click the grabber and release, or you drag the
toolbar ending in a docked position.
Doesn't work yet when drag ends un-docked.
Necessitated by MIDI support, as many people's local portaudio libs will not be patched.
This also solves some issues with building with lv2 and ffmpeg on some Ubuntu systems.
... I can't reproduce the symptoms on my Mac, but the stack trace supplied by
Gale shows an infinite recursion overflowing the stack.
I see that at commit d1f66d768f "Updates for wx3"
by Leland, he saw the need to set a guard against infinite recursion in another
window resizing callback. He tested that guard, but did not set it, in two
other places. I speculate that the cycle can be entered from those other
places, bypassing where the guard was set. So I set the guard in more places.