Method
GLibMainContextadd_poll
Declaration [src]
void
g_main_context_add_poll (
GMainContext* context,
GPollFD* fd,
gint priority
)
Description [src]
Adds a file descriptor to the set of file descriptors polled for
this context. This will very seldom be used directly. Instead
a typical event source will use g_source_add_unix_fd instead.
Parameters
context-
Type:
GMainContextA
GMainContext(orNULLfor the global-default main context).The argument can be NULL. fd-
Type:
GPollFDA
GPollFDstructure holding information about a file descriptor to watch.The data is owned by the caller of the method. priority-
Type:
gintThe priority for this file descriptor which should be the same as the priority used for
g_source_attach()to ensure that the file descriptor is polled whenever the results may be needed.