~albaguirre/mir/backport-fixes-to-0.11

« back to all changes in this revision

Viewing changes to src/include/server/mir/default_server_configuration.h

  • Committer: Tarmac
  • Author(s): Alan Griffiths
  • Date: 2015-01-28 20:21:34 UTC
  • mfrom: (2257.1.31 mir3)
  • Revision ID: tarmac-20150128202134-dn97lf8gwk0xcqbc
shell, frontend: Provide a mir::shell::Shell customization point.

Approved by PS Jenkins bot, Kevin DuBois, Alexandros Frantzis.

Show diffs side-by-side

added added

removed removed

Lines of Context:
76
76
class FocusController;
77
77
class DisplayLayout;
78
78
class HostLifecycleEventListener;
79
 
class DefaultShell;
 
79
class Shell;
 
80
namespace detail { class FrontendShell; }
80
81
}
81
82
namespace time
82
83
{
228
229
    virtual std::shared_ptr<frontend::SessionMediatorReport>  the_session_mediator_report();
229
230
    virtual std::shared_ptr<frontend::MessageProcessorReport> the_message_processor_report();
230
231
    virtual std::shared_ptr<frontend::SessionAuthorizer>      the_session_authorizer();
231
 
    // the_frontend_shell() is an adapter for the_session_coordinator().
232
 
    // To customize this behaviour it is recommended you override wrap_session_coordinator().
 
232
    // the_frontend_shell() is an adapter for the_shell().
 
233
    // To customize this behaviour it is recommended you override wrap_shell().
233
234
    std::shared_ptr<frontend::Shell>                          the_frontend_shell();
234
235
    virtual std::shared_ptr<frontend::EventSink>              the_global_event_sink();
235
236
    virtual std::shared_ptr<frontend::DisplayChanger>         the_frontend_display_changer();
243
244
    /** @} */
244
245
    /** @} */
245
246
 
246
 
    // the_focus_controller() is an adapter for the_session_coordinator().
247
 
    // To customize this behaviour it is recommended you override wrap_session_coordinator().
 
247
    // the_focus_controller() is an interface for the_shell().
248
248
    std::shared_ptr<shell::FocusController> the_focus_controller();
249
249
 
250
250
    /** @name shell configuration - customization
251
251
     * configurable interfaces for modifying shell
252
252
     *  @{ */
 
253
    virtual auto the_shell() -> std::shared_ptr<shell::Shell>;
253
254
    virtual std::shared_ptr<scene::PlacementStrategy>   the_placement_strategy();
254
255
    virtual std::shared_ptr<scene::SessionListener>     the_session_listener();
255
256
    virtual std::shared_ptr<shell::DisplayLayout>       the_shell_display_layout();
284
285
    /** @name scene configuration - services
285
286
     * services provided by scene for the rest of Mir
286
287
     *  @{ */
287
 
    // To customize this behaviour it is recommended you override wrap_session_coordinator().
288
288
    virtual std::shared_ptr<scene::SessionCoordinator>  the_session_coordinator();
289
289
    virtual std::shared_ptr<scene::CoordinateTranslator> the_coordinate_translator();
290
290
    /** @} */
342
342
    virtual std::shared_ptr<graphics::DisplayConfigurationPolicy> wrap_display_configuration_policy(
343
343
        std::shared_ptr<graphics::DisplayConfigurationPolicy> const& wrapped);
344
344
 
345
 
    virtual std::shared_ptr<scene::SurfaceCoordinator>  wrap_surface_coordinator(
346
 
        std::shared_ptr<scene::SurfaceCoordinator> const& wrapped);
347
 
 
348
 
    virtual std::shared_ptr<scene::SessionCoordinator>  wrap_session_coordinator(
349
 
        std::shared_ptr<scene::SessionCoordinator> const& wrapped);
 
345
    virtual std::shared_ptr<shell::Shell>  wrap_shell(
 
346
        std::shared_ptr<shell::Shell> const& wrapped);
350
347
 
351
348
    virtual std::shared_ptr<input::CursorListener>  wrap_cursor_listener(
352
349
        std::shared_ptr<input::CursorListener> const& wrapped);
400
397
    CachedPtr<scene::SurfaceFactory> surface_factory;
401
398
    CachedPtr<scene::SessionContainer>  session_container;
402
399
    CachedPtr<scene::SurfaceCoordinator> surface_coordinator;
403
 
    CachedPtr<scene::PlacementStrategy> shell_placement_strategy;
 
400
    CachedPtr<scene::PlacementStrategy> placement_strategy;
404
401
    CachedPtr<scene::SessionListener> session_listener;
405
402
    CachedPtr<scene::PixelBuffer>       pixel_buffer;
406
403
    CachedPtr<scene::SnapshotStrategy>  snapshot_strategy;
426
423
    CachedPtr<EmergencyCleanup> emergency_cleanup;
427
424
    CachedPtr<shell::HostLifecycleEventListener> host_lifecycle_event_listener;
428
425
    CachedPtr<SharedLibraryProberReport> shared_library_prober_report;
 
426
    CachedPtr<shell::Shell> shell;
429
427
 
430
428
private:
431
429
    std::shared_ptr<options::Configuration> const configuration_options;
441
439
 
442
440
    auto report_factory(char const* report_opt) -> std::unique_ptr<report::ReportFactory>;
443
441
 
444
 
    // TODO properly expose a shell::Shell interface
445
 
    CachedPtr<shell::DefaultShell> default_shell;
446
 
    auto the_shell() -> std::shared_ptr<shell::DefaultShell>;
 
442
    CachedPtr<shell::detail::FrontendShell> frontend_shell;
447
443
};
448
444
}
449
445