[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;
|
||||
}
|
||||
|
||||
public void set(final ImVec2 imVec2) {
|
||||
this.x = imVec2.x;
|
||||
this.y = imVec2.y;
|
||||
public void set(final ImVec2 value) {
|
||||
this.x = value.x;
|
||||
this.y = value.y;
|
||||
}
|
||||
|
||||
@Override
|
||||
|
||||
@@ -35,11 +35,11 @@ public final class ImVec4 implements Cloneable {
|
||||
this.w = w;
|
||||
}
|
||||
|
||||
public void set(final ImVec4 imVec4) {
|
||||
this.x = imVec4.x;
|
||||
this.y = imVec4.y;
|
||||
this.z = imVec4.z;
|
||||
this.w = imVec4.w;
|
||||
public void set(final ImVec4 value) {
|
||||
this.x = value.x;
|
||||
this.y = value.y;
|
||||
this.z = value.z;
|
||||
this.w = value.w;
|
||||
}
|
||||
|
||||
@Override
|
||||
|
||||
@@ -26,6 +26,10 @@ public final class ImBoolean implements Cloneable {
|
||||
data[0] = value;
|
||||
}
|
||||
|
||||
public void set(final ImBoolean value) {
|
||||
set(value.get());
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return String.valueOf(data[0]);
|
||||
|
||||
@@ -26,6 +26,10 @@ public final class ImDouble implements Cloneable {
|
||||
this.data[0] = value;
|
||||
}
|
||||
|
||||
public void set(final ImDouble value) {
|
||||
set(value.get());
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return String.valueOf(get());
|
||||
|
||||
@@ -26,6 +26,10 @@ public final class ImFloat implements Cloneable {
|
||||
this.data[0] = value;
|
||||
}
|
||||
|
||||
public void set(final ImFloat value) {
|
||||
set(value.get());
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return String.valueOf(get());
|
||||
|
||||
@@ -26,6 +26,10 @@ public final class ImInt implements Cloneable {
|
||||
this.data[0] = value;
|
||||
}
|
||||
|
||||
public void set(final ImInt value) {
|
||||
set(value.get());
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return String.valueOf(get());
|
||||
|
||||
@@ -26,6 +26,10 @@ public final class ImLong implements Cloneable {
|
||||
this.data[0] = value;
|
||||
}
|
||||
|
||||
public void set(final ImLong value) {
|
||||
set(value.get());
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return String.valueOf(get());
|
||||
|
||||
@@ -26,6 +26,10 @@ public final class ImShort implements Cloneable {
|
||||
this.data[0] = value;
|
||||
}
|
||||
|
||||
public void set(final ImShort value) {
|
||||
set(value.get());
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return String.valueOf(get());
|
||||
|
||||
@@ -81,6 +81,10 @@ public final class ImString implements Cloneable {
|
||||
return data;
|
||||
}
|
||||
|
||||
public void set(final ImString value) {
|
||||
set(value.get());
|
||||
}
|
||||
|
||||
public void set(final String value) {
|
||||
set(value, inputData.isResizable, inputData.resizeFactor);
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user