Subversion Repositories Projects

Compare Revisions

Ignore whitespace Rev 2318 → Rev 2319

/MKLiveView/v1.0/Source/GMapCustomMarkers/CustomMarkerCopter.xaml
4,7 → 4,7
x:Class="MKLiveView.GMapCustomMarkers.CustomMarkerCopter"
Height="32.916" Width="112.515" Opacity="10">
<Grid>
<Image Name="icon" Source="copter1.png" HorizontalAlignment="Left" Width="56" Height="36" VerticalAlignment="Top" />
<Image Name="icon" Source="CopterRed.png" HorizontalAlignment="Left" Width="56" Height="36" VerticalAlignment="Top" />
<Label x:Name="lbl" Content="Label" Margin="39,0,0,-0.084" VerticalAlignment="Top" FontSize="10" Height="33" Foreground="White" HorizontalAlignment="Left" Width="73" Padding="0">
<Label.Effect>
<DropShadowEffect Direction="45" ShadowDepth="0.5" BlurRadius="2"/>
/MKLiveView/v1.0/Source/GMapCustomMarkers/CustomMarkerCopter.xaml.cs
18,7 → 18,7
GMapMarker Marker;
MainWindow MainWindow;
 
public CustomMarkerCopter(MainWindow window, GMapMarker marker, string title)
public CustomMarkerCopter(MainWindow window, GMapMarker marker, string title, string sColor)
{
this.InitializeComponent();
 
80,7 → 80,31
{
lbl.Content = s;
}
public void setColor(string sColor)
{
switch (sColor)
{
case "red":
icon.Source = new System.Windows.Media.Imaging.BitmapImage(new System.Uri("CopterRed.png", System.UriKind.Relative));
break;
case "green":
icon.Source = new System.Windows.Media.Imaging.BitmapImage(new System.Uri("CopterGreen.png", System.UriKind.Relative));
break;
case "blue":
icon.Source = new System.Windows.Media.Imaging.BitmapImage(new System.Uri("CopterBlue.png", System.UriKind.Relative));
break;
case "yellow":
icon.Source = new System.Windows.Media.Imaging.BitmapImage(new System.Uri("CopterYellow.png", System.UriKind.Relative));
break;
case "pink":
icon.Source = new System.Windows.Media.Imaging.BitmapImage(new System.Uri("CopterPink.png", System.UriKind.Relative));
break;
 
default:
icon.Source = new System.Windows.Media.Imaging.BitmapImage(new System.Uri("CopterRed.png", System.UriKind.Relative));
break;
}
}
void CustomMarkerCopter_SizeChanged(object sender, SizeChangedEventArgs e)
{
// Marker.Offset = new Point(-e.NewSize.Width / 4, -e.NewSize.Height /2);