[API] Add #set(value) method to all types
This commit is contained in:
1 parent
33d6b605d8
commit
3706927ef5
9 files changed
+36
-8
No files matched your search
@@ -27,9 +27,9 @@ public final class ImVec2 implements Cloneable {
|
|||||||
this.y = y;
|
this.y = y;
|
||||||
}
|
}
|
||||||
|
|
||||||
public void set(final ImVec2 imVec2) {
|
public void set(final ImVec2 value) {
|
||||||
this.x = imVec2.x;
|
this.x = value.x;
|
||||||
this.y = imVec2.y;
|
this.y = value.y;
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
|||||||
@@ -35,11 +35,11 @@ public final class ImVec4 implements Cloneable {
|
|||||||
this.w = w;
|
this.w = w;
|
||||||
}
|
}
|
||||||
|
|
||||||
public void set(final ImVec4 imVec4) {
|
public void set(final ImVec4 value) {
|
||||||
this.x = imVec4.x;
|
this.x = value.x;
|
||||||
this.y = imVec4.y;
|
this.y = value.y;
|
||||||
this.z = imVec4.z;
|
this.z = value.z;
|
||||||
this.w = imVec4.w;
|
this.w = value.w;
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
|||||||
@@ -26,6 +26,10 @@ public final class ImBoolean implements Cloneable {
|
|||||||
data[0] = value;
|
data[0] = value;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public void set(final ImBoolean value) {
|
||||||
|
set(value.get());
|
||||||
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public String toString() {
|
public String toString() {
|
||||||
return String.valueOf(data[0]);
|
return String.valueOf(data[0]);
|
||||||
|
|||||||
@@ -26,6 +26,10 @@ public final class ImDouble implements Cloneable {
|
|||||||
this.data[0] = value;
|
this.data[0] = value;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public void set(final ImDouble value) {
|
||||||
|
set(value.get());
|
||||||
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public String toString() {
|
public String toString() {
|
||||||
return String.valueOf(get());
|
return String.valueOf(get());
|
||||||
|
|||||||
@@ -26,6 +26,10 @@ public final class ImFloat implements Cloneable {
|
|||||||
this.data[0] = value;
|
this.data[0] = value;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public void set(final ImFloat value) {
|
||||||
|
set(value.get());
|
||||||
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public String toString() {
|
public String toString() {
|
||||||
return String.valueOf(get());
|
return String.valueOf(get());
|
||||||
|
|||||||
@@ -26,6 +26,10 @@ public final class ImInt implements Cloneable {
|
|||||||
this.data[0] = value;
|
this.data[0] = value;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public void set(final ImInt value) {
|
||||||
|
set(value.get());
|
||||||
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public String toString() {
|
public String toString() {
|
||||||
return String.valueOf(get());
|
return String.valueOf(get());
|
||||||
|
|||||||
@@ -26,6 +26,10 @@ public final class ImLong implements Cloneable {
|
|||||||
this.data[0] = value;
|
this.data[0] = value;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public void set(final ImLong value) {
|
||||||
|
set(value.get());
|
||||||
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public String toString() {
|
public String toString() {
|
||||||
return String.valueOf(get());
|
return String.valueOf(get());
|
||||||
|
|||||||
@@ -26,6 +26,10 @@ public final class ImShort implements Cloneable {
|
|||||||
this.data[0] = value;
|
this.data[0] = value;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public void set(final ImShort value) {
|
||||||
|
set(value.get());
|
||||||
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public String toString() {
|
public String toString() {
|
||||||
return String.valueOf(get());
|
return String.valueOf(get());
|
||||||
|
|||||||
@@ -81,6 +81,10 @@ public final class ImString implements Cloneable {
|
|||||||
return data;
|
return data;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public void set(final ImString value) {
|
||||||
|
set(value.get());
|
||||||
|
}
|
||||||
|
|
||||||
public void set(final String value) {
|
public void set(final String value) {
|
||||||
set(value, inputData.isResizable, inputData.resizeFactor);
|
set(value, inputData.isResizable, inputData.resizeFactor);
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in new issue
Block a user