GithubHelp home page GithubHelp logo

mvvm's Issues

请教 依赖属性传递问题

谢谢你的例子,很少看到这么整洁的例子

以下是我的一些问题:

  1. 我在代码上打了断点, 以跟踪界面改动如何通知到viewmodel里, 我发现更改了 用户名 之后, 代码里除了 User.UserName 触发修改, 并不会通知到上层的 LoginViewModel 里的 User 中, 意思是WPF的依赖属性不支持嵌套传递吗?
  2. 如果我希望一开始登录按钮是不可用的 , 界面上用户名和密码都为空, 当用户密码都输入有值时登录按钮才会变为可用. ------ 类似这样的需求我应该如何实现会优雅点? 我现在想到的是在 User 内做event , LoginViewModel 来注册这个事件.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.