Пример #1
0
        public void Execute(object parameter)
        {
            Type t = parameter as Type;

            //if (t.Name == "VEXDBFileModel")
            //    UIStateCategoyModel parent = parameter as UIStateCategoyModel;

            UInt32 id = 0;

            if (mpm != null)
            {
                var tableModel = mpm.Parent as DBTableModel;
                if (tableModel != null)
                {
                    id = tableModel.AutoIncrement();
                }
            }

            //if (id > 0)
            //{
            //    if (t.Name == "RenderableComponent")
            //    {
            //        EntityX newEntity = new EntityX() {  Name = "New Entity" };
            //        RenderableComponent pom = new RenderableComponent() { Parent = newEntity };


            //      //  pom.Create();
            //        mpm.Items.Add(newEntity);
            //        newEntity.Components.Add(pom);
            //    }

            if (t.Name == "Atlas")
            {
                // EntityX newEntity = new EntityX() { Name = "New Entity" };
                AtlasModel pom = new AtlasModel();// { Parent = newEntity };

                //  pom.Create();
                mpm.Items.Add(pom);
                //  newEntity.Components.Add(pom);
            }
            else if (t.Name == "UIStateModel")
            {
                // EntityX newEntity = new EntityX() { Name = "New Entity" };
                UIStateModel pom = new UIStateModel();// { Parent = newEntity };

                //  pom.Create();
                mpm.Items.Add(pom);
                //  newEntity.Components.Add(pom);
            }
            //}
            //else
            //{
            //    (VEFModule.UnityContainer.Resolve(typeof(ILoggerService), "") as ILoggerService).Log("Error: CmdCreateStaticObj id =  (" + id.ToString() + ")", LogCategory.Error, LogPriority.High);
            //}
        }
Пример #2
0
 public CmdLoadGorillaFile(AtlasModel pm)
 {
     mpm = pm;
 }
Пример #3
0
 public CmdGenerateAtlas(AtlasModel pm)
 {
     mpm = pm;
 }
Пример #4
0
 public CmdLoadAngelCodeFontFile(AtlasModel pm)
 {
     mpm = pm;
 }
Пример #5
0
 public CmdGenFBAtlasFile(AtlasModel pm)
 {
     mpm = pm;
 }