~kdub/+junk/split-out-old-semantics

« back to all changes in this revision

Viewing changes to src/server/graphics/nested/mir_client_host_connection.cpp

  • Committer: Tarmac
  • Author(s): Alan Griffiths
  • Date: 2016-01-15 14:34:46 UTC
  • mfrom: (3226.5.18 mir1)
  • Revision ID: tarmac-20160115143446-9x0v7bz4ijfr5wj3
Provide information on the selected graphics platform through the client API and use it in nested servers to select the same module. (LP:1515558). Fixes: https://bugs.launchpad.net/bugs/1515558.

Approved by PS Jenkins bot, Brandon Schaefer, Alberto Aguirre, Kevin DuBois, mir-ci-bot, Alexandros Frantzis, Cemil Azizoglu.

Show diffs side-by-side

added added

removed removed

Lines of Context:
317
317
        surface->hide_cursor();
318
318
    }
319
319
}
 
320
 
 
321
auto mgn::MirClientHostConnection::graphics_platform_library() -> std::string
 
322
{
 
323
    MirModuleProperties properties = { nullptr, 0, 0, 0, nullptr };
 
324
 
 
325
    mir_connection_get_graphics_module(mir_connection, &properties);
 
326
 
 
327
    if (properties.filename == nullptr)
 
328
    {
 
329
        BOOST_THROW_EXCEPTION(std::runtime_error("Cannot identify host graphics platform"));
 
330
    }
 
331
 
 
332
    return properties.filename;
 
333
}
 
 
b'\\ No newline at end of file'