[TASK] Initial commit with basic product setup

This commit is contained in:
2019-08-18 13:50:14 +02:00
commit 01a66a8e1f
2548 changed files with 167528 additions and 0 deletions

View File

@@ -0,0 +1,55 @@
namespace Mapbox.Unity.Map
{
using Mapbox.Unity.MeshGeneration.Factories;
using Mapbox.Unity.MeshGeneration.Interfaces;
using Mapbox.Unity.MeshGeneration.Modifiers;
public class LayerUpdateArgs : System.EventArgs
{
public AbstractTileFactory factory;
public MapboxDataProperty property;
public bool effectsVectorLayer;
}
public class VectorLayerUpdateArgs : LayerUpdateArgs
{
public LayerVisualizerBase visualizer;
public ModifierBase modifier;
}
public class AbstractLayer
{
public event System.EventHandler UpdateLayer;
protected virtual void NotifyUpdateLayer(LayerUpdateArgs layerUpdateArgs)
{
System.EventHandler handler = UpdateLayer;
if (handler != null)
{
handler(this, layerUpdateArgs);
}
}
protected virtual void NotifyUpdateLayer(AbstractTileFactory factory, MapboxDataProperty prop, bool effectsVectorLayer = false)
{
System.EventHandler handler = UpdateLayer;
if (handler != null)
{
LayerUpdateArgs layerUpdateArgs =
(factory is VectorTileFactory) ?
new VectorLayerUpdateArgs
{
factory = factory,
effectsVectorLayer = effectsVectorLayer,
property = prop
}
:
new LayerUpdateArgs
{
factory = factory,
effectsVectorLayer = effectsVectorLayer,
property = prop
};
handler(this, layerUpdateArgs);
}
}
}
}