zoukankan      html  css  js  c++  java
  • 用WPF开发仿QQ概念版之MessageWindow开发以及Demo下载 碧血黄沙

    转眼半年了,期间发生了很多事情,一直无暇整理该代码。不说废话了,抽时间整理了下,今天先把DEMO发出来。

    一下是MessageBox窗体的代码:

    MessageWindow.xaml

     1 <Window
     2     xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
     3     xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
     4     xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
     5     xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
     6     mc:Ignorable="d"
     7     x:Class="WpfQQDemo.MessageWindow"
     8     x:Name="UserControl"
     9 
    10     d:DesignWidth="340" d:DesignHeight="142"
    11     WindowStyle="None"
    12     Background="{x:Null}"  AllowsTransparency="True" MouseLeftButtonDown="Window_MouseLeftButtonDown" WindowStartupLocation="CenterScreen" Icon="/WpfQQDemo;component/Images/logo32.ico" Height="142" Width="340">
    13 
    14     <Grid x:Name="LayoutRoot">
    15         <Image Margin="0" Source="/WpfQQDemo;component/Images/messagebg.png" Stretch="Fill"/>
    16         <Label x:Name="LabTitle" Content="" Height="25.368" Margin="6,4,82,0" VerticalAlignment="Top" Foreground="#FFFAF9F9" FontWeight="Bold"/>
    17         <Label x:Name="LabTips" Content="" Margin="56,47,13,43"/>
    18         <Button x:Name="vbutton1" Content="确定" Height="28" Margin="0,0,29,5" VerticalAlignment="Bottom" Click="vbutton1_Click" HorizontalAlignment="Right" Width="78" />
    19         <Button x:Name="vbutton2" Content="取消" Height="28" Margin="69,0,0,5" VerticalAlignment="Bottom" Click="vbutton2_Click" HorizontalAlignment="Left" Width="78" />
    20         <Button x:Name="vbutton3" Content="忽略" Height="28" Margin="151,0,111,5" VerticalAlignment="Bottom" Click="vbutton3_Click" />
    21         <Label x:Name="vPicBox" Content="" HorizontalAlignment="Left" Margin="8,47,0,52" Width="44"/>
    22         <Button x:Name="buttonclose" Content="X" Template="{StaticResource temp_b_top_close}"   HorizontalAlignment="Right" Margin="0,6.368,10.16,0" Width="22" RenderTransformOrigin="0.5,0.5" Click="buttonclose_Click" Height="22" VerticalAlignment="Top">
    23             <Button.RenderTransform>
    24                 <TransformGroup>
    25                     <ScaleTransform/>
    26                     <SkewTransform/>
    27                     <RotateTransform/>
    28                     <TranslateTransform/>
    29                 </TransformGroup>
    30             </Button.RenderTransform>
    31         </Button>
    32     </Grid>
    33 </Window>

     当然还有一个MessageBoxEx类,您自己在DEMO中反编译看看吧,我就不写出来了。

    Demo下载地址:Demo

    新站上线--咱地里 www.zandili.com 科技博客
  • 相关阅读:
    HDU 1312 Red and Black(经典DFS)
    POJ 1274 The Perfect Stall(二分图 && 匈牙利 && 最小点覆盖)
    POJ 3041 Asteroids(二分图 && 匈牙利算法 && 最小点覆盖)
    HDU 1016 素数环(dfs + 回溯)
    HDU 1035 Robot Motion(dfs + 模拟)
    vjudge Trailing Zeroes (III) (二分答案 && 数论)
    openjudge 和为给定数(二分答案)
    图的存储
    二分查找
    快速选择算法
  • 原文地址:https://www.cnblogs.com/airfey/p/2168524.html
Copyright © 2011-2022 走看看