[android] return color string values in the [0-255] range
This commit is contained in:
committed by
Łukasz Paczos
parent
4224b89a9c
commit
b21f9f3e35
@@ -25,18 +25,7 @@ Result<jni::Local<jni::Object<>>> Converter<jni::Local<jni::Object<>>, std::stri
|
||||
}
|
||||
|
||||
Result<jni::Local<jni::Object<>>> Converter<jni::Local<jni::Object<>>, Color>::operator()(jni::JNIEnv& env, const Color& value) const {
|
||||
std::string result;
|
||||
result.reserve(32);
|
||||
result += "rgba(";
|
||||
result += util::toString(value.r);
|
||||
result += ", ";
|
||||
result += util::toString(value.g);
|
||||
result += ", ";
|
||||
result += util::toString(value.b);
|
||||
result += ", ";
|
||||
result += util::toString(value.a);
|
||||
result += ")";
|
||||
return jni::Make<jni::String>(env, result);
|
||||
return jni::Make<jni::String>(env, value.stringify());
|
||||
}
|
||||
|
||||
Result<jni::Local<jni::Object<>>> Converter<jni::Local<jni::Object<>>, style::expression::Formatted>::operator()(jni::JNIEnv& env, const style::expression::Formatted& value) const {
|
||||
|
||||
Reference in New Issue
Block a user