using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Data; using System.Drawing; using System.Windows.Forms; using System.Collections; namespace testAurigmaOne { public class AnimationObjectDesigner : Aurigma.GraphicsMill.WinControls.IDesigner { protected string _fileName; protected PointF _posicaoNoCanvas; public AnimationObjectDesigner() { _vObjectHost = null; _objects = new AnimationObject[] { }; } public AnimationObjectDesigner(string filePath, PointF PosicaoNoCanvas) { _vObjectHost = null; _objects = new AnimationObject[] { }; _fileName = filePath; _posicaoNoCanvas = PosicaoNoCanvas; } public void Draw(System.Drawing.Graphics g) { } public bool Connected { get { return _vObjectHost != null; } } public Aurigma.GraphicsMill.WinControls.IVObject[] VObjects { get { return _objects; } } public void NotifyConnect(Aurigma.GraphicsMill.WinControls.IVObjectHost vObjectHost) { _vObjectHost = vObjectHost; } public void NotifyDisconnect() { _vObjectHost = null; } public bool NotifyKeyDown(System.Windows.Forms.KeyEventArgs e) { return true; } public bool NotifyKeyUp(System.Windows.Forms.KeyEventArgs e) { return true; } public bool NotifyMouseDoubleClick(System.EventArgs e) { return true; } public bool NotifyMouseDown(System.Windows.Forms.MouseEventArgs e) { AnimationObject obj = new AnimationObject(_fileName, _posicaoNoCanvas.X, _posicaoNoCanvas.Y); if (obj.SupportedActions.Contains(Aurigma.GraphicsMill.WinControls.VObjectAction.Resize)) { int c = obj.SupportedActions.Count; } _vObjectHost.CurrentLayer.VObjects.Add( obj); _vObjectHost.CurrentDesigner = _vObjectHost.DefaultDesigner; return false; } public bool NotifyMouseMove(System.Windows.Forms.MouseEventArgs e) { return true; } public bool NotifyMouseUp(System.Windows.Forms.MouseEventArgs e) { return true; } public void UpdateSettings() { } [field: System.CLSCompliant(false)] public AnimationObject [] _objects; private Aurigma.GraphicsMill.WinControls.IVObjectHost _vObjectHost; } }