Comments (4)
Thanks for reporting this. It looks like a bug.
from mapsui.
Had a look at this. We could make the layer Name a mandatory parameter of the OnDataChangedEventArgs constructor. This solves a lot of problems but a complication is that it is also used in some providers. So, perhaps in those cases the providers should return another type of event args (OnProviderDataChangedEventArgs?) and the layers should create their own OnDataChangedEventArgs when they handle those events.
from mapsui.
The workaround I used is the following :
/// <summary>
/// Map DataChanged event to generate IsBusy ViewModel for showing activity indicator
/// </summary>
/// <param name="sender"></param>
/// <param name="e"></param>
private void Map_DataChanged(object sender, Mapsui.Fetcher.DataChangedEventArgs e)
{
if ((sender != null) && (sender is ILayer) && ((ILayer)sender).Name == "OpenStreetMap")
{
IsBusy = ((ILayer)sender).Busy;
}
}
I'm using the sender ILayer.Name instead of the event args.
I don't know enough Mapsui architecture, but changing DataChangedEventArgs type on context would be a problem at use.
from mapsui.
I fixed this in main by making the layerName constructor argument mandatory for the DataChangeEventArgs and remove use of it in non-layers. These now use an event with minimal data.
#2685
I improved this in develop/4.1 without introducing breaking changes
#2684
from mapsui.
Related Issues (20)
- Shapefiles and mbtiles in .NET MAUI (Android) HOT 3
- Mapsui Maui not working in ios 17.5 HOT 7
- Upgrade 3-> 4 / Help / Question / Viewport HOT 6
- Confusion with WMTS (blank map) #question #helpneeded HOT 5
- MAUI: Double click on map HOT 3
- Memory Leak HOT 10
- [Question/Feature Request] Is there a way to distinguish ViewportChanged events between "manual" and "programmatical" ? HOT 3
- Pinch zoom causes map to pan even with PanLock on HOT 4
- PanLock prevents programmatic moving of the map HOT 2
- WPF: Zoom is laggy after MapControl is re-created HOT 4
- RasterizingLayer performance and display HOT 18
- Let Map be Disposable but not the MapControl
- WPF: Shape layer performance issue HOT 3
- Blazor map control crashes when AOT compiled HOT 8
- System.Text.Json has a vulnerability in version 8.0.3 HOT 3
- Country reappears after it gets back into the viewport HOT 6
- Features are not in the right namespace HOT 2
- Sprite was removed without replacement HOT 1
- How to create Custom calllout
- MapControl from Mapsui.Uno.WinUI doesn't work when targeting windows
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from mapsui.