From bca95adc0e4e8dfbecd6a7837e40b43c9464c27d Mon Sep 17 00:00:00 2001 From: Jonas Kulla Date: Fri, 5 Sep 2014 22:54:57 +0200 Subject: [PATCH] MRI: WindowVX dummy contents object is always created The check was against rgssVer >= 2, but since that's always true if WindowVX is used, it was pointless. --- binding-mri/windowvx-binding.cpp | 11 ++++------- 1 file changed, 4 insertions(+), 7 deletions(-) diff --git a/binding-mri/windowvx-binding.cpp b/binding-mri/windowvx-binding.cpp index 21cc7c3..50ee979 100644 --- a/binding-mri/windowvx-binding.cpp +++ b/binding-mri/windowvx-binding.cpp @@ -56,13 +56,10 @@ RB_METHOD(windowVXInitialize) wrapProperty(self, w->getTone(), "tone", ToneType); wrapProperty(self, w->getCursorRect(), "cursor_rect", RectType); - if (rgssVer >= 2) - { - Bitmap *contents = new Bitmap(1, 1); - VALUE contentsObj = wrapObject(contents, BitmapType); - bitmapInitProps(contents, contentsObj); - rb_iv_set(self, "contents", contentsObj); - } + Bitmap *contents = new Bitmap(1, 1); + VALUE contentsObj = wrapObject(contents, BitmapType); + bitmapInitProps(contents, contentsObj); + rb_iv_set(self, "contents", contentsObj); return self; }