# Merge lp:~mir-team/mir/1.0-artful into lp:mir/ubuntu

Proposed by Alan Griffiths on 2017-10-08
Reviewer Review Type Date Requested Status
Gerry Boland (community) 2017-10-08 Approve on 2017-10-10
Mir CI Bot continuous-integration 2017-10-08 Approve on 2017-10-08

### Commit message

Mir 0.28 release to artful

 Gerry Boland (gerboland) wrote on 2017-10-10: #

To be noted that this causes the miral-examples package to be deprecated and removed by mir-demos. A dist-upgrade is needed to do this. But all packages installed/upgraded ok.

It is a large diff, but it mainly consists of 2 changes:
1. adding MirAL from lp:miral to Mir itself, and adapting the tests to suit
2. relicencing changes, which touch every file
MirAL's inter-operability with Mir has long been good quality, and in my testing of lp:mir this hasn't changed.

I've run through the testing plan, found no new issues

review: Approve

## Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
 1 === modified file '.bzrignore' 2 --- .bzrignore 2017-05-08 03:04:26 +0000 3 +++ .bzrignore 2017-10-11 15:01:23 +0000 4 @@ -2,4 +2,6 @@ 5 .project 6 include/server/mir/version.h 7 include/client/mir_toolkit/version.h 8 +include/miral/version.h 9 build-* 10 +cmake-* 11 12 === modified file 'CMakeLists.txt' 13 --- CMakeLists.txt 2017-05-25 08:58:03 +0000 14 +++ CMakeLists.txt 2017-10-11 15:01:23 +0000 15 @@ -1,7 +1,7 @@ 16 # Copyright © 2012 Canonical Ltd. 17 # 18 # This program is free software: you can redistribute it and/or modify 19 -# it under the terms of the GNU General Public License version 3 as 20 +# it under the terms of the GNU General Public License version 2 or 3 as 21 # published by the Free Software Foundation. 22 # 23 # This program is distributed in the hope that it will be useful, 24 @@ -28,7 +28,7 @@ 25 set(CMAKE_LIBRARY_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/lib) 26 27 set(MIR_VERSION_MAJOR 0) 28 -set(MIR_VERSION_MINOR 27) 29 +set(MIR_VERSION_MINOR 28) 30 set(MIR_VERSION_PATCH 0) 31 32 add_definitions(-DMIR_VERSION_MAJOR=${MIR_VERSION_MAJOR}) 33 @@ -53,6 +53,7 @@ 34 include (cmake/EnableCoverageReport.cmake) 35 include (cmake/MirCommon.cmake) 36 include (GNUInstallDirs) 37 +include (cmake/Doxygen.cmake) 38 39 set(build_types "None;Debug;Release;RelWithDebInfo;MinSizeRel;Coverage;AddressSanitizer;ThreadSanitizer;UBSanitizer") 40 # Change informational string for CMAKE_BUILD_TYPE 41 @@ -73,6 +74,16 @@ 42 set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wno-mismatched-tags") 43 endif() 44 45 +# GCC 7.1 fixed a bug in the ARM ABI, which results in some std::vector methods 46 +# (among others) generating this warning. 47 +# 48 +# There's nothing we can do about it; everything just needs to be rebuilt with 49 +# GCC 7.1. 50 +check_cxx_compiler_flag(-Wpsabi HAS_W_PSABI) 51 +if(HAS_W_PSABI) 52 + set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wno-psabi") 53 +endif() 54 + 55 option(MIR_USE_LD_GOLD "Enables the \"gold\" linker." OFF) 56 if(MIR_USE_LD_GOLD) 57 set (CMAKE_SHARED_LINKER_FLAGS "${CMAKE_SHARED_LINKER_FLAGS} -fuse-ld=gold") 58 @@ -81,8 +92,6 @@ 59 endif() 60 61 # Link time optimization allows leaner, cleaner libraries 62 -message(STATUS "CMAKE_C_COMPILER: "${CMAKE_C_COMPILER}) 63 - 64 option(MIR_LINK_TIME_OPTIMIZATION "Enables the linker to optimize binaries." OFF) 65 if(MIR_LINK_TIME_OPTIMIZATION) 66 set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -flto -ffat-lto-objects") 67 @@ -207,6 +216,8 @@ 68 69 pkg_check_modules(UDEV REQUIRED libudev) 70 pkg_check_modules(GLIB REQUIRED glib-2.0) 71 +pkg_check_modules(WAYLAND_SERVER REQUIRED wayland-server) 72 +pkg_check_modules(WAYLAND_CLIENT REQUIRED wayland-client) 73 74 include_directories (SYSTEM${GLESv2_INCLUDE_DIRS}) 75 include_directories (SYSTEM ${EGL_INCLUDE_DIRS}) 76 @@ -291,7 +302,7 @@ 77 78 # There's no nice way to format this. Thanks CMake. 79 mir_add_test(NAME LGPL-required 80 - COMMAND /bin/sh -c "! grep -rl 'GNU General'${PROJECT_SOURCE_DIR}/src/client ${PROJECT_SOURCE_DIR}/include/client${PROJECT_SOURCE_DIR}/src/common ${PROJECT_SOURCE_DIR}/include/common${PROJECT_SOURCE_DIR}/src/include/common ${PROJECT_SOURCE_DIR}/src/platform${PROJECT_SOURCE_DIR}/include/platform ${PROJECT_SOURCE_DIR}/src/include/platform${PROJECT_SOURCE_DIR}/src/capnproto" 81 + COMMAND /bin/sh -c "! grep -rl 'GNU General' ${PROJECT_SOURCE_DIR}/src/client${PROJECT_SOURCE_DIR}/include/client ${PROJECT_SOURCE_DIR}/src/core${PROJECT_SOURCE_DIR}/include/core ${PROJECT_SOURCE_DIR}/src/common${PROJECT_SOURCE_DIR}/include/common ${PROJECT_SOURCE_DIR}/src/include/common${PROJECT_SOURCE_DIR}/src/platform ${PROJECT_SOURCE_DIR}/include/platform${PROJECT_SOURCE_DIR}/src/include/platform ${PROJECT_SOURCE_DIR}/src/platforms${PROJECT_SOURCE_DIR}/include/platforms ${PROJECT_SOURCE_DIR}/src/include/platforms${PROJECT_SOURCE_DIR}/src/renderers ${PROJECT_SOURCE_DIR}/include/renderers${PROJECT_SOURCE_DIR}/src/include/renderers ${PROJECT_SOURCE_DIR}/src/capnproto" 82 ) 83 mir_add_test(NAME GPL-required 84 COMMAND /bin/sh -c "! grep -rl 'GNU Lesser'${PROJECT_SOURCE_DIR}/src/server ${PROJECT_SOURCE_DIR}/include/server${PROJECT_SOURCE_DIR}/src/include/server ${PROJECT_SOURCE_DIR}/tests${PROJECT_SOURCE_DIR}/examples" 85 @@ -302,7 +313,6 @@ 86 endif () 87 88 enable_coverage_report(mirserver) 89 -include (cmake/Doxygen.cmake) 90 include (cmake/ABICheck.cmake) 91 92 add_custom_target(ptest 93 94 === added file 'COPYING.GPL2' 95 --- COPYING.GPL2 1970-01-01 00:00:00 +0000 96 +++ COPYING.GPL2 2017-10-11 15:01:23 +0000 97 @@ -0,0 +1,339 @@ 98 + GNU GENERAL PUBLIC LICENSE 99 + Version 2, June 1991 100 + 101 + Copyright (C) 1989, 1991 Free Software Foundation, Inc., 102 + 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA 103 + Everyone is permitted to copy and distribute verbatim copies 104 + of this license document, but changing it is not allowed. 105 + 106 + Preamble 107 + 108 + The licenses for most software are designed to take away your 109 +freedom to share and change it. By contrast, the GNU General Public 110 +License is intended to guarantee your freedom to share and change free 111 +software--to make sure the software is free for all its users. This 112 +General Public License applies to most of the Free Software 113 +Foundation's software and to any other program whose authors commit to 114 +using it. (Some other Free Software Foundation software is covered by 115 +the GNU Lesser General Public License instead.) You can apply it to 116 +your programs, too. 117 + 118 + When we speak of free software, we are referring to freedom, not 119 +price. Our General Public Licenses are designed to make sure that you 120 +have the freedom to distribute copies of free software (and charge for 121 +this service if you wish), that you receive source code or can get it 122 +if you want it, that you can change the software or use pieces of it 123 +in new free programs; and that you know you can do these things. 124 + 125 + To protect your rights, we need to make restrictions that forbid 126 +anyone to deny you these rights or to ask you to surrender the rights. 127 +These restrictions translate to certain responsibilities for you if you 128 +distribute copies of the software, or if you modify it. 129 + 130 + For example, if you distribute copies of such a program, whether 131 +gratis or for a fee, you must give the recipients all the rights that 132 +you have. You must make sure that they, too, receive or can get the 133 +source code. And you must show them these terms so they know their 134 +rights. 135 + 136 + We protect your rights with two steps: (1) copyright the software, and 137 +(2) offer you this license which gives you legal permission to copy, 138 +distribute and/or modify the software. 139 + 140 + Also, for each author's protection and ours, we want to make certain 141 +that everyone understands that there is no warranty for this free 142 +software. If the software is modified by someone else and passed on, we 143 +want its recipients to know that what they have is not the original, so 144 +that any problems introduced by others will not reflect on the original 145 +authors' reputations. 146 + 147 + Finally, any free program is threatened constantly by software 148 +patents. We wish to avoid the danger that redistributors of a free 149 +program will individually obtain patent licenses, in effect making the 150 +program proprietary. To prevent this, we have made it clear that any 151 +patent must be licensed for everyone's free use or not licensed at all. 152 + 153 + The precise terms and conditions for copying, distribution and 154 +modification follow. 155 + 156 + GNU GENERAL PUBLIC LICENSE 157 + TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION 158 + 159 + 0. This License applies to any program or other work which contains 160 +a notice placed by the copyright holder saying it may be distributed 161 +under the terms of this General Public License. The "Program", below, 162 +refers to any such program or work, and a "work based on the Program" 163 +means either the Program or any derivative work under copyright law: 164 +that is to say, a work containing the Program or a portion of it, 165 +either verbatim or with modifications and/or translated into another 166 +language. (Hereinafter, translation is included without limitation in 167 +the term "modification".) Each licensee is addressed as "you". 168 + 169 +Activities other than copying, distribution and modification are not 170 +covered by this License; they are outside its scope. The act of 171 +running the Program is not restricted, and the output from the Program 172 +is covered only if its contents constitute a work based on the 173 +Program (independent of having been made by running the Program). 174 +Whether that is true depends on what the Program does. 175 + 176 + 1. You may copy and distribute verbatim copies of the Program's 177 +source code as you receive it, in any medium, provided that you 178 +conspicuously and appropriately publish on each copy an appropriate 179 +copyright notice and disclaimer of warranty; keep intact all the 180 +notices that refer to this License and to the absence of any warranty; 181 +and give any other recipients of the Program a copy of this License 182 +along with the Program. 183 + 184 +You may charge a fee for the physical act of transferring a copy, and 185 +you may at your option offer warranty protection in exchange for a fee. 186 + 187 + 2. You may modify your copy or copies of the Program or any portion 188 +of it, thus forming a work based on the Program, and copy and 189 +distribute such modifications or work under the terms of Section 1 190 +above, provided that you also meet all of these conditions: 191 + 192 + a) You must cause the modified files to carry prominent notices 193 + stating that you changed the files and the date of any change. 194 + 195 + b) You must cause any work that you distribute or publish, that in 196 + whole or in part contains or is derived from the Program or any 197 + part thereof, to be licensed as a whole at no charge to all third 198 + parties under the terms of this License. 199 + 200 + c) If the modified program normally reads commands interactively 201 + when run, you must cause it, when started running for such 202 + interactive use in the most ordinary way, to print or display an 203 + announcement including an appropriate copyright notice and a 204 + notice that there is no warranty (or else, saying that you provide 205 + a warranty) and that users may redistribute the program under 206 + these conditions, and telling the user how to view a copy of this 207 + License. (Exception: if the Program itself is interactive but 208 + does not normally print such an announcement, your work based on 209 + the Program is not required to print an announcement.) 210 + 211 +These requirements apply to the modified work as a whole. If 212 +identifiable sections of that work are not derived from the Program, 213 +and can be reasonably considered independent and separate works in 214 +themselves, then this License, and its terms, do not apply to those 215 +sections when you distribute them as separate works. But when you 216 +distribute the same sections as part of a whole which is a work based 217 +on the Program, the distribution of the whole must be on the terms of 218 +this License, whose permissions for other licensees extend to the 219 +entire whole, and thus to each and every part regardless of who wrote it. 220 + 221 +Thus, it is not the intent of this section to claim rights or contest 222 +your rights to work written entirely by you; rather, the intent is to 223 +exercise the right to control the distribution of derivative or 224 +collective works based on the Program. 225 + 226 +In addition, mere aggregation of another work not based on the Program 227 +with the Program (or with a work based on the Program) on a volume of 228 +a storage or distribution medium does not bring the other work under 229 +the scope of this License. 230 + 231 + 3. You may copy and distribute the Program (or a work based on it, 232 +under Section 2) in object code or executable form under the terms of 233 +Sections 1 and 2 above provided that you also do one of the following: 234 + 235 + a) Accompany it with the complete corresponding machine-readable 236 + source code, which must be distributed under the terms of Sections 237 + 1 and 2 above on a medium customarily used for software interchange; or, 238 + 239 + b) Accompany it with a written offer, valid for at least three 240 + years, to give any third party, for a charge no more than your 241 + cost of physically performing source distribution, a complete 242 + machine-readable copy of the corresponding source code, to be 243 + distributed under the terms of Sections 1 and 2 above on a medium 244 + customarily used for software interchange; or, 245 + 246 + c) Accompany it with the information you received as to the offer 247 + to distribute corresponding source code. (This alternative is 248 + allowed only for noncommercial distribution and only if you 249 + received the program in object code or executable form with such 250 + an offer, in accord with Subsection b above.) 251 + 252 +The source code for a work means the preferred form of the work for 253 +making modifications to it. For an executable work, complete source 254 +code means all the source code for all modules it contains, plus any 255 +associated interface definition files, plus the scripts used to 256 +control compilation and installation of the executable. However, as a 257 +special exception, the source code distributed need not include 258 +anything that is normally distributed (in either source or binary 259 +form) with the major components (compiler, kernel, and so on) of the 260 +operating system on which the executable runs, unless that component 261 +itself accompanies the executable. 262 + 263 +If distribution of executable or object code is made by offering 264 +access to copy from a designated place, then offering equivalent 265 +access to copy the source code from the same place counts as 266 +distribution of the source code, even though third parties are not 267 +compelled to copy the source along with the object code. 268 + 269 + 4. You may not copy, modify, sublicense, or distribute the Program 270 +except as expressly provided under this License. Any attempt 271 +otherwise to copy, modify, sublicense or distribute the Program is 272 +void, and will automatically terminate your rights under this License. 273 +However, parties who have received copies, or rights, from you under 274 +this License will not have their licenses terminated so long as such 275 +parties remain in full compliance. 276 + 277 + 5. You are not required to accept this License, since you have not 278 +signed it. However, nothing else grants you permission to modify or 279 +distribute the Program or its derivative works. These actions are 280 +prohibited by law if you do not accept this License. Therefore, by 281 +modifying or distributing the Program (or any work based on the 282 +Program), you indicate your acceptance of this License to do so, and 283 +all its terms and conditions for copying, distributing or modifying 284 +the Program or works based on it. 285 + 286 + 6. Each time you redistribute the Program (or any work based on the 287 +Program), the recipient automatically receives a license from the 288 +original licensor to copy, distribute or modify the Program subject to 289 +these terms and conditions. You may not impose any further 290 +restrictions on the recipients' exercise of the rights granted herein. 291 +You are not responsible for enforcing compliance by third parties to 292 +this License. 293 + 294 + 7. If, as a consequence of a court judgment or allegation of patent 295 +infringement or for any other reason (not limited to patent issues), 296 +conditions are imposed on you (whether by court order, agreement or 297 +otherwise) that contradict the conditions of this License, they do not 298 +excuse you from the conditions of this License. If you cannot 299 +distribute so as to satisfy simultaneously your obligations under this 300 +License and any other pertinent obligations, then as a consequence you 301 +may not distribute the Program at all. For example, if a patent 302 +license would not permit royalty-free redistribution of the Program by 303 +all those who receive copies directly or indirectly through you, then 304 +the only way you could satisfy both it and this License would be to 305 +refrain entirely from distribution of the Program. 306 + 307 +If any portion of this section is held invalid or unenforceable under 308 +any particular circumstance, the balance of the section is intended to 309 +apply and the section as a whole is intended to apply in other 310 +circumstances. 311 + 312 +It is not the purpose of this section to induce you to infringe any 313 +patents or other property right claims or to contest validity of any 314 +such claims; this section has the sole purpose of protecting the 315 +integrity of the free software distribution system, which is 316 +implemented by public license practices. Many people have made 317 +generous contributions to the wide range of software distributed 318 +through that system in reliance on consistent application of that 319 +system; it is up to the author/donor to decide if he or she is willing 320 +to distribute software through any other system and a licensee cannot 321 +impose that choice. 322 + 323 +This section is intended to make thoroughly clear what is believed to 324 +be a consequence of the rest of this License. 325 + 326 + 8. If the distribution and/or use of the Program is restricted in 327 +certain countries either by patents or by copyrighted interfaces, the 328 +original copyright holder who places the Program under this License 329 +may add an explicit geographical distribution limitation excluding 330 +those countries, so that distribution is permitted only in or among 331 +countries not thus excluded. In such case, this License incorporates 332 +the limitation as if written in the body of this License. 333 + 334 + 9. The Free Software Foundation may publish revised and/or new versions 335 +of the General Public License from time to time. Such new versions will 336 +be similar in spirit to the present version, but may differ in detail to 337 +address new problems or concerns. 338 + 339 +Each version is given a distinguishing version number. If the Program 340 +specifies a version number of this License which applies to it and "any 341 +later version", you have the option of following the terms and conditions 342 +either of that version or of any later version published by the Free 343 +Software Foundation. If the Program does not specify a version number of 344 +this License, you may choose any version ever published by the Free Software 345 +Foundation. 346 + 347 + 10. If you wish to incorporate parts of the Program into other free 348 +programs whose distribution conditions are different, write to the author 349 +to ask for permission. For software which is copyrighted by the Free 350 +Software Foundation, write to the Free Software Foundation; we sometimes 351 +make exceptions for this. Our decision will be guided by the two goals 352 +of preserving the free status of all derivatives of our free software and 353 +of promoting the sharing and reuse of software generally. 354 + 355 + NO WARRANTY 356 + 357 + 11. BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY 358 +FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN 359 +OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES 360 +PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED 361 +OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF 362 +MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS 363 +TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE 364 +PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING, 365 +REPAIR OR CORRECTION. 366 + 367 + 12. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING 368 +WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR 369 +REDISTRIBUTE THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, 370 +INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING 371 +OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED 372 +TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY 373 +YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER 374 +PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE 375 +POSSIBILITY OF SUCH DAMAGES. 376 + 377 + END OF TERMS AND CONDITIONS 378 + 379 + How to Apply These Terms to Your New Programs 380 + 381 + If you develop a new program, and you want it to be of the greatest 382 +possible use to the public, the best way to achieve this is to make it 383 +free software which everyone can redistribute and change under these terms. 384 + 385 + To do so, attach the following notices to the program. It is safest 386 +to attach them to the start of each source file to most effectively 387 +convey the exclusion of warranty; and each file should have at least 388 +the "copyright" line and a pointer to where the full notice is found. 389 + 390 + 391 + Copyright (C) 392 + 393 + This program is free software; you can redistribute it and/or modify 394 + it under the terms of the GNU General Public License as published by 395 + the Free Software Foundation; either version 2 of the License, or 396 + (at your option) any later version. 397 + 398 + This program is distributed in the hope that it will be useful, 399 + but WITHOUT ANY WARRANTY; without even the implied warranty of 400 + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 401 + GNU General Public License for more details. 402 + 403 + You should have received a copy of the GNU General Public License along 404 + with this program; if not, write to the Free Software Foundation, Inc., 405 + 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. 406 + 407 +Also add information on how to contact you by electronic and paper mail. 408 + 409 +If the program is interactive, make it output a short notice like this 410 +when it starts in an interactive mode: 411 + 412 + Gnomovision version 69, Copyright (C) year name of author 413 + Gnomovision comes with ABSOLUTELY NO WARRANTY; for details type show w'. 414 + This is free software, and you are welcome to redistribute it 415 + under certain conditions; type show c' for details. 416 + 417 +The hypothetical commands show w' and show c' should show the appropriate 418 +parts of the General Public License. Of course, the commands you use may 419 +be called something other than show w' and show c'; they could even be 420 +mouse-clicks or menu items--whatever suits your program. 421 + 422 +You should also get your employer (if you work as a programmer) or your 423 +school, if any, to sign a "copyright disclaimer" for the program, if 424 +necessary. Here is a sample; alter the names: 425 + 426 + Yoyodyne, Inc., hereby disclaims all copyright interest in the program 427 + Gnomovision' (which makes passes at compilers) written by James Hacker. 428 + 429 + , 1 April 1989 430 + Ty Coon, President of Vice 431 + 432 +This General Public License does not permit incorporating your program into 433 +proprietary programs. If your program is a subroutine library, you may 434 +consider it more useful to permit linking proprietary applications with the 435 +library. If this is what you want to do, use the GNU Lesser General 436 +Public License instead of this License. 437 438 === renamed file 'COPYING.GPL' => 'COPYING.GPL3' 439 === added file 'COPYING.LGPL2' 440 --- COPYING.LGPL2 1970-01-01 00:00:00 +0000 441 +++ COPYING.LGPL2 2017-10-11 15:01:23 +0000 442 @@ -0,0 +1,481 @@ 443 + GNU LIBRARY GENERAL PUBLIC LICENSE 444 + Version 2, June 1991 445 + 446 + Copyright (C) 1991 Free Software Foundation, Inc. 447 + 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA 448 + Everyone is permitted to copy and distribute verbatim copies 449 + of this license document, but changing it is not allowed. 450 + 451 +[This is the first released version of the library GPL. It is 452 + numbered 2 because it goes with version 2 of the ordinary GPL.] 453 + 454 + Preamble 455 + 456 + The licenses for most software are designed to take away your 457 +freedom to share and change it. By contrast, the GNU General Public 458 +Licenses are intended to guarantee your freedom to share and change 459 +free software--to make sure the software is free for all its users. 460 + 461 + This license, the Library General Public License, applies to some 462 +specially designated Free Software Foundation software, and to any 463 +other libraries whose authors decide to use it. You can use it for 464 +your libraries, too. 465 + 466 + When we speak of free software, we are referring to freedom, not 467 +price. Our General Public Licenses are designed to make sure that you 468 +have the freedom to distribute copies of free software (and charge for 469 +this service if you wish), that you receive source code or can get it 470 +if you want it, that you can change the software or use pieces of it 471 +in new free programs; and that you know you can do these things. 472 + 473 + To protect your rights, we need to make restrictions that forbid 474 +anyone to deny you these rights or to ask you to surrender the rights. 475 +These restrictions translate to certain responsibilities for you if 476 +you distribute copies of the library, or if you modify it. 477 + 478 + For example, if you distribute copies of the library, whether gratis 479 +or for a fee, you must give the recipients all the rights that we gave 480 +you. You must make sure that they, too, receive or can get the source 481 +code. If you link a program with the library, you must provide 482 +complete object files to the recipients so that they can relink them 483 +with the library, after making changes to the library and recompiling 484 +it. And you must show them these terms so they know their rights. 485 + 486 + Our method of protecting your rights has two steps: (1) copyright 487 +the library, and (2) offer you this license which gives you legal 488 +permission to copy, distribute and/or modify the library. 489 + 490 + Also, for each distributor's protection, we want to make certain 491 +that everyone understands that there is no warranty for this free 492 +library. If the library is modified by someone else and passed on, we 493 +want its recipients to know that what they have is not the original 494 +version, so that any problems introduced by others will not reflect on 495 +the original authors' reputations. 496 + 497 498 + Finally, any free program is threatened constantly by software 499 +patents. We wish to avoid the danger that companies distributing free 500 +software will individually obtain patent licenses, thus in effect 501 +transforming the program into proprietary software. To prevent this, 502 +we have made it clear that any patent must be licensed for everyone's 503 +free use or not licensed at all. 504 + 505 + Most GNU software, including some libraries, is covered by the ordinary 506 +GNU General Public License, which was designed for utility programs. This 507 +license, the GNU Library General Public License, applies to certain 508 +designated libraries. This license is quite different from the ordinary 509 +one; be sure to read it in full, and don't assume that anything in it is 510 +the same as in the ordinary license. 511 + 512 + The reason we have a separate public license for some libraries is that 513 +they blur the distinction we usually make between modifying or adding to a 514 +program and simply using it. Linking a program with a library, without 515 +changing the library, is in some sense simply using the library, and is 516 +analogous to running a utility program or application program. However, in 517 +a textual and legal sense, the linked executable is a combined work, a 518 +derivative of the original library, and the ordinary General Public License 519 +treats it as such. 520 + 521 + Because of this blurred distinction, using the ordinary General 522 +Public License for libraries did not effectively promote software 523 +sharing, because most developers did not use the libraries. We 524 +concluded that weaker conditions might promote sharing better. 525 + 526 + However, unrestricted linking of non-free programs would deprive the 527 +users of those programs of all benefit from the free status of the 528 +libraries themselves. This Library General Public License is intended to 529 +permit developers of non-free programs to use free libraries, while 530 +preserving your freedom as a user of such programs to change the free 531 +libraries that are incorporated in them. (We have not seen how to achieve 532 +this as regards changes in header files, but we have achieved it as regards 533 +changes in the actual functions of the Library.) The hope is that this 534 +will lead to faster development of free libraries. 535 + 536 + The precise terms and conditions for copying, distribution and 537 +modification follow. Pay close attention to the difference between a 538 +"work based on the library" and a "work that uses the library". The 539 +former contains code derived from the library, while the latter only 540 +works together with the library. 541 + 542 + Note that it is possible for a library to be covered by the ordinary 543 +General Public License rather than by this special one. 544 + 545 546 + GNU LIBRARY GENERAL PUBLIC LICENSE 547 + TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION 548 + 549 + 0. This License Agreement applies to any software library which 550 +contains a notice placed by the copyright holder or other authorized 551 +party saying it may be distributed under the terms of this Library 552 +General Public License (also called "this License"). Each licensee is 553 +addressed as "you". 554 + 555 + A "library" means a collection of software functions and/or data 556 +prepared so as to be conveniently linked with application programs 557 +(which use some of those functions and data) to form executables. 558 + 559 + The "Library", below, refers to any such software library or work 560 +which has been distributed under these terms. A "work based on the 561 +Library" means either the Library or any derivative work under 562 +copyright law: that is to say, a work containing the Library or a 563 +portion of it, either verbatim or with modifications and/or translated 564 +straightforwardly into another language. (Hereinafter, translation is 565 +included without limitation in the term "modification".) 566 + 567 + "Source code" for a work means the preferred form of the work for 568 +making modifications to it. For a library, complete source code means 569 +all the source code for all modules it contains, plus any associated 570 +interface definition files, plus the scripts used to control compilation 571 +and installation of the library. 572 + 573 + Activities other than copying, distribution and modification are not 574 +covered by this License; they are outside its scope. The act of 575 +running a program using the Library is not restricted, and output from 576 +such a program is covered only if its contents constitute a work based 577 +on the Library (independent of the use of the Library in a tool for 578 +writing it). Whether that is true depends on what the Library does 579 +and what the program that uses the Library does. 580 + 581 + 1. You may copy and distribute verbatim copies of the Library's 582 +complete source code as you receive it, in any medium, provided that 583 +you conspicuously and appropriately publish on each copy an 584 +appropriate copyright notice and disclaimer of warranty; keep intact 585 +all the notices that refer to this License and to the absence of any 586 +warranty; and distribute a copy of this License along with the 587 +Library. 588 + 589 + You may charge a fee for the physical act of transferring a copy, 590 +and you may at your option offer warranty protection in exchange for a 591 +fee. 592 + 593 594 + 2. You may modify your copy or copies of the Library or any portion 595 +of it, thus forming a work based on the Library, and copy and 596 +distribute such modifications or work under the terms of Section 1 597 +above, provided that you also meet all of these conditions: 598 + 599 + a) The modified work must itself be a software library. 600 + 601 + b) You must cause the files modified to carry prominent notices 602 + stating that you changed the files and the date of any change. 603 + 604 + c) You must cause the whole of the work to be licensed at no 605 + charge to all third parties under the terms of this License. 606 + 607 + d) If a facility in the modified Library refers to a function or a 608 + table of data to be supplied by an application program that uses 609 + the facility, other than as an argument passed when the facility 610 + is invoked, then you must make a good faith effort to ensure that, 611 + in the event an application does not supply such function or 612 + table, the facility still operates, and performs whatever part of 613 + its purpose remains meaningful. 614 + 615 + (For example, a function in a library to compute square roots has 616 + a purpose that is entirely well-defined independent of the 617 + application. Therefore, Subsection 2d requires that any 618 + application-supplied function or table used by this function must 619 + be optional: if the application does not supply it, the square 620 + root function must still compute square roots.) 621 + 622 +These requirements apply to the modified work as a whole. If 623 +identifiable sections of that work are not derived from the Library, 624 +and can be reasonably considered independent and separate works in 625 +themselves, then this License, and its terms, do not apply to those 626 +sections when you distribute them as separate works. But when you 627 +distribute the same sections as part of a whole which is a work based 628 +on the Library, the distribution of the whole must be on the terms of 629 +this License, whose permissions for other licensees extend to the 630 +entire whole, and thus to each and every part regardless of who wrote 631 +it. 632 + 633 +Thus, it is not the intent of this section to claim rights or contest 634 +your rights to work written entirely by you; rather, the intent is to 635 +exercise the right to control the distribution of derivative or 636 +collective works based on the Library. 637 + 638 +In addition, mere aggregation of another work not based on the Library 639 +with the Library (or with a work based on the Library) on a volume of 640 +a storage or distribution medium does not bring the other work under 641 +the scope of this License. 642 + 643 + 3. You may opt to apply the terms of the ordinary GNU General Public 644 +License instead of this License to a given copy of the Library. To do 645 +this, you must alter all the notices that refer to this License, so 646 +that they refer to the ordinary GNU General Public License, version 2, 647 +instead of to this License. (If a newer version than version 2 of the 648 +ordinary GNU General Public License has appeared, then you can specify 649 +that version instead if you wish.) Do not make any other change in 650 +these notices. 651 + 652 653 + Once this change is made in a given copy, it is irreversible for 654 +that copy, so the ordinary GNU General Public License applies to all 655 +subsequent copies and derivative works made from that copy. 656 + 657 + This option is useful when you wish to copy part of the code of 658 +the Library into a program that is not a library. 659 + 660 + 4. You may copy and distribute the Library (or a portion or 661 +derivative of it, under Section 2) in object code or executable form 662 +under the terms of Sections 1 and 2 above provided that you accompany 663 +it with the complete corresponding machine-readable source code, which 664 +must be distributed under the terms of Sections 1 and 2 above on a 665 +medium customarily used for software interchange. 666 + 667 + If distribution of object code is made by offering access to copy 668 +from a designated place, then offering equivalent access to copy the 669 +source code from the same place satisfies the requirement to 670 +distribute the source code, even though third parties are not 671 +compelled to copy the source along with the object code. 672 + 673 + 5. A program that contains no derivative of any portion of the 674 +Library, but is designed to work with the Library by being compiled or 675 +linked with it, is called a "work that uses the Library". Such a 676 +work, in isolation, is not a derivative work of the Library, and 677 +therefore falls outside the scope of this License. 678 + 679 + However, linking a "work that uses the Library" with the Library 680 +creates an executable that is a derivative of the Library (because it 681 +contains portions of the Library), rather than a "work that uses the 682 +library". The executable is therefore covered by this License. 683 +Section 6 states terms for distribution of such executables. 684 + 685 + When a "work that uses the Library" uses material from a header file 686 +that is part of the Library, the object code for the work may be a 687 +derivative work of the Library even though the source code is not. 688 +Whether this is true is especially significant if the work can be 689 +linked without the Library, or if the work is itself a library. The 690 +threshold for this to be true is not precisely defined by law. 691 + 692 + If such an object file uses only numerical parameters, data 693 +structure layouts and accessors, and small macros and small inline 694 +functions (ten lines or less in length), then the use of the object 695 +file is unrestricted, regardless of whether it is legally a derivative 696 +work. (Executables containing this object code plus portions of the 697 +Library will still fall under Section 6.) 698 + 699 + Otherwise, if the work is a derivative of the Library, you may 700 +distribute the object code for the work under the terms of Section 6. 701 +Any executables containing that work also fall under Section 6, 702 +whether or not they are linked directly with the Library itself. 703 + 704 705 + 6. As an exception to the Sections above, you may also compile or 706 +link a "work that uses the Library" with the Library to produce a 707 +work containing portions of the Library, and distribute that work 708 +under terms of your choice, provided that the terms permit 709 +modification of the work for the customer's own use and reverse 710 +engineering for debugging such modifications. 711 + 712 + You must give prominent notice with each copy of the work that the 713 +Library is used in it and that the Library and its use are covered by 714 +this License. You must supply a copy of this License. If the work 715 +during execution displays copyright notices, you must include the 716 +copyright notice for the Library among them, as well as a reference 717 +directing the user to the copy of this License. Also, you must do one 718 +of these things: 719 + 720 + a) Accompany the work with the complete corresponding 721 + machine-readable source code for the Library including whatever 722 + changes were used in the work (which must be distributed under 723 + Sections 1 and 2 above); and, if the work is an executable linked 724 + with the Library, with the complete machine-readable "work that 725 + uses the Library", as object code and/or source code, so that the 726 + user can modify the Library and then relink to produce a modified 727 + executable containing the modified Library. (It is understood 728 + that the user who changes the contents of definitions files in the 729 + Library will not necessarily be able to recompile the application 730 + to use the modified definitions.) 731 + 732 + b) Accompany the work with a written offer, valid for at 733 + least three years, to give the same user the materials 734 + specified in Subsection 6a, above, for a charge no more 735 + than the cost of performing this distribution. 736 + 737 + c) If distribution of the work is made by offering access to copy 738 + from a designated place, offer equivalent access to copy the above 739 + specified materials from the same place. 740 + 741 + d) Verify that the user has already received a copy of these 742 + materials or that you have already sent this user a copy. 743 + 744 + For an executable, the required form of the "work that uses the 745 +Library" must include any data and utility programs needed for 746 +reproducing the executable from it. However, as a special exception, 747 +the source code distributed need not include anything that is normally 748 +distributed (in either source or binary form) with the major 749 +components (compiler, kernel, and so on) of the operating system on 750 +which the executable runs, unless that component itself accompanies 751 +the executable. 752 + 753 + It may happen that this requirement contradicts the license 754 +restrictions of other proprietary libraries that do not normally 755 +accompany the operating system. Such a contradiction means you cannot 756 +use both them and the Library together in an executable that you 757 +distribute. 758 + 759 760 + 7. You may place library facilities that are a work based on the 761 +Library side-by-side in a single library together with other library 762 +facilities not covered by this License, and distribute such a combined 763 +library, provided that the separate distribution of the work based on 764 +the Library and of the other library facilities is otherwise 765 +permitted, and provided that you do these two things: 766 + 767 + a) Accompany the combined library with a copy of the same work 768 + based on the Library, uncombined with any other library 769 + facilities. This must be distributed under the terms of the 770 + Sections above. 771 + 772 + b) Give prominent notice with the combined library of the fact 773 + that part of it is a work based on the Library, and explaining 774 + where to find the accompanying uncombined form of the same work. 775 + 776 + 8. You may not copy, modify, sublicense, link with, or distribute 777 +the Library except as expressly provided under this License. Any 778 +attempt otherwise to copy, modify, sublicense, link with, or 779 +distribute the Library is void, and will automatically terminate your 780 +rights under this License. However, parties who have received copies, 781 +or rights, from you under this License will not have their licenses 782 +terminated so long as such parties remain in full compliance. 783 + 784 + 9. You are not required to accept this License, since you have not 785 +signed it. However, nothing else grants you permission to modify or 786 +distribute the Library or its derivative works. These actions are 787 +prohibited by law if you do not accept this License. Therefore, by 788 +modifying or distributing the Library (or any work based on the 789 +Library), you indicate your acceptance of this License to do so, and 790 +all its terms and conditions for copying, distributing or modifying 791 +the Library or works based on it. 792 + 793 + 10. Each time you redistribute the Library (or any work based on the 794 +Library), the recipient automatically receives a license from the 795 +original licensor to copy, distribute, link with or modify the Library 796 +subject to these terms and conditions. You may not impose any further 797 +restrictions on the recipients' exercise of the rights granted herein. 798 +You are not responsible for enforcing compliance by third parties to 799 +this License. 800 + 801 802 + 11. If, as a consequence of a court judgment or allegation of patent 803 +infringement or for any other reason (not limited to patent issues), 804 +conditions are imposed on you (whether by court order, agreement or 805 +otherwise) that contradict the conditions of this License, they do not 806 +excuse you from the conditions of this License. If you cannot 807 +distribute so as to satisfy simultaneously your obligations under this 808 +License and any other pertinent obligations, then as a consequence you 809 +may not distribute the Library at all. For example, if a patent 810 +license would not permit royalty-free redistribution of the Library by 811 +all those who receive copies directly or indirectly through you, then 812 +the only way you could satisfy both it and this License would be to 813 +refrain entirely from distribution of the Library. 814 + 815 +If any portion of this section is held invalid or unenforceable under any 816 +particular circumstance, the balance of the section is intended to apply, 817 +and the section as a whole is intended to apply in other circumstances. 818 + 819 +It is not the purpose of this section to induce you to infringe any 820 +patents or other property right claims or to contest validity of any 821 +such claims; this section has the sole purpose of protecting the 822 +integrity of the free software distribution system which is 823 +implemented by public license practices. Many people have made 824 +generous contributions to the wide range of software distributed 825 +through that system in reliance on consistent application of that 826 +system; it is up to the author/donor to decide if he or she is willing 827 +to distribute software through any other system and a licensee cannot 828 +impose that choice. 829 + 830 +This section is intended to make thoroughly clear what is believed to 831 +be a consequence of the rest of this License. 832 + 833 + 12. If the distribution and/or use of the Library is restricted in 834 +certain countries either by patents or by copyrighted interfaces, the 835 +original copyright holder who places the Library under this License may add 836 +an explicit geographical distribution limitation excluding those countries, 837 +so that distribution is permitted only in or among countries not thus 838 +excluded. In such case, this License incorporates the limitation as if 839 +written in the body of this License. 840 + 841 + 13. The Free Software Foundation may publish revised and/or new 842 +versions of the Library General Public License from time to time. 843 +Such new versions will be similar in spirit to the present version, 844 +but may differ in detail to address new problems or concerns. 845 + 846 +Each version is given a distinguishing version number. If the Library 847 +specifies a version number of this License which applies to it and 848 +"any later version", you have the option of following the terms and 849 +conditions either of that version or of any later version published by 850 +the Free Software Foundation. If the Library does not specify a 851 +license version number, you may choose any version ever published by 852 +the Free Software Foundation. 853 + 854 855 + 14. If you wish to incorporate parts of the Library into other free 856 +programs whose distribution conditions are incompatible with these, 857 +write to the author to ask for permission. For software which is 858 +copyrighted by the Free Software Foundation, write to the Free 859 +Software Foundation; we sometimes make exceptions for this. Our 860 +decision will be guided by the two goals of preserving the free status 861 +of all derivatives of our free software and of promoting the sharing 862 +and reuse of software generally. 863 + 864 + NO WARRANTY 865 + 866 + 15. BECAUSE THE LIBRARY IS LICENSED FREE OF CHARGE, THERE IS NO 867 +WARRANTY FOR THE LIBRARY, TO THE EXTENT PERMITTED BY APPLICABLE LAW. 868 +EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR 869 +OTHER PARTIES PROVIDE THE LIBRARY "AS IS" WITHOUT WARRANTY OF ANY 870 +KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE 871 +IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR 872 +PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE 873 +LIBRARY IS WITH YOU. SHOULD THE LIBRARY PROVE DEFECTIVE, YOU ASSUME 874 +THE COST OF ALL NECESSARY SERVICING, REPAIR OR CORRECTION. 875 + 876 + 16. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN 877 +WRITING WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY 878 +AND/OR REDISTRIBUTE THE LIBRARY AS PERMITTED ABOVE, BE LIABLE TO YOU 879 +FOR DAMAGES, INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR 880 +CONSEQUENTIAL DAMAGES ARISING OUT OF THE USE OR INABILITY TO USE THE 881 +LIBRARY (INCLUDING BUT NOT LIMITED TO LOSS OF DATA OR DATA BEING 882 +RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD PARTIES OR A 883 +FAILURE OF THE LIBRARY TO OPERATE WITH ANY OTHER SOFTWARE), EVEN IF 884 +SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH 885 +DAMAGES. 886 + 887 + END OF TERMS AND CONDITIONS 888 + 889 890 + How to Apply These Terms to Your New Libraries 891 + 892 + If you develop a new library, and you want it to be of the greatest 893 +possible use to the public, we recommend making it free software that 894 +everyone can redistribute and change. You can do so by permitting 895 +redistribution under these terms (or, alternatively, under the terms of the 896 +ordinary General Public License). 897 + 898 + To apply these terms, attach the following notices to the library. It is 899 +safest to attach them to the start of each source file to most effectively 900 +convey the exclusion of warranty; and each file should have at least the 901 +"copyright" line and a pointer to where the full notice is found. 902 + 903 + 904 + Copyright (C) 905 + 906 + This library is free software; you can redistribute it and/or 907 + modify it under the terms of the GNU Library General Public 908 + License as published by the Free Software Foundation; either 909 + version 2 of the License, or (at your option) any later version. 910 + 911 + This library is distributed in the hope that it will be useful, 912 + but WITHOUT ANY WARRANTY; without even the implied warranty of 913 + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 914 + Library General Public License for more details. 915 + 916 + You should have received a copy of the GNU Library General Public 917 + License along with this library; if not, write to the Free Software 918 + Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA 919 + 920 +Also add information on how to contact you by electronic and paper mail. 921 + 922 +You should also get your employer (if you work as a programmer) or your 923 +school, if any, to sign a "copyright disclaimer" for the library, if 924 +necessary. Here is a sample; alter the names: 925 + 926 + Yoyodyne, Inc., hereby disclaims all copyright interest in the 927 + library Frob' (a library for tweaking knobs) written by James Random Hacker. 928 + 929 + , 1 April 1990 930 + Ty Coon, President of Vice 931 + 932 +That's all there is to it! 933 934 === renamed file 'COPYING.LGPL' => 'COPYING.LGPL3' 935 === modified file 'HACKING.md' 936 --- HACKING.md 2017-05-08 03:04:26 +0000 937 +++ HACKING.md 2017-10-11 15:01:23 +0000 938 @@ -1,38 +1,6 @@ 939 Mir hacking guide 940 ================= 941 942 -Getting Mir 943 ------------ 944 - 945 -If you're reading this file then you've probably solved this one. ;) 946 - 947 -However, for completeness Mir is a project on LaunchPad (https://launchpad.net/mir) 948 -to grab a copy use the command: 949 - 950 - $bzr branch lp:mir 951 - 952 - 953 -Getting dependencies 954 --------------------- 955 -To succesfully build Mir there are a few packages required: 956 - 957 -$ apt-get install devscripts equivs cmake 958 - $mk-build-deps --install --tool "apt-get -y" --build-dep debian/control 959 - 960 - 961 -Building Mir 962 ------------ 963 - 964 -Mir is built using cmake. There are other options, but here's one way to 965 -build the system: 966 - 967 -$ mkdir build 968 - $cd build 969 -$ cmake .. 970 - $make -j 8 971 -$ ctest 972 - 973 - 974 Coding Mir 975 ---------- 976 977 @@ -109,7 +77,7 @@ 978 you need to know to get it working, and also to prevent your existing X server 979 from dying at the same time. 980 981 - - \ref using_mir_on_pc 982 + - \ref getting_and_using_mir 983 984 You can configure Mir to provide runtime information helpful for debugging 985 by enabling component reports: 986 987 === modified file 'README.md' 988 --- README.md 2013-04-24 05:22:20 +0000 989 +++ README.md 2017-10-11 15:01:23 +0000 990 @@ -9,7 +9,7 @@ 991 License (server) 992 ------- 993 This program is free software: you can redistribute it and/or modify 994 -it under the terms of the GNU General Public License version 3 as 995 +it under the terms of the GNU General Public License version 2 or 3 as 996 published by the Free Software Foundation. 997 998 This program is distributed in the hope that it will be useful, 999 @@ -23,7 +23,7 @@ 1000 License (client) 1001 ------- 1002 This program is free software: you can redistribute it and/or modify 1003 -it under the terms of the GNU Lesser General Public License version 3 as 1004 +it under the terms of the GNU Lesser General Public License version 2 or 3 as 1005 published by the Free Software Foundation. 1006 1007 This program is distributed in the hope that it will be useful, 1008 1009 === modified file 'benchmarks/benchmark_multiplexing_dispatchable.cpp' 1010 --- benchmarks/benchmark_multiplexing_dispatchable.cpp 2015-06-17 05:20:42 +0000 1011 +++ benchmarks/benchmark_multiplexing_dispatchable.cpp 2017-10-11 15:01:23 +0000 1012 @@ -2,7 +2,7 @@ 1013 * Copyright © 2015 Canonical Ltd. 1014 * 1015 * This program is free software: you can redistribute it and/or modify 1016 - * it under the terms of the GNU General Public License version 3 as 1017 + * it under the terms of the GNU General Public License version 2 or 3 as 1018 * published by the Free Software Foundation. 1019 * 1020 * This program is distributed in the hope that it will be useful, 1021 1022 === modified file 'benchmarks/frame-uniformity/frame_uniformity_test.cpp' 1023 --- benchmarks/frame-uniformity/frame_uniformity_test.cpp 2014-10-22 19:27:20 +0000 1024 +++ benchmarks/frame-uniformity/frame_uniformity_test.cpp 2017-10-11 15:01:23 +0000 1025 @@ -2,7 +2,7 @@ 1026 * Copyright © 2014 Canonical Ltd. 1027 * 1028 * This program is free software: you can redistribute it and/or modify 1029 - * it under the terms of the GNU General Public License version 3 as 1030 + * it under the terms of the GNU General Public License version 2 or 3 as 1031 * published by the Free Software Foundation. 1032 * 1033 * This program is distributed in the hope that it will be useful, 1034 1035 === modified file 'benchmarks/frame-uniformity/frame_uniformity_test.h' 1036 --- benchmarks/frame-uniformity/frame_uniformity_test.h 2015-06-25 03:00:08 +0000 1037 +++ benchmarks/frame-uniformity/frame_uniformity_test.h 2017-10-11 15:01:23 +0000 1038 @@ -2,7 +2,7 @@ 1039 * Copyright © 2014 Canonical Ltd. 1040 * 1041 * This program is free software: you can redistribute it and/or modify 1042 - * it under the terms of the GNU General Public License version 3 as 1043 + * it under the terms of the GNU General Public License version 2 or 3 as 1044 * published by the Free Software Foundation. 1045 * 1046 * This program is distributed in the hope that it will be useful, 1047 1048 === modified file 'benchmarks/frame-uniformity/main.cpp' 1049 --- benchmarks/frame-uniformity/main.cpp 2015-04-28 07:54:10 +0000 1050 +++ benchmarks/frame-uniformity/main.cpp 2017-10-11 15:01:23 +0000 1051 @@ -2,7 +2,7 @@ 1052 * Copyright © 2014 Canonical Ltd. 1053 * 1054 * This program is free software: you can redistribute it and/or modify 1055 - * it under the terms of the GNU General Public License version 3 as 1056 + * it under the terms of the GNU General Public License version 2 or 3 as 1057 * published by the Free Software Foundation. 1058 * 1059 * This program is distributed in the hope that it will be useful, 1060 1061 === modified file 'benchmarks/frame-uniformity/touch_measuring_client.cpp' 1062 --- benchmarks/frame-uniformity/touch_measuring_client.cpp 2017-05-08 03:04:26 +0000 1063 +++ benchmarks/frame-uniformity/touch_measuring_client.cpp 2017-10-11 15:01:23 +0000 1064 @@ -2,7 +2,7 @@ 1065 * Copyright © 2014 Canonical Ltd. 1066 * 1067 * This program is free software: you can redistribute it and/or modify 1068 - * it under the terms of the GNU General Public License version 3 as 1069 + * it under the terms of the GNU General Public License version 2 or 3 as 1070 * published by the Free Software Foundation. 1071 * 1072 * This program is distributed in the hope that it will be useful, 1073 1074 === modified file 'benchmarks/frame-uniformity/touch_measuring_client.h' 1075 --- benchmarks/frame-uniformity/touch_measuring_client.h 2015-06-25 03:00:08 +0000 1076 +++ benchmarks/frame-uniformity/touch_measuring_client.h 2017-10-11 15:01:23 +0000 1077 @@ -2,7 +2,7 @@ 1078 * Copyright © 2014 Canonical Ltd. 1079 * 1080 * This program is free software: you can redistribute it and/or modify 1081 - * it under the terms of the GNU General Public License version 3 as 1082 + * it under the terms of the GNU General Public License version 2 or 3 as 1083 * published by the Free Software Foundation. 1084 * 1085 * This program is distributed in the hope that it will be useful, 1086 1087 === modified file 'benchmarks/frame-uniformity/touch_producing_server.cpp' 1088 --- benchmarks/frame-uniformity/touch_producing_server.cpp 2016-01-29 08:18:22 +0000 1089 +++ benchmarks/frame-uniformity/touch_producing_server.cpp 2017-10-11 15:01:23 +0000 1090 @@ -2,7 +2,7 @@ 1091 * Copyright © 2014 Canonical Ltd. 1092 * 1093 * This program is free software: you can redistribute it and/or modify 1094 - * it under the terms of the GNU General Public License version 3 as 1095 + * it under the terms of the GNU General Public License version 2 or 3 as 1096 * published by the Free Software Foundation. 1097 * 1098 * This program is distributed in the hope that it will be useful, 1099 1100 === modified file 'benchmarks/frame-uniformity/touch_producing_server.h' 1101 --- benchmarks/frame-uniformity/touch_producing_server.h 2016-01-29 08:18:22 +0000 1102 +++ benchmarks/frame-uniformity/touch_producing_server.h 2017-10-11 15:01:23 +0000 1103 @@ -2,7 +2,7 @@ 1104 * Copyright © 2014 Canonical Ltd. 1105 * 1106 * This program is free software: you can redistribute it and/or modify 1107 - * it under the terms of the GNU General Public License version 3 as 1108 + * it under the terms of the GNU General Public License version 2 or 3 as 1109 * published by the Free Software Foundation. 1110 * 1111 * This program is distributed in the hope that it will be useful, 1112 1113 === modified file 'benchmarks/frame-uniformity/touch_samples.cpp' 1114 --- benchmarks/frame-uniformity/touch_samples.cpp 2015-06-17 05:20:42 +0000 1115 +++ benchmarks/frame-uniformity/touch_samples.cpp 2017-10-11 15:01:23 +0000 1116 @@ -2,7 +2,7 @@ 1117 * Copyright © 2014 Canonical Ltd. 1118 * 1119 * This program is free software: you can redistribute it and/or modify 1120 - * it under the terms of the GNU General Public License version 3 as 1121 + * it under the terms of the GNU General Public License version 2 or 3 as 1122 * published by the Free Software Foundation. 1123 * 1124 * This program is distributed in the hope that it will be useful, 1125 1126 === modified file 'benchmarks/frame-uniformity/touch_samples.h' 1127 --- benchmarks/frame-uniformity/touch_samples.h 2014-10-22 14:08:51 +0000 1128 +++ benchmarks/frame-uniformity/touch_samples.h 2017-10-11 15:01:23 +0000 1129 @@ -2,7 +2,7 @@ 1130 * Copyright © 2014 Canonical Ltd. 1131 * 1132 * This program is free software: you can redistribute it and/or modify 1133 - * it under the terms of the GNU General Public License version 3 as 1134 + * it under the terms of the GNU General Public License version 2 or 3 as 1135 * published by the Free Software Foundation. 1136 * 1137 * This program is distributed in the hope that it will be useful, 1138 1139 === modified file 'benchmarks/frame-uniformity/vsync_simulating_graphics_platform.cpp' 1140 --- benchmarks/frame-uniformity/vsync_simulating_graphics_platform.cpp 2016-01-29 08:18:22 +0000 1141 +++ benchmarks/frame-uniformity/vsync_simulating_graphics_platform.cpp 2017-10-11 15:01:23 +0000 1142 @@ -2,7 +2,7 @@ 1143 * Copyright © 2014 Canonical Ltd. 1144 * 1145 * This program is free software: you can redistribute it and/or modify 1146 - * it under the terms of the GNU General Public License version 3 as 1147 + * it under the terms of the GNU General Public License version 2 or 3 as 1148 * published by the Free Software Foundation. 1149 * 1150 * This program is distributed in the hope that it will be useful, 1151 1152 === modified file 'benchmarks/frame-uniformity/vsync_simulating_graphics_platform.h' 1153 --- benchmarks/frame-uniformity/vsync_simulating_graphics_platform.h 2016-01-29 08:18:22 +0000 1154 +++ benchmarks/frame-uniformity/vsync_simulating_graphics_platform.h 2017-10-11 15:01:23 +0000 1155 @@ -2,7 +2,7 @@ 1156 * Copyright © 2014 Canonical Ltd. 1157 * 1158 * This program is free software: you can redistribute it and/or modify 1159 - * it under the terms of the GNU General Public License version 3 as 1160 + * it under the terms of the GNU General Public License version 2 or 3 as 1161 * published by the Free Software Foundation. 1162 * 1163 * This program is distributed in the hope that it will be useful, 1164 1165 === added file 'cmake/FindPIL.cmake' 1166 --- cmake/FindPIL.cmake 1970-01-01 00:00:00 +0000 1167 +++ cmake/FindPIL.cmake 2017-10-11 15:01:23 +0000 1168 @@ -0,0 +1,8 @@ 1169 +execute_process( 1170 + COMMAND python3 -c "from PIL import Image" 1171 + RESULT_VARIABLE HAVE_PIL 1172 +) 1173 + 1174 +if (NOT ${HAVE_PIL} EQUAL 0) 1175 + message(FATAL_ERROR "Python Imaging Library (PIL) not found") 1176 +endif() 1177 1178 === modified file 'cmake/MirCommon.cmake' 1179 --- cmake/MirCommon.cmake 2017-05-08 03:04:26 +0000 1180 +++ cmake/MirCommon.cmake 2017-10-11 15:01:23 +0000 1181 @@ -26,6 +26,7 @@ 1182 set(VALGRIND_CMD "${VALGRIND_EXECUTABLE}" "--error-exitcode=1" "--trace-children=yes") 1183 set(VALGRIND_CMD ${VALGRIND_CMD} "--leak-check=full" "--show-leak-kinds=definite" "--errors-for-leak-kinds=definite") 1184 set(VALGRIND_CMD${VALGRIND_CMD} "--track-fds=yes") 1185 + set(VALGRIND_CMD ${VALGRIND_CMD} "--track-origins=yes") 1186 set(VALGRIND_CMD${VALGRIND_CMD} "--num-callers=128") 1187 set(VALGRIND_CMD ${VALGRIND_CMD} "--suppressions=${CMAKE_SOURCE_DIR}/tools/valgrind_suppressions_generic") 1188 set(VALGRIND_CMD ${VALGRIND_CMD} "--suppressions=${CMAKE_SOURCE_DIR}/tools/valgrind_suppressions_glibc_2.23") 1189 1190 === modified file 'debian/changelog' 1191 --- debian/changelog 2017-06-30 12:00:38 +0000 1192 +++ debian/changelog 2017-10-11 15:01:23 +0000 1193 @@ -1,3 +1,61 @@ 1194 +mir (0.28.0-0ubuntu1) UNRELEASED; urgency=medium 1195 + 1196 + * New upstream release 0.28.0(https://launchpad.net/mir/+milestone/0.28.0) 1197 + - ABI summary: 1198 + . mirclient ABI unchanged at 9 1199 + . miral ABI introduced at 2 1200 + . mirserver ABI bumped to 45 1201 + . mircommon ABI unchanged at 7 1202 + . mirplatform ABI unchanged at 61 1203 + . mirprotobuf ABI unchanged at 3 1204 + . mirplatformgraphics ABI unchanged at 13 1205 + . mirclientplatform ABI unchanged at 5 1206 + . mirinputplatform ABI unchanged at 7 1207 + . mircore ABI unchanged at 1 1208 + - Enhancements: 1209 + . Update licences to (L)GPL3 or (L)GPL2. 1210 + . Initial support for Wayland clients 1211 + . [mir_demo_client_display_config] add orientation changing 1212 + . RPC: Don't require the server ACK client's buffer-release requests. 1213 + . Added libmirclientcpp to Mir source package 1214 + . Added libmiral to Mir source package 1215 + . Various small improvements to miral-shell example 1216 + . [libmiral, miral-shell] handle display reconfiguration better and allow 1217 + shells to customize maximized placements. 1218 + . Enable CommandLineOptions to be processed before server initialization 1219 + - Bugs fixed: 1220 + . Fix handling of invalid display configuration. (LP: #1643446) 1221 + . Move full responsibility for buffer IPC into frontend. (LP: #1395421) 1222 + . Don't destroy an IPC "closure" object when it may yet be used 1223 + (LP: #1672960) 1224 + . [mesa-kms] Respect display orientation when painting cursor. 1225 + (LP: #1610078) 1226 + . Respect cursor hotspot when hosted on Mir. (LP: #1705284) 1227 + . mcl::BufferVault: Fix lock inversion. 1228 + . Handle mir_event_type_close_window in examples (LP: #1706004), 1229 + (LP: #1705439) 1230 + . Drop BufferStream::suitable_for_cursor() 1231 + . Only notify resize events for valid surfaces (LP: #1643446) 1232 + . Don't leak DRM fds in platform-eglstream probe. 1233 + . Remove obsolete & broken example code. (LP: #1663130) 1234 + . Move buffer-release IPC to a dedicated IPC thread. (LP: #1395421) 1235 + . [NestedServerWithTwoDisplays] Look for the last of a series of 1236 + synthetic events to ensure that the queue is drained before the test 1237 + exits. (LP: #1709666) 1238 + . floating window manager allows resizing maximized windows (LP: #1704776) 1239 + . [miral-shell] doesn't work with breeze X cursor theme (LP: #1699084) 1240 + . [miral-shell] Don't allow splashscreen to be occluded (LP: #1705973) 1241 + . [miral-shell] Update maximized windows on display changes (LP: #1705695) 1242 + . Make racy DragAndDrop test reliable. (LP: #1704780) 1243 + . [libmiral] Define default window settings in one place and clamp the 1244 + actual values to avoid ldiv0. (LP: #1717061) 1245 + . [miral-kiosk] Apply fullscreen logic when hidden windows are restored. 1246 + (LP: #1717910) 1247 + . [mir-on-x11] Less annoying clipping of Mir-on-X11 window when it exceeds 1248 + display bounds. (LP: #1668599) 1249 + 1250 + -- Alan Griffiths Thu, 10 Aug 2017 11:54:30 +0000 1251 + 1252 mir (0.27.0+17.10.20170630-0ubuntu1) artful; urgency=medium 1253 1254 [ Daniel van Vugt ] 1255 1256 === modified file 'debian/control' 1257 --- debian/control 2017-06-28 16:02:35 +0000 1258 +++ debian/control 2017-10-11 15:01:23 +0000 1259 @@ -31,6 +31,7 @@ 1260 libudev-dev, 1261 libgtest-dev, 1262 google-mock (>= 1.6.0+svn437), 1263 + libxml++2.6-dev, 1264 # only enable valgrind once it's been tested to work on each architecture: 1265 valgrind [amd64 i386 armhf arm64], 1266 libglib2.0-dev, 1267 @@ -45,6 +46,8 @@ 1268 libcapnp-dev, 1269 capnproto, 1270 libepoxy-dev, 1271 + python3-pil:native, 1272 + linux-libc-dev, 1273 Standards-Version: 3.9.4 1274 Homepage: https://launchpad.net/mir 1275 # If you aren't a member of ~mir-team but need to upload packaging changes, 1276 @@ -67,7 +70,7 @@ 1277 1278 #TODO: Packaging infrastructure for better dependency generation, 1279 # ala pkg-xorg's xviddriver:Provides and ABI detection. 1280 -Package: libmirserver44 1281 +Package: libmirserver45 1282 Section: libs 1283 Architecture: linux-any 1284 Multi-Arch: same 1285 @@ -146,7 +149,7 @@ 1286 Architecture: linux-any 1287 Multi-Arch: same 1288 Pre-Depends: ${misc:Pre-Depends} 1289 -Depends: libmirserver44 (=${binary:Version}), 1290 +Depends: libmirserver45 (= ${binary:Version}), 1291 libmirplatform-dev (=${binary:Version}), 1292 libmircommon-dev (= ${binary:Version}), 1293 libglm-dev, 1294 @@ -195,6 +198,9 @@ 1295 Architecture: linux-any 1296 Multi-Arch: same 1297 Pre-Depends:${misc:Pre-Depends} 1298 +Breaks: libmirclientcpp-dev 1299 +Replaces: libmirclientcpp-dev 1300 +Provides: libmirclientcpp-dev (=1.5) 1301 Depends: libmirclient9 (= ${binary:Version}), 1302 libmircommon-dev (=${binary:Version}), 1303 libmircookie-dev (= ${binary:Version}), 1304 @@ -233,7 +239,7 @@ 1305 Multi-Arch: same 1306 Pre-Depends:${misc:Pre-Depends} 1307 Depends: libmirclient-debug-extension1 (= ${binary:Version}), 1308 -${misc:Depends}, 1309 + ${misc:Depends}, 1310${shlibs:Depends}, 1311 Description: Display server for Ubuntu - client debug interface headers 1312 Mir is a display server running on linux systems, with a focus on efficiency, 1313 @@ -254,9 +260,13 @@ 1314 1315 Package: mir-demos 1316 Architecture: linux-any 1317 +Breaks: miral-examples 1318 +Replaces: miral-examples 1319 +Provides: miral-examples (=1.5) 1320 Depends: ${misc:Depends}, 1321${shlibs:Depends}, 1322 -Recommends: fonts-liberation 1323 +Recommends: dmz-cursor-theme, 1324 + fonts-liberation 1325 Description: Display server for Ubuntu - demonstration programs 1326 Mir is a display server running on linux systems, with a focus on efficiency, 1327 robust operation and a well-defined driver model. 1328 @@ -477,3 +487,33 @@ 1329 . 1330 Contains header files that define the interfaces through which platforms and 1331 renderers access the functionality needed to render with GL. 1332 + 1333 +Package: libmiral2 1334 +Section: libs 1335 +Architecture: linux-any 1336 +Multi-Arch: same 1337 +Pre-Depends: ${misc:Pre-Depends} 1338 +Depends:${misc:Depends}, 1339 + ${shlibs:Depends}, 1340 +Description: Display server for Ubuntu - ABI preserving abstraction layer 1341 + MirAL provides an ABI-stable abstraction layer for Mir based shells, 1342 + insulating them from mirserver ABI breaks. 1343 + . 1344 + Contains the shared library containing MirAL abstraction layer. 1345 + 1346 +Package: libmiral-dev 1347 +Section: libdevel 1348 +Architecture: linux-any 1349 +Multi-Arch: same 1350 +Pre-Depends:${misc:Pre-Depends} 1351 +Depends: libmiral2 (= ${libmiral2:Version}), 1352 +#${source:Version} is technically incorrect, but Launchpad doesn't do BinNMUs 1353 +# so it's harmless. 1354 + libmirclient-dev (= ${source:Version}), 1355 +${misc:Depends}, 1356 +Description: Developer files for the Mir ABI-stable abstraction layer 1357 + MirAL provides an ABI-stable abstraction layer for Mir based shells, 1358 + insulating them from mirserver ABI breaks. 1359 + . 1360 + Contains header files required for development using the MirAL abstraction 1361 + layer. 1362 1363 === modified file 'debian/copyright' 1364 --- debian/copyright 2017-05-08 03:04:26 +0000 1365 +++ debian/copyright 2017-10-11 15:01:23 +0000 1366 @@ -1,11 +1,11 @@ 1367 Format: http://www.debian.org/doc/packaging-manuals/copyright-format/1.0/ 1368 Upstream-Name: Mir 1369 -Upstream-Contact: Thomas Voß 1370 +Upstream-Contact: Alan Griffiths 1371 Source: http://launchpad.net/mir 1372 1373 Files: * 1374 -Copyright: 2012-2013, Canonical Ltd. 1375 -License: GPL-3 1376 +Copyright: 2012-2017, Canonical Ltd. 1377 +License: GPL-3 or GPL-2 1378 This program is free software: you can redistribute it and/or modify 1379 it under the terms of the GNU General Public License version 3 as 1380 published by the Free Software Foundation. 1381 @@ -18,6 +18,31 @@ 1382 On Debian systems, the full text of the GNU General Public 1383 License version 3 can be found in the file 1384 /usr/share/common-licenses/GPL-3'. 1385 + . 1386 + On Debian systems, the full text of the GNU General Public 1387 + License version 2 can be found in the file 1388 + /usr/share/common-licenses/GPL-2'. 1389 + 1390 +Files: include/client/* include/common/* include/core/* include/platform/* include/platforms/* include/renderers/* 1391 + src/client/* src/common/* src/core/* src/platform/* src/platforms/* src/renderers/* 1392 +Copyright: 2012-2017, Canonical Ltd. 1393 +License: LGPL-3 or LGPL-2 1394 + This program is free software: you can redistribute it and/or modify 1395 + it under the terms of the GNU Lesser General Public License version 3 as 1396 + published by the Free Software Foundation. 1397 + . 1398 + This program is distributed in the hope that it will be useful, 1399 + but WITHOUT ANY WARRANTY; without even the implied warranty of 1400 + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 1401 + GNU Lesser General Public License for more details. 1402 + . 1403 + On Debian systems, the full text of the GNU Lesser General Public 1404 + License version 3 can be found in the file 1405 + /usr/share/common-licenses/LGPL-3'. 1406 + . 1407 + On Debian systems, the full text of the GNU Lesser General Public 1408 + License version 2 can be found in the file 1409 + /usr/share/common-licenses/LGPL-2'. 1410 1411 Files: include/test/mir_test/gmock_fixes.h: 1412 Copyright: 1413 @@ -49,20 +74,3 @@ 1414 THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 1415 (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE 1416 OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 1417 - 1418 -Files: include/client/* include/common/* src/client/* src/common/* 1419 -Copyright: 2012-2013, Canonical Ltd. 1420 -License: LGPL-3 1421 - This program is free software: you can redistribute it and/or modify 1422 - it under the terms of the GNU Lesser General Public License version 3 as 1423 - published by the Free Software Foundation. 1424 - . 1425 - This program is distributed in the hope that it will be useful, 1426 - but WITHOUT ANY WARRANTY; without even the implied warranty of 1427 - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 1428 - GNU Lesser General Public License for more details. 1429 - . 1430 - On Debian systems, the full text of the GNU Lesser General Public 1431 - License version 3 can be found in the file 1432 - /usr/share/common-licenses/LGPL-3'. 1433 - 1434 1435 === added file 'debian/libmiral-dev.install' 1436 --- debian/libmiral-dev.install 1970-01-01 00:00:00 +0000 1437 +++ debian/libmiral-dev.install 2017-10-11 15:01:23 +0000 1438 @@ -0,0 +1,3 @@ 1439 +usr/include/miral/miral/* 1440 +usr/lib/*/pkgconfig/miral.pc 1441 +usr/lib/*/libmiral.so 1442 1443 === added file 'debian/libmiral2.install' 1444 --- debian/libmiral2.install 1970-01-01 00:00:00 +0000 1445 +++ debian/libmiral2.install 2017-10-11 15:01:23 +0000 1446 @@ -0,0 +1,1 @@ 1447 +usr/lib/*/libmiral.so.2 1448 1449 === added file 'debian/libmiral2.symbols' 1450 --- debian/libmiral2.symbols 1970-01-01 00:00:00 +0000 1451 +++ debian/libmiral2.symbols 2017-10-11 15:01:23 +0000 1452 @@ -0,0 +1,399 @@ 1453 +libmiral.so.2 libmiral2 #MINVER# 1454 + MIRAL_1.0@MIRAL_1.0 1.0.0 1455 + (c++)"miral::WindowInfo::height_inc(mir::geometry::detail::IntWrapper)@MIRAL_1.0" 1.0.0 1456 + (c++)"miral::WindowInfo::max_aspect(miral::WindowSpecification::AspectRatio)@MIRAL_1.0" 1.0.0 1457 + (c++)"miral::WindowInfo::max_height(mir::geometry::detail::IntWrapper)@MIRAL_1.0" 1.0.0 1458 + (c++)"miral::WindowInfo::min_aspect(miral::WindowSpecification::AspectRatio)@MIRAL_1.0" 1.0.0 1459 + (c++)"miral::WindowInfo::min_height(mir::geometry::detail::IntWrapper)@MIRAL_1.0" 1.0.0 1460 + (c++)"miral::WindowInfo::remove_child(miral::Window const&)@MIRAL_1.0" 1.0.0 1461 + (c++)"miral::WindowInfo::restore_rect(mir::geometry::Rectangle const&)@MIRAL_1.0" 1.0.0 1462 + (c++)"miral::WindowInfo::needs_titlebar(MirSurfaceType)@MIRAL_1.0" 1.0.0 1463 + (c++)"miral::WindowInfo::confine_pointer(MirPointerConfinementState)@MIRAL_1.0" 1.0.0 1464 + (c++)"miral::WindowInfo::preferred_orientation(MirOrientationMode)@MIRAL_1.0" 1.0.0 1465 + (c++)"miral::WindowInfo::name(std::__cxx11::basic_string, std::allocator > const&)@MIRAL_1.0" 1.0.0 1466 + (c++)"miral::WindowInfo::type(MirSurfaceType)@MIRAL_1.0" 1.0.0 1467 + (c++)"miral::WindowInfo::state(MirSurfaceState)@MIRAL_1.0" 1.0.0 1468 + (c++)"miral::WindowInfo::parent(miral::Window const&)@MIRAL_1.0" 1.0.0 1469 + (c++)"miral::WindowInfo::userdata(std::shared_ptr)@MIRAL_1.0" 1.0.0 1470 + (c++)"miral::WindowInfo::add_child(miral::Window const&)@MIRAL_1.0" 1.0.0 1471 + (c++)"miral::WindowInfo::max_width(mir::geometry::detail::IntWrapper)@MIRAL_1.0" 1.0.0 1472 + (c++)"miral::WindowInfo::min_width(mir::geometry::detail::IntWrapper)@MIRAL_1.0" 1.0.0 1473 + (c++)"miral::WindowInfo::output_id(mir::optional_value)@MIRAL_1.0" 1.0.0 1474 + (c++)"miral::WindowInfo::width_inc(mir::geometry::detail::IntWrapper)@MIRAL_1.0" 1.0.0 1475 + (c++)"miral::WindowInfo::WindowInfo(miral::Window const&, miral::WindowSpecification const&)@MIRAL_1.0" 1.0.0 1476 + (c++)"miral::WindowInfo::WindowInfo(miral::WindowInfo const&)@MIRAL_1.0" 1.0.0 1477 + (c++)"miral::WindowInfo::WindowInfo()@MIRAL_1.0" 1.0.0 1478 + (c++)"miral::WindowInfo::WindowInfo(miral::Window const&, miral::WindowSpecification const&)@MIRAL_1.0" 1.0.0 1479 + (c++)"miral::WindowInfo::WindowInfo(miral::WindowInfo const&)@MIRAL_1.0" 1.0.0 1480 + (c++)"miral::WindowInfo::WindowInfo()@MIRAL_1.0" 1.0.0 1481 + (c++)"miral::WindowInfo::~WindowInfo()@MIRAL_1.0" 1.0.0 1482 + (c++)"miral::WindowInfo::~WindowInfo()@MIRAL_1.0" 1.0.0 1483 + (c++)"miral::WindowInfo::operator=(miral::WindowInfo const&)@MIRAL_1.0" 1.0.0 1484 + (c++)"miral::CursorTheme::CursorTheme(std::__cxx11::basic_string, std::allocator > const&)@MIRAL_1.0" 1.0.0 1485 + (c++)"miral::CursorTheme::CursorTheme(std::__cxx11::basic_string, std::allocator > const&)@MIRAL_1.0" 1.0.0 1486 + (c++)"miral::CursorTheme::~CursorTheme()@MIRAL_1.0" 1.0.0 1487 + (c++)"miral::CursorTheme::~CursorTheme()@MIRAL_1.0" 1.0.0 1488 + (c++)"miral::SetTerminator::SetTerminator(std::function const&)@MIRAL_1.0" 1.0.0 1489 + (c++)"miral::SetTerminator::SetTerminator(std::function const&)@MIRAL_1.0" 1.0.0 1490 + (c++)"miral::SetTerminator::~SetTerminator()@MIRAL_1.0" 1.0.0 1491 + (c++)"miral::SetTerminator::~SetTerminator()@MIRAL_1.0" 1.0.0 1492 + (c++)"miral::DebugExtension::enable()@MIRAL_1.0" 1.0.0 1493 + (c++)"miral::DebugExtension::disable()@MIRAL_1.0" 1.0.0 1494 + (c++)"miral::DebugExtension::DebugExtension(miral::DebugExtension const&)@MIRAL_1.0" 1.0.0 1495 + (c++)"miral::DebugExtension::DebugExtension()@MIRAL_1.0" 1.0.0 1496 + (c++)"miral::DebugExtension::DebugExtension(miral::DebugExtension const&)@MIRAL_1.0" 1.0.0 1497 + (c++)"miral::DebugExtension::DebugExtension()@MIRAL_1.0" 1.0.0 1498 + (c++)"miral::DebugExtension::operator=(miral::DebugExtension const&)@MIRAL_1.0" 1.0.0 1499 + (c++)"miral::AddInitCallback::AddInitCallback(std::function const&)@MIRAL_1.0" 1.0.0 1500 + (c++)"miral::AddInitCallback::AddInitCallback(std::function const&)@MIRAL_1.0" 1.0.0 1501 + (c++)"miral::AddInitCallback::~AddInitCallback()@MIRAL_1.0" 1.0.0 1502 + (c++)"miral::AddInitCallback::~AddInitCallback()@MIRAL_1.0" 1.0.0 1503 + (c++)"miral::ApplicationInfo::add_window(miral::Window const&)@MIRAL_1.0" 1.0.0 1504 + (c++)"miral::ApplicationInfo::remove_window(miral::Window const&)@MIRAL_1.0" 1.0.0 1505 + (c++)"miral::ApplicationInfo::userdata(std::shared_ptr)@MIRAL_1.0" 1.0.0 1506 + (c++)"miral::ApplicationInfo::ApplicationInfo(miral::ApplicationInfo const&)@MIRAL_1.0" 1.0.0 1507 + (c++)"miral::ApplicationInfo::ApplicationInfo(std::shared_ptr const&)@MIRAL_1.0" 1.0.0 1508 + (c++)"miral::ApplicationInfo::ApplicationInfo()@MIRAL_1.0" 1.0.0 1509 + (c++)"miral::ApplicationInfo::ApplicationInfo(miral::ApplicationInfo const&)@MIRAL_1.0" 1.0.0 1510 + (c++)"miral::ApplicationInfo::ApplicationInfo(std::shared_ptr const&)@MIRAL_1.0" 1.0.0 1511 + (c++)"miral::ApplicationInfo::ApplicationInfo()@MIRAL_1.0" 1.0.0 1512 + (c++)"miral::ApplicationInfo::~ApplicationInfo()@MIRAL_1.0" 1.0.0 1513 + (c++)"miral::ApplicationInfo::~ApplicationInfo()@MIRAL_1.0" 1.0.0 1514 + (c++)"miral::ApplicationInfo::operator=(miral::ApplicationInfo const&)@MIRAL_1.0" 1.0.0 1515 + (c++)"miral::AppendEventFilter::AppendEventFilter(std::function const&)@MIRAL_1.0" 1.0.0 1516 + (c++)"miral::AppendEventFilter::AppendEventFilter(std::function const&)@MIRAL_1.0" 1.0.0 1517 + (c++)"miral::AppendEventFilter::operator()(mir::Server&)@MIRAL_1.0" 1.0.0 1518 + (c++)"miral::CommandLineOption::CommandLineOption(miral::CommandLineOption const&)@MIRAL_1.0" 1.0.0 1519 + (c++)"miral::CommandLineOption::CommandLineOption(std::function, std::allocator > > const&)>, std::__cxx11::basic_string, std::allocator > const&, std::__cxx11::basic_string, std::allocator > const&)@MIRAL_1.0" 1.0.0 1520 + (c++)"miral::CommandLineOption::CommandLineOption(std::function const&)>, std::__cxx11::basic_string, std::allocator > const&, std::__cxx11::basic_string, std::allocator > const&)@MIRAL_1.0" 1.0.0 1521 + (c++)"miral::CommandLineOption::CommandLineOption(std::function const&)>, std::__cxx11::basic_string, std::allocator > const&, std::__cxx11::basic_string, std::allocator > const&)@MIRAL_1.0" 1.0.0 1522 + (c++)"miral::CommandLineOption::CommandLineOption(std::function, std::allocator > const&)>, std::__cxx11::basic_string, std::allocator > const&, std::__cxx11::basic_string, std::allocator > const&, char const*)@MIRAL_1.0" 1.0.0 1523 + (c++)"miral::CommandLineOption::CommandLineOption(std::function, std::allocator > const&)>, std::__cxx11::basic_string, std::allocator > const&, std::__cxx11::basic_string, std::allocator > const&, std::__cxx11::basic_string, std::allocator > const&)@MIRAL_1.0" 1.0.0 1524 + (c++)"miral::CommandLineOption::CommandLineOption(std::function, std::__cxx11::basic_string, std::allocator > const&, std::__cxx11::basic_string, std::allocator > const&)@MIRAL_1.0" 1.0.0 1525 + (c++)"miral::CommandLineOption::CommandLineOption(std::function, std::__cxx11::basic_string, std::allocator > const&, std::__cxx11::basic_string, std::allocator > const&, bool)@MIRAL_1.0" 1.0.0 1526 + (c++)"miral::CommandLineOption::CommandLineOption(std::function, std::__cxx11::basic_string, std::allocator > const&, std::__cxx11::basic_string, std::allocator > const&, double)@MIRAL_1.0" 1.0.0 1527 + (c++)"miral::CommandLineOption::CommandLineOption(std::function, std::__cxx11::basic_string, std::allocator > const&, std::__cxx11::basic_string, std::allocator > const&, int)@MIRAL_1.0" 1.0.0 1528 + (c++)"miral::CommandLineOption::CommandLineOption(miral::CommandLineOption const&)@MIRAL_1.0" 1.0.0 1529 + (c++)"miral::CommandLineOption::CommandLineOption(std::function, std::allocator > > const&)>, std::__cxx11::basic_string, std::allocator > const&, std::__cxx11::basic_string, std::allocator > const&)@MIRAL_1.0" 1.0.0 1530 + (c++)"miral::CommandLineOption::CommandLineOption(std::function const&)>, std::__cxx11::basic_string, std::allocator > const&, std::__cxx11::basic_string, std::allocator > const&)@MIRAL_1.0" 1.0.0 1531 + (c++)"miral::CommandLineOption::CommandLineOption(std::function const&)>, std::__cxx11::basic_string, std::allocator > const&, std::__cxx11::basic_string, std::allocator > const&)@MIRAL_1.0" 1.0.0 1532 + (c++)"miral::CommandLineOption::CommandLineOption(std::function, std::allocator > const&)>, std::__cxx11::basic_string, std::allocator > const&, std::__cxx11::basic_string, std::allocator > const&, char const*)@MIRAL_1.0" 1.0.0 1533 + (c++)"miral::CommandLineOption::CommandLineOption(std::function, std::allocator > const&)>, std::__cxx11::basic_string, std::allocator > const&, std::__cxx11::basic_string, std::allocator > const&, std::__cxx11::basic_string, std::allocator > const&)@MIRAL_1.0" 1.0.0 1534 + (c++)"miral::CommandLineOption::CommandLineOption(std::function, std::__cxx11::basic_string, std::allocator > const&, std::__cxx11::basic_string, std::allocator > const&)@MIRAL_1.0" 1.0.0 1535 + (c++)"miral::CommandLineOption::CommandLineOption(std::function, std::__cxx11::basic_string, std::allocator > const&, std::__cxx11::basic_string, std::allocator > const&, bool)@MIRAL_1.0" 1.0.0 1536 + (c++)"miral::CommandLineOption::CommandLineOption(std::function, std::__cxx11::basic_string, std::allocator > const&, std::__cxx11::basic_string, std::allocator > const&, double)@MIRAL_1.0" 1.0.0 1537 + (c++)"miral::CommandLineOption::CommandLineOption(std::function, std::__cxx11::basic_string, std::allocator > const&, std::__cxx11::basic_string, std::allocator > const&, int)@MIRAL_1.0" 1.0.0 1538 + (c++)"miral::CommandLineOption::~CommandLineOption()@MIRAL_1.0" 1.0.0 1539 + (c++)"miral::CommandLineOption::~CommandLineOption()@MIRAL_1.0" 1.0.0 1540 + (c++)"miral::CommandLineOption::operator=(miral::CommandLineOption const&)@MIRAL_1.0" 1.0.0 1541 + (c++)"miral::WindowManagerTools::raise_tree(miral::Window const&)@MIRAL_1.0" 1.0.0 1542 + (c++)"miral::WindowManagerTools::force_close(miral::Window const&)@MIRAL_1.0" 1.0.0 1543 + (c++)"miral::WindowManagerTools::modify_window(miral::Window const&, miral::WindowSpecification const&)@MIRAL_1.0" 1.0.0 1544 + (c++)"miral::WindowManagerTools::modify_window(miral::WindowInfo&, miral::WindowSpecification const&)@MIRAL_1.0" 1.0.0 1545 + (c++)"miral::WindowManagerTools::active_display()@MIRAL_1.0" 1.0.0 1546 + (c++)"miral::WindowManagerTools::find_application(std::function const&)@MIRAL_1.0" 1.0.0 1547 + (c++)"miral::WindowManagerTools::invoke_under_lock(std::function const&)@MIRAL_1.0" 1.0.0 1548 + (c++)"miral::WindowManagerTools::drag_active_window(mir::geometry::Displacement)@MIRAL_1.0" 1.0.0 1549 + (c++)"miral::WindowManagerTools::ask_client_to_close(miral::Window const&)@MIRAL_1.0" 1.0.0 1550 + (c++)"miral::WindowManagerTools::for_each_application(std::function const&)@MIRAL_1.0" 1.0.0 1551 + (c++)"miral::WindowManagerTools::select_active_window(miral::Window const&)@MIRAL_1.0" 1.0.0 1552 + (c++)"miral::WindowManagerTools::focus_next_application()@MIRAL_1.0" 1.0.0 1553 + (c++)"miral::WindowManagerTools::focus_next_within_application()@MIRAL_1.0" 1.0.0 1554 + (c++)"miral::WindowManagerTools::WindowManagerTools(miral::WindowManagerToolsImplementation*)@MIRAL_1.0" 1.0.0 1555 + (c++)"miral::WindowManagerTools::WindowManagerTools(miral::WindowManagerTools const&)@MIRAL_1.0" 1.0.0 1556 + (c++)"miral::WindowManagerTools::WindowManagerTools(miral::WindowManagerToolsImplementation*)@MIRAL_1.0" 1.0.0 1557 + (c++)"miral::WindowManagerTools::WindowManagerTools(miral::WindowManagerTools const&)@MIRAL_1.0" 1.0.0 1558 + (c++)"miral::WindowManagerTools::~WindowManagerTools()@MIRAL_1.0" 1.0.0 1559 + (c++)"miral::WindowManagerTools::~WindowManagerTools()@MIRAL_1.0" 1.0.0 1560 + (c++)"miral::WindowManagerTools::operator=(miral::WindowManagerTools const&)@MIRAL_1.0" 1.0.0 1561 + (c++)"miral::WindowSpecification::height_inc()@MIRAL_1.0" 1.0.0 1562 + (c++)"miral::WindowSpecification::input_mode()@MIRAL_1.0" 1.0.0 1563 + (c++)"miral::WindowSpecification::max_aspect()@MIRAL_1.0" 1.0.0 1564 + (c++)"miral::WindowSpecification::max_height()@MIRAL_1.0" 1.0.0 1565 + (c++)"miral::WindowSpecification::min_aspect()@MIRAL_1.0" 1.0.0 1566 + (c++)"miral::WindowSpecification::min_height()@MIRAL_1.0" 1.0.0 1567 + (c++)"miral::WindowSpecification::input_shape()@MIRAL_1.0" 1.0.0 1568 + (c++)"miral::WindowSpecification::shell_chrome()@MIRAL_1.0" 1.0.0 1569 + (c++)"miral::WindowSpecification::confine_pointer()@MIRAL_1.0" 1.0.0 1570 + (c++)"miral::WindowSpecification::placement_hints()@MIRAL_1.0" 1.0.0 1571 + (c++)"miral::WindowSpecification::preferred_orientation()@MIRAL_1.0" 1.0.0 1572 + (c++)"miral::WindowSpecification::window_placement_gravity()@MIRAL_1.0" 1.0.0 1573 + (c++)"miral::WindowSpecification::aux_rect_placement_offset()@MIRAL_1.0" 1.0.0 1574 + (c++)"miral::WindowSpecification::aux_rect_placement_gravity()@MIRAL_1.0" 1.0.0 1575 + (c++)"miral::WindowSpecification::name[abi:cxx11]()@MIRAL_1.0" 1.0.0 1576 + (c++)"miral::WindowSpecification::size()@MIRAL_1.0" 1.0.0 1577 + (c++)"miral::WindowSpecification::type()@MIRAL_1.0" 1.0.0 1578 + (c++)"miral::WindowSpecification::state()@MIRAL_1.0" 1.0.0 1579 + (c++)"miral::WindowSpecification::parent()@MIRAL_1.0" 1.0.0 1580 + (c++)"miral::WindowSpecification::aux_rect()@MIRAL_1.0" 1.0.0 1581 + (c++)"miral::WindowSpecification::top_left()@MIRAL_1.0" 1.0.0 1582 + (c++)"miral::WindowSpecification::userdata()@MIRAL_1.0" 1.0.0 1583 + (c++)"miral::WindowSpecification::max_width()@MIRAL_1.0" 1.0.0 1584 + (c++)"miral::WindowSpecification::min_width()@MIRAL_1.0" 1.0.0 1585 + (c++)"miral::WindowSpecification::output_id()@MIRAL_1.0" 1.0.0 1586 + (c++)"miral::WindowSpecification::width_inc()@MIRAL_1.0" 1.0.0 1587 + (c++)"miral::WindowSpecification::WindowSpecification(mir::scene::SurfaceCreationParameters const&)@MIRAL_1.0" 1.0.0 1588 + (c++)"miral::WindowSpecification::WindowSpecification(mir::shell::SurfaceSpecification const&)@MIRAL_1.0" 1.0.0 1589 + (c++)"miral::WindowSpecification::WindowSpecification(miral::WindowSpecification const&)@MIRAL_1.0" 1.0.0 1590 + (c++)"miral::WindowSpecification::WindowSpecification()@MIRAL_1.0" 1.0.0 1591 + (c++)"miral::WindowSpecification::WindowSpecification(mir::scene::SurfaceCreationParameters const&)@MIRAL_1.0" 1.0.0 1592 + (c++)"miral::WindowSpecification::WindowSpecification(mir::shell::SurfaceSpecification const&)@MIRAL_1.0" 1.0.0 1593 + (c++)"miral::WindowSpecification::WindowSpecification(miral::WindowSpecification const&)@MIRAL_1.0" 1.0.0 1594 + (c++)"miral::WindowSpecification::WindowSpecification()@MIRAL_1.0" 1.0.0 1595 + (c++)"miral::WindowSpecification::~WindowSpecification()@MIRAL_1.0" 1.0.0 1596 + (c++)"miral::WindowSpecification::~WindowSpecification()@MIRAL_1.0" 1.0.0 1597 + (c++)"miral::WindowSpecification::operator=(miral::WindowSpecification const&)@MIRAL_1.0" 1.0.0 1598 + (c++)"miral::ActiveOutputsMonitor::add_listener(miral::ActiveOutputsListener*)@MIRAL_1.0" 1.0.0 1599 + (c++)"miral::ActiveOutputsMonitor::delete_listener(miral::ActiveOutputsListener*)@MIRAL_1.0" 1.0.0 1600 + (c++)"miral::ActiveOutputsMonitor::ActiveOutputsMonitor(miral::ActiveOutputsMonitor const&)@MIRAL_1.0" 1.0.0 1601 + (c++)"miral::ActiveOutputsMonitor::ActiveOutputsMonitor()@MIRAL_1.0" 1.0.0 1602 + (c++)"miral::ActiveOutputsMonitor::ActiveOutputsMonitor(miral::ActiveOutputsMonitor const&)@MIRAL_1.0" 1.0.0 1603 + (c++)"miral::ActiveOutputsMonitor::ActiveOutputsMonitor()@MIRAL_1.0" 1.0.0 1604 + (c++)"miral::ActiveOutputsMonitor::~ActiveOutputsMonitor()@MIRAL_1.0" 1.0.0 1605 + (c++)"miral::ActiveOutputsMonitor::~ActiveOutputsMonitor()@MIRAL_1.0" 1.0.0 1606 + (c++)"miral::ActiveOutputsMonitor::operator=(miral::ActiveOutputsMonitor const&)@MIRAL_1.0" 1.0.0 1607 + (c++)"miral::ActiveOutputsMonitor::operator()(mir::Server&)@MIRAL_1.0" 1.0.0 1608 + (c++)"miral::ActiveOutputsListener::advise_output_end()@MIRAL_1.0" 1.0.0 1609 + (c++)"miral::ActiveOutputsListener::advise_output_begin()@MIRAL_1.0" 1.0.0 1610 + (c++)"miral::ActiveOutputsListener::advise_output_create(miral::Output const&)@MIRAL_1.0" 1.0.0 1611 + (c++)"miral::ActiveOutputsListener::advise_output_delete(miral::Output const&)@MIRAL_1.0" 1.0.0 1612 + (c++)"miral::ActiveOutputsListener::advise_output_update(miral::Output const&, miral::Output const&)@MIRAL_1.0" 1.0.0 1613 + (c++)"miral::SetCommandLineHandler::SetCommandLineHandler(std::function const&)@MIRAL_1.0" 1.0.0 1614 + (c++)"miral::SetCommandLineHandler::SetCommandLineHandler(std::function const&)@MIRAL_1.0" 1.0.0 1615 + (c++)"miral::SetCommandLineHandler::~SetCommandLineHandler()@MIRAL_1.0" 1.0.0 1616 + (c++)"miral::SetCommandLineHandler::~SetCommandLineHandler()@MIRAL_1.0" 1.0.0 1617 + (c++)"miral::StartupInternalClient::StartupInternalClient(std::__cxx11::basic_string, std::allocator >, std::function, std::function)>)@MIRAL_1.0" 1.0.0 1618 + (c++)"miral::StartupInternalClient::StartupInternalClient(std::__cxx11::basic_string, std::allocator >, std::function, std::function)>)@MIRAL_1.0" 1.0.0 1619 + (c++)"miral::StartupInternalClient::~StartupInternalClient()@MIRAL_1.0" 1.0.0 1620 + (c++)"miral::StartupInternalClient::~StartupInternalClient()@MIRAL_1.0" 1.0.0 1621 + (c++)"miral::StartupInternalClient::operator()(mir::Server&)@MIRAL_1.0" 1.0.0 1622 + (c++)"miral::ApplicationCredentials::ApplicationCredentials(mir::frontend::SessionCredentials const&)@MIRAL_1.0" 1.0.0 1623 + (c++)"miral::ApplicationCredentials::ApplicationCredentials(mir::frontend::SessionCredentials const&)@MIRAL_1.0" 1.0.0 1624 + (c++)"miral::InternalClientLauncher::InternalClientLauncher()@MIRAL_1.0" 1.0.0 1625 + (c++)"miral::InternalClientLauncher::InternalClientLauncher()@MIRAL_1.0" 1.0.0 1626 + (c++)"miral::InternalClientLauncher::~InternalClientLauncher()@MIRAL_1.0" 1.0.0 1627 + (c++)"miral::InternalClientLauncher::~InternalClientLauncher()@MIRAL_1.0" 1.0.0 1628 + (c++)"miral::InternalClientLauncher::operator()(mir::Server&)@MIRAL_1.0" 1.0.0 1629 + (c++)"miral::WindowManagementPolicy::advise_end()@MIRAL_1.0" 1.0.0 1630 + (c++)"miral::WindowManagementPolicy::advise_begin()@MIRAL_1.0" 1.0.0 1631 + (c++)"miral::WindowManagementPolicy::advise_raise(std::vector > const&)@MIRAL_1.0" 1.0.0 1632 + (c++)"miral::WindowManagementPolicy::advise_resize(miral::WindowInfo const&, mir::geometry::Size const&)@MIRAL_1.0" 1.0.0 1633 + (c++)"miral::WindowManagementPolicy::advise_move_to(miral::WindowInfo const&, mir::geometry::Point)@MIRAL_1.0" 1.0.0 1634 + (c++)"miral::WindowManagementPolicy::advise_new_app(miral::ApplicationInfo&)@MIRAL_1.0" 1.0.0 1635 + (c++)"miral::WindowManagementPolicy::advise_delete_app(miral::ApplicationInfo const&)@MIRAL_1.0" 1.0.0 1636 + (c++)"miral::WindowManagementPolicy::advise_focus_lost(miral::WindowInfo const&)@MIRAL_1.0" 1.0.0 1637 + (c++)"miral::WindowManagementPolicy::advise_new_window(miral::WindowInfo const&)@MIRAL_1.0" 1.0.0 1638 + (c++)"miral::WindowManagementPolicy::advise_focus_gained(miral::WindowInfo const&)@MIRAL_1.0" 1.0.0 1639 + (c++)"miral::WindowManagementPolicy::advise_state_change(miral::WindowInfo const&, MirSurfaceState)@MIRAL_1.0" 1.0.0 1640 + (c++)"miral::WindowManagementPolicy::advise_delete_window(miral::WindowInfo const&)@MIRAL_1.0" 1.0.0 1641 + (c++)"miral::equivalent_display_area(miral::Output const&, miral::Output const&)@MIRAL_1.0" 1.0.0 1642 + (c++)"miral::SetWindowManagmentPolicy::SetWindowManagmentPolicy(std::function > (miral::WindowManagerTools const&)> const&)@MIRAL_1.0" 1.0.0 1643 + (c++)"miral::SetWindowManagmentPolicy::SetWindowManagmentPolicy(std::function > (miral::WindowManagerTools const&)> const&)@MIRAL_1.0" 1.0.0 1644 + (c++)"miral::SetWindowManagmentPolicy::~SetWindowManagmentPolicy()@MIRAL_1.0" 1.0.0 1645 + (c++)"miral::SetWindowManagmentPolicy::~SetWindowManagmentPolicy()@MIRAL_1.0" 1.0.0 1646 + (c++)"miral::apply_lifecycle_state_to(std::shared_ptr const&, MirLifecycleState)@MIRAL_1.0" 1.0.0 1647 + (c++)"miral::CanonicalWindowManagerPolicy::place_new_surface(miral::ApplicationInfo const&, miral::WindowSpecification const&)@MIRAL_1.0" 1.0.0 1648 + (c++)"miral::CanonicalWindowManagerPolicy::advise_focus_gained(miral::WindowInfo const&)@MIRAL_1.0" 1.0.0 1649 + (c++)"miral::CanonicalWindowManagerPolicy::handle_raise_window(miral::WindowInfo&)@MIRAL_1.0" 1.0.0 1650 + (c++)"miral::CanonicalWindowManagerPolicy::handle_window_ready(miral::WindowInfo&)@MIRAL_1.0" 1.0.0 1651 + (c++)"miral::CanonicalWindowManagerPolicy::handle_modify_window(miral::WindowInfo&, miral::WindowSpecification const&)@MIRAL_1.0" 1.0.0 1652 + (c++)"miral::CanonicalWindowManagerPolicy::confirm_inherited_move(miral::WindowInfo const&, mir::geometry::Displacement)@MIRAL_1.0" 1.0.0 1653 + (c++)"miral::CanonicalWindowManagerPolicy::CanonicalWindowManagerPolicy(miral::WindowManagerTools const&)@MIRAL_1.0" 1.0.0 1654 + (c++)"miral::CanonicalWindowManagerPolicy::CanonicalWindowManagerPolicy(miral::WindowManagerTools const&)@MIRAL_1.0" 1.0.0 1655 + (c++)"miral::BasicSetApplicationAuthorizer::BasicSetApplicationAuthorizer(std::function ()> const&)@MIRAL_1.0" 1.0.0 1656 + (c++)"miral::BasicSetApplicationAuthorizer::BasicSetApplicationAuthorizer(std::function ()> const&)@MIRAL_1.0" 1.0.0 1657 + (c++)"miral::BasicSetApplicationAuthorizer::~BasicSetApplicationAuthorizer()@MIRAL_1.0" 1.0.0 1658 + (c++)"miral::BasicSetApplicationAuthorizer::~BasicSetApplicationAuthorizer()@MIRAL_1.0" 1.0.0 1659 + (c++)"miral::BasicSetApplicationAuthorizer::operator()(mir::Server&)@MIRAL_1.0" 1.0.0 1660 + (c++)"miral::display_configuration_options(mir::Server&)@MIRAL_1.0" 1.0.0 1661 + (c++)"miral::kill(std::shared_ptr const&, int)@MIRAL_1.0" 1.0.0 1662 + (c++)"miral::Keymap::set_keymap(std::__cxx11::basic_string, std::allocator > const&)@MIRAL_1.0" 1.0.0 1663 + (c++)"miral::Keymap::Keymap(std::__cxx11::basic_string, std::allocator > const&)@MIRAL_1.0" 1.0.0 1664 + (c++)"miral::Keymap::Keymap(miral::Keymap const&)@MIRAL_1.0" 1.0.0 1665 + (c++)"miral::Keymap::Keymap()@MIRAL_1.0" 1.0.0 1666 + (c++)"miral::Keymap::Keymap(std::__cxx11::basic_string, std::allocator > const&)@MIRAL_1.0" 1.0.0 1667 + (c++)"miral::Keymap::Keymap(miral::Keymap const&)@MIRAL_1.0" 1.0.0 1668 + (c++)"miral::Keymap::Keymap()@MIRAL_1.0" 1.0.0 1669 + (c++)"miral::Keymap::~Keymap()@MIRAL_1.0" 1.0.0 1670 + (c++)"miral::Keymap::~Keymap()@MIRAL_1.0" 1.0.0 1671 + (c++)"miral::Keymap::operator=(miral::Keymap const&)@MIRAL_1.0" 1.0.0 1672 + (c++)"miral::Output::Output(mir::graphics::DisplayConfigurationOutput const&)@MIRAL_1.0" 1.0.0 1673 + (c++)"miral::Output::Output(miral::Output const&)@MIRAL_1.0" 1.0.0 1674 + (c++)"miral::Output::Output(mir::graphics::DisplayConfigurationOutput const&)@MIRAL_1.0" 1.0.0 1675 + (c++)"miral::Output::Output(miral::Output const&)@MIRAL_1.0" 1.0.0 1676 + (c++)"miral::Output::~Output()@MIRAL_1.0" 1.0.0 1677 + (c++)"miral::Output::~Output()@MIRAL_1.0" 1.0.0 1678 + (c++)"miral::Output::operator=(miral::Output const&)@MIRAL_1.0" 1.0.0 1679 + (c++)"miral::Window::resize(mir::geometry::Size const&)@MIRAL_1.0" 1.0.0 1680 + (c++)"miral::Window::move_to(mir::geometry::Point)@MIRAL_1.0" 1.0.0 1681 + (c++)"miral::Window::Window(std::shared_ptr const&, std::shared_ptr const&)@MIRAL_1.0" 1.0.0 1682 + (c++)"miral::Window::Window()@MIRAL_1.0" 1.0.0 1683 + (c++)"miral::Window::Window(std::shared_ptr const&, std::shared_ptr const&)@MIRAL_1.0" 1.0.0 1684 + (c++)"miral::Window::Window()@MIRAL_1.0" 1.0.0 1685 + (c++)"miral::Window::~Window()@MIRAL_1.0" 1.0.0 1686 + (c++)"miral::Window::~Window()@MIRAL_1.0" 1.0.0 1687 + (c++)"miral::pid_of(std::shared_ptr const&)@MIRAL_1.0" 1.0.0 1688 + (c++)"miral::name_of[abi:cxx11](std::shared_ptr const&)@MIRAL_1.0" 1.0.0 1689 + (c++)"miral::MirRunner::add_stop_callback(std::function const&)@MIRAL_1.0" 1.0.0 1690 + (c++)"miral::MirRunner::add_start_callback(std::function const&)@MIRAL_1.0" 1.0.0 1691 + (c++)"miral::MirRunner::set_exception_handler(std::function const&)@MIRAL_1.0" 1.0.0 1692 + (c++)"miral::MirRunner::stop()@MIRAL_1.0" 1.0.0 1693 + (c++)"miral::MirRunner::run_with(std::initializer_list >)@MIRAL_1.0" 1.0.0 1694 + (c++)"miral::MirRunner::MirRunner(int, char const**)@MIRAL_1.0" 1.0.0 1695 + (c++)"miral::MirRunner::MirRunner(int, char const**, char const*)@MIRAL_1.0" 1.0.0 1696 + (c++)"miral::MirRunner::MirRunner(int, char const**)@MIRAL_1.0" 1.0.0 1697 + (c++)"miral::MirRunner::MirRunner(int, char const**, char const*)@MIRAL_1.0" 1.0.0 1698 + (c++)"miral::MirRunner::~MirRunner()@MIRAL_1.0" 1.0.0 1699 + (c++)"miral::MirRunner::~MirRunner()@MIRAL_1.0" 1.0.0 1700 + (c++)"miral::operator==(miral::Output::PhysicalSizeMM const&, miral::Output::PhysicalSizeMM const&)@MIRAL_1.0" 1.0.0 1701 + (c++)"miral::operator==(miral::Window const&, std::shared_ptr const&)@MIRAL_1.0" 1.0.0 1702 + (c++)"miral::operator==(miral::Window const&, miral::Window const&)@MIRAL_1.0" 1.0.0 1703 + (c++)"miral::operator==(std::shared_ptr const&, miral::Window const&)@MIRAL_1.0" 1.0.0 1704 + (c++)"miral::WindowInfo::height_inc() const@MIRAL_1.0" 1.0.0 1705 + (c++)"miral::WindowInfo::is_visible() const@MIRAL_1.0" 1.0.0 1706 + (c++)"miral::WindowInfo::max_aspect() const@MIRAL_1.0" 1.0.0 1707 + (c++)"miral::WindowInfo::max_height() const@MIRAL_1.0" 1.0.0 1708 + (c++)"miral::WindowInfo::min_aspect() const@MIRAL_1.0" 1.0.0 1709 + (c++)"miral::WindowInfo::min_height() const@MIRAL_1.0" 1.0.0 1710 + (c++)"miral::WindowInfo::can_morph_to(MirSurfaceType) const@MIRAL_1.0" 1.0.0 1711 + (c++)"miral::WindowInfo::restore_rect() const@MIRAL_1.0" 1.0.0 1712 + (c++)"miral::WindowInfo::can_be_active() const@MIRAL_1.0" 1.0.0 1713 + (c++)"miral::WindowInfo::has_output_id() const@MIRAL_1.0" 1.0.0 1714 + (c++)"miral::WindowInfo::confine_pointer() const@MIRAL_1.0" 1.0.0 1715 + (c++)"miral::WindowInfo::constrain_resize(mir::geometry::Point&, mir::geometry::Size&) const@MIRAL_1.0" 1.0.0 1716 + (c++)"miral::WindowInfo::must_have_parent() const@MIRAL_1.0" 1.0.0 1717 + (c++)"miral::WindowInfo::must_not_have_parent() const@MIRAL_1.0" 1.0.0 1718 + (c++)"miral::WindowInfo::preferred_orientation() const@MIRAL_1.0" 1.0.0 1719 + (c++)"miral::WindowInfo::name[abi:cxx11]() const@MIRAL_1.0" 1.0.0 1720 + (c++)"miral::WindowInfo::type() const@MIRAL_1.0" 1.0.0 1721 + (c++)"miral::WindowInfo::state() const@MIRAL_1.0" 1.0.0 1722 + (c++)"miral::WindowInfo::parent() const@MIRAL_1.0" 1.0.0 1723 + (c++)"miral::WindowInfo::window() const@MIRAL_1.0" 1.0.0 1724 + (c++)"miral::WindowInfo::children() const@MIRAL_1.0" 1.0.0 1725 + (c++)"miral::WindowInfo::userdata() const@MIRAL_1.0" 1.0.0 1726 + (c++)"miral::WindowInfo::max_width() const@MIRAL_1.0" 1.0.0 1727 + (c++)"miral::WindowInfo::min_width() const@MIRAL_1.0" 1.0.0 1728 + (c++)"miral::WindowInfo::output_id() const@MIRAL_1.0" 1.0.0 1729 + (c++)"miral::WindowInfo::width_inc() const@MIRAL_1.0" 1.0.0 1730 + (c++)"miral::CursorTheme::operator()(mir::Server&) const@MIRAL_1.0" 1.0.0 1731 + (c++)"miral::SetTerminator::operator()(mir::Server&) const@MIRAL_1.0" 1.0.0 1732 + (c++)"miral::DebugExtension::operator()(mir::Server&) const@MIRAL_1.0" 1.0.0 1733 + (c++)"miral::AddInitCallback::operator()(mir::Server&) const@MIRAL_1.0" 1.0.0 1734 + (c++)"miral::ApplicationInfo::application() const@MIRAL_1.0" 1.0.0 1735 + (c++)"miral::ApplicationInfo::name[abi:cxx11]() const@MIRAL_1.0" 1.0.0 1736 + (c++)"miral::ApplicationInfo::windows() const@MIRAL_1.0" 1.0.0 1737 + (c++)"miral::ApplicationInfo::userdata() const@MIRAL_1.0" 1.0.0 1738 + (c++)"miral::CommandLineOption::operator()(mir::Server&) const@MIRAL_1.0" 1.0.0 1739 + (c++)"miral::WindowManagerTools::active_window() const@MIRAL_1.0" 1.0.0 1740 + (c++)"miral::WindowManagerTools::id_for_window[abi:cxx11](miral::Window const&) const@MIRAL_1.0" 1.0.0 1741 + (c++)"miral::WindowManagerTools::count_applications() const@MIRAL_1.0" 1.0.0 1742 + (c++)"miral::WindowManagerTools::info_for_window_id(std::__cxx11::basic_string, std::allocator > const&) const@MIRAL_1.0" 1.0.0 1743 + (c++)"miral::WindowManagerTools::place_and_size_for_state(miral::WindowSpecification&, miral::WindowInfo const&) const@MIRAL_1.0" 1.0.0 1744 + (c++)"miral::WindowManagerTools::info_for(miral::Window const&) const@MIRAL_1.0" 1.0.0 1745 + (c++)"miral::WindowManagerTools::info_for(std::weak_ptr const&) const@MIRAL_1.0" 1.0.0 1746 + (c++)"miral::WindowManagerTools::info_for(std::weak_ptr const&) const@MIRAL_1.0" 1.0.0 1747 + (c++)"miral::WindowManagerTools::window_at(mir::geometry::Point) const@MIRAL_1.0" 1.0.0 1748 + (c++)"miral::WindowSpecification::height_inc() const@MIRAL_1.0" 1.0.0 1749 + (c++)"miral::WindowSpecification::input_mode() const@MIRAL_1.0" 1.0.0 1750 + (c++)"miral::WindowSpecification::max_aspect() const@MIRAL_1.0" 1.0.0 1751 + (c++)"miral::WindowSpecification::max_height() const@MIRAL_1.0" 1.0.0 1752 + (c++)"miral::WindowSpecification::min_aspect() const@MIRAL_1.0" 1.0.0 1753 + (c++)"miral::WindowSpecification::min_height() const@MIRAL_1.0" 1.0.0 1754 + (c++)"miral::WindowSpecification::input_shape() const@MIRAL_1.0" 1.0.0 1755 + (c++)"miral::WindowSpecification::shell_chrome() const@MIRAL_1.0" 1.0.0 1756 + (c++)"miral::WindowSpecification::confine_pointer() const@MIRAL_1.0" 1.0.0 1757 + (c++)"miral::WindowSpecification::placement_hints() const@MIRAL_1.0" 1.0.0 1758 + (c++)"miral::WindowSpecification::preferred_orientation() const@MIRAL_1.0" 1.0.0 1759 + (c++)"miral::WindowSpecification::window_placement_gravity() const@MIRAL_1.0" 1.0.0 1760 + (c++)"miral::WindowSpecification::aux_rect_placement_offset() const@MIRAL_1.0" 1.0.0 1761 + (c++)"miral::WindowSpecification::aux_rect_placement_gravity() const@MIRAL_1.0" 1.0.0 1762 + (c++)"miral::WindowSpecification::name[abi:cxx11]() const@MIRAL_1.0" 1.0.0 1763 + (c++)"miral::WindowSpecification::size() const@MIRAL_1.0" 1.0.0 1764 + (c++)"miral::WindowSpecification::type() const@MIRAL_1.0" 1.0.0 1765 + (c++)"miral::WindowSpecification::state() const@MIRAL_1.0" 1.0.0 1766 + (c++)"miral::WindowSpecification::parent() const@MIRAL_1.0" 1.0.0 1767 + (c++)"miral::WindowSpecification::update(mir::scene::SurfaceCreationParameters&) const@MIRAL_1.0" 1.0.0 1768 + (c++)"miral::WindowSpecification::aux_rect() const@MIRAL_1.0" 1.0.0 1769 + (c++)"miral::WindowSpecification::top_left() const@MIRAL_1.0" 1.0.0 1770 + (c++)"miral::WindowSpecification::userdata() const@MIRAL_1.0" 1.0.0 1771 + (c++)"miral::WindowSpecification::max_width() const@MIRAL_1.0" 1.0.0 1772 + (c++)"miral::WindowSpecification::min_width() const@MIRAL_1.0" 1.0.0 1773 + (c++)"miral::WindowSpecification::output_id() const@MIRAL_1.0" 1.0.0 1774 + (c++)"miral::WindowSpecification::width_inc() const@MIRAL_1.0" 1.0.0 1775 + (c++)"miral::ActiveOutputsMonitor::process_outputs(std::function > const&)> const&) const@MIRAL_1.0" 1.0.0 1776 + (c++)"miral::WindowManagerOptions::operator()(mir::Server&) const@MIRAL_1.0" 1.0.0 1777 + (c++)"miral::SetCommandLineHandler::operator()(mir::Server&) const@MIRAL_1.0" 1.0.0 1778 + (c++)"miral::ApplicationCredentials::gid() const@MIRAL_1.0" 1.0.0 1779 + (c++)"miral::ApplicationCredentials::pid() const@MIRAL_1.0" 1.0.0 1780 + (c++)"miral::ApplicationCredentials::uid() const@MIRAL_1.0" 1.0.0 1781 + (c++)"miral::InternalClientLauncher::launch(std::__cxx11::basic_string, std::allocator > const&, std::function const&, std::function)> const&) const@MIRAL_1.0" 1.0.0 1782 + (c++)"miral::SetWindowManagmentPolicy::operator()(mir::Server&) const@MIRAL_1.0" 1.0.0 1783 + (c++)"miral::BasicSetApplicationAuthorizer::the_application_authorizer() const@MIRAL_1.0" 1.0.0 1784 + (c++)"miral::Keymap::operator()(mir::Server&) const@MIRAL_1.0" 1.0.0 1785 + (c++)"miral::Output::power_mode() const@MIRAL_1.0" 1.0.0 1786 + (c++)"miral::Output::form_factor() const@MIRAL_1.0" 1.0.0 1787 + (c++)"miral::Output::orientation() const@MIRAL_1.0" 1.0.0 1788 + (c++)"miral::Output::pixel_format() const@MIRAL_1.0" 1.0.0 1789 + (c++)"miral::Output::refresh_rate() const@MIRAL_1.0" 1.0.0 1790 + (c++)"miral::Output::is_same_output(miral::Output const&) const@MIRAL_1.0" 1.0.0 1791 + (c++)"miral::Output::physical_size_mm() const@MIRAL_1.0" 1.0.0 1792 + (c++)"miral::Output::type() const@MIRAL_1.0" 1.0.0 1793 + (c++)"miral::Output::used() const@MIRAL_1.0" 1.0.0 1794 + (c++)"miral::Output::scale() const@MIRAL_1.0" 1.0.0 1795 + (c++)"miral::Output::valid() const@MIRAL_1.0" 1.0.0 1796 + (c++)"miral::Output::extents() const@MIRAL_1.0" 1.0.0 1797 + (c++)"miral::Output::connected() const@MIRAL_1.0" 1.0.0 1798 + (c++)"miral::Window::application() const@MIRAL_1.0" 1.0.0 1799 + (c++)"miral::Window::size() const@MIRAL_1.0" 1.0.0 1800 + (c++)"miral::Window::top_left() const@MIRAL_1.0" 1.0.0 1801 + (c++)"miral::Window::operator std::shared_ptr() const@MIRAL_1.0" 1.0.0 1802 + (c++)"miral::Window::operator std::weak_ptr() const@MIRAL_1.0" 1.0.0 1803 + (c++)"miral::Window::operator bool() const@MIRAL_1.0" 1.0.0 1804 + (c++)"typeinfo for miral::ActiveOutputsListener@MIRAL_1.0" 1.0.0 1805 + (c++)"typeinfo for miral::WindowManagementPolicy@MIRAL_1.0" 1.0.0 1806 + (c++)"typeinfo for miral::CanonicalWindowManagerPolicy@MIRAL_1.0" 1.0.0 1807 + (c++)"vtable for miral::ActiveOutputsListener@MIRAL_1.0" 1.0.0 1808 + (c++)"vtable for miral::WindowManagementPolicy@MIRAL_1.0" 1.0.0 1809 + (c++)"vtable for miral::CanonicalWindowManagerPolicy@MIRAL_1.0" 1.0.0 1810 + MIRAL_1.1@MIRAL_1.1 1.1.0 1811 + (c++)"miral::WindowInfo::needs_titlebar(MirWindowType)@MIRAL_1.1" 1.1.0 1812 + (c++)"miral::WindowInfo::type(MirWindowType)@MIRAL_1.1" 1.1.0 1813 + (c++)"miral::WindowInfo::state(MirWindowState)@MIRAL_1.1" 1.1.0 1814 + (c++)"miral::WindowManagementPolicy::advise_state_change(miral::WindowInfo const&, MirWindowState)@MIRAL_1.1" 1.1.0 1815 + (c++)"miral::WindowInfo::can_morph_to(MirWindowType) const@MIRAL_1.1" 1.1.0 1816 + (c++)"miral::CanonicalWindowManagerPolicy::place_new_window(miral::ApplicationInfo const&, miral::WindowSpecification const&)@MIRAL_1.1" 1.1.0 1817 + MIRAL_1.2@MIRAL_1.2 1.2.0 1818 + (c++)"miral::StartupInternalClient::StartupInternalClient(std::__cxx11::basic_string, std::allocator >, std::function, std::function)>)@MIRAL_1.2" 1.2.0 1819 + (c++)"miral::InternalClientLauncher::launch(std::__cxx11::basic_string, std::allocator > const&, std::function const&, std::function)> const&) const@MIRAL_1.2" 1.2.0 1820 + (c++)"miral::WindowInfo::shell_chrome(MirShellChrome)@MIRAL_1.2" 1.2.0 1821 + (c++)"miral::WindowInfo::shell_chrome() const@MIRAL_1.2" 1.2.0 1822 + (c++)"miral::WindowManagerTools::drag_window(miral::Window const&, mir::geometry::Displacement)@MIRAL_1.2" 1.2.0 1823 + (c++)"typeinfo for miral::ApplicationAuthorizer@MIRAL_1.0" 1.2.0 1824 + (c++)"typeinfo for miral::ApplicationAuthorizer1@MIRAL_1.2" 1.2.0 1825 + MIRAL_1.3@MIRAL_1.3 1.3.0 1826 + (c++)"miral::operator<(miral::Window const&, miral::Window const&)@MIRAL_1.0" 1.3.0 1827 + (c++)"miral::WindowManagerTools::create_workspace()@MIRAL_1.3" 1.3.0 1828 + (c++)"miral::WindowManagerTools::add_tree_to_workspace(miral::Window const&, std::shared_ptr const&)@MIRAL_1.3" 1.3.0 1829 + (c++)"miral::WindowManagerTools::focus_prev_within_application()@MIRAL_1.3" 1.3.0 1830 + (c++)"miral::WindowManagerTools::remove_tree_from_workspace(miral::Window const&, std::shared_ptr const&)@MIRAL_1.3" 1.3.0 1831 + (c++)"miral::WindowManagerTools::move_workspace_content_to_workspace(std::shared_ptr const&, std::shared_ptr const&)@MIRAL_1.3" 1.3.0 1832 + (c++)"miral::WorkspacePolicy::advise_adding_to_workspace(std::shared_ptr const&, std::vector > const&)@MIRAL_1.3" 1.3.0 1833 + (c++)"miral::WorkspacePolicy::advise_removing_from_workspace(std::shared_ptr const&, std::vector > const&)@MIRAL_1.3" 1.3.0 1834 + (c++)"miral::WindowManagerTools::for_each_window_in_workspace(std::shared_ptr const&, std::function const&)@MIRAL_1.3" 1.3.0 1835 + (c++)"miral::WindowManagerTools::for_each_workspace_containing(miral::Window const&, std::function const&)> const&)@MIRAL_1.3" 1.3.0 1836 + (c++)"typeinfo for miral::WorkspacePolicy@MIRAL_1.3" 1.3.0 1837 + (c++)"vtable for miral::WorkspacePolicy@MIRAL_1.3" 1.3.0 1838 + MIRAL_1.3.1@MIRAL_1.3.1 1.3.1 1839 + (c++)"miral::SetWindowManagementPolicy::SetWindowManagementPolicy(std::function > (miral::WindowManagerTools const&)> const&)@MIRAL_1.3.1" 1.3.1 1840 + (c++)"miral::SetWindowManagementPolicy::SetWindowManagementPolicy(std::function > (miral::WindowManagerTools const&)> const&)@MIRAL_1.3.1" 1.3.1 1841 + (c++)"miral::SetWindowManagementPolicy::~SetWindowManagementPolicy()@MIRAL_1.3.1" 1.3.1 1842 + (c++)"miral::SetWindowManagementPolicy::~SetWindowManagementPolicy()@MIRAL_1.3.1" 1.3.1 1843 + (c++)"miral::SetWindowManagementPolicy::operator()(mir::Server&) const@MIRAL_1.3.1" 1.3.1 1844 + MIRAL_1.4.0@MIRAL_1.4.0 1.4.0 1845 + (c++)"miral::WindowManagerTools::end_drag_and_drop()@MIRAL_1.4.0" 1.4.0 1846 + (c++)"miral::WindowManagerTools::start_drag_and_drop(miral::WindowInfo&, std::vector > const&)@MIRAL_1.4.0" 1.4.0 1847 + (c++)"typeinfo for miral::WindowManagementPolicyAddendum2@MIRAL_1.4.0" 1.4.0 1848 + MIRAL_1.5.0@MIRAL_1.5.0 1.5.0 1849 + (c++)"miral::pre_init(miral::CommandLineOption const&)@MIRAL_1.5.0" 1.5.0 1850 + (c++)"typeinfo for miral::WindowManagementPolicyAddendum3@MIRAL_1.5.0" 1.5.0 1851 + (c++)"miral::WindowManagerTools::active_output()@MIRAL_1.5.0" 1.5.0 1852 \ No newline at end of file 1853 1854 === modified file 'debian/libmirclient-dev.install' 1855 --- debian/libmirclient-dev.install 2017-05-17 04:48:46 +0000 1856 +++ debian/libmirclient-dev.install 2017-10-11 15:01:23 +0000 1857 @@ -1,8 +1,10 @@ 1858 usr/include/mirclient/mir_toolkit/*.h 1859 usr/include/mirclient/mir_toolkit/extensions/*.h 1860 +usr/include/mirclient/mir/client/*.h 1861 usr/include/mirclient/mir/events/*.h 1862 usr/include/mirclient/mir/event_printer.h 1863 usr/include/mirclient/mir_toolkit/events 1864 usr/include/mirclient/mir_toolkit/rs/mir_render_surface.h 1865 usr/lib/*/pkgconfig/mirclient.pc 1866 +usr/lib/*/pkgconfig/mirclientcpp.pc 1867 usr/lib/*/libmirclient.so 1868 1869 === renamed file 'debian/libmirserver44.install' => 'debian/libmirserver45.install' 1870 --- debian/libmirserver44.install 2017-05-08 03:04:26 +0000 1871 +++ debian/libmirserver45.install 2017-10-11 15:01:23 +0000 1872 @@ -1,1 +1,1 @@ 1873 -usr/lib/*/libmirserver.so.44 1874 +usr/lib/*/libmirserver.so.45 1875 1876 === modified file 'debian/mir-demos.install' 1877 --- debian/mir-demos.install 2015-06-17 05:20:42 +0000 1878 +++ debian/mir-demos.install 2017-10-11 15:01:23 +0000 1879 @@ -1,3 +1,11 @@ 1880 usr/bin/mir_demo_* 1881 -usr/bin/mir_proving_* 1882 usr/lib/*/libmir_demo_* 1883 +usr/bin/miral-shell 1884 +usr/bin/miral-run 1885 +usr/bin/miral-kiosk 1886 +usr/bin/miral-xrun 1887 +usr/bin/miral-screencast 1888 +usr/bin/miral-desktop 1889 +usr/bin/miral-app 1890 +usr/share/applications/miral-shell.desktop 1891 +usr/share/icons/hicolor/scalable/apps/ubuntu-logo.svg 1892 1893 === modified file 'debian/rules' 1894 --- debian/rules 2017-06-28 16:02:35 +0000 1895 +++ debian/rules 2017-10-11 15:01:23 +0000 1896 @@ -1,10 +1,6 @@ 1897 #!/usr/bin/make -f 1898 1899 -DEB_HOST_ARCH ?= $(shell dpkg-architecture -qDEB_HOST_ARCH) 1900 -DEB_HOST_MULTIARCH ?=$(shell dpkg-architecture -qDEB_HOST_MULTIARCH) 1901 -DEB_HOST_ARCH_ENDIAN ?= $(shell dpkg-architecture -qDEB_HOST_ARCH_ENDIAN) 1902 -EXACT_PACKAGE_VERSION =$(shell dpkg-parsechangelog | grep Version | cut -d' ' -f 2) 1903 -DISTRIB_CODENAME = $(shell grep DISTRIB_CODENAME /etc/lsb-release | cut -d= -f2) 1904 +include /usr/share/dpkg/default.mk 1905 1906 export DPKG_GENSYMBOLS_CHECK_LEVEL = 4 1907 1908 @@ -57,16 +53,25 @@ 1909 override_dh_auto_build-indep: 1910 dh_auto_build -- doc 1911 1912 +# Reconstruct the MirAL version 1913 +MIRAL_VERSION_MAJOR =$(shell perl -n -e '/^set$$MIRAL_VERSION_MAJOR ([0-9]*)$$$$/ && print$$1' src/CMakeLists.txt) 1914 +MIRAL_VERSION_MINOR = $(shell perl -n -e '/^set$$MIRAL_VERSION_MINOR ([0-9]*)$$$$/ && print$$1' src/CMakeLists.txt) 1915 +MIRAL_VERSION_PATCH =$(shell perl -n -e '/^set$$MIRAL_VERSION_PATCH ([0-9]*)$$$$/ && print$$1' src/CMakeLists.txt) 1916 +MIRAL_RELEASE=$(MIRAL_VERSION_MAJOR).$(MIRAL_VERSION_MINOR).$(MIRAL_VERSION_PATCH) 1917 +MIRAL_VERSION=$(MIRAL_RELEASE).$(DEB_VERSION) 1918 + 1919 # TODO: we'll use a symbol file once mir is abi stable 1920 override_dh_makeshlibs: 1921 - dh_makeshlibs -V -Nmir-test-tools 1922 + dh_makeshlibs -Nlibmiral2 -V -Nmir-test-tools 1923 + # libmiral2 *has* a symbols file, so we don't need to -V it! 1924 + dh_makeshlibs -plibmiral2 -- -v$(MIRAL_RELEASE) 1925 1926 override_dh_install: 1927 # Nothing outside Mir should link to libmirprotobuf directly. 1928 # Delete the symlink so that --fail-missing doesn't think we've missed it 1929 # accidentally. 1930 -rm debian/tmp/usr/lib/*/libmirprotobuf.so 1931 -ifeq ($(filter xenial yakkety zesty,$(DISTRIB_CODENAME)),) 1932 +ifeq ($(filter xenial yakkety zesty,$(DEB_DISTRIBUTION)),) 1933 dh_install 1934 else 1935 # xenial, yakkety & zesty predate dh_missing 1936 @@ -80,3 +85,7 @@ 1937 # Don't try to find dependencies of libraries used as test data 1938 override_dh_shlibdeps: 1939 dh_shlibdeps -Xmir-test-data 1940 + 1941 +override_dh_gencontrol: 1942 + dh_gencontrol -Nlibmiral2 -Nlibmiral-dev 1943 + dh_gencontrol -plibmiral2 -plibmiral-dev -- -v$(MIRAL_VERSION) -V'libmiral2:Version=$(MIRAL_VERSION)' 1944 1945 === modified file 'doc/Doxyfile.in' 1946 --- doc/Doxyfile.in 2017-05-08 03:04:26 +0000 1947 +++ doc/Doxyfile.in 2017-10-11 15:01:23 +0000 1948 @@ -784,7 +784,8 @@ 1949 INPUT = @CMAKE_CURRENT_SOURCE_DIR@/README.md \ 1950 @CMAKE_CURRENT_SOURCE_DIR@/HACKING.md \ 1951 @CMAKE_CURRENT_SOURCE_DIR@/doc \ 1952 - @CMAKE_CURRENT_SOURCE_DIR@/examples \ 1953 + @CMAKE_CURRENT_SOURCE_DIR@/examples/miral-kiosk \ 1954 + @CMAKE_CURRENT_SOURCE_DIR@/examples/miral-shell \ 1955 @CMAKE_CURRENT_SOURCE_DIR@/include \ 1956 @MIR_GENERATED_INCLUDE_DIRECTORIES_FLATTENED@ 1957 1958 @@ -859,7 +860,9 @@ 1959 # Note that relative paths are relative to the directory from which doxygen is 1960 # run. 1961 1962 -EXCLUDE = 1963 +EXCLUDE = @CMAKE_CURRENT_SOURCE_DIR@/include/server \ 1964 + @CMAKE_CURRENT_SOURCE_DIR@/include/platform \ 1965 + @CMAKE_CURRENT_SOURCE_DIR@/include/platforms 1966 1967 # The EXCLUDE_SYMLINKS tag can be used to select whether or not files or 1968 # directories that are symbolic links (a Unix file system feature) are excluded 1969 @@ -875,7 +878,11 @@ 1970 # Note that the wildcards are matched against the file with absolute path, so to 1971 # exclude all test directories for example use the pattern */test/* 1972 1973 -EXCLUDE_PATTERNS = */include/test/* 1974 +EXCLUDE_PATTERNS = *.capnp.c++ \ 1975 + */detail/* \ 1976 + @CMAKE_CURRENT_SOURCE_DIR@/examples/multi_stream.cpp \ 1977 + @CMAKE_CURRENT_SOURCE_DIR@/examples/uses_non_client_symbol.cpp \ 1978 + @CMAKE_CURRENT_SOURCE_DIR@/examples/miral-shell/titlebar_config.* 1979 1980 # The EXCLUDE_SYMBOLS tag can be used to specify one or more symbol names 1981 # (namespaces, classes, functions, etc.) that should be excluded from the 1982 1983 === removed file 'doc/building_source_for_pc.md' 1984 --- doc/building_source_for_pc.md 2017-05-08 03:04:26 +0000 1985 +++ doc/building_source_for_pc.md 1970-01-01 00:00:00 +0000 1986 @@ -1,101 +0,0 @@ 1987 -Building the source for a PC {#building_source_for_pc} 1988 -============================ 1989 - 1990 -Getting Mir 1991 ------------ 1992 - 1993 -Mir is a project on Launchpad (https://launchpad.net/mir). To grab a copy use 1994 -the command: 1995 - 1996 - $bzr branch lp:mir 1997 - 1998 -The command above will download the latest development version of Mir into 1999 -the 'mir' directory (called the 'project directory' from now on). 2000 - 2001 -Getting dependencies 2002 --------------------- 2003 - 2004 -To succesfully build Mir there are a few packages required. The easiest way 2005 -to get them is to use the packaging build dependencies: 2006 - 2007 -$ sudo apt-get install devscripts equivs cmake 2008 - 2009 -Then, in the project directory: 2010 - 2011 - $sudo mk-build-deps -i 2012 - 2013 - 2014 -Building Mir 2015 ------------- 2016 - 2017 -Mir is built using CMake. You first need to create the build directory and 2018 -configure the build. In the project directory do: 2019 - 2020 -$ mkdir build 2021 - $cd build 2022 -$ cmake .. (possibly passing configuration options to CMake) 2023 - 2024 -There are many configuration options for the Mir project. The default options 2025 -will work fine, but you may want to customize the build depending on your 2026 -needs. The best way to get an overview and set them is to use the cmake-gui 2027 -tool: 2028 - 2029 - $cmake-gui .. 2030 - 2031 -The next step is to build the source and run the tests: 2032 - 2033 -$ make (-j8) 2034 - $ctest 2035 - 2036 - 2037 -Running Mir 2038 ------------ 2039 - 2040 -The binaries created in the bin subdirectory of the project directory can be 2041 -used directly. For example, 2042 - 2043 -$ bin/mir_demo_server --launch-client bin/mir_demo_client_multiwin 2044 - 2045 -Other examples described elsewhere in this documentation assume you're using the 2046 -installed version and simply need "bin/" adding to specify the local build. 2047 - 2048 - 2049 -Install Mir 2050 ------------ 2051 - 2052 -*It should not be necessary to install Mir for experimental purposes (see 2053 -"Running Mir" above).* Further, if you are using an Ubuntu derived disto then 2054 -there's likely to be existing Mir binaries elsewhere that may interact badly 2055 -with a second install. 2056 - 2057 -To install Mir just use the normal make install command: 2058 - 2059 - $sudo make install 2060 - 2061 -This will install the Mir libraries, executable, example clients and header 2062 -files to the configured installation location (/usr/local by default). 2063 - 2064 -NB You may need "sudo ldconfig" to refresh the cache before the installed 2065 -programs work. 2066 - 2067 -If you install to a non-standard location, keep in mind that you will probably 2068 -need to properly set the PKG_CONFIG_PATH environment variable to allow other 2069 -applications to build against Mir, and LD_LIBRARY_PATH to allow applications to 2070 -find the Mir libraries at runtime. 2071 - 2072 - 2073 -Building Mesa 2074 -------------- 2075 - 2076 -*The Mesa packages shipped with Ubuntu are already built with the relevant Mir patches 2077 -and should work out of the box with Mir.* 2078 - 2079 -For GL accelerated clients to use Mir they need to use a patched version of Mesa 2080 -that supports Mir. 2081 - 2082 -The patch is hosted on GitHub: 2083 - 2084 -$ git clone https://github.com/RAOF/mesa.git 2085 - 2086 -Compile as per normal instructions and pass --with-egl-platforms="mir,drm" to 2087 -the configure options. You will need libmirclient installed as shown above. 2088 2089 === removed file 'doc/demo_server_controls.md' 2090 --- doc/demo_server_controls.md 2017-05-08 03:04:26 +0000 2091 +++ doc/demo_server_controls.md 1970-01-01 00:00:00 +0000 2092 @@ -1,69 +0,0 @@ 2093 -Demo Server {#demo_server} 2094 -=========== 2095 - 2096 -Mir's demo server (mir_demo_server) is an example of using the Mir to 2097 -build a server. It uses only functionality supported by the public Mir API. 2098 - 2099 -Running Demo Server 2100 -------------------- 2101 - 2102 -Remember to always run mir_demo_server as root on PC (not required on 2103 -Android), as this is required for input device support (open bug 2104 -https://bugs.launchpad.net/mir/+bug/1286252); 2105 - 2106 - sudo mir_demo_server 2107 - 2108 -And if you're not already on the VT you wish to use, that needs to be 2109 -specified: 2110 - 2111 - sudo mir_demo_server --vt 1 2112 - 2113 -There are plenty more options available if you run: 2114 - 2115 - mir_demo_server --help 2116 - 2117 -The following operations are supported: 2118 - 2119 - - Quit (shut down the Mir server): *Ctrl-Alt-Backspace* 2120 - - Switch back to X: *Ctrl-Alt-F7* 2121 - - Switch virtual terminals (VTs): *Ctrl-Alt-(F1-F12)* 2122 - - Switch apps: *Alt-Tab*, tap or click on the corresponding app 2123 - - Close app: *Alt-F4* 2124 - - Switch window within app: *Alt-*, tap or click on the window 2125 - - Close surface: *Ctrl-F4* 2126 - - Move window: *Alt-leftmousebutton* drag 2127 - - Resize window: *Alt-middle_button* drag 2128 - - Maximize/restore current window: *Alt-F11* 2129 - - Vertically maximize/restore current window: *Shift-F11* 2130 - - Horizontally maximize/restore current window: *Ctrl-F11* 2131 - 2132 -For those writing client code request to set the surface attribute 2133 -mir_surface_attrib_state are honoured: 2134 - - mir_window_state_restored: restores the window 2135 - - mir_window_state_maximized: maximizes size 2136 - - mir_window_state_vertmaximized: maximizes height 2137 - - mir_window_state_horizmaximized: maximizes width 2138 - 2139 -For a quick demo try: 2140 - 2141 - sudo DISPLAY= mir_demo_server --vt 1 --launch bin/mir_demo_client_egltriangle\ 2142 - --test-client bin/mir_demo_client_multiwin --test-timeout 60 2143 - 2144 -(Remember to unwrap the line) 2145 - 2146 -### Tiling Window Manager 2147 - 2148 -One option that needs elaboration is "--window-manager tiling". 2149 - 2150 -This starts a (rather primitive) tiling window manager. It tracks the available 2151 -displays and splits the available workspace into "tiles" (one per client). 2152 - 2153 -For a quick demo try: 2154 - 2155 - sudo DISPLAY= mir_demo_server --vt 1 --launch bin/mir_demo_client_egltriangle\ 2156 - --test-client bin/mir_demo_client_multiwin --test-timeout 60\ 2157 - --window-manager tiling 2158 - 2159 -(Remember to unwrap the line) 2160 - 2161 -Want more? Log your requests at: https://bugs.launchpad.net/mir/+filebug 2162 2163 === removed file 'doc/demo_shell_controls.md' 2164 --- doc/demo_shell_controls.md 2016-01-29 08:18:22 +0000 2165 +++ doc/demo_shell_controls.md 1970-01-01 00:00:00 +0000 2166 @@ -1,53 +0,0 @@ 2167 -Demo Shell Controls {#demo_shell_controls} 2168 -=================== 2169 - 2170 -Mir's demo shell (mir_proving_server) is a basic environment for testing 2171 -Mir server features as well as running natively ported apps/toolkits. It is 2172 -still primitive and requires some explaining to make proper use of, so read 2173 -on. 2174 - 2175 -Running Demo Shell 2176 ------------------- 2177 - 2178 -Remember to always run mir_proving_server as root on PC (not required on 2179 -Android), as this is required for input device support (open bug 2180 -https://bugs.launchpad.net/mir/+bug/1286252); 2181 - 2182 - sudo mir_proving_server 2183 - 2184 -And if you're not already on the VT you wish to use, that needs to be 2185 -specified: 2186 - 2187 - sudo mir_proving_server --vt 1 2188 - 2189 -There are plenty more options available if you run: 2190 - 2191 - mir_proving_server --help 2192 - 2193 -Controls 2194 --------- 2195 - 2196 -All controls have a keyboard/mouse combination and where possible also have 2197 -touch alternatives for phones/tablets: 2198 - 2199 - - Quit the shell (shut down the Mir server): *Ctrl-Alt-Backspace* 2200 - - Switch back to X: *Ctrl-Alt-F7* 2201 - - Switch virtual terminals (VTs): *Ctrl-Alt-(F1-F12)* 2202 - - Switch apps: *Alt-Tab* or *4-finger swipe left/right* 2203 - - Switch windows of the current app: *Alt-grave* 2204 - - Ask an app to close: *Alt-F4* (it may refuse or not understand) 2205 - - Move window: *Alt-leftmousebutton* or *3-finger drag* 2206 - - Resize window: *Alt-middlemousebutton* or *3-finger pinch/zoom* 2207 - - Toggle negative rendering: *Super-N* 2208 - - Toggle high-contrast rendering: *Super-C* 2209 - - Sleep/wake all displays: *Alt-P* or *Android power button* 2210 - - Rotate the focussed monitor: *Ctrl-Alt-(Left/Right/Up/Down)* or 2211 - *Volume up/down while touching the screen* 2212 - - Change display mode of the focussed monitor: *Ctrl-Alt-(=/-)* 2213 - - Reset display mode to default, on focussed monitor: *Ctrl-Alt-0* 2214 - - Adjust window opacity/alpha: *Alt-mousewheel* 2215 - - Zoom in/out: *Super-mousewheel* 2216 - 2217 -*Super* means the Windows key on a PC, or the search key on a Chromebook. 2218 - 2219 -Want more? Log your requests at: https://bugs.launchpad.net/mir/+filebug 2220 2221 === added file 'doc/getting_and_using_mir.md' 2222 --- doc/getting_and_using_mir.md 1970-01-01 00:00:00 +0000 2223 +++ doc/getting_and_using_mir.md 2017-10-11 15:01:23 +0000 2224 @@ -0,0 +1,106 @@ 2225 +Getting and Using Mir {#getting_and_using_mir} 2226 +===================== 2227 + 2228 +Getting Mir examples 2229 +-------------------- 2230 + 2231 +You can install the Mir examples as follows: 2232 + 2233 + $sudo apt install mir-demos qterminal 2234 +$ sudo apt install mir-graphics-drivers-desktop qtubuntu-desktop 2235 + 2236 +Using Mir examples 2237 +------------------ 2238 + 2239 +For convenient testing there's a "miral-app" script that wraps the commands used 2240 +to start a server and then launches a terminal (as the current user): 2241 + 2242 + $miral-app 2243 + 2244 +To run independently of X11 you need to grant access to the graphics hardware 2245 +(by running as root) and specify a VT to run in. There's a "miral-desktop" 2246 +script that wraps to start the server (as root) and then launch a terminal 2247 +(as the current user): 2248 + 2249 +$ miral-desktop 2250 + 2251 +For more options see *Options when running the Mir example shell* below. 2252 + 2253 +### Running applications on Mir 2254 + 2255 +If you use the command-line launched by miral-app or miral-desktop native Mir 2256 +applications (which include native Mir clients and those that use SDL or the 2257 +GTK+, Qt toolkits) can be started as usual: 2258 + 2259 + $mir_demo_client_egltriangle 2260 +$ gedit 2261 + $sudo apt install kate neverball 2262 +$ kate 2263 + $neverball 2264 + 2265 +From outside the MirAL session GTK+, Qt and SDL applications can still be run 2266 +using the miral-run script: 2267 + 2268 +$ miral-run gedit 2269 + $miral-run 7kaa 2270 + 2271 +### Running for X11 applications 2272 + 2273 +If you want to run X11 applications that do not have native Mir support in the 2274 +toolkit they use then the answer is Xmir: an X11 server that runs on Mir. First 2275 +you need Xmir installed: 2276 + 2277 +$ sudo apt install xmir 2278 + 2279 +Then once you have started a miral shell (as above) you can use miral-xrun to 2280 +run applications under Xmir: 2281 + 2282 + $miral-xrun firefox 2283 + 2284 +This automatically starts a Xmir X11 server on a new$DISPLAY for the 2285 +application to use. You can use miral-xrun both from a command-line outside the 2286 +miral-shell or, for example, from the terminal running in the shell. 2287 + 2288 +### Options when running the Mir example shell 2289 + 2290 +#### Script Options 2291 + 2292 +Both the "miral-app" and "miral-desktop" scripts provide options for using an 2293 +alternative example shell (miral-kiosk) and an alternative to gnome-terminal. 2294 + 2295 + -kiosk use miral-kiosk instead of miral-shell 2296 + -launcher use instead of qterminal 2297 + 2298 +In addition miral-desktop has the option to set the VT that is used: 2299 + 2300 + -vt set the virtual terminal [4] 2301 + 2302 +There are some additional options (listed with "-h") but those are the important 2303 +ones. 2304 + 2305 +#### miral-shell Options 2306 + 2307 +The scripts can also be used to pass options to Mir: they pass everything on 2308 +the command-line following the first thing they don't understand. These can be 2309 +listed by miral-shell --help. Most of these options are inherited from Mir, 2310 +but the following MirAL specific are likely to be of interest: 2311 + 2312 + --window-management-trace log trace message 2313 + 2314 +Probably the main use for MirAL is to test window-management (either of a 2315 +toolkit or of a server) and this logs all calls to and from the window 2316 +management policy. This option is supported directly in the MirAL library and 2317 +works for any MirAL based shell - even one you write yourself. 2318 + 2319 + --keymap arg (=us) keymap [+[+]] 2320 + , e,g, "gb" or "cz+qwerty" or 2321 + "de++compose:caps" 2322 + 2323 +For those of us not in the USA this is very useful. Both the -shell and -kiosk 2324 +examples support this option. 2325 + 2326 + --window-manager arg (=floating) window management strategy 2327 + [{floating|tiling|system-compositor}] 2328 + 2329 +Is only supported by miral-shell and its main use is to allow an alternative 2330 +"tiling" window manager to be selected. 2331 2332 === added file 'doc/getting_involved_in_mir.md' 2333 --- doc/getting_involved_in_mir.md 1970-01-01 00:00:00 +0000 2334 +++ doc/getting_involved_in_mir.md 2017-10-11 15:01:23 +0000 2335 @@ -0,0 +1,106 @@ 2336 +Getting Involved in Mir {#getting_involved_in_mir} 2337 +======================= 2338 + 2339 +Getting involved 2340 +---------------- 2341 + 2342 +The best place to ask questions and discuss about the Mir project is 2343 +the \#ubuntu-mir IRC channel on freenode. 2344 + 2345 +The Mir project is hosted on Launchpad: https://launchpad.net/mir 2346 + 2347 +Building Mir 2348 +------------ 2349 + 2350 +These instructions assume that you’re using Ubuntu 16.04LTS or later, I’ve not 2351 +earlier Ubuntu versions or other distributions. 2352 + 2353 +You’ll need a few development and utility packages installed, along with the 2354 +Mir graphics drivers: 2355 + 2356 + $sudo apt install devscripts equivs bzr 2357 +$ sudo apt install mir-graphics-drivers-desktop 2358 + 2359 +If you’re working on a phone or tablet use mir-graphics-drivers-android in 2360 +place of mir-graphics-drivers-desktop. (See \ref building_source_for_arm for 2361 +more on this.) 2362 + 2363 +With these installed you can checkout and build Mir: 2364 + 2365 + $bzr branch lp:mir 2366 +$ sudo mk-build-deps -i 2367 + $mkdir mir/build 2368 +$ cd mir/build 2369 + $cmake .. 2370 +$ make 2371 + 2372 +This creates an example shell (miral-shell) in the bin directory. This can be 2373 +run directly: 2374 + 2375 + $bin/miral-shell 2376 + 2377 +With the default options this runs in a window on X (which is convenient for 2378 +development). 2379 + 2380 +The miral-shell example is simple, don’t expect to see a sophisticated launcher 2381 +by default. You can start mir apps from the command-line. For example: 2382 + 2383 +$ bin/miral-run gnome-terminal 2384 + 2385 +That’s right, a lot of standard GTK+ applications will “just work” (the GDK 2386 +toolkit has a Mir backend). Any that assume the existence of an X11 and bypass 2387 +the toolkit my making X11 protocol calls will have problems though. 2388 + 2389 +To exit from miral-shell press Ctrl-Alt-BkSp. 2390 + 2391 +You can install the Mir examples, headers and libraries you've built with: 2392 + 2393 + $sudo make install 2394 + 2395 +### Preparing a VM to run Mir 2396 + 2397 +Especially if you want to debug the shell without locking your system this might be a helpful setup: 2398 + 2399 +- \ref setup_kvm_for_mir 2400 +- \ref setup_vmware_for_mir 2401 + 2402 +### Contributing to Mir 2403 + 2404 +Currently, the Mir code activity is performed on a development branch: 2405 +lp:~mir-team/mir/development-branch 2406 + 2407 +This development branch is promoted to the branch used for the ubuntu archive 2408 +and touch images. Please submit any merge proposals against the development 2409 +branch. 2410 + 2411 +Please file bug reports at: https://bugs.launchpad.net/mir 2412 + 2413 +The Mir development mailing list can be found at: https://lists.ubuntu.com/mailman/listinfo/Mir-devel 2414 + 2415 +The Mir coding guidelines are [here](cppguide/index.html). 2416 + 2417 +### Working on Mir code 2418 + 2419 + - \ref md_README "Mir Read me" 2420 + - \ref md_HACKING "Mir hacking guide" 2421 + - \ref component_reports 2422 + - \ref dso_versioning_guide 2423 + - \ref abi_compatibility_tools 2424 + - \ref performance_framework 2425 + - \ref latency "Measuring visual latency" 2426 + 2427 +Building Mesa 2428 +------------- 2429 + 2430 +*The Mesa packages shipped with Ubuntu are already built with the relevant Mir patches 2431 +and should work out of the box with Mir.* 2432 + 2433 +For GL accelerated clients to use Mir they need to use a patched version of Mesa 2434 +that supports Mir. 2435 + 2436 +The patch is hosted on GitHub: 2437 + 2438 +$ git clone https://github.com/RAOF/mesa.git 2439 + 2440 +Compile as per normal instructions and pass --with-egl-platforms="mir,drm" to 2441 +the configure options. You will need libmirclient installed as shown above. 2442 2443 === removed file 'doc/installing_prebuilt_on_pc.md' 2444 --- doc/installing_prebuilt_on_pc.md 2016-01-29 08:18:22 +0000 2445 +++ doc/installing_prebuilt_on_pc.md 1970-01-01 00:00:00 +0000 2446 @@ -1,8 +0,0 @@ 2447 -Installing pre-built packages on a PC {#installing_prebuilt_on_pc} 2448 -===================================== 2449 - 2450 -Install Ubuntu 13.10 or later if you haven't done so already. Uninstall any 2451 -proprietary drivers (-nvidia, -fglrx) and reboot on the FOSS drivers. 2452 - 2453 - sudo apt-get update 2454 - sudo apt-get install mir-demos 2455 2456 === added file 'doc/introducing_the_miral_api.md' 2457 --- doc/introducing_the_miral_api.md 1970-01-01 00:00:00 +0000 2458 +++ doc/introducing_the_miral_api.md 2017-10-11 15:01:23 +0000 2459 @@ -0,0 +1,25 @@ 2460 +Introducing the Miral API {#introducing_the_miral_api} 2461 +========================= 2462 + 2463 +The main() program 2464 +------------------ 2465 + 2466 +The main() program from miral-shell looks like this: 2467 + 2468 +\include shell_main.cpp 2469 + 2470 +This shell is providing FloatingWindowManagerPolicy, TilingWindowManagerPolicy 2471 +and SpinnerSplash. The rest is from MirAL. 2472 + 2473 +If you look for the corresponding code in lp:qtmir and lp:mir you’ll find it 2474 +less clear, more verbose and scattered over multiple files. 2475 + 2476 +A shell has to provide a window management policy (miral-shell provides two: 2477 +FloatingWindowManagerPolicy and TilingWindowManagerPolicy). A window management 2478 +policy needs to implement the \ref miral::WindowManagementPolicy interface for 2479 +handling a set of window management events. 2480 + 2481 +The way these events are handled determines the behaviour of the shell. 2482 + 2483 +The \ref miral::WindowManagerTools interface provides the principle methods for 2484 +a window management policy to control Mir. 2485 2486 === modified file 'doc/mainpage.md' 2487 --- doc/mainpage.md 2017-05-08 03:04:26 +0000 2488 +++ doc/mainpage.md 2017-10-11 15:01:23 +0000 2489 @@ -3,104 +3,66 @@ 2490 2491 Mir is a next generation display server targeted as a replacement for the X 2492 window server system to unlock next-generation user experiences for devices 2493 -ranging from Linux desktop to mobile devices powered by Ubuntu. The primary 2494 -purpose of Mir is to enable the development of the next generation 2495 -[Unity](http://unity.ubuntu.com). 2496 +ranging from Linux desktop to mobile and IoT devices powered by Ubuntu. 2497 + 2498 + - If you want to use the Mir snaps, see: 2499 + [Run a kiosk snap on Ubuntu Core](https://developer.ubuntu.com/core/examples/snaps-on-mir) 2500 + 2501 + - If you want to try out the Mir demos on desktop, see: \ref getting_and_using_mir 2502 + 2503 + - If you want to get involved in Mir development, see: \ref getting_involved_in_mir 2504 + 2505 +Using Mir for client development 2506 +-------------------------------- 2507 + 2508 +This is usually something you don't need to do explicitly, it is normally 2509 +handled by a GUI toolkit (or library). 2510 + 2511 +A toolkit can run on Mir in three ways: using Wayland protocols, using the Mir 2512 +client API or using X11 translation by the Xmir server. 2513 + 2514 + - Qt, has "wayland" and "mir" plugins that can be selected by setting 2515 + the QT_QPA_PLATFORM environment variable to "wayland" or "ubuntumirclient" 2516 + respectively. 2517 + 2518 + - SDL can be built with "wayland" and "mir" support and these options selected 2519 + by setting the SDL_VIDEODRIVER environment variable to "wayland" or "mir". 2520 + 2521 +If want to use the Mir client library directly (e.g. you are working on "mir" 2522 +support for a toolkit or library) Install the headers and libraries for using 2523 +libmirclient in development: 2524 + 2525 + $sudo apt install libmirclient-dev 2526 + 2527 +A miral.pc file is provided for use with pkg-config or other tools. For 2528 +example: 2529 + 2530 +$ pkg-config --cflags mirclient 2531 + 2532 +The client API documentation is here: \ref mir_toolkit 2533 + 2534 +Using Mir for server development 2535 +-------------------------------- 2536 + 2537 +Install the headers and libraries for using libmiral in development: 2538 + 2539 + $sudo apt install libmiral-dev 2540 + 2541 +A miral.pc file is provided for use with pkg-config or other tools. For 2542 +example: 2543 + 2544 +$ pkg-config --cflags miral 2545 + 2546 +The server API is introduced here: \ref introducing_the_miral_api 2547 + 2548 +The Mir Documentation 2549 +--------------------- 2550 + 2551 +The Mir documentation can be installed and read like this: 2552 + 2553 + $sudo apt install mir-doc 2554 +$ xdg-open /usr/share/doc/mir-doc/html/index.html 2555 2556 More detailed information about the motivation, scope, and high-level design 2557 of Mir can be found at http://wiki.ubuntu.com/MirSpec . 2558 2559 -Getting and installing Mir 2560 --------------------------- 2561 - 2562 -### Using pre-built packages 2563 - 2564 -If you just want to try out mir, or write client applications, then the easiest 2565 -way is to use the pre-built packages: 2566 - 2567 - - \ref installing_prebuilt_on_pc 2568 - 2569 -### Building and installing from source 2570 - 2571 -If you are curious about Mir internals or intend to contribute to it, you should 2572 -get the source and build it: 2573 - 2574 - - \ref building_source_for_pc 2575 - - \ref building_source_for_arm 2576 - 2577 -### Preparing a VM to run Mir 2578 - 2579 -Especially if you want to debug the shell without locking your system this might be a helpful setup: 2580 - 2581 -- \ref setup_kvm_for_mir 2582 -- \ref setup_vmware_for_mir 2583 - 2584 -Using Mir 2585 ---------- 2586 - 2587 - - \ref using_mir_on_pc 2588 - - \ref demo_shell_controls 2589 - - \ref demo_server 2590 - 2591 -Getting involved 2592 ----------------- 2593 - 2594 -The best place to ask questions and discuss about the Mir project is 2595 -the \#ubuntu-mir IRC channel on freenode. 2596 - 2597 -The Mir project is hosted on Launchpad: https://launchpad.net/mir 2598 - 2599 -Currently, the Mir code activity is performed on a development branch: 2600 -lp:~mir-team/mir/development-branch 2601 - 2602 -Approximately fortnightly, this development branch is promoted to the branch 2603 -used for the ubuntu archive and touch images. Please submit any merge proposals 2604 -against the development branch. 2605 - 2606 -Please file bug reports at: https://bugs.launchpad.net/mir 2607 - 2608 -The Mir development mailing list can be found at: https://lists.ubuntu.com/mailman/listinfo/Mir-devel 2609 - 2610 -The Mir coding guidelines are [here](cppguide/index.html). 2611 - 2612 -Writing client applications 2613 ---------------------------- 2614 - 2615 - - \ref mir_toolkit "Mir API Documentation" 2616 - - \subpage basic.c "basic.c: A basic Mir client (which does nothing)" 2617 - 2618 -Writing server applications 2619 ---------------------------- 2620 - 2621 -Mir server is written as a library which allows the server code to be adapted 2622 -for bespoke applications. 2623 - 2624 - - \subpage server_example.cpp 2625 - "server_example.cpp: a test executable hosting the following" 2626 - - \subpage server_example_input_event_filter.cpp 2627 - "server_example_input_event_filter.cpp: provide a Quit command" 2628 - - \subpage server_example_display_configuration_policy.cpp 2629 - "server_example_display_configuration_policy.cpp: configuring display layout" 2630 - - \subpage server_example_input_filter.cpp 2631 - "server_example_input_filter.cpp: print input events to stdout" 2632 - - \subpage server_example_log_options.cpp 2633 - "server_example_log_options.cpp: replace Mir logger with glog" 2634 - - \subpage server_example_basic_window_manager.h 2635 - "server_example_basic_window_manager.h: How to wire up a window manager" 2636 - - \subpage server_example_window_management.cpp 2637 - "server_example_window_management.cpp: simple window management examples" 2638 - - \subpage server_example_canonical_window_manager.cpp 2639 - "server_example_canonical_window_manager.cpp: canonical window management policy" 2640 - - \subpage server_example_custom_compositor.cpp 2641 - "server_example_custom_compositor.cpp: demonstrate writing an alternative GL rendering code" 2642 - 2643 -Working on Mir code 2644 -------------------- 2645 - 2646 - - \ref md_README "Mir Read me" 2647 - - \ref md_HACKING "Mir hacking guide" 2648 - - \ref component_reports 2649 - - \ref dso_versioning_guide 2650 - - \ref abi_compatibility_tools 2651 - - \ref performance_framework 2652 - - \ref latency "Measuring visual latency" 2653 2654 === removed file 'doc/using_mir_on_pc.md' 2655 --- doc/using_mir_on_pc.md 2016-01-29 08:18:22 +0000 2656 +++ doc/using_mir_on_pc.md 1970-01-01 00:00:00 +0000 2657 @@ -1,91 +0,0 @@ 2658 -Using Mir on a PC {#using_mir_on_pc} 2659 -================= 2660 - 2661 -Before you begin 2662 ----------------- 2663 - 2664 -Make sure your hardware is supported. That means you're using a Mesa driver, 2665 -of which intel, radeon, and nouveau families are supported. If you're logged 2666 -in to X then run this command to verify an appropriate DRI driver is active: 2667 - 2668 - sudo pmap pidof X | grep dri.so 2669 - 2670 -or 2671 - 2672 - lsmod | grep drm 2673 - 2674 -Before you can use Mir you need to ensure you have the proper custom Mesa 2675 -build installed. If you are running Ubuntu 13.10 or later 2676 -(see \ref installing_prebuilt_on_pc), you should be good to go. 2677 - 2678 -If you built Mir from source code (see \ref building_source_for_pc), you 2679 -need to ensure you are using the proper Mesa at runtime. You can do that by 2680 -installing the Mesa packages from Ubuntu 13.10 (or later) or by building the 2681 -custom Mesa yourself and ensuring it can be found by Mir, e.g., by using 2682 -LD_LIBRARY_PATH. 2683 - 2684 -### Getting some example client applications 2685 - 2686 -You can get some example programs by installing the mir-demos package: 2687 - 2688 - $sudo apt-get install mir-demos 2689 - 2690 -If you are building from source you can find client applications in the bin/ 2691 -subdirectory of the build directory. 2692 - 2693 -Running Mir 2694 ------------ 2695 - 2696 -Mir can run run either natively on mesa-kms or as an X application. 2697 - 2698 -### Running Mir on X 2699 - 2700 -To run Mir as an X client start it from an X terminal: 2701 - 2702 -$ mir_demo_server --launch-client mir_demo_client_multiwin 2703 - 2704 -You can start additional Mir clients, for example (in a new terminal): 2705 - 2706 - $mir_demo_egltriangle 2707 - 2708 -To exit from Mir: 2709 - 2710 - 2711 - 2712 -Note: up to Mir 0.18 it is also necessary to specify --platform-input-lib when 2713 -starting the server: 2714 - - for Mir-0.17 add: --platform-input-lib server-mesa-x11.so.6 2715 - - for Mir-0.18 add: --platform-input-lib server-mesa-x11.so.7 2716 - 2717 -### Running Mir natively 2718 - 2719 -To run Mir natively on a PC/desktop/laptop: 2720 - 2721 -$ sudo DISPLAY= mir_demo_server --vt 1 --arw-file 2722 - 2723 -This will switch you to a Mir session on VT1. Switch back to your X-based 2724 -desktop: 2725 - 2726 - 2727 - 2728 -In a new terminal: 2729 - 2730 - $mir_demo_client_multiwin -m /tmp/mir_socket 2731 - 2732 -Switch back to Mir. 2733 - 2734 - 2735 - 2736 -Watch your friends be amazed! 2737 - 2738 -To exit from Mir: 2739 - 2740 - 2741 - 2742 -In case you accidentally killed your X login and ended up with a failsafe 2743 -screen, you might find on subsequent reboots you can't log in to X at all any 2744 -more (it instantly and silently takes you back to the login screen). The fix 2745 -for this is to log in to a VT and: 2746 - 2747 -$ rm .Xauthority 2748 - $sudo restart lightdm 2749 2750 === modified file 'examples/CMakeLists.txt' 2751 --- examples/CMakeLists.txt 2017-06-06 16:26:18 +0000 2752 +++ examples/CMakeLists.txt 2017-10-11 15:01:23 +0000 2753 @@ -1,14 +1,5 @@ 2754 -mir_add_wrapped_executable(mir_demo_standalone_render_surfaces 2755 - render_surfaces.cpp 2756 - buffer_render_target.cpp 2757 - image_renderer.cpp 2758 -) 2759 - 2760 -target_link_libraries(mir_demo_standalone_render_surfaces 2761 - mirserver 2762 - exampleserverconfig 2763 -${Boost_LIBRARIES} 2764 -) 2765 +add_subdirectory(miral-kiosk) 2766 +add_subdirectory(miral-shell) 2767 2768 set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -std=c99 -Wall -fno-strict-aliasing -Wextra") 2769 2770 @@ -18,26 +9,17 @@ 2771 ) 2772 2773 add_library(exampleserverconfig STATIC 2774 - server_example_basic_window_manager.cpp 2775 - server_example_basic_window_manager.h 2776 - server_example_canonical_window_manager.cpp 2777 - server_example_display_configuration_policy.cpp 2778 server_example_input_device_config.cpp 2779 server_example_input_event_filter.cpp 2780 server_example_log_options.cpp 2781 server_example_input_filter.cpp 2782 server_example_host_lifecycle_event.cpp 2783 - server_example_window_management.cpp 2784 server_example_custom_compositor.cpp 2785 server_example_adorning_compositor.cpp 2786 - server_example_cursor_images.cpp 2787 - server_example_cursor_images.h 2788 - xcursor_loader.cpp 2789 - xcursor_loader.h 2790 - xcursor.c 2791 - xcursor.h 2792 ) 2793 2794 +target_link_libraries(exampleserverconfig mirserver) 2795 + 2796 target_link_libraries(eglapp 2797 mirclient 2798${EGL_LIBRARIES} 2799 @@ -184,6 +166,7 @@ 2800 add_library(mirdraw STATIC graphics_utils.cpp) 2801 2802 include_directories( 2803 + ${PROJECT_SOURCE_DIR}/include/miral 2804${PROJECT_SOURCE_DIR}/include/server 2805 ${PROJECT_SOURCE_DIR}/include/client 2806${PROJECT_SOURCE_DIR}/include/platform 2807 @@ -192,17 +175,6 @@ 2808 ${GL_INCLUDE_DIRS} 2809 ) 2810 2811 -mir_add_wrapped_executable(mir_demo_standalone_render_to_fb 2812 - render_to_fb.cpp 2813 -) 2814 - 2815 -target_link_libraries(mir_demo_standalone_render_to_fb 2816 - mirserver 2817 - mirdraw 2818 -${GL_LIBRARIES} 2819 - ${Boost_LIBRARIES} 2820 -) 2821 - 2822 add_library(mir_demo_server_loadable MODULE 2823 server_example.cpp 2824 glog_logger.cpp 2825 @@ -210,7 +182,8 @@ 2826 ) 2827 2828 target_link_libraries(mir_demo_server_loadable 2829 - mirserver 2830 + miral-shell-lib 2831 + miral 2832 exampleserverconfig 2833${GLog_LIBRARY} 2834 ${GFlags_LIBRARY} 2835 @@ -229,9 +202,6 @@ 2836 dl 2837 ) 2838 2839 -mir_add_wrapped_executable(mir_demo_server_minimal server_minimal.cpp) 2840 -target_link_libraries(mir_demo_server_minimal mirserver) 2841 - 2842 if (MIR_ENABLE_TESTS) 2843 add_executable(mir_symbol_test 2844 uses_non_client_symbol.cpp 2845 @@ -268,15 +238,6 @@ 2846 endif () 2847 endif () 2848 2849 -add_executable(mir_cursor_theme_dump 2850 - cursor-theme-dump.cpp 2851 -) 2852 - 2853 -target_link_libraries(mir_cursor_theme_dump 2854 - exampleserverconfig 2855 - mirserver 2856 -) 2857 - 2858 mir_add_wrapped_executable(mir_demo_client_multistream 2859 multi_stream.cpp 2860 ) 2861 @@ -313,6 +274,15 @@ 2862 mirclient 2863 ) 2864 2865 +include_directories(${MIR_GENERATED_INCLUDE_DIRECTORIES}) 2866 + 2867 +mir_add_wrapped_executable(mir_demo_client_wayland wayland_client.c) 2868 +target_link_libraries(mir_demo_client_wayland 2869 + 2870 + ${WAYLAND_CLIENT_LIBRARIES} 2871 +) 2872 + 2873 mir_add_wrapped_executable(mir_demo_client_screencast screencast.cpp) 2874 2875 target_link_libraries(mir_demo_client_screencast mirclient) 2876 + 2877 2878 === modified file 'examples/animated_cursor_demo_client.c' 2879 --- examples/animated_cursor_demo_client.c 2017-05-19 13:51:47 +0000 2880 +++ examples/animated_cursor_demo_client.c 2017-10-11 15:01:23 +0000 2881 @@ -2,7 +2,7 @@ 2882 * Copyright © 2015 Canonical LTD 2883 * 2884 * This program is free software: you can redistribute it and/or modify 2885 - * it under the terms of the GNU General Public License version 3 as 2886 + * it under the terms of the GNU General Public License version 2 or 3 as 2887 * published by the Free Software Foundation. 2888 * 2889 * This program is distributed in the hope that it will be useful, 2890 2891 === modified file 'examples/as_render_target.h' 2892 --- examples/as_render_target.h 2015-10-01 08:58:30 +0000 2893 +++ examples/as_render_target.h 2017-10-11 15:01:23 +0000 2894 @@ -2,7 +2,7 @@ 2895 * Copyright © 2015 Canonical Ltd. 2896 * 2897 * This program is free software: you can redistribute it and/or modify 2898 - * it under the terms of the GNU General Public License version 3 as 2899 + * it under the terms of the GNU General Public License version 2 or 3 as 2900 * published by the Free Software Foundation. 2901 * 2902 * This program is distributed in the hope that it will be useful, 2903 2904 === modified file 'examples/basic.c' 2905 --- examples/basic.c 2017-05-19 13:49:04 +0000 2906 +++ examples/basic.c 2017-10-11 15:01:23 +0000 2907 @@ -2,7 +2,7 @@ 2908 * Copyright © 2012 Canonical Ltd. 2909 * 2910 * This program is free software: you can redistribute it and/or modify 2911 - * it under the terms of the GNU General Public License version 3 as 2912 + * it under the terms of the GNU General Public License version 2 or 3 as 2913 * published by the Free Software Foundation. 2914 * 2915 * This program is distributed in the hope that it will be useful, 2916 @@ -41,16 +41,12 @@ 2917 /// \snippet basic.c surface_release_tag 2918 ///\subsection connection_release We release our connection 2919 /// \snippet basic.c connection_release_tag 2920 -///\subsection get the raw, platform-specific buffer handle for the current buffer 2921 -/// \snippet basic.c get_current_buffer_tag 2922 +///\subsection get graphics region for the current buffer 2923 +/// \snippet basic.c get_graphics_region_tag 2924 /// \example basic.c A simple mir client 2925 ///\section MirDemoState MirDemoState 2926 /// The handles needs to be accessible both to callbacks and to the control function. 2927 /// \snippet basic.c MirDemoState_tag 2928 -///\section Callbacks Callbacks 2929 -/// This program opens a mir connection and creates a surface. The handles 2930 -/// needs to be accessible both to callbacks and to the control function. 2931 -/// \snippet basic.c Callback_tag 2932 2933 ///\internal [MirDemoState_tag] 2934 // Utility structure for the state of a single surface session. 2935 @@ -143,11 +139,12 @@ 2936 { 2937 // We can query the current graphics buffer attributes 2938 { 2939 + ///\internal [get_graphics_region_tag] 2940 MirGraphicsRegion graphics_region; 2941 mir_buffer_stream_get_graphics_region(bs, &graphics_region); 2942 2943 - ///\internal [get_current_buffer_tag] 2944 - // In a real application we'd render into the current buffer 2945 + ///\internal [get_graphics_region_tag] 2946 + // In a real application we'd render into the graphics_region 2947 } 2948 2949 ///\internal [swap_buffers_tag] 2950 2951 === modified file 'examples/buffer_render_target.cpp' 2952 --- examples/buffer_render_target.cpp 2016-01-29 08:18:22 +0000 2953 +++ examples/buffer_render_target.cpp 2017-10-11 15:01:23 +0000 2954 @@ -2,7 +2,7 @@ 2955 * Copyright © 2012 Canonical Ltd. 2956 * 2957 * This program is free software: you can redistribute it and/or modify 2958 - * it under the terms of the GNU General Public License version 3 as 2959 + * it under the terms of the GNU General Public License version 2 or 3 as 2960 * published by the Free Software Foundation. 2961 * 2962 * This program is distributed in the hope that it will be useful, 2963 2964 === modified file 'examples/buffer_render_target.h' 2965 --- examples/buffer_render_target.h 2015-02-22 07:46:25 +0000 2966 +++ examples/buffer_render_target.h 2017-10-11 15:01:23 +0000 2967 @@ -2,7 +2,7 @@ 2968 * Copyright © 2012 Canonical Ltd. 2969 * 2970 * This program is free software: you can redistribute it and/or modify 2971 - * it under the terms of the GNU General Public License version 3 as 2972 + * it under the terms of the GNU General Public License version 2 or 3 as 2973 * published by the Free Software Foundation. 2974 * 2975 * This program is distributed in the hope that it will be useful, 2976 2977 === modified file 'examples/camera.c' 2978 --- examples/camera.c 2017-05-19 13:49:04 +0000 2979 +++ examples/camera.c 2017-10-11 15:01:23 +0000 2980 @@ -2,7 +2,7 @@ 2981 * Copyright © 2015-2016 Canonical Ltd. 2982 * 2983 * This program is free software: you can redistribute it and/or modify 2984 - * it under the terms of the GNU General Public License version 3 as 2985 + * it under the terms of the GNU General Public License version 2 or 3 as 2986 * published by the Free Software Foundation. 2987 * 2988 * This program is distributed in the hope that it will be useful, 2989 2990 === modified file 'examples/chain_jumping_buffers.c' 2991 --- examples/chain_jumping_buffers.c 2017-05-19 13:54:14 +0000 2992 +++ examples/chain_jumping_buffers.c 2017-10-11 15:01:23 +0000 2993 @@ -2,7 +2,7 @@ 2994 * Copyright © 2016 Canonical Ltd. 2995 * 2996 * This program is free software: you can redistribute it and/or modify 2997 - * it under the terms of the GNU General Public License version 3 as 2998 + * it under the terms of the GNU General Public License version 2 or 3 as 2999 * published by the Free Software Foundation. 3000 * 3001 * This program is distributed in the hope that it will be useful, 3002 3003 === modified file 'examples/client_helpers.cpp' 3004 --- examples/client_helpers.cpp 2017-06-06 14:57:41 +0000 3005 +++ examples/client_helpers.cpp 2017-10-11 15:01:23 +0000 3006 @@ -2,7 +2,7 @@ 3007 * Copyright © 2015-2017 Canonical Ltd. 3008 * 3009 * This program is free software: you can redistribute it and/or modify 3010 - * it under the terms of the GNU General Public License version 3 as 3011 + * it under the terms of the GNU General Public License version 2 or 3 as 3012 * published by the Free Software Foundation. 3013 * 3014 * This program is distributed in the hope that it will be useful, 3015 @@ -18,6 +18,8 @@ 3016 3017 #include "client_helpers.h" 3018 #include "mir_toolkit/mir_client_library.h" 3019 +#include 3020 +#include 3021 3022 namespace me = mir::examples; 3023 3024 @@ -89,6 +91,10 @@ 3025 break; 3026 } 3027 3028 + case mir_event_type_close_window: 3029 + kill(getpid(), SIGTERM); 3030 + break; 3031 + 3032 default: 3033 break; 3034 } 3035 3036 === modified file 'examples/client_helpers.h' 3037 --- examples/client_helpers.h 2017-06-06 14:57:41 +0000 3038 +++ examples/client_helpers.h 2017-10-11 15:01:23 +0000 3039 @@ -2,7 +2,7 @@ 3040 * Copyright © 2015-2017 Canonical Ltd. 3041 * 3042 * This program is free software: you can redistribute it and/or modify 3043 - * it under the terms of the GNU General Public License version 3 as 3044 + * it under the terms of the GNU General Public License version 2 or 3 as 3045 * published by the Free Software Foundation. 3046 * 3047 * This program is distributed in the hope that it will be useful, 3048 3049 === modified file 'examples/client_touch_validator.cpp' 3050 --- examples/client_touch_validator.cpp 2017-06-06 15:41:28 +0000 3051 +++ examples/client_touch_validator.cpp 2017-10-11 15:01:23 +0000 3052 @@ -4,7 +4,7 @@ 3053 * Copyright © 2015 Canonical Ltd. 3054 * 3055 * This program is free software: you can redistribute it and/or modify 3056 - * it under the terms of the GNU General Public License version 3 as 3057 + * it under the terms of the GNU General Public License version 2 or 3 as 3058 * published by the Free Software Foundation. 3059 * 3060 * This program is distributed in the hope that it will be useful, 3061 3062 === removed file 'examples/cursor-theme-dump.cpp' 3063 --- examples/cursor-theme-dump.cpp 2016-01-29 08:18:22 +0000 3064 +++ examples/cursor-theme-dump.cpp 1970-01-01 00:00:00 +0000 3065 @@ -1,127 +0,0 @@ 3066 -/* 3067 - * Copyright © 2015 Canonical Ltd. 3068 - * 3069 - * This program is free software: you can redistribute it and/or modify it 3070 - * under the terms of the GNU General Public License version 3, 3071 - * as published by the Free Software Foundation. 3072 - * 3073 - * This program is distributed in the hope that it will be useful, 3074 - * but WITHOUT ANY WARRANTY; without even the implied warranty of 3075 - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 3076 - * GNU General Public License for more details. 3077 - * 3078 - * You should have received a copy of the GNU General Public License 3079 - * along with this program. If not, see . 3080 - * 3081 - * Authored by: Alan Griffiths 3082 - */ 3083 - 3084 -#include "xcursor_loader.h" 3085 - 3086 -#include "mir/graphics/cursor_image.h" 3087 -#include 3088 - 3089 -#include 3090 - 3091 -using namespace mir::examples; 3092 -using namespace mir::geometry; 3093 - 3094 -namespace 3095 -{ 3096 -auto const cursor_names = { 3097 - mir_arrow_cursor_name, 3098 - mir_busy_cursor_name, 3099 - mir_caret_cursor_name, 3100 - mir_default_cursor_name, 3101 - mir_pointing_hand_cursor_name, 3102 - mir_open_hand_cursor_name, 3103 - mir_closed_hand_cursor_name, 3104 - mir_horizontal_resize_cursor_name, 3105 - mir_vertical_resize_cursor_name, 3106 - mir_diagonal_resize_bottom_to_top_cursor_name, 3107 - mir_diagonal_resize_top_to_bottom_cursor_name, 3108 - mir_omnidirectional_resize_cursor_name, 3109 - mir_vsplit_resize_cursor_name, 3110 - mir_hsplit_resize_cursor_name, 3111 - mir_crosshair_cursor_name }; 3112 -} 3113 - 3114 - 3115 -int main(int argc, char const* argv[]) 3116 -try 3117 -{ 3118 - if (argc != 2) 3119 - { 3120 - puts("Usage mir_cursor_theme_dump \n"); 3121 - exit(-1); 3122 - } 3123 - 3124 - auto const theme = argv[1]; 3125 - std::ofstream output(std::string{theme} + "-theme.h"); 3126 - 3127 - output << "#include \n" 3128 - "\n" 3129 - "namespace\n" 3130 - "{\n" 3131 - "struct CursorData\n" 3132 - "{\n" 3133 - " CursorData(char const* name, unsigned int hotspot_x, unsigned int hotspot_y, char const* pixel_data) :\n" 3134 - " name(name), hotspot_x(hotspot_x), hotspot_y(hotspot_y), pixel_data(reinterpret_cast(pixel_data)) {}\n" 3135 - "\n" 3136 - " unsigned int const width{" << mir::input::default_cursor_size.width.as_int() << "};\n" 3137 - " unsigned int const height{" << mir::input::default_cursor_size.height.as_int() << "};\n" 3138 - " char const* const name;\n" 3139 - " unsigned int const hotspot_x;\n" 3140 - " unsigned int const hotspot_y;\n" 3141 - " unsigned char const* const pixel_data;\n" 3142 - "};\n" 3143 - "auto const cursor_data = {\n"; 3144 - 3145 - auto const buffer_size = 4*mir::input::default_cursor_size.height.as_int()*mir::input::default_cursor_size.height.as_int(); 3146 - 3147 - auto const xcursor_loader = std::make_shared(theme); 3148 - 3149 - for (auto cursor : cursor_names) 3150 - { 3151 - if (auto const image = xcursor_loader->image(cursor, mir::input::default_cursor_size)) 3152 - { 3153 - printf("Have image for %s:%s\n", theme, cursor); 3154 - 3155 - auto const hotspot = image->hotspot(); 3156 - auto const argb_8888 = static_cast(image->as_argb_8888()); 3157 - 3158 - output << "CursorData{\"" << cursor << "\", " << hotspot.dx.as_int() << ", " << hotspot.dy.as_int() << ",\n"; 3159 - 3160 - int chars = 0; 3161 - 3162 - output << std::oct << " \""; 3163 - 3164 - for (auto pbyte = argb_8888; pbyte != argb_8888 + buffer_size; ++pbyte) 3165 - { 3166 - auto step = (*pbyte < 010) ? 2 : (*pbyte < 0100) ? 3 : 4; 3167 - 3168 - if ((chars += step) > 80) 3169 - { 3170 - output << "\"\n \""; 3171 - chars = step; 3172 - } 3173 - 3174 - output << '\\' << static_cast(*pbyte); 3175 - } 3176 - 3177 - output << "\"\n"; 3178 - 3179 - output << "},\n"; 3180 - } 3181 - else 3182 - { 3183 - printf("** WARNING ** No image for %s:%s\n", theme, cursor); 3184 - } 3185 - } 3186 - output << "};\n"; 3187 - output << "}\n"; 3188 -} 3189 -catch (std::exception const& error) 3190 -{ 3191 - printf("** ERROR **: %s", error.what()); 3192 -} 3193 \ No newline at end of file 3194 3195 === modified file 'examples/cursors_demo_client.c' 3196 --- examples/cursors_demo_client.c 2017-05-08 03:04:26 +0000 3197 +++ examples/cursors_demo_client.c 2017-10-11 15:01:23 +0000 3198 @@ -2,7 +2,7 @@ 3199 * Copyright © 2014 Canonical LTD 3200 * 3201 * This program is free software: you can redistribute it and/or modify 3202 - * it under the terms of the GNU General Public License version 3 as 3203 + * it under the terms of the GNU General Public License version 2 or 3 as 3204 * published by the Free Software Foundation. 3205 * 3206 * This program is distributed in the hope that it will be useful, 3207 3208 === modified file 'examples/demo_client_display_config.c' 3209 --- examples/demo_client_display_config.c 2017-05-08 03:04:26 +0000 3210 +++ examples/demo_client_display_config.c 2017-10-11 15:01:23 +0000 3211 @@ -1,10 +1,10 @@ 3212 /* 3213 * Client-side display configuration demo. 3214 * 3215 - * Copyright © 2013 Canonical Ltd. 3216 + * Copyright © 2013, 2017 Canonical Ltd. 3217 * 3218 * This program is free software: you can redistribute it and/or modify 3219 - * it under the terms of the GNU General Public License version 3 as 3220 + * it under the terms of the GNU General Public License version 2 or 3 as 3221 * published by the Free Software Foundation. 3222 * 3223 * This program is distributed in the hope that it will be useful, 3224 @@ -37,7 +37,11 @@ 3225 configuration_mode_clone, 3226 configuration_mode_horizontal, 3227 configuration_mode_vertical, 3228 - configuration_mode_single 3229 + configuration_mode_single, 3230 + configuration_mode_left, 3231 + configuration_mode_right, 3232 + configuration_mode_up, 3233 + configuration_mode_down, 3234 } ConfigurationMode; 3235 3236 struct ClientContext 3237 @@ -49,9 +53,13 @@ 3238 volatile sig_atomic_t reconfigure; 3239 }; 3240 3241 -static void print_current_configuration(MirConnection *connection) 3242 +static MirDisplayConfig *conf = NULL; 3243 + 3244 +static void print_current_configuration() 3245 { 3246 - MirDisplayConfig *conf = mir_connection_create_display_configuration(connection); 3247 + if (!conf) 3248 + return; 3249 + 3250 size_t num_outputs = mir_display_config_get_num_outputs(conf); 3251 3252 for (uint32_t i = 0; i < num_outputs; i++) 3253 @@ -64,8 +72,8 @@ 3254 bool connected = mir_output_get_connection_state(output) == 3255 mir_output_connection_state_connected; 3256 3257 - printf("Output id: %d connected: %d used: %d position_x: %d position_y: %d", 3258 - id, connected, used, position_x, position_y); 3259 + printf("Output id: %d connected: %d used: %d position_x: %d position_y: %d orientation: %d", 3260 + id, connected, used, position_x, position_y, mir_output_get_orientation(output)); 3261 3262 MirOutputMode const* current = mir_output_get_current_mode(output); 3263 if (current) 3264 @@ -80,8 +88,6 @@ 3265 printf("\n"); 3266 } 3267 } 3268 - 3269 - mir_display_config_release(conf); 3270 } 3271 3272 static int apply_configuration(MirConnection *connection, MirDisplayConfig *conf) 3273 @@ -208,31 +214,67 @@ 3274 } 3275 } 3276 3277 +static void orient_display(MirDisplayConfig *conf, MirOrientation orientation) 3278 +{ 3279 + size_t num_outputs = mir_display_config_get_num_outputs(conf); 3280 + 3281 + for (size_t i = 0; i < num_outputs; i++) 3282 + { 3283 + MirOutput *output = mir_display_config_get_mutable_output(conf, i); 3284 + mir_output_set_orientation(output, orientation); 3285 + } 3286 +} 3287 + 3288 static void configure_display(struct ClientContext *context, ConfigurationMode mode, 3289 int mode_data) 3290 { 3291 - MirDisplayConfig *conf = 3292 - mir_connection_create_display_configuration(context->connection); 3293 + if (!conf) 3294 + conf = mir_connection_create_display_configuration(context->connection); 3295 3296 - if (mode == configuration_mode_clone) 3297 + switch (mode) 3298 { 3299 + case configuration_mode_clone: 3300 configure_display_clone(conf); 3301 printf("Applying clone configuration: "); 3302 - } 3303 - else if (mode == configuration_mode_vertical) 3304 - { 3305 + break; 3306 + 3307 + case configuration_mode_vertical: 3308 configure_display_vertical(conf); 3309 printf("Applying vertical configuration: "); 3310 - } 3311 - else if (mode == configuration_mode_horizontal) 3312 - { 3313 + break; 3314 + 3315 + case configuration_mode_horizontal: 3316 configure_display_horizontal(conf); 3317 printf("Applying horizontal configuration: "); 3318 - } 3319 - else if (mode == configuration_mode_single) 3320 - { 3321 + break; 3322 + 3323 + case configuration_mode_single: 3324 configure_display_single(conf, mode_data); 3325 printf("Applying single configuration for output %d: ", mode_data); 3326 + break; 3327 + 3328 + case configuration_mode_left: 3329 + orient_display(conf, mir_orientation_left); 3330 + printf("Applying orientation left: "); 3331 + break; 3332 + 3333 + case configuration_mode_right: 3334 + orient_display(conf, mir_orientation_right); 3335 + printf("Applying orientation right: "); 3336 + break; 3337 + 3338 + case configuration_mode_up: 3339 + orient_display(conf, mir_orientation_inverted); 3340 + printf("Applying orientation up: "); 3341 + break; 3342 + 3343 + case configuration_mode_down: 3344 + orient_display(conf, mir_orientation_normal); 3345 + printf("Applying orientation down: "); 3346 + break; 3347 + 3348 + default: 3349 + break; 3350 } 3351 3352 if (apply_configuration(context->connection, conf)) 3353 @@ -240,22 +282,33 @@ 3354 context->mode = mode; 3355 context->mode_data = mode_data; 3356 } 3357 - 3358 - mir_display_config_release(conf); 3359 } 3360 3361 static void display_change_callback(MirConnection *connection, void *context) 3362 { 3363 - (void)context; 3364 - 3365 printf("=== Display configuration changed === \n"); 3366 3367 - print_current_configuration(connection); 3368 + if (conf) 3369 + mir_display_config_release(conf); 3370 + 3371 + conf = mir_connection_create_display_configuration(connection); 3372 + 3373 + print_current_configuration(); 3374 3375 struct ClientContext *ctx = (struct ClientContext*) context; 3376 ctx->reconfigure = 1; 3377 } 3378 3379 +static void apply_to_base_configuration(MirConnection *connection) 3380 +{ 3381 + if (!conf) 3382 + return; 3383 + 3384 + mir_connection_preview_base_display_configuration(connection, conf, 2); 3385 + puts("Applying to base configuration"); 3386 + mir_connection_confirm_base_display_configuration(connection, conf); 3387 +} 3388 + 3389 static void handle_keyboard_event(struct ClientContext *ctx, MirKeyboardEvent const* event) 3390 { 3391 if (mir_keyboard_event_action(event) != mir_keyboard_action_up) 3392 @@ -271,6 +324,9 @@ 3393 3394 switch (key_code) 3395 { 3396 + case XKB_KEY_a: 3397 + apply_to_base_configuration(ctx->connection); 3398 + break; 3399 case XKB_KEY_q: 3400 ctx->running = 0; 3401 break; 3402 @@ -284,7 +340,21 @@ 3403 configure_display(ctx, configuration_mode_vertical, 0); 3404 break; 3405 case XKB_KEY_p: 3406 - print_current_configuration(ctx->connection); 3407 + if (!conf) 3408 + conf = mir_connection_create_display_configuration(ctx->connection); 3409 + print_current_configuration(); 3410 + break; 3411 + case XKB_KEY_Left: 3412 + configure_display(ctx, configuration_mode_right, 0); 3413 + break; 3414 + case XKB_KEY_Up: 3415 + configure_display(ctx, configuration_mode_up, 0); 3416 + break; 3417 + case XKB_KEY_Right: 3418 + configure_display(ctx, configuration_mode_left, 0); 3419 + break; 3420 + case XKB_KEY_Down: 3421 + configure_display(ctx, configuration_mode_down, 0); 3422 break; 3423 } 3424 } 3425 @@ -292,15 +362,16 @@ 3426 static void event_callback( 3427 MirWindow* surface, MirEvent const* event, void* context) 3428 { 3429 - (void) surface; 3430 + mir_eglapp_handle_event(surface, event, context); 3431 + 3432 struct ClientContext *ctx = (struct ClientContext*) context; 3433 - 3434 + 3435 if (mir_event_get_type(event) != mir_event_type_input) 3436 return; 3437 MirInputEvent const* input_event = mir_event_get_input_event(event); 3438 if (mir_input_event_get_type(input_event) != mir_input_event_type_key) 3439 return; 3440 - 3441 + 3442 handle_keyboard_event(ctx, mir_input_event_get_keyboard_event(input_event)); 3443 } 3444 3445 @@ -317,7 +388,9 @@ 3446 " h: arrange outputs horizontally in the virtual space\n" 3447 " v: arrange outputs vertically in the virtual space\n" 3448 " 1-9: enable only the Nth connected output (in the order returned by the hardware)\n" 3449 - " p: print current display configuration\n"); 3450 + " Arrows: orient display (sets \"down\" direction)\n" 3451 + " p: print current display configuration\n" 3452 + " a: apply current display configuration globally\n"); 3453 3454 return 1; 3455 } 3456 @@ -351,6 +424,9 @@ 3457 } 3458 } 3459 3460 + if (conf) 3461 + mir_display_config_release(conf); 3462 + 3463 mir_eglapp_cleanup(); 3464 3465 return 0; 3466 3467 === modified file 'examples/eglapp.c' 3468 --- examples/eglapp.c 2017-06-30 11:35:46 +0000 3469 +++ examples/eglapp.c 2017-10-11 15:01:23 +0000 3470 @@ -2,7 +2,7 @@ 3471 * Copyright © 2013 Canonical Ltd. 3472 * 3473 * This program is free software: you can redistribute it and/or modify 3474 - * it under the terms of the GNU General Public License version 3 as 3475 + * it under the terms of the GNU General Public License version 2 or 3 as 3476 * published by the Free Software Foundation. 3477 * 3478 * This program is distributed in the hope that it will be useful, 3479 3480 === modified file 'examples/eglapp.h' 3481 --- examples/eglapp.h 2017-06-06 15:41:28 +0000 3482 +++ examples/eglapp.h 2017-10-11 15:01:23 +0000 3483 @@ -2,7 +2,7 @@ 3484 * Copyright © 2013 Canonical Ltd. 3485 * 3486 * This program is free software: you can redistribute it and/or modify 3487 - * it under the terms of the GNU General Public License version 3 as 3488 + * it under the terms of the GNU General Public License version 2 or 3 as 3489 * published by the Free Software Foundation. 3490 * 3491 * This program is distributed in the hope that it will be useful, 3492 3493 === modified file 'examples/eglcounter.cpp' 3494 --- examples/eglcounter.cpp 2017-05-08 03:04:26 +0000 3495 +++ examples/eglcounter.cpp 2017-10-11 15:01:23 +0000 3496 @@ -2,7 +2,7 @@ 3497 * Copyright © 2014 Canonical Ltd. 3498 * 3499 * This program is free software: you can redistribute it and/or modify 3500 - * it under the terms of the GNU General Public License version 3 as 3501 + * it under the terms of the GNU General Public License version 2 or 3 as 3502 * published by the Free Software Foundation. 3503 * 3504 * This program is distributed in the hope that it will be useful, 3505 3506 === modified file 'examples/eglflash.c' 3507 --- examples/eglflash.c 2017-05-08 03:04:26 +0000 3508 +++ examples/eglflash.c 2017-10-11 15:01:23 +0000 3509 @@ -4,7 +4,7 @@ 3510 * Copyright © 2013 Canonical Ltd. 3511 * 3512 * This program is free software: you can redistribute it and/or modify 3513 - * it under the terms of the GNU General Public License version 3 as 3514 + * it under the terms of the GNU General Public License version 2 or 3 as 3515 * published by the Free Software Foundation. 3516 * 3517 * This program is distributed in the hope that it will be useful, 3518 3519 === modified file 'examples/eglplasma.c' 3520 --- examples/eglplasma.c 2017-05-08 03:04:26 +0000 3521 +++ examples/eglplasma.c 2017-10-11 15:01:23 +0000 3522 @@ -2,7 +2,7 @@ 3523 * Copyright © 2013 Canonical Ltd. 3524 * 3525 * This program is free software: you can redistribute it and/or modify 3526 - * it under the terms of the GNU General Public License version 3 as 3527 + * it under the terms of the GNU General Public License version 2 or 3 as 3528 * published by the Free Software Foundation. 3529 * 3530 * This program is distributed in the hope that it will be useful, 3531 3532 === modified file 'examples/eglsquare.cpp' 3533 --- examples/eglsquare.cpp 2017-06-06 13:55:51 +0000 3534 +++ examples/eglsquare.cpp 2017-10-11 15:01:23 +0000 3535 @@ -2,7 +2,7 @@ 3536 * Copyright © 2015 Canonical Ltd. 3537 * 3538 * This program is free software: you can redistribute it and/or modify 3539 - * it under the terms of the GNU General Public License version 3 as 3540 + * it under the terms of the GNU General Public License version 2 or 3 as 3541 * published by the Free Software Foundation. 3542 * 3543 * This program is distributed in the hope that it will be useful, 3544 @@ -169,84 +169,89 @@ 3545 3546 pos = Pos{x, y}; 3547 cv.notify_one(); 3548 + break; 3549 } 3550 3551 + case mir_event_type_close_window: 3552 + kill(getpid(), SIGTERM); 3553 + break; 3554 + 3555 default:; 3556 } 3557 - } 3558 - 3559 - SquareRenderingSurface(SquareRenderingSurface const&) = delete; 3560 - SquareRenderingSurface& operator=(SquareRenderingSurface const&) = delete; 3561 - private: 3562 - struct OutputDimensions 3563 - { 3564 - unsigned int const width; 3565 - unsigned int const height; 3566 - } const dimensions; 3567 - 3568 - me::Context context; 3569 - me::NormalWindow window; 3570 - RenderProgram program; 3571 - 3572 - OutputDimensions active_output_dimensions(MirConnection* connection) 3573 - { 3574 - unsigned int width{0}; 3575 - unsigned int height{0}; 3576 - auto display_config = mir_connection_create_display_configuration(connection); 3577 - auto num_outputs = mir_display_config_get_num_outputs(display_config); 3578 - for (auto i = 0; i < num_outputs; i++) 3579 - { 3580 - auto output = mir_display_config_get_output(display_config, i); 3581 - auto state = mir_output_get_connection_state(output); 3582 - if (state == mir_output_connection_state_connected && mir_output_is_enabled(output)) 3583 - { 3584 - auto mode = mir_output_get_current_mode(output); 3585 - width = mir_output_mode_get_width(mode); 3586 - height = mir_output_mode_get_height(mode); 3587 - break; 3588 - } 3589 - } 3590 - mir_display_config_release(display_config); 3591 - if (width == 0 || height == 0) 3592 - throw std::logic_error("could not determine display size"); 3593 - return {width, height}; 3594 - } 3595 - 3596 - static void on_event(MirWindow*, const MirEvent *event, void *context) 3597 - { 3598 - auto surface = reinterpret_cast(context); 3599 - if (surface) surface->on_event(event); 3600 - } 3601 - 3602 - private: 3603 - void do_work() 3604 - { 3605 - std::unique_lock lock(mutex); 3606 - 3607 - while (true) 3608 - { 3609 - cv.wait(lock); 3610 - 3611 - if (!running) return; 3612 - 3613 - Pos pos = this->pos; 3614 - 3615 - context.make_current(); 3616 - program.draw( 3617 - pos.x/static_cast(dimensions.width)*2.0 - 1.0, 3618 - pos.y/static_cast(dimensions.height)*-2.0 + 1.0); 3619 - context.swapbuffers(); 3620 - } 3621 - } 3622 - 3623 - struct Pos { float x; float y; }; 3624 - std::atomic pos; 3625 - 3626 - std::thread worker; 3627 - std::condition_variable cv; 3628 - std::mutex mutex; 3629 - bool running{true}; 3630 - }; 3631 + } 3632 + 3633 + SquareRenderingSurface(SquareRenderingSurface const&) = delete; 3634 + SquareRenderingSurface& operator=(SquareRenderingSurface const&) = delete; 3635 +private: 3636 + struct OutputDimensions 3637 + { 3638 + unsigned int const width; 3639 + unsigned int const height; 3640 + } const dimensions; 3641 + 3642 + me::Context context; 3643 + me::NormalWindow window; 3644 + RenderProgram program; 3645 + 3646 + OutputDimensions active_output_dimensions(MirConnection* connection) 3647 + { 3648 + unsigned int width{0}; 3649 + unsigned int height{0}; 3650 + auto display_config = mir_connection_create_display_configuration(connection); 3651 + auto num_outputs = mir_display_config_get_num_outputs(display_config); 3652 + for (auto i = 0; i < num_outputs; i++) 3653 + { 3654 + auto output = mir_display_config_get_output(display_config, i); 3655 + auto state = mir_output_get_connection_state(output); 3656 + if (state == mir_output_connection_state_connected && mir_output_is_enabled(output)) 3657 + { 3658 + auto mode = mir_output_get_current_mode(output); 3659 + width = mir_output_mode_get_width(mode); 3660 + height = mir_output_mode_get_height(mode); 3661 + break; 3662 + } 3663 + } 3664 + mir_display_config_release(display_config); 3665 + if (width == 0 || height == 0) 3666 + throw std::logic_error("could not determine display size"); 3667 + return {width, height}; 3668 + } 3669 + 3670 + static void on_event(MirWindow*, const MirEvent *event, void *context) 3671 + { 3672 + auto surface = reinterpret_cast(context); 3673 + if (surface) surface->on_event(event); 3674 + } 3675 + 3676 +private: 3677 + void do_work() 3678 + { 3679 + std::unique_lock lock(mutex); 3680 + 3681 + while (true) 3682 + { 3683 + cv.wait(lock); 3684 + 3685 + if (!running) return; 3686 + 3687 + Pos pos = this->pos; 3688 + 3689 + context.make_current(); 3690 + program.draw( 3691 + pos.x/static_cast(dimensions.width)*2.0 - 1.0, 3692 + pos.y/static_cast(dimensions.height)*-2.0 + 1.0); 3693 + context.swapbuffers(); 3694 + } 3695 + } 3696 + 3697 + struct Pos { float x; float y; }; 3698 + std::atomic pos; 3699 + 3700 + std::thread worker; 3701 + std::condition_variable cv; 3702 + std::mutex mutex; 3703 + bool running{true}; 3704 +}; 3705 } 3706 3707 int main(int argc, char *argv[]) 3708 3709 === modified file 'examples/eglstateswitcher.c' 3710 --- examples/eglstateswitcher.c 2017-05-08 03:04:26 +0000 3711 +++ examples/eglstateswitcher.c 2017-10-11 15:01:23 +0000 3712 @@ -4,7 +4,7 @@ 3713 * Copyright © 2014 Canonical Ltd. 3714 * 3715 * This program is free software: you can redistribute it and/or modify 3716 - * it under the terms of the GNU General Public License version 3 as 3717 + * it under the terms of the GNU General Public License version 2 or 3 as 3718 * published by the Free Software Foundation. 3719 * 3720 * This program is distributed in the hope that it will be useful, 3721 3722 === modified file 'examples/egltriangle.c' 3723 --- examples/egltriangle.c 2017-05-08 03:04:26 +0000 3724 +++ examples/egltriangle.c 2017-10-11 15:01:23 +0000 3725 @@ -2,7 +2,7 @@ 3726 * Copyright © 2013 Canonical Ltd. 3727 * 3728 * This program is free software: you can redistribute it and/or modify 3729 - * it under the terms of the GNU General Public License version 3 as 3730 + * it under the terms of the GNU General Public License version 2 or 3 as 3731 * published by the Free Software Foundation. 3732 * 3733 * This program is distributed in the hope that it will be useful, 3734 3735 === modified file 'examples/fingerpaint.c' 3736 --- examples/fingerpaint.c 2017-05-19 13:49:04 +0000 3737 +++ examples/fingerpaint.c 2017-10-11 15:01:23 +0000 3738 @@ -2,7 +2,7 @@ 3739 * Copyright © 2013 Canonical Ltd. 3740 * 3741 * This program is free software: you can redistribute it and/or modify 3742 - * it under the terms of the GNU General Public License version 3 as 3743 + * it under the terms of the GNU General Public License version 2 or 3 as 3744 * published by the Free Software Foundation. 3745 * 3746 * This program is distributed in the hope that it will be useful, 3747 3748 === modified file 'examples/flicker.c' 3749 --- examples/flicker.c 2017-06-06 09:02:33 +0000 3750 +++ examples/flicker.c 2017-10-11 15:01:23 +0000 3751 @@ -2,7 +2,7 @@ 3752 * Copyright © 2012 Canonical Ltd. 3753 * 3754 * This program is free software: you can redistribute it and/or modify 3755 - * it under the terms of the GNU General Public License version 3 as 3756 + * it under the terms of the GNU General Public License version 2 or 3 as 3757 * published by the Free Software Foundation. 3758 * 3759 * This program is distributed in the hope that it will be useful, 3760 3761 === modified file 'examples/glog_logger.cpp' 3762 --- examples/glog_logger.cpp 2015-02-22 07:46:25 +0000 3763 +++ examples/glog_logger.cpp 2017-10-11 15:01:23 +0000 3764 @@ -2,7 +2,7 @@ 3765 * Copyright © 2013 Canonical Ltd. 3766 * 3767 * This program is free software: you can redistribute it and/or modify 3768 - * it under the terms of the GNU General Public License version 3 as 3769 + * it under the terms of the GNU General Public License version 2 or 3 as 3770 * published by the Free Software Foundation. 3771 * 3772 * This program is distributed in the hope that it will be useful, 3773 3774 === modified file 'examples/glog_logger.h' 3775 --- examples/glog_logger.h 2015-02-22 07:46:25 +0000 3776 +++ examples/glog_logger.h 2017-10-11 15:01:23 +0000 3777 @@ -2,7 +2,7 @@ 3778 * Copyright © 2013 Canonical Ltd. 3779 * 3780 * This program is free software: you can redistribute it and/or modify 3781 - * it under the terms of the GNU General Public License version 3 as 3782 + * it under the terms of the GNU General Public License version 2 or 3 as 3783 * published by the Free Software Foundation. 3784 * 3785 * This program is distributed in the hope that it will be useful, 3786 3787 === modified file 'examples/graphics.h' 3788 --- examples/graphics.h 2013-04-24 05:22:20 +0000 3789 +++ examples/graphics.h 2017-10-11 15:01:23 +0000 3790 @@ -2,7 +2,7 @@ 3791 * Copyright © 2012 Canonical Ltd. 3792 * 3793 * This program is free software: you can redistribute it and/or modify it 3794 - * under the terms of the GNU General Public License version 3, 3795 + * under the terms of the GNU General Public License version 2 or 3, 3796 * as published by the Free Software Foundation. 3797 * 3798 * This program is distributed in the hope that it will be useful, 3799 3800 === modified file 'examples/graphics_utils.cpp' 3801 --- examples/graphics_utils.cpp 2017-05-08 03:04:26 +0000 3802 +++ examples/graphics_utils.cpp 2017-10-11 15:01:23 +0000 3803 @@ -2,7 +2,7 @@ 3804 * Copyright © 2012 Canonical Ltd. 3805 * 3806 * This program is free software: you can redistribute it and/or modify it 3807 - * under the terms of the GNU General Public License version 3, 3808 + * under the terms of the GNU General Public License version 2 or 3, 3809 * as published by the Free Software Foundation. 3810 * 3811 * This program is distributed in the hope that it will be useful, 3812 3813 === modified file 'examples/image_renderer.cpp' 3814 --- examples/image_renderer.cpp 2017-05-08 03:04:26 +0000 3815 +++ examples/image_renderer.cpp 2017-10-11 15:01:23 +0000 3816 @@ -2,7 +2,7 @@ 3817 * Copyright © 2012 Canonical Ltd. 3818 * 3819 * This program is free software: you can redistribute it and/or modify 3820 - * it under the terms of the GNU General Public License version 3 as 3821 + * it under the terms of the GNU General Public License version 2 or 3 as 3822 * published by the Free Software Foundation. 3823 * 3824 * This program is distributed in the hope that it will be useful, 3825 3826 === modified file 'examples/image_renderer.h' 3827 --- examples/image_renderer.h 2015-02-22 07:46:25 +0000 3828 +++ examples/image_renderer.h 2017-10-11 15:01:23 +0000 3829 @@ -2,7 +2,7 @@ 3830 * Copyright © 2012 Canonical Ltd. 3831 * 3832 * This program is free software: you can redistribute it and/or modify 3833 - * it under the terms of the GNU General Public License version 3 as 3834 + * it under the terms of the GNU General Public License version 2 or 3 as 3835 * published by the Free Software Foundation. 3836 * 3837 * This program is distributed in the hope that it will be useful, 3838 3839 === modified file 'examples/input_shapes.cpp' 3840 --- examples/input_shapes.cpp 2017-05-23 10:51:47 +0000 3841 +++ examples/input_shapes.cpp 2017-10-11 15:01:23 +0000 3842 @@ -2,7 +2,7 @@ 3843 * Copyright © 2015 Canonical Ltd. 3844 * 3845 * This program is free software: you can redistribute it and/or modify 3846 - * it under the terms of the GNU General Public License version 3 as 3847 + * it under the terms of the GNU General Public License version 2 or 3 as 3848 * published by the Free Software Foundation. 3849 * 3850 * This program is distributed in the hope that it will be useful, 3851 3852 === modified file 'examples/mir_demo_server_loader.cpp' 3853 --- examples/mir_demo_server_loader.cpp 2017-05-08 03:04:26 +0000 3854 +++ examples/mir_demo_server_loader.cpp 2017-10-11 15:01:23 +0000 3855 @@ -2,7 +2,7 @@ 3856 * Copyright © 2015 Canonical Ltd. 3857 * 3858 * This program is free software: you can redistribute it and/or modify 3859 - * it under the terms of the GNU General Public License version 3 as 3860 + * it under the terms of the GNU General Public License version 2 or 3 as 3861 * published by the Free Software Foundation. 3862 * 3863 * This program is distributed in the hope that it will be useful, 3864 3865 === modified file 'examples/mir_image.h' 3866 --- examples/mir_image.h 2013-04-24 05:22:20 +0000 3867 +++ examples/mir_image.h 2017-10-11 15:01:23 +0000 3868 @@ -2,7 +2,7 @@ 3869 * Copyright © 2012 Canonical Ltd. 3870 * 3871 * This program is free software: you can redistribute it and/or modify it 3872 - * under the terms of the GNU General Public License version 3, 3873 + * under the terms of the GNU General Public License version 2 or 3, 3874 * as published by the Free Software Foundation. 3875 * 3876 * This program is distributed in the hope that it will be useful, 3877 3878 === added directory 'examples/miral-kiosk' 3879 === added file 'examples/miral-kiosk/CMakeLists.txt' 3880 --- examples/miral-kiosk/CMakeLists.txt 1970-01-01 00:00:00 +0000 3881 +++ examples/miral-kiosk/CMakeLists.txt 2017-10-11 15:01:23 +0000 3882 @@ -0,0 +1,12 @@ 3883 +include_directories( 3884 +${PROJECT_SOURCE_DIR}/include/miral 3885 + ${PROJECT_SOURCE_DIR}/include/client 3886 +) 3887 + 3888 +mir_add_wrapped_executable(miral-kiosk 3889 + kiosk_main.cpp 3890 + kiosk_window_manager.cpp kiosk_window_manager.h 3891 + sw_splash.cpp sw_splash.h 3892 +) 3893 + 3894 +target_link_libraries(miral-kiosk miral) 3895 3896 === added file 'examples/miral-kiosk/kiosk_main.cpp' 3897 --- examples/miral-kiosk/kiosk_main.cpp 1970-01-01 00:00:00 +0000 3898 +++ examples/miral-kiosk/kiosk_main.cpp 2017-10-11 15:01:23 +0000 3899 @@ -0,0 +1,94 @@ 3900 +/* 3901 + * Copyright © 2016 Canonical Ltd. 3902 + * 3903 + * This program is free software: you can redistribute it and/or modify 3904 + * under the terms of the GNU General Public License version 2 or 3 as as 3905 + * published by the Free Software Foundation. 3906 + * 3907 + * This program is distributed in the hope that it will be useful, 3908 + * but WITHOUT ANY WARRANTY; without even the implied warranty of 3909 + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 3910 + * GNU General Public License for more details. 3911 + * 3912 + * You should have received a copy of the GNU General Public License 3913 + * along with this program. If not, see . 3914 + * 3915 + * Authored by: Alan Griffiths 3916 + */ 3917 + 3918 +#include "kiosk_window_manager.h" 3919 + 3920 +#include 3921 +#include 3922 +#include 3923 +#include 3924 +#include 3925 +#include 3926 + 3927 +#include 3928 +#include 3929 + 3930 +namespace 3931 +{ 3932 +struct KioskAuthorizer : miral::ApplicationAuthorizer 3933 +{ 3934 + KioskAuthorizer(SwSplash const& splash) : splash{splash}{} 3935 + 3936 + virtual bool connection_is_allowed(miral::ApplicationCredentials const& creds) override 3937 + { 3938 + // Allow internal applications and (optionally) only ones that start "immediately" 3939 + // (For the sake of an example "immediately" means while the spash is running) 3940 + return getpid() == creds.pid() || !startup_only || splash.session().lock(); 3941 + } 3942 + 3943 + virtual bool configure_display_is_allowed(miral::ApplicationCredentials const& /*creds*/) override 3944 + { 3945 + return false; 3946 + } 3947 + 3948 + virtual bool set_base_display_configuration_is_allowed(miral::ApplicationCredentials const& /*creds*/) override 3949 + { 3950 + return false; 3951 + } 3952 + 3953 + virtual bool screencast_is_allowed(miral::ApplicationCredentials const& /*creds*/) override 3954 + { 3955 + return true; 3956 + } 3957 + 3958 + virtual bool prompt_session_is_allowed(miral::ApplicationCredentials const& /*creds*/) override 3959 + { 3960 + return false; 3961 + } 3962 + 3963 + static std::atomic startup_only; 3964 + 3965 + SwSplash splash; 3966 +}; 3967 + 3968 +std::atomic KioskAuthorizer::startup_only{false}; 3969 +} 3970 + 3971 +int main(int argc, char const* argv[]) 3972 +{ 3973 + using namespace miral; 3974 + 3975 + SwSplash splash; 3976 + 3977 + CommandLineOption startup_only{ 3978 + [&](bool startup_only) {KioskAuthorizer::startup_only = startup_only; }, 3979 + "kiosk-startup-apps-only", 3980 + "Only allow applications to connect during startup", 3981 + KioskAuthorizer::startup_only}; 3982 + 3983 + return MirRunner{argc, argv}.run_with( 3984 + { 3985 + CommandLineOption{[&](std::string const& ) { }, 3986 + "desktop_file_hint", "Ignored for Unity8 compatability", "miral-shell.desktop"}, 3987 + set_window_management_policy(splash), 3988 + SetApplicationAuthorizer{splash}, 3989 + Keymap{}, 3990 + startup_only, 3991 + StartupInternalClient{"Intro", splash} 3992 + }); 3993 +} 3994 3995 === added file 'examples/miral-kiosk/kiosk_window_manager.cpp' 3996 --- examples/miral-kiosk/kiosk_window_manager.cpp 1970-01-01 00:00:00 +0000 3997 +++ examples/miral-kiosk/kiosk_window_manager.cpp 2017-10-11 15:01:23 +0000 3998 @@ -0,0 +1,164 @@ 3999 +/* 4000 + * Copyright © 2016-2017 Canonical Ltd. 4001 + * 4002 + * This program is free software: you can redistribute it and/or modify it 4003 + * under the terms of the GNU General Public License version 2 or 3 as 4004 + * published by the Free Software Foundation. 4005 + * 4006 + * This program is distributed in the hope that it will be useful, 4007 + * but WITHOUT ANY WARRANTY; without even the implied warranty of 4008 + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 4009 + * GNU General Public License for more details. 4010 + * 4011 + * You should have received a copy of the GNU General Public License 4012 + * along with this program. If not, see . 4013 + * 4014 + * Authored By: Alan Griffiths 4015 + */ 4016 + 4017 +#include "kiosk_window_manager.h" 4018 + 4019 +#include 4020 +#include 4021 +#include 4022 + 4023 +#include 4024 + 4025 +namespace ms = mir::scene; 4026 +using namespace miral; 4027 + 4028 +KioskWindowManagerPolicy::KioskWindowManagerPolicy(WindowManagerTools const& tools, SwSplash const& splash) : 4029 + CanonicalWindowManagerPolicy{tools}, 4030 + splash{splash} 4031 +{ 4032 +} 4033 + 4034 +bool KioskWindowManagerPolicy::handle_keyboard_event(MirKeyboardEvent const* event) 4035 +{ 4036 + auto const action = mir_keyboard_event_action(event); 4037 + auto const scan_code = mir_keyboard_event_scan_code(event); 4038 + auto const modifiers = mir_keyboard_event_modifiers(event) & modifier_mask; 4039 + 4040 + if (action == mir_keyboard_action_down && 4041 + modifiers == mir_input_event_modifier_alt && 4042 + scan_code == KEY_TAB) 4043 + { 4044 + tools.focus_next_application(); 4045 + 4046 + return true; 4047 + } 4048 + else if (action == mir_keyboard_action_down && 4049 + modifiers == mir_input_event_modifier_alt && 4050 + scan_code == KEY_GRAVE) 4051 + { 4052 + tools.focus_next_within_application(); 4053 + 4054 + return true; 4055 + } 4056 + else if (action == mir_keyboard_action_down && 4057 + modifiers == (mir_input_event_modifier_alt | mir_input_event_modifier_shift) && 4058 + scan_code == KEY_GRAVE) 4059 + { 4060 + tools.focus_prev_within_application(); 4061 + 4062 + return true; 4063 + } 4064 + else if (action == mir_keyboard_action_down && scan_code == KEY_F4) 4065 + { 4066 + switch (modifiers & modifier_mask) 4067 + { 4068 + case mir_input_event_modifier_alt: 4069 + tools.ask_client_to_close(tools.active_window());; 4070 + return true; 4071 + 4072 + default: 4073 + break; 4074 + } 4075 + } 4076 + 4077 + return false; 4078 +} 4079 + 4080 +bool KioskWindowManagerPolicy::handle_touch_event(MirTouchEvent const* event) 4081 +{ 4082 + auto const count = mir_touch_event_point_count(event); 4083 + 4084 + long total_x = 0; 4085 + long total_y = 0; 4086 + 4087 + for (auto i = 0U; i != count; ++i) 4088 + { 4089 + total_x += mir_touch_event_axis_value(event, i, mir_touch_axis_x); 4090 + total_y += mir_touch_event_axis_value(event, i, mir_touch_axis_y); 4091 + } 4092 + 4093 + Point const cursor{total_x/count, total_y/count}; 4094 + 4095 + tools.select_active_window(tools.window_at(cursor)); 4096 + 4097 + return false; 4098 +} 4099 + 4100 +bool KioskWindowManagerPolicy::handle_pointer_event(MirPointerEvent const* event) 4101 +{ 4102 + auto const action = mir_pointer_event_action(event); 4103 + 4104 + Point const cursor{ 4105 + mir_pointer_event_axis_value(event, mir_pointer_axis_x), 4106 + mir_pointer_event_axis_value(event, mir_pointer_axis_y)}; 4107 + 4108 + if (action == mir_pointer_action_button_down) 4109 + { 4110 + tools.select_active_window(tools.window_at(cursor)); 4111 + } 4112 + 4113 + return false; 4114 +} 4115 + 4116 +void KioskWindowManagerPolicy::advise_focus_gained(WindowInfo const& info) 4117 +{ 4118 + CanonicalWindowManagerPolicy::advise_focus_gained(info); 4119 + 4120 + if (auto session = splash.session().lock()) 4121 + { 4122 + auto const& app_info = tools.info_for(session); 4123 + 4124 + for (auto const& s : app_info.windows()) 4125 + tools.raise_tree(s); 4126 + } 4127 +} 4128 + 4129 +auto KioskWindowManagerPolicy::place_new_window(ApplicationInfo const& app_info, WindowSpecification const& request) 4130 +-> WindowSpecification 4131 +{ 4132 + WindowSpecification specification = CanonicalWindowManagerPolicy::place_new_window(app_info, request); 4133 + 4134 + if ((specification.type() == mir_window_type_normal || specification.type() == mir_window_type_freestyle) && 4135 + (!specification.parent().is_set() || !specification.parent().value().lock())) 4136 + { 4137 + specification.state() = mir_window_state_maximized; 4138 + tools.place_and_size_for_state(specification, WindowInfo{}); 4139 + 4140 + if (!request.state().is_set() || request.state().value() != mir_window_state_restored) 4141 + specification.state() = request.state(); 4142 + } 4143 + 4144 + return specification; 4145 +} 4146 + 4147 +void KioskWindowManagerPolicy::handle_modify_window(WindowInfo& window_info, WindowSpecification const& modifications) 4148 +{ 4149 + WindowSpecification specification = modifications; 4150 + 4151 + if ((window_info.type() == mir_window_type_normal || window_info.type() == mir_window_type_freestyle) && 4152 + !window_info.parent()) 4153 + { 4154 + specification.state() = mir_window_state_maximized; 4155 + tools.place_and_size_for_state(specification, window_info); 4156 + 4157 + if (!modifications.state().is_set() || modifications.state().value() != mir_window_state_restored) 4158 + specification.state() = modifications.state(); 4159 + } 4160 + 4161 + CanonicalWindowManagerPolicy::handle_modify_window(window_info, specification); 4162 +} 4163 4164 === added file 'examples/miral-kiosk/kiosk_window_manager.h' 4165 --- examples/miral-kiosk/kiosk_window_manager.h 1970-01-01 00:00:00 +0000 4166 +++ examples/miral-kiosk/kiosk_window_manager.h 2017-10-11 15:01:23 +0000 4167 @@ -0,0 +1,54 @@ 4168 +/* 4169 + * Copyright © 2016-2017 Canonical Ltd. 4170 + * 4171 + * This program is free software: you can redistribute it and/or modify it 4172 + * under the terms of the GNU General Public License version 2 or 3 as 4173 + * published by the Free Software Foundation. 4174 + * 4175 + * This program is distributed in the hope that it will be useful, 4176 + * but WITHOUT ANY WARRANTY; without even the implied warranty of 4177 + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 4178 + * GNU General Public License for more details. 4179 + * 4180 + * You should have received a copy of the GNU General Public License 4181 + * along with this program. If not, see . 4182 + * 4183 + * Authored By: Alan Griffiths 4184 + */ 4185 + 4186 +#ifndef MIRAL_KIOSK_WINDOW_MANAGER_H 4187 +#define MIRAL_KIOSK_WINDOW_MANAGER_H 4188 + 4189 +#include "sw_splash.h" 4190 + 4191 +#include 4192 + 4193 +using namespace mir::geometry; 4194 + 4195 +class KioskWindowManagerPolicy : public miral::CanonicalWindowManagerPolicy 4196 +{ 4197 +public: 4198 + KioskWindowManagerPolicy(miral::WindowManagerTools const& tools, SwSplash const&); 4199 + 4200 + auto place_new_window(miral::ApplicationInfo const& app_info, miral::WindowSpecification const& request) 4201 + -> miral::WindowSpecification override; 4202 + 4203 + void advise_focus_gained(miral::WindowInfo const& info) override; 4204 + 4205 + bool handle_keyboard_event(MirKeyboardEvent const* event) override; 4206 + bool handle_touch_event(MirTouchEvent const* event) override; 4207 + bool handle_pointer_event(MirPointerEvent const* event) override; 4208 + void handle_modify_window(miral::WindowInfo& window_info, miral::WindowSpecification const& modifications) override; 4209 + 4210 +private: 4211 + static const int modifier_mask = 4212 + mir_input_event_modifier_alt | 4213 + mir_input_event_modifier_shift | 4214 + mir_input_event_modifier_sym | 4215 + mir_input_event_modifier_ctrl | 4216 + mir_input_event_modifier_meta; 4217 + 4218 + SwSplash const splash; 4219 +}; 4220 + 4221 +#endif /* MIRAL_KIOSK_WINDOW_MANAGER_H */ 4222 4223 === added file 'examples/miral-kiosk/sw_splash.cpp' 4224 --- examples/miral-kiosk/sw_splash.cpp 1970-01-01 00:00:00 +0000 4225 +++ examples/miral-kiosk/sw_splash.cpp 2017-10-11 15:01:23 +0000 4226 @@ -0,0 +1,173 @@ 4227 +/* 4228 + * Copyright © 2016 Canonical Ltd. 4229 + * 4230 + * This program is free software: you can redistribute it and/or modify it 4231 + * under the terms of the GNU General Public License version 2 or 3 as 4232 + * published by the Free Software Foundation. 4233 + * 4234 + * This program is distributed in the hope that it will be useful, 4235 + * but WITHOUT ANY WARRANTY; without even the implied warranty of 4236 + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 4237 + * GNU General Public License for more details. 4238 + * 4239 + * You should have received a copy of the GNU General Public License 4240 + * along with this program. If not, see . 4241 + * 4242 + * Authored by: Alan Griffiths 4243 + */ 4244 + 4245 +#include "sw_splash.h" 4246 + 4247 +#include 4248 +#include 4249 +#include 4250 +#include 4251 + 4252 +#include 4253 + 4254 +#include 4255 +#include 4256 +#include 4257 +#include 4258 + 4259 +namespace 4260 +{ 4261 +MirPixelFormat find_8888_format(MirConnection* connection) 4262 +{ 4263 + unsigned int const num_formats = 32; 4264 + MirPixelFormat pixel_formats[num_formats]; 4265 + unsigned int valid_formats; 4266 + mir_connection_get_available_surface_formats(connection, pixel_formats, num_formats, &valid_formats); 4267 + 4268 + for (unsigned int i = 0; i < num_formats; ++i) 4269 + { 4270 + MirPixelFormat cur_pf = pixel_formats[i]; 4271 + if (cur_pf == mir_pixel_format_abgr_8888 || 4272 + cur_pf == mir_pixel_format_argb_8888) 4273 + { 4274 + return cur_pf; 4275 + } 4276 + } 4277 + 4278 + for (unsigned int i = 0; i < num_formats; ++i) 4279 + { 4280 + MirPixelFormat cur_pf = pixel_formats[i]; 4281 + if (cur_pf == mir_pixel_format_xbgr_8888 || 4282 + cur_pf == mir_pixel_format_xrgb_8888) 4283 + { 4284 + return cur_pf; 4285 + } 4286 + } 4287 + 4288 + return *pixel_formats; 4289 +} 4290 + 4291 +auto create_window(MirConnection* connection, mir::client::Surface const& surface) -> mir::client::Window 4292 +{ 4293 + int id = 0; 4294 + int width = 0; 4295 + int height = 0; 4296 + 4297 + mir::client::DisplayConfig{connection}.for_each_output([&](MirOutput const* output) 4298 + { 4299 + if (mir_output_get_connection_state(output) == mir_output_connection_state_connected && 4300 + mir_output_is_enabled(output)) 4301 + { 4302 + id = mir_output_get_id(output); 4303 + 4304 + MirOutputMode const* mode = mir_output_get_current_mode(output); 4305 + width = mir_output_mode_get_width(mode); 4306 + height = mir_output_mode_get_height(mode); 4307 + } 4308 + }); 4309 + 4310 + return mir::client::WindowSpec::for_normal_window(connection, width, height) 4311 + .set_name("splash") 4312 + .set_fullscreen_on_output(id) 4313 + .add_surface(surface, width, height, 0, 0) 4314 + .create_window(); 4315 +} 4316 + 4317 +void render_pattern(MirGraphicsRegion *region, uint8_t pattern[]) 4318 +{ 4319 + char *row = region->vaddr; 4320 + 4321 + for (int j = 0; j < region->height; j++) 4322 + { 4323 + uint32_t *pixel = (uint32_t*)row; 4324 + 4325 + for (int i = 0; i < region->width; i++) 4326 + memcpy(pixel+i, pattern, sizeof pixel[i]); 4327 + 4328 + row += region->stride; 4329 + } 4330 +} 4331 +} 4332 + 4333 +struct SwSplash::Self 4334 +{ 4335 + std::mutex mutex; 4336 + std::weak_ptr session; 4337 +}; 4338 + 4339 +SwSplash::SwSplash() : self{std::make_shared()} {} 4340 + 4341 +SwSplash::~SwSplash() = default; 4342 + 4343 +void SwSplash::operator()(std::weak_ptr const& session) 4344 +{ 4345 + std::lock_guardmutex)> lock{self->mutex}; 4346 + self->session = session; 4347 +} 4348 + 4349 +auto SwSplash::session() const -> std::weak_ptr 4350 +{ 4351 + std::lock_guardmutex)> lock{self->mutex}; 4352 + return self->session; 4353 +} 4354 + 4355 +void SwSplash::operator()(MirConnection* connection) 4356 +{ 4357 + MirPixelFormat pixel_format = find_8888_format(connection); 4358 + 4359 + uint8_t pattern[4] = { 0x14, 0x48, 0xDD, 0xFF }; 4360 + 4361 + switch(pixel_format) 4362 + { 4363 + case mir_pixel_format_abgr_8888: 4364 + case mir_pixel_format_xbgr_8888: 4365 + std::swap(pattern[2],pattern[0]); 4366 + break; 4367 + 4368 + case mir_pixel_format_argb_8888: 4369 + case mir_pixel_format_xrgb_8888: 4370 + break; 4371 + 4372 + default: 4373 + return; 4374 + }; 4375 + 4376 + 4377 + mir::client::Surface surface{mir_connection_create_render_surface_sync(connection, 42, 42)}; 4378 + MirBufferStream* buffer_stream = mir_render_surface_get_buffer_stream(surface, 42, 42, pixel_format); 4379 + 4380 + auto const window = create_window(connection, surface); 4381 + 4382 + MirGraphicsRegion graphics_region; 4383 + 4384 + auto const time_limit = std::chrono::steady_clock::now() + std::chrono::seconds(2); 4385 + 4386 + do 4387 + { 4388 + mir_buffer_stream_get_graphics_region(buffer_stream, &graphics_region); 4389 + 4390 + render_pattern(&graphics_region, pattern); 4391 + mir_buffer_stream_swap_buffers_sync(buffer_stream); 4392 + 4393 + for (auto& x : pattern) 4394 + x = 3*x/4; 4395 + 4396 + std::this_thread::sleep_for(std::chrono::milliseconds(200)); 4397 + } 4398 + while (std::chrono::steady_clock::now() < time_limit); 4399 +} 4400 4401 === added file 'examples/miral-kiosk/sw_splash.h' 4402 --- examples/miral-kiosk/sw_splash.h 1970-01-01 00:00:00 +0000 4403 +++ examples/miral-kiosk/sw_splash.h 2017-10-11 15:01:23 +0000 4404 @@ -0,0 +1,44 @@ 4405 +/* 4406 + * Copyright © 2016 Canonical Ltd. 4407 + * 4408 + * This program is free software: you can redistribute it and/or modify it 4409 + * under the terms of the GNU General Public License version 2 or 3 as 4410 + * published by the Free Software Foundation. 4411 + * 4412 + * This program is distributed in the hope that it will be useful, 4413 + * but WITHOUT ANY WARRANTY; without even the implied warranty of 4414 + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 4415 + * GNU General Public License for more details. 4416 + * 4417 + * You should have received a copy of the GNU General Public License 4418 + * along with this program. If not, see . 4419 + * 4420 + * Authored by: Alan Griffiths 4421 + */ 4422 + 4423 +#ifndef MIRAL_SHELL_SW_SPLASH_H 4424 +#define MIRAL_SHELL_SW_SPLASH_H 4425 + 4426 +#include 4427 + 4428 +#include 4429 + 4430 +namespace mir { class Server; namespace scene { class Session; }} 4431 + 4432 +// A very simple s/w rendered splash animation 4433 +class SwSplash 4434 +{ 4435 +public: 4436 + SwSplash(); 4437 + ~SwSplash(); 4438 + 4439 + void operator()(MirConnection* connection); 4440 + void operator()(std::weak_ptr const& session); 4441 + auto session() const -> std::weak_ptr; 4442 + 4443 +private: 4444 + struct Self; 4445 + std::shared_ptr const self; 4446 +}; 4447 + 4448 +#endif //MIRAL_SHELL_SW_SPLASH_H 4449 4450 === added directory 'examples/miral-shell' 4451 === added file 'examples/miral-shell/CMakeLists.txt' 4452 --- examples/miral-shell/CMakeLists.txt 1970-01-01 00:00:00 +0000 4453 +++ examples/miral-shell/CMakeLists.txt 2017-10-11 15:01:23 +0000 4454 @@ -0,0 +1,69 @@ 4455 +include_directories( 4456 +${PROJECT_SOURCE_DIR}/include/miral 4457 + ${PROJECT_SOURCE_DIR}/include/client 4458 +) 4459 + 4460 +add_subdirectory(spinner) 4461 +add_subdirectory(desktop) 4462 + 4463 +add_custom_target(miral-run ALL 4464 + cp${CMAKE_CURRENT_SOURCE_DIR}/miral-run.sh ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/miral-run 4465 +) 4466 + 4467 +install(PROGRAMS${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/miral-run 4468 + DESTINATION ${CMAKE_INSTALL_PREFIX}/bin 4469 +) 4470 + 4471 +add_custom_target(miral-xrun ALL 4472 + cp${CMAKE_CURRENT_SOURCE_DIR}/miral-xrun.sh ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/miral-xrun 4473 +) 4474 + 4475 +install(PROGRAMS${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/miral-xrun 4476 + DESTINATION ${CMAKE_INSTALL_PREFIX}/bin 4477 +) 4478 + 4479 +add_custom_target(miral-screencast ALL 4480 + cp${CMAKE_CURRENT_SOURCE_DIR}/miral-screencast.sh ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/miral-screencast 4481 +) 4482 + 4483 +install(PROGRAMS${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/miral-screencast 4484 + DESTINATION ${CMAKE_INSTALL_PREFIX}/bin 4485 +) 4486 + 4487 +add_custom_target(miral-desktop ALL 4488 + cp${CMAKE_CURRENT_SOURCE_DIR}/miral-desktop.sh ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/miral-desktop 4489 +) 4490 + 4491 +install(PROGRAMS${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/miral-desktop 4492 + DESTINATION ${CMAKE_INSTALL_PREFIX}/bin 4493 +) 4494 + 4495 +add_custom_target(miral-app ALL 4496 + cp${CMAKE_CURRENT_SOURCE_DIR}/miral-app.sh ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/miral-app 4497 +) 4498 + 4499 +install(PROGRAMS${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/miral-app 4500 + DESTINATION ${CMAKE_INSTALL_PREFIX}/bin 4501 +) 4502 + 4503 +add_library(miral-shell-lib STATIC 4504 + tiling_window_manager.cpp tiling_window_manager.h 4505 + floating_window_manager.cpp floating_window_manager.h 4506 + decoration_provider.cpp decoration_provider.h 4507 + titlebar_config.cpp titlebar_config.h 4508 +) 4509 + 4510 +pkg_check_modules(FREETYPE freetype2 REQUIRED) 4511 +target_include_directories(miral-shell-lib PRIVATE${FREETYPE_INCLUDE_DIRS}) 4512 +target_compile_definitions(miral-shell-lib PRIVATE -DTYPO_SUPPORTS_FREETYPE) 4513 +target_link_libraries(miral-shell-lib miral-spinner miral \${FREETYPE_LIBRARIES}) 4514 + 4515 +mir_add_wrapped_executable(miral-shell 4516 + shell_main.cpp 4517 +) 4518 + 4519 +target_link_libraries(miral-shell 4520 + miral-shell-lib 4521 + miral 4522 +) 4523 + 4524 4525 === added file 'examples/miral-shell/decoration_provider.cpp' 4526 --- examples/miral-shell/decoration_provider.cpp 1970-01-01 00:00:00 +0000 4527 +++ examples/miral-shell/decoration_provider.cpp 2017-10-11 15:01:23 +0000 4528 @@ -0,0 +1,666 @@ 4529 +/* 4530 + * Copyright © 2016-2017 Canonical Ltd. 4531 + * 4532 + * This program is free software: you can redistribute it and/or modify it 4533 + * under the terms of the GNU General Public License version 2 or 3 as 4534 + * published by the Free Software Foundation. 4535 + * 4536 + * This program is distributed in the hope that it will be useful, 4537 + * but WITHOUT ANY WARRANTY; without even the implied warranty of 4538 + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 4539 + * GNU General Public License for more details. 4540 + * 4541 + * You should have received a copy of the GNU General Public License 4542 + * along with this program. If not, see . 4543 + * 4544 + * Authored by: Alan Griffiths 4545 + */ 4546 + 4547 +#include "decoration_provider.h" 4548 +#include "titlebar_config.h" 4549 + 4550 +#include 4551 +#include 4552 + 4553 +#include 4554 + 4555 +#include 4556 +#include FT_FREETYPE_H 4557 + 4558 +#include 4559 +#include 4560 +#include 4561 +#include 4562 +#include 4563 + 4564 +#include 4565 + 4566 +namespace 4567 +{ 4568 +int const title_bar_height = 12; 4569 +char const* const wallpaper_name = "wallpaper"; 4570 + 4571 +void null_window_callback(MirWindow*, void*) {} 4572 + 4573 +struct preferred_codecvt : std::codecvt_byname 4574 +{ 4575 + preferred_codecvt() : std::codecvt_byname("") {} 4576 + ~preferred_codecvt() = default; 4577 +}; 4578 + 4579 +struct Printer 4580 +{ 4581 + Printer(); 4582 + ~Printer(); 4583 + Printer(Printer const&) = delete; 4584 + Printer& operator=(Printer const&) = delete; 4585 + 4586 + void print(MirGraphicsRegion const& region, std::string const& title, int const intensity); 4587 + void printhelp(MirGraphicsRegion const& region); 4588 + 4589 +private: 4590 + std::wstring_convert converter; 4591 + 4592 + bool working = false; 4593 + FT_Library lib; 4594 + FT_Face face; 4595 +}; 4596 + 4597 +void paint_surface(MirBufferStream* buffer_stream, std::string const& title, int const intensity) 4598 +{ 4599 + // TODO sometimes buffer_stream is nullptr - find out why (and fix). 4600 + // (Only observed when creating a lot of clients at once) 4601 + if (!buffer_stream) 4602 + return; 4603 + 4604 + MirGraphicsRegion region; 4605 + mir_buffer_stream_get_graphics_region(buffer_stream, ®ion); 4606 + 4607 + char* row = region.vaddr; 4608 + 4609 + for (int j = 0; j != region.height; ++j) 4610 + { 4611 + memset(row, intensity, 4*region.width); 4612 + row += region.stride; 4613 + } 4614 + 4615 + static Printer printer; 4616 + printer.print(region, title, intensity); 4617 + 4618 + mir_buffer_stream_swap_buffers_sync(buffer_stream); 4619 +} 4620 + 4621 +Printer::Printer() 4622 +{ 4623 + if (FT_Init_FreeType(&lib)) 4624 + return; 4625 + 4626 + if (FT_New_Face(lib, titlebar::font_file().c_str(), 0, &face)) 4627 + { 4628 + std::cerr << "WARNING: failed to load titlebar font: \"" << titlebar::font_file() << "\"\n"; 4629 + FT_Done_FreeType(lib); 4630 + return; 4631 + } 4632 + 4633 + FT_Set_Pixel_Sizes(face, 0, 10); 4634 + working = true; 4635 +} 4636 + 4637 +Printer::~Printer() 4638 +{ 4639 + if (working) 4640 + { 4641 + FT_Done_Face(face); 4642 + FT_Done_FreeType(lib); 4643 + } 4644 +} 4645 + 4646 +void Printer::print(MirGraphicsRegion const& region, std::string const& title_, int const intensity) 4647 +try 4648 +{ 4649 + if (!working) 4650 + return; 4651 + 4652 + auto title = converter.from_bytes(title_); 4653 + 4654 + int base_x = 2; 4655 + int base_y = region.height-2; 4656 + 4657 + for (auto const& ch : title) 4658 + { 4659 + FT_Load_Glyph(face, FT_Get_Char_Index(face, ch), FT_LOAD_DEFAULT); 4660 + auto const glyph = face->glyph; 4661 + FT_Render_Glyph(glyph, FT_RENDER_MODE_NORMAL); 4662 + 4663 + auto const& bitmap = glyph->bitmap; 4664 + auto const x = base_x + glyph->bitmap_left; 4665 + 4666 + if (static_cast(x + bitmap.width) <= region.width) 4667 + { 4668 + unsigned char* src = bitmap.buffer; 4669 + 4670 + auto const y = base_y - glyph->bitmap_top; 4671 + char* dest = region.vaddr + y*region.stride + 4*x; 4672 + 4673 + for (auto row = 0u; row != std::min(bitmap.rows, glyph->bitmap_top+2u); ++row) 4674 + { 4675 + for (auto col = 0u; col != bitmap.width; ++col) 4676 + memset(dest+ 4*col, (intensity*(0xff^src[col]))/0xff, 4); 4677 + 4678 + src += bitmap.pitch; 4679 + dest += region.stride; 4680 + } 4681 + } 4682 + 4683 + base_x += glyph->advance.x >> 6; 4684 + base_y += glyph->advance.y >> 6; 4685 + } 4686 +} 4687 +catch (...) 4688 +{ 4689 + std::cerr << "WARNING: failed render title: \"" << title_ << "\"\n"; 4690 +} 4691 + 4692 +void Printer::printhelp(MirGraphicsRegion const& region) 4693 +{ 4694 + if (!working) 4695 + return; 4696 + 4697 + static char const* const helptext[] = 4698 + { 4699 + "Welcome to miral-shell", 4700 + "", 4701 + "Keyboard shortcuts:", 4702 + "", 4703 + " o Switch apps: Alt-Tab, tap or click on the corresponding window", 4704 + " o Next (previous) app window: Alt- (Alt-Shift-)", 4705 + "", 4706 + " o Move window: Alt-leftmousebutton drag (three finger drag)", 4707 + " o Resize window: Alt-middle_button drag (three finger pinch)", 4708 + "", 4709 + " o Maximize/restore current window (to display size). : Alt-F11", 4710 + " o Maximize/restore current window (to display height): Shift-F11", 4711 + " o Maximize/restore current window (to display width) : Ctrl-F11", 4712 + "", 4713 + " o Switch workspace: Meta-Alt-[F1|F2|F3|F4]", 4714 + " o Switch workspace taking active window: Meta-Ctrl-[F1|F2|F3|F4]", 4715 + "", 4716 + " o To exit: Ctrl-Alt-BkSp", 4717 + }; 4718 + 4719 + int help_width = 0; 4720 + unsigned int help_height = 0; 4721 + unsigned int line_height = 0; 4722 + 4723 + for (auto const* rawline : helptext) 4724 + { 4725 + int line_width = 0; 4726 + 4727 + auto const line = converter.from_bytes(rawline); 4728 + 4729 + auto const fwidth = std::min(region.width / 60, 20); 4730 + 4731 + FT_Set_Pixel_Sizes(face, fwidth, 0); 4732 + 4733 + for (auto const& ch : line) 4734 + { 4735 + FT_Load_Glyph(face, FT_Get_Char_Index(face, ch), FT_LOAD_DEFAULT); 4736 + auto const glyph = face->glyph; 4737 + FT_Render_Glyph(glyph, FT_RENDER_MODE_NORMAL); 4738 + 4739 + line_width += glyph->advance.x >> 6; 4740 + line_height = std::max(line_height, glyph->bitmap.rows + glyph->bitmap.rows/2); 4741 + } 4742 + 4743 + if (help_width < line_width) help_width = line_width; 4744 + help_height += line_height; 4745 + } 4746 + 4747 + int base_y = (region.height - help_height)/2; 4748 + 4749 + for (auto const* rawline : helptext) 4750 + { 4751 + int base_x = (region.width - help_width)/2; 4752 + 4753 + auto const line = converter.from_bytes(rawline); 4754 + 4755 + for (auto const& ch : line) 4756 + { 4757 + FT_Load_Glyph(face, FT_Get_Char_Index(face, ch), FT_LOAD_DEFAULT); 4758 + auto const glyph = face->glyph; 4759 + FT_Render_Glyph(glyph, FT_RENDER_MODE_NORMAL); 4760 + 4761 + auto const& bitmap = glyph->bitmap; 4762 + auto const x = base_x + glyph->bitmap_left; 4763 + 4764 + if (static_cast(x + bitmap.width) <= region.width) 4765 + { 4766 + unsigned char* src = bitmap.buffer; 4767 + 4768 + auto const y = base_y - glyph->bitmap_top; 4769 + char* dest = region.vaddr + y * region.stride + 4 * x; 4770 + 4771 + for (auto row = 0u; row != bitmap.rows; ++row) 4772 + { 4773 + for (auto col = 0u; col != 4 * bitmap.width; ++col) 4774 + dest[col] |= src[col / 4]/2; 4775 + 4776 + src += bitmap.pitch; 4777 + dest += region.stride; 4778 + 4779 + if (dest > region.vaddr + region.height * region.stride) 4780 + break; 4781 + } 4782 + } 4783 + 4784 + base_x += glyph->advance.x >> 6; 4785 + } 4786 + base_y += line_height; 4787 + } 4788 +} 4789 + 4790 +void render_background(MirBufferStream* buffer_stream, MirGraphicsRegion& graphics_region) 4791 +{ 4792 + static uint8_t const pattern[4] = {0x00, 0x00, 0x00, 0x00 }; 4793 + 4794 + char* row = (&graphics_region)->vaddr; 4795 + 4796 + for (int j = 0; j < (&graphics_region)->height; j++) 4797 + { 4798 + uint32_t* pixel = (uint32_t*)row; 4799 + 4800 + for (int i = 0; i < (&graphics_region)->width; i++) 4801 + memcpy(pixel + i, pattern, sizeof pixel[i]); 4802 + 4803 + row += (&graphics_region)->stride; 4804 + } 4805 + 4806 + static Printer printer; 4807 + printer.printhelp(*&graphics_region); 4808 + 4809 + mir_buffer_stream_swap_buffers_sync(buffer_stream); 4810 +} 4811 +} 4812 + 4813 +using namespace mir::client; 4814 +using namespace mir::geometry; 4815 + 4816 +DecorationProvider::DecorationProvider(miral::WindowManagerTools const& tools) : tools{tools} 4817 +{ 4818 + 4819 +} 4820 + 4821 +DecorationProvider::~DecorationProvider() 4822 +{ 4823 +} 4824 + 4825 +void DecorationProvider::stop() 4826 +{ 4827 + enqueue_work([this] 4828 + { 4829 + std::lock_guard lock{mutex}; 4830 + window_to_titlebar.clear(); 4831 + }); 4832 + 4833 + enqueue_work([this] 4834 + { 4835 + if (connection) 4836 + { 4837 + wallpaper.erase(begin(wallpaper), end(wallpaper)); 4838 + } 4839 + connection.reset(); 4840 + }); 4841 + stop_work(); 4842 +} 4843 + 4844 +void DecorationProvider::operator()(Connection connection) 4845 +{ 4846 + this->connection = connection; 4847 + 4848 + DisplayConfig const display_conf{this->connection}; 4849 + 4850 + display_conf.for_each_output([this](MirOutput const* output) 4851 + { 4852 + if (!mir_output_is_enabled(output)) 4853 + return; 4854 + 4855 + auto const mode = mir_output_get_current_mode(output); 4856 + auto const output_id = mir_output_get_id(output); 4857 + auto const width = mir_output_mode_get_width(mode); 4858 + auto const height = mir_output_mode_get_height(mode); 4859 + 4860 + Surface surface{mir_connection_create_render_surface_sync(DecorationProvider::connection, width, height)}; 4861 + 4862 + auto const buffer_stream = 4863 + mir_render_surface_get_buffer_stream(surface, width, height, mir_pixel_format_xrgb_8888); 4864 + 4865 + auto window = WindowSpec::for_gloss(DecorationProvider::connection, width, height) 4866 + .set_fullscreen_on_output(output_id) 4867 + .set_event_handler(&handle_event_for_background, this) 4868 + .add_surface(surface, width, height, 0, 0) 4869 + .set_name(wallpaper_name).create_window(); 4870 + 4871 + wallpaper.push_back(Wallpaper{surface, window, buffer_stream}); 4872 + 4873 + MirGraphicsRegion graphics_region; 4874 + mir_buffer_stream_get_graphics_region(buffer_stream, &graphics_region); 4875 + render_background(buffer_stream, graphics_region); 4876 + }); 4877 + 4878 + start_work(); 4879 +} 4880 + 4881 +void DecorationProvider::operator()(std::weak_ptr const& session) 4882 +{ 4883 + std::lock_guard lock{mutex}; 4884 + this->weak_session = session; 4885 +} 4886 + 4887 +auto DecorationProvider::session() const -> std::shared_ptr 4888 +{ 4889 + std::lock_guard lock{mutex}; 4890 + return weak_session.lock(); 4891 +} 4892 + 4893 +void DecorationProvider::handle_event(MirWindow* window, MirEvent const* ev, void* context_) 4894 +{ 4895 + auto* const context = (Data*)context_; 4896 + 4897 + switch (mir_event_get_type(ev)) 4898 + { 4899 + case mir_event_type_resize: 4900 + { 4901 + MirResizeEvent const* resize = mir_event_get_resize_event(ev); 4902 + int const new_width = mir_resize_event_get_width(resize); 4903 + int const new_height = mir_resize_event_get_height(resize); 4904 + mir_render_surface_set_size(context->surface, new_width, new_height); 4905 + WindowSpec::for_changes(context->connection) 4906 + .add_surface(context->surface, new_width, new_height, 0, 0) 4907 + .apply_to(window); 4908 + break; 4909 + } 4910 + 4911 + default: 4912 + break; 4913 + } 4914 +} 4915 + 4916 +void DecorationProvider::create_titlebar_for(miral::Window const& window) 4917 +{ 4918 + if (is_decoration(window)) return; 4919 + 4920 + enqueue_work([this, window] 4921 + { 4922 + auto const width = window.size().width.as_int(); 4923 + std::ostringstream buffer; 4924 + buffer << std::shared_ptr(window).get(); 4925 + 4926 + Surface surface{mir_connection_create_render_surface_sync(this->connection, width, title_bar_height)}; 4927 + 4928 + std::lock_guard lock{mutex}; 4929 + 4930 + auto const data = &window_to_titlebar[window]; 4931 + data->connection = connection; 4932 + data->surface = surface; 4933 + data->stream = mir_render_surface_get_buffer_stream(surface, width, title_bar_height, mir_pixel_format_xrgb_8888); 4934 + windows_awaiting_titlebar[buffer.str()] = window; 4935 + 4936 + WindowSpec::for_gloss(connection, width, title_bar_height) 4937 + .add_surface(surface, width, title_bar_height, 0, 0) 4938 + .set_name(buffer.str().c_str()) 4939 + .set_event_handler(&handle_event, data) 4940 + .create_window(insert, data); 4941 + }); 4942 +} 4943 + 4944 +void DecorationProvider::paint_titlebar_for(miral::WindowInfo const& info, int intensity) 4945 +{ 4946 + if (auto data = find_titlebar_data(info.window())) 4947 + { 4948 + data->intensity = intensity; 4949 + 4950 + auto const title = info.name(); 4951 + 4952 + enqueue_work([stream=data->stream, title, intensity]{ paint_surface(stream, title, intensity); }); 4953 + } 4954 +} 4955 + 4956 +void DecorationProvider::destroy_titlebar_for(miral::Window const& window) 4957 +{ 4958 + if (auto data = find_titlebar_data(window)) 4959 + { 4960 + if (auto surface = data->titlebar.exchange(nullptr)) 4961 + { 4962 + enqueue_work([surface] 4963 + { 4964 + mir_window_release(surface, &null_window_callback, nullptr); 4965 + }); 4966 + } 4967 + 4968 + if (data->titlebar.load()) 4969 + { 4970 + enqueue_work([this, window] 4971 + { 4972 + std::lock_guard lock{mutex}; 4973 + window_to_titlebar.erase(window); 4974 + }); 4975 + } 4976 + else 4977 + { 4978 + data->on_create = [this, window](MirWindow*) 4979 + { 4980 + enqueue_work([this, window] 4981 + { 4982 + std::lock_guard lock{mutex}; 4983 + window_to_titlebar.erase(window); 4984 + }); 4985 + }; 4986 + } 4987 + } 4988 +} 4989 + 4990 +void DecorationProvider::resize_titlebar_for(miral::WindowInfo const& window_info, Size const& size) 4991 +{ 4992 + auto const window = window_info.window(); 4993 + 4994 + if (window.size().width == size.width) 4995 + return; 4996 + 4997 + if (auto titlebar_window = find_titlebar_window(window)) 4998 + { 4999 + titlebar_window.resize({size.width, title_bar_height}); 5000 +
The diff has been truncated for viewing.

## Subscribers

People subscribed via source and target branches

to all changes: