Subversion Repositories Projects

Compare Revisions

Ignore whitespace Rev 2349 → Rev 2350

/MKLiveView/v1.0/Source/MKLiveView.csproj
9,11 → 9,14
<AppDesignerFolder>Properties</AppDesignerFolder>
<RootNamespace>MKLiveView</RootNamespace>
<AssemblyName>MKLiveView</AssemblyName>
<TargetFrameworkVersion>v4.5.2</TargetFrameworkVersion>
<TargetFrameworkVersion>v4.5</TargetFrameworkVersion>
<FileAlignment>512</FileAlignment>
<ProjectTypeGuids>{60dc8134-eba5-43b8-bcc9-bb4bc16c2548};{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}</ProjectTypeGuids>
<WarningLevel>4</WarningLevel>
<AutoGenerateBindingRedirects>true</AutoGenerateBindingRedirects>
<IsWebBootstrapper>false</IsWebBootstrapper>
<TargetFrameworkProfile>
</TargetFrameworkProfile>
<PublishUrl>publish\</PublishUrl>
<Install>true</Install>
<InstallFrom>Disk</InstallFrom>
26,7 → 29,6
<MapFileExtensions>true</MapFileExtensions>
<ApplicationRevision>0</ApplicationRevision>
<ApplicationVersion>1.0.0.%2a</ApplicationVersion>
<IsWebBootstrapper>false</IsWebBootstrapper>
<UseApplicationTrust>false</UseApplicationTrust>
<BootstrapperEnabled>true</BootstrapperEnabled>
</PropertyGroup>
39,6 → 41,8
<DefineConstants>DEBUG;TRACE</DefineConstants>
<ErrorReport>prompt</ErrorReport>
<WarningLevel>4</WarningLevel>
<Prefer32Bit>true</Prefer32Bit>
<AllowUnsafeBlocks>true</AllowUnsafeBlocks>
</PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">
<PlatformTarget>AnyCPU</PlatformTarget>
48,11 → 52,13
<DefineConstants>TRACE</DefineConstants>
<ErrorReport>prompt</ErrorReport>
<WarningLevel>4</WarningLevel>
<Prefer32Bit>false</Prefer32Bit>
</PropertyGroup>
<PropertyGroup>
<ApplicationIcon>MK.ico</ApplicationIcon>
</PropertyGroup>
<ItemGroup>
<Reference Include="Microsoft.Windows.Shell, Version=3.5.41019.1, Culture=neutral, PublicKeyToken=31bf3856ad364e35, processorArchitecture=MSIL" />
<Reference Include="System" />
<Reference Include="System.Data" />
<Reference Include="System.Drawing" />
87,12 → 93,10
<Compile Include="GMapCustomMarkers\CustomMarkerCopter.xaml.cs">
<DependentUpon>CustomMarkerCopter.xaml</DependentUpon>
</Compile>
<Compile Include="GMapCustomMarkers\CustomMarkerWPActive.xaml.cs">
<DependentUpon>CustomMarkerWPActive.xaml</DependentUpon>
</Compile>
<Compile Include="GMapCustomMarkers\CustomMarkerWP.xaml.cs">
<DependentUpon>CustomMarkerWP.xaml</DependentUpon>
</Compile>
<Compile Include="GMapCustomMarkers\CustomMarkerWPActive.xaml.cs" />
<Compile Include="SerialPortCtrl.xaml.cs">
<DependentUpon>SerialPortCtrl.xaml</DependentUpon>
</Compile>
109,11 → 113,11
<Generator>MSBuild:Compile</Generator>
<SubType>Designer</SubType>
</Page>
<Page Include="GMapCustomMarkers\CustomMarkerWPActive.xaml">
<Page Include="GMapCustomMarkers\CustomMarkerWP.xaml">
<Generator>MSBuild:Compile</Generator>
<SubType>Designer</SubType>
</Page>
<Page Include="GMapCustomMarkers\CustomMarkerWP.xaml">
<Page Include="GMapCustomMarkers\CustomMarkerWPActive.xaml">
<Generator>MSBuild:Compile</Generator>
<SubType>Designer</SubType>
</Page>
175,6 → 179,9
<Resource Include="GMapCustomMarkers\home.png" />
</ItemGroup>
<ItemGroup>
<Resource Include="GMapCustomMarkers\CopterRed.png" />
</ItemGroup>
<ItemGroup>
<Resource Include="ArtificialHorizon\horizon.png" />
<Resource Include="ArtificialHorizon\wings.png" />
</ItemGroup>
309,19 → 316,19
<Resource Include="Images\LoadFile.png" />
</ItemGroup>
<ItemGroup>
<Resource Include="Images\DeleteCopterList.png" />
<Resource Include="GMapCustomMarkers\CopterBlue.png" />
<Resource Include="GMapCustomMarkers\CopterGreen.png" />
<Resource Include="GMapCustomMarkers\CopterPink.png" />
<Resource Include="GMapCustomMarkers\CopterYellow.png" />
</ItemGroup>
<ItemGroup>
<Resource Include="Images\DeleteList.png" />
</ItemGroup>
<ItemGroup>
<Resource Include="GMapCustomMarkers\CopterBlue.png" />
<Resource Include="GMapCustomMarkers\CopterGreen.png" />
<Resource Include="GMapCustomMarkers\CopterPink.png" />
<Resource Include="GMapCustomMarkers\CopterYellow.png" />
<Resource Include="Images\DeleteCopterList.png" />
</ItemGroup>
<ItemGroup>
<Resource Include="GMapCustomMarkers\CopterRed.png" />
<Resource Include="Images\SaveFile.png" />
</ItemGroup>
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
<!-- To modify your build process, add your task inside one of the targets below and uncomment it.
/MKLiveView/v1.0/Source/MainWindow.xaml
585,7 → 585,7
</Label.Style>
</Label>
</Grid>
<Grid x:Name="GridData" Background="#7F000000" HorizontalAlignment="Left" Width="204" Margin="23,36,0,0" >
<Grid x:Name="GridData" Background="#7F000000" HorizontalAlignment="Left" Width="204" Margin="23,36,0,0" Visibility="Collapsed" >
<TabControl x:Name="tabControl" HorizontalAlignment="Left" Height="619" VerticalAlignment="Top" Width="200" Background="{x:Null}" Margin="2,0,0,0">
<TabItem Header="Analog">
<Grid>
664,10 → 664,10
</TabItem>
<TabItem Header="Serial" HorizontalAlignment="Left" Height="20" VerticalAlignment="Top" Width="54" Margin="-1,0,0,0">
<Grid>
<GroupBox x:Name="groupBox3" Header="Channel 1" HorizontalAlignment="Left" Height="206" VerticalAlignment="Top" Width="194" Foreground="White" BorderThickness="0.5" Margin="0,31,0,0">
<GroupBox x:Name="groupBox3" Header="Channel 1" HorizontalAlignment="Left" Height="188" VerticalAlignment="Top" Width="194" Foreground="White" BorderThickness="0.5">
<Grid Margin="0,0,-2,0.04">
<TextBox x:Name="textBoxSerial1" HorizontalAlignment="Left" Height="21" Margin="6,10,0,0" Text="SerialChannel1 description" VerticalAlignment="Top" Width="146" Background="{x:Null}" Foreground="White" UndoLimit="0" IsUndoEnabled="False" MaxLines="1" MaxLength="24" TextChanged="textBoxSerial1_TextChanged"/>
<Label x:Name="labelSerChan1" HorizontalAlignment="Left" Margin="157,12,0,0" VerticalAlignment="Top" Foreground="White" Padding="0" Width="24" Content="{Binding Value, ElementName=SerChan1ScaleSlider}">
<TextBox x:Name="textBoxSerial1" HorizontalAlignment="Left" Height="21" Margin="6,3,0,0" Text="SerialChannel1 description" VerticalAlignment="Top" Width="146" Background="{x:Null}" Foreground="White" UndoLimit="0" IsUndoEnabled="False" MaxLines="1" MaxLength="24" TextChanged="textBoxSerial1_TextChanged"/>
<Label x:Name="labelSerChan1" HorizontalAlignment="Left" Margin="157,5,0,0" VerticalAlignment="Top" Foreground="White" Padding="0" Width="24" Content="{Binding Value, ElementName=SerChan1ScaleSlider}">
<Label.Style>
<Style TargetType="{x:Type Label}">
<Style.Triggers>
678,14 → 678,14
</Style>
</Label.Style>
</Label>
<Slider x:Name="SerChan1ScaleSlider" HorizontalAlignment="Left" Height="29" Margin="4,35,0,0" VerticalAlignment="Top" Width="177" Maximum="254" FontSize="20" Style="{DynamicResource TouchSliderStyle}" SmallChange="0.001" ValueChanged="SerChan1ScaleSlider_ValueChanged"/>
<Button x:Name="btnSer1_0" Content="0" HorizontalAlignment="Left" Height="35" Margin="2,69,0,0" VerticalAlignment="Top" Width="58" FontSize="14" Click="btnSer1_0_Click"/>
<Button x:Name="btnSer1_127" Content="127" HorizontalAlignment="Left" Height="35" Margin="62,69,0,0" VerticalAlignment="Top" Width="58" FontSize="14" Click="btnSer1_127_Click"/>
<Button x:Name="btnSer1_254" Content="254" HorizontalAlignment="Left" Height="35" Margin="122,69,0,0" VerticalAlignment="Top" Width="58" FontSize="14" Click="btnSer1_254_Click"/>
<TextBox x:Name="textBoxSerial1_val1" HorizontalAlignment="Left" Height="29" Margin="2,111,0,0" TextWrapping="Wrap" Text="0" VerticalAlignment="Top" Width="58" MaxLines="1" MaxLength="3" IsUndoEnabled="False" FontSize="14" VerticalContentAlignment="Center" HorizontalContentAlignment="Center" KeyUp="textBox_serial_KeyPress" TextChanged="textBoxSerial1_val1_TextChanged"/>
<TextBox x:Name="textBoxSerial1_val2" HorizontalAlignment="Left" Height="29" Margin="62,111,0,0" TextWrapping="Wrap" Text="0" VerticalAlignment="Top" Width="58" MaxLines="1" MaxLength="3" IsUndoEnabled="False" FontSize="14" VerticalContentAlignment="Center" HorizontalContentAlignment="Center" KeyUp="textBox_serial_KeyPress" TextChanged="textBoxSerial1_val2_TextChanged"/>
<TextBox x:Name="textBoxSerial1_val3" HorizontalAlignment="Left" Height="29" Margin="122,111,0,0" TextWrapping="Wrap" Text="0" VerticalAlignment="Top" Width="58" MaxLines="1" MaxLength="3" IsUndoEnabled="False" FontSize="14" VerticalContentAlignment="Center" HorizontalContentAlignment="Center" KeyUp="textBox_serial_KeyPress" TextChanged="textBoxSerial1_val3_TextChanged"/>
<Button x:Name="btnSer1_val1" Content="{Binding Text, ElementName=textBoxSerial1_val1}" HorizontalAlignment="Left" Height="35" Margin="2,143,0,0" VerticalAlignment="Top" Width="58" FontSize="14" Click="btnSer1_val1_Click">
<Slider x:Name="SerChan1ScaleSlider" HorizontalAlignment="Left" Height="29" Margin="4,29,0,0" VerticalAlignment="Top" Width="177" Maximum="254" FontSize="20" Style="{DynamicResource TouchSliderStyle}" SmallChange="0.001" ValueChanged="SerChan1ScaleSlider_ValueChanged" IsSnapToTickEnabled="True"/>
<Button x:Name="btnSer1_0" Content="0" HorizontalAlignment="Left" Height="35" Margin="2,57,0,0" VerticalAlignment="Top" Width="58" FontSize="14" Click="btnSer1_0_Click"/>
<Button x:Name="btnSer1_127" Content="127" HorizontalAlignment="Left" Height="35" Margin="62,57,0,0" VerticalAlignment="Top" Width="58" FontSize="14" Click="btnSer1_127_Click"/>
<Button x:Name="btnSer1_254" Content="254" HorizontalAlignment="Left" Height="35" Margin="122,57,0,0" VerticalAlignment="Top" Width="58" FontSize="14" Click="btnSer1_254_Click"/>
<TextBox x:Name="textBoxSerial1_val1" HorizontalAlignment="Left" Height="29" Margin="2,96,0,0" TextWrapping="Wrap" Text="0" VerticalAlignment="Top" Width="58" MaxLines="1" MaxLength="3" IsUndoEnabled="False" FontSize="14" VerticalContentAlignment="Center" HorizontalContentAlignment="Center" KeyUp="textBox_serial_KeyPress" TextChanged="textBoxSerial1_val1_TextChanged"/>
<TextBox x:Name="textBoxSerial1_val2" HorizontalAlignment="Left" Height="29" Margin="62,96,0,0" TextWrapping="Wrap" Text="0" VerticalAlignment="Top" Width="58" MaxLines="1" MaxLength="3" IsUndoEnabled="False" FontSize="14" VerticalContentAlignment="Center" HorizontalContentAlignment="Center" KeyUp="textBox_serial_KeyPress" TextChanged="textBoxSerial1_val2_TextChanged"/>
<TextBox x:Name="textBoxSerial1_val3" HorizontalAlignment="Left" Height="29" Margin="122,96,0,0" TextWrapping="Wrap" Text="0" VerticalAlignment="Top" Width="58" MaxLines="1" MaxLength="3" IsUndoEnabled="False" FontSize="14" VerticalContentAlignment="Center" HorizontalContentAlignment="Center" KeyUp="textBox_serial_KeyPress" TextChanged="textBoxSerial1_val3_TextChanged"/>
<Button x:Name="btnSer1_val1" Content="{Binding Text, ElementName=textBoxSerial1_val1}" HorizontalAlignment="Left" Height="35" Margin="2,128,0,0" VerticalAlignment="Top" Width="58" FontSize="14" Click="btnSer1_val1_Click">
<Button.Style>
<Style TargetType="{x:Type Button}">
<Style.Triggers>
694,7 → 694,7
</Style>
</Button.Style>
</Button>
<Button x:Name="btnSer1_val2" Content="{Binding Text, ElementName=textBoxSerial1_val2}" HorizontalAlignment="Left" Height="35" Margin="62,143,0,0" VerticalAlignment="Top" Width="58" FontSize="14" Click="btnSer1_val2_Click">
<Button x:Name="btnSer1_val2" Content="{Binding Text, ElementName=textBoxSerial1_val2}" HorizontalAlignment="Left" Height="35" Margin="62,128,0,0" VerticalAlignment="Top" Width="58" FontSize="14" Click="btnSer1_val2_Click">
<Button.Style>
<Style TargetType="{x:Type Button}">
<Style.Triggers>
703,7 → 703,7
</Style>
</Button.Style>
</Button>
<Button x:Name="btnSer1_val3" Content="{Binding Text, ElementName=textBoxSerial1_val3}" HorizontalAlignment="Left" Height="35" Margin="122,143,0,0" VerticalAlignment="Top" Width="58" FontSize="14" Click="btnSer1_val3_Click">
<Button x:Name="btnSer1_val3" Content="{Binding Text, ElementName=textBoxSerial1_val3}" HorizontalAlignment="Left" Height="35" Margin="122,128,0,0" VerticalAlignment="Top" Width="58" FontSize="14" Click="btnSer1_val3_Click">
<Button.Style>
<Style TargetType="{x:Type Button}">
<Style.Triggers>
715,10 → 715,10
 
