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

TargetNullValue does not work with x:DataType #4103

Closed
ysmoradi opened this issue Oct 16, 2018 · 1 comment · Fixed by #4490

Comments

@ysmoradi
Copy link
Contributor

commented Oct 16, 2018

Description

I've following binding:

<Label Text="{Binding SomeNullValue, TargetNullValue='TargetNullValue'}" />

where SomeNullValue is null. I see no 'TargetNullValue'

Steps to Reproduce

See Reproduction Link.

Expected Behavior

See 'TargetNullValue'

Actual Behavior

See nothing. It becomes even worse if you bind that to something like BackgroundColor whihc does not accept null values (It's struct).

Basic Information

  • Version with issue:
  • Last known good version: N/A
  • IDE: Visual Studio 2017 15.8.5 Enterprise edition.
  • Platform Target Frameworks: This happens in Xamarin Forms Core (3.3.0.893527-pre3)

Screenshots

N/A

Reproduction Link

Clone https://github.com/ysmoradi/XDataTypeIssues and un comment this line. Then run the app.

@pauldipietro pauldipietro added this to New in Triage Oct 16, 2018

@StephaneDelcroix StephaneDelcroix self-assigned this Oct 17, 2018

@StephaneDelcroix StephaneDelcroix moved this from New to Ready For Work in Triage Oct 17, 2018

@samhouts samhouts added the t/bug 🐛 label Oct 29, 2018

@ysmoradi

This comment has been minimized.

Copy link
Contributor Author

commented Nov 6, 2018

I'm sure you're so busy with other tasks, but could you please let me know when this gets fixed? Thanks in advance.

StephaneDelcroix added a commit that referenced this issue Nov 20, 2018
[C] support TargetNullValue in TypedBindings
Call base.GetSourceValue so the TargetNullValue is returned in case of a
null value. I have no idea why the code was there, but commented out,
and I don't want any of you to start digging at the why it wasn't
enabled before.

- fixes #4103

@samhouts samhouts added this to In Progress in v3.6.0 Nov 20, 2018

@samhouts samhouts added this to To do in Other Ready For Work Nov 20, 2018

@samhouts samhouts removed this from Ready For Work in Triage Nov 20, 2018

Other Ready For Work automation moved this from To do to Done Nov 21, 2018

StephaneDelcroix added a commit that referenced this issue Nov 21, 2018
[C] support TargetNullValue in TypedBindings (#4490)
Call base.GetSourceValue so the TargetNullValue is returned in case of a
null value. I have no idea why the code was there, but commented out,
and I don't want any of you to start digging at the why it wasn't
enabled before.

- fixes #4103

@samhouts samhouts moved this from In Progress to Done in v3.6.0 Nov 21, 2018

@samhouts samhouts removed this from Done in v3.6.0 Jan 3, 2019

@samhouts samhouts added this to In Progress in v3.5.0 Jan 11, 2019

@samhouts samhouts moved this from In Progress to Done in v3.5.0 Jan 11, 2019

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
3 participants
You can’t perform that action at this time.