Skip to content

Commit

Permalink
Merge r235108 - Unreviewed, rolling out r234979.
Browse files Browse the repository at this point in the history
https://bugs.webkit.org/show_bug.cgi?id=188780

broke ubuntu LTS build (Requested by philn on #webkit).

Reverted changeset:

"[GTK] Never return an uninitialized ImageGStreamer object."
https://bugs.webkit.org/show_bug.cgi?id=188305
https://trac.webkit.org/changeset/234979
  • Loading branch information
webkit-commit-queue authored and carlosgcampos committed Aug 24, 2018
1 parent cb4065f commit 0ceb206
Show file tree
Hide file tree
Showing 3 changed files with 20 additions and 10 deletions.
13 changes: 13 additions & 0 deletions Source/WebCore/ChangeLog
@@ -1,3 +1,16 @@
2018-08-21 Commit Queue <commit-queue@webkit.org>

Unreviewed, rolling out r234979.
https://bugs.webkit.org/show_bug.cgi?id=188780

broke ubuntu LTS build (Requested by philn on #webkit).

Reverted changeset:

"[GTK] Never return an uninitialized ImageGStreamer object."
https://bugs.webkit.org/show_bug.cgi?id=188305
https://trac.webkit.org/changeset/234979

2018-08-20 Devin Rousso <drousso@apple.com>

Web Inspector: allow breakpoints to be set for specific event listeners
Expand Down
14 changes: 5 additions & 9 deletions Source/WebCore/platform/graphics/gstreamer/ImageGStreamer.h
Expand Up @@ -38,28 +38,24 @@ class IntSize;

class ImageGStreamer : public RefCounted<ImageGStreamer> {
public:
static RefPtr<ImageGStreamer> createImage(GstSample* sample)
static Ref<ImageGStreamer> createImage(GstSample* sample)
{
auto image = adoptRef(*new ImageGStreamer(sample));
if (!image->m_image)
return nullptr;

return image;
return adoptRef(*new ImageGStreamer(sample));
}
~ImageGStreamer();

BitmapImage& image()
BitmapImage* image()
{
ASSERT(m_image);
return *m_image.get();
return m_image.get();
}

void setCropRect(FloatRect rect) { m_cropRect = rect; }
FloatRect rect()
{
ASSERT(m_image);
if (!m_cropRect.isEmpty())
return FloatRect(m_cropRect);
ASSERT(m_image);
return FloatRect(0, 0, m_image->size().width(), m_image->size().height());
}

Expand Down
Expand Up @@ -966,7 +966,8 @@ void MediaPlayerPrivateGStreamerBase::paint(GraphicsContext& context, const Floa
if (!gstImage)
return;

context.drawImage(gstImage->image(), rect, gstImage->rect(), paintingOptions);
if (Image* image = reinterpret_cast<Image*>(gstImage->image()))
context.drawImage(*image, rect, gstImage->rect(), paintingOptions);
}

#if USE(GSTREAMER_GL)
Expand Down

0 comments on commit 0ceb206

Please sign in to comment.