EGLWLMockNavigation: update for wayland version 1.0.0
[profile/ivi/layer-management.git] / LayerManagerExamples / EGLWLMockNavigation / src / WaylandServerinfoProtocol.cpp
1 /***************************************************************************
2 *
3 * Copyright (C) 2011 DENSO CORPORATION and Robert Bosch Car Multimedia Gmbh
4 *
5 *
6 * Licensed under the Apache License, Version 2.0 (the "License");
7 * you may not use this file except in compliance with the License.
8 * You may obtain a copy of the License at
9 *
10 *        http://www.apache.org/licenses/LICENSE-2.0
11 *
12 * Unless required by applicable law or agreed to in writing, software
13 * distributed under the License is distributed on an "AS IS" BASIS,
14 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
15 * See the License for the specific language governing permissions and
16 * limitations under the License.
17 *
18 *
19 * THE COPYRIGHT HOLDERS DISCLAIM ALL WARRANTIES WITH REGARD TO THIS
20 * SOFTWARE, INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND
21 * FITNESS, IN NO EVENT SHALL THE COPYRIGHT HOLDERS BE LIABLE FOR ANY
22 * SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER
23 * RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF
24 * CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN
25 * CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
26 *
27 ****************************************************************************/
28
29 #include <stdlib.h>
30 #include <stdint.h>
31 #include "wayland-util.h"
32
33 #define ARRAY_LENGTH(a) (sizeof (a) / sizeof (a)[0])
34
35 static const struct wl_interface *types[] = {
36         NULL,
37 };
38
39 static const struct wl_message serverinfo_requests[] = {
40         { "get_connection_id", "", types + 0 },
41 };
42
43 static const struct wl_message serverinfo_events[] = {
44         { "connection_id", "u", types + 0 },
45 };
46
47 extern "C" WL_EXPORT const struct wl_interface serverinfo_interface = {
48         "serverinfo", 1,
49         ARRAY_LENGTH(serverinfo_requests), serverinfo_requests,
50         ARRAY_LENGTH(serverinfo_events), serverinfo_events,
51 };
52