예제 #1
0
 public SharedGraphicExercise(BasicLayer layer, int uid, string exerciseName, string userName, int width,
     int height)
     : base(layer, uid, exerciseName, userName)
 {
     Width = width;
     Height = height;
 }
예제 #2
0
 protected SharedExercise(BasicLayer layer, int uid, string exerciseName, string userName)
 {
     UID = uid;
     Layer = layer;
     ExerciseName = exerciseName;
     UserName = userName;
 }
예제 #3
0
 public override int AddLayer(string name = "", bool isRenameable = true, bool isHideable = true,
     bool isDeletable = true, bool isShareable = true, bool isInkable = true)
 {
     if (name == "")
         name = GetFallbackName();
     var layer = new BasicLayer(this, name, isRenameable, isHideable, isDeletable, isShareable, isInkable);
     Layers.Add(layer);
     return layer.UID;
 }
예제 #4
0
 public override void CollectLayer(BasicLayer layer)
 {
     var goodLayer = (QuizLayer) layer;
     foreach (var bullet in goodLayer.Bullets)
     {
         if (result.ContainsKey(bullet.Offset))
         {
             result[bullet.Offset] += (bullet.Checked ? 1 : 0);
         }
         else
         {
             result.Add(bullet.Offset, (bullet.Checked ? 1 : 0));
         }
     }
 }
예제 #5
0
 public abstract void CollectLayer(BasicLayer layer);
예제 #6
0
 public override void CollectLayer(BasicLayer layer)
 {
     throw new NotImplementedException();
 }
예제 #7
0
 public override void CollectLayer(BasicLayer layer)
 {
     foreach (var stroke in layer.Strokes)
         foreach (var point in stroke.Points)
             points.Add(point);
 }