diff --git a/Trunk/Interface/CzokoŚmieciarka.WPFv2/Models/GarbageCollector.cs b/Trunk/Interface/CzokoŚmieciarka.WPFv2/Models/GarbageCollector.cs index 04f35a9..64e56d8 100644 --- a/Trunk/Interface/CzokoŚmieciarka.WPFv2/Models/GarbageCollector.cs +++ b/Trunk/Interface/CzokoŚmieciarka.WPFv2/Models/GarbageCollector.cs @@ -18,19 +18,23 @@ namespace CzokoŚmieciarka.WPFv2.Models { class WPFGarbageCollector : AGarbageCollector, IWPFObject, INotifyPropertyChanged { - public Image Image - { - get - { - return new Image - { - Source = new BitmapImage(new Uri(AppDomain.CurrentDomain.BaseDirectory + @"..\..\Images\garbageCollector.png")) - }; - } - } + public Image Image { get; set; } + //{ + // get + // { + // return new Image + // { + // Source = new BitmapImage(new Uri(AppDomain.CurrentDomain.BaseDirectory + @"..\..\Images\garbageCollector.png")) + // }; + // } + //} public WPFGarbageCollector(Coords startPosition, IEnumerable trashContainers, int columns, int rows) : base(startPosition, trashContainers, columns, rows) { + Image = new Image() + { + Source = new BitmapImage(new Uri(AppDomain.CurrentDomain.BaseDirectory + @"..\..\Images\garbageCollector.png")) + }; } public event PropertyChangedEventHandler PropertyChanged; diff --git a/Trunk/Interface/CzokoŚmieciarka.WPFv2/Models/House.cs b/Trunk/Interface/CzokoŚmieciarka.WPFv2/Models/House.cs index 4ad0f6d..eb7b999 100644 --- a/Trunk/Interface/CzokoŚmieciarka.WPFv2/Models/House.cs +++ b/Trunk/Interface/CzokoŚmieciarka.WPFv2/Models/House.cs @@ -17,17 +17,21 @@ namespace CzokoŚmieciarka.WPFv2.Models { public Coords Coords { get; set; } public IEnumerable TrashCans { get; set; } - public Image Image { get { - return new Image - { - Source = new BitmapImage(new Uri(AppDomain.CurrentDomain.BaseDirectory + @"..\..\Images\house.png")) - }; - } } + public Image Image { get; set; } + //{ get { + // return new Image + // { + // Source = new BitmapImage(new Uri(AppDomain.CurrentDomain.BaseDirectory + @"..\..\Images\house.png")) + // }; + // } } public WPFHouse(Coords coords, IEnumerable trashCans) { - + Image = new Image() + { + Source = new BitmapImage(new Uri(AppDomain.CurrentDomain.BaseDirectory + @"..\..\Images\house.png")) + }; TrashCans = trashCans; Coords = coords; } diff --git a/Trunk/Interface/CzokoŚmieciarka.WPFv2/Models/Road.cs b/Trunk/Interface/CzokoŚmieciarka.WPFv2/Models/Road.cs index fd1542b..8e4f5d7 100644 --- a/Trunk/Interface/CzokoŚmieciarka.WPFv2/Models/Road.cs +++ b/Trunk/Interface/CzokoŚmieciarka.WPFv2/Models/Road.cs @@ -13,20 +13,26 @@ namespace CzokoŚmieciarka.WPFv2.Models { class Road : IWPFObject { - public Image Image - { - get - { - return new Image - { - Source = new BitmapImage(new Uri(AppDomain.CurrentDomain.BaseDirectory + @"..\..\Images\intersection.png")) - }; - } - } - public Coords Coords { get; set; } + public Image Image { get; set; } + //{ + // get + // { + // return new Image + // { + // Source = new BitmapImage(new Uri(AppDomain.CurrentDomain.BaseDirectory + @"..\..\Images\intersection.png")) + // }; + // } + //} public Road() { + Image = new Image() + { + Source = + new BitmapImage(new Uri(AppDomain.CurrentDomain.BaseDirectory + @"..\..\Images\intersection.png")) + }; } + + public Coords Coords { get; set; } } }