コード例 #1
0
ファイル: iTextBox.xaml.cs プロジェクト: ceejii/ForlaningsApp
        private void DecreaseValue(
            object sender,
            RoutedEventArgs e
            )
        {
            Value--;
            if (BoundToResident)
            {
                BoundToResidentEventArgs newEventArgs =
                    new BoundToResidentEventArgs(
                        BoundToResidentRoutedEvent,
                        "Decrease",
                        new SoldierModel()
                {
                    Position = ResidentType
                }
                        );

                RaiseEvent(newEventArgs);
            }
        }
コード例 #2
0
ファイル: iTextBox.xaml.cs プロジェクト: ceejii/ForlaningsApp
        private void IncreaseValue(
            object sender,
            RoutedEventArgs e
            )
        {
            Value++;
            if (BoundToResident)
            {
                BoundToResidentEventArgs newEventArgs =
                    new BoundToResidentEventArgs(
                        BoundToResidentRoutedEvent,
                        "Increase",
                        new SoldierModel()
                {
                    PersonName = "",
                    Age        = 0,
                    Type       = "Soldier",
                    Position   = ResidentType
                }
                        );

                RaiseEvent(newEventArgs);
            }
        }