Merge branch 'develop' into feature/#290
Conflicts: CampusAppWP8/CampusAppWP8/Pages/StartPage.xaml
This commit is contained in:
@@ -13,6 +13,7 @@
|
||||
<ResourceDictionary Source="Styles/ListButton.xaml"/>
|
||||
<ResourceDictionary Source="Styles/StartPageStyles.xaml"/>
|
||||
<ResourceDictionary Source="Styles/Labels.xaml"/>
|
||||
<ResourceDictionary Source="Styles/UniColors.xaml"/>
|
||||
<ResourceDictionary>
|
||||
<local:LocalizedStrings xmlns:local="clr-namespace:CampusAppWP8" x:Key="LocalizedStrings"/>
|
||||
<local:ThemelizedIcons xmlns:local="clr-namespace:CampusAppWP8" x:Key="ThemelizedIcons"/>
|
||||
|
||||
@@ -10,6 +10,7 @@ using System.IO.IsolatedStorage;
|
||||
using System.Threading;
|
||||
using System.Windows;
|
||||
using System.Windows.Markup;
|
||||
using System.Windows.Media;
|
||||
using System.Windows.Navigation;
|
||||
|
||||
|
||||
@@ -157,6 +158,19 @@ namespace CampusAppWP8
|
||||
Settings.AppSetting.InitApp = false;
|
||||
}
|
||||
|
||||
Color appColor = ((SolidColorBrush)App.Current.Resources["PhoneAccentBrush"]).Color;
|
||||
if (!Settings.AppSetting.DisplaySetting.PhoneAccentColor.Equals(appColor))
|
||||
{
|
||||
if (Settings.AppSetting.DisplaySetting.AppAccentColor.Equals(Settings.AppSetting.DisplaySetting.PhoneAccentColor))
|
||||
{
|
||||
Settings.AppSetting.DisplaySetting.AppAccentColor = appColor;
|
||||
}
|
||||
Settings.AppSetting.DisplaySetting.PhoneAccentColor = appColor;
|
||||
}
|
||||
|
||||
appColor = Settings.AppSetting.DisplaySetting.AppAccentColor;
|
||||
Utilities.SwitchAccentColor(appColor);
|
||||
|
||||
this.UserSettingsLoaded();
|
||||
|
||||
Settings.AppSetting.NetworkSetting.UniNetwork = Utilities.IsUniNetworkAvailable();
|
||||
|
||||
@@ -134,6 +134,7 @@
|
||||
<Compile Include="Model\Setting\AppSettings.cs" />
|
||||
<Compile Include="Model\Setting\BTUTagHandlerTypes.cs" />
|
||||
<Compile Include="Model\Setting\BTUTagSetting.cs" />
|
||||
<Compile Include="Model\Setting\DisplaySetting.cs" />
|
||||
<Compile Include="Model\Setting\FunctionSettings.cs" />
|
||||
<Compile Include="Model\Setting\ISetting.cs" />
|
||||
<Compile Include="Model\Setting\LocatingSetting.cs" />
|
||||
@@ -144,6 +145,8 @@
|
||||
<Compile Include="Model\Setting\UserProfilModel.cs" />
|
||||
<Compile Include="Model\TimeTable\AppointmentListModel.cs" />
|
||||
<Compile Include="Model\TimeTable\AppointmentModel.cs" />
|
||||
<Compile Include="Model\Utility\AppAccentColorListPickerItemListModel.cs" />
|
||||
<Compile Include="Model\Utility\ColorListPickerItemModel.cs" />
|
||||
<Compile Include="Pages\Setting\FunctionSettingPage.xaml.cs">
|
||||
<DependentUpon>FunctionSettingPage.xaml</DependentUpon>
|
||||
</Compile>
|
||||
@@ -542,6 +545,10 @@
|
||||
<Generator>MSBuild:Compile</Generator>
|
||||
<SubType>Designer</SubType>
|
||||
</Page>
|
||||
<Page Include="Styles\UniColors.xaml">
|
||||
<Generator>MSBuild:Compile</Generator>
|
||||
<SubType>Designer</SubType>
|
||||
</Page>
|
||||
<Page Include="Styles\Labels.xaml">
|
||||
<Generator>MSBuild:Compile</Generator>
|
||||
<SubType>Designer</SubType>
|
||||
|
||||
@@ -26,10 +26,30 @@ namespace CampusAppWP8.Model.Setting
|
||||
/// <summary> The locating setting. </summary>
|
||||
private static LocatingSetting locatingSetting = new LocatingSetting();
|
||||
|
||||
private static DisplaySetting displaySetting = new DisplaySetting();
|
||||
|
||||
#endregion
|
||||
|
||||
#region Property
|
||||
|
||||
/// <summary> Gets or sets the display setting. </summary>
|
||||
/// <value> The display setting. </value>
|
||||
public DisplaySetting DisplaySetting
|
||||
{
|
||||
get
|
||||
{
|
||||
return AppSettings.displaySetting;
|
||||
}
|
||||
|
||||
set
|
||||
{
|
||||
if (AppSettings.displaySetting != value)
|
||||
{
|
||||
AppSettings.displaySetting = value;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary> Gets or sets the locating setting. </summary>
|
||||
/// <value> The locating setting. </value>
|
||||
public LocatingSetting LocatingSetting
|
||||
@@ -150,6 +170,7 @@ namespace CampusAppWP8.Model.Setting
|
||||
this.FunctionSettings.SetSettingToDefault();
|
||||
this.NetworkSetting.SetSettingToDefault();
|
||||
this.LocatingSetting.SetSettingToDefault();
|
||||
this.DisplaySetting.SetSettingToDefault();
|
||||
}
|
||||
#endregion
|
||||
}
|
||||
|
||||
64
CampusAppWP8/CampusAppWP8/Model/Setting/DisplaySetting.cs
Normal file
64
CampusAppWP8/CampusAppWP8/Model/Setting/DisplaySetting.cs
Normal file
@@ -0,0 +1,64 @@
|
||||
using CampusAppWP8.Resources;
|
||||
//-----------------------------------------------------------------------
|
||||
// <copyright file="DisplaySetting.cs" company="BTU/IIT">
|
||||
// The MIT License (MIT). Copyright (c) 2013 BTU/IIT.
|
||||
// </copyright>
|
||||
// <author>Stubbfel</author>
|
||||
// <date>26.11.2013</date>
|
||||
// <summary>Implements the display setting class</summary>
|
||||
//-----------------------------------------------------------------------
|
||||
using System.Windows.Media;
|
||||
|
||||
namespace CampusAppWP8.Model.Setting
|
||||
{
|
||||
/// <summary> A display setting. </summary>
|
||||
/// <remarks> Stubbfel, 26.11.2013. </remarks>
|
||||
/// <seealso cref="T:CampusAppWP8.Model.Setting.ISetting"/>
|
||||
public class DisplaySetting : ISetting
|
||||
{
|
||||
#region property
|
||||
|
||||
/// <summary> Gets or sets the color of the application accent. </summary>
|
||||
/// <value> The color of the application accent. </value>
|
||||
public Color AppAccentColor
|
||||
{
|
||||
get
|
||||
{
|
||||
return App.LoadFromAppState<Color>(Constants.Setting_AppAccentColor);
|
||||
}
|
||||
|
||||
set
|
||||
{
|
||||
App.SaveToAppState<Color>(Constants.Setting_AppAccentColor, value);
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary> Gets or sets the color of the phone accent. </summary>
|
||||
/// <value> The color of the phone accent. </value>
|
||||
public Color PhoneAccentColor
|
||||
{
|
||||
get
|
||||
{
|
||||
return App.LoadFromAppState<Color>(Constants.Setting_PhoneAccentColor);
|
||||
}
|
||||
|
||||
set
|
||||
{
|
||||
App.SaveToAppState<Color>(Constants.Setting_PhoneAccentColor, value);
|
||||
}
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
#region method
|
||||
|
||||
/// <summary> Sets setting to default. </summary>
|
||||
/// <remarks> Stubbfel, 25.11.2013. </remarks>
|
||||
/// <seealso cref="M:CampusAppWP8.Model.Setting.ISetting.SetSettingToDefault()"/>
|
||||
public void SetSettingToDefault()
|
||||
{
|
||||
this.AppAccentColor = this.PhoneAccentColor;
|
||||
}
|
||||
#endregion
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,91 @@
|
||||
//-----------------------------------------------------------------------
|
||||
// <copyright file="AppAccentColorListPickerItemListModel.cs" company="BTU/IIT">
|
||||
// The MIT License (MIT). Copyright (c) 2013 BTU/IIT.
|
||||
// </copyright>
|
||||
// <author>Stubbfel</author>
|
||||
// <date>26.11.2013</date>
|
||||
// <summary>Implements the application accent color list picker item list model class</summary>
|
||||
//-----------------------------------------------------------------------
|
||||
namespace CampusAppWP8.Model.Utility
|
||||
{
|
||||
using System.Windows.Media;
|
||||
using CampusAppWP8.Resources;
|
||||
|
||||
/// <summary> A data Model for the application accent color list picker item list. </summary>
|
||||
/// <remarks> Stubbfel, 26.11.2013. </remarks>
|
||||
/// <seealso cref="T:CampusAppWPortalLib8.Model.Utility.ListPickerItemListTemplateModel{System.Windows.Media.Color}"/>
|
||||
public class AppAccentColorListPickerItemListModel : CampusAppWPortalLib8.Model.Utility.ListPickerItemListTemplateModel<SolidColorBrush>
|
||||
{
|
||||
#region member
|
||||
|
||||
/// <summary> The faculty 1 color. </summary>
|
||||
private static readonly SolidColorBrush Faculty1Color = (SolidColorBrush)App.Current.Resources[Constants.Brush_Faculty1];
|
||||
|
||||
/// <summary> The faculty 2 color. </summary>
|
||||
private static readonly SolidColorBrush Faculty2Color = (SolidColorBrush)App.Current.Resources[Constants.Brush_Faculty2];
|
||||
|
||||
/// <summary> The faculty 3 color. </summary>
|
||||
private static readonly SolidColorBrush Faculty3Color = (SolidColorBrush)App.Current.Resources[Constants.Brush_Faculty3];
|
||||
|
||||
/// <summary> The faculty 4 color. </summary>
|
||||
private static readonly SolidColorBrush Faculty4Color = (SolidColorBrush)App.Current.Resources[Constants.Brush_Faculty4];
|
||||
|
||||
/// <summary> The faculty 5 color. </summary>
|
||||
private static readonly SolidColorBrush Faculty5Color = (SolidColorBrush)App.Current.Resources[Constants.Brush_Faculty5];
|
||||
|
||||
/// <summary> The faculty. </summary>
|
||||
private readonly string faculty = CampusAppWPortalLib8.Resources.AppResources.Faculty;
|
||||
|
||||
#endregion
|
||||
|
||||
#region Constructor
|
||||
|
||||
/// <summary>
|
||||
/// Initializes a new instance of the AppAccentColorListPickerItemListModel class.
|
||||
/// </summary>
|
||||
/// <remarks> Stubbfel, 26.11.2013. </remarks>
|
||||
public AppAccentColorListPickerItemListModel()
|
||||
: base()
|
||||
{
|
||||
this.LoadList();
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
#region Method
|
||||
|
||||
/// <summary> Gets index or default. </summary>
|
||||
/// <remarks> Stubbfel, 27.11.2013. </remarks>
|
||||
/// <param name="value"> The value. </param>
|
||||
/// <returns> The index or default. </returns>
|
||||
public override int GetIndexOrDefault(SolidColorBrush value)
|
||||
{
|
||||
int index = 0;
|
||||
foreach (ColorListPickerItemModel brush in this.List)
|
||||
{
|
||||
if (brush.Value.Color.Equals(value.Color))
|
||||
{
|
||||
break;
|
||||
}
|
||||
|
||||
index++;
|
||||
}
|
||||
|
||||
return index;
|
||||
}
|
||||
|
||||
/// <summary> Loads the list. </summary>
|
||||
/// <remarks> Stubbfel, 26.11.2013. </remarks>
|
||||
protected override void LoadList()
|
||||
{
|
||||
this.AddItem(new ColorListPickerItemModel(new SolidColorBrush(Settings.AppSetting.DisplaySetting.PhoneAccentColor), CampusAppWP8.Resources.AppResources.AccentColor));
|
||||
this.AddItem(new ColorListPickerItemModel(AppAccentColorListPickerItemListModel.Faculty1Color, this.faculty + " 1"));
|
||||
this.AddItem(new ColorListPickerItemModel(AppAccentColorListPickerItemListModel.Faculty2Color, this.faculty + " 2"));
|
||||
this.AddItem(new ColorListPickerItemModel(AppAccentColorListPickerItemListModel.Faculty3Color, this.faculty + " 3"));
|
||||
this.AddItem(new ColorListPickerItemModel(AppAccentColorListPickerItemListModel.Faculty4Color, this.faculty + " 4"));
|
||||
this.AddItem(new ColorListPickerItemModel(AppAccentColorListPickerItemListModel.Faculty5Color, this.faculty + " 5"));
|
||||
}
|
||||
|
||||
#endregion
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,34 @@
|
||||
//-----------------------------------------------------------------------
|
||||
// <copyright file="ColorListPickerItemModel.cs" company="BTU/IIT">
|
||||
// The MIT License (MIT). Copyright (c) 2013 BTU/IIT.
|
||||
// </copyright>
|
||||
// <author>Stubbfel</author>
|
||||
// <date>26.11.2013</date>
|
||||
// <summary>Implements the color list picker item model class</summary>
|
||||
//-----------------------------------------------------------------------
|
||||
namespace CampusAppWP8.Model.Utility
|
||||
{
|
||||
using System.Windows.Media;
|
||||
|
||||
/// <summary> A data Model for the color list picker item. </summary>
|
||||
/// <remarks> Stubbfel, 26.11.2013. </remarks>
|
||||
/// <seealso cref="T:CampusAppWPortalLib8.Model.Utility.ListPickerItemTemplateModel{System.Windows.Media.Color}"/>
|
||||
public class ColorListPickerItemModel : CampusAppWPortalLib8.Model.Utility.ListPickerItemTemplateModel<SolidColorBrush>
|
||||
{
|
||||
/// <summary> Initializes a new instance of the ColorListPickerItemModel class. </summary>
|
||||
/// <remarks> Stubbfel, 26.11.2013. </remarks>
|
||||
public ColorListPickerItemModel()
|
||||
: base()
|
||||
{
|
||||
}
|
||||
|
||||
/// <summary> Initializes a new instance of the ColorListPickerItemModel class. </summary>
|
||||
/// <remarks> Stubbfel, 26.11.2013. </remarks>
|
||||
/// <param name="value"> The value. </param>
|
||||
/// <param name="text"> The text. </param>
|
||||
public ColorListPickerItemModel(SolidColorBrush value, string text)
|
||||
: base(value, text)
|
||||
{
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -26,7 +26,7 @@
|
||||
|
||||
<!--TitlePanel enthält den Namen der Anwendung und den Seitentitel-->
|
||||
<StackPanel Grid.Row="0">
|
||||
<header:DefaultHeader Name="DefHeader" HeaderName="{Binding Path=LocalizedResources.Setting_General, Source={StaticResource LocalizedStrings}}"/>
|
||||
<header:DefaultHeader x:Name="DefHeader" HeaderName="{Binding Path=LocalizedResources.Setting_General, Source={StaticResource LocalizedStrings}}"/>
|
||||
</StackPanel>
|
||||
<phone:Pivot Grid.Row="1" Name="GeneralSettingPivot">
|
||||
<phone:Pivot.HeaderTemplate>
|
||||
@@ -69,7 +69,29 @@
|
||||
</phone:PivotItem>
|
||||
<phone:PivotItem
|
||||
Header="{Binding Path=LocalizedResources.Setting_Display_Short, Source={StaticResource LocalizedStrings}}">
|
||||
|
||||
<StackPanel >
|
||||
<TextBlock
|
||||
Text="{Binding Path=LocalizedResources.AccentColor, Source={StaticResource LocalizedStrings}}" Style="{StaticResource SettingLabel}"/>
|
||||
<!-- Listpicket of courses -->
|
||||
<toolkit:ListPicker Name="AccentColorPicker" FullModeHeader="{Binding Path=LocalizedResources.AccentColorPicker, Source={StaticResource LocalizedStrings}}" VerticalAlignment="Center" SelectionChanged="AccentColorPicker_SelectionChanged">
|
||||
<toolkit:ListPicker.ItemTemplate>
|
||||
<DataTemplate>
|
||||
<StackPanel Orientation="Horizontal">
|
||||
<Rectangle Fill="{Binding Value}" Height="24" Width="24" Stroke="Black"/>
|
||||
<TextBlock Text="{Binding Text}" Margin="12,0,0,0"/>
|
||||
</StackPanel>
|
||||
</DataTemplate>
|
||||
</toolkit:ListPicker.ItemTemplate>
|
||||
<toolkit:ListPicker.FullModeItemTemplate>
|
||||
<DataTemplate>
|
||||
<StackPanel Orientation="Horizontal" Margin="0,12,0,0">
|
||||
<Rectangle Fill="{Binding Value}" Height="48" Width="48" Stroke="Black"/>
|
||||
<TextBlock Text="{Binding Text}" Style="{StaticResource PhoneTextGroupHeaderStyle}" TextWrapping="Wrap" Margin="24,0,0,0"/>
|
||||
</StackPanel>
|
||||
</DataTemplate>
|
||||
</toolkit:ListPicker.FullModeItemTemplate>
|
||||
</toolkit:ListPicker>
|
||||
</StackPanel>
|
||||
</phone:PivotItem>
|
||||
|
||||
<phone:PivotItem
|
||||
|
||||
@@ -9,15 +9,26 @@
|
||||
namespace CampusAppWP8.Pages.Setting
|
||||
{
|
||||
using System;
|
||||
using System.Windows.Media;
|
||||
using System.Windows.Navigation;
|
||||
using CampusAppWP8.Model.Utility;
|
||||
using CampusAppWP8.Resources;
|
||||
using CampusAppWP8.Utility;
|
||||
using Microsoft.Phone.Controls;
|
||||
|
||||
/// <summary> Class for the AppSettingPage. </summary>
|
||||
/// <remarks> Stubbfel, 15.10.2013. </remarks>
|
||||
/// <seealso cref="T:Microsoft.Phone.Controls.PhoneApplicationPage"/>
|
||||
/// <seealso cref="T:CampusAppWP8.Pages.Setting.IRefreshingPage"/>
|
||||
public partial class AppSettingPage : PhoneApplicationPage, IRefreshingPage
|
||||
{
|
||||
#region member
|
||||
|
||||
/// <summary> List of colors of the application accents. </summary>
|
||||
private readonly AppAccentColorListPickerItemListModel appAccentColors = new AppAccentColorListPickerItemListModel();
|
||||
|
||||
#endregion
|
||||
|
||||
#region Constructor
|
||||
|
||||
/// <summary> Initializes a new instance of the <see cref="AppSettingPage" /> class. </summary>
|
||||
@@ -25,6 +36,7 @@ namespace CampusAppWP8.Pages.Setting
|
||||
public AppSettingPage()
|
||||
{
|
||||
this.InitializeComponent();
|
||||
this.AccentColorPicker.ItemsSource = this.appAccentColors.List;
|
||||
this.LoadSettings();
|
||||
}
|
||||
|
||||
@@ -44,6 +56,7 @@ namespace CampusAppWP8.Pages.Setting
|
||||
#endregion
|
||||
|
||||
#region protected
|
||||
|
||||
/// <summary> Override the OnNavigatedTo method. </summary>
|
||||
/// <remarks> Stubbfel, 15.10.2013. </remarks>
|
||||
/// <seealso cref="M:System.Windows.Controls.Page.OnNavigatedTo(NavigationEventArgs)"/>
|
||||
@@ -78,12 +91,14 @@ namespace CampusAppWP8.Pages.Setting
|
||||
#endregion
|
||||
|
||||
#region private
|
||||
|
||||
/// <summary> Loads the settings. </summary>
|
||||
/// <remarks> Stubbfel, 25.11.2013. </remarks>
|
||||
private void LoadSettings()
|
||||
{
|
||||
this.GeoWatchToggle.IsChecked = Settings.AppSetting.LocatingSetting.GeoWatchEnable;
|
||||
this.OnlyWiFiToggle.IsChecked = Settings.AppSetting.NetworkSetting.OnlyWifi;
|
||||
this.AccentColorPicker.SelectedIndex = this.appAccentColors.GetIndexOrDefault(new SolidColorBrush(Settings.AppSetting.DisplaySetting.AppAccentColor));
|
||||
}
|
||||
|
||||
/// <summary> Saves the settings. </summary>
|
||||
@@ -104,6 +119,21 @@ namespace CampusAppWP8.Pages.Setting
|
||||
this.LoadSettings();
|
||||
}
|
||||
|
||||
/// <summary> Event handler. Called by AccentColorPicker for selection changed events. </summary>
|
||||
/// <remarks> Stubbfel, 26.11.2013. </remarks>
|
||||
/// <param name="sender"> Source of the event. </param>
|
||||
/// <param name="e"> Selection changed event information. </param>
|
||||
private void AccentColorPicker_SelectionChanged(object sender, System.Windows.Controls.SelectionChangedEventArgs e)
|
||||
{
|
||||
if (e.AddedItems.Count == 1 && e.RemovedItems.Count == 1)
|
||||
{
|
||||
int selectedIndex = this.AccentColorPicker.SelectedIndex;
|
||||
Color newColor = this.appAccentColors.List[selectedIndex].Value.Color;
|
||||
Utilities.SwitchAccentColor(newColor);
|
||||
Settings.AppSetting.DisplaySetting.AppAccentColor = newColor;
|
||||
}
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
#endregion
|
||||
|
||||
@@ -29,10 +29,13 @@
|
||||
|
||||
<!--ContentPanel - zusätzliche Inhalte hier platzieren-->
|
||||
<Grid x:Name="ContentPanel" Grid.Row="1" Margin="12,0,12,0">
|
||||
<ScrollViewer>
|
||||
<StackPanel Margin="12">
|
||||
<TextBlock>Name: BTU Campus-App</TextBlock>
|
||||
<TextBlock>Version: 1.0</TextBlock>
|
||||
<TextBlock>Kontakt:</TextBlock>
|
||||
<TextBlock Style="{StaticResource PhoneTextGroupHeaderStyle}">Name</TextBlock>
|
||||
<TextBlock Style="{StaticResource PhoneTextTitle2Style}" Margin="24,0,0,12">BTU CampusApp</TextBlock>
|
||||
<TextBlock Style="{StaticResource PhoneTextGroupHeaderStyle}">Version</TextBlock>
|
||||
<TextBlock Style="{StaticResource PhoneTextTitle2Style}" Margin="24,0,0,12">1.1</TextBlock>
|
||||
<TextBlock Style="{StaticResource PhoneTextGroupHeaderStyle}">Kontakt:</TextBlock>
|
||||
<Grid Margin="12,0,0,0">
|
||||
<Grid.RowDefinitions>
|
||||
<RowDefinition Height="auto"/>
|
||||
@@ -43,19 +46,56 @@
|
||||
<ColumnDefinition Width="auto"/>
|
||||
<ColumnDefinition Width="auto" />
|
||||
</Grid.ColumnDefinitions>
|
||||
<TextBlock Grid.Row="0" Grid.Column="0" VerticalAlignment="Center">Email:</TextBlock>
|
||||
<TextBlock Grid.Row="0" Grid.Column="0" VerticalAlignment="Center" Style="{StaticResource PhoneTextTitle2Style}">Email:</TextBlock>
|
||||
<lui:EmailButton Grid.Row="0" Grid.Column="1" EmailAddress="campusapp@tu-cottbus.de" Height="100" />
|
||||
|
||||
|
||||
<TextBlock Grid.Row="1" Grid.Column="0" VerticalAlignment="Center">Website:</TextBlock>
|
||||
<TextBlock Grid.Row="1" Grid.Column="0" VerticalAlignment="Center" Style="{StaticResource PhoneTextTitle2Style}">Website:</TextBlock>
|
||||
<lui:LinkButton Grid.Row="1" Grid.Column="1" Url="http://www.tu-cottbus.de/btu/de/service/redaktionssystem/?beitrag_id=80012374" Height="100"/>
|
||||
|
||||
|
||||
<TextBlock Grid.Row="2" Grid.Column="0" VerticalAlignment="Center">Facebook:</TextBlock>
|
||||
<TextBlock Grid.Row="2" Grid.Column="0" VerticalAlignment="Center" Style="{StaticResource PhoneTextTitle2Style}">Facebook:</TextBlock>
|
||||
<lui:LinkButton Grid.Row="2" Grid.Column="1" Url="https://www.facebook.com/btucampusapp" Height="100"/>
|
||||
|
||||
</Grid>
|
||||
</StackPanel>
|
||||
<TextBlock Style="{StaticResource PhoneTextGroupHeaderStyle}">Versionshinweise</TextBlock>
|
||||
<TextBlock Style="{StaticResource PhoneTextTitle2Style}" Margin="24,0,0,12">Version 1.1:</TextBlock>
|
||||
<TextBlock TextWrapping="Wrap" Margin="36,0,0,0">
|
||||
- neue Funktionen:<LineBreak/>
|
||||
- Stundenplan<LineBreak/>
|
||||
- Wahl der Akzentfarbe<LineBreak/>
|
||||
- Änderungen<LineBreak/>
|
||||
- Überarbeitetes Layout der Startseite<LineBreak/>
|
||||
- Überarbeitetes Einstellungsmenu<LineBreak/>
|
||||
- Überarbeitet Raumübersicht<LineBreak/>
|
||||
</TextBlock>
|
||||
<TextBlock Style="{StaticResource PhoneTextTitle2Style}" Margin="24,0,0,12">Version 1.0.0.1:</TextBlock>
|
||||
<TextBlock TextWrapping="Wrap" Margin="36,0,0,0">
|
||||
- Bugfixes:<LineBreak/>
|
||||
- Beseitigung eines Fehler beim starten der App<LineBreak/>
|
||||
</TextBlock>
|
||||
<TextBlock Style="{StaticResource PhoneTextTitle2Style}" Margin="24,0,0,12">Version 1.0:</TextBlock>
|
||||
<TextBlock TextWrapping="Wrap" Margin="36,0,0,0">
|
||||
Initaler Release <LineBreak/>
|
||||
Funktionsübersicht:<LineBreak/>
|
||||
- Vorlesungsverzeichnis (Vorlesungen, Übungen, Prüfungen etc.)<LineBreak/>
|
||||
- Mensaplan<LineBreak/>
|
||||
- Lehrstuhlübersicht<LineBreak/>
|
||||
- Fachschaftenübersicht<LineBreak/>
|
||||
- Prüfungsordnung<LineBreak/>
|
||||
- Personsuche (Mitarbeiter)<LineBreak/>
|
||||
- BTU Webmail<LineBreak/>
|
||||
- Öffnungszeiten<LineBreak/>
|
||||
- Verzeichnis mit nützlichen Links<LineBreak/>
|
||||
- News und Events rund um den Campus<LineBreak/>
|
||||
- mit Text-to-Speech−Funktion<LineBreak/>
|
||||
- Campusplan :<LineBreak/>
|
||||
- Gebäudesuchfunktion<LineBreak/>
|
||||
- Lokalisierung mittles GPS oder BTU-Tag (QR-Codes, NFC-Tags)<LineBreak/>
|
||||
- Ebenenpläne für das IKMZ und MZG<LineBreak/>
|
||||
</TextBlock>
|
||||
</StackPanel>
|
||||
</ScrollViewer>
|
||||
</Grid>
|
||||
</Grid>
|
||||
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
<page:PortraitLandscapePage
|
||||
<phone:PhoneApplicationPage
|
||||
x:Class="CampusAppWP8.Pages.StartPage"
|
||||
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
|
||||
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
|
||||
@@ -8,11 +8,10 @@
|
||||
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
|
||||
xmlns:lui="clr-namespace:CampusAppWP8.Utility.Lui.Button"
|
||||
xmlns:toolkit="clr-namespace:Microsoft.Phone.Controls;assembly=Microsoft.Phone.Controls.Toolkit"
|
||||
xmlns:page="clr-namespace:CampusAppWP8.Utility.Lui.Page"
|
||||
FontFamily="{StaticResource PhoneFontFamilyNormal}"
|
||||
FontSize="{StaticResource PhoneFontSizeNormal}"
|
||||
Foreground="{StaticResource PhoneForegroundBrush}"
|
||||
SupportedOrientations="PortraitOrLandscape" Orientation="Portrait"
|
||||
SupportedOrientations="Portrait" Orientation="Portrait"
|
||||
mc:Ignorable="d"
|
||||
shell:SystemTray.IsVisible="True">
|
||||
|
||||
@@ -27,8 +26,7 @@
|
||||
|
||||
<!--Panoramaelement eins-->
|
||||
<phone:PanoramaItem Name="Item1">
|
||||
<ScrollViewer Name="scoller1" Margin="12 -24 12 0">
|
||||
<StackPanel>
|
||||
<StackPanel Margin="12 -24 12 0">
|
||||
<lui:NavigateButton x:Name="TimeTableAppButton" Style="{StaticResource StartPageButtonLong}" Grid.Column="0" Url="{Binding Path=Constants.PathTimeTable_Day, Source={StaticResource Const}}" Click="TimeTable_Click">
|
||||
<StackPanel Style="{StaticResource StartPageStackPanelStyleLong}">
|
||||
<StackPanel Background="{StaticResource PhoneAccentBrush}" Margin="0 0 12 0">
|
||||
@@ -121,14 +119,12 @@
|
||||
</toolkit:ContextMenuService.ContextMenu>
|
||||
</lui:NavigateButton>
|
||||
</StackPanel>
|
||||
</ScrollViewer>
|
||||
</phone:PanoramaItem>
|
||||
|
||||
<!--Panoramaelement zwei-->
|
||||
<phone:PanoramaItem Orientation="Horizontal"
|
||||
Name="Item2">
|
||||
<ScrollViewer Name="scoller2" Margin="12 -24 12 0">
|
||||
<StackPanel>
|
||||
<StackPanel Margin="12 -24 12 0">
|
||||
<Grid Name="Row0">
|
||||
<Grid.ColumnDefinitions>
|
||||
<ColumnDefinition Width="*"/>
|
||||
@@ -237,7 +233,7 @@
|
||||
<lui:NavigateButton Name="OpenHoursAppButton" Url="{Binding Path=Constants.PathOpeninghours_OpeninghoursPage, Source={StaticResource Const}}" Grid.Column="1" Style="{StaticResource StartPageButton}">
|
||||
<StackPanel Style="{StaticResource StartPageStackPanelStyle}">
|
||||
<Image Source="{Binding Path=ThemelizedIcon.Openhours, Source={StaticResource ThemelizedIcons}}" Style="{StaticResource StartPageButtonImg}"/>
|
||||
<TextBlock Name="OpenHoursAppButtonText" Text="{Binding Path=LocalizedResources.OpenHoursApp_Title, Source={StaticResource LocalizedStrings}}" Style="{StaticResource StartPageButtonText}"/>
|
||||
<TextBlock Name="OpenHoursAppButtonText" Text="{Binding Path=LocalizedResources.OpenHoursApp_Title2, Source={StaticResource LocalizedStrings}}" Style="{StaticResource StartPageButtonText}"/>
|
||||
</StackPanel>
|
||||
<toolkit:ContextMenuService.ContextMenu>
|
||||
<toolkit:ContextMenu>
|
||||
@@ -273,7 +269,6 @@
|
||||
</lui:NavigateButton>
|
||||
</Grid>
|
||||
</StackPanel>
|
||||
</ScrollViewer>
|
||||
</phone:PanoramaItem>
|
||||
|
||||
<!--Panoramaelement drei
|
||||
@@ -305,7 +300,6 @@
|
||||
</phone:PanoramaItem>-->
|
||||
|
||||
<phone:PanoramaItem Header="Einstellungen" Name="Item3">
|
||||
<ScrollViewer Name="scoller3">
|
||||
<StackPanel Background="{StaticResource PhoneSemitransparentBrush}" VerticalAlignment="Top">
|
||||
<lui:NavigateButton Url="{Binding Path=Constants.PathSetting_User, Source={StaticResource Const}}" BorderThickness="0" HorizontalContentAlignment="Left">
|
||||
<TextBlock Text="{Binding Path=LocalizedResources.Setting_UserInfo, Source={StaticResource LocalizedStrings}}" HorizontalAlignment="Left" Style="{StaticResource PhoneTextTitle2Style}" />
|
||||
@@ -313,18 +307,15 @@
|
||||
<lui:NavigateButton Url="{Binding Path=Constants.PathSetting_App, Source={StaticResource Const}}" BorderThickness="0" HorizontalContentAlignment="Left">
|
||||
<TextBlock Text="{Binding Path=LocalizedResources.Setting_General, Source={StaticResource LocalizedStrings}}" HorizontalAlignment="Left" Style="{StaticResource PhoneTextTitle2Style}" />
|
||||
</lui:NavigateButton>
|
||||
<lui:NavigateButton Url="{Binding Path=Constants.PathSetting_App, Source={StaticResource Const}}" BorderThickness="0" HorizontalContentAlignment="Left">
|
||||
<!-- <lui:NavigateButton Url="{Binding Path=Constants.PathSetting_App, Source={StaticResource Const}}" BorderThickness="0" HorizontalContentAlignment="Left">
|
||||
<TextBlock Text="{Binding Path=LocalizedResources.Setting_Other, Source={StaticResource LocalizedStrings}}" HorizontalAlignment="Left" Style="{StaticResource PhoneTextTitle2Style}" />
|
||||
</lui:NavigateButton>
|
||||
</lui:NavigateButton> -->
|
||||
<lui:NavigateButton Url="{Binding Path=Constants.PathSetting_Impressum, Source={StaticResource Const}}" BorderThickness="0" HorizontalContentAlignment="Left">
|
||||
<TextBlock Text="{Binding Path=LocalizedResources.Setting_ImpressumTitle, Source={StaticResource LocalizedStrings}}" HorizontalAlignment="Left" Style="{StaticResource PhoneTextTitle2Style}" />
|
||||
</lui:NavigateButton>
|
||||
</StackPanel>
|
||||
</ScrollViewer>
|
||||
</phone:PanoramaItem>
|
||||
|
||||
</phone:Panorama>
|
||||
</Grid>
|
||||
|
||||
|
||||
</page:PortraitLandscapePage>
|
||||
</phone:PhoneApplicationPage>
|
||||
@@ -12,26 +12,23 @@ namespace CampusAppWP8.Pages
|
||||
using System.Runtime.InteropServices.WindowsRuntime;
|
||||
using System.Threading;
|
||||
using System.Windows;
|
||||
using System.Windows.Controls;
|
||||
using System.Windows.Navigation;
|
||||
using CampusAppWP8.Feed.Utility;
|
||||
using CampusAppWP8.File.Places;
|
||||
using CampusAppWP8.Model.Setting;
|
||||
using CampusAppWP8.Pages.TimeTable;
|
||||
using CampusAppWP8.Resources;
|
||||
using CampusAppWP8.Utility;
|
||||
using CampusAppWP8.Utility.Lui.MessageBoxes;
|
||||
using CampusAppWP8.Utility.Lui.Page;
|
||||
using CampusAppWP8.Utility.Lui.Tiles;
|
||||
using CampusAppWP8.Utility.NDEF;
|
||||
using Microsoft.Phone.Controls;
|
||||
using Microsoft.Phone.Shell;
|
||||
using Windows.Networking.Proximity;
|
||||
using Microsoft.Phone.Controls;
|
||||
|
||||
/// <summary> Class for the StartPage. </summary>
|
||||
/// <remarks> Stubbfel, 15.10.2013. </remarks>
|
||||
/// <seealso cref="T:Microsoft.Phone.Controls.PhoneApplicationPage"/>
|
||||
public partial class StartPage : PortraitLandscapePage
|
||||
public partial class StartPage : PhoneApplicationPage
|
||||
{
|
||||
#region Member
|
||||
|
||||
@@ -75,7 +72,7 @@ namespace CampusAppWP8.Pages
|
||||
|
||||
#region protected
|
||||
|
||||
/// <summary> Methods overrides the OnNavigatedTo-Method. </summary>
|
||||
/// <summary> Methods overrides the OnNavigatedTo-Method. </summary>
|
||||
/// <remarks> Stubbfel, 15.10.2013. </remarks>
|
||||
/// <seealso cref="M:System.Windows.Controls.Page.OnNavigatedTo(NavigationEventArgs)"/>
|
||||
protected override void OnNavigatedTo(NavigationEventArgs e)
|
||||
@@ -84,7 +81,7 @@ namespace CampusAppWP8.Pages
|
||||
if (device != null)
|
||||
{
|
||||
this.ndefId = this.device.SubscribeForMessage(Constants.NCFMessageType_NDEF, this.NDEFHandler);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary> Methods overrides the OnNavigatedFrom-Method. </summary>
|
||||
@@ -123,7 +120,7 @@ namespace CampusAppWP8.Pages
|
||||
/// <remarks> Stubbfel, 15.10.2013. </remarks>
|
||||
/// <param name="sender"> Caller of the function. </param>
|
||||
/// <param name="e"> some EventArgs. </param>
|
||||
private void NFCButton_Click(object sender,RoutedEventArgs e)
|
||||
private void NFCButton_Click(object sender, RoutedEventArgs e)
|
||||
{
|
||||
MessageBoxes.ShowMainModelInfoMessageBox(AppResources.ScarNfc_Search);
|
||||
}
|
||||
|
||||
@@ -60,6 +60,24 @@ namespace CampusAppWP8.Resources {
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Sucht eine lokalisierte Zeichenfolge, die Akzentfarbe ähnelt.
|
||||
/// </summary>
|
||||
public static string AccentColor {
|
||||
get {
|
||||
return ResourceManager.GetString("AccentColor", resourceCulture);
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Sucht eine lokalisierte Zeichenfolge, die Akzentfarbe-Auswahl ähnelt.
|
||||
/// </summary>
|
||||
public static string AccentColorPicker {
|
||||
get {
|
||||
return ResourceManager.GetString("AccentColorPicker", resourceCulture);
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Sucht eine lokalisierte Zeichenfolge, die Hinzufügen ähnelt.
|
||||
/// </summary>
|
||||
@@ -1285,7 +1303,7 @@ namespace CampusAppWP8.Resources {
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Sucht eine lokalisierte Zeichenfolge, die Über BTU Campus-App ähnelt.
|
||||
/// Sucht eine lokalisierte Zeichenfolge, die Über BTU CampusApp ähnelt.
|
||||
/// </summary>
|
||||
public static string Setting_ImpressumTitle {
|
||||
get {
|
||||
|
||||
@@ -570,7 +570,7 @@
|
||||
<value>BTU-Tag-Standardfunktion</value>
|
||||
</data>
|
||||
<data name="Setting_ImpressumTitle" xml:space="preserve">
|
||||
<value>Über BTU Campus-App</value>
|
||||
<value>Über BTU CampusApp</value>
|
||||
</data>
|
||||
<data name="BTUTag_WrongTag" xml:space="preserve">
|
||||
<value>Der eingescannte Tag ist kein BTU-Tag</value>
|
||||
@@ -662,4 +662,10 @@
|
||||
<data name="Setting_Mensa" xml:space="preserve">
|
||||
<value>Mensa</value>
|
||||
</data>
|
||||
<data name="AccentColor" xml:space="preserve">
|
||||
<value>Akzentfarbe</value>
|
||||
</data>
|
||||
<data name="AccentColorPicker" xml:space="preserve">
|
||||
<value>Akzentfarbe-Auswahl</value>
|
||||
</data>
|
||||
</root>
|
||||
@@ -680,5 +680,46 @@
|
||||
</data>
|
||||
<data name="ParamDay" xml:space="preserve">
|
||||
<value>paramday</value>
|
||||
<data name="Setting_AppAccentColor" xml:space="preserve">
|
||||
<value>AppAccentColor</value>
|
||||
</data>
|
||||
<data name="Setting_PhoneAccentColor" xml:space="preserve">
|
||||
<value>PhoneAccentColor</value>
|
||||
</data>
|
||||
<data name="Brush_Faculty1" xml:space="preserve">
|
||||
<value>FacultyBrush1</value>
|
||||
</data>
|
||||
<data name="Brush_Faculty2" xml:space="preserve">
|
||||
<value>FacultyBrush2</value>
|
||||
</data>
|
||||
<data name="Brush_Faculty3" xml:space="preserve">
|
||||
<value>FacultyBrush3</value>
|
||||
</data>
|
||||
<data name="Brush_Faculty4" xml:space="preserve">
|
||||
<value>FacultyBrush4</value>
|
||||
</data>
|
||||
<data name="Brush_Faculty5" xml:space="preserve">
|
||||
<value>FacultyBrush5</value>
|
||||
</data>
|
||||
<data name="Brush_PhoneAccent" xml:space="preserve">
|
||||
<value>PhoneAccentBrush</value>
|
||||
</data>
|
||||
<data name="Color_Faculty1" xml:space="preserve">
|
||||
<value>FacultyColor1</value>
|
||||
</data>
|
||||
<data name="Color_Faculty2" xml:space="preserve">
|
||||
<value>FacultyColor2</value>
|
||||
</data>
|
||||
<data name="Color_Faculty3" xml:space="preserve">
|
||||
<value>FacultyColor3</value>
|
||||
</data>
|
||||
<data name="Color_Faculty4" xml:space="preserve">
|
||||
<value>FacultyColor4</value>
|
||||
</data>
|
||||
<data name="Color_Faculty5" xml:space="preserve">
|
||||
<value>FacultyColor5</value>
|
||||
</data>
|
||||
<data name="Color_PhoneAccent" xml:space="preserve">
|
||||
<value>PhoneAccentColor</value>
|
||||
</data>
|
||||
</root>
|
||||
@@ -204,6 +204,60 @@ namespace CampusAppWP8.Resources {
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Sucht eine lokalisierte Zeichenfolge, die FacultyBrush1 ähnelt.
|
||||
/// </summary>
|
||||
public static string Brush_Faculty1 {
|
||||
get {
|
||||
return ResourceManager.GetString("Brush_Faculty1", resourceCulture);
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Sucht eine lokalisierte Zeichenfolge, die FacultyBrush2 ähnelt.
|
||||
/// </summary>
|
||||
public static string Brush_Faculty2 {
|
||||
get {
|
||||
return ResourceManager.GetString("Brush_Faculty2", resourceCulture);
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Sucht eine lokalisierte Zeichenfolge, die FacultyBrush3 ähnelt.
|
||||
/// </summary>
|
||||
public static string Brush_Faculty3 {
|
||||
get {
|
||||
return ResourceManager.GetString("Brush_Faculty3", resourceCulture);
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Sucht eine lokalisierte Zeichenfolge, die FacultyBrush4 ähnelt.
|
||||
/// </summary>
|
||||
public static string Brush_Faculty4 {
|
||||
get {
|
||||
return ResourceManager.GetString("Brush_Faculty4", resourceCulture);
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Sucht eine lokalisierte Zeichenfolge, die FacultyBrush5 ähnelt.
|
||||
/// </summary>
|
||||
public static string Brush_Faculty5 {
|
||||
get {
|
||||
return ResourceManager.GetString("Brush_Faculty5", resourceCulture);
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Sucht eine lokalisierte Zeichenfolge, die PhoneAccentBrush ähnelt.
|
||||
/// </summary>
|
||||
public static string Brush_PhoneAccent {
|
||||
get {
|
||||
return ResourceManager.GetString("Brush_PhoneAccent", resourceCulture);
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Sucht eine lokalisierte Zeichenfolge, die BTU-CampusApp ähnelt.
|
||||
/// </summary>
|
||||
@@ -222,6 +276,60 @@ namespace CampusAppWP8.Resources {
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Sucht eine lokalisierte Zeichenfolge, die FacultyColor1 ähnelt.
|
||||
/// </summary>
|
||||
public static string Color_Faculty1 {
|
||||
get {
|
||||
return ResourceManager.GetString("Color_Faculty1", resourceCulture);
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Sucht eine lokalisierte Zeichenfolge, die FacultyColor2 ähnelt.
|
||||
/// </summary>
|
||||
public static string Color_Faculty2 {
|
||||
get {
|
||||
return ResourceManager.GetString("Color_Faculty2", resourceCulture);
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Sucht eine lokalisierte Zeichenfolge, die FacultyColor3 ähnelt.
|
||||
/// </summary>
|
||||
public static string Color_Faculty3 {
|
||||
get {
|
||||
return ResourceManager.GetString("Color_Faculty3", resourceCulture);
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Sucht eine lokalisierte Zeichenfolge, die FacultyColor4 ähnelt.
|
||||
/// </summary>
|
||||
public static string Color_Faculty4 {
|
||||
get {
|
||||
return ResourceManager.GetString("Color_Faculty4", resourceCulture);
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Sucht eine lokalisierte Zeichenfolge, die FacultyColor5 ähnelt.
|
||||
/// </summary>
|
||||
public static string Color_Faculty5 {
|
||||
get {
|
||||
return ResourceManager.GetString("Color_Faculty5", resourceCulture);
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Sucht eine lokalisierte Zeichenfolge, die PhoneAccentColor ähnelt.
|
||||
/// </summary>
|
||||
public static string Color_PhoneAccent {
|
||||
get {
|
||||
return ResourceManager.GetString("Color_PhoneAccent", resourceCulture);
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Sucht eine lokalisierte Zeichenfolge, die 8 ähnelt.
|
||||
/// </summary>
|
||||
@@ -1392,6 +1500,15 @@ namespace CampusAppWP8.Resources {
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Sucht eine lokalisierte Zeichenfolge, die AppAccentColor ähnelt.
|
||||
/// </summary>
|
||||
public static string Setting_AppAccentColor {
|
||||
get {
|
||||
return ResourceManager.GetString("Setting_AppAccentColor", resourceCulture);
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Sucht eine lokalisierte Zeichenfolge, die AppSetting ähnelt.
|
||||
/// </summary>
|
||||
@@ -1491,6 +1608,15 @@ namespace CampusAppWP8.Resources {
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Sucht eine lokalisierte Zeichenfolge, die PhoneAccentColor ähnelt.
|
||||
/// </summary>
|
||||
public static string Setting_PhoneAccentColor {
|
||||
get {
|
||||
return ResourceManager.GetString("Setting_PhoneAccentColor", resourceCulture);
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Sucht eine lokalisierte Zeichenfolge, die UserSetting ähnelt.
|
||||
/// </summary>
|
||||
|
||||
@@ -22,8 +22,8 @@
|
||||
<Setter Property="HorizontalContentAlignment" Value="Stretch"/>
|
||||
<Setter Property="BorderThickness" Value="0"/>
|
||||
<Setter Property="Padding" Value="0"/>
|
||||
<Setter Property="Width" Value="200"/>
|
||||
<Setter Property="Height" Value="200"/>
|
||||
<Setter Property="Width" Value="193"/>
|
||||
<Setter Property="Height" Value="193"/>
|
||||
<Setter Property="toolkit:TiltEffect.IsTiltEnabled" Value="True"/>
|
||||
</Style>
|
||||
<Style x:Key="StartPageButtonLong" TargetType="Button">
|
||||
|
||||
16
CampusAppWP8/CampusAppWP8/Styles/UniColors.xaml
Normal file
16
CampusAppWP8/CampusAppWP8/Styles/UniColors.xaml
Normal file
@@ -0,0 +1,16 @@
|
||||
<ResourceDictionary
|
||||
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
|
||||
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
|
||||
xmlns:System="clr-namespace:System;assembly=mscorlib">
|
||||
|
||||
<Color x:Key="FacultyColor1">#d20078</Color>
|
||||
<Color x:Key="FacultyColor2">#0050a0</Color>
|
||||
<Color x:Key="FacultyColor3">#009bd2</Color>
|
||||
<Color x:Key="FacultyColor4">#a5c300</Color>
|
||||
<Color x:Key="FacultyColor5">#ff9900</Color>
|
||||
<SolidColorBrush x:Key="FacultyBrush1">#d20078</SolidColorBrush>
|
||||
<SolidColorBrush x:Key="FacultyBrush2">#0050a0</SolidColorBrush>
|
||||
<SolidColorBrush x:Key="FacultyBrush3">#009bd2</SolidColorBrush>
|
||||
<SolidColorBrush x:Key="FacultyBrush4">#a5c300</SolidColorBrush>
|
||||
<SolidColorBrush x:Key="FacultyBrush5">#ff9900</SolidColorBrush>
|
||||
</ResourceDictionary>
|
||||
@@ -445,6 +445,31 @@ namespace CampusAppWP8.Utility
|
||||
obj.SelectedIndex = -1;
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary> Switch color. </summary>
|
||||
/// <remarks> Stubbfel, 26.11.2013. </remarks>
|
||||
/// <param name="ressourceKey"> The ressource key. </param>
|
||||
/// <param name="newColor"> The new color. </param>
|
||||
public static void SwitchColor(string ressourceKey, Color newColor)
|
||||
{
|
||||
SolidColorBrush oldColor = App.Current.Resources[ressourceKey] as SolidColorBrush;
|
||||
|
||||
if (oldColor == null || oldColor.Color.Equals(newColor))
|
||||
{
|
||||
return;
|
||||
}
|
||||
App.Current.Resources.Remove(ressourceKey);
|
||||
App.Current.Resources.Add(ressourceKey, newColor);
|
||||
}
|
||||
|
||||
/// <summary> Switch accent color. </summary>
|
||||
/// <remarks> Stubbfel, 26.11.2013. </remarks>
|
||||
/// <param name="newColor"> The new color. </param>
|
||||
public static void SwitchAccentColor(Color newColor)
|
||||
{
|
||||
Utilities.SwitchColor(Constants.Color_PhoneAccent, newColor);
|
||||
((SolidColorBrush)App.Current.Resources[Constants.Brush_PhoneAccent]).Color = newColor;
|
||||
}
|
||||
#endregion
|
||||
}
|
||||
}
|
||||
@@ -91,7 +91,9 @@
|
||||
<Compile Include="Model\Utility\DegreeListPickerItemListModel.cs" />
|
||||
<Compile Include="Model\Utility\GeoMapPoint.cs" />
|
||||
<Compile Include="Model\Utility\ListPickerItemListModel.cs" />
|
||||
<Compile Include="Model\Utility\ListPickerItemListTemplateModel.cs" />
|
||||
<Compile Include="Model\Utility\ListPickerItemModel.cs" />
|
||||
<Compile Include="Model\Utility\ListPickerItemTemplateModel.cs" />
|
||||
<Compile Include="Model\Utility\MapPoint.cs" />
|
||||
<Compile Include="Model\Utility\RoleListPickerItemListModel.cs" />
|
||||
<Compile Include="Model\Utility\SemesterListPickerItemListModel.cs">
|
||||
|
||||
@@ -70,6 +70,10 @@ namespace CampusAppWPortalLib8.Model.Mensa
|
||||
/// <returns> The canteen. </returns>
|
||||
public PriceCanteenModel GetCanteen(Campus campus)
|
||||
{
|
||||
if (campus == Campus.CB_NORTH)
|
||||
{
|
||||
return this.GetCanteen((int)Campus.CB_MAIN - 1);
|
||||
}
|
||||
return this.GetCanteen((int)campus - 1);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -12,15 +12,8 @@ namespace CampusAppWPortalLib8.Model.Utility
|
||||
|
||||
/// <summary> Class for a List of ListPickerItems. </summary>
|
||||
/// <remarks> Stubbfel, 15.10.2013. </remarks>
|
||||
public class ListPickerItemListModel
|
||||
public class ListPickerItemListModel : ListPickerItemListTemplateModel<string>
|
||||
{
|
||||
#region Members
|
||||
|
||||
/// <summary> reference of the itemList. </summary>
|
||||
private List<ListPickerItemModel> list;
|
||||
|
||||
#endregion
|
||||
|
||||
#region Constructor
|
||||
|
||||
/// <summary>
|
||||
@@ -28,109 +21,10 @@ namespace CampusAppWPortalLib8.Model.Utility
|
||||
/// </summary>
|
||||
/// <remarks> Stubbfel, 15.10.2013. </remarks>
|
||||
public ListPickerItemListModel()
|
||||
: base()
|
||||
{
|
||||
this.list = new List<ListPickerItemModel>();
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
#region Property
|
||||
|
||||
/// <summary> Gets or sets the ItemList. </summary>
|
||||
/// <value> The list. </value>
|
||||
public List<ListPickerItemModel> List
|
||||
{
|
||||
get
|
||||
{
|
||||
return this.list;
|
||||
}
|
||||
|
||||
set
|
||||
{
|
||||
if (value != this.list)
|
||||
{
|
||||
this.list = value;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
#region Method
|
||||
|
||||
#region public
|
||||
|
||||
/// <summary> Method return a the Index of an item which has a certain value. </summary>
|
||||
/// <remarks> Stubbfel, 15.10.2013. </remarks>
|
||||
/// <param name="value"> a certain value. </param>
|
||||
/// <returns> return index of value or default(0) </returns>
|
||||
public virtual int GetIndexOrDefault(string value)
|
||||
{
|
||||
int index = 0;
|
||||
int i = 0;
|
||||
foreach (ListPickerItemModel item in this.list)
|
||||
{
|
||||
if (item.Value.Equals(value))
|
||||
{
|
||||
index = i;
|
||||
break;
|
||||
}
|
||||
|
||||
i++;
|
||||
}
|
||||
|
||||
return index;
|
||||
}
|
||||
|
||||
/// <summary> add an new item to the list. </summary>
|
||||
/// <remarks> Stubbfel, 15.10.2013. </remarks>
|
||||
/// <param name="value"> value of the item. </param>
|
||||
/// <param name="text"> text of the item. </param>
|
||||
public void AddItem(string value, string text)
|
||||
{
|
||||
this.AddItem(new ListPickerItemModel(value, text));
|
||||
}
|
||||
|
||||
/// <summary> add an new item to the list. </summary>
|
||||
/// <remarks> Stubbfel, 15.10.2013. </remarks>
|
||||
/// <param name="item"> new item of the list. </param>
|
||||
public void AddItem(ListPickerItemModel item)
|
||||
{
|
||||
this.list.Add(item);
|
||||
}
|
||||
|
||||
/// <summary> remove an item. </summary>
|
||||
/// <remarks> Stubbfel, 15.10.2013. </remarks>
|
||||
/// <param name="value"> value of the item. </param>
|
||||
/// <param name="text"> text of the item. </param>
|
||||
/// <returns> true if removing was successful, otherwise false. </returns>
|
||||
public bool RemoveItem(string value, string text)
|
||||
{
|
||||
return this.RemoveItem(new ListPickerItemModel(value, text));
|
||||
}
|
||||
|
||||
/// <summary> remove an item. </summary>
|
||||
/// <remarks> Stubbfel, 15.10.2013. </remarks>
|
||||
/// <param name="item"> item which has to be remove. </param>
|
||||
/// <returns> true if removing was successful, otherwise false. </returns>
|
||||
public bool RemoveItem(ListPickerItemModel item)
|
||||
{
|
||||
return this.list.Remove(item);
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
#region protected
|
||||
|
||||
/// <summary> Method load an default list. </summary>
|
||||
/// <remarks> load an empty list. </remarks>
|
||||
protected virtual void LoadList()
|
||||
{
|
||||
return;
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
#endregion
|
||||
}
|
||||
}
|
||||
|
||||
@@ -0,0 +1,135 @@
|
||||
//-----------------------------------------------------------------------
|
||||
// <copyright file="ListPickerItemListTemplateModel.cs" company="BTU/IIT">
|
||||
// The MIT License (MIT). Copyright (c) 2013 BTU/IIT.
|
||||
// </copyright>
|
||||
// <author>Stubbfel</author>
|
||||
// <date>26.11.2013</date>
|
||||
// <summary>Implements the list picker item list template model class</summary>
|
||||
//-----------------------------------------------------------------------
|
||||
namespace CampusAppWPortalLib8.Model.Utility
|
||||
{
|
||||
using System.Collections.Generic;
|
||||
|
||||
/// <summary> A data Model for the list picker item list template. </summary>
|
||||
/// <remarks> Stubbfel, 26.11.2013. </remarks>
|
||||
/// <typeparam name="T"> Generic type parameter. </typeparam>
|
||||
public class ListPickerItemListTemplateModel<T>
|
||||
{
|
||||
#region Members
|
||||
|
||||
/// <summary> reference of the itemList. </summary>
|
||||
private List<ListPickerItemTemplateModel<T>> list;
|
||||
|
||||
#endregion
|
||||
|
||||
#region Constructor
|
||||
|
||||
/// <summary> Initializes a new instance of the ListPickerItemListTemplateModel class. </summary>
|
||||
/// <remarks> Stubbfel, 26.11.2013. </remarks>
|
||||
public ListPickerItemListTemplateModel()
|
||||
{
|
||||
this.list = new List<ListPickerItemTemplateModel<T>>();
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
#region Property
|
||||
|
||||
/// <summary> Gets or sets the ItemList. </summary>
|
||||
/// <value> The list. </value>
|
||||
public List<ListPickerItemTemplateModel<T>> List
|
||||
{
|
||||
get
|
||||
{
|
||||
return this.list;
|
||||
}
|
||||
|
||||
set
|
||||
{
|
||||
if (value != this.list)
|
||||
{
|
||||
this.list = value;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
#region Method
|
||||
|
||||
#region public
|
||||
|
||||
/// <summary> Method return a the Index of an item which has a certain value. </summary>
|
||||
/// <remarks> Stubbfel, 15.10.2013. </remarks>
|
||||
/// <param name="value"> a certain value. </param>
|
||||
/// <returns> return index of value or default(0) </returns>
|
||||
public virtual int GetIndexOrDefault(T value)
|
||||
{
|
||||
int index = 0;
|
||||
int i = 0;
|
||||
foreach (ListPickerItemTemplateModel<T> item in this.list)
|
||||
{
|
||||
if (item.Value.Equals(value))
|
||||
{
|
||||
index = i;
|
||||
break;
|
||||
}
|
||||
|
||||
i++;
|
||||
}
|
||||
|
||||
return index;
|
||||
}
|
||||
|
||||
/// <summary> add an new item to the list. </summary>
|
||||
/// <remarks> Stubbfel, 15.10.2013. </remarks>
|
||||
/// <param name="value"> value of the item. </param>
|
||||
/// <param name="text"> text of the item. </param>
|
||||
public void AddItem(T value, string text)
|
||||
{
|
||||
this.AddItem(new ListPickerItemTemplateModel<T>(value, text));
|
||||
}
|
||||
|
||||
/// <summary> add an new item to the list. </summary>
|
||||
/// <remarks> Stubbfel, 15.10.2013. </remarks>
|
||||
/// <param name="item"> new item of the list. </param>
|
||||
public void AddItem(ListPickerItemTemplateModel<T> item)
|
||||
{
|
||||
this.list.Add(item);
|
||||
}
|
||||
|
||||
/// <summary> remove an item. </summary>
|
||||
/// <remarks> Stubbfel, 15.10.2013. </remarks>
|
||||
/// <param name="value"> value of the item. </param>
|
||||
/// <param name="text"> text of the item. </param>
|
||||
/// <returns> true if removing was successful, otherwise false. </returns>
|
||||
public bool RemoveItem(T value, string text)
|
||||
{
|
||||
return this.RemoveItem(new ListPickerItemTemplateModel<T>(value, text));
|
||||
}
|
||||
|
||||
/// <summary> remove an item. </summary>
|
||||
/// <remarks> Stubbfel, 15.10.2013. </remarks>
|
||||
/// <param name="item"> item which has to be remove. </param>
|
||||
/// <returns> true if removing was successful, otherwise false. </returns>
|
||||
public bool RemoveItem(ListPickerItemTemplateModel<T> item)
|
||||
{
|
||||
return this.list.Remove(item);
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
#region protected
|
||||
|
||||
/// <summary> Method load an default list. </summary>
|
||||
/// <remarks> load an empty list. </remarks>
|
||||
protected virtual void LoadList()
|
||||
{
|
||||
return;
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
#endregion
|
||||
}
|
||||
}
|
||||
@@ -10,7 +10,7 @@ namespace CampusAppWPortalLib8.Model.Utility
|
||||
{
|
||||
/// <summary> Model for the ListPickerItems. </summary>
|
||||
/// <remarks> Stubbfel, 15.10.2013. </remarks>
|
||||
public class ListPickerItemModel
|
||||
public class ListPickerItemModel : ListPickerItemTemplateModel<string>
|
||||
{
|
||||
#region Constructor
|
||||
|
||||
@@ -19,6 +19,7 @@ namespace CampusAppWPortalLib8.Model.Utility
|
||||
/// </summary>
|
||||
/// <remarks> Stubbfel, 15.10.2013. </remarks>
|
||||
public ListPickerItemModel()
|
||||
: base()
|
||||
{
|
||||
}
|
||||
|
||||
@@ -29,23 +30,10 @@ namespace CampusAppWPortalLib8.Model.Utility
|
||||
/// <param name="value"> string for the value property of an item. </param>
|
||||
/// <param name="text"> string for the text property of an item. </param>
|
||||
public ListPickerItemModel(string value, string text)
|
||||
: base(value, text)
|
||||
{
|
||||
this.Value = value;
|
||||
this.Text = text;
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
#region Property
|
||||
|
||||
/// <summary> Gets or sets the Value of an Item. </summary>
|
||||
/// <value> The value. </value>
|
||||
public string Value { get; set; }
|
||||
|
||||
/// <summary> Gets or sets the Text (caption) of an Item. </summary>
|
||||
/// <value> The text. </value>
|
||||
public string Text { get; set; }
|
||||
|
||||
#endregion
|
||||
}
|
||||
}
|
||||
|
||||
@@ -0,0 +1,48 @@
|
||||
//-----------------------------------------------------------------------
|
||||
// <copyright file="ListPickerItemTemplateModel.cs" company="BTU/IIT">
|
||||
// The MIT License (MIT). Copyright (c) 2013 BTU/IIT.
|
||||
// </copyright>
|
||||
// <author>Stubbfel</author>
|
||||
// <date>26.11.2013</date>
|
||||
// <summary>Implements the list picker item template model class</summary>
|
||||
//-----------------------------------------------------------------------
|
||||
namespace CampusAppWPortalLib8.Model.Utility
|
||||
{
|
||||
/// <summary> A data Model for the list picker item template. </summary>
|
||||
/// <remarks> Stubbfel, 26.11.2013. </remarks>
|
||||
/// <typeparam name="V"> Generic type parameter. </typeparam>
|
||||
public class ListPickerItemTemplateModel<V>
|
||||
{
|
||||
#region Constructor
|
||||
|
||||
/// <summary> Initializes a new instance of the ListPickerItemTemplateModel class. </summary>
|
||||
/// <remarks> Stubbfel, 26.11.2013. </remarks>
|
||||
public ListPickerItemTemplateModel()
|
||||
{
|
||||
}
|
||||
|
||||
/// <summary> Initializes a new instance of the ListPickerItemTemplateModel class. </summary>
|
||||
/// <remarks> Stubbfel, 26.11.2013. </remarks>
|
||||
/// <param name="value"> The value. </param>
|
||||
/// <param name="text"> The text. </param>
|
||||
public ListPickerItemTemplateModel(V value, string text)
|
||||
{
|
||||
this.Value = value;
|
||||
this.Text = text;
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
#region Property
|
||||
|
||||
/// <summary> Gets or sets the Value of an Item. </summary>
|
||||
/// <value> The value. </value>
|
||||
public V Value { get; set; }
|
||||
|
||||
/// <summary> Gets or sets the Text (caption) of an Item. </summary>
|
||||
/// <value> The text. </value>
|
||||
public string Text { get; set; }
|
||||
|
||||
#endregion
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user