zoukankan      html  css  js  c++  java
  • Click WhiteSpace Drag

    案例实现效果:通过鼠标左键单击窗口空白处,按住鼠标来拖动窗口。该案例实现很简单,可以应用在一些自定义窗口(如窗口不显示标题栏等情况)。

    <Window x:Class="ClickWhitespaceAndDrag.Window1"
        xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
        xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
        Title="ClickWhitespaceAndDrag" Height="300" Width="300" MouseLeftButtonDown="MyMouseLeftButtonDown"
        >
        <Grid>
            
        </Grid>
    </Window>
    void MyMouseLeftButtonDown(object sender, MouseButtonEventArgs e)
           {
               this.DragMove();
           }
  • 相关阅读:
    分享一些书籍,方方面面,很多值得一读
    C#网络爬虫--多线程处理强化版
    图书管理系统
    jquery完成界面无刷新加载登陆注册
    springboot jar项目 改为war项目
    nginx 配置文件配置(ssl和代理80端口)
    linux 安装mysql8.0
    linux redis安装和启动,远程链接
    linux nginx 安装启动
    linux tar方式安装配置jdk
  • 原文地址:https://www.cnblogs.com/January/p/2433477.html
Copyright © 2011-2022 走看看