Skip to content

Commit bc5852e

Browse files
committed
analoge semantische Anpassung bei Beispielen zum Eventhandling (Preisanpassung) durchgefuehrt
1 parent b75016f commit bc5852e

1 file changed

Lines changed: 10 additions & 10 deletions

File tree

22_Events.md

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -431,10 +431,10 @@ public class Stock{
431431
public decimal Price{
432432
get { return price; }
433433
set { if (price != value){
434-
if (OnPropertyPriceChanged != null){
435-
OnPropertyPriceChanged(this, EventArgs.Empty );
436-
price = value;
437-
}
434+
price = value;
435+
if (OnPropertyPriceChanged != null){
436+
OnPropertyPriceChanged(this, EventArgs.Empty);
437+
}
438438
}
439439
}
440440
}
@@ -503,12 +503,12 @@ public class Stock{
503503
public decimal Price{
504504
get { return price; }
505505
set { if (price != value){
506-
if (OnPropertyPriceChanged != null){
507-
PriceChangedEventArgs myEventArgs = new PriceChangedEventArgs();
508-
myEventArgs.Difference = price - value;
509-
OnPropertyPriceChanged(this, myEventArgs );
510-
price = value;
511-
}
506+
price = value;
507+
if (OnPropertyPriceChanged != null){
508+
PriceChangedEventArgs myEventArgs = new PriceChangedEventArgs();
509+
myEventArgs.Difference = price - value;
510+
OnPropertyPriceChanged(this, myEventArgs);
511+
}
512512
}
513513
}
514514
}

0 commit comments

Comments
 (0)