</Grid>
</GroupBox>
<GroupBox x:Name="groupBoxSerchan2" Header="Channel 2" HorizontalAlignment="Left" Height="206" VerticalAlignment="Top" Width="194" Foreground="White" BorderThickness="0.5" Margin="0,277,0,0">
<GroupBox x:Name="groupBoxSerchan2" Header="Channel 2" HorizontalAlignment="Left" Height="193" VerticalAlignment="Top" Width="194" Foreground="White" BorderThickness="0.5" Margin="0,193,0,0">
<Grid Margin="0,0,-2,0.04">
<TextBox x:Name="textBoxSerial2" HorizontalAlignment="Left" Height="21" Margin="6,10,0,0" Text="SerialChannel2 description" VerticalAlignment="Top" Width="146" Background="{x:Null}" Foreground="White" UndoLimit="0" IsUndoEnabled="False" MaxLines="1" MaxLength="24" TextChanged="textBoxSerial2_TextChanged"/>
<Label x:Name="labelSerChan2" HorizontalAlignment="Left" Margin="157,12,0,0" VerticalAlignment="Top" Foreground="White" Padding="0" Width="24" Content="{Binding Value, ElementName=SerChan2ScaleSlider}">
<TextBox x:Name="textBoxSerial2" HorizontalAlignment="Left" Height="21" Margin="6,3,0,0" Text="SerialChannel2 description" VerticalAlignment="Top" Width="146" Background="{x:Null}" Foreground="White" UndoLimit="0" IsUndoEnabled="False" MaxLines="1" MaxLength="24" TextChanged="textBoxSerial2_TextChanged"/>
<Label x:Name="labelSerChan2" HorizontalAlignment="Left" Margin="157,5,0,0" VerticalAlignment="Top" Foreground="White" Padding="0" Width="24" Content="{Binding Value, ElementName=SerChan2ScaleSlider}">
<Label.Style>
<Style TargetType="{x:Type Label}">
<Style.Triggers>
729,14 → 729,14
</Style>
</Label.Style>
</Label>
<Slider x:Name="SerChan2ScaleSlider" HorizontalAlignment="Left" Height="29" Margin="4,35,0,0" VerticalAlignment="Top" Width="177" Maximum="254" FontSize="20" Style="{DynamicResource TouchSliderStyle}" SmallChange="0.001" ValueChanged="SerChan2ScaleSlider_ValueChanged"/>
<Button x:Name="btnSer2_0" Content="0" HorizontalAlignment="Left" Height="35" Margin="2,69,0,0" VerticalAlignment="Top" Width="58" FontSize="14" Click="btnSer2_0_Click"/>
<Button x:Name="btnSer2_127" Content="127" HorizontalAlignment="Left" Height="35" Margin="62,69,0,0" VerticalAlignment="Top" Width="58" FontSize="14" Click="btnSer2_127_Click"/>
<Button x:Name="btnSer2_254" Content="254" HorizontalAlignment="Left" Height="35" Margin="122,69,0,0" VerticalAlignment="Top" Width="58" FontSize="14" Click="btnSer2_254_Click"/>
<TextBox x:Name="textBoxSerial2_val1" HorizontalAlignment="Left" Height="29" Margin="2,111,0,0" TextWrapping="Wrap" Text="0" VerticalAlignment="Top" Width="58" MaxLines="1" MaxLength="3" IsUndoEnabled="False" FontSize="14" VerticalContentAlignment="Center" HorizontalContentAlignment="Center" KeyUp="textBox_serial_KeyPress" TextChanged="textBoxSerial2_val1_TextChanged"/>
<TextBox x:Name="textBoxSerial2_val2" HorizontalAlignment="Left" Height="29" Margin="62,111,0,0" TextWrapping="Wrap" Text="0" VerticalAlignment="Top" Width="58" MaxLines="1" MaxLength="3" IsUndoEnabled="False" FontSize="14" VerticalContentAlignment="Center" HorizontalContentAlignment="Center" KeyUp="textBox_serial_KeyPress" TextChanged="textBoxSerial2_val2_TextChanged"/>
<TextBox x:Name="textBoxSerial2_val3" HorizontalAlignment="Left" Height="29" Margin="122,111,0,0" TextWrapping="Wrap" Text="0" VerticalAlignment="Top" Width="58" MaxLines="1" MaxLength="3" IsUndoEnabled="False" FontSize="14" VerticalContentAlignment="Center" HorizontalContentAlignment="Center" KeyUp="textBox_serial_KeyPress" TextChanged="textBoxSerial2_val3_TextChanged"/>
<Button x:Name="btnSer2_val1" Content="{Binding Text, ElementName=textBoxSerial2_val1}" HorizontalAlignment="Left" Height="35" Margin="2,143,0,0" VerticalAlignment="Top" Width="58" FontSize="14" Click="btnSer2_val1_Click">
<Slider x:Name="SerChan2ScaleSlider" HorizontalAlignment="Left" Height="29" Margin="4,29,0,0" VerticalAlignment="Top" Width="177" Maximum="254" FontSize="20" Style="{DynamicResource TouchSliderStyle}" SmallChange="0.001" ValueChanged="SerChan2ScaleSlider_ValueChanged" IsSnapToTickEnabled="True"/>
<Button x:Name="btnSer2_0" Content="0" HorizontalAlignment="Left" Height="35" Margin="2,57,0,0" VerticalAlignment="Top" Width="58" FontSize="14" Click="btnSer2_0_Click"/>
<Button x:Name="btnSer2_127" Content="127" HorizontalAlignment="Left" Height="35" Margin="62,57,0,0" VerticalAlignment="Top" Width="58" FontSize="14" Click="btnSer2_127_Click"/>
<Button x:Name="btnSer2_254" Content="254" HorizontalAlignment="Left" Height="35" Margin="122,57,0,0" VerticalAlignment="Top" Width="58" FontSize="14" Click="btnSer2_254_Click"/>
<TextBox x:Name="textBoxSerial2_val1" HorizontalAlignment="Left" Height="29" Margin="2,96,0,0" TextWrapping="Wrap" Text="0" VerticalAlignment="Top" Width="58" MaxLines="1" MaxLength="3" IsUndoEnabled="False" FontSize="14" VerticalContentAlignment="Center" HorizontalContentAlignment="Center" KeyUp="textBox_serial_KeyPress" TextChanged="textBoxSerial2_val1_TextChanged"/>
<TextBox x:Name="textBoxSerial2_val2" HorizontalAlignment="Left" Height="29" Margin="62,96,0,0" TextWrapping="Wrap" Text="0" VerticalAlignment="Top" Width="58" MaxLines="1" MaxLength="3" IsUndoEnabled="False" FontSize="14" VerticalContentAlignment="Center" HorizontalContentAlignment="Center" KeyUp="textBox_serial_KeyPress" TextChanged="textBoxSerial2_val2_TextChanged"/>
<TextBox x:Name="textBoxSerial2_val3" HorizontalAlignment="Left" Height="29" Margin="122,96,0,0" TextWrapping="Wrap" Text="0" VerticalAlignment="Top" Width="58" MaxLines="1" MaxLength="3" IsUndoEnabled="False" FontSize="14" VerticalContentAlignment="Center" HorizontalContentAlignment="Center" KeyUp="textBox_serial_KeyPress" TextChanged="textBoxSerial2_val3_TextChanged"/>
<Button x:Name="btnSer2_val1" Content="{Binding Text, ElementName=textBoxSerial2_val1}" HorizontalAlignment="Left" Height="35" Margin="2,128,0,0" VerticalAlignment="Top" Width="58" FontSize="14" Click="btnSer2_val1_Click">
<Button.Style>
<Style TargetType="{x:Type Button}">
<Style.Triggers>
745,7 → 745,7
</Style>
</Button.Style>
</Button>
<Button x:Name="btnSer2_val2" Content="{Binding Text, ElementName=textBoxSerial2_val2}" HorizontalAlignment="Left" Height="35" Margin="62,143,0,0" VerticalAlignment="Top" Width="58" FontSize="14" Click="btnSer2_val2_Click">
<Button x:Name="btnSer2_val2" Content="{Binding Text, ElementName=textBoxSerial2_val2}" HorizontalAlignment="Left" Height="35" Margin="62,128,0,0" VerticalAlignment="Top" Width="58" FontSize="14" Click="btnSer2_val2_Click">
<Button.Style>
<Style TargetType="{x:Type Button}">
<Style.Triggers>
754,7 → 754,7
</Style>
</Button.Style>
</Button>
<Button x:Name="btnSer2_val3" Content="{Binding Text, ElementName=textBoxSerial2_val3}" HorizontalAlignment="Left" Height="35" Margin="122,143,0,0" VerticalAlignment="Top" Width="58" FontSize="14" Click="btnSer2_val3_Click">
<Button x:Name="btnSer2_val3" Content="{Binding Text, ElementName=textBoxSerial2_val3}" HorizontalAlignment="Left" Height="35" Margin="122,128,0,0" VerticalAlignment="Top" Width="58" FontSize="14" Click="btnSer2_val3_Click">
<Button.Style>
<Style TargetType="{x:Type Button}">
<Style.Triggers>
766,13 → 766,64
 
