When update the original image, we can't set it directly as its address has changed,
and _SetPicture() will then delete it behind our back. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@40671 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
parent
433dc78379
commit
8cf55acfff
@ -127,13 +127,15 @@ PictureView::Revert()
|
||||
void
|
||||
PictureView::Update(const entry_ref* ref)
|
||||
{
|
||||
// Don't update when user has changed the picture
|
||||
// Don't update when user has modified the picture
|
||||
if (HasChanged())
|
||||
return;
|
||||
|
||||
BBitmap* bitmap = BTranslationUtils::GetBitmap(ref);
|
||||
_SetPicture(bitmap);
|
||||
|
||||
delete fOriginalPicture;
|
||||
fOriginalPicture = BTranslationUtils::GetBitmap(ref);
|
||||
_SetPicture(fOriginalPicture);
|
||||
fOriginalPicture = fPicture;
|
||||
}
|
||||
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user