// Path: app/src/main/java/javax/microedition/lcdui/event/CommandActionEvent.java
// public class CommandActionEvent extends Event
// {
// 	private static ArrayStack<CommandActionEvent> recycled = new ArrayStack();
// 	
// 	private CommandListener listener;
// 	private ItemCommandListener itemlistener;
// 	
// 	private Command command;
// 	private Displayable displayable;
// 	private Item item;
// 	
// 	private CommandActionEvent()
// 	{
// 	}
// 	
// 	public static Event getInstance(CommandListener listener, Command command, Displayable displayable)
// 	{
// 		CommandActionEvent instance = recycled.pop();
// 		
// 		if(instance == null)
// 		{
// 			instance = new CommandActionEvent();
// 		}
// 		
// 		instance.listener = listener;
// 		instance.command = command;
// 		instance.displayable = displayable;
// 		
// 		return instance;
// 	}
// 	
// 	public static Event getInstance(ItemCommandListener itemlistener, Command command, Item item)
// 	{
// 		CommandActionEvent instance = recycled.pop();
// 		
// 		if(instance == null)
// 		{
// 			instance = new CommandActionEvent();
// 		}
// 		
// 		instance.itemlistener = itemlistener;
// 		instance.command = command;
// 		instance.item = item;
// 		
// 		return instance;
// 	}
// 	
// 	public void process()
// 	{
// 		if(listener != null)
// 		{
// 			listener.commandAction(command, displayable);
// 		}
// 		else if(itemlistener != null)
// 		{
// 			itemlistener.commandAction(command, item);
// 		}
// 	}
// 	
// 	public void recycle()
// 	{
// 		listener = null;
// 		itemlistener = null;
// 		
// 		command = null;
// 		displayable = null;
// 		item = null;
// 		
// 		recycled.push(this);
// 	}
// 	
// 	public void enterQueue()
// 	{
// 	}
// 	
// 	public void leaveQueue()
// 	{
// 	}
// 	
// 	public boolean placeableAfter(Event event)
// 	{
// 		return true;
// 	}
// 	
// //	public String toString()
// //	{
// //		if(listener != null)
// //		{
// //			return "сommandAction(" + command + ", " + displayable + ")";
// //		}
// //		else if(itemlistener != null)
// //		{
// //			return "сommandAction(" + command + ", " + item + ")";
// //		}
// //		else
// //		{
// //			return "сommandAction(" + command + ")";
// //		}
// //	}
// }
// 
// Path: app/src/main/java/javax/microedition/lcdui/event/SimpleEvent.java
// public abstract class SimpleEvent extends Event
// {
// 	public void recycle()
// 	{
// 	}
// 	
// 	public void enterQueue()
// 	{
// 	}
// 	
// 	public void leaveQueue()
// 	{
// 	}
// 
// 	public boolean placeableAfter(Event event)
// 	{
// 		return true;
// 	}
// }


import android.view.View;
import android.view.ViewGroup.LayoutParams;
import android.widget.LinearLayout;
import android.widget.TextView;
import java.util.ArrayList;
import javax.microedition.lcdui.event.CommandActionEvent;
import javax.microedition.lcdui.event.SimpleEvent;
import android.content.Context;
import android.graphics.Paint;
import android.graphics.drawable.Drawable;
import android.graphics.drawable.ShapeDrawable;
import android.graphics.drawable.shapes.RoundRectShape;
import android.util.TypedValue;
import android.view.ContextMenu;
import android.view.Menu;
import android.view.MenuItem;

	public static final int LAYOUT_TOP = 16;
	public static final int LAYOUT_BOTTOM = 32;
	public static final int LAYOUT_VCENTER = 48;
	public static final int LAYOUT_NEWLINE_BEFORE = 256;
	public static final int LAYOUT_NEWLINE_AFTER = 512;
	public static final int LAYOUT_SHRINK = 1024;
	public static final int LAYOUT_EXPAND = 2048;
	public static final int LAYOUT_VSHRINK = 4096;
	public static final int LAYOUT_VEXPAND = 8192;
	public static final int LAYOUT_2 = 16384;
	
	private static final float BORDER_PADDING = 7;
	private static final float BORDER_RADIUS = 4;
	
	private static final int LABEL_NO_ACTION = 0;
	private static final int LABEL_SHOW = 1;
	private static final int LABEL_HIDE = 2;
	
	private LinearLayout layout;
	private View contentview;
	
	private String label;
	private TextView labelview;
	private int labelmode;
	
	private Form owner;
	
	private ArrayList<Command> commands = new ArrayList();
	private ItemCommandListener listener = null;
	

