qv4l2: correctly resubscribe events after a reopen.
authorHans Verkuil <hans.verkuil@cisco.com>
Sun, 20 Jul 2014 15:48:15 +0000 (17:48 +0200)
committerHans Verkuil <hans.verkuil@cisco.com>
Sun, 20 Jul 2014 15:48:15 +0000 (17:48 +0200)
commit5849910b8804f840d4b9ed485cfc8d26e6221974
treece9663fb2a1472c3125502cdd9e3b2039e220d17
parent16c5c10cfbcbe8d1fefbbae87c1d91cfaa1ea0a5
qv4l2: correctly resubscribe events after a reopen.

The reopen() call closes the original filehandle and at the same time any
subscribed events. So resubscribe the events.

In addition both the ApplicationWindow and the GeneralTab had a cv4l_fd
instance with the same fd. With reopen that means that those fd's are
no longer in sync.

GeneralTab now has a pointer to the cv4l_fd of the ApplicationWindow, so
they remain synchronized.

Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
utils/qv4l2/ctrl-tab.cpp
utils/qv4l2/general-tab.cpp
utils/qv4l2/general-tab.h
utils/qv4l2/qv4l2.cpp
utils/qv4l2/qv4l2.h