-
Notifications
You must be signed in to change notification settings - Fork 14
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Added first iteration of ErrorWindow
- Loading branch information
Showing
12 changed files
with
846 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,86 @@ | ||
<?xml version="1.0" encoding="utf-8"?> | ||
<Project ToolsVersion="15.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003"> | ||
<Import Project="$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props" Condition="Exists('$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props')" /> | ||
<PropertyGroup> | ||
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration> | ||
<Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform> | ||
<ProjectGuid>{19BA0777-B414-4C19-9E73-47D6B1B78AF8}</ProjectGuid> | ||
<OutputType>Library</OutputType> | ||
<AppDesignerFolder>Properties</AppDesignerFolder> | ||
<RootNamespace>Arma.Studio.ErrorWindow</RootNamespace> | ||
<AssemblyName>Arma.Studio.ErrorWindow</AssemblyName> | ||
<TargetFrameworkVersion>v4.6.1</TargetFrameworkVersion> | ||
<FileAlignment>512</FileAlignment> | ||
<Deterministic>true</Deterministic> | ||
</PropertyGroup> | ||
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' "> | ||
<DebugSymbols>true</DebugSymbols> | ||
<DebugType>full</DebugType> | ||
<Optimize>false</Optimize> | ||
<OutputPath>bin\Debug\</OutputPath> | ||
<DefineConstants>DEBUG;TRACE</DefineConstants> | ||
<ErrorReport>prompt</ErrorReport> | ||
<WarningLevel>4</WarningLevel> | ||
</PropertyGroup> | ||
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' "> | ||
<DebugType>pdbonly</DebugType> | ||
<Optimize>true</Optimize> | ||
<OutputPath>bin\Release\</OutputPath> | ||
<DefineConstants>TRACE</DefineConstants> | ||
<ErrorReport>prompt</ErrorReport> | ||
<WarningLevel>4</WarningLevel> | ||
</PropertyGroup> | ||
<ItemGroup> | ||
<Reference Include="PresentationCore" /> | ||
<Reference Include="PresentationFramework" /> | ||
<Reference Include="System" /> | ||
<Reference Include="System.Core" /> | ||
<Reference Include="System.Xaml" /> | ||
<Reference Include="System.Xml.Linq" /> | ||
<Reference Include="System.Data.DataSetExtensions" /> | ||
<Reference Include="Microsoft.CSharp" /> | ||
<Reference Include="System.Data" /> | ||
<Reference Include="System.Net.Http" /> | ||
<Reference Include="System.Xml" /> | ||
<Reference Include="WindowsBase" /> | ||
</ItemGroup> | ||
<ItemGroup> | ||
<Compile Include="ErrorWindowDataContext.cs" /> | ||
<Compile Include="PluginMain.cs" /> | ||
<Compile Include="Properties\AssemblyInfo.cs" /> | ||
<Compile Include="Properties\Language.Designer.cs"> | ||
<AutoGen>True</AutoGen> | ||
<DesignTime>True</DesignTime> | ||
<DependentUpon>Language.resx</DependentUpon> | ||
</Compile> | ||
</ItemGroup> | ||
<ItemGroup> | ||
<EmbeddedResource Include="ErrorWindow.xaml"> | ||
<Generator>MSBuild:Compile</Generator> | ||
<SubType>Designer</SubType> | ||
</EmbeddedResource> | ||
<EmbeddedResource Include="Properties\Language.resx"> | ||
<Generator>PublicResXFileCodeGenerator</Generator> | ||
<LastGenOutput>Language.Designer.cs</LastGenOutput> | ||
</EmbeddedResource> | ||
</ItemGroup> | ||
<ItemGroup> | ||
<ProjectReference Include="..\Arma.Studio.Data\Arma.Studio.Data.csproj"> | ||
<Project>{05a55f19-86ee-46a1-875a-15bbfe31a4ab}</Project> | ||
<Name>Arma.Studio.Data</Name> | ||
</ProjectReference> | ||
</ItemGroup> | ||
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" /> | ||
<PropertyGroup> | ||
<PostBuildEvent> | ||
if not exist "$(SolutionDir)Arma.Studio\$(OutDir)Plugins" mkdir ""$(SolutionDir)Arma.Studio\$(OutDir)Plugins"" | ||
if not exist "$(SolutionDir)Arma.Studio\$(OutDir)Plugins\ErrorWindow" mkdir ""$(SolutionDir)Arma.Studio\$(OutDir)Plugins\ErrorWindow"" | ||
xcopy /Y "$(TargetDir)*" "$(SolutionDir)Arma.Studio\$(OutDir)Plugins\ErrorWindow" | ||
( | ||
echo ^<plugin^> | ||
echo ^<library^>$(TargetFileName)^</library^> | ||
echo ^</plugin^> | ||
) > "$(SolutionDir)Arma.Studio\$(OutDir)Plugins\ErrorWindow\plugin.xml" | ||
</PostBuildEvent> | ||
</PropertyGroup> | ||
</Project> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,191 @@ | ||
<DataTemplate xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" | ||
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" | ||
xmlns:d="http://schemas.microsoft.com/expression/blend/2008" | ||
xmlns:asd="http://schemas.armastudio.io/data" | ||
xmlns:xceed="http://schemas.xceed.com/wpf/xaml/toolkit" | ||
xmlns:text="clr-namespace:System.Text;assembly=mscorlib" | ||
xmlns:local="clr-namespace:Arma.Studio.ErrorWindow;assembly=Arma.Studio.ErrorWindow" | ||
xmlns:p="clr-namespace:Arma.Studio.ErrorWindow.Properties;assembly=Arma.Studio.ErrorWindow" | ||
DataType="{x:Type local:ErrorWindowDataContext}"> | ||
<Grid> | ||
<Grid.RowDefinitions> | ||
<RowDefinition Height="Auto"/> | ||
<RowDefinition Height="*"/> | ||
</Grid.RowDefinitions> | ||
<StackPanel Grid.Row="0" ToolBarTray.IsLocked="True" Orientation="Horizontal" Margin="4"> | ||
<StackPanel.Resources> | ||
<Style TargetType="ToggleButton"> | ||
<Setter Property="Template"> | ||
<Setter.Value> | ||
<ControlTemplate TargetType="ToggleButton"> | ||
<Border BorderBrush="{TemplateBinding BorderBrush}" Background="{TemplateBinding Background}" BorderThickness="{TemplateBinding BorderThickness}" Padding="{TemplateBinding Padding}"> | ||
<ContentPresenter/> | ||
</Border> | ||
</ControlTemplate> | ||
</Setter.Value> | ||
</Setter> | ||
<Setter Property="BorderThickness" Value="0"/> | ||
<Setter Property="Margin" Value="1"/> | ||
<Setter Property="BorderBrush" Value="#007ACC"/> | ||
<Setter Property="Background" Value="Transparent"/> | ||
<Setter Property="Padding" Value="2"/> | ||
<Style.Triggers> | ||
<Trigger Property="IsChecked" Value="True"> | ||
<Setter Property="BorderThickness" Value="1"/> | ||
<Setter Property="Margin" Value="0"/> | ||
<Setter Property="Background" Value="Transparent"/> | ||
</Trigger> | ||
</Style.Triggers> | ||
</Style> | ||
<Style TargetType="Separator"> | ||
<Setter Property="Margin" Value="4 0"/> | ||
<Setter Property="LayoutTransform"> | ||
<Setter.Value> | ||
<TransformGroup> | ||
<TransformGroup.Children> | ||
<TransformCollection> | ||
<RotateTransform Angle="90"/> | ||
</TransformCollection> | ||
</TransformGroup.Children> | ||
</TransformGroup> | ||
</Setter.Value> | ||
</Setter> | ||
</Style> | ||
</StackPanel.Resources> | ||
<ToggleButton IsChecked="{Binding IsErrorsDisplayed}"> | ||
<Grid> | ||
<Grid.ColumnDefinitions> | ||
<ColumnDefinition/> | ||
<ColumnDefinition/> | ||
</Grid.ColumnDefinitions> | ||
<Rectangle Grid.Column="0" Width="16" Height="16" Fill="{StaticResource DrawingBrushStatusCriticalError}"/> | ||
<StackPanel Grid.Column="1" Orientation="Horizontal"> | ||
<TextBlock Margin="4 0"> | ||
<TextBlock.Style> | ||
<Style TargetType="TextBlock"> | ||
<Setter Property="Text" Value="{x:Static p:Language.Errors}"/> | ||
<Style.Triggers> | ||
<DataTrigger Binding="{Binding CurrentErrorCount}" Value="1"> | ||
<Setter Property="Text" Value="{x:Static p:Language.Error}"/> | ||
</DataTrigger> | ||
</Style.Triggers> | ||
</Style> | ||
</TextBlock.Style> | ||
</TextBlock> | ||
<TextBlock Text="("/> | ||
<TextBlock Text="{Binding CurrentErrorCount}"/> | ||
<TextBlock Text=")"/> | ||
</StackPanel> | ||
</Grid> | ||
</ToggleButton> | ||
<Separator/> | ||
<ToggleButton IsChecked="{Binding IsWarningsDisplayed, FallbackValue=true}"> | ||
<Grid> | ||
<Grid.ColumnDefinitions> | ||
<ColumnDefinition/> | ||
<ColumnDefinition/> | ||
</Grid.ColumnDefinitions> | ||
<Rectangle Grid.Column="0" Width="16" Height="16" Fill="{StaticResource DrawingBrushStatusWarning}"/> | ||
<StackPanel Grid.Column="1" Orientation="Horizontal"> | ||
<TextBlock Margin="4 0"> | ||
<TextBlock.Style> | ||
<Style TargetType="TextBlock"> | ||
<Setter Property="Text" Value="{x:Static p:Language.Warnings}"/> | ||
<Style.Triggers> | ||
<DataTrigger Binding="{Binding CurrentWarningCount}" Value="1"> | ||
<Setter Property="Text" Value="{x:Static p:Language.Warning}"/> | ||
</DataTrigger> | ||
</Style.Triggers> | ||
</Style> | ||
</TextBlock.Style> | ||
</TextBlock> | ||
<TextBlock Text="("/> | ||
<TextBlock Text="{Binding CurrentWarningCount}"/> | ||
<TextBlock Text=")"/> | ||
</StackPanel> | ||
</Grid> | ||
</ToggleButton> | ||
<Separator/> | ||
<ToggleButton IsChecked="{Binding IsInfosDisplayed}"> | ||
<Grid> | ||
<Grid.ColumnDefinitions> | ||
<ColumnDefinition/> | ||
<ColumnDefinition/> | ||
</Grid.ColumnDefinitions> | ||
<Rectangle Grid.Column="0" Width="16" Height="16" Fill="{StaticResource DrawingBrushStatusInformation}"/> | ||
<StackPanel Grid.Column="1" Orientation="Horizontal"> | ||
<TextBlock Margin="4 0"> | ||
<TextBlock.Style> | ||
<Style TargetType="TextBlock"> | ||
<Setter Property="Text" Value="{x:Static p:Language.Infos}"/> | ||
<Style.Triggers> | ||
<DataTrigger Binding="{Binding CurrentInfoCount}" Value="1"> | ||
<Setter Property="Text" Value="{x:Static p:Language.Info}"/> | ||
</DataTrigger> | ||
</Style.Triggers> | ||
</Style> | ||
</TextBlock.Style> | ||
</TextBlock> | ||
<TextBlock Text="("/> | ||
<TextBlock Text="{Binding CurrentInfoCount}"/> | ||
<TextBlock Text=")"/> | ||
</StackPanel> | ||
</Grid> | ||
</ToggleButton> | ||
</StackPanel> | ||
<ListView Grid.Row="1" ItemsSource="{Binding LintInfos}"> | ||
<ListView.ItemContainerStyle> | ||
<Style TargetType="ListViewItem"> | ||
<Setter Property="Template"> | ||
<Setter.Value> | ||
<ControlTemplate TargetType="ListViewItem"> | ||
<Border Background="{TemplateBinding Background}" BorderBrush="{TemplateBinding BorderBrush}" BorderThickness="{TemplateBinding BorderThickness}" Padding="0 4"> | ||
<GridViewRowPresenter/> | ||
</Border> | ||
</ControlTemplate> | ||
</Setter.Value> | ||
</Setter> | ||
<Setter Property="asd:MouseDoubleClick.Command" Value="{Binding DataContext.CmdEntryOnDoubleClick, RelativeSource={RelativeSource AncestorType=ListView, Mode=FindAncestor}}"/> | ||
<Setter Property="asd:MouseDoubleClick.CommandParameter" Value="{Binding}"/> | ||
<Style.Triggers> | ||
<Trigger Property="IsSelected" Value="True"> | ||
<Setter Property="Background" Value="LightBlue"/> | ||
</Trigger> | ||
</Style.Triggers> | ||
</Style> | ||
</ListView.ItemContainerStyle> | ||
<ListView.View> | ||
<GridView> | ||
<GridViewColumn> | ||
<GridViewColumn.CellTemplate> | ||
<DataTemplate> | ||
<Rectangle Height="16" Width="16"> | ||
<Rectangle.Style> | ||
<Style TargetType="Rectangle"> | ||
<Setter Property="Fill" Value="{StaticResource DrawingBrushStatusInformation}"/> | ||
<Setter Property="ToolTip" Value="{x:Static p:Language.Info}"/> | ||
<Style.Triggers> | ||
<DataTrigger Binding="{Binding Severity}" Value="{x:Static asd:ESeverity.Error}"> | ||
<Setter Property="Fill" Value="{StaticResource DrawingBrushStatusCriticalError}"/> | ||
<Setter Property="ToolTip" Value="{x:Static p:Language.Error}"/> | ||
</DataTrigger> | ||
<DataTrigger Binding="{Binding Severity}" Value="{x:Static asd:ESeverity.Warning}"> | ||
<Setter Property="Fill" Value="{StaticResource DrawingBrushStatusWarning}"/> | ||
<Setter Property="ToolTip" Value="{x:Static p:Language.Warning}"/> | ||
</DataTrigger> | ||
</Style.Triggers> | ||
</Style> | ||
</Rectangle.Style> | ||
</Rectangle> | ||
</DataTemplate> | ||
</GridViewColumn.CellTemplate> | ||
</GridViewColumn> | ||
<GridViewColumn Header="{x:Static p:Language.Line}" DisplayMemberBinding="{Binding Line}"/> | ||
<GridViewColumn Header="{x:Static p:Language.Column}" DisplayMemberBinding="{Binding Column}"/> | ||
<GridViewColumn Header="{x:Static p:Language.Description}" DisplayMemberBinding="{Binding Description}"/> | ||
<GridViewColumn Header="{x:Static p:Language.File}" DisplayMemberBinding="{Binding File}" Width="512"/> | ||
</GridView> | ||
</ListView.View> | ||
</ListView> | ||
</Grid> | ||
</DataTemplate> |
Oops, something went wrong.