공지사항:
2025년 4월 15일 전에 Earth Engine 사용을 위해 등록된 모든 비상업용 프로젝트는 Earth Engine 액세스를 유지하기 위해
비상업용 자격 요건을 인증해야 합니다.
ui.Slider.onChange
컬렉션을 사용해 정리하기
내 환경설정을 기준으로 콘텐츠를 저장하고 분류하세요.
슬라이더의 상태가 변경될 때 실행되는 콜백을 등록합니다. 사용자가 슬라이더를 드래그하여 변경한 경우 드래그가 완료될 때까지 이벤트가 실행되지 않습니다.
콜백을 등록 취소하기 위해 unlisten()에 전달할 수 있는 ID를 반환합니다.
사용 | 반환 값 |
---|
Slider.onChange(callback) | 문자열 |
인수 | 유형 | 세부정보 |
---|
다음과 같은 경우: ui.slider | ui.Slider | ui.Slider 인스턴스입니다. |
callback | 함수 | 슬라이더의 상태가 변경될 때 실행되는 콜백입니다. 콜백에는 슬라이더의 현재 값과 슬라이더 위젯이 전달됩니다. |
달리 명시되지 않는 한 이 페이지의 콘텐츠에는 Creative Commons Attribution 4.0 라이선스에 따라 라이선스가 부여되며, 코드 샘플에는 Apache 2.0 라이선스에 따라 라이선스가 부여됩니다. 자세한 내용은 Google Developers 사이트 정책을 참조하세요. 자바는 Oracle 및/또는 Oracle 계열사의 등록 상표입니다.
최종 업데이트: 2025-07-26(UTC)
[null,null,["최종 업데이트: 2025-07-26(UTC)"],[[["\u003cp\u003eThe \u003ccode\u003eonChange\u003c/code\u003e method registers a callback function that is triggered when the slider's value changes, but only after a user completes dragging the slider.\u003c/p\u003e\n"],["\u003cp\u003eIt returns a unique ID that can be used with the \u003ccode\u003eunlisten()\u003c/code\u003e method to remove the registered callback.\u003c/p\u003e\n"],["\u003cp\u003eThe callback function receives the slider's current value and the slider widget itself as arguments when invoked.\u003c/p\u003e\n"]]],["The `Slider.onChange` method registers a callback function to be executed when a slider's state changes. This callback is triggered after a user completes dragging the slider, not during the drag. The method accepts a callback function as an argument, which receives the slider's current value and the slider widget itself. It returns a unique ID (string) that can be used to unregister the callback later using `unlisten()`.\n"],null,["# ui.Slider.onChange\n\n\u003cbr /\u003e\n\nRegisters a callback that's fired when the slider's state changes. If the change is due to the user dragging the slider, the event will not fire until the drag completes.\n\n\u003cbr /\u003e\n\nReturns an ID which can be passed to unlisten() to unregister the callback.\n\n| Usage | Returns |\n|-----------------------------|---------|\n| Slider.onChange`(callback)` | String |\n\n| Argument | Type | Details |\n|-------------------|-----------|--------------------------------------------------------------------------------------------------------------------------------|\n| this: `ui.slider` | ui.Slider | The ui.Slider instance. |\n| `callback` | Function | The callback to fire when the slider's state changes. The callback is passed the slider's current value and the slider widget. |"]]