public GuiButtonList(GuiCard f)
 {
     FatherCard    = f;
     EasyAnimation = new EasyAnimation();
     EasyAnimation.AddAnimation(Animation0_FlyOut, 0.3f);
     EasyAnimation.AddAnimation(Animation1_Fade, Animation1_WhenEnd, 0.3f);
     Size = f.Size;
     Transform.SetTransform(FatherCard.Transform.Matrix);
     EasyInputAction = new EasyInputAction(this);
     EasyInputAction.AddEvent_MouseHoverFromInsideOut(CloseAllButtons);
 }
示例#2
0
        public GuiCard(Size size)
        {
            base.Size        = size;
            this.State       = StateToDraw.None;
            this.Style       = new GuiCardStyle();
            this.FrontImage  = Image.Load(".\\pic\\mon_wunaichacha.png");
            this.BackImage   = Image.Load(".\\pic\\pic_backimage.jpg"); //Card.BaceImage;
            this.GuiCardRect = new GuiCardRect(size);
            base.Dragable    = true;
            WhereIsCard      = Where.None;
            //------------------------------------------
            GuiButtonList = new GuiButtonList(this);
            GuiButtonList.AddButton(new MyGuiButton("点击1", 15, new Size(100, 50)));
            GuiButtonList.AddButton(new MyGuiButton("点击2", 15, new Size(100, 50)));
            //------------------------------------------
            EasyAudio_1 = new EasyAudio(MusicAndSounds.LightButton);
            EasyAudio_2 = new EasyAudio(MusicAndSounds.Water);
            //-----------------------------------------
            EasyInputAction = new EasyInputAction(this);
            EasyInputAction.AddEvent_InsideMouseLeftUp(Event_MouseLeftUp);
            EasyInputAction.AddEvent_InsideMouseLeftDown(Event_MouseLeftDown);
            EasyInputAction.AddEvent_InsideMouseRightUp(Event_MouseRightUp);
            EasyInputAction.AddEvent_InsideMouseLeftOnceDown(Event_MouseLeftOnceDown);


            EasyAnimation = new EasyAnimation();
            EasyAnimation.AddAnimation(Animation0, 0.7f);
        }