Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
是否可以“冻结”滑块(NSSlider)?当我按下按钮“开始”时,我想让我的滑块不可移动(具有固定值),这会启动我的应用程序......当我按下按钮“停止”时,它会终止我的应用程序,我想滑块再次变为可移动。
感谢你的回答!
只需使用该enabled属性:
enabled
yourSlider.enabled = NO; // this will "freeze" yourSlider.enabled = YES; // this will "unfreeze"