1
0
mirror of https://github.com/fadden/6502bench.git synced 2024-06-13 14:29:30 +00:00

Fix setting of IsLongComment

This commit is contained in:
Andy McFadden 2019-06-04 13:06:24 -07:00
parent da825d3114
commit 9bbaa80570
2 changed files with 3 additions and 9 deletions

View File

@ -310,13 +310,6 @@ namespace SourceGenWPF {
return parts;
}
public static FormattedParts Create(string longComment) {
FormattedParts parts = new FormattedParts();
parts.Comment = longComment;
parts.IsLongComment = true;
return parts;
}
public static FormattedParts CreateBlankLine() {
FormattedParts parts = new FormattedParts();
return parts;
@ -325,6 +318,7 @@ namespace SourceGenWPF {
public static FormattedParts CreateLongComment(string comment) {
FormattedParts parts = new FormattedParts();
parts.Comment = comment;
parts.IsLongComment = true;
return parts;
}

View File

@ -72,7 +72,7 @@ See also https://github.com/fadden/DisasmUiTest
<!-- Template for long lines. This is a modification of the default style, with
Content and Columns attributes defined in the GridViewRowPresenter. It appears we
inherit the FocusVisualStyle from the default. -->
<ControlTemplate x:Key="longComment" TargetType="{x:Type ListViewItem}">
<ControlTemplate x:Key="longCommentTemplate" TargetType="{x:Type ListViewItem}">
<StackPanel>
<Border BorderBrush="{TemplateBinding BorderBrush}"
BorderThickness="{TemplateBinding BorderThickness}"
@ -135,7 +135,7 @@ See also https://github.com/fadden/DisasmUiTest
<Style x:Key="codeListItemStyle" TargetType="{x:Type ListViewItem}">
<Style.Triggers>
<DataTrigger Binding="{Binding Path=IsLongComment}" Value="True">
<Setter Property="Template" Value="{StaticResource longComment}"/>
<Setter Property="Template" Value="{StaticResource longCommentTemplate}"/>
</DataTrigger>
</Style.Triggers>
</Style>