Commit 27c0f9fa authored by claes's avatar claes

A removed attribute didn't set a new class version

parent a611129e
/*
* Proview $Id: wb_vrepmem.cpp,v 1.26 2007-10-01 14:36:15 claes Exp $
* Proview $Id: wb_vrepmem.cpp,v 1.27 2007-10-25 16:05:10 claes Exp $
* Copyright (C) 2005 SSAB Oxelsund AB.
*
* This program is free software; you can redistribute it and/or
......@@ -1089,6 +1089,9 @@ bool wb_vrepmem::deleteObject(pwr_tStatus *sts, wb_orep *orep)
return false;
}
if ( m_classeditor)
classeditorDeleteObject( memo);
if ( memo == root_object)
root_object = memo->fws;
......@@ -1995,6 +1998,32 @@ void wb_vrepmem::classeditorRenameObject( mem_object *memo, char *oldname,
}
}
void wb_vrepmem::classeditorDeleteObject( mem_object *memo)
{
switch ( memo->m_cid) {
case pwr_eClass_ObjBodyDef:
case pwr_eClass_Param:
case pwr_eClass_Intern:
case pwr_eClass_Input:
case pwr_eClass_Output:
case pwr_eClass_ObjXRef:
case pwr_eClass_AttrXRef:
case pwr_eClass_Buffer: {
// Change ohtime in parent to get new class version
if ( !memo->fth)
break;
pwr_tTime time;
clock_gettime(CLOCK_REALTIME, &time);
memo->fth->m_ohtime = time;
break;
}
default: ;
}
}
bool wb_vrepmem::classeditorCheck( ldh_eDest dest_code, mem_object *dest, pwr_tCid cid,
pwr_tOix *oix, char *name, pwr_tStatus *sts,
bool import_paste)
......
/*
* Proview $Id: wb_vrepmem.h,v 1.20 2007-09-20 15:09:18 claes Exp $
* Proview $Id: wb_vrepmem.h,v 1.21 2007-10-25 16:05:10 claes Exp $
* Copyright (C) 2005 SSAB Oxelsund AB.
*
* This program is free software; you can redistribute it and/or
......@@ -376,6 +376,7 @@ public:
void classeditorCommit();
void classeditorRenameObject( mem_object *memo, char *oldname,
wb_name &name);
void classeditorDeleteObject( mem_object *memo);
private:
bool nameCheck( mem_object *memo);
......
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