Tim Heyer's Fixation EditableComboBox for SL3 and SL's latest toolkit

I use Tim Heyer's style to get an editable combo box: http://timheuer.com/blog/archive/2008/11/05/silverlight-editable-combobox-using-styles.aspx

This works well in my project around the previous version of the Silverlight Toolkit. Unfortunately, trying to use this style with RTM RTM and the latest SL Toolkit does not work. I suspect the problem is this: "Breaking Change: part of the" DropDownToggle "template of type ToggleButton has been removed." I'm not sure how to fix this, to release the part down again, any ideas?

+3
source share
5 answers

. ToggleButton EditableComboStyle:

IsChecked="{Binding RelativeSource={RelativeSource TemplatedParent}, Path=IsDropDownOpen, Mode=TwoWay}"

ListBox x: Name= "" EditableComboStyle, . :

<toolkit:AutoCompleteBox MinimumPrefixLength="0" 
                                 MinimumPopulateDelay="200" 
                                 x:Name="editableCombo"
                                 Style="{StaticResource EditableComboStyle}"
                                 Text="{Binding MyProperty, Mode=TwoWay, NotifyOnValidationError=True, ValidatesOnExceptions=True}" />

, , combobox , :

  • , "Google", , - .

  • .

+3

Silverlight Toolkit # ( 2009 ), , . , .

ToggleButton - , Click IsDropDownOpen .

: , , , Silverlight 3.

, , , !

, , Silverlight Toolkit Silverlight 2 ( Silverlight 3 SDK) AutoCompleteBox ListBox "" "SelectionAdapter", ListBox .

+2
+2

Khyalis on Tim Heyer's blog seems to have fixed this by linking IsChecked to DropDownToggle:

IsChecked="{Binding RelativeSource={RelativeSource TemplatedParent}, Path=IsDropDownOpen, Mode=TwoWay}"

So far this works for me.

0
source

IsTabStop = false in AutoCompleteBox will fix the tab issue. The TextBox (inside the AutoCompleteBox template) will still focus on the tab.

0
source

Source: https://habr.com/ru/post/1713466/


All Articles