[KPhotoAlbum] can not deal with images not on disk

Sujee Maniyam kimdaba at sujee.net
Sun Jul 1 00:25:32 BST 2007


I see.  I am also thinking, if somebody works with partial image 
collections, they wouldn't normally delete images that are not on disk. 
  I'd like to hear others' thought on this as well.  I don't want to 
keep blocking images that are not on disk.

One suggestion I do have is, to leave the 'delete images from disk' 
check box *UNCHECKED* by default.  So even if somebody accidentaly 
deletes images, can go back to index.xml and 'unblock' them.

In the mean time, I have made the following change that works for me.

MsinWindow/DeleteDiallog.cpp : around line 75

if ( _delete_file->isChecked() )
	{
//             if ( DB::ImageInfo::imageOnDisk(*it) && QFile( *it 
).exists() && QFile( *it ).remove() ) {
//                 listToDelete.append( *it );
//                 Utilities::removeThumbNail( *it );
//             } else {
//                 listCouldNotDelete.append( *it );
//             }

		if ( DB::ImageInfo::imageOnDisk(*it) && QFile( *it ).exists())
		{
			QFile( *it ).remove();
  			Utilities::removeThumbNail( *it );
		}
		listToDelete.append( *it );
	}

regards
/sujee

Jan Kundrát wrote:
> Sujee Maniyam wrote:
>> When I select 'delete from disk as well' for 'images not on disk', I get 
>> the error msg (can't delete files) and nothing happens.  I can still 
>> block these images from my database.  But I don't want to do that, as it 
>> bloats the database.  I just want the entry completely gone from the 
>> database.
> 
> I see your point, but note that some people use KPA with storage that
> might go partially offline (external disk, network mount,...). If we
> allow deleting files in such a case, it might be confusing as images
> might suddenly appear again upon remount...
> 
> Suggestions are welcome.
> 
> Cheers,
> -jkt
> 



More information about the Kphotoalbum mailing list