Avoid interruptions in the callbacks for several controls
조회 수: 5 (최근 30일)
이전 댓글 표시
I am building a GUI programmatically. In order to have data consistency, I want that all the uicontrol's don't interrupt a previously running callback function. In order to achieve so, I modify each uicontrol as:
set(hdl, 'BusyAction','cancel', 'Interruptible','off');
I want to configure all the uicontrol's at once. But there are not default value, like with the Units (DefaultUIControlUnits). Besides, they don't inherit this property from the parent control. Thus, is there any elegant way to do it?
댓글 수: 0
채택된 답변
추가 답변 (1개)
Daniel Shub
2013년 3월 6일
Callbacks are only processed when the event queue is flushed. There are only a small number of things that can cause this (pause and drawnow). As long as you are careful to never flush the event queue, you won't get any interrupts.
댓글 수: 3
Daniel Shub
2013년 3월 7일
You can use drawnow('expose') to avoid flushing the event queue while still updating the screen.
참고 항목
카테고리
Help Center 및 File Exchange에서 Migrate GUIDE Apps에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!