mirror of
https://github.com/farcasclaudiu/myfriendsaround.git
synced 2026-06-29 15:01:45 +03:00
imrpovements
This commit is contained in:
@@ -228,9 +228,15 @@
|
|||||||
<Content Include="icons\anonymousIcon.png">
|
<Content Include="icons\anonymousIcon.png">
|
||||||
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
|
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
|
||||||
</Content>
|
</Content>
|
||||||
|
<Content Include="icons\appbar.add.rest.png">
|
||||||
|
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
|
||||||
|
</Content>
|
||||||
<Content Include="icons\appbar.feature.settings.rest.png">
|
<Content Include="icons\appbar.feature.settings.rest.png">
|
||||||
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
|
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
|
||||||
</Content>
|
</Content>
|
||||||
|
<Content Include="icons\appbar.minus.rest.png">
|
||||||
|
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
|
||||||
|
</Content>
|
||||||
<Content Include="icons\appbar.publish.png">
|
<Content Include="icons\appbar.publish.png">
|
||||||
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
|
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
|
||||||
</Content>
|
</Content>
|
||||||
|
|||||||
@@ -69,6 +69,8 @@ namespace MyFriendsAround.WP7.ViewModel
|
|||||||
CropCancelCommand = new RelayCommand(() => CropCancel());
|
CropCancelCommand = new RelayCommand(() => CropCancel());
|
||||||
MapViewChangedCommand = new RelayCommand<LocationRect>(boundRectangle => MapViewChanged(boundRectangle));
|
MapViewChangedCommand = new RelayCommand<LocationRect>(boundRectangle => MapViewChanged(boundRectangle));
|
||||||
ShowMyLocationCommand = new RelayCommand(() => ShowMyLocation());
|
ShowMyLocationCommand = new RelayCommand(() => ShowMyLocation());
|
||||||
|
MapZoomInCommand = new RelayCommand(() => MapZoomIn());
|
||||||
|
MapZoomOutCommand = new RelayCommand(() => MapZoomOut());
|
||||||
|
|
||||||
if (IsInDesignMode)
|
if (IsInDesignMode)
|
||||||
{
|
{
|
||||||
@@ -89,6 +91,24 @@ namespace MyFriendsAround.WP7.ViewModel
|
|||||||
InitGps();
|
InitGps();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
private void MapZoomOut()
|
||||||
|
{
|
||||||
|
//
|
||||||
|
if(MapZoom<22)
|
||||||
|
{
|
||||||
|
MapZoom++;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
private void MapZoomIn()
|
||||||
|
{
|
||||||
|
//
|
||||||
|
if (MapZoom >2 )
|
||||||
|
{
|
||||||
|
MapZoom--;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
private void InitGps()
|
private void InitGps()
|
||||||
{
|
{
|
||||||
@@ -286,12 +306,12 @@ namespace MyFriendsAround.WP7.ViewModel
|
|||||||
/// The <see cref="MyPicture" /> property's name.
|
/// The <see cref="MyPicture" /> property's name.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
public const string MyPicturePropertyName = "MyPicture";
|
public const string MyPicturePropertyName = "MyPicture";
|
||||||
private BitmapSource _myPicture = new BitmapImage(new Uri("/icons/anonymousIcon.png", UriKind.RelativeOrAbsolute));
|
private ImageSource _myPicture = new BitmapImage(new Uri("/icons/anonymousIcon.png", UriKind.RelativeOrAbsolute));
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Gets the MyPicture property.
|
/// Gets the MyPicture property.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
public BitmapSource MyPicture
|
public ImageSource MyPicture
|
||||||
{
|
{
|
||||||
get
|
get
|
||||||
{
|
{
|
||||||
@@ -586,6 +606,8 @@ namespace MyFriendsAround.WP7.ViewModel
|
|||||||
public ICommand CropSaveCommand { get; set; }
|
public ICommand CropSaveCommand { get; set; }
|
||||||
public ICommand CropCancelCommand { get; set; }
|
public ICommand CropCancelCommand { get; set; }
|
||||||
public ICommand MapViewChangedCommand { get; set; }
|
public ICommand MapViewChangedCommand { get; set; }
|
||||||
|
public ICommand MapZoomInCommand { get; set; }
|
||||||
|
public ICommand MapZoomOutCommand { get; set; }
|
||||||
|
|
||||||
#endregion
|
#endregion
|
||||||
|
|
||||||
|
|||||||
@@ -144,31 +144,41 @@
|
|||||||
|
|
||||||
<Grid HorizontalAlignment="Right"
|
<Grid HorizontalAlignment="Right"
|
||||||
VerticalAlignment="Center"
|
VerticalAlignment="Center"
|
||||||
Width="64"
|
Width="64">
|
||||||
>
|
|
||||||
<Rectangle RadiusX="10"
|
<Rectangle RadiusX="10"
|
||||||
RadiusY="10"
|
RadiusY="10"
|
||||||
Fill="Black"
|
Fill="Black"
|
||||||
Opacity="0.3"
|
Opacity="0.3"
|
||||||
Margin="0,0,-20,0"
|
Margin="0,0,-20,0">
|
||||||
>
|
|
||||||
</Rectangle>
|
</Rectangle>
|
||||||
|
|
||||||
|
|
||||||
<StackPanel HorizontalAlignment="Left" VerticalAlignment="Stretch">
|
<StackPanel HorizontalAlignment="Left"
|
||||||
<Image Source="/icons/appbar.location.png"
|
VerticalAlignment="Stretch">
|
||||||
Margin="0"
|
<Image Source="/icons/appbar.add.rest.png"
|
||||||
Width="64"
|
Margin="0"
|
||||||
Height="64"
|
Width="64"
|
||||||
VerticalAlignment="Top"
|
Height="64"
|
||||||
HorizontalAlignment="Left"
|
VerticalAlignment="Top"
|
||||||
/>
|
HorizontalAlignment="Left">
|
||||||
<Image Source="/icons/appbar.location.png"
|
<i:Interaction.Triggers>
|
||||||
Margin="0"
|
<i:EventTrigger EventName="MouseLeftButtonDown">
|
||||||
Width="64"
|
<cmd:EventToCommand Command="{Binding MapZoomOutCommand}" />
|
||||||
Height="64"
|
</i:EventTrigger>
|
||||||
VerticalAlignment="Bottom"
|
</i:Interaction.Triggers>
|
||||||
HorizontalAlignment="Left" />
|
</Image>
|
||||||
|
<Image Source="/icons/appbar.minus.rest.png"
|
||||||
|
Margin="0"
|
||||||
|
Width="64"
|
||||||
|
Height="64"
|
||||||
|
VerticalAlignment="Bottom"
|
||||||
|
HorizontalAlignment="Left">
|
||||||
|
<i:Interaction.Triggers>
|
||||||
|
<i:EventTrigger EventName="MouseLeftButtonDown">
|
||||||
|
<cmd:EventToCommand Command="{Binding MapZoomInCommand}" />
|
||||||
|
</i:EventTrigger>
|
||||||
|
</i:Interaction.Triggers>
|
||||||
|
</Image>
|
||||||
|
|
||||||
</StackPanel>
|
</StackPanel>
|
||||||
</Grid>
|
</Grid>
|
||||||
@@ -200,8 +210,7 @@
|
|||||||
Opacity="1"
|
Opacity="1"
|
||||||
Source="{Binding MyPicture, Mode=OneWay}"
|
Source="{Binding MyPicture, Mode=OneWay}"
|
||||||
Margin="0"
|
Margin="0"
|
||||||
Stretch="Fill"
|
Stretch="Fill">
|
||||||
>
|
|
||||||
</Image>
|
</Image>
|
||||||
<Border Background="{StaticResource PhoneAccentBrush}"
|
<Border Background="{StaticResource PhoneAccentBrush}"
|
||||||
Width="80"
|
Width="80"
|
||||||
|
|||||||
Binary file not shown.
|
After Width: | Height: | Size: 271 B |
Binary file not shown.
|
After Width: | Height: | Size: 204 B |
Reference in New Issue
Block a user