package mezz.jei.gui;

import mezz.jei.api.gui.IDrawable;
import net.minecraft.client.Minecraft;
import net.minecraft.client.gui.Gui;
import net.minecraft.util.ResourceLocation;

import javax.annotation.Nonnull;

public class DrawableResource extends Gui implements IDrawable {

	@Nonnull
	private final ResourceLocation resourceLocation;
	private final int u;
	private final int v;
	private final int width;
	private final int height;

	public DrawableResource(@Nonnull ResourceLocation resourceLocation, int u, int v, int width, int height) {
		this.resourceLocation = resourceLocation;

		this.u = u;
		this.v = v;
		this.width = width;
		this.height = height;
	}

	@Override
	public int getWidth() {
		return width;
	}

	@Override
	public int getHeight() {
		return height;
	}

	public void draw(@Nonnull Minecraft minecraft) {
		minecraft.getTextureManager().bindTexture(resourceLocation);
		this.drawTexturedModalRect(0, 0, u, v, width, height);
	}

}

@@ -16,16 +16,60 @@
 i.gui;%0A%0A
+import cpw.mods.fml.client.config.GuiUtils;%0A
 import m
@@ -95,16 +95,16 @@
 awable;%0A
-
 import n
@@ -138,45 +138,8 @@
 ft;%0A
-import net.minecraft.client.gui.Gui;%0A
 impo
@@ -213,16 +213,16 @@
 nnull;%0A%0A
+
 public c
@@ -247,20 +247,8 @@
 rce 
-extends Gui 
 impl
@@ -885,19 +885,23 @@
 ion);%0A%09%09
-thi
+GuiUtil
 s.drawTe
@@ -941,16 +941,19 @@
 , height
+, 0
 );%0A%09%7D%0A%0A%7D

Use GuiUtils instead of extending Gui