Check-in [dda11a1178]

Many hyperlinks are disabled.
Use anonymous login to enable hyperlinks.

Overview
Comment:Some Form base; If a resource was not found in a suite then do a traditional classpath search for it.
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | trunk
Files: files | file ages | folders
SHA1:dda11a1178c67e275fed009709ac943ee087e475
User & Date: stephanie.gawroriski 2019-05-19 17:21:22
Context
2019-05-19
17:46
Implement some of Vector. check-in: 97b18f324f user: stephanie.gawroriski tags: trunk
17:21
Some Form base; If a resource was not found in a suite then do a traditional classpath search for it. check-in: dda11a1178 user: stephanie.gawroriski tags: trunk
14:22
Change names of the demos. check-in: 94f5881fbe user: stephanie.gawroriski tags: trunk
Changes
Hide Diffs Unified Diffs Ignore Whitespace Patch

Changes to changelog.mkd.

50
51
52
53
54
55
56





57
58
59
60
61
62
63
       `java.util.Hashtable` knows when a reorder was performed.
     * Added `java.util.Vector`, it was missing.
     * Added support for ISO-8859-15, this is the newer encoding with the
       Euro symbol.
     * Corrected bug in `__CanSetPrintStream__` where if it were set to itself
       then it could lead to infinite recursion, instead if this kind of
       stream is attempted to be set it will use the target.





     * Implemented `java.io.InputStream`.
     * Implemented `java.util.EventObject`.
     * Implemented `java.util.Hashtable`.
     * Implemented `java.util.LinkedHashMap`.
     * Implemented `java.util.LinkedList`.
     * Made the stack trace printed by `Throwable` much cleaner so that it
       takes up less screen space and is formatted a bit better.







>
>
>
>
>







50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
       `java.util.Hashtable` knows when a reorder was performed.
     * Added `java.util.Vector`, it was missing.
     * Added support for ISO-8859-15, this is the newer encoding with the
       Euro symbol.
     * Corrected bug in `__CanSetPrintStream__` where if it were set to itself
       then it could lead to infinite recursion, instead if this kind of
       stream is attempted to be set it will use the target.
     * If a resource was not found, do a traditional search of the classpath
       for the given resource. This technically is not valid, however some
       games use the wrong class when looking up resources. Note that the
       current suite will always be searched first to maintain the correct
       behavior.
     * Implemented `java.io.InputStream`.
     * Implemented `java.util.EventObject`.
     * Implemented `java.util.Hashtable`.
     * Implemented `java.util.LinkedHashMap`.
     * Implemented `java.util.LinkedList`.
     * Made the stack trace printed by `Throwable` much cleaner so that it
       takes up less screen space and is formatted a bit better.

Changes to runt/apis/cldc-compact/java/lang/Class.java.

9
10
11
12
13
14
15

16
17
18
19
20
21
22
...
222
223
224
225
226
227
228
229












230
231
232
233
234
235
236
// ---------------------------------------------------------------------------

package java.lang;

import cc.squirreljme.runtime.cldc.asm.ObjectAccess;
import cc.squirreljme.runtime.cldc.asm.ResourceAccess;
import cc.squirreljme.runtime.cldc.asm.StaticMethod;

import cc.squirreljme.runtime.cldc.io.ResourceInputStream;
import cc.squirreljme.runtime.cldc.lang.ClassData;
import java.io.InputStream;
import java.lang.ref.Reference;
import java.lang.ref.WeakReference;
import cc.squirreljme.runtime.cldc.lang.ClassFlag;

