waypoint.cs 1.1 KB

1234567891011121314151617181920212223242526272829303132333435
  1. using System;
  2. using System.Collections.Generic;
  3. using Windows.UI.Xaml.Media.Imaging;
  4. using Windows.UI.Core;
  5. using Windows.UI.Xaml.Controls;
  6. using Windows.Devices.Geolocation;
  7. namespace Breda_Tour.Data
  8. {
  9. public class Waypoint
  10. {
  11. private Geopoint _position;
  12. public Geopoint Position
  13. {
  14. get { return _position; }
  15. }
  16. public String Title { get; private set; }
  17. public String Description { get; private set; }
  18. public List<Picture> Pictures { get; private set; }
  19. public Waypoint(double Lat, double Long, String Title, String Description, List<string> pictures)
  20. {
  21. this._position = new Geopoint(new BasicGeoposition() { Altitude = 0, Latitude = Lat, Longitude = Long });
  22. this.Title = Title;
  23. this.Description = Description;
  24. this.Pictures = new List<Picture>();
  25. foreach (var imageSource in pictures)
  26. {
  27. string newSource = "ms-appx:///Assets/" + imageSource;
  28. Pictures.Add(new Picture(newSource));
  29. }
  30. }
  31. }
  32. }