Bladeren bron

help page dingen

Jannick van Ballegooijen 10 jaren geleden
bovenliggende
commit
b6bb0b95a5

+ 5 - 0
Breda-Tour/App.xaml

@@ -44,7 +44,12 @@
                 <GradientStop Color="#185a9d" Offset="0"/>
                 <GradientStop Color="#43cea2" Offset="1"/>
             </LinearGradientBrush>
+            <LinearGradientBrush x:Key="BredaTourDropShadowBrush" StartPoint="0,0" EndPoint="0,1" SpreadMethod="Reflect">
+                <GradientStop Color="#44000000" Offset="0"/>
+                <GradientStop Color="#FFFFFFFF" Offset="0.5"/>
+                <GradientStop Color="#44000000" Offset="1"/>
 
+            </LinearGradientBrush>
             <Style TargetType="TextBlock" x:Key="SettingsHeaderStyle">
                 <Setter Property="Margin" Value="20,15,0,15"/>
                 <Setter Property="FontSize" Value="14"/>

+ 0 - 1
Breda-Tour/Breda-Tour.csproj

@@ -117,7 +117,6 @@
     <Compile Include="CustomControls\DefaultTopBar.xaml.cs">
       <DependentUpon>DefaultTopBar.xaml</DependentUpon>
     </Compile>
-    <Compile Include="HelpScreen\HelpItem.cs" />
     <Compile Include="HelpScreen\HelpPage.xaml.cs">
       <DependentUpon>HelpPage.xaml</DependentUpon>
     </Compile>

+ 1 - 1
Breda-Tour/Data/HelpItem.cs