</Grid>
</GroupBox>
<GroupBox x:Name="groupBoxSerchan3" Header="Channel 3" HorizontalAlignment="Left" Height="193" VerticalAlignment="Top" Width="194" Foreground="White" BorderThickness="0.5" Margin="0,391,0,0">
<Grid Margin="0,0,-2,-12.96">
<TextBox x:Name="textBoxSerial3" HorizontalAlignment="Left" Height="21" Margin="6,3,0,0" Text="SerialChannel3 description" VerticalAlignment="Top" Width="146" Background="{x:Null}" Foreground="White" UndoLimit="0" IsUndoEnabled="False" MaxLines="1" MaxLength="24" TextChanged="textBoxSerial3_TextChanged"/>
<Label x:Name="labelSerChan3" HorizontalAlignment="Left" Margin="157,5,0,0" VerticalAlignment="Top" Foreground="White" Padding="0" Width="24" Content="{Binding Value, ElementName=SerChan3ScaleSlider}">
<Label.Style>
<Style TargetType="{x:Type Label}">
<Style.Triggers>
<DataTrigger Binding="{Binding Value, ElementName=SerChan3ScaleSlider}">
<Setter Property="Content" Value="{Binding Value, ElementName=SerChan3ScaleSlider}"/>
</DataTrigger>
</Style.Triggers>
</Style>
</Label.Style>
</Label>
<Slider x:Name="SerChan3ScaleSlider" HorizontalAlignment="Left" Height="29" Margin="4,29,0,0" VerticalAlignment="Top" Width="177" Maximum="254" FontSize="20" Style="{DynamicResource TouchSliderStyle}" SmallChange="1" ValueChanged="SerChan3ScaleSlider_ValueChanged" IsSnapToTickEnabled="True"/>
<Button x:Name="btnSer3_0" Content="0" HorizontalAlignment="Left" Height="35" Margin="2,57,0,0" VerticalAlignment="Top" Width="58" FontSize="14" Click="btnSer3_0_Click"/>
<Button x:Name="btnSer3_127" Content="127" HorizontalAlignment="Left" Height="35" Margin="62,57,0,0" VerticalAlignment="Top" Width="58" FontSize="14" Click="btnSer3_127_Click"/>
<Button x:Name="btnSer3_254" Content="254" HorizontalAlignment="Left" Height="35" Margin="122,57,0,0" VerticalAlignment="Top" Width="58" FontSize="14" Click="btnSer3_254_Click"/>
<TextBox x:Name="textBoxSerial3_val1" HorizontalAlignment="Left" Height="29" Margin="2,96,0,0" TextWrapping="Wrap" Text="0" VerticalAlignment="Top" Width="58" MaxLines="1" MaxLength="3" IsUndoEnabled="False" FontSize="14" VerticalContentAlignment="Center" HorizontalContentAlignment="Center" KeyUp="textBox_serial_KeyPress" TextChanged="textBoxSerial3_val1_TextChanged"/>
<TextBox x:Name="textBoxSerial3_val2" HorizontalAlignment="Left" Height="29" Margin="62,96,0,0" TextWrapping="Wrap" Text="0" VerticalAlignment="Top" Width="58" MaxLines="1" MaxLength="3" IsUndoEnabled="False" FontSize="14" VerticalContentAlignment="Center" HorizontalContentAlignment="Center" KeyUp="textBox_serial_KeyPress" TextChanged="textBoxSerial3_val2_TextChanged"/>
<TextBox x:Name="textBoxSerial3_val3" HorizontalAlignment="Left" Height="29" Margin="122,96,0,0" TextWrapping="Wrap" Text="0" VerticalAlignment="Top" Width="58" MaxLines="1" MaxLength="3" IsUndoEnabled="False" FontSize="14" VerticalContentAlignment="Center" HorizontalContentAlignment="Center" KeyUp="textBox_serial_KeyPress" TextChanged="textBoxSerial3_val3_TextChanged"/>
<Button x:Name="btnSer3_val1" Content="{Binding Text, ElementName=textBoxSerial2_val1}" HorizontalAlignment="Left" Height="35" Margin="2,128,0,0" VerticalAlignment="Top" Width="58" FontSize="14" Click="btnSer3_val1_Click">
<Button.Style>
<Style TargetType="{x:Type Button}">
<Style.Triggers>
<DataTrigger Binding="{Binding Text, ElementName=textBoxSerial3_val1}"/>
</Style.Triggers>
</Style>
</Button.Style>
</Button>
<Button x:Name="btnSer3_val2" Content="{Binding Text, ElementName=textBoxSerial3_val2}" HorizontalAlignment="Left" Height="35" Margin="62,128,0,0" VerticalAlignment="Top" Width="58" FontSize="14" Click="btnSer3_val2_Click">
<Button.Style>
<Style TargetType="{x:Type Button}">
<Style.Triggers>
<DataTrigger Binding="{Binding Text, ElementName=textBoxSerial3_val2}"/>
</Style.Triggers>
</Style>
</Button.Style>
</Button>
<Button x:Name="btnSer3_val3" Content="{Binding Text, ElementName=textBoxSerial3_val3}" HorizontalAlignment="Left" Height="35" Margin="122,128,0,0" VerticalAlignment="Top" Width="58" FontSize="14" Click="btnSer3_val3_Click">
<Button.Style>
<Style TargetType="{x:Type Button}">
<Style.Triggers>
<DataTrigger Binding="{Binding Text, ElementName=textBoxSerial3_val3}"/>
</Style.Triggers>
</Style>
</Button.Style>
</Button>
 
