By itamarco
on Wed, 06/20/2012 - 17:12
Hello
Im using the VirtualButoons sample code.
i want to change the isPressed action, so the button name will displayed to the screen.
i tried to do that by changing the renderFrame function in virtuslButttons.cpp
to this code:
[CODE]
if (button->isPressed())
{
jstring js = env->NewStringUTF(button->getName());
jclass javaClass = env->GetObjectClass(obj);
jmethodID method = env->GetMethodID(javaClass, "displayMessage", "(Ljava/lang/String;)V");
env->CallVoidMethod(obj, method, js);
} [/CODE]
however,
when pressing buttons a message appear but stay for long time,
even after "releasing the button.
what did i do wrong?
how to change Virtual Buttons action?