cwUi.cpp : Warn if the UI resource does not have a 'main' element.
This commit is contained in:
parent
49f1f8efcd
commit
5e90a9ff53
4
cwUi.cpp
4
cwUi.cpp
@ -1207,7 +1207,9 @@ cw::rc_t cw::ui::create(
|
|||||||
{
|
{
|
||||||
const object_t* main_obj = nullptr;
|
const object_t* main_obj = nullptr;
|
||||||
|
|
||||||
if((main_obj = uiRsrc->find( "main")) != nullptr )
|
if((main_obj = uiRsrc->find( "main")) == nullptr )
|
||||||
|
cwLogWarning("The UI resource does not have a 'main' element.");
|
||||||
|
else
|
||||||
if((rc = _createFromObj( p, main_obj, kInvalidId, kRootUuId, kInvalidId )) != kOkRC )
|
if((rc = _createFromObj( p, main_obj, kInvalidId, kRootUuId, kInvalidId )) != kOkRC )
|
||||||
rc = cwLogError(rc,"Create from UI resource failed.");
|
rc = cwLogError(rc,"Create from UI resource failed.");
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user