summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGravatar Vitaly Takmazov2013-01-31 16:47:53 +0400
committerGravatar Vitaly Takmazov2013-01-31 16:47:53 +0400
commitfb20dfd7b1529d654c1ec9ad23dda1a427ac648c (patch)
treeea7f639f980fad33f23bc3b7c72a23a28233d81d
parent56b910c625fadcc712ba735a82a107e2bb0c9c41 (diff)
parent79317212ed6b3d26c3a2e765b6f58f9d43207f8d (diff)
Merge branch 'master' of https://bitbucket.org/vitalyster/juick-windowsphone
-rw-r--r--CommonResources/Application.svg20
-rw-r--r--CommonResources/SplashScreenImage.svg29
-rw-r--r--Juick/Classes/ScrollViewerMonitor.cs25
-rw-r--r--Juick/Juick.csproj4
-rw-r--r--Juick/LoginView.xaml4
-rw-r--r--Juick/MainPage.xaml245
-rw-r--r--Juick/MainPage.xaml.cs63
-rw-r--r--Juick/Properties/AssemblyInfo.cs4
-rw-r--r--Juick/SplashScreenImage.jpgbin9417 -> 17118 bytes
-rw-r--r--Juick/SubmissionInfo/ApplicationTile.pngbin1169 -> 0 bytes
-rw-r--r--Juick/SubmissionInfo/ApplicationTileMarket.pngbin1589 -> 4968 bytes
-rw-r--r--Juick/SubmissionInfo/ApplicationTileSmall.pngbin580 -> 0 bytes
-rw-r--r--Juick/SubmissionInfo/Settings.xml2
-rw-r--r--Juick/ThreadView.xaml.cs2
-rw-r--r--Juick/ViewModels/MessageViewModel.cs15
15 files changed, 228 insertions, 185 deletions
diff --git a/CommonResources/Application.svg b/CommonResources/Application.svg
new file mode 100644
index 0000000..36a47cc
--- /dev/null
+++ b/CommonResources/Application.svg
@@ -0,0 +1,20 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd">
+<svg xmlns="http://www.w3.org/2000/svg" xml:space="preserve" width="45.323mm" height="45.323mm" style="shape-rendering:geometricPrecision; text-rendering:geometricPrecision; image-rendering:optimizeQuality; fill-rule:evenodd; clip-rule:evenodd"
+viewBox="0 0 4532 4532"
+ xmlns:xlink="http://www.w3.org/1999/xlink">
+ <defs>
+ <style type="text/css">
+ <![CDATA[
+ .fil0 {fill:#FEFEFE}
+ ]]>
+ </style>
+ </defs>
+ <g id="Layer_x0020_1">
+ <metadata id="CorelCorpID_0Corel-Layer"/>
+ <g id="_271701456">
+ <path class="fil0" d="M2376 1626l607 4c-403,1897 -41,1719 -1520,1714l0 -294c19,0 54,0 67,0 0,26 0,52 0,70 690,2 528,117 845,-1494z"/>
+ <polygon class="fil0" points="2407,1481 2466,1182 3070,1181 3011,1481 "/>
+ </g>
+ </g>
+</svg>
diff --git a/CommonResources/SplashScreenImage.svg b/CommonResources/SplashScreenImage.svg
new file mode 100644
index 0000000..5cd1632
--- /dev/null
+++ b/CommonResources/SplashScreenImage.svg
@@ -0,0 +1,29 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd">
+<svg xmlns="http://www.w3.org/2000/svg" xml:space="preserve" width="210mm" height="297mm" style="shape-rendering:geometricPrecision; text-rendering:geometricPrecision; image-rendering:optimizeQuality; fill-rule:evenodd; clip-rule:evenodd"
+viewBox="0 0 21000 29700"
+ xmlns:xlink="http://www.w3.org/1999/xlink">
+ <defs>
+ <style type="text/css">
+ <![CDATA[
+ .fil0 {fill:#4488AA}
+ ]]>
+ </style>
+ </defs>
+ <g id="Layer_x0020_1">
+ <metadata id="CorelCorpID_0Corel-Layer"/>
+ <g id="_301171840">
+ <g>
+ <path class="fil0" d="M3568 2485l860 6c-572,2690 -58,2438 -2155,2430l1 -416c27,0 77,0 96,0 0,37 0,74 0,99 979,3 748,167 1198,-2119z"/>
+ <polygon class="fil0" points="3613,2279 3696,1855 4553,1855 4470,2279 "/>
+ </g>
+ <path class="fil0" d="M7570 2485l854 6c-183,863 -255,1423 -337,1786l-843 0c54,-295 149,-818 326,-1792z"/>
+ <path class="fil0" d="M6325 2488l841 1c-159,868 -258,1422 -327,1788l-840 0c54,-295 150,-815 326,-1789z"/>
+ <polygon class="fil0" points="7609,2280 7691,1855 8548,1855 8465,2280 "/>
+ <path class="fil0" d="M4549 3945l268 -1463 846 0c-80,420 -160,770 -216,1187 -10,78 -75,289 59,292 115,3 343,1 407,0 130,-2 154,-67 176,-177 19,174 54,174 -15,287 -47,76 -115,206 -260,205 -368,-1 -619,-15 -990,2 -177,8 -307,-152 -274,-334z"/>
+ <path class="fil0" d="M11079 1838l854 6c-183,863 -354,2067 -436,2430l-843 0c54,-295 248,-1462 425,-2436z"/>
+ <polygon class="fil0" points="11705,3079 12503,2462 13250,2462 13250,2557 13078,2557 12628,2956 13139,4183 13224,4185 13224,4280 12177,4280 11724,3197 11606,3199 "/>
+ <path class="fil0" d="M9171 2487l1488 -17 9 420 -102 0 0 -99c-283,0 -656,-10 -867,0 -67,-2 -125,3 -145,92 -58,251 -142,748 -160,962 -6,65 41,109 106,109l917 8 23 -111 95 -1 -81 427c-505,-1 -1010,-1 -1507,-6 -261,6 -435,-152 -400,-349 73,-413 139,-717 194,-1056 32,-196 203,-378 431,-380z"/>
+ </g>
+ </g>
+</svg>
diff --git a/Juick/Classes/ScrollViewerMonitor.cs b/Juick/Classes/ScrollViewerMonitor.cs
index 6a65773..a985360 100644
--- a/Juick/Classes/ScrollViewerMonitor.cs
+++ b/Juick/Classes/ScrollViewerMonitor.cs
@@ -37,7 +37,7 @@ namespace Juick.Classes
{
var element = (FrameworkElement)sender;
element.Loaded -= element_Loaded;
- var scrollViewer = FindChildOfType<ScrollViewer>(element);
+ var scrollViewer = (ScrollViewer)element.Parent;
if (scrollViewer == null)
{
throw new InvalidOperationException("ScrollViewer not found.");
@@ -59,28 +59,5 @@ namespace Juick.Classes
var binding = new Binding("VerticalOffset") { Source = scrollViewer };
listener.Attach(scrollViewer, binding);
}
-
- static T FindChildOfType<T>(DependencyObject root)
- where T : class
- {
- var queue = new Queue<DependencyObject>();
- queue.Enqueue(root);
-
- while (queue.Count > 0)
- {
- var current = queue.Dequeue();
- for (int i = VisualTreeHelper.GetChildrenCount(current) - 1; 0 <= i; i--)
- {
- var child = VisualTreeHelper.GetChild(current, i);
- var typedChild = child as T;
- if (typedChild != null)
- {
- return typedChild;
- }
- queue.Enqueue(child);
- }
- }
- return null;
- }
}
}
diff --git a/Juick/Juick.csproj b/Juick/Juick.csproj
index ec24b06..7bd452a 100644
--- a/Juick/Juick.csproj
+++ b/Juick/Juick.csproj
@@ -125,7 +125,9 @@
<ItemGroup>
<None Include="packages.config" />
<None Include="Properties\AppManifest.xml" />
- <None Include="Properties\WMAppManifest.xml" />
+ <None Include="Properties\WMAppManifest.xml">
+ <SubType>Designer</SubType>
+ </None>
</ItemGroup>
<ItemGroup>
<Content Include="ApplicationIcon.png">
diff --git a/Juick/LoginView.xaml b/Juick/LoginView.xaml
index db5e193..ad1d70c 100644
--- a/Juick/LoginView.xaml
+++ b/Juick/LoginView.xaml
@@ -22,14 +22,14 @@
<!--TitlePanel contains the name of the application and page title-->
<StackPanel x:Name="TitlePanel" Grid.Row="0" Margin="12,17,0,28">
- <TextBlock x:Name="ApplicationTitle" Text="JUICK" Style="{StaticResource PhoneTextNormalStyle}"/>
+ <TextBlock x:Name="ApplicationTitle" Text="juick" Style="{StaticResource PhoneTextNormalStyle}"/>
<TextBlock x:Name="PageTitle" Text="signup" Margin="9,-7,0,0" Style="{StaticResource PhoneTextTitle1Style}"/>
</StackPanel>
<!--ContentPanel - place additional content here-->
<Grid x:Name="ContentPanel" Grid.Row="1" Margin="12,0,12,0">
<TextBlock Height="30" HorizontalAlignment="Left" Margin="37,119,0,0" Name="textBlock1" Text="Username" VerticalAlignment="Top" />
- <TextBox Height="72" HorizontalAlignment="Left" Margin="25,155,0,0" Name="textBox1" Text="{Binding Username}" VerticalAlignment="Top" Width="409" />
+ <TextBox Height="72" HorizontalAlignment="Left" Margin="25,155,0,0" Name="textBox1" Text="{Binding UserName}" VerticalAlignment="Top" Width="409" />
<TextBlock Height="30" HorizontalAlignment="Left" Margin="37,246,0,0" Name="textBlock2" Text="Password" VerticalAlignment="Top" />
<Button Content="Sign in" Height="72" HorizontalAlignment="Left" Margin="274,360,0,0" Name="button1" VerticalAlignment="Top" Width="160" Click="button1_Click" />
<PasswordBox Height="72" HorizontalAlignment="Left" Password="{Binding Password}" Margin="25,282,0,0" Name="textBox2" VerticalAlignment="Top" Width="409" />
diff --git a/Juick/MainPage.xaml b/Juick/MainPage.xaml
index a713a39..bffd94f 100644
--- a/Juick/MainPage.xaml
+++ b/Juick/MainPage.xaml
@@ -1,20 +1,20 @@
-<phone:PhoneApplicationPage
+<phone:PhoneApplicationPage
x:Class="Juick.MainPage"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:phone="clr-namespace:Microsoft.Phone.Controls;assembly=Microsoft.Phone"
- xmlns:shell="clr-namespace:Microsoft.Phone.Shell;assembly=Microsoft.Phone"
+ xmlns:phoneshell="clr-namespace:Microsoft.Phone.Shell;assembly=Microsoft.Phone"
xmlns:controls="clr-namespace:Microsoft.Phone.Controls;assembly=Microsoft.Phone.Controls"
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
xmlns:bindings="clr-namespace:Juick.Classes"
- mc:Ignorable="d" d:DesignWidth="480" d:DesignHeight="728"
+ mc:Ignorable="d" d:DesignWidth="480" d:DesignHeight="728"
d:DataContext="{d:DesignData SampleData/MainViewModelSampleData.xaml}"
FontFamily="{StaticResource PhoneFontFamilyNormal}"
FontSize="{StaticResource PhoneFontSizeNormal}"
Foreground="{StaticResource PhoneForegroundBrush}"
SupportedOrientations="PortraitOrLandscape" Orientation="Portrait"
- shell:SystemTray.IsVisible="False">
+ phoneshell:SystemTray.IsVisible="True">
<phone:PhoneApplicationPage.Resources>
<ResourceDictionary>
<bindings:RichTextConverter x:Key="inlineConverter" />
@@ -23,10 +23,18 @@
<!--LayoutRoot is the root grid where all page content is placed-->
<Grid x:Name="LayoutRoot" Background="Transparent">
-
+ <Grid.RowDefinitions>
+ <RowDefinition Height="Auto" />
+ <RowDefinition Height="*" />
+ </Grid.RowDefinitions>
+ <phoneshell:SystemTray.ProgressIndicator>
+ <phoneshell:ProgressIndicator IsIndeterminate="{Binding IsDataLoading}"
+ IsVisible="{Binding IsDataLoading}"
+ Text="Loading..." />
+ </phoneshell:SystemTray.ProgressIndicator>
<!--Panorama control-->
<!--<controls:Panorama Title="Juick20">-->
- <!--<controls:Panorama.TitleTemplate>
+ <!--<controls:Panorama.TitleTemplate>
<DataTemplate>
<Grid Margin="0,80,0,0">
<ContentPresenter>
@@ -35,134 +43,137 @@
</Grid>
</DataTemplate>
</controls:Panorama.TitleTemplate>-->
- <controls:Pivot Title="juick">
+ <controls:Pivot Title="juick" Grid.Row="1">
<!--Use 'Orientation="Horizontal"' to enable a panel that lays out horizontally-->
<!--<controls:PanoramaItem x:Name="MainPanoramaItem" Header="My feed" Margin="0, -40, 0, 0">-->
<controls:PivotItem Header="My feed" Margin="0, -5, 0, 0">
<!--Double line list with image placeholder and text wrapping-->
- <ListBox x:Name="Home"
- Margin="0, 0, -12, 0"
- ItemsSource="{Binding Items}"
- SelectionChanged="ListBoxSelectionChanged"
- bindings:ScrollViewerMonitor.AtEndCommand="{Binding LoadMessagesPageCommand}">
- <ListBox.ItemContainerStyle>
- <Style TargetType="ListBoxItem">
- <Setter Property="HorizontalContentAlignment" Value="Stretch"></Setter>
- </Style>
- </ListBox.ItemContainerStyle>
- <ListBox.ItemTemplate>
- <DataTemplate>
- <Border BorderBrush="{StaticResource PhoneForegroundBrush}" BorderThickness="0 0 0 1">
- <Grid>
- <Grid.ColumnDefinitions>
- <ColumnDefinition Width="Auto" />
- <ColumnDefinition Width="*" />
- </Grid.ColumnDefinitions>
- <Grid.RowDefinitions>
- <RowDefinition Height="Auto" />
- <RowDefinition Height="Auto" />
- <RowDefinition Height="Auto" />
- <RowDefinition Height="Auto" />
- </Grid.RowDefinitions>
- <Image Source="{Binding UserAvatar}" Grid.Row="0" Grid.Column="0" Margin="3" />
- <TextBlock Text="{Binding Username}" Grid.Row="0" Grid.Column="1"
- Margin="5,0,5,5" VerticalAlignment="Top"
- HorizontalAlignment="Left"
- FontFamily="{StaticResource PhoneFontFamilySemiLight}"
- FontSize="{StaticResource PhoneFontSizeLarge}"
- Style="{StaticResource PhoneTextAccentStyle}" />
- <!--Style="{StaticResource PhoneTextNormalStyle}"-->
- <RichTextBox Grid.Row="1" Grid.Column="0" Grid.ColumnSpan="2"
- TextWrapping="Wrap" HorizontalAlignment="Left"
- Foreground="{StaticResource PhoneForegroundBrush}"
- Margin="5,0,5,5" VerticalAlignment="Top"
- IsReadOnly="True">
- <Paragraph bindings:ParagraphBindingBehavior.AssignedInlines="{Binding MessageText, Converter={StaticResource inlineConverter}}" />
- </RichTextBox>
- <Image Source="{Binding Attachment}" Grid.Row="2" Grid.Column="0" Margin="3" Grid.ColumnSpan="2" />
- <TextBlock Text="{Binding Status}" Grid.Row="3" Grid.Column="0" Grid.ColumnSpan="2"
- Foreground="{StaticResource PhoneForegroundBrush}"
- Style="{StaticResource PhoneTextAccentStyle}"
- FontSize="{StaticResource PhoneFontSizeSmall}"
- Margin="5,0,5,5" VerticalAlignment="Top"
- TextWrapping="Wrap" HorizontalAlignment="Left"/>
- </Grid>
- </Border>
- </DataTemplate>
- </ListBox.ItemTemplate>
- </ListBox>
+ <ScrollViewer>
+ <ItemsControl x:Name="Home"
+ Margin="0, 0, -12, 0"
+ ItemsSource="{Binding Items}"
+ bindings:ScrollViewerMonitor.AtEndCommand="{Binding LoadMessagesPageCommand}">
+ <ItemsControl.ItemTemplate>
+ <DataTemplate>
+ <HyperlinkButton NavigateUri="{Binding MessageUri}">
+ <HyperlinkButton.Template>
+ <ControlTemplate>
+ <Border BorderBrush="{StaticResource PhoneForegroundBrush}" BorderThickness="0 0 0 1">
+ <Grid>
+ <Grid.ColumnDefinitions>
+ <ColumnDefinition Width="Auto" />
+ <ColumnDefinition Width="*" />
+ </Grid.ColumnDefinitions>
+ <Grid.RowDefinitions>
+ <RowDefinition Height="Auto" />
+ <RowDefinition Height="Auto" />
+ <RowDefinition Height="Auto" />
+ <RowDefinition Height="Auto" />
+ </Grid.RowDefinitions>
+ <Image Source="{Binding UserAvatar}" Grid.Row="0" Grid.Column="0" Margin="3" />
+ <TextBlock Text="{Binding Username}" Grid.Row="0" Grid.Column="1"
+ Margin="5,0,5,5" VerticalAlignment="Top"
+ HorizontalAlignment="Left"
+ FontFamily="{StaticResource PhoneFontFamilySemiLight}"
+ FontSize="{StaticResource PhoneFontSizeLarge}"
+ Style="{StaticResource PhoneTextAccentStyle}" />
+ <!--Style="{StaticResource PhoneTextNormalStyle}"-->
+ <RichTextBox Grid.Row="1" Grid.Column="0" Grid.ColumnSpan="2"
+ TextWrapping="Wrap" HorizontalAlignment="Left"
+ Foreground="{StaticResource PhoneForegroundBrush}"
+ Margin="5,0,5,5" VerticalAlignment="Top"
+ IsReadOnly="True">
+ <Paragraph bindings:ParagraphBindingBehavior.AssignedInlines="{Binding MessageText, Converter={StaticResource inlineConverter}}" />
+ </RichTextBox>
+ <Image Source="{Binding Attachment}" Grid.Row="2" Grid.Column="0" Margin="3" Grid.ColumnSpan="2" />
+ <TextBlock Text="{Binding Status}" Grid.Row="3" Grid.Column="0" Grid.ColumnSpan="2"
+ Foreground="{StaticResource PhoneForegroundBrush}"
+ Style="{StaticResource PhoneTextAccentStyle}"
+ FontSize="{StaticResource PhoneFontSizeSmall}"
+ Margin="5,0,5,5" VerticalAlignment="Top"
+ TextWrapping="Wrap" HorizontalAlignment="Left"/>
+ </Grid>
+ </Border>
+ </ControlTemplate>
+ </HyperlinkButton.Template>
+ </HyperlinkButton>
+ </DataTemplate>
+ </ItemsControl.ItemTemplate>
+ </ItemsControl>
+ </ScrollViewer>
<!--</controls:PanoramaItem>-->
</controls:PivotItem>
-
<!--<controls:PanoramaItem x:Name="LastPanoramaItem" Header="Last" Margin="0, -40, 0, 0">-->
<controls:PivotItem Header="Last" Margin="0, -5, 0, 0">
<!--Double line list with image placeholder and text wrapping-->
- <ListBox x:Name="Last" Margin="0,0,-12,0"
- ItemsSource="{Binding Items}"
- SelectionChanged="LastBoxSelectionChanged"
- bindings:ScrollViewerMonitor.AtEndCommand="{Binding LoadMessagesPageCommand}">
- <ListBox.ItemContainerStyle>
- <Style TargetType="ListBoxItem">
- <Setter Property="HorizontalContentAlignment" Value="Stretch"></Setter>
- </Style>
- </ListBox.ItemContainerStyle>
- <ListBox.ItemTemplate>
- <DataTemplate>
- <Border BorderBrush="{StaticResource PhoneForegroundBrush}" BorderThickness="0 0 0 1">
- <Grid>
- <Grid.ColumnDefinitions>
- <ColumnDefinition Width="Auto" />
- <ColumnDefinition Width="*" />
- </Grid.ColumnDefinitions>
- <Grid.RowDefinitions>
- <RowDefinition Height="Auto" />
- <RowDefinition Height="Auto" />
- <RowDefinition Height="Auto" />
- <RowDefinition Height="Auto" />
- </Grid.RowDefinitions>
- <Image Source="{Binding UserAvatar}" Grid.Row="0" Grid.Column="0" Margin="3" />
- <TextBlock Text="{Binding Username}" Grid.Row="0" Grid.Column="1"
- Margin="5,0,5,5" VerticalAlignment="Top"
- HorizontalAlignment="Left"
- FontFamily="{StaticResource PhoneFontFamilySemiLight}"
- FontSize="{StaticResource PhoneFontSizeLarge}"
- Style="{StaticResource PhoneTextAccentStyle}" />
- <RichTextBox Grid.Row="1" Grid.Column="0" Grid.ColumnSpan="2"
- TextWrapping="Wrap" HorizontalAlignment="Left"
- Foreground="{StaticResource PhoneForegroundBrush}"
- Margin="5,0,5,5" VerticalAlignment="Top"
- IsReadOnly="True">
- <Paragraph bindings:ParagraphBindingBehavior.AssignedInlines="{Binding MessageText, Converter={StaticResource inlineConverter}}" />
- </RichTextBox>
- <Image Source="{Binding Attachment}" Grid.Row="2" Grid.Column="0" Margin="3" Grid.ColumnSpan="2" />
- <TextBlock Text="{Binding Status}" Grid.Row="3" Grid.Column="0" Grid.ColumnSpan="2"
- Foreground="{StaticResource PhoneForegroundBrush}"
- Style="{StaticResource PhoneTextAccentStyle}"
- FontSize="{StaticResource PhoneFontSizeSmall}"
- Margin="5,0,5,5" VerticalAlignment="Top"
- TextWrapping="Wrap" HorizontalAlignment="Left"/>
- </Grid>
- </Border>
- </DataTemplate>
- </ListBox.ItemTemplate>
- </ListBox>
+ <ScrollViewer>
+ <ItemsControl x:Name="Last" Margin="0,0,-12,0"
+ ItemsSource="{Binding Items}"
+ bindings:ScrollViewerMonitor.AtEndCommand="{Binding LoadMessagesPageCommand}">
+ <ItemsControl.ItemTemplate>
+ <DataTemplate>
+ <HyperlinkButton NavigateUri="{Binding MessageUri}">
+ <HyperlinkButton.Template>
+ <ControlTemplate>
+ <Border BorderBrush="{StaticResource PhoneForegroundBrush}" BorderThickness="0 0 0 1">
+ <Grid>
+ <Grid.ColumnDefinitions>
+ <ColumnDefinition Width="Auto" />
+ <ColumnDefinition Width="*" />
+ </Grid.ColumnDefinitions>
+ <Grid.RowDefinitions>
+ <RowDefinition Height="Auto" />
+ <RowDefinition Height="Auto" />
+ <RowDefinition Height="Auto" />
+ <RowDefinition Height="Auto" />
+ </Grid.RowDefinitions>
+ <Image Source="{Binding UserAvatar}" Grid.Row="0" Grid.Column="0" Margin="3" />
+ <TextBlock Text="{Binding Username}" Grid.Row="0" Grid.Column="1"
+ Margin="5,0,5,5" VerticalAlignment="Top"
+ HorizontalAlignment="Left"
+ FontFamily="{StaticResource PhoneFontFamilySemiLight}"
+ FontSize="{StaticResource PhoneFontSizeLarge}"
+ Style="{StaticResource PhoneTextAccentStyle}" />
+ <RichTextBox Grid.Row="1" Grid.Column="0" Grid.ColumnSpan="2"
+ TextWrapping="Wrap" HorizontalAlignment="Left"
+ Foreground="{StaticResource PhoneForegroundBrush}"
+ Margin="5,0,5,5" VerticalAlignment="Top"
+ IsReadOnly="True">
+ <Paragraph bindings:ParagraphBindingBehavior.AssignedInlines="{Binding MessageText, Converter={StaticResource inlineConverter}}" />
+ </RichTextBox>
+ <Image Source="{Binding Attachment}" Grid.Row="2" Grid.Column="0" Margin="3" Grid.ColumnSpan="2" />
+ <TextBlock Text="{Binding Status}" Grid.Row="3" Grid.Column="0" Grid.ColumnSpan="2"
+ Foreground="{StaticResource PhoneForegroundBrush}"
+ Style="{StaticResource PhoneTextAccentStyle}"
+ FontSize="{StaticResource PhoneFontSizeSmall}"
+ Margin="5,0,5,5" VerticalAlignment="Top"
+ TextWrapping="Wrap" HorizontalAlignment="Left"/>
+ </Grid>
+ </Border>
+ </ControlTemplate>
+ </HyperlinkButton.Template>
+ </HyperlinkButton>
+ </DataTemplate>
+ </ItemsControl.ItemTemplate>
+ </ItemsControl>
+ </ScrollViewer>
<!--</controls:PanoramaItem>-->
</controls:PivotItem>
<!--</controls:Panorama>-->
</controls:Pivot>
</Grid>
<phone:PhoneApplicationPage.ApplicationBar>
- <shell:ApplicationBar IsVisible="True" IsMenuEnabled="True">
- <shell:ApplicationBarIconButton IconUri="/Images/appbar.feature.email.rest.png" Text="New post" Click="ApplicationBarIconButtonClick1"/>
- <shell:ApplicationBarIconButton IconUri="/Images/appbar.refresh.rest.png" Text="Refresh" Click="ApplicationBarIconButtonClick" />
+ <phoneshell:ApplicationBar IsVisible="True" IsMenuEnabled="True">
+ <phoneshell:ApplicationBarIconButton IconUri="/Images/appbar.feature.email.rest.png" Text="New post" Click="ApplicationBarIconButtonClick1"/>
+ <phoneshell:ApplicationBarIconButton IconUri="/Images/appbar.refresh.rest.png" Text="Refresh" Click="ApplicationBarIconButtonClick" />
- <shell:ApplicationBar.MenuItems>
- <shell:ApplicationBarMenuItem Text="New message" Click="ApplicationBarIconButtonClick1"/>
- <shell:ApplicationBarMenuItem Text="Refresh" Click="ApplicationBarIconButtonClick"/>
- <shell:ApplicationBarMenuItem Text="Sign out" Click="ApplicationBarMenuItemClick" />
- </shell:ApplicationBar.MenuItems>
- </shell:ApplicationBar>
+ <phoneshell:ApplicationBar.MenuItems>
+ <phoneshell:ApplicationBarMenuItem Text="New message" Click="ApplicationBarIconButtonClick1"/>
+ <phoneshell:ApplicationBarMenuItem Text="Refresh" Click="ApplicationBarIconButtonClick"/>
+ <phoneshell:ApplicationBarMenuItem Text="Sign out" Click="ApplicationBarMenuItemClick" />
+ </phoneshell:ApplicationBar.MenuItems>
+ </phoneshell:ApplicationBar>
</phone:PhoneApplicationPage.ApplicationBar>
</phone:PhoneApplicationPage> \ No newline at end of file
diff --git a/Juick/MainPage.xaml.cs b/Juick/MainPage.xaml.cs
index eba1635..d6b0b08 100644
--- a/Juick/MainPage.xaml.cs
+++ b/Juick/MainPage.xaml.cs
@@ -1,20 +1,12 @@
using System;
using System.Collections.Generic;
-using System.Linq;
-using System.Net;
using System.Text;
using System.Windows;
using System.Windows.Controls;
-using System.Windows.Documents;
-using System.Windows.Input;
-using System.Windows.Media;
-using System.Windows.Media.Animation;
-using System.Windows.Shapes;
-using Juick.Classes;
+using System.Windows.Data;
using Microsoft.Phone.Controls;
using Microsoft.Phone.Notification;
-using Microsoft.Xna.Framework.Media;
-using System.Windows.Media.Imaging;
+using Microsoft.Phone.Shell;
namespace Juick
{
@@ -30,7 +22,7 @@ namespace Juick
//string channelName = "JuickChannel"; // unused variable
InitializeComponent();
-
+
/* // Try to find the push channel.
pushChannel = HttpNotificationChannel.Find(channelName);
@@ -71,6 +63,29 @@ namespace Juick
// Set the data context of the listbox control to the sample data
Home.DataContext = App.MyFeedView;
Last.DataContext = App.LastView;
+ Loaded += (o, args) =>
+ {
+ var progressIndicator = SystemTray.ProgressIndicator;
+
+ if (progressIndicator != null)
+ {
+ return;
+ }
+
+ progressIndicator = new ProgressIndicator();
+
+ SystemTray.SetProgressIndicator(this, progressIndicator);
+
+ Binding binding = new Binding("IsDataLoading") { Source = Home.DataContext };
+
+ BindingOperations.SetBinding(
+ progressIndicator, ProgressIndicator.IsVisibleProperty, binding);
+
+ binding = new Binding("IsDataLoading") { Source = Home.DataContext };
+
+ BindingOperations.SetBinding(
+ progressIndicator, ProgressIndicator.IsIndeterminateProperty, binding);
+ };
}
protected override void OnNavigatedTo(System.Windows.Navigation.NavigationEventArgs e)
@@ -144,32 +159,6 @@ namespace Juick
);
}
- private void ListBoxSelectionChanged(object sender, SelectionChangedEventArgs e)
- {
- // If selected index is -1 (no selection) do nothing
- if (((ListBox)sender).SelectedIndex == -1)
- return;
-
- // Navigate to the new page
- NavigationService.Navigate(new Uri("/ThreadView.xaml?mid=" + App.MyFeedView.Items[((ListBox)sender).SelectedIndex].MID, UriKind.Relative));
-
- // Reset selected index to -1 (no selection)
- ((ListBox)sender).SelectedIndex = -1;
- }
-
- private void LastBoxSelectionChanged(object sender, SelectionChangedEventArgs e)
- {
- // If selected index is -1 (no selection) do nothing
- if (((ListBox)sender).SelectedIndex == -1)
- return;
-
- // Navigate to the new page
- NavigationService.Navigate(new Uri(string.Format("/ThreadView.xaml?mid={0}", App.LastView.Items[((ListBox)sender).SelectedIndex].MID), UriKind.Relative));
-
- // Reset selected index to -1 (no selection)
- ((ListBox)sender).SelectedIndex = -1;
- }
-
private void ApplicationBarIconButtonClick(object sender, EventArgs e)
{
App.MyFeedView.Items.Clear();
diff --git a/Juick/Properties/AssemblyInfo.cs b/Juick/Properties/AssemblyInfo.cs
index d3496e2..9a52d9e 100644
--- a/Juick/Properties/AssemblyInfo.cs
+++ b/Juick/Properties/AssemblyInfo.cs
@@ -32,6 +32,6 @@ using System.Resources;
//
// You can specify all the values or you can default the Revision and Build Numbers
// by using the '*' as shown below:
-[assembly: AssemblyVersion("1.0.0.0")]
-[assembly: AssemblyFileVersion("1.0.0.0")]
+[assembly: AssemblyVersion("1.0.9.9")]
+[assembly: AssemblyFileVersion("1.0.9.9")]
[assembly: NeutralResourcesLanguageAttribute("en-US")]
diff --git a/Juick/SplashScreenImage.jpg b/Juick/SplashScreenImage.jpg
index 353b192..5feee2e 100644
--- a/Juick/SplashScreenImage.jpg
+++ b/Juick/SplashScreenImage.jpg
Binary files differ
diff --git a/Juick/SubmissionInfo/ApplicationTile.png b/Juick/SubmissionInfo/ApplicationTile.png
deleted file mode 100644
index 68b5849..0000000
--- a/Juick/SubmissionInfo/ApplicationTile.png
+++ /dev/null
Binary files differ
diff --git a/Juick/SubmissionInfo/ApplicationTileMarket.png b/Juick/SubmissionInfo/ApplicationTileMarket.png
index 8493707..d402061 100644
--- a/Juick/SubmissionInfo/ApplicationTileMarket.png
+++ b/Juick/SubmissionInfo/ApplicationTileMarket.png
Binary files differ
diff --git a/Juick/SubmissionInfo/ApplicationTileSmall.png b/Juick/SubmissionInfo/ApplicationTileSmall.png
deleted file mode 100644
index f48658b..0000000
--- a/Juick/SubmissionInfo/ApplicationTileSmall.png
+++ /dev/null
Binary files differ
diff --git a/Juick/SubmissionInfo/Settings.xml b/Juick/SubmissionInfo/Settings.xml
index 1f6c8f2..d425313 100644
--- a/Juick/SubmissionInfo/Settings.xml
+++ b/Juick/SubmissionInfo/Settings.xml
@@ -1,6 +1,4 @@
<MarketplaceDetails>
- <SmallAppTile>ApplicationTileSmall.png</SmallAppTile>
- <LargeAppTile>ApplicationTile.png</LargeAppTile>
<PCAppTile>ApplicationTileMarket.png</PCAppTile>
<ScreenShots>scr1.png;scr2.png;scr3.png;;;;;;</ScreenShots>
</MarketplaceDetails> \ No newline at end of file
diff --git a/Juick/ThreadView.xaml.cs b/Juick/ThreadView.xaml.cs
index 958efe2..d17f8f5 100644
--- a/Juick/ThreadView.xaml.cs
+++ b/Juick/ThreadView.xaml.cs
@@ -21,6 +21,8 @@ namespace Juick
// When page is navigated to set data context to selected item in list
protected override void OnNavigatedTo(NavigationEventArgs e)
{
+ if (Model.Items.Count > 0)
+ return;
string _mid = "";
if (NavigationContext.QueryString.TryGetValue("mid", out _mid))
{
diff --git a/Juick/ViewModels/MessageViewModel.cs b/Juick/ViewModels/MessageViewModel.cs
index e120c5d..460df38 100644
--- a/Juick/ViewModels/MessageViewModel.cs
+++ b/Juick/ViewModels/MessageViewModel.cs
@@ -17,6 +17,7 @@ namespace Juick.ViewModels
public MessageViewModel(Message message)
{
MID = message.Mid;
+ MessageUri = string.Format("/ThreadView.xaml?mid={0}", MID);
RID = message.Rid;
Username = message.User.UName;
MessageText = HttpUtility.HtmlDecode(message.Body);
@@ -138,6 +139,8 @@ namespace Juick.ViewModels
}
private string _status;
+
+
/// <summary>
/// Sample _viewModelBase property; this property is used in the view to display its value using a Binding.
/// </summary>
@@ -158,6 +161,18 @@ namespace Juick.ViewModels
}
}
+ private string _messageUri;
+
+ public string MessageUri
+ {
+ get { return _messageUri; }
+ set
+ {
+ _messageUri = value;
+ NotifyPropertyChanged("MessageUri");
+ }
+ }
+
public event PropertyChangedEventHandler PropertyChanged;
public void NotifyPropertyChanged(String propertyName)