Actually flush messages before terminating a plugin (upon
the shutdown message) and flush messages in the file- and
dirpicker before opening the blocking dialog. Flush debug
messages too (deeper into the code, just prior to the actual
blocking call).
Also, fix the context folder map to be a thread-safe
singleton and *attempt* to add support for default folders
to windows and Mac. The latter might even not compile yet
and definitely have to be tested (and fixed):
Opening a DirPicker in preferences --> Network and Set
the directory location of the cache. It should open a
Dialog window where you are already in the folder that
is the current cache directory setting (you can click
Cancel after verifying that this worked).
And, start to upload an image, select a file is some
directory (other than what it starts in). You can omit
the actual upload by clicking cancel in the preview.
Then upload again and now it should start in the same
folder as that you were just in. Possibly you need to
first open a file picker elsewhere with a different context
though, or windows might choose to open in the last
folder anyway while the code doesn't really work. Uploading
a sound before the second texture upload should do the
trick.
Resolved Conflicts:
indra/newview/llviewermedia.cpp
indra/plugins/base_media/CMakeLists.txt
Trivial fix for indra/newview/llviewermedia.cpp.
Moved 'prepare' dependency from base_media to
base_basic because media already depends on basic.
Added support for plugin debug messages and better error reporting
when something goes wrong during start up of SLPlugin.
Also added more debug output regarding general plugin messages
as well as debug output related to AIFilePicker.
Add back fixes that were in Singularity (in indra/media_plugins) but not
in imprudence.
Also:
Add "shutdown" plugin message and terminate file picker plugins cleanly.
The DSO (libbasic_plugin_filepicker.so) now tells the child process /
plugin loader (SLPlugin) to terminate (using the 'shutdown' message),
and AIFilePicker::finish_impl destroys the plugin object on the viewer
side when it's ... finished thus.
Also added a large comment that gives an overview of all classes
involved on the viewer side.
Additional fixes for filepicker.
Plugin refactor bug fix: mDeleteMe was uninitialized in AIPluginFilePicker.
This commit deletes all indra/media_plugins and copied one-on-one
the indra/plugins directory from my (imprudence) statemachine branch
(which contains the AIFilePicker patch).
git shows this as a lot of 'renamed' files because originally it
was a rename. However, there are a lot of changes as well: it's both
an upgrade to a newer plugin system (changes by LL) as well as an
upgrade to my refactored plugin system with a file picker as plugin.
Since this commit is a one-on-one copy, it disregards any changes
that were in Singularity and not in imprudence in indra/media_plugins
however. I will add those back in the next commit.