Skip to content

Commit

Permalink
move to Microsoft.Toolkit.Uwp.UI.Controls.Input
Browse files Browse the repository at this point in the history
  • Loading branch information
huynhsontung committed May 1, 2021
1 parent 27307f5 commit 2f17dcc
Show file tree
Hide file tree
Showing 12 changed files with 8 additions and 7 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -5,11 +5,11 @@
using System;
using System.Collections.Generic;
using System.Linq;
using Microsoft.Toolkit.Uwp.UI;
using Microsoft.Toolkit.Uwp.UI.Controls;
using Windows.UI;
using Windows.UI.Xaml;
using Windows.UI.Xaml.Controls;
using Microsoft.Toolkit.Uwp.UI.Extensions;

// The Blank Page item template is documented at https://go.microsoft.com/fwlink/?LinkId=234238

Expand Down Expand Up @@ -101,26 +101,26 @@ public void OnXamlRendered(FrameworkElement control)
this._rsb.SuggestionsRequested -= this.SuggestingBox_OnSuggestionsRequested;
}

if (control.FindChildByName("SuggestingBox") is RichSuggestBox rsb)
if (control.FindChild("SuggestingBox") is RichSuggestBox rsb)
{
this._rsb = rsb;
this._rsb.SuggestionChosen += this.SuggestingBox_OnSuggestionChosen;
this._rsb.SuggestionsRequested += this.SuggestingBox_OnSuggestionsRequested;
}

if (control.FindChildByName("PlainTextSuggestingBox") is RichSuggestBox tsb)
if (control.FindChild("PlainTextSuggestingBox") is RichSuggestBox tsb)
{
this._tsb = tsb;
this._tsb.SuggestionChosen += this.SuggestingBox_OnSuggestionChosen;
this._tsb.SuggestionsRequested += this.SuggestingBox_OnSuggestionsRequested;
}

if (control.FindChildByName("TokenListView1") is ListView tls1)
if (control.FindChild("TokenListView1") is ListView tls1)
{
tls1.ItemsSource = this._rsb?.Tokens;
}

if (control.FindChildByName("TokenListView2") is ListView tls2)
if (control.FindChild("TokenListView2") is ListView tls2)
{
tls2.ItemsSource = this._tsb?.Tokens;
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
// See the LICENSE file in the project root for more information.

using System;
using Microsoft.Toolkit.Uwp.Deferred;
using Microsoft.Toolkit.Deferred;

namespace Microsoft.Toolkit.Uwp.UI.Controls
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.

using Microsoft.Toolkit.Uwp.Deferred;
using Microsoft.Toolkit.Deferred;

namespace Microsoft.Toolkit.Uwp.UI.Controls
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,5 +8,6 @@
<ResourceDictionary Source="ms-appx:///Microsoft.Toolkit.Uwp.UI.Controls.Input/RangeSelector/RangeSelector.xaml" />
<ResourceDictionary Source="ms-appx:///Microsoft.Toolkit.Uwp.UI.Controls.Input/RemoteDevicePicker/RemoteDevicePicker.xaml" />
<ResourceDictionary Source="ms-appx:///Microsoft.Toolkit.Uwp.UI.Controls.Input/TokenizingTextBox/TokenizingTextBox.xaml" />
<ResourceDictionary Source="ms-appx:///Microsoft.Toolkit.Uwp.UI.Controls.Input/RichSuggestBox/RichSuggestBox.xaml" />
</ResourceDictionary.MergedDictionaries>
</ResourceDictionary>

0 comments on commit 2f17dcc

Please sign in to comment.