Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
42 changes: 21 additions & 21 deletions CodenameOne/src/com/codename1/components/MultiButton.java
Original file line number Diff line number Diff line change
Expand Up @@ -971,31 +971,31 @@ public String[] getPropertyNames() {
@Override
public Class[] getPropertyTypes() {
return new Class[]{
String.class,// line1
String.class,// line2
String.class,// line3
String.class,// line4
String.class,// name1
String.class,// name2
String.class,// name3
String.class,// name4
String.class,// uiid1
String.class,// uiid2
String.class,// uiid3
String.class,// uiid4
Image.class,// icon
String.class,// iconName
String.class,// iconUiid
String.class,// iconPosition
Image.class,// emblem
String.class,// emblemName
String.class,// emblemUiid
String.class,// emblemPosition
String.class, // line1
String.class, // line2
String.class, // line3
String.class, // line4
String.class, // name1
String.class, // name2
String.class, // name3
String.class, // name4
String.class, // uiid1
String.class, // uiid2
String.class, // uiid3
String.class, // uiid4
Image.class, // icon
String.class, // iconName
String.class, // iconUiid
String.class, // iconPosition
Image.class, // emblem
String.class, // emblemName
String.class, // emblemUiid
String.class, // emblemPosition
Boolean.class,
Boolean.class,
Boolean.class,
Boolean.class,
String.class,// group
String.class, // group
Boolean.class, // selected
String.class
};
Expand Down
42 changes: 21 additions & 21 deletions CodenameOne/src/com/codename1/components/SpanMultiButton.java
Original file line number Diff line number Diff line change
Expand Up @@ -921,31 +921,31 @@ public String[] getPropertyNames() {
@Override
public Class[] getPropertyTypes() {
return new Class[]{
String.class,// line1
String.class,// line2
String.class,// line3
String.class,// line4
String.class,// name1
String.class,// name2
String.class,// name3
String.class,// name4
String.class,// uiid1
String.class,// uiid2
String.class,// uiid3
String.class,// uiid4
Image.class,// icon
String.class,// iconName
String.class,// iconUiid
String.class,// iconPosition
Image.class,// emblem
String.class,// emblemName
String.class,// emblemUiid
String.class,// emblemPosition
String.class, // line1
String.class, // line2
String.class, // line3
String.class, // line4
String.class, // name1
String.class, // name2
String.class, // name3
String.class, // name4
String.class, // uiid1
String.class, // uiid2
String.class, // uiid3
String.class, // uiid4
Image.class, // icon
String.class, // iconName
String.class, // iconUiid
String.class, // iconPosition
Image.class, // emblem
String.class, // emblemName
String.class, // emblemUiid
String.class, // emblemPosition
Boolean.class,
Boolean.class,
Boolean.class,
Boolean.class,
String.class,// group
String.class, // group
Boolean.class, // selected
String.class
};
Expand Down
10 changes: 4 additions & 6 deletions CodenameOne/src/com/codename1/components/Switch.java
Original file line number Diff line number Diff line change
Expand Up @@ -365,7 +365,7 @@ private static int getAlignedCoord(int coord, int parentDim, int elemDim, int al
case Component.BOTTOM:
return coord + parentDim - elemDim;
//case Component.LEFT: case Component.TOP:
// return coord;
// return coord;
default:
return coord;
}
Expand Down Expand Up @@ -749,7 +749,7 @@ public void paint(Graphics g) {
}

Style s = getStyle();
int padLeft = s.getPaddingLeft(isRTL());//s.getPaddingLeftNoRTL();
int padLeft = s.getPaddingLeft(isRTL()); //s.getPaddingLeftNoRTL();
int padRight = s.getPaddingRight(isRTL());
int padTop = s.getPaddingTop();
int padBot = s.getPaddingBottom();
Expand Down Expand Up @@ -991,8 +991,7 @@ public void setOff() {
*/
@Override
public String[] getPropertyNames() {
return new String[]{
"value",};
return new String[] {"value"};
}

/**
Expand Down Expand Up @@ -1026,8 +1025,7 @@ public void setComponentState(Object state) {
*/
@Override
public Class[] getPropertyTypes() {
return new Class[]{
Boolean.class,};
return new Class[] { Boolean.class };
}

/**
Expand Down
12 changes: 6 additions & 6 deletions CodenameOne/src/com/codename1/io/gzip/Deflate.java
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ final class Deflate {
"data error", // Z_DATA_ERROR (-3)
"insufficient memory", // Z_MEM_ERROR (-4)
"buffer error", // Z_BUF_ERROR (-5)
"incompatible version",// Z_VERSION_ERROR (-6)
"incompatible version", // Z_VERSION_ERROR (-6)
""
};
// block not completed, need more input or more output
Expand Down Expand Up @@ -386,7 +386,7 @@ void pqdownheap(short[] tree, // the tree to restore

// Scan a literal or distance tree to determine the frequencies of the codes
// in the bit length tree.
void scanTree(short[] tree,// the tree to be scanned
void scanTree(short[] tree, // the tree to be scanned
int maxCode // and its largest code of non-zero frequency
) {
int n; // iterates over all tree elements
Expand Down Expand Up @@ -482,7 +482,7 @@ void sendAllTrees(int lcodes, int dcodes, int blcodes) {

// Send a literal or distance tree in compressed form, using the codes in
// bl_tree.
void sendTree(short[] tree,// the tree to be sent
void sendTree(short[] tree, // the tree to be sent
int maxCode // and its largest code of non zero frequency
) {
int n; // iterates over all tree elements
Expand Down Expand Up @@ -1033,7 +1033,7 @@ int deflateFast(int flush) {
if (lookahead >= MIN_MATCH) {
insH = (((insH) << hashShift) ^ (window[(strStart) + (MIN_MATCH - 1)] & 0xff)) & hashMask;

// prev[strstart&w_mask]=hashHead=head[ins_h];
// prev[strstart&w_mask]=hashHead=head[ins_h];
hashHead = (head[insH] & 0xffff);
prev[strStart & wMask] = head[insH];
head[insH] = (short) strStart;
Expand Down Expand Up @@ -1069,7 +1069,7 @@ int deflateFast(int flush) {
strStart++;

insH = ((insH << hashShift) ^ (window[(strStart) + (MIN_MATCH - 1)] & 0xff)) & hashMask;
// prev[strstart&w_mask]=hashHead=head[ins_h];
// prev[strstart&w_mask]=hashHead=head[ins_h];
hashHead = (head[insH] & 0xffff);
prev[strStart & wMask] = head[insH];
head[insH] = (short) strStart;
Expand Down Expand Up @@ -1145,7 +1145,7 @@ int deflateSlow(int flush) {

if (lookahead >= MIN_MATCH) {
insH = (((insH) << hashShift) ^ (window[(strStart) + (MIN_MATCH - 1)] & 0xff)) & hashMask;
// prev[strstart&w_mask]=hashHead=head[ins_h];
// prev[strstart&w_mask]=hashHead=head[ins_h];
hashHead = (head[insH] & 0xffff);
prev[strStart & wMask] = head[insH];
head[insH] = (short) strStart;
Expand Down
2 changes: 1 addition & 1 deletion CodenameOne/src/com/codename1/io/gzip/InfBlocks.java
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ final class InfBlocks {

static final private int TYPE = 0; // get type bits (3, including end bit)
static final private int LENS = 1; // get lengths for stored
static final private int STORED = 2;// processing stored block
static final private int STORED = 2; // processing stored block
static final private int TABLE = 3; // get table lengths
static final private int BTREE = 4; // get bit lengths tree for a dynamic block
static final private int DTREE = 5; // get length, distance trees for a dynamic block
Expand Down
4 changes: 2 additions & 2 deletions CodenameOne/src/com/codename1/io/gzip/InfCodes.java
Original file line number Diff line number Diff line change
Expand Up @@ -55,12 +55,12 @@ final class InfCodes {
static final private int LEN = 1; // i: get length/literal/eob next
static final private int LENEXT = 2; // i: getting length extra (have base)
static final private int DIST = 3; // i: get distance next
static final private int DISTEXT = 4;// i: getting distance extra
static final private int DISTEXT = 4; // i: getting distance extra
static final private int COPY = 5; // o: copying bytes in window, waiting for space
static final private int LIT = 6; // o: got literal, waiting for output space
static final private int WASH = 7; // o: got eob, possibly still output waiting
static final private int END = 8; // x: got eob and all data flushed
static final private int BADCODE = 9;// x: got error
static final private int BADCODE = 9; // x: got error
private final ZStream z;
private final InfBlocks s;
int mode; // current inflate_codes mode
Expand Down
8 changes: 4 additions & 4 deletions CodenameOne/src/com/codename1/io/gzip/InfTree.java
Original file line number Diff line number Diff line change
Expand Up @@ -214,8 +214,8 @@ final class InfTree {

static int inflateTreesFixed(int[] bl, //literal desired/actual bit depth
int[] bd, //distance desired/actual bit depth
int[][] tl,//literal/length tree result
int[][] td,//distance tree result
int[][] tl, //literal/length tree result
int[][] td, //distance tree result
ZStream z //for memory allocation
) {
bl[0] = fixed_bl;
Expand All @@ -233,8 +233,8 @@ private int huftBuild(int[] b, // code lengths in bits (all assumed <= BMAX)
int[] e, // list of extra bits for non-simple codes
int[] t, // result: starting table
int[] m, // maximum lookup bits, returns actual
int[] hp,// space for trees
int[] hn,// hufts used in space
int[] hp, // space for trees
int[] hn, // hufts used in space
int[] v // working area: values in order of bit length
) {
// Given a list of code lengths and a maximum table size, make a set of
Expand Down
10 changes: 5 additions & 5 deletions CodenameOne/src/com/codename1/io/gzip/Inflate.java
Original file line number Diff line number Diff line change
Expand Up @@ -247,9 +247,9 @@ int inflate(int f) {
this.mode = BAD;
z.msg = "unknown compression method";
// since zlib 1.2, it is allowted to inflateSync for this case.
/*
/*
this.marker = 5; // can't try inflateSync
*/
*/
break;
}

Expand All @@ -261,9 +261,9 @@ int inflate(int f) {
this.mode = BAD;
z.msg = "invalid window size";
// since zlib 1.2, it is allowted to inflateSync for this case.
/*
/*
this.marker = 5; // can't try inflateSync
*/
*/
break;
}

Expand Down Expand Up @@ -403,7 +403,7 @@ int inflate(int f) {
this.mode = BAD;
this.marker = 5; // can't try inflateSync
break;
*/
*/
} else if (flags != 0 && gheader != null) {
gheader.crc = this.need;
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
Derivative Revision History:

2012-03 - Pulled this code from Sun's JavaME JSON impl, JSONObject
and moved to separate utility class.
and moved to separate utility class.
*/
package com.codename1.processing;

Expand Down
26 changes: 13 additions & 13 deletions CodenameOne/src/com/codename1/processing/Result.java
Original file line number Diff line number Diff line change
Expand Up @@ -190,11 +190,11 @@ public static Result fromContent(String content, String format)
*
* <pre>
* ConnectionRequest request = new ConnectionRequest() {
* protected void readResponse(InputStream input) throws IOException {
* Result evaluator = Result.fromContent(input, Result.JSON);
* // ... evaluate the result here
* protected void readResponse(InputStream input) throws IOException {
* Result evaluator = Result.fromContent(input, Result.JSON);
* // ... evaluate the result here
* }
* // ... etc
* // ... etc
* };
* </pre>
*
Expand Down Expand Up @@ -231,11 +231,11 @@ public static Result fromContent(InputStream content, String format)
*
* <pre>
* ConnectionRequest request = new ConnectionRequest() {
* protected void readResponse(InputStream input) throws IOException {
* Result evaluator = Result.fromContent(input, Result.JSON);
* // ... evaluate the result here
* protected void readResponse(InputStream input) throws IOException {
* Result evaluator = Result.fromContent(input, Result.JSON);
* // ... evaluate the result here
* }
* // ... etc
* // ... etc
* };
* </pre>
*
Expand Down Expand Up @@ -661,7 +661,7 @@ public int getSizeOfArray(final String path)
*
* <pre>
* String types[] = result
* .getAsStringArray(&quot;/results[0]/address_components[2]/types&quot;);
* .getAsStringArray(&quot;/results[0]/address_components[2]/types&quot;);
* </pre>
*
* @param path Path expression to evaluate
Expand Down Expand Up @@ -721,7 +721,7 @@ private String getTextInternal(Object o) {
*
* <pre>
* String types[] = result
* .getAsStringArray(&quot;/results[0]/address_components[2]/types&quot;);
* .getAsStringArray(&quot;/results[0]/address_components[2]/types&quot;);
* </pre>
*
* @param path Path expression to evaluate
Expand Down Expand Up @@ -751,7 +751,7 @@ public int[] getAsIntegerArray(final String path)
* Get an array of values from the requested path.
* <pre>
* String types[] = result
* .getAsStringArray(&quot;/results[0]/address_components[2]/types&quot;);
* .getAsStringArray(&quot;/results[0]/address_components[2]/types&quot;);
* </pre>
*
* @param path Path expression to evaluate
Expand Down Expand Up @@ -781,7 +781,7 @@ public long[] getAsLongArray(final String path)
* Get an array of values from the requested path.
* <pre>
* String types[] = result
* .getAsStringArray(&quot;/results[0]/address_components[2]/types&quot;);
* .getAsStringArray(&quot;/results[0]/address_components[2]/types&quot;);
* </pre>
*
* @param path Path expression to evaluate
Expand All @@ -807,7 +807,7 @@ public double[] getAsDoubleArray(final String path)
* Get an array of values from the requested path.
* <pre>
* String types[] = result
* .getAsStringArray(&quot;/results[0]/address_components[2]/types&quot;);
* .getAsStringArray(&quot;/results[0]/address_components[2]/types&quot;);
* </pre>
*
* @param path Path expression to evaluate
Expand Down
4 changes: 2 additions & 2 deletions CodenameOne/src/com/codename1/processing/ResultTokenizer.java
Original file line number Diff line number Diff line change
Expand Up @@ -32,8 +32,8 @@ LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
Derivative Revision History:

2012-03 - derivative work from original Sun source, added
support for nested expressions to support new features added
to Result class.
support for nested expressions to support new features added
to Result class.
*/

package com.codename1.processing;
Expand Down
2 changes: 1 addition & 1 deletion CodenameOne/src/com/codename1/ui/Dialog.java
Original file line number Diff line number Diff line change
Expand Up @@ -1915,7 +1915,7 @@ private void growOrShrinkImpl(int w, int h) {
menuHeight = menuBar.getPreferredH() + menuStyle.getVerticalMargins();
}
prefWidth = Math.min(prefWidth, w);
h = h - menuHeight - title.getPreferredH();// - titleStyle.getMargin(false, TOP) - titleStyle.getMargin(false, BOTTOM);
h = h - menuHeight - title.getPreferredH(); // - titleStyle.getMargin(false, TOP) - titleStyle.getMargin(false, BOTTOM);
int topBottom = Math.max(0, (h - prefHeight) / 2);
int leftRight = Math.max(0, (w - prefWidth) / 2);
int top = topBottom;
Expand Down
2 changes: 1 addition & 1 deletion CodenameOne/src/com/codename1/ui/Slider.java
Original file line number Diff line number Diff line change
Expand Up @@ -440,7 +440,7 @@ public void paintComponentBackground(Graphics g) {
g.drawImage(thumbImage, xPos,
y + height / 2 - thumbImage.getHeight() / 2);
} else {
int yPos = y;// + height - thumbImage.getHeight() / 2;
int yPos = y; // + height - thumbImage.getHeight() / 2;
//yPos = Math.max(getY(), yPos);
//yPos = Math.min(getY() + getHeight() - thumbImage.getHeight(), yPos);
g.drawImage(thumbImage, getX() + width / 2 - thumbImage.getWidth() / 2,
Expand Down
Loading
Loading