</Grid>
</GroupBox>
 
 
</Grid>
</TabItem>
</TabControl>
</Grid>
<Grid x:Name="GridSettings" Background="#7B000000" HorizontalAlignment="Left" Width="233" Margin="23,36,0,0" Visibility="Collapsed">
<Grid x:Name="GridSettings" Background="#7B000000" HorizontalAlignment="Left" Width="233" Margin="23,36,0,0">
<TabControl x:Name="tabControlSettings" HorizontalAlignment="Left" Width="229" Background="{x:Null}" Margin="2,0,0,0">
<TabItem Header="General" Margin="0,0,-0.237,0">
<Grid x:Name="TabGridGeneral">
1083,8 → 1134,8
<Label x:Name="lblWPCount" Content="##" HorizontalAlignment="Right" Margin="0,382,5,0" VerticalAlignment="Top" Width="38" Foreground="White" HorizontalContentAlignment="Right" Padding="0" Height="16"/>
<Label x:Name="label4_Copy" Content="WP Index" HorizontalAlignment="Left" Margin="94,194,0,0" VerticalAlignment="Top" Width="80" Foreground="White" Visibility="Hidden"/>
<Label x:Name="lblWPIndex" Content="##" HorizontalAlignment="Left" Margin="170,194,0,0" VerticalAlignment="Top" Width="28" Foreground="White" Visibility="Hidden"/>
<Border Margin="10,359,0,3" BorderBrush="White" BorderThickness="0.5" CornerRadius="5" HorizontalAlignment="Left" Width="322">
<Grid Margin="0,-4,-1,4">
<Border Margin="10,370,0,3" BorderBrush="White" BorderThickness="0.5" CornerRadius="5" HorizontalAlignment="Left" Width="322">
<Grid Margin="-0.5,-0.5,-0.5,4.5">
<Rectangle HorizontalAlignment="Left" Width="94" Stroke="#FFE4E4E4" StrokeThickness="0.5" Margin="103,0,0,61" Height="40" VerticalAlignment="Bottom">
<Rectangle.Style>
<Style TargetType="{x:Type Rectangle}">
1133,8 → 1184,8
<ImageBrush ImageSource="Images/LoadFile.png" Stretch="Uniform"/>
</Button.Background>
</Button>
<Label x:Name="label4_Copy5" Content="receive from copter" HorizontalAlignment="Left" Margin="98,0,0,98" VerticalAlignment="Bottom" Width="116" Foreground="White"/>
<Label x:Name="label4_Copy6" Content="send to copter" HorizontalAlignment="Left" Margin="1,0,0,98" VerticalAlignment="Bottom" Width="86" Foreground="White"/>
<Label x:Name="label4_Copy5" Content="receive from copter" HorizontalAlignment="Left" Margin="98,-2,0,98" VerticalAlignment="Bottom" Width="116" Foreground="White" Height="26"/>
<Label x:Name="label4_Copy6" Content="send to copter" HorizontalAlignment="Left" Margin="1,-2,0,98" VerticalAlignment="Bottom" Width="86" Foreground="White" Height="26"/>
<Label x:Name="label4_Copy7" Content="load from file" HorizontalAlignment="Left" Margin="0,0,0,36" VerticalAlignment="Bottom" Width="86" Foreground="White"/>
<Rectangle HorizontalAlignment="Left" Width="94" Stroke="#FFE4E4E4" StrokeThickness="0.5" Margin="221,0,0,0" Height="40" VerticalAlignment="Bottom">
<Rectangle.Style>
1169,7 → 1220,24
<ImageBrush ImageSource="Images/DeleteCopterList.png" Stretch="Uniform"/>
</Button.Background>
</Button>
<Label x:Name="label4_Copy12" Content="clear copter list" HorizontalAlignment="Left" Margin="217,0,0,98" VerticalAlignment="Bottom" Width="93" Foreground="White" Height="26"/>
<Label x:Name="label4_Copy12" Content="clear copter list" HorizontalAlignment="Left" Margin="217,-2,0,98" VerticalAlignment="Bottom" Width="93" Foreground="White" Height="26"/>
<Rectangle HorizontalAlignment="Left" Width="94" Stroke="#FFE4E4E4" StrokeThickness="0.5" Margin="103,0,0,0" Height="40" VerticalAlignment="Bottom">
<Rectangle.Style>
<Style TargetType="{x:Type Rectangle}">
<Style.Triggers>
<DataTrigger Binding="{Binding IsMouseOver, ElementName=btnSaveWPLFile}" Value="True">
<Setter Property="Fill" Value="{DynamicResource PressedItemBrush}"/>
</DataTrigger>
</Style.Triggers>
</Style>
</Rectangle.Style>
</Rectangle>
<Button x:Name="btnSaveWPLFile" Content="" HorizontalAlignment="Left" Height="37" Margin="103,0,0,1" VerticalAlignment="Bottom" Width="94" ToolTip="save list to *.wpl file" BorderBrush="#FFBDBDBD" HorizontalContentAlignment="Center" Click="btnSaveWPLFile_Click" Style="{DynamicResource ButtonWithoutEffectStyle}">
<Button.Background>
<ImageBrush ImageSource="Images/SaveFile.png" Stretch="Uniform"/>
</Button.Background>
</Button>
<Label x:Name="label4_Copy13" Content="save to file (.wpl)" HorizontalAlignment="Left" Margin="99,0,0,36" VerticalAlignment="Bottom" Width="98" Foreground="White"/>
</Grid>
</Border>
<DataGrid x:Name="dgvWP" Margin="10,5,10,143" Background="{x:Null}" ItemsSource="{Binding}" HorizontalContentAlignment="Center" VerticalContentAlignment="Center" FontSize="14" HorizontalGridLinesBrush="#FF688CAF" VerticalGridLinesBrush="#FF688CAF" HeadersVisibility="Column" BorderBrush="{x:Null}" Padding="0" AutoGenerateColumns="False" MouseUp="dgvWP_MouseUp">
/MKLiveView/v1.0/Source/MainWindow.xaml.cs
2795,6 → 2795,7
MessageBox.Show("Error writing ini-file!" + Environment.NewLine + "Please make sure that the programm is in a location where it is allowed to write" + Environment.NewLine + e.Message, "Write ini-file", MessageBoxButton.OK, MessageBoxImage.Error);
}
}
 
