惯性聚合 高效追踪和阅读你感兴趣的博客、新闻、科技资讯
阅读原文 在惯性聚合中打开

推荐订阅源

Help Net Security
Help Net Security
S
SegmentFault 最新的问题
T
The Blog of Author Tim Ferriss
J
Java Code Geeks
博客园 - 三生石上(FineUI控件)
月光博客
月光博客
C
Check Point Blog
M
MIT News - Artificial intelligence
GbyAI
GbyAI
H
Hackread – Cybersecurity News, Data Breaches, AI and More
U
Unit 42
D
Docker
G
Google Developers Blog
云风的 BLOG
云风的 BLOG
H
Help Net Security
D
DataBreaches.Net
Microsoft Azure Blog
Microsoft Azure Blog
B
Blog RSS Feed
Engineering at Meta
Engineering at Meta
Cyber Security Advisories - MS-ISAC
Cyber Security Advisories - MS-ISAC
B
Blog
Cloudbric
Cloudbric
Blog — PlanetScale
Blog — PlanetScale
K
KPMG report finds enterprise disconnect between AI and its ROI | CIO
T
Troy Hunt's Blog
N
News | PayPal Newsroom
V2EX - 技术
V2EX - 技术
H
Heimdal Security Blog
S
Security @ Cisco Blogs
V
Visual Studio Blog
The Last Watchdog
The Last Watchdog
博客园 - Franky
大猫的无限游戏
大猫的无限游戏
Exploit-DB.com RSS Feed
Exploit-DB.com RSS Feed
Webroot Blog
Webroot Blog
Security Archives - TechRepublic
Security Archives - TechRepublic
C
Cyber Attacks, Cyber Crime and Cyber Security
Last Week in AI
Last Week in AI
爱范儿
爱范儿
博客园 - 聂微东
S
Securelist
小众软件
小众软件
酷 壳 – CoolShell
酷 壳 – CoolShell
Cisco Talos Blog
Cisco Talos Blog
奇客Solidot–传递最新科技情报
奇客Solidot–传递最新科技情报
C
CXSECURITY Database RSS Feed - CXSecurity.com
V
Vulnerabilities – Threatpost
让小产品的独立变现更简单 - ezindie.com
让小产品的独立变现更简单 - ezindie.com
O
OpenAI News
Apple Machine Learning Research
Apple Machine Learning Research

博客园 - OnlyLiu

ZigBee On Windows Mobile-ZigBee模块的设计制作[转] dojo的学习笔记【转】 三五个人十来条枪 如何走出软件作坊成为开发正规军 甘特图(Javascript实现) - SIcon Gantt Chart GPRS开发系列文章 Fully Editable GridView .net中的socket异步通信实现 Window Mobile 常用资源 ListView Custom Controls in Visual C# .NET (很详细,还是外国人严谨) C# 实现屏幕键盘 (ScreenKeyboard) SerialPort Flex delphi播放flash 蒙板 生死不离 [转]孩子,这水不用买 转发一首 《孩子快抓紧妈妈的手》 ------献给在四川大地震中遇难的孩子
使用C#实现WinForm窗体的动画效果
OnlyLiu · 2008-06-11 · via 博客园 - OnlyLiu

C# Form Animation with Windows API

.NET Animation Control
C# GameDev: Simple Animation  
An Animation Component using C#
C#如何实现渐显窗口[原创]

using System.Runtime.InteropServices;

 public class Win32
 {
  public const Int32 AW_HOR_POSITIVE = 0x00000001; // 从左到右打开窗口
  public const Int32 AW_HOR_NEGATIVE = 0x00000002; // 从右到左打开窗口
  public const Int32 AW_VER_POSITIVE = 0x00000004; // 从上到下打开窗口
  public const Int32 AW_VER_NEGATIVE = 0x00000008; // 从下到上打开窗口
  public const Int32 AW_CENTER = 0x00000010; //若使用了AW_HIDE标志,则使窗口向内重叠;若未使用AW_HIDE标志,则使窗口向外扩展。
  public const Int32 AW_HIDE = 0x00010000; //隐藏窗口,缺省则显示窗口。
  public const Int32 AW_ACTIVATE = 0x00020000; //激活窗口。在使用了AW_HIDE标志后不要使用这个标志。
  public const Int32 AW_SLIDE = 0x00040000; //使用滑动类型。缺省则为滚动动画类型。当使用AW_CENTER标志时,这个标志就被忽略。
  public const Int32 AW_BLEND = 0x00080000; //使用淡出效果。只有当hWnd为顶层窗口的时候才可以使用此标志。
  [DllImport("user32.dll", CharSet = CharSet.Auto)]
  public static extern bool AnimateWindow(
    IntPtr hwnd, // handle to window
    int dwTime, // duration of animation
    int dwFlags // animation type
    );
 }

 /*淡入窗体*/
 private void Form_Load(object sender, EventArgs e)
 {
  Win32.AnimateWindow(this.Handle, 2000, Win32.AW_BLEND);
 }
 /*淡出窗体*/
 private void Form_FormClosing(object sender, FormClosingEventArgs e)
 {
  Win32.AnimateWindow(this.Handle, 2000, Win32.AW_SLIDE | Win32.AW_HIDE | Win32.AW_BLEND);
 }