Handle correctly duplicate thumbnails (see #10225)

First test the ticket against develop, the PR should then be rebased onto dev_4_4 (hard to trigger there)

To test 
* select the folder ```al3d```
* Click import, 2 images should show up in the import queue

Follow 2 thumbnails before and after the fix
![10225_before](https://f.cloud.github.com/assets/1022396/79262/960ffa9e-61a8-11e2-8e5e-b7d7894820d5.png)
![10225_after](https://f.cloud.github.com/assets/1022396/79263/99e1cd78-61a8-11e2-9ac2-968df1e26226.png)