ふらっと C#,C♯,C#(初心者用) Part158at TECH
ふらっと C#,C♯,C#(初心者用) Part158 - 暇つぶし2ch888:デフォルトの名無しさん (ワッチョイ 4dc6-l/Dq)
23/07/18 16:00:19.51 zVxGTRP30.net
>>871
細かいけどINotifyPropertyChangedじゃない?
SquareにINotifyPropertyChangedを実装して、
Hogeの方でこういう風に
Square square {
get { return _square; }
set {
if (_square is not null) _square.PropertyChanged -= OnSquareChanged;
this._square = value;
if (value is not null) _square.PropertyChanged += OnSquareChanged;
}
}
void OnSquareChanged(object sender, PropertyChangedArgs e) {
this.OnPropertyChanged(nameof(this.square));
}


次ページ
続きを表示
1を表示
最新レス表示
レスジャンプ
類似スレ一覧
スレッドの検索
話題のニュース
おまかせリスト
オプション
しおりを挟む
スレッドに書込
スレッドの一覧
暇つぶし2ch