开发者

WPF CheckBox IsChecked toggled on different events

Does anyone know t开发者_JS百科he rationale behind the WPF CheckBox behaviour where it (appears) to display IsChecked true on MouseLeftButtonDown event and false on MouseLeftButtonUp event?

The reason I ask is that I'm implementing a CheckBox in an existing grid where the text is on the left instead of the right of the CheckBox. The easiest way was to add a TextBlock and some code-behind, but if I want to be consistent it means adding both events and checking state on each one.


If all you want is CheckBox having text to its left, why not simply modify its template: http://www.codeproject.com/KB/WPF/WPFCheckboxTextOnLeft.aspx
http://social.msdn.microsoft.com/Forums/en/wpf/thread/85673c27-01e6-4f8e-96a5-1847bb44abc4

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