Mir
Main Page
Related Pages
Modules
Namespaces
Classes
Files
Examples
File List
File Members
include
client
mir_toolkit
mir_prompt_session.h
Go to the documentation of this file.
1
/*
2
* Copyright © 2014 Canonical Ltd.
3
*
4
* This program is free software: you can redistribute it and/or modify it
5
* under the terms of the GNU Lesser General Public License version 3,
6
* as published by the Free Software Foundation.
7
*
8
* This program is distributed in the hope that it will be useful,
9
* but WITHOUT ANY WARRANTY; without even the implied warranty of
10
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
11
* GNU Lesser General Public License for more details.
12
*
13
* You should have received a copy of the GNU Lesser General Public License
14
* along with this program. If not, see <http://www.gnu.org/licenses/>.
15
*/
16
17
#ifndef MIR_TOOLKIT_MIR_PROMPT_SESSION_H_
18
#define MIR_TOOLKIT_MIR_PROMPT_SESSION_H_
19
20
#include "
mir_toolkit/mir_client_library.h
"
21
22
#include <sys/types.h>
23
#include <stdbool.h>
24
25
#ifdef __cplusplus
26
30
extern
"C"
{
31
#endif
32
41
MirPromptSession
*
mir_connection_create_prompt_session_sync
(
42
MirConnection
* connection,
43
pid_t application_pid,
44
MirPromptSessionStateChangeCallback
state_change_callback,
45
void
*context);
46
61
MirWaitHandle
*
mir_prompt_session_new_fds_for_prompt_providers
(
62
MirPromptSession
*prompt_session,
63
unsigned
int
no_of_fds,
64
MirClientFdCallback
callback,
65
void
* context);
66
80
size_t
mir_prompt_session_new_fds_for_prompt_providers_sync
(
81
MirPromptSession
*prompt_session,
82
unsigned
int
no_of_fds,
83
int
* fds);
88
void
mir_prompt_session_release_sync
(
MirPromptSession
*prompt_session);
89
95
bool
mir_prompt_session_is_valid
(
MirPromptSession
*prompt_session);
96
105
char
const
*
mir_prompt_session_error_message
(
MirPromptSession
*prompt_session);
106
107
#ifdef __cplusplus
108
}
110
#endif
111
112
#endif
/* MIR_TOOLKIT_MIR_PROMPT_SESSION_H_ */
MirPromptSession
struct MirPromptSession MirPromptSession
Definition:
client_types.h:48
MirWaitHandle
struct MirWaitHandle MirWaitHandle
Returned by asynchronous functions.
Definition:
client_types.h:72
MirConnection
struct MirConnection MirConnection
Definition:
client_types.h:41
mir_prompt_session_is_valid
bool mir_prompt_session_is_valid(MirPromptSession *prompt_session)
Test for a valid prompt session.
MirClientFdCallback
void(* MirClientFdCallback)(MirPromptSession *prompt_session, size_t count, int const *fds, void *context)
Callback called when a request for client file descriptors completes.
Definition:
client_types.h:162
mir_prompt_session_error_message
char const * mir_prompt_session_error_message(MirPromptSession *prompt_session)
Retrieve a text description of the last error.
mir_prompt_session_new_fds_for_prompt_providers_sync
size_t mir_prompt_session_new_fds_for_prompt_providers_sync(MirPromptSession *prompt_session, unsigned int no_of_fds, int *fds)
Allocate some FDs for prompt providers to connect on.
mir_client_library.h
MirPromptSessionStateChangeCallback
void(* MirPromptSessionStateChangeCallback)(MirPromptSession *prompt_provider, MirPromptSessionState state, void *context)
Callback member of MirPromptSession for handling of prompt sessions events.
Definition:
client_types.h:450
mir_connection_create_prompt_session_sync
MirPromptSession * mir_connection_create_prompt_session_sync(MirConnection *connection, pid_t application_pid, MirPromptSessionStateChangeCallback state_change_callback, void *context)
Create and start a new prompt session.
mir_prompt_session_new_fds_for_prompt_providers
MirWaitHandle * mir_prompt_session_new_fds_for_prompt_providers(MirPromptSession *prompt_session, unsigned int no_of_fds, MirClientFdCallback callback, void *context)
Allocate some FDs for prompt providers to connect on.
mir_prompt_session_release_sync
void mir_prompt_session_release_sync(MirPromptSession *prompt_session)
Stop and release the specified prompt session.
Copyright © 2012-2016 Canonical Ltd.
Generated on Mon Jun 5 11:05:03 UTC 2017