Merge branch 'master' into careminster

Conflicts:
	OpenSim/Region/Application/OpenSimBase.cs
	OpenSim/Region/ClientStack/Linden/Caps/NewFileAgentInventoryVariablePriceModule.cs
	OpenSim/Region/CoreModules/World/Warp3DMap/Warp3DImageModule.cs
	OpenSim/Region/Framework/ModuleLoader.cs
	OpenSim/Region/Framework/Scenes/SceneManager.cs
This commit is contained in:
Melanie
2012-11-12 23:27:47 +00:00
42 changed files with 85 additions and 572 deletions

View File

@@ -757,33 +757,13 @@ namespace OpenSim
switch (cmdparams[0].ToLower())
{
case "list":
foreach (IRegionModule irm in m_moduleLoader.GetLoadedSharedModules)
{
MainConsole.Instance.Output(String.Format("Shared region module: {0}", irm.Name));
}
//TODO: Convert to new region modules
break;
case "unload":
if (cmdparams.Length > 1)
{
foreach (IRegionModule rm in new ArrayList(m_moduleLoader.GetLoadedSharedModules))
{
if (rm.Name.ToLower() == cmdparams[1].ToLower())
{
MainConsole.Instance.Output(String.Format("Unloading module: {0}", rm.Name));
m_moduleLoader.UnloadModule(rm);
}
}
}
//TODO: Convert to new region modules
break;
case "load":
if (cmdparams.Length > 1)
{
foreach (Scene s in new ArrayList(SceneManager.Scenes))
{
MainConsole.Instance.Output(String.Format("Loading module: {0}", cmdparams[1]));
m_moduleLoader.LoadRegionModules(cmdparams[1], s);
}
}
//TODO: Convert to new region modules
break;
}
}
@@ -1018,28 +998,9 @@ namespace OpenSim
break;
case "modules":
MainConsole.Instance.Output("The currently loaded shared modules are:");
foreach (IRegionModule module in m_moduleLoader.GetLoadedSharedModules)
{
MainConsole.Instance.Output("Shared Module: " + module.Name);
}
SceneManager.ForEachScene(
delegate(Scene scene) {
m_log.Error("The currently loaded modules in " + scene.RegionInfo.RegionName + " are:");
foreach (IRegionModule module in scene.Modules.Values)
{
if (!module.IsSharedModule)
{
m_log.Error("Region Module: " + module.Name);
}
}
}
);
SceneManager.ForEachScene(
delegate(Scene scene) {
MainConsole.Instance.Output("Loaded new region modules in" + scene.RegionInfo.RegionName + " are:");
MainConsole.Instance.Output("Loaded region modules in" + scene.RegionInfo.RegionName + " are:");
foreach (IRegionModuleBase module in scene.RegionModules.Values)
{
Type type = module.GetType().GetInterface("ISharedRegionModule");

View File

@@ -131,14 +131,6 @@ namespace OpenSim
get { return m_httpServerPort; }
}
public ModuleLoader ModuleLoader
{
get { return m_moduleLoader; }
set { m_moduleLoader = value; }
}
protected ModuleLoader m_moduleLoader;
protected IRegistryCore m_applicationRegistry = new RegistryCore();
public IRegistryCore ApplicationRegistry
@@ -232,9 +224,6 @@ namespace OpenSim
base.StartupSpecific();
// Create a ModuleLoader instance
m_moduleLoader = new ModuleLoader(m_config.Source);
LoadPlugins();
if (m_plugins.Count == 0) // We failed to load any modules. Mono Addins glitch!
@@ -385,12 +374,6 @@ namespace OpenSim
m_log.Info("[MODULES]: Loading Region's modules (old style)");
List<IRegionModule> modules = m_moduleLoader.PickupModules(scene, ".");
// This needs to be ahead of the script engine load, so the
// script module can pick up events exposed by a module
m_moduleLoader.InitialiseSharedModules(scene);
// Use this in the future, the line above will be deprecated soon
m_log.Info("[REGIONMODULES]: Loading Region's modules (new style)");
IRegionModulesController controller;
@@ -400,28 +383,29 @@ namespace OpenSim
}
else m_log.Error("[REGIONMODULES]: The new RegionModulesController is missing...");
if (m_securePermissionsLoading)
{
foreach (string s in m_permsModules)
{
if (!scene.RegionModules.ContainsKey(s))
{
bool found = false;
foreach (IRegionModule m in modules)
{
if (m.Name == s)
{
found = true;
}
}
if (!found)
{
m_log.Fatal("[MODULES]: Required module " + s + " not found.");
Environment.Exit(0);
}
}
}
}
// XPTO: Fix this
// if (m_securePermissionsLoading)
// {
// foreach (string s in m_permsModules)
// {
// if (!scene.RegionModules.ContainsKey(s))
// {
// bool found = false;
// foreach (IRegionModule m in modules)
// {
// if (m.Name == s)
// {
// found = true;
// }
// }
// if (!found)
// {
// m_log.Fatal("[MODULES]: Required module " + s + " not found.");
// Environment.Exit(0);
// }
// }
// }
// }
scene.SetModuleInterfaces();
// First Step of bootreport sequence
@@ -498,13 +482,6 @@ namespace OpenSim
{
scene.SnmpService.BootInfo("Initializing region modules", scene);
}
if (do_post_init)
{
foreach (IRegionModule module in modules)
{
module.PostInitialise();
}
}
scene.EventManager.OnShutdown += delegate() { ShutdownRegion(scene); };
mscene = scene;
@@ -805,7 +782,7 @@ namespace OpenSim
return new Scene(
regionInfo, circuitManager, sceneGridService,
simDataService, estateDataService, m_moduleLoader, false,
simDataService, estateDataService, false,
m_config.Source, m_version);
}