Commit 539c4212 authored by kenan's avatar kenan

fix refreshTexture

parent cf193a10
......@@ -1116,7 +1116,7 @@ bool DeckBuilder::OnEvent(const irr::SEvent& event) {
s32 y = event.MouseInput.Y;
irr::core::position2di pos(x, y);
if (x < (200 * mainGame->xScale) && y < (270 * mainGame->yScale)) {
mainGame->textFont->setTransparency(true);
mainGame->refreshTexture();
mainGame->ClearChatMsg();
break;
}//touch the pic of detail to refresh textfonts
......
......@@ -1053,7 +1053,7 @@ bool ClientField::OnEvent(const irr::SEvent& event) {
hovered_location = 0;
irr::core::position2di pos(x, y);
if (x < (200 * mainGame->xScale) && y < (270 * mainGame->yScale)) {
mainGame->textFont->setTransparency(true);
mainGame->refreshTexture();
mainGame->ClearChatMsg();
break;
}//touch the pic of detail to refresh textfonts
......@@ -1925,14 +1925,14 @@ bool ClientField::OnCommonEvent(const irr::SEvent& event) {
case irr::KEY_KEY_R: {
if(mainGame->gameConf.control_mode == 0
&& !event.KeyInput.PressedDown && !mainGame->HasFocus(EGUIET_EDIT_BOX))
mainGame->textFont->setTransparency(true);
mainGame->refreshTexture();
return true;
break;
}
case irr::KEY_F9: {
if(mainGame->gameConf.control_mode == 1
&& !event.KeyInput.PressedDown && !mainGame->HasFocus(EGUIET_EDIT_BOX))
mainGame->textFont->setTransparency(true);
mainGame->refreshTexture();
return true;
break;
}
......
......@@ -1758,4 +1758,15 @@ JNIEnv* Game::getJniEnv(){
}
#endif
void Game::refreshTexture(){
#ifdef _IRR_ANDROID_PLATFORM_
LOGD("refreshTexture before");
#endif
gMutex.lock();
textFont->setTransparency(true);
gMutex.unlock();
#ifdef _IRR_ANDROID_PLATFORM_
LOGD("refreshTexture after");
#endif
}
}
......@@ -560,6 +560,7 @@ public:
JNIEnv* getJniEnv();
#endif
void refreshTexture();
void runWindbot(const char* cmd);
io::path getCardImagePath(){
return cardImagePath;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment