Commit 5c66bbbf authored by Rafaël Carré's avatar Rafaël Carré

qt4: Don't update art when it hasn't changed

This gives a use to the otherwise useless artUrl variable
This prevents qt4 interface from consuming 100% of CPU when art image
has to be scaled from a big source picture
parent 434e1e05
...@@ -614,8 +614,13 @@ void InputManager::UpdateArt() ...@@ -614,8 +614,13 @@ void InputManager::UpdateArt()
url = url.replace( "attachment://", "" ); url = url.replace( "attachment://", "" );
} }
/* the art hasn't changed, no need to update */
if(artUrl == url)
return;
/* Update Art meta */ /* Update Art meta */
emit artChanged( url ); artUrl = url;
emit artChanged( artUrl );
} }
inline void InputManager::UpdateStats() inline void InputManager::UpdateStats()
......
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