diff --git a/CampusAppWP8/CampusAppWP8/Model/Campusmap/Maps/BuildingMapModel.cs b/CampusAppWP8/CampusAppWP8/Model/Campusmap/Maps/BuildingMapModel.cs
index 0aa09ac9..2748639a 100644
--- a/CampusAppWP8/CampusAppWP8/Model/Campusmap/Maps/BuildingMapModel.cs
+++ b/CampusAppWP8/CampusAppWP8/Model/Campusmap/Maps/BuildingMapModel.cs
@@ -10,11 +10,10 @@ namespace CampusAppWP8.Model.Campusmap.Map
{
using System.Globalization;
using System.Linq;
- using System.Windows;
using CampusAppWP8.Model.GeoDb;
using CampusAppWP8.Resources;
- using CampusAppWPortalLib8.Utility;
using CampusAppWPortalLib8.Model.Utility;
+ using CampusAppWPortalLib8.Utility;
/// A data Model for the building map.
/// Stubbfel, 14.10.2013.
diff --git a/CampusAppWP8/CampusAppWP8/Model/Campusmap/Maps/CBMainMapModel.cs b/CampusAppWP8/CampusAppWP8/Model/Campusmap/Maps/CBMainMapModel.cs
index 4d9c1e87..0135f757 100644
--- a/CampusAppWP8/CampusAppWP8/Model/Campusmap/Maps/CBMainMapModel.cs
+++ b/CampusAppWP8/CampusAppWP8/Model/Campusmap/Maps/CBMainMapModel.cs
@@ -9,7 +9,6 @@
namespace CampusAppWP8.Model.Campusmap.Map
{
using System.Collections.Generic;
- using System.Windows;
using CampusAppWP8.Model.GeoDb;
using CampusAppWP8.Resources;
using CampusAppWPortalLib8.Model.Utility;
diff --git a/CampusAppWP8/CampusAppWP8/Model/Campusmap/Maps/MapWp8Model.cs b/CampusAppWP8/CampusAppWP8/Model/Campusmap/Maps/MapWp8Model.cs
index 3bb05881..fb61bd2e 100644
--- a/CampusAppWP8/CampusAppWP8/Model/Campusmap/Maps/MapWp8Model.cs
+++ b/CampusAppWP8/CampusAppWP8/Model/Campusmap/Maps/MapWp8Model.cs
@@ -1,27 +1,27 @@
//-----------------------------------------------------------------------
-//
+//
// The MIT License (MIT). Copyright (c) 2013 BTU/IIT.
//
// Stubbfel
-// 14.10.2013
-// Implements the map model class
+// 22.10.2013
+// Implements the map wp 8 model class
//-----------------------------------------------------------------------
namespace CampusAppWP8.Model.Campusmap.Map
{
using System;
using System.Collections.Generic;
- using System.Windows;
using System.Windows.Controls;
using System.Windows.Input;
using System.Windows.Media.Imaging;
- using CampusAppWP8.Model.GeoDb;
using CampusAppWP8.Model.Campusmap.Pin;
- using CampusAppWPortalLib8.Model.Utility;
+ using CampusAppWP8.Model.GeoDb;
using CampusAppWPortalLib8.Model.Campusmap.Pin;
+ using CampusAppWPortalLib8.Model.Utility;
/// This Class manage the properties of a Map.
/// Stubbfel, 14.10.2013.
- public class MapWp8Model : CampusAppWPortalLib8.Model.Campusmap.Map.MapModel
+ ///
+ public class MapWp8Model : CampusAppWPortalLib8.Model.Campusmap.Map.MapModel
{
#region Constructors
diff --git a/CampusAppWP8/CampusAppWP8/Model/Campusmap/Pins/ClickAblePlacePinModel.cs b/CampusAppWP8/CampusAppWP8/Model/Campusmap/Pins/ClickAblePlacePinModel.cs
index 2a314373..729e45cb 100644
--- a/CampusAppWP8/CampusAppWP8/Model/Campusmap/Pins/ClickAblePlacePinModel.cs
+++ b/CampusAppWP8/CampusAppWP8/Model/Campusmap/Pins/ClickAblePlacePinModel.cs
@@ -9,9 +9,9 @@
namespace CampusAppWP8.Model.Campusmap.Pin
{
using System.Collections.Generic;
- using CampusAppWP8.Model.GeoDb;
using CampusAppWP8.Model.Campusmap.Map;
- using CampusAppWPortalLib8.Model.Campusmap.Pin;
+ using CampusAppWP8.Model.GeoDb;
+ using CampusAppWPortalLib8.Model.Campusmap.Pin;
/// abstract class for click abel bins.
/// Stubbfel, 14.10.2013.
diff --git a/CampusAppWP8/CampusAppWP8/Model/Campusmap/Pins/CurrentPositionPinModel.cs b/CampusAppWP8/CampusAppWP8/Model/Campusmap/Pins/CurrentPositionPinModel.cs
index 7e3d0ed4..61aeca2c 100644
--- a/CampusAppWP8/CampusAppWP8/Model/Campusmap/Pins/CurrentPositionPinModel.cs
+++ b/CampusAppWP8/CampusAppWP8/Model/Campusmap/Pins/CurrentPositionPinModel.cs
@@ -8,10 +8,9 @@
//-----------------------------------------------------------------------
namespace CampusAppWP8.Model.Campusmap.Pin
{
- using System.Windows;
using CampusAppWP8.Resources;
- using CampusAppWPortalLib8.Model.Utility;
using CampusAppWPortalLib8.Model.Campusmap.Pin;
+ using CampusAppWPortalLib8.Model.Utility;
/// Current position pin model.
/// Stubbfel, 27.08.2013.
diff --git a/CampusAppWP8/CampusAppWP8/Model/Campusmap/Pins/HiddenPinPlaceModel.cs b/CampusAppWP8/CampusAppWP8/Model/Campusmap/Pins/HiddenPinPlaceModel.cs
index cfe0fe7a..2e7aa0d6 100644
--- a/CampusAppWP8/CampusAppWP8/Model/Campusmap/Pins/HiddenPinPlaceModel.cs
+++ b/CampusAppWP8/CampusAppWP8/Model/Campusmap/Pins/HiddenPinPlaceModel.cs
@@ -6,9 +6,10 @@
// 14.10.2013
// Implements the hidden pin place model class
//-----------------------------------------------------------------------
-using CampusAppWPortalLib8.Model.Campusmap.Pin;
namespace CampusAppWP8.Model.Campusmap.Pin
{
+ using CampusAppWPortalLib8.Model.Campusmap.Pin;
+
/// Hidden pin place model.
/// Stubbfel, 27.08.2013.
///
diff --git a/CampusAppWP8/CampusAppWP8/Model/Campusmap/Pins/InfoLabPlacePinModel.cs b/CampusAppWP8/CampusAppWP8/Model/Campusmap/Pins/InfoLabPlacePinModel.cs
index 98f55e55..cec99ac5 100644
--- a/CampusAppWP8/CampusAppWP8/Model/Campusmap/Pins/InfoLabPlacePinModel.cs
+++ b/CampusAppWP8/CampusAppWP8/Model/Campusmap/Pins/InfoLabPlacePinModel.cs
@@ -18,8 +18,8 @@ namespace CampusAppWP8.Model.Campusmap.Pin
{
#region Constructor
- /// Initializes a new instance of the class.
- /// Stubbfel, 27.08.2013.
+ /// Initializes a new instance of the InfoLabPlacePinModel class.
+ /// Stubbfel, 22.10.2013.
public InfoLabPlacePinModel()
{
this.ImageSource = Icons.PlaceLab;
diff --git a/CampusAppWP8/CampusAppWP8/Model/Campusmap/Pins/InfoPlaceAccessPinModel.cs b/CampusAppWP8/CampusAppWP8/Model/Campusmap/Pins/InfoPlaceAccessPinModel.cs
index 63f162db..bf93a54f 100644
--- a/CampusAppWP8/CampusAppWP8/Model/Campusmap/Pins/InfoPlaceAccessPinModel.cs
+++ b/CampusAppWP8/CampusAppWP8/Model/Campusmap/Pins/InfoPlaceAccessPinModel.cs
@@ -18,8 +18,8 @@ namespace CampusAppWP8.Model.Campusmap.Pin
{
#region Constructor
- /// Initializes a new instance of the class.
- /// Stubbfel, 27.08.2013.
+ /// Initializes a new instance of the InfoPlaceAccessPinModel class.
+ /// Stubbfel, 22.10.2013.
public InfoPlaceAccessPinModel()
{
this.ImageSource = Icons.PlaceInfoAccess;
diff --git a/CampusAppWP8/CampusAppWP8/Pages/Campusmap/CampusMapPage.xaml.cs b/CampusAppWP8/CampusAppWP8/Pages/Campusmap/CampusMapPage.xaml.cs
index 7a61db9c..12e903a8 100644
--- a/CampusAppWP8/CampusAppWP8/Pages/Campusmap/CampusMapPage.xaml.cs
+++ b/CampusAppWP8/CampusAppWP8/Pages/Campusmap/CampusMapPage.xaml.cs
@@ -8,18 +8,6 @@
//-----------------------------------------------------------------------
namespace CampusAppWP8.Pages.Campusmap
{
- using CampusAppWP8.File.Places;
- using CampusAppWP8.Model.Campusmap.Map;
- using CampusAppWP8.Model.Campusmap.Pin;
- using CampusAppWP8.Model.GeoDb;
- using CampusAppWP8.Resources;
- using CampusAppWP8.Utility;
- using CampusAppWP8.Utility.Lui.MessageBoxes;
- using CampusAppWP8.Utility.NDEF;
- using CampusAppWPortalLib8.Model.Campusmap.Pin;
- using CampusAppWPortalLib8.Model.Utility;
- using Microsoft.Phone.Controls;
- using Microsoft.Phone.Shell;
using System;
using System.Collections.Generic;
using System.Device.Location;
@@ -31,6 +19,17 @@ namespace CampusAppWP8.Pages.Campusmap
using System.Windows.Controls;
using System.Windows.Input;
using System.Windows.Navigation;
+ using CampusAppWP8.File.Places;
+ using CampusAppWP8.Model.Campusmap.Map;
+ using CampusAppWP8.Model.GeoDb;
+ using CampusAppWP8.Resources;
+ using CampusAppWP8.Utility;
+ using CampusAppWP8.Utility.Lui.MessageBoxes;
+ using CampusAppWP8.Utility.NDEF;
+ using CampusAppWPortalLib8.Model.Campusmap.Pin;
+ using CampusAppWPortalLib8.Model.Utility;
+ using Microsoft.Phone.Controls;
+ using Microsoft.Phone.Shell;
using Windows.Networking.Proximity;
/// Class for the campusMap page.
diff --git a/CampusAppWP8/CampusAppWP8/Pages/Campusmap/RoomListPage.xaml.cs b/CampusAppWP8/CampusAppWP8/Pages/Campusmap/RoomListPage.xaml.cs
index c49774cb..f0aa4d96 100644
--- a/CampusAppWP8/CampusAppWP8/Pages/Campusmap/RoomListPage.xaml.cs
+++ b/CampusAppWP8/CampusAppWP8/Pages/Campusmap/RoomListPage.xaml.cs
@@ -16,16 +16,14 @@ namespace CampusAppWP8.Pages.Campusmap
using System.Windows.Media;
using System.Windows.Navigation;
using CampusAppWP8.File.Places;
- using CampusAppWP8.Model.Campusmap;
+ using CampusAppWP8.Model.Campusmap.Map;
using CampusAppWP8.Model.GeoDb;
using CampusAppWP8.Resources;
using CampusAppWP8.Utility;
using CampusAppWP8.Utility.Lui.MessageBoxes;
+ using CampusAppWPortalLib8.Model.Campusmap.Pin;
using CampusAppWPortalLib8.Model.Utility;
using Microsoft.Phone.Controls;
- using CampusAppWP8.Model.Campusmap.Map;
- using CampusAppWP8.Model.Campusmap.Pin;
- using CampusAppWPortalLib8.Model.Campusmap.Pin;
/// Class of the RoomListPage.
/// Stubbfel, 14.10.2013.
@@ -157,8 +155,7 @@ namespace CampusAppWP8.Pages.Campusmap
x = room.GeoRefPoint.Longitude;
y = room.GeoRefPoint.Latitude;
MapPoint roompoint = this.buildingMap.GetScrollPoint(this.buildingMap.ConverToPixelPoint(this.buildingMap.ConverToMapPoint(x, y)));
- MapPoint viewPoint = roompoint - mappoint + offsetPoint;
-
+ MapPoint viewPoint = roompoint - this.mappoint + this.offsetPoint;
MapCanvas.Children.Add(this.buildingMap.AddPin(viewPoint, MapPinModel.PinType.InfoRedPlace, new List { room }));
}
@@ -303,7 +300,7 @@ namespace CampusAppWP8.Pages.Campusmap
x = room.GeoRefPoint.Longitude;
y = room.GeoRefPoint.Latitude;
MapPoint roompoint = this.buildingMap.GetScrollPoint(this.buildingMap.ConverToPixelPoint(this.buildingMap.ConverToMapPoint(x, y)));
- MapPoint viewPoint = roompoint - mappoint + offsetPoint;
+ MapPoint viewPoint = roompoint - this.mappoint + this.offsetPoint;
MapPinModel.PinType type;
@@ -328,7 +325,7 @@ namespace CampusAppWP8.Pages.Campusmap
MapCanvas.Children.Add(this.buildingMap.AddPin(viewPoint, type, new List { room }));
}
- // MapCanvas.Children.Add(this.buildingMap.AddPin(offsetPoint, MapPinModel.PinType.SearchPlace));
+ // MapCanvas.Children.Add(this.buildingMap.AddPin(offsetPoint, MapPinModel.PinType.SearchPlace));
}
/// Shows the layer places.
@@ -354,7 +351,7 @@ namespace CampusAppWP8.Pages.Campusmap
double y = this.building.Building.GeoRefPoint.Latitude;
double x = this.building.Building.GeoRefPoint.Longitude;
this.mappoint = this.buildingMap.GetScrollPoint(this.buildingMap.ConverToPixelPoint(this.buildingMap.ConverToMapPoint(x, y)));
- this.offsetPoint = -this.buildingMap.MapImageOffsetPoint;// new Point(-this.buildingMap.MapImageOffsetX, -this.buildingMap.MapImageOffsetY);
+ this.offsetPoint = -this.buildingMap.MapImageOffsetPoint;
this.MapCanvas.DataContext = this.buildingMap;
diff --git a/CampusAppWP8/CampusAppWP8/Utility/Utilities.cs b/CampusAppWP8/CampusAppWP8/Utility/Utilities.cs
index 87d42f83..cf835b3f 100644
--- a/CampusAppWP8/CampusAppWP8/Utility/Utilities.cs
+++ b/CampusAppWP8/CampusAppWP8/Utility/Utilities.cs
@@ -17,11 +17,11 @@ namespace CampusAppWP8.Utility
using System.Windows.Media;
using CampusAppWP8.Resources;
using CampusAppWPortalLib8.Model;
+ using CampusAppWPortalLib8.Model.Campusmap.Map;
using CampusAppWPortalLib8.Model.Settings;
using CampusAppWPortalLib8.Model.Utility;
using CampusAppWPortalLib8.Utility;
using Microsoft.Phone.Net.NetworkInformation;
- using CampusAppWPortalLib8.Model.Campusmap.Map;
/// Collection of utility functions.
/// Stubbfel, 14.10.2013.
@@ -137,15 +137,17 @@ namespace CampusAppWP8.Utility
return retValue;
}
- /// Return the element.
- /// Stubbfel, 14.10.2013.
+ /// Gets an element.
+ /// Stubbfel, 22.10.2013.
///
/// Thrown when the index is outside the required range.
///
- /// .
- /// .
- /// .
- /// (Optional)
+ /// root object.
+ /// name of the parent grid.
+ /// name of the element(s)
+ ///
+ /// (Optional) index of the element in the parent child list.
+ ///
/// The element.
public static FrameworkElement GetElement(DependencyObject rootObj, string parentGridName, string elemName, int index = 0)
{
@@ -252,7 +254,7 @@ namespace CampusAppWP8.Utility
return geoposition;
}
- /// Method set current positon to Zero.
+ /// Method set current position to Zero.
/// Stubbfel, 14.10.2013.
public static void SetGeoPositionToZero()
{
@@ -384,6 +386,7 @@ namespace CampusAppWP8.Utility
{
return true;
}
+
return false;
}
@@ -406,7 +409,6 @@ namespace CampusAppWP8.Utility
MapPoint currentPoint = new MapPoint(log, lat);
MapPoint tmpCampus = CampusMapPoints.NorthCB;
-
double minDistance = MapPoint.CalcDistance(currentPoint, tmpCampus);
if (minDistance < 0.01)
{
diff --git a/CampusAppWP8/CampusAppWPortalLib8/CampusAppWPortalLib8.csproj b/CampusAppWP8/CampusAppWPortalLib8/CampusAppWPortalLib8.csproj
index 52ea7f04..26f3acae 100644
--- a/CampusAppWP8/CampusAppWPortalLib8/CampusAppWPortalLib8.csproj
+++ b/CampusAppWP8/CampusAppWPortalLib8/CampusAppWPortalLib8.csproj
@@ -36,6 +36,7 @@
+
diff --git a/CampusAppWP8/CampusAppWPortalLib8/Model/Campusmap/Maps/CampusMapPoints.cs b/CampusAppWP8/CampusAppWPortalLib8/Model/Campusmap/Maps/CampusMapPoints.cs
index 83ba496d..8a50382c 100644
--- a/CampusAppWP8/CampusAppWPortalLib8/Model/Campusmap/Maps/CampusMapPoints.cs
+++ b/CampusAppWP8/CampusAppWPortalLib8/Model/Campusmap/Maps/CampusMapPoints.cs
@@ -1,12 +1,17 @@
-using CampusAppWPortalLib8.Model.Utility;
-using System;
-using System.Collections.Generic;
-using System.Linq;
-using System.Text;
-using System.Threading.Tasks;
-
+//-----------------------------------------------------------------------
+//
+// The MIT License (MIT). Copyright (c) 2013 BTU/IIT.
+//
+// Stubbfel
+// 22.10.2013
+// Implements the campus map points class
+//-----------------------------------------------------------------------
namespace CampusAppWPortalLib8.Model.Campusmap.Map
{
+ using CampusAppWPortalLib8.Model.Utility;
+
+ /// The campus map points.
+ /// Stubbfel, 22.10.2013.
public class CampusMapPoints
{
#region member
@@ -15,33 +20,41 @@ namespace CampusAppWPortalLib8.Model.Campusmap.Map
private static MapPoint northCB = new MapPoint(14.293908825617, 51.77670359509875);
/// The middle campus of cottbus.
- private static MapPoint midCB = new MapPoint(14.324056352976152,51.76737987049448);
+ private static MapPoint midCB = new MapPoint(14.324056352976152, 51.76737987049448);
/// The south campus of cottbus.
- private static MapPoint southCB = new MapPoint(14.319497377197282,51.72668339740452);
+ private static MapPoint southCB = new MapPoint(14.319497377197282, 51.72668339740452);
/// The middle campus of senftenberg.
- private static MapPoint midSFB = new MapPoint(13.986618441187698,51.522217168257356);
+ private static MapPoint midSFB = new MapPoint(13.986618441187698, 51.522217168257356);
#endregion
#region porperty
+ /// Gets the middle sfb.
+ /// The middle sfb.
public static MapPoint MidSFB
{
get { return CampusMapPoints.midSFB; }
}
+ /// Gets the south cb.
+ /// The south cb.
public static MapPoint SouthCB
{
get { return CampusMapPoints.southCB; }
}
+ /// Gets the middle cb.
+ /// The middle cb.
public static MapPoint MidCB
{
get { return CampusMapPoints.midCB; }
}
+ /// Gets the north cb.
+ /// The north cb.
public static MapPoint NorthCB
{
get { return CampusMapPoints.northCB; }
diff --git a/CampusAppWP8/CampusAppWPortalLib8/Model/Campusmap/Maps/MapModel.cs b/CampusAppWP8/CampusAppWPortalLib8/Model/Campusmap/Maps/MapModel.cs
index d2babaa1..53cf3504 100644
--- a/CampusAppWP8/CampusAppWPortalLib8/Model/Campusmap/Maps/MapModel.cs
+++ b/CampusAppWP8/CampusAppWPortalLib8/Model/Campusmap/Maps/MapModel.cs
@@ -8,27 +8,29 @@
//-----------------------------------------------------------------------
namespace CampusAppWPortalLib8.Model.Campusmap.Map
{
+ using System.Collections.Generic;
using CampusAppWPortalLib8.Model.GeoDb;
using CampusAppWPortalLib8.Model.Utility;
- using System.Collections.Generic;
- /// This Class manage the properties of a Map.
- /// Stubbfel, 14.10.2013.
+ /// A data Model for the map.
+ /// Stubbfel, 22.10.2013.
+ /// Generic type parameter. SpsModel
+ /// Generic type parameter. PlaceModel
public class MapModel
where V : PlaceModel
where T : SpsModel, new()
{
#region Constructors
- /// Initializes a new instance of the class.
- /// Stubbfel, 14.10.2013.
+ /// Initializes a new instance of the MapModel class.
+ /// Stubbfel, 22.10.2013.
public MapModel()
{
this.IsReady = false;
}
- /// Initializes a new instance of the class.
- /// Stubbfel, 14.10.2013.
+ /// Initializes a new instance of the MapModel class.
+ /// Stubbfel, 22.10.2013.
/// list of places.
public MapModel(List placeList)
{
@@ -77,6 +79,8 @@ namespace CampusAppWPortalLib8.Model.Campusmap.Map
/// The reference point.
public MapPoint RefPoint { get; set; }
+ /// Gets the map reference point.
+ /// The map reference point.
public MapPoint MapRefPoint
{
get
@@ -84,7 +88,6 @@ namespace CampusAppWPortalLib8.Model.Campusmap.Map
return this.MapImageOffsetPoint + this.RefPoint;
}
}
-
#endregion
@@ -98,7 +101,7 @@ namespace CampusAppWPortalLib8.Model.Campusmap.Map
/// The scroll point.
public MapPoint GetScrollPoint(MapPoint point)
{
- MapPoint result = this.MapRefPoint;
+ MapPoint result = this.MapRefPoint;
result.X += point.X;
result.Y -= point.Y;
return result;
@@ -114,7 +117,6 @@ namespace CampusAppWPortalLib8.Model.Campusmap.Map
return this.GetScrollPoint(new MapPoint(x, y));
}
-
/// Convert a coordinates to coordinates which address pixels.
/// Stubbfel, 27.08.2013.
/// the x-coordinate.
@@ -122,7 +124,7 @@ namespace CampusAppWPortalLib8.Model.Campusmap.Map
/// Point in pixel-size.
public MapPoint ConverToPixelPoint(double x, double y)
{
- return this.ConverToPixelPoint(new MapPoint(x,y));
+ return this.ConverToPixelPoint(new MapPoint(x, y));
}
/// Convert a coordinates to coordinates which address pixels.
@@ -150,7 +152,7 @@ namespace CampusAppWPortalLib8.Model.Campusmap.Map
/// Point in pixel-size.
public MapPoint ConverToMapPoint(MapPoint point)
{
- MapPoint result = point - this.GeoOffsetPoint;
+ MapPoint result = point - this.GeoOffsetPoint;
return result;
}
diff --git a/CampusAppWP8/CampusAppWPortalLib8/Model/Campusmap/Pins/MapPinModel.cs b/CampusAppWP8/CampusAppWPortalLib8/Model/Campusmap/Pins/MapPinModel.cs
index 26b387b2..3ba6084c 100644
--- a/CampusAppWP8/CampusAppWPortalLib8/Model/Campusmap/Pins/MapPinModel.cs
+++ b/CampusAppWP8/CampusAppWPortalLib8/Model/Campusmap/Pins/MapPinModel.cs
@@ -8,6 +8,7 @@
//-----------------------------------------------------------------------
namespace CampusAppWPortalLib8.Model.Campusmap.Pin
{
+ using CampusAppWPortalLib8.Model.Campusmap.Pins;
using CampusAppWPortalLib8.Model.Utility;
using CampusAppWPortalLib8.Resources;
@@ -56,38 +57,6 @@ namespace CampusAppWPortalLib8.Model.Campusmap.Pin
#endregion
- #region enums
-
- /// Values that represent PinType.
- /// Stubbfel, 27.08.2013.
- public enum PinType
- {
- /// An enum constant representing the hidden option.
- Hidden = 0,
-
- /// An enum constant representing the search place option.
- SearchPlace = 1,
-
- /// An enum constant representing the current position option.
- CurrentPosition = 2,
-
- /// An enum constant representing the info place option.
- InfoPlace = 3,
-
- /// An enum constant representing the information lab place option.
- InfoLabPlace = 4,
-
- /// An enum constant representing the information wc place option.
- InfoWcPlace = 5,
-
- /// An enum constant representing the information red place option.
- InfoRedPlace = 6,
-
- /// An enum constant representing the information access place option.
- InfoAccesPlace = 7
- }
- #endregion
-
#region Property
/// Gets the information red place pin string.
@@ -204,6 +173,7 @@ namespace CampusAppWPortalLib8.Model.Campusmap.Pin
}
#endregion
+
#endregion
#region Method
diff --git a/CampusAppWP8/CampusAppWPortalLib8/Model/Campusmap/Pins/PinTypes.cs b/CampusAppWP8/CampusAppWPortalLib8/Model/Campusmap/Pins/PinTypes.cs
new file mode 100644
index 00000000..08d87fc3
--- /dev/null
+++ b/CampusAppWP8/CampusAppWPortalLib8/Model/Campusmap/Pins/PinTypes.cs
@@ -0,0 +1,42 @@
+//-----------------------------------------------------------------------
+//
+// The MIT License (MIT). Copyright (c) 2013 BTU/IIT.
+//
+// Stubbfel
+// 22.10.2013
+// Implements the pin types class
+//-----------------------------------------------------------------------
+namespace CampusAppWPortalLib8.Model.Campusmap.Pins
+{
+ #region enums
+
+ /// Values that represent PinType.
+ /// Stubbfel, 27.08.2013.
+ public enum PinType
+ {
+ /// An enum constant representing the hidden option.
+ Hidden = 0,
+
+ /// An enum constant representing the search place option.
+ SearchPlace = 1,
+
+ /// An enum constant representing the current position option.
+ CurrentPosition = 2,
+
+ /// An enum constant representing the info place option.
+ InfoPlace = 3,
+
+ /// An enum constant representing the information lab place option.
+ InfoLabPlace = 4,
+
+ /// An enum constant representing the information wc place option.
+ InfoWcPlace = 5,
+
+ /// An enum constant representing the information red place option.
+ InfoRedPlace = 6,
+
+ /// An enum constant representing the information access place option.
+ InfoAccesPlace = 7
+ }
+ #endregion
+}
diff --git a/CampusAppWP8/CampusAppWPortalLib8/Model/Utility/MapPoint.cs b/CampusAppWP8/CampusAppWPortalLib8/Model/Utility/MapPoint.cs
index 23a83efa..6105c472 100644
--- a/CampusAppWP8/CampusAppWPortalLib8/Model/Utility/MapPoint.cs
+++ b/CampusAppWP8/CampusAppWPortalLib8/Model/Utility/MapPoint.cs
@@ -1,16 +1,26 @@
-using System;
-using System.Collections.Generic;
-using System.Linq;
-using System.Text;
-using System.Threading.Tasks;
-
+//-----------------------------------------------------------------------
+//
+// The MIT License (MIT). Copyright (c) 2013 BTU/IIT.
+//
+// Stubbfel
+// 22.10.2013
+// Implements the map point class
+//-----------------------------------------------------------------------
namespace CampusAppWPortalLib8.Model.Utility
{
+ using System;
+
+ /// A map point.
+ /// Stubbfel, 22.10.2013.
+ ///
public class MapPoint : IEquatable
{
-
#region Constructor
+ /// Initializes a new instance of the MapPoint class.
+ /// Stubbfel, 22.10.2013.
+ /// The x coordinate.
+ /// The y coordinate.
public MapPoint(double x, double y)
{
this.X = x;
@@ -21,39 +31,93 @@ namespace CampusAppWPortalLib8.Model.Utility
#region property
+ /// Gets or sets the x coordinate.
+ /// The x coordinate.
public double X { get; set; }
+ /// Gets or sets the y coordinate.
+ /// The y coordinate.
public double Y { get; set; }
#endregion
#region method
+ /// Addition operator.
+ /// Stubbfel, 22.10.2013.
+ /// The first mapPoint.
+ /// The second mapPoint.
+ /// The result of the operation.
public static MapPoint operator +(MapPoint mp1, MapPoint mp2)
{
return new MapPoint(mp1.X + mp2.X, mp1.Y + mp2.Y);
}
+ /// Subtraction operator.
+ /// Stubbfel, 22.10.2013.
+ /// The first mapPoint.
+ /// The second mapPoint.
+ /// The result of the operation.
public static MapPoint operator -(MapPoint mp1, MapPoint mp2)
{
return new MapPoint(mp1.X - mp2.X, mp1.Y - mp2.Y);
}
+ /// Negation operator.
+ /// Stubbfel, 22.10.2013.
+ /// The mapPoint.
+ /// The result of the operation.
public static MapPoint operator -(MapPoint mp1)
{
return new MapPoint(-mp1.X, -mp1.Y);
}
+ /// Multiplication operator.
+ /// Stubbfel, 22.10.2013.
+ /// The first mapPoint.
+ /// The second mapPoint.
+ /// The result of the operation.
public static MapPoint operator *(MapPoint mp1, MapPoint mp2)
{
return new MapPoint(mp1.X * mp2.X, mp1.Y * mp2.Y);
}
+ /// Division operator.
+ /// Stubbfel, 22.10.2013.
+ /// The first mapPoint.
+ /// The second mapPoint.
+ /// The result of the operation.
public static MapPoint operator /(MapPoint mp1, MapPoint mp2)
{
return new MapPoint(mp1.X / mp2.X, mp1.Y / mp2.Y);
}
+ /// Calculates the distance.
+ /// Stubbfel, 22.10.2013.
+ /// Start Point.
+ /// End Point.
+ /// The calculated distance.
+ public static double CalcDistance(MapPoint src, MapPoint dst)
+ {
+ MapPoint subPoint = dst - src;
+ subPoint *= subPoint;
+ double result = Math.Sqrt(subPoint.X + subPoint.Y);
+ return result;
+ }
+
+ /// Calculates the distance.
+ /// Stubbfel, 22.10.2013.
+ /// The map point to compare to this object.
+ /// The calculated distance.
+ public double CalcDistance(MapPoint other)
+ {
+ return MapPoint.CalcDistance(other, this);
+ }
+
+ /// Tests if this MapPoint is considered equal to another.
+ /// Stubbfel, 22.10.2013.
+ /// The map point to compare to this object.
+ /// true if the objects are considered equal, false if they are not.
public bool Equals(MapPoint other)
{
if (other != null && this.X == other.X && this.Y == other.Y)
@@ -64,15 +128,6 @@ namespace CampusAppWPortalLib8.Model.Utility
return false;
}
-
- public static double CalcDistance(MapPoint src, MapPoint dst)
- {
- MapPoint subPoint = dst - src;
- subPoint *= subPoint;
- double result = Math.Sqrt(subPoint.X + subPoint.Y);
- return result;
- }
-
#endregion
}
}
diff --git a/CampusAppWP8/CampusAppWPortalLib8/Settings.StyleCop b/CampusAppWP8/CampusAppWPortalLib8/Settings.StyleCop
index d40e399f..62e42ba3 100644
--- a/CampusAppWP8/CampusAppWPortalLib8/Settings.StyleCop
+++ b/CampusAppWP8/CampusAppWPortalLib8/Settings.StyleCop
@@ -3,14 +3,20 @@
akadgrad
api
+ cb
+ enum
fiedlchr
nfc
param
qr
+ senftenberg
+ sfb
+ sps
str
stubbfel
telefon
uni
+ wc