Commit fca70af3 authored by Dennis Nienhüser's avatar Dennis Nienhüser
Browse files

Let the cache handle item removal

When the destructor is called at plugin unload time, the static
QPixmapCache instance can already be deleted, leading to a crash.
parent b30f9b1b
......@@ -53,13 +53,6 @@ NavigationFloatItem::NavigationFloatItem( const MarbleModel *marbleModel )
NavigationFloatItem::~NavigationFloatItem()
{
QPixmapCache::remove( "marble/navigation/navigational_backdrop_top" );
QPixmapCache::remove( "marble/navigation/navigational_backdrop_center" );
QPixmapCache::remove( "marble/navigation/navigational_backdrop_bottom" );
QPixmapCache::remove( "marble/navigation/navigational_currentlocation" );
QPixmapCache::remove( "marble/navigation/navigational_currentlocation_hover" );
QPixmapCache::remove( "marble/navigation/navigational_currentlocation_pressed" );
delete m_navigationWidget;
}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment