[Digikam-devel] [Bug 248087] Preview not toggling from video mode to image mode

Berthier Lemieux berthier_lemieux at hotmail.com
Mon Aug 16 20:33:19 BST 2010


https://bugs.kde.org/show_bug.cgi?id=248087





--- Comment #2 from Berthier Lemieux <berthier_lemieux hotmail com>  2010-08-16 21:33:18 ---
Hmm. I'm noob here, can't use the tools correctly, apologies.

The patch submitted above address the error I just raised, the problem is that
if  ImagePreviewView::setImageInfo() is called with an imageInfo that is same
as already in use, setImageInfo() did not do anything to change the
albumwidgetstack mode back to image mode.

I copied the code from ImagePreviewView::slotGotImagePreview, which after
reflexion may not be the best thing to do here, at least I should have checked
for isLoaded()... 

BTW, it would seem simpler & better to only emit signalPreviewLoaded(), instead
of the current calls to d->stack:
        d->stack->setPreviewMode(AlbumWidgetStack::PreviewImageMode);
        d->stack->previewLoaded();
        emit signalPreviewLoaded(true);

Is there any special reason why it's like this? 

PPS. In my patch I also propose a small improvement to the mediaplayer logic:
The assignment:
    KUrl url = info.fileUrl();
doesn't return an empty url, when info.isEmpty(). Media player was not stopped
by stop(), but by a request to play("").

-- 
Configure bugmail: https://bugs.kde.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.



More information about the Digikam-devel mailing list