Example #1
0
 void Data::PostLoad(KeyList<ScaleKey> &keys)
 {
   // keys lists must have at least 2 entries
   //
   if (keys.GetCount() == 0)
   {
     keys.Append( new ScaleKey( 0.0f, scale) );
   }
   if (keys.GetCount() == 1)
   {
     keys.Append( new ScaleKey( 1.0f, keys.GetHead()->scale) );
   }
   keys.KeyList<ScaleKey>::PostLoad();
 }
Example #2
0
  void Data::PostLoad( KeyList<ColorKey> &keys)
  {
    // keys lists must have at least 2 entries
    //
    if (keys.GetCount() == 0)
    {
      keys.Append( new ColorKey( 0.0f, color.r, color.g, color.b, color.a) );
    }
    if (keys.GetCount() == 1)
    {
      ColorKey *key = keys.GetHead();
      Color c = key->color;

      keys.Append( new ColorKey( 1.0f, c.r, c.g, c.b, c.a) );
    }
    keys.KeyList<ColorKey>::PostLoad();
  }