-
Notifications
You must be signed in to change notification settings - Fork 1.4k
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
Various Sample app fixes #1428
Various Sample app fixes #1428
Conversation
@@ -53,7 +53,7 @@ | |||
CompactPaneLength="@[CompactPaneLength:Slider:48:10-80]" | |||
HamburgerHeight="@[HamburgerHeight:Slider:48:10-80]" | |||
HamburgerVisibility="@[HamburgerVisibility:Enum:Visibility.Visible]" | |||
IsPaneOpen="@[IsPaneOpen:Bool:False]"> | |||
IsPaneOpen="@[IsPaneOpen:Bool:False]@"> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There is an additional @ here
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is a new syntax, the end @ signifies that the template should generate it using a TwoWay Binding instead of a OneWay Binding.
@@ -427,7 +454,7 @@ private void NavigationFrameOnNavigated(object sender, NavigationEventArgs navig | |||
this._lastRenderedProperties = true; | |||
|
|||
// Called to load the sample initially as we don't get an Item Pivot Selection Changed with Sample Loaded yet. | |||
UpdateXamlRenderAsync(_currentSample.BindedXamlCode); | |||
var t = UpdateXamlRenderAsync(_currentSample.BindedXamlCode); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
vat t is unused
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
quick workaround to remove the VS warning about calling an async method without await.
@@ -488,7 +515,7 @@ private void HamburgerMenu_OnOptionsItemClick(object sender, ItemClickEventArgs | |||
{ | |||
_lastRenderedProperties = true; | |||
|
|||
UpdateXamlRenderAsync(_currentSample.BindedXamlCode); | |||
var t = UpdateXamlRenderAsync(_currentSample.BindedXamlCode); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
vat t is unused
@@ -502,8 +529,8 @@ private void HamburgerMenu_OnOptionsItemClick(object sender, ItemClickEventArgs | |||
// If we switch to the Live Preview, then we want to use the Value based Text | |||
XamlCodeRenderer.Text = _currentSample.UpdatedXamlCode; | |||
|
|||
UpdateXamlRenderAsync(_currentSample.UpdatedXamlCode); | |||
|
|||
var t = UpdateXamlRenderAsync(_currentSample.UpdatedXamlCode); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
vat t is unused
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why also almost all usages of UpdateXamlRenderAsync is fire and forgot why not awaited ?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We don't need the result, it's just to reload the rendering
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
some questions
var code = string.Empty; | ||
if (_currentSample.PropertyDescriptor != null && | ||
_currentSample.PropertyDescriptor.Options.Count > 0 && | ||
InfoAreaPivot.SelectedIndex == 0) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Use the SelectedItem syntax like we use elsewhere?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Good point, fixed
_currentSample.PropertyDescriptor.Options.Count > 0 && | ||
InfoAreaPivot.SelectedIndex == 0) | ||
{ | ||
code = _currentSample.BindedXamlCode + " "; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What's the extra space for?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nothing, removed (I was trying something and forgot to remove)
No description provided.