Yes, you can see it in docs:
Note: A value will be emitted immediately on subscribe.
This is the behavior for all view that have 'state', that makes sense, as otherwise you will not get notify about the initial value of the view when subscribed, but will react only on first change.
You can also note this from the custom type of the returned Observable
- InitialValueObservable
.
If you don't want this behavior you can use skipInitialValue()
, this is a special operator at the custom InitialValueObservable
:
RxCompoundButton.checkedChanges(btOneWayFlag)
.skipInitialValue()
.debounce(0, TimeUnit.MILLISECONDS, AndroidSchedulers.mainThread())
.subscribe(notifyOneWayChecked);