QSlider Value Changed Signal

ぐ巨炮叔叔 提交于 2019-12-02 22:05:23
Pawel Stolowski

Good question, I checked the API and also couldn't find a signal that would be triggered only if value was modified by user. The workaround you proposed may be the only option, just keep in mind that you don't have to disconnect / connect all signals, just use QObject::blockSignals method:

slider->blockSignals(true);
slider->setValue(x);
slider->blockSignals(false);

Hope that helps.

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!