-
-
Notifications
You must be signed in to change notification settings - Fork 7
/
Copy pathIMapboxView.cs
132 lines (103 loc) · 3.69 KB
/
IMapboxView.cs
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
namespace MapboxMaui;
using System.Windows.Input;
using MapboxMaui.Annotations;
using MapboxMaui.Query;
using MapboxMaui.Styles;
using MapboxMaui.Viewport;
public partial interface IMapboxView : IView
{
CameraOptions CameraOptions { get; set; }
GestureSettings GestureSettings { get; set; }
MapboxStyle MapboxStyle { get; set; }
IPosition MapCenter { get; set; }
float? MapZoom { get; set; }
OrnamentVisibility ScaleBarVisibility { get; set; }
DebugOption[] DebugOptions { get; set; }
IEnumerable<MapboxSource> Sources { get; set; }
IEnumerable<MapboxLayer> Layers { get; set; }
IEnumerable<ResolvedImage> Images { get; set; }
IEnumerable<ViewAnnotationOptions> ViewAnnotations { get; set; }
Terrain Terrain { get; set; }
Light Light { get; set; }
IAnnotationController AnnotationController { get; }
IMapFeatureQueryable QueryManager { get; }
IViewportPlugin Viewport { get; }
}
partial interface IMapboxView
{
event EventHandler MapReady;
ICommand MapReadyCommand { get; set; }
event EventHandler StyleLoaded;
ICommand StyleLoadedCommand { get; set; }
event EventHandler MapLoaded;
ICommand MapLoadedCommand { get; set; }
event EventHandler<MapTappedEventArgs> MapTapped;
ICommand Command { get; }
event EventHandler<CameraChangedEventArgs> CameraChanged;
ICommand CameraChangedCommand { get; }
event EventHandler<Viewport.ViewportStatusChangedEventArgs> ViewportStatusChanged;
ICommand ViewportStatusChangedCommand { get; }
event EventHandler<Gestures.RotatingBeganEventArgs> RotatingBegan;
ICommand RotatingBeganCommand { get; }
event EventHandler<Gestures.RotatingEndedEventArgs> RotatingEnded;
ICommand RotatingEndedCommand { get; }
event EventHandler<Gestures.RotatingEventArgs> Rotating;
ICommand RotatingCommand { get; }
}
public interface IAnnotationController
{
IPolygonAnnotationManager CreatePolygonAnnotationManager(string id, LayerPosition layerPosition);
ICircleAnnotationManager CreateCircleAnnotationManager(string id, LayerPosition layerPosition);
IPointAnnotationManager CreatePointAnnotationManager(string id, LayerPosition layerPosition, ClusterOptions clusterOptions = null);
IPolylineAnnotationManager CreatePolylineAnnotationManager(string id, LayerPosition layerPosition);
}
public interface IMapFeatureQueryable
{
Task<IEnumerable<QueriedRenderedFeature>> QueryRenderedFeaturesWith(ScreenPosition point, RenderedQueryOptions options);
}
public interface IMapboxController
{
IPosition GetMapPosition(ScreenPosition position);
CoordinateBounds GetCoordinateBoundsForCamera(CameraOptions cameraOptions);
ScreenPosition GetScreenPosition(IPosition position);
}
public class MapTappedEventArgs : EventArgs
{
public MapTappedPosition Position { get; }
public MapTappedEventArgs(MapTappedPosition position)
{
Position = position;
}
}
public class CameraChangedEventArgs : EventArgs
{
public CameraChangedEventArgs(CameraOptions options)
{
Options = options;
}
public CameraOptions Options { get; }
}
public class IndicatorAccuracyRadiusChangedEventArgs : EventArgs
{
public IndicatorAccuracyRadiusChangedEventArgs(double radius)
{
Radius = radius;
}
public double Radius { get; }
}
public class IndicatorBearingChangedEventArgs : EventArgs
{
public IndicatorBearingChangedEventArgs(double bearing)
{
Bearing = bearing;
}
public double Bearing { get; }
}
public class IndicatorPositionChangedEventArgs : EventArgs
{
public IndicatorPositionChangedEventArgs(IPosition position)
{
Position = position;
}
public IPosition Position { get; }
}