Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Enable text search on combo boxes #9206

Merged
3 commits merged into from
Feb 19, 2021
Merged
Show file tree
Hide file tree
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .github/actions/spelling/dictionary/apis.txt
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,7 @@ IObject
IPackage
IPeasant
IStorage
IStringable
ITab
ITaskbar
LCID
Expand Down
5 changes: 5 additions & 0 deletions src/cascadia/TerminalSettingsEditor/EnumEntry.h
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,11 @@ namespace winrt::Microsoft::Terminal::Settings::Editor::implementation
_EnumName{ enumName },
_EnumValue{ enumValue } {}

hstring ToString()
{
return EnumName();
}

WINRT_CALLBACK(PropertyChanged, Windows::UI::Xaml::Data::PropertyChangedEventHandler);
OBSERVABLE_GETSET_PROPERTY(winrt::hstring, EnumName, _PropertyChangedHandlers);
OBSERVABLE_GETSET_PROPERTY(winrt::Windows::Foundation::IInspectable, EnumValue, _PropertyChangedHandlers);
Expand Down
3 changes: 2 additions & 1 deletion src/cascadia/TerminalSettingsEditor/EnumEntry.idl
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,10 @@

namespace Microsoft.Terminal.Settings.Editor
{
[default_interface] runtimeclass EnumEntry : Windows.UI.Xaml.Data.INotifyPropertyChanged
[default_interface] runtimeclass EnumEntry : Windows.UI.Xaml.Data.INotifyPropertyChanged, Windows.Foundation.IStringable
{
String EnumName { get; };
IInspectable EnumValue { get; };
String ToString();
carlos-zamora marked this conversation as resolved.
Show resolved Hide resolved
}
}
5 changes: 5 additions & 0 deletions src/cascadia/TerminalSettingsModel/ColorScheme.h
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,11 @@ namespace winrt::Microsoft::Terminal::Settings::Model::implementation
ColorScheme(hstring name, COLORREF defaultFg, COLORREF defaultBg, COLORREF cursorColor);
com_ptr<ColorScheme> Copy() const;

hstring ToString()
{
return Name();
}

static com_ptr<ColorScheme> FromJson(const Json::Value& json);
bool ShouldBeLayered(const Json::Value& json) const;
void LayerJson(const Json::Value& json);
Expand Down
3 changes: 2 additions & 1 deletion src/cascadia/TerminalSettingsModel/ColorScheme.idl
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,9 @@

namespace Microsoft.Terminal.Settings.Model
{
[default_interface] runtimeclass ColorScheme {
[default_interface] runtimeclass ColorScheme : Windows.Foundation.IStringable {
ColorScheme(String name);
String ToString();
carlos-zamora marked this conversation as resolved.
Show resolved Hide resolved

String Name;

Expand Down
6 changes: 6 additions & 0 deletions src/cascadia/TerminalSettingsModel/Profile.h
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,12 @@ namespace winrt::Microsoft::Terminal::Settings::Model::implementation
public:
Profile();
Profile(guid guid);

hstring ToString()
{
return Name();
}

static com_ptr<Profile> CloneInheritanceGraph(com_ptr<Profile> oldProfile, com_ptr<Profile> newProfile, std::unordered_map<void*, com_ptr<Profile>>& visited);
static com_ptr<Profile> CopySettings(com_ptr<Profile> source);

Expand Down
4 changes: 3 additions & 1 deletion src/cascadia/TerminalSettingsModel/Profile.idl
Original file line number Diff line number Diff line change
Expand Up @@ -31,10 +31,12 @@ namespace Microsoft.Terminal.Settings.Model
Vertical_Bottom = 0x20
};

[default_interface] runtimeclass Profile {
[default_interface] runtimeclass Profile : Windows.Foundation.IStringable {
Profile();
Profile(Guid guid);

String ToString();

Boolean HasName();
void ClearName();
String Name;
Expand Down