From 419d2caeb291a3285fde4672bad3de23fca47ef5 Mon Sep 17 00:00:00 2001 From: Jarod42 Date: Mon, 26 Aug 2024 08:56:03 +0200 Subject: [PATCH] Apply Guichan's changes from e3b13a3923cbe3e46c231b4f2817d2f0cabb58f9 (Aug 4th 2008) http://code.google.com/p/guichan/issues/detail?id=48 --- TODO | 2 +- src/graphics.cpp | 3 +++ 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/TODO b/TODO index 866272f..edc9631 100644 --- a/TODO +++ b/TODO @@ -1,4 +1,4 @@ -* Continue rebasing from e3b13a3923cbe3e46c231b4f2817d2f0cabb58f9 +* Continue rebasing from 40b4a526479f407546bb3a9d33eabc8ff75a40d3 * Add a focus listener interface. * Make focus apply synchronously. * Graphics and input objects for DirectX. diff --git a/src/graphics.cpp b/src/graphics.cpp index 8061b51..86f259f 100644 --- a/src/graphics.cpp +++ b/src/graphics.cpp @@ -74,6 +74,9 @@ namespace gcn bool Graphics::pushClipArea(Rectangle area) { + // Ignore area with a negative width or height + if (area.width < 0 || area.height < 0) + return false; if (mClipStack.empty()) { ClipRectangle carea;