2014-02-14 2 views
0

Extjs4.2.2를 사용하고 있습니다.Extjs 라디오 버튼에서 suspendEvent

radiogroup의 경우 컨트롤러에 변경 리스너가 있습니다. 라디오 선택을 여러 번 프로 그램 방식으로 변경하고 있지만 일부 경우에는 변경 이벤트가 발생하지 않기를 바랍니다. 따라서 다음과 같이 선택을 변경하기 전에 suspendEvents를 사용했습니다.

radio.suspendEvents(); 
//radio.suspendEvent('change'); 
radio.setValue({communication: 1}); // where communications is the name of radios 

그러나 이것은 도움이되지 않으며 변경 이벤트가 여전히 발생합니다.

어떻게 그만합니까?

+0

전체'radiogroup' 또는 단일'radio' 구성 요소에'change' 이벤트 리스너를 설정 했습니까? – Akatum

답변

1

combobox에도 suspendEvent 이벤트 버그가 있습니다. 여기에 버그 리포트는 다음과 같습니다 http://www.sencha.com/forum/showthread.php?232919-ComboBox-suspendEvents-doesn-t-work

http://www.sencha.com/forum/showthread.php?171525-suspendEvents-did-not-affect-to-Ext.app.Controller.control

    • 내가 콤보 위해를 해결하는 솔루션을 발견했다. 어쩌면이 솔루션은 라디오에서도 작동 할 것입니다. Ext JS 4.2.1에서 작동합니다. 어쩌면 다른 버전도 있습니다.

      radio.suspendCheckChange++; 
      radio.setValue({communication: 1}); 
      radio.suspendCheckChange--; 
      
  • 관련 문제