#region serial channels
/// <summary>
/// Sending the serial channel values
2818,8 → 2819,8
textBoxSerial1.Text = serChanTitle[0];
SerChan2ScaleSlider.Value = serChan[1];
textBoxSerial2.Text = serChanTitle[1];
//SerChan3ScaleSlider.Value = serChan[2];
//textBoxSerial3.Text = serChanTitle[2];
SerChan3ScaleSlider.Value = serChan[2];
textBoxSerial3.Text = serChanTitle[2];
//SerChan4ScaleSlider.Value = serChan[3];
//textBoxSerial4.Text = serChanTitle[3];
//trckbarSerial5.Value = serChan[4];
2837,9 → 2838,9
textBoxSerial2_val1.Text = serChan_sub[3].ToString();
textBoxSerial2_val2.Text = serChan_sub[4].ToString();
textBoxSerial2_val3.Text = serChan_sub[5].ToString();
//textBoxSerial3_val1.Text = serChan_sub[6].ToString();
//textBoxSerial3_val2.Text = serChan_sub[7].ToString();
//textBoxSerial3_val3.Text = serChan_sub[8].ToString();
textBoxSerial3_val1.Text = serChan_sub[6].ToString();
textBoxSerial3_val2.Text = serChan_sub[7].ToString();
textBoxSerial3_val3.Text = serChan_sub[8].ToString();
//textBoxSerial4_val1.Text = serChan_sub[9].ToString();
//textBoxSerial4_val2.Text = serChan_sub[10].ToString();
//textBoxSerial4_val3.Text = serChan_sub[11].ToString();
2983,6 → 2984,76
SerChan2ScaleSlider.Value = Convert.ToInt16(textBoxSerial2_val3.Text);
}
}
 