................................................................................
			
			// Is in default package
			else
				want = __name;
		}
		
		// Open the resource, perhaps
		return ResourceInputStream.open(injar, want);












	}
	
	/**
	 * Returns the class which is the superclass of this class.
	 *
	 * @return The superclass or {@code null} if there is none.
	 * @since 2017/03/29







>







 







|
>
>
>
>
>
>
>
>
>
>
>
>







9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
...
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
// ---------------------------------------------------------------------------

package java.lang;

import cc.squirreljme.runtime.cldc.asm.ObjectAccess;
import cc.squirreljme.runtime.cldc.asm.ResourceAccess;
import cc.squirreljme.runtime.cldc.asm.StaticMethod;
import cc.squirreljme.runtime.cldc.asm.SuiteAccess;
import cc.squirreljme.runtime.cldc.io.ResourceInputStream;
import cc.squirreljme.runtime.cldc.lang.ClassData;
import java.io.InputStream;
import java.lang.ref.Reference;
import java.lang.ref.WeakReference;
import cc.squirreljme.runtime.cldc.lang.ClassFlag;

................................................................................
			
			// Is in default package
			else
				want = __name;
		}
		
		// Open the resource, perhaps
		InputStream rv = ResourceInputStream.open(injar, want);
		if (rv != null)
			return rv;
		
		// Otherwise, do a traditional back to front search for the resource
		// since it might be in another JAR
		String[] classpath = SuiteAccess.currentClassPath();
		for (int i = classpath.length - 1; i >= 0; i--)
			if (null != (rv = ResourceInputStream.open(classpath[i], want)))
				return rv;
		
		// Not found
		return null;
	}
	
	/**
	 * Returns the class which is the superclass of this class.
	 *
	 * @return The superclass or {@code null} if there is none.
	 * @since 2017/03/29

Changes to runt/apis/midp-lcdui/cc/squirreljme/runtime/lcdui/phoneui/DrawingMethod.java.

14
15
16
17
18
19
20

21
22
23
24
25
26
27
..
82
83
84
85
86
87
88
89















90
91
92
93
94
95
96
import javax.microedition.lcdui.Display;
import javax.microedition.lcdui.Displayable;
import javax.microedition.lcdui.FileSelector;
import javax.microedition.lcdui.Font;
import javax.microedition.lcdui.Form;
import javax.microedition.lcdui.Graphics;
import javax.microedition.lcdui.Image;

import javax.microedition.lcdui.List;
import javax.microedition.lcdui.TabbedPane;
import javax.microedition.lcdui.TextBox;

/**
 * This contains various drawing methods which modify how a display is
 * drawn.
................................................................................
		 * {@inheritDoc}
		 * @since 2019/05/18
		 */
		@Override
		public final void paint(Displayable __d, State __s, Graphics __g,
			int __w, int __h)
		{
			__g.drawString("FORM", 0, 0, 0);















		}
	},
	
	/** List. */
	LIST
	{
		/**







>







 







|
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>







14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
..
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
import javax.microedition.lcdui.Display;
import javax.microedition.lcdui.Displayable;
import javax.microedition.lcdui.FileSelector;
import javax.microedition.lcdui.Font;
import javax.microedition.lcdui.Form;
import javax.microedition.lcdui.Graphics;
import javax.microedition.lcdui.Image;
import javax.microedition.lcdui.Item;
import javax.microedition.lcdui.List;
import javax.microedition.lcdui.TabbedPane;
import javax.microedition.lcdui.TextBox;

/**
 * This contains various drawing methods which modify how a display is
 * drawn.
................................................................................
		 * {@inheritDoc}
		 * @since 2019/05/18
		 */
		@Override
		public final void paint(Displayable __d, State __s, Graphics __g,
			int __w, int __h)
		{
			Form form = (Form)__d;
			
			// Number of entries
			int n = form.size();
			
			// Working base coordinates for each item
			int dx = 0,
				dy = 0;
			
			// Draw each entry
			for (int i = 0; i < n; i++)
			{
				// Get item here
				Item item = form.get(i);
				
			}
		}
	},
	
	/** List. */
	LIST
	{
		/**

Changes to runt/apis/midp-lcdui/javax/microedition/lcdui/Form.java.

142
143
144
145
146
147
148








149

150
151

152
153
154
155
156
157
158
...
197
198
199
200
201
202
203






204
205
206

207
208
209
210
	}
	
	public void deleteAll()
	{
		throw new todo.TODO();
	}
	








	public Item get(int __a)

	{
		throw new todo.TODO();

	}
	
	/**
	 * {@inheritDoc}
	 * @since 2017/05/24
	 */
	@Override
................................................................................
	}
	
	public void setLayoutPolicy(FormLayoutPolicy __p)
	{
		throw new todo.TODO();
	}
	






	public int size()
	{
		throw new todo.TODO();

	}
}









>
>
>
>
>
>
>
>
|
>

<
>







 







>
>
>
>
>
>


<
>




142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159

160
161
162
163
164
165
166
167
...
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220

221
222
223
224
225
	}
	
	public void deleteAll()
	{
		throw new todo.TODO();
	}
	
	/**
	 * Returns the given form item.
	 *
	 * @param __i The index to get.
	 * @return The item.
	 * @throws IndexOutOfBoundsException If the index is not within range.
	 * @since 2019/05/19
	 */
	public Item get(int __i)
		throws IndexOutOfBoundsException
	{

		return this._items.get(__i);
	}
	
	/**
	 * {@inheritDoc}
	 * @since 2017/05/24
	 */
	@Override
................................................................................
	}
	
	public void setLayoutPolicy(FormLayoutPolicy __p)
	{
		throw new todo.TODO();
	}
	
	/**
	 * Returns the number of items in the form.
	 *
	 * @return The number of form items.
	 * @since 2109/05/19
	 */
	public int size()
	{

		return this._items.size();
	}
}