コード例 #1
0
c4_RenameViewer::c4_RenameViewer(c4_Sequence &seq_, const c4_Property &old_,
  const c4_Property &new_): _parent(&seq_) {
  for (int i = 0; i < _parent.NumProperties(); ++i) {
    const c4_Property &prop = _parent.NthProperty(i);
    _template.AddProperty(prop.GetId() == old_.GetId() ? new_ : prop);
  }
}
コード例 #2
0
void c4_Property::operator = (const c4_Property &prop_) {
  c4_ThreadLock::Hold lock;

  prop_.Refs( + 1);
  Refs( - 1);

  _id = prop_.GetId();
  _type = prop_.Type();
}
コード例 #3
0
c4_Property::c4_Property(const c4_Property &prop_): _id(prop_.GetId()), _type
  (prop_.Type()) {
  c4_ThreadLock::Hold lock;

  d4_assert(sPropCounts != 0);
  d4_assert(sPropCounts->GetAt(_id) > 0);

  Refs( + 1);
}