MCPcopy
hub / github.com/libgdx/libgdx / setSize

Method setSize

gdx/src/com/badlogic/gdx/utils/Array.java:478–483  ·  view source on GitHub ↗

Sets the array size, leaving any values beyond the current size null. @return #items

(int newSize)

Source from the content-addressed store, hash-verified

476 /** Sets the array size, leaving any values beyond the current size null.
477 * @return {@link #items} */
478 public T[] setSize (int newSize) {
479 truncate(newSize);
480 if (newSize > items.length) resize(Math.max(8, newSize));
481 size = newSize;
482 return items;
483 }
484
485 /** Creates a new backing array with the specified size containing the current items. */
486 protected T[] resize (int newSize) {

Callers 15

keyboardWillShowMethod · 0.45
constructMethod · 0.45
initializeMethod · 0.45
checkResizeMethod · 0.45
keyboardWillShowMethod · 0.45
updateLogLabelSizeMethod · 0.45
createUIMethod · 0.45
keyUpMethod · 0.45
createMethod · 0.45
createMethod · 0.45

Calls 3

truncateMethod · 0.95
resizeMethod · 0.95
maxMethod · 0.45

Tested by 15

createUIMethod · 0.36
keyUpMethod · 0.36
createMethod · 0.36
createMethod · 0.36
renderMethod · 0.36
createMethod · 0.36
createMethod · 0.36
createMethod · 0.36
createMethod · 0.36
createMethod · 0.36
DrawableActorMethod · 0.36
createMethod · 0.36