private void SerChan3ScaleSlider_ValueChanged(object sender, RoutedPropertyChangedEventArgs<double> e)
{
if (!_init)
{
serChan[2] = (int)SerChan3ScaleSlider.Value;
_sendSerialData();
}
}
private void textBoxSerial3_TextChanged(object sender, TextChangedEventArgs e)
{
if (!_init)
{
serChanTitle[2] = textBoxSerial3.Text;
}
}
private void textBoxSerial3_val1_TextChanged(object sender, TextChangedEventArgs e)
{
if (textBoxSerial3_val1.Text.Length > 0 & !_init)
{
serChan_sub[6] = Convert.ToInt16(textBoxSerial3_val1.Text);
}
}
private void textBoxSerial3_val2_TextChanged(object sender, TextChangedEventArgs e)
{
if (textBoxSerial3_val2.Text.Length > 0 & !_init)
{
serChan_sub[7] = Convert.ToInt16(textBoxSerial3_val2.Text);
}
}
private void textBoxSerial3_val3_TextChanged(object sender, TextChangedEventArgs e)
{
if (textBoxSerial3_val3.Text.Length > 0 & !_init)
{
serChan_sub[8] = Convert.ToInt16(textBoxSerial3_val3.Text);
}
}
private void btnSer3_0_Click(object sender, RoutedEventArgs e)
{
SerChan3ScaleSlider.Value = 0;
}
private void btnSer3_127_Click(object sender, RoutedEventArgs e)
{
SerChan3ScaleSlider.Value = 127;
}
private void btnSer3_254_Click(object sender, RoutedEventArgs e)
{
SerChan3ScaleSlider.Value = 254;
}
private void btnSer3_val1_Click(object sender, RoutedEventArgs e)
{
if (textBoxSerial3_val1.Text.Length > 0)
{
SerChan3ScaleSlider.Value = Convert.ToInt16(textBoxSerial3_val1.Text);
}
}
private void btnSer3_val2_Click(object sender, RoutedEventArgs e)
{
if (textBoxSerial3_val2.Text.Length > 0)
{
SerChan3ScaleSlider.Value = Convert.ToInt16(textBoxSerial3_val2.Text);
}
}
private void btnSer3_val3_Click(object sender, RoutedEventArgs e)
{
if (textBoxSerial3_val3.Text.Length > 0)
{
SerChan3ScaleSlider.Value = Convert.ToInt16(textBoxSerial3_val3.Text);
}
}
/// <summary>
/// checks the input of a textbox
/// for valid data
3111,7 → 3182,8
i++;
sVal = ini.IniReadValue(wp, "Prefix");
if (sVal != "")
o[i] = sVal == "0" ? "P" + k.ToString() : sVal + k.ToString();
o[i] = sVal + k.ToString();
// o[i] = sVal == "0" ? "!" + k.ToString() : sVal + k.ToString();
i++;
sVal = ini.IniReadValue(wp, "Latitude");
if (sVal != "")
3207,6 → 3279,59
 
}
}
void _saveWPLFile()
{
if (dtWaypoints.Rows.Count > 0)
{
Microsoft.Win32.SaveFileDialog fd = new Microsoft.Win32.SaveFileDialog();
fd.Filter = "Waypointlists | *.wpl";
fd.AddExtension = true;
if (fd.ShowDialog().Value)
{
string file = fd.SafeFileName;
IniFile ini = new IniFile(fd.SafeFileName);
ini.path = fd.FileName;
NumberFormatInfo nfi = new NumberFormatInfo();
nfi.NumberDecimalSeparator = ".";
 
try
{
ini.IniWriteValue("General", "FileVersion", "3");
ini.IniWriteValue("General", "NumberOfWaypoints", dtWaypoints.Rows.Count.ToString());
ini.IniWriteValue("General", "Mapfile", "");
for(int i = 1; i<=dtWaypoints.Rows.Count; i++)
{
ini.IniWriteValue("Point" + i.ToString(), "Latitude", ((double)(dtWaypoints.Rows[i-1][3])).ToString(nfi));
ini.IniWriteValue("Point" + i.ToString(), "Longitude", ((double)(dtWaypoints.Rows[i - 1][4])).ToString(nfi));
ini.IniWriteValue("Point" + i.ToString(), "Radius", dtWaypoints.Rows[i - 1][9].ToString());
ini.IniWriteValue("Point" + i.ToString(), "Altitude", dtWaypoints.Rows[i - 1][5].ToString());
ini.IniWriteValue("Point" + i.ToString(), "ClimbRate", dtWaypoints.Rows[i - 1][8].ToString());
ini.IniWriteValue("Point" + i.ToString(), "DelayTime", dtWaypoints.Rows[i - 1][10].ToString());
ini.IniWriteValue("Point" + i.ToString(), "WP_Event_Channel_Value", dtWaypoints.Rows[i - 1][14].ToString());
ini.IniWriteValue("Point" + i.ToString(), "Heading", dtWaypoints.Rows[i - 1][6].ToString());
ini.IniWriteValue("Point" + i.ToString(), "Speed", dtWaypoints.Rows[i - 1][7].ToString());
ini.IniWriteValue("Point" + i.ToString(), "CAM-Nick", dtWaypoints.Rows[i - 1][12].ToString());
ini.IniWriteValue("Point" + i.ToString(), "Type", ((int)dtWaypoints.Rows[i - 1][1]+1).ToString());
ini.IniWriteValue("Point" + i.ToString(), "Prefix", dtWaypoints.Rows[i - 1][2].ToString().Substring(0, 1)); // == "!" ? "0" : dtWaypoints.Rows[i - 1][2].ToString().Substring(0, 1));
ini.IniWriteValue("Point" + i.ToString(), "AutoTrigger", dtWaypoints.Rows[i - 1][11].ToString());
}
MessageBox.Show(dtWaypoints.Rows.Count.ToString() + " points saved to " + file, "Waypointlist saved", MessageBoxButton.OK, MessageBoxImage.Information);
}
catch { }
}
}
else
MessageBox.Show("Nothing to save...");
}
private void btnSaveWPLFile_Click(object sender, RoutedEventArgs e)
{
_saveWPLFile();
}
/// <summary>
/// set the selected color for the route
/// </summary>
/// <param name="color"></param>
/// <returns></returns>
Brush _getBrush(string color)
{
switch (color)
3405,7 → 3530,6
}
 
#endregion WP
 
#region GPX
private void checkBoxGPXLog_Click(object sender, RoutedEventArgs e)
{
3474,18 → 3598,14
}
}
}
 
private void btnLoadGPXLog_Click(object sender, RoutedEventArgs e)
{
_loadGPXLog();
}
 
private void btnClearRoute_Click(object sender, RoutedEventArgs e)
{
_clearMapMarkers(typeof(GMapRoute));
}
 
 
void _loadGPXLog()
{