mirror of
https://port.numenaute.org/aleajactaest/khanat-opennel-code.git
synced 2024-12-03 17:14:46 +00:00
CDBViewQuantity shouldn't crash in the editor.
This commit is contained in:
parent
2e0f06f231
commit
836e2814d8
1 changed files with 10 additions and 7 deletions
|
@ -157,14 +157,17 @@ namespace NLGUI
|
|||
// ***************************************************************************
|
||||
void CDBViewQuantity::draw ()
|
||||
{
|
||||
// change text
|
||||
sint32 val= _Number.getSInt32();
|
||||
sint32 valMax= _NumberMax.getSInt32();
|
||||
if(_Cache!=val || _CacheMax!=valMax)
|
||||
if( _Number.hasValue() && _NumberMax.hasValue() )
|
||||
{
|
||||
_Cache= val;
|
||||
_CacheMax=valMax;
|
||||
buildTextFromCache();
|
||||
// change text
|
||||
sint32 val= _Number.getSInt32();
|
||||
sint32 valMax= _NumberMax.getSInt32();
|
||||
if(_Cache!=val || _CacheMax!=valMax)
|
||||
{
|
||||
_Cache= val;
|
||||
_CacheMax=valMax;
|
||||
buildTextFromCache();
|
||||
}
|
||||
}
|
||||
|
||||
// parent call
|
||||
|
|
Loading…
Reference in a new issue