This commit is contained in:
Christian Fiedler
2013-10-11 13:56:12 +02:00
parent 027de4972d
commit e78a03d403
3 changed files with 17 additions and 3 deletions

View File

@@ -179,7 +179,11 @@ namespace CampusAppWP8.Pages.Openinghours
MessageBoxResult result = MessageBoxes.ShowMainModelErrorMessageBox(AppResources.MsgBox_ErrorMainModelLoadFile);
}
/// <summary>
/// Method will be execute if the selection is change in the listbox.
/// </summary>
/// <param name="sender">listbox object.</param>
/// <param name="e">event args.</param>
private void InstitutionPanel_SelectionChanged(object sender, System.Windows.Controls.SelectionChangedEventArgs e)
{
this.InstitutionPanel.SelectedIndex = -1;

View File

@@ -64,7 +64,7 @@
<TextBlock Text="{Binding FullName}" TextWrapping="Wrap"/>
</lui:ToggleButton>
<StackPanel Tag="{Binding Path=Constants.ToggleContent, Source={StaticResource Const}}" Visibility="Collapsed">
<ListBox ItemsSource="{Binding Functions}" ScrollViewer.VerticalScrollBarVisibility="Disabled">
<ListBox ItemsSource="{Binding Functions}" ScrollViewer.VerticalScrollBarVisibility="Disabled" SelectionMode="Single" SelectionChanged="Box_SelectionChanged">
<ListBox.ItemContainerStyle>
<Style TargetType="ListBoxItem">
<Setter Property="HorizontalContentAlignment" Value="Stretch"/>

View File

@@ -19,6 +19,7 @@ namespace CampusAppWP8.Pages.Person
using Microsoft.Phone.Controls;
using Microsoft.Phone.Tasks;
using System.Collections.Generic;
using System.Windows.Controls;
/// <summary>Person page.</summary>
/// <remarks>Stubbfel, 09.09.2013.</remarks>
@@ -152,7 +153,16 @@ namespace CampusAppWP8.Pages.Person
}
}
#endregion
/// <summary>
/// Method is called when the selection in the listbox is changed.
/// </summary>
/// <param name="sender">listbox object.</param>
/// <param name="e">event args.</param>
private void Box_SelectionChanged(object sender, System.Windows.Controls.SelectionChangedEventArgs e)
{
(sender as ListBox).SelectedIndex = -1;
}
#endregion
}
}