// Path: app/src/main/java/javax/microedition/lcdui/event/CommandActionEvent.java
// public class CommandActionEvent extends Event
// {
// 	private static ArrayStack<CommandActionEvent> recycled = new ArrayStack();
// 	
// 	private CommandListener listener;
// 	private ItemCommandListener itemlistener;
// 	
// 	private Command command;
// 	private Displayable displayable;
// 	private Item item;
// 	
// 	private CommandActionEvent()
// 	{
// 	}
// 	
// 	public static Event getInstance(CommandListener listener, Command command, Displayable displayable)
// 	{
// 		CommandActionEvent instance = recycled.pop();
// 		
// 		if(instance == null)
// 		{
// 			instance = new CommandActionEvent();
// 		}
// 		
// 		instance.listener = listener;
// 		instance.command = command;
// 		instance.displayable = displayable;
// 		
// 		return instance;
// 	}
// 	
// 	public static Event getInstance(ItemCommandListener itemlistener, Command command, Item item)
// 	{
// 		CommandActionEvent instance = recycled.pop();
// 		
// 		if(instance == null)
// 		{
// 			instance = new CommandActionEvent();
// 		}
// 		
// 		instance.itemlistener = itemlistener;
// 		instance.command = command;
// 		instance.item = item;
// 		
// 		return instance;
// 	}
// 	
// 	public void process()
// 	{
// 		if(listener != null)
// 		{
// 			listener.commandAction(command, displayable);
// 		}
// 		else if(itemlistener != null)
// 		{
// 			itemlistener.commandAction(command, item);
// 		}
// 	}
// 	
// 	public void recycle()
// 	{
// 		listener = null;
// 		itemlistener = null;
// 		
// 		command = null;
// 		displayable = null;
// 		item = null;
// 		
// 		recycled.push(this);
// 	}
// 	
// 	public void enterQueue()
// 	{
// 	}
// 	
// 	public void leaveQueue()
// 	{
// 	}
// 	
// 	public boolean placeableAfter(Event event)
// 	{
// 		return true;
// 	}
// 	
// //	public String toString()
// //	{
// //		if(listener != null)
// //		{
// //			return "сommandAction(" + command + ", " + displayable + ")";
// //		}
// //		else if(itemlistener != null)
// //		{
// //			return "сommandAction(" + command + ", " + item + ")";
// //		}
// //		else
// //		{
// //			return "сommandAction(" + command + ")";
// //		}
// //	}
// }
// 
// Path: app/src/main/java/javax/microedition/lcdui/event/SimpleEvent.java
// public abstract class SimpleEvent extends Event
// {
// 	public void recycle()
// 	{
// 	}
// 	
// 	public void enterQueue()
// 	{
// 	}
// 	
// 	public void leaveQueue()
// 	{
// 	}
// 
// 	public boolean placeableAfter(Event event)
// 	{
// 		return true;
// 	}
// }


// Path: app/src/main/java/javax/microedition/lcdui/Item.java
import android.view.View;
import android.view.ViewGroup.LayoutParams;
import android.widget.LinearLayout;
import android.widget.TextView;
import java.util.ArrayList;
import javax.microedition.lcdui.event.CommandActionEvent;
import javax.microedition.lcdui.event.SimpleEvent;
import android.content.Context;
import android.graphics.Paint;
import android.graphics.drawable.Drawable;
import android.graphics.drawable.ShapeDrawable;
import android.graphics.drawable.shapes.RoundRectShape;
import android.util.TypedValue;
import android.view.ContextMenu;
import android.view.Menu;
import android.view.MenuItem;

	public static final int LAYOUT_TOP = 16;
	public static final int LAYOUT_BOTTOM = 32;
	public static final int LAYOUT_VCENTER = 48;
	public static final int LAYOUT_NEWLINE_BEFORE = 256;
	public static final int LAYOUT_NEWLINE_AFTER = 512;
	public static final int LAYOUT_SHRINK = 1024;
	public static final int LAYOUT_EXPAND = 2048;
	public static final int LAYOUT_VSHRINK = 4096;
	public static final int LAYOUT_VEXPAND = 8192;
	public static final int LAYOUT_2 = 16384;
	
	private static final float BORDER_PADDING = 7;
	private static final float BORDER_RADIUS = 4;
	
	private static final int LABEL_NO_ACTION = 0;
	private static final int LABEL_SHOW = 1;
	private static final int LABEL_HIDE = 2;
	
	private LinearLayout layout;
	private View contentview;
	
	private String label;
	private TextView labelview;
	private int labelmode;
	
	private Form owner;
	
	private ArrayList<Command> commands = new ArrayList();
	private ItemCommandListener listener = null;
	

	private SimpleEvent msgSetContextMenuListener = new SimpleEvent()
