mirror of
https://github.com/ClemensFischer/XAML-Map-Control.git
synced 2025-12-06 07:12:04 +01:00
Fixed using Path = System.IO.Path
This commit is contained in:
parent
2bf9b81fac
commit
02e138eb7c
|
|
@ -7,7 +7,6 @@ global using Avalonia.Animation;
|
||||||
global using Avalonia.Animation.Easings;
|
global using Avalonia.Animation.Easings;
|
||||||
global using Avalonia.Controls;
|
global using Avalonia.Controls;
|
||||||
global using Avalonia.Controls.Documents;
|
global using Avalonia.Controls.Documents;
|
||||||
global using Avalonia.Controls.Shapes;
|
|
||||||
global using Avalonia.Data;
|
global using Avalonia.Data;
|
||||||
global using Avalonia.Input;
|
global using Avalonia.Input;
|
||||||
global using Avalonia.Interactivity;
|
global using Avalonia.Interactivity;
|
||||||
|
|
|
||||||
|
|
@ -2,6 +2,7 @@
|
||||||
// Copyright © 2024 Clemens Fischer
|
// Copyright © 2024 Clemens Fischer
|
||||||
// Licensed under the Microsoft Public License (Ms-PL)
|
// Licensed under the Microsoft Public License (Ms-PL)
|
||||||
|
|
||||||
|
using Avalonia.Controls.Shapes;
|
||||||
using System.Collections.Generic;
|
using System.Collections.Generic;
|
||||||
using System.Globalization;
|
using System.Globalization;
|
||||||
using System.Linq;
|
using System.Linq;
|
||||||
|
|
|
||||||
|
|
@ -2,6 +2,8 @@
|
||||||
// Copyright © 2024 Clemens Fischer
|
// Copyright © 2024 Clemens Fischer
|
||||||
// Licensed under the Microsoft Public License (Ms-PL)
|
// Licensed under the Microsoft Public License (Ms-PL)
|
||||||
|
|
||||||
|
using Avalonia.Controls.Shapes;
|
||||||
|
|
||||||
namespace MapControl
|
namespace MapControl
|
||||||
{
|
{
|
||||||
public partial class MapPath : Shape
|
public partial class MapPath : Shape
|
||||||
|
|
|
||||||
|
|
@ -5,7 +5,6 @@
|
||||||
using System;
|
using System;
|
||||||
using System.Globalization;
|
using System.Globalization;
|
||||||
using System.IO;
|
using System.IO;
|
||||||
using Path = System.IO.Path;
|
|
||||||
using System.Linq;
|
using System.Linq;
|
||||||
using System.Threading.Tasks;
|
using System.Threading.Tasks;
|
||||||
#if WPF
|
#if WPF
|
||||||
|
|
|
||||||
|
|
@ -7,7 +7,6 @@ using System.Collections.Generic;
|
||||||
using System.Diagnostics;
|
using System.Diagnostics;
|
||||||
using System.Globalization;
|
using System.Globalization;
|
||||||
using System.IO;
|
using System.IO;
|
||||||
using Path = System.IO.Path;
|
|
||||||
using System.IO.Compression;
|
using System.IO.Compression;
|
||||||
using System.Linq;
|
using System.Linq;
|
||||||
using System.Threading.Tasks;
|
using System.Threading.Tasks;
|
||||||
|
|
|
||||||
|
|
@ -12,7 +12,6 @@ using System.Linq;
|
||||||
using System.Text;
|
using System.Text;
|
||||||
using System.Threading;
|
using System.Threading;
|
||||||
using System.Threading.Tasks;
|
using System.Threading.Tasks;
|
||||||
using Path = System.IO.Path;
|
|
||||||
|
|
||||||
namespace MapControl.Caching
|
namespace MapControl.Caching
|
||||||
{
|
{
|
||||||
|
|
|
||||||
|
|
@ -6,8 +6,8 @@ using System;
|
||||||
using System.Collections.Generic;
|
using System.Collections.Generic;
|
||||||
using System.Collections.Specialized;
|
using System.Collections.Specialized;
|
||||||
using System.Diagnostics;
|
using System.Diagnostics;
|
||||||
|
using System.IO;
|
||||||
using System.Linq;
|
using System.Linq;
|
||||||
using Path = System.IO.Path;
|
|
||||||
#if WPF
|
#if WPF
|
||||||
using System.Windows;
|
using System.Windows;
|
||||||
#elif UWP
|
#elif UWP
|
||||||
|
|
|
||||||
|
|
@ -24,6 +24,8 @@ using Microsoft.UI.Xaml.Controls;
|
||||||
using Microsoft.UI.Xaml.Data;
|
using Microsoft.UI.Xaml.Data;
|
||||||
using Microsoft.UI.Xaml.Media;
|
using Microsoft.UI.Xaml.Media;
|
||||||
using Microsoft.UI.Xaml.Shapes;
|
using Microsoft.UI.Xaml.Shapes;
|
||||||
|
#elif AVALONIA
|
||||||
|
using Avalonia.Controls.Shapes;
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
namespace MapControl
|
namespace MapControl
|
||||||
|
|
|
||||||
|
|
@ -9,6 +9,7 @@ using System;
|
||||||
using System.Collections.Concurrent;
|
using System.Collections.Concurrent;
|
||||||
using System.Collections.Generic;
|
using System.Collections.Generic;
|
||||||
using System.Diagnostics;
|
using System.Diagnostics;
|
||||||
|
using System.IO;
|
||||||
using System.Linq;
|
using System.Linq;
|
||||||
using System.Threading.Tasks;
|
using System.Threading.Tasks;
|
||||||
|
|
||||||
|
|
@ -48,7 +49,7 @@ namespace MapControl
|
||||||
/// Default folder path where a persistent cache implementation may save data, i.e. "C:\ProgramData\MapControl\TileCache".
|
/// Default folder path where a persistent cache implementation may save data, i.e. "C:\ProgramData\MapControl\TileCache".
|
||||||
/// </summary>
|
/// </summary>
|
||||||
public static string DefaultCacheFolder =>
|
public static string DefaultCacheFolder =>
|
||||||
System.IO.Path.Combine(Environment.GetFolderPath(Environment.SpecialFolder.CommonApplicationData), "MapControl", "TileCache");
|
Path.Combine(Environment.GetFolderPath(Environment.SpecialFolder.CommonApplicationData), "MapControl", "TileCache");
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// An IDistributedCache implementation used to cache tile images.
|
/// An IDistributedCache implementation used to cache tile images.
|
||||||
|
|
@ -152,7 +153,7 @@ namespace MapControl
|
||||||
|
|
||||||
private static async Task LoadCachedTileAsync(Tile tile, Uri uri, string cacheName)
|
private static async Task LoadCachedTileAsync(Tile tile, Uri uri, string cacheName)
|
||||||
{
|
{
|
||||||
var extension = System.IO.Path.GetExtension(uri.LocalPath);
|
var extension = Path.GetExtension(uri.LocalPath);
|
||||||
|
|
||||||
if (string.IsNullOrEmpty(extension) || extension.Equals(".jpeg", StringComparison.OrdinalIgnoreCase))
|
if (string.IsNullOrEmpty(extension) || extension.Equals(".jpeg", StringComparison.OrdinalIgnoreCase))
|
||||||
{
|
{
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue