基本信息
源码名称:wpf 模仿360界面 实例源码
源码大小:1.11M
文件格式:.rar
开发语言:C#
更新时间:2017-04-23
   友情提示:(无需注册或充值,赞助后即可获取资源下载链接)

     嘿,亲!知识可是无价之宝呢,但咱这精心整理的资料也耗费了不少心血呀。小小地破费一下,绝对物超所值哦!如有下载和支付问题,请联系我们QQ(微信同号):813200300

本次赞助数额为: 2 元 
   源码介绍

using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Data;
using System.Windows.Documents;
using System.Windows.Input;
using System.Windows.Media;
using System.Windows.Media.Imaging;
using System.Windows.Shapes;

namespace _360UI
{
    /// <summary>
    /// Like360Main.xaml 的交互逻辑
    /// </summary>
    public partial class Like360Main : Window
    {
        public Like360Main()
        {
            InitializeComponent();
         
          
           
        }
        public void fnTest()
        {
            string txt = "世界引世界";
            string keys = "能源,技术,世界";
            string res = fn是否包含(keys, txt);
        }
        public string fn是否包含(string keys, string input)
        {
            string[] arrKey = keys.Split(',');
            foreach (string key in arrKey)
            {
                if (input.IndexOf(key) >= 0)
                {
                    return "1"; 
                }
            }
            return "0";

        }

        private void closeButton_Click(object sender, RoutedEventArgs e)
        {
            this.Close();
        }

        private void maxButton_Click(object sender, RoutedEventArgs e)
        {
            if (WindowState == WindowState.Normal)
                WindowState = WindowState.Maximized;
            else
                WindowState = WindowState.Normal; 
        }

        private void mniButton_Click(object sender, RoutedEventArgs e)
        {
            this.WindowState = WindowState.Minimized;
        }

        private void menuButton_Click(object sender, RoutedEventArgs e)
        {
            Menu.IsOpen = true;
        }

        private void Window_MouseLeftButtonDown(object sender, MouseButtonEventArgs e)
        {
            //拖动
            this.DragMove();
        }

        private void TabControl_SelectionChanged(object sender, SelectionChangedEventArgs e)
        {
            int index = this.tab360.SelectedIndex;
            if (index == 0)
            {
                //可以设置TransitionType WpfPage 来更改界面出入的动画效果
                //this.pTransitionControl_1.TransitionType = WpfPageTransitions.PageTransitionType.SpinAndFade;
                pages.index newPage = new pages.index();
                this.pTransitionControl_1.ShowPage(newPage);

            }

            else if (index == 1)
            {
                pages.scan newPage = new pages.scan();
                this.pTransitionControl_2.ShowPage(newPage);
            }
            else if (index == 2)
            {
                pages.scan newPage = new pages.scan();
                this.pTransitionControl_3.ShowPage(newPage);
            }
            else
            {
                pages.index newPage = new pages.index();
                this.pTransitionControl_1.ShowPage(newPage);
            }
        }
    }
}