@@ -6,7 +6,7 @@ using System.Threading.Tasks;
 
 namespace Breda_Tour.Data
 {
-    class HelpItem
+    public class HelpItem
     {
         public string Title { get; private set; }
         public string Language { get; private set; }

+ 1 - 1
Breda-Tour/Data/HelpItemStep.cs

@@ -6,7 +6,7 @@ using System.Threading.Tasks;
 
 namespace Breda_Tour.Data
 {
-    class HelpItemStep
+    public class HelpItemStep
     {
         public string Title { get; private set; }
         public string Description { get; private set; }

+ 4 - 3
Breda-Tour/Data/HelpPageDatabase.cs

@@ -2,6 +2,7 @@
 using Newtonsoft.Json.Linq;
 using System;
 using System.Collections.Generic;
+using System.Collections.ObjectModel;
 using System.IO;
 using System.Linq;
 using System.Text;
@@ -10,12 +11,12 @@ using System.Threading.Tasks;
 namespace Breda_Tour.Data
 { 
 
-    class HelpPageDatabase
+    public class HelpPageDatabase
     {
-        private List<HelpItem> HelpItems;
+        public ObservableCollection<HelpItem> HelpItems;
         public HelpPageDatabase()
         {
-            HelpItems = new List<HelpItem>();
+            HelpItems = new ObservableCollection<HelpItem>();
             readHelpItems();
 
         }

+ 0 - 13
Breda-Tour/HelpScreen/HelpItem.cs

@@ -1,13 +0,0 @@
-using System;
-using System.Collections.Generic;
-using System.Linq;
-using System.Text;
-using System.Threading.Tasks;
-
-namespace Breda_Tour.HelpScreen
-{
-    public class HelpItem
-    {
-        public string Title { get; set; }
-    }
-}

+ 16 - 2
Breda-Tour/HelpScreen/HelpPage.xaml

@@ -15,9 +15,23 @@
             <RowDefinition Height="75"/>
         </Grid.RowDefinitions>
         <c:DefaultTopBar MySymbol="{StaticResource SymbolClose}" Header="HelpItem" />
-        <StackPanel Background="White" Grid.Row="1">
+        <ScrollViewer HorizontalScrollBarVisibility="Disabled" HorizontalScrollMode="Disabled" VerticalScrollMode="Enabled" VerticalScrollBarVisibility="Hidden" Background="White"  Grid.Row="1" Padding="20,20,20,0">
+            <StackPanel Orientation="Vertical" Height="Auto">
+                <TextBlock Text="Afbeelding" FontWeight="Bold"/>
+                <Image
+                Name="HelpImage"
+                Height="400"
+                Width="300" >
 
-        </StackPanel>
+                </Image>
+                <TextBlock Margin="0,10,0,0" Text="Description" FontWeight="Bold"/>
+                <TextBlock Margin="0,10,0,0"
+                       TextWrapping="Wrap">
+                </TextBlock>
+
+            </StackPanel>
+        </ScrollViewer>
+       
         <Grid Grid.Row="2">
             <Grid.ColumnDefinitions>
                 <ColumnDefinition/>

+ 10 - 10
Breda-Tour/SettingsScreen/SettingsPage.xaml

@@ -6,7 +6,7 @@
     xmlns:c="using:Breda_Tour.CustomControls"
     xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
     xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
-    xmlns:data="using:Breda_Tour.HelpScreen"
+    xmlns:data="using:Breda_Tour.Data"
     mc:Ignorable="d">
     <Grid Background="Transparent">
         <Grid.RowDefinitions>
@@ -17,16 +17,16 @@
         <c:DefaultTopBar Header="Instellingen"/>
         <c:DefaultPivotControl x:Name="DefaultPivot" Grid.Row="1"/>
         <ScrollViewer Grid.Row="2" VerticalScrollBarVisibility="Hidden">
-            <StackPanel Orientation="Vertical">
-                <TextBlock Style="{StaticResource SettingsHeaderStyle}" Foreground="White" Text="{StaticResource AppSettingsLanguageSettings}"></TextBlock>
+            <StackPanel Orientation="Vertical" Background="White">
+                <TextBlock Style="{StaticResource SettingsHeaderStyle}" Foreground="{StaticResource BredaToursMainColorBrush}" Text="{StaticResource AppSettingsLanguageSettings}"></TextBlock>
                 <ListViewItem>
                     <StackPanel Margin="8,0,0,0">
-                        <TextBlock FontSize="18" Text="Taal instellen" Foreground="White"></TextBlock>
-                        <TextBlock Margin="0,-1,0,0" FontSize="12" Foreground="White" Text="{StaticResource AppLanguageDutch}"></TextBlock>
+                        <TextBlock FontSize="18" Text="Taal instellen"></TextBlock>
+                        <TextBlock Margin="0,-1,0,0" FontSize="12" Text="{StaticResource AppLanguageDutch}"></TextBlock>
                     </StackPanel>
                 </ListViewItem>
-                <Rectangle Margin="0,15,0,0" Fill="#99FFFFFF" Height="1" />
-                <TextBlock Style="{StaticResource SettingsHeaderStyle}" Foreground="White" Text="{StaticResource AppSettingsHelp}"></TextBlock>
+                <Rectangle Margin="0,15,0,0" Fill="#99000000" Height="1" />
+                <TextBlock Style="{StaticResource SettingsHeaderStyle}" Foreground="{StaticResource BredaToursMainColorBrush}" Text="{StaticResource AppSettingsHelp}"></TextBlock>
                 <ListView ItemsSource="{x:Bind HelpItems}" >
                     <ListView.ItemTemplate>
                         <DataTemplate x:DataType="data:HelpItem">
@@ -36,19 +36,19 @@
                                         <ColumnDefinition Width="50"/>
                                         <ColumnDefinition Width="*"/>
                                     </Grid.ColumnDefinitions>
-                                    <Ellipse Height="40" Width="40" Stroke="White" StrokeThickness="0.5"
+                                    <Ellipse Height="40" Width="40" Stroke="{StaticResource BredaToursMainColorBrush}" StrokeThickness="0.5"
                                          Margin="5"
                                          Name="FolderEllipse"/>
                                     <SymbolIcon Symbol="Folder"
                                                 
-                                            Foreground="White"
+                                            Foreground="{StaticResource BredaToursMainColorBrush}"
                                             Margin="10"
                                             >
                                         <SymbolIcon.RenderTransform>
                                             <RotateTransform Angle="270" CenterX="15" CenterY="15"/>
                                         </SymbolIcon.RenderTransform>
                                     </SymbolIcon>
-                                    <TextBlock RelativePanel.RightOf="FolderEllipse" Foreground="White" Margin="10,14" Text="{x:Bind Title}" Grid.Column="1"/>
+                                    <TextBlock RelativePanel.RightOf="FolderEllipse" Margin="10,14" Text="{x:Bind Title}" Grid.Column="1"/>
                                 </Grid>
                             </ListBoxItem>
                         </DataTemplate>

+ 4 - 6
Breda-Tour/SettingsScreen/SettingsPage.xaml.cs

@@ -8,6 +8,7 @@ using System.Runtime.InteropServices.WindowsRuntime;
 using Breda_Tour;
 
 using Breda_Tour.HelpScreen;
+using Breda_Tour.Data;
 using Windows.Foundation;
 using Windows.Foundation.Collections;
 using Windows.UI.Xaml;
@@ -41,12 +42,9 @@ namespace Breda_Tours.SettingsScreen
             this.InitializeComponent();
 
             DefaultPivot.SetCheckedButton(Breda_Tour.CustomControls.DefaultPivotControl.Tab.Settings);
-            HelpItems = new ObservableCollection<HelpItem>();
-            for (int i = 0; i < 10; i++)
-                HelpItems.Add(new HelpItem
-                {
-                    Title = "HelpItem" + i
-                });
+            HelpPageDatabase helpDatabase = new HelpPageDatabase();
+            HelpItems = helpDatabase.HelpItems;
+            
             DataContext = this;
         }