fix compile errors with GCC/Clang

This commit is contained in:
Jinhao
2016-01-20 14:40:57 +08:00
parent ece696c3b5
commit 920a1fe490
5 changed files with 23 additions and 12 deletions

View File

@@ -263,7 +263,7 @@ namespace checkbox
if (ui_container_.end() == i)
return;
checkbox * target;
checkbox * target = nullptr;
if (keyboard::os_arrow_up == arg.key)
{
@@ -280,8 +280,11 @@ namespace checkbox
target = ui_container_.front().uiobj;
}
target->check(true);
target->focus();
if(target)
{
target->check(true);
target->focus();
}
});