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

Thickness null checks #26

Closed
wants to merge 1 commit into from
Closed

Thickness null checks #26

wants to merge 1 commit into from

Conversation

dp901
Copy link

@dp901 dp901 commented Mar 14, 2017

No description provided.

@BSick7
Copy link
Member

BSick7 commented Mar 14, 2017

I know it seems weird, but the null checks were left off intentionally.
Since copyTo is used during the pipeline execution, I aggressively pruned checks that were could incur penalties.

@BSick7
Copy link
Member

BSick7 commented Mar 14, 2017

Thanks for the PR though.
Is this causing issues for you?

@dp901
Copy link
Author

dp901 commented Mar 14, 2017

Thanks for the reply Brad. Yes, this is causing issues. Rendering stops completely. Is it possible to somehow handle the exception? Adding the check allows the app to render normally.

@BSick7
Copy link
Member

BSick7 commented Mar 14, 2017

Can you send a stack trace of where this is originating?

@dp901
Copy link
Author

dp901 commented Mar 15, 2017

TypeError: Cannot read property 'left' of undefined
at Thickness.copyTo (Thickness.ts:23)
at DependencyProperty.ChangedCallback (UIReaction.ts:42)
at PropertyStore.OnPropertyChanged (PropertyStore.ts:167)
at PropertyStore.ClearValue (PropertyStore.ts:136)
at Border.DependencyObject.ClearValue (DependencyObject.ts:143)

The error is caused when our code calls ClearValue on BorderThickness, Margin or CornerRadius.

@BSick7
Copy link
Member

BSick7 commented Mar 15, 2017

Sorry for that issue.
It would be much more appropriate to adjust in Fayde.

@BSick7
Copy link
Member

BSick7 commented Mar 15, 2017

Closing in favor of wsick/Fayde#271
Thanks again @dp901!

@BSick7 BSick7 closed this Mar 15, 2017
@BSick7
Copy link
Member

BSick7 commented Mar 15, 2017

@dp901 dp901 deleted the patch-2 branch March 15, 2017 14:04
@dp901
Copy link
Author

dp901 commented Mar 15, 2017

Thanks Brad. Does the same fix apply to FrameworkElement MarginProperty?
Same error.

@BSick7
Copy link
Member

BSick7 commented Mar 15, 2017

It is not included. Can you open an issue regarding this in Fayde please?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants