2017년 1월 31일 화요일

자마린 스튜디오(Xamarin Studio)에서 작성한 간단한 애니메이션 코드 입니다.

버튼이 회전하는 간단한 애니메이션 코드입니다. 재물로 버튼을 디자인하고 클릭하면 360도 회전하도록 되어 있습니다. 

<?xml version="1.0" encoding="utf-8"?>
<ContentPage xmlns="http://xamarin.com/schemas/2014/forms" xmlns:x="http://schemas.microsoft.com/winfx/2009/xaml" xmlns:local="clr-namespace:DemoAnimation" x:Class="DemoAnimation.DemoAnimationPage">

    <Button x:Name="button"
            Text="Tap Me!"
            FontSize="Large"
            HorizontalOptions="Center"
            VerticalOptions="Center"
            Clicked="OnButtonClicked" />
    
</ContentPage>


using Xamarin.Forms;
using System; 

namespace DemoAnimation
{
    public partial class DemoAnimationPage : ContentPage
    {
        public DemoAnimationPage()
        {
            InitializeComponent();
        }

        void OnButtonClicked(object sender, EventArgs args)
        {
            button.RotateTo(360); 
        }
    }
}



댓글 없음:

댓글 쓰기

참고: 블로그의 회원만 댓글을 작성할 수 있습니다.

일상생활에서 사용되는 로봇 - 중국

아직은 가격이 저렴하지 않고, 기술적인 한계도 있지만 일상으로 빠르게 로봇이 들어올 것 같습니다.  피지컬 AI는 올해가 새로운 해가 되겠죠. ㅎㅎ   https://www.youtube.com/watch?v=r6g37b6JxnE