a4be58f76933b9aeab415d64edc6de1d689d410c
[staging/HomeScreen.git] / interfaces / windowmanager.xml
1 <!DOCTYPE node PUBLIC "-//freedesktop//DTD D-BUS Object Introspection 1.0//EN" "http://www.freedesktop.org/standards/dbus/1.0/introspect.dtd">
2 <!-- Copyright (C) 2016 Mentor Graphics Development (Deutschland) GmbH
3
4  Licensed under the Apache License, Version 2.0 (the "License");
5  you may not use this file except in compliance with the License.
6  You may obtain a copy of the License at
7
8       http://www.apache.org/licenses/LICENSE-2.0
9
10  Unless required by applicable law or agreed to in writing, software
11  distributed under the License is distributed on an "AS IS" BASIS,
12  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13  See the License for the specific language governing permissions and
14  limitations under the License. -->
15 <node>
16         <!--
17           org.agl.windowmanager:
18           @short_description: A Layout-based interface for the WindowManager.
19
20           A Layout defines a list of surfaces areas.
21         -->
22         <interface name="org.agl.windowmanager">
23                 <!--
24                   addLayout:
25                   @layoutId: A unique ID that represents this layout. If the ID is already in use WINDOWMANAGER_ERROR_ID_ALREADY_DEFINED will be returned.
26                   @layoutName: A user readable string for the layout. If the string is already in use WINDOWMANAGER_ERROR_NAME_ALREADY_DEFINED will be returned.
27                   @surfaceAreas: A list of surface areas.
28                   @error: WINDOWMANAGER_NO_ERROR or the first error that occurred.
29
30                   Add a layout definition to the WindowManayer layout database.
31                   The layout database is temoprary and not stored persistently. It has to be recreated by the client after
32                   a WindowManager restart.
33                 -->
34                 <method name="addLayout">
35                         <arg name="layoutId" type="i" direction="in"/>
36                         <arg name="layoutName" type="s" direction="in"/>
37                         <arg name="surfaceAreas" type="a(iiii)" direction="in"/>
38                         <annotation name="org.qtproject.QtDBus.QtTypeName.In2" value="QList&lt;LayoutArea&gt;"/>
39                         <arg name="error" type="i" direction="out"/>
40                 </method>
41
42                 <!--
43                   deleteLayoutById:
44                   @layoutId: The ID of the layout to delete.
45                   @error: WINDOWMANAGER_NO_ERROR or the first error that occurred.
46
47                   Deletes the layout with the given ID. This cannot be the current active layout!
48                 -->
49                 <method name="deleteLayoutById">
50                         <arg name="layoutId" type="i" direction="in"/>
51                         <arg name="error" type="i" direction="out"/>
52                 </method>
53
54                 <!--
55                   setLayoutById:
56                   @layoutId: The ID of the layout to activate.
57                   @error: WINDOWMANAGER_NO_ERROR or the first error that occurred.
58
59                   Switch to the layout with the given ID.
60                 -->
61                 <method name="setLayoutById">
62                         <arg name="layoutId" type="i" direction="in"/>
63                         <arg name="error" type="i" direction="out"/>
64                 </method>
65                 <!--
66                   setLayoutByName:
67                   @layoutName: The name of the layout to activate.
68                   @error: WINDOWMANAGER_NO_ERROR or the first error that occurred.
69
70                   Switch to the layout with the given name.
71                 -->
72                 <method name="setLayoutByName">
73                         <arg name="layoutName" type="s" direction="in"/>
74                         <arg name="error" type="i" direction="out"/>
75                 </method>
76
77                 <!--
78                   getLayoutName:
79                   @layoutId: The ID of the requested layout name.
80                   @layoutName: The name of the layout with the given ID.
81
82                   Request the name of the layout with the given ID. This does not set or activate a layout.
83                   It is just returning the name of the given layout.
84                 -->
85                 <method name="getLayoutName">
86                         <arg name="layoutId" type="i" direction="in"/>
87                         <arg name="layoutName" type="s" direction="out"/>
88                 </method>
89
90                 <!--
91                   layout:
92                   The current active layout with all its information.
93                 -->
94                 <property>
95                         <arg name="layout" type="(isa(iiii))" access="read"/>
96                         <annotation name="org.qtproject.QtDBus.QtTypeName" value="Layout"/>
97                 </property>
98                 <!--
99                   layoutId:
100                   The current active layout id. This property is redundant, since its info is already available
101                   in the property layout. But this property is more lightweight.
102                 -->
103                 <property name="layoutId" type="i" access="read"/>
104                 <!--
105                   layoutName:
106                   The name of the current active layout. This property is redundant, since its info is already available
107                   in the property layout. But this property is more lightweight.
108                 -->
109                 <property name="layoutName" type="s" access="read"/>
110
111                 <!--
112                   getAllLayouts:
113                   @layouts: A list of all layouts.
114
115                   Returns a list of all layouts that were added to the WindowManager.
116                 -->
117                 <method name="getAllLayouts">
118                         <arg name="layoutIds" type="a(isa(iiii))" direction="out"/>
119                         <annotation name="org.qtproject.QtDBus.QtTypeName.Out0" value="QList&lt;Layout&gt;"/>
120                 </method>
121
122                 <!--
123                   getAvailableLayouts:
124                   @numberOfAppSurfaces: The ID of the requested layout name.
125                   @layoutIds: A list of layouts that offer the exact requested ammount of surface render areas.
126
127                   Returns a list of layouts that offer the exact requested ammount of surface render areas.
128                   If the list is empty, no layout fits the exact ammount.
129                 -->
130                 <method name="getAvailableLayouts">
131                         <arg name="numberOfAppSurfaces" type="i" direction="in"/>
132                         <arg name="layoutIds" type="ai" direction="out"/>
133                         <annotation name="org.qtproject.QtDBus.QtTypeName.Out0" value="QList&lt;int&gt;"/>
134                 </method>
135
136                 <!--
137                   getAllSurfacesOfProcess:
138                   @pid: The PID of the process.
139                   @surfaceIds: A list of surfaces that were created by the process.
140
141                   The surface IDs can be used to assign them to a layout render area.
142                 -->
143                 <method name="getAllSurfacesOfProcess">
144                         <arg name="pid" type="i" direction="in"/>
145                         <arg name="layoutIds" type="ai" direction="out"/>
146                         <annotation name="org.qtproject.QtDBus.QtTypeName.Out0" value="QList&lt;int&gt;"/>
147                 </method>
148
149                 <!--
150                   setSurfaceToLayoutArea:
151                   @surfaceId: The ID of the surface that shall be positioned.
152                   @layoutAreaId: The ID of the layout area where the surface shall be rendered.
153                   @error: WINDOWMANAGER_NO_ERROR or the first error that occurred.
154
155                   The surface will be scaled to the size of the layout area.
156                   The surface will be made visible with this call.
157                 -->
158                 <method name="setSurfaceToLayoutArea">
159                         <arg name="surfaceId" type="i" direction="in"/>
160                         <arg name="layoutAreaId" type="i" direction="in"/>
161                         <arg name="error" type="i" direction="out"/>
162                 </method>
163
164                 <!--
165                   getAvailableSurfaces:
166                   @surfaceIds: A list of all known surfaceIds except for the surfaces created by the Home Screen app.
167
168                   If no surfaces are available, the returned list is empty.
169                 -->
170                 <method name="getAvailableSurfaces">
171                         <arg name="surfaceIds" type="a(i)" direction="out"/>
172                         <annotation name="org.qtproject.QtDBus.QtTypeName.Out0" value="QList&lt;int&gt;"/> 
173                 </method>
174
175                 <!--
176                   showLayer:
177                   @layer: The ID of the layer to show. POPUP=0, APPS=1, HOMESCREEN=2
178
179                   Show complete layers.
180                   By default, all layers are shown.
181                 -->
182                 <method name="showLayer">
183                         <arg name="layer" type="i" direction="in"/>
184                 </method>
185                 <!--
186                   hideLayer:
187                   @layer: The ID of the layer to hide. POPUP=0, APPS=1, HOMESCREEN=2
188
189                   Hide complete layers.
190                   By default, all layers are shown.
191                 -->
192                 <method name="hideLayer">
193                         <arg name="layer" type="i" direction="in"/>
194                 </method>
195         </interface>
196 </node>
197