Mir

Merge lp:~robertcarr/mir/dedupe-null-display-config into lp:~mir-team/mir/trunk

Proposed by Robert Carr
Status: Merged
Approved by: Alexandros Frantzis
Approved revision: no longer in the source branch.
Merged at revision: 1057
Proposed branch: lp:~robertcarr/mir/dedupe-null-display-config
Merge into: lp:~mir-team/mir/trunk
Diff against target: 102 lines (+3/-55)
4 files modified
include/test/mir_test_doubles/null_display_changer.h (+2/-2)
include/test/mir_test_doubles/null_display_config.h (+0/-51)
tests/integration-tests/test_display_info.cpp (+0/-1)
tests/unit-tests/frontend/test_session_mediator.cpp (+1/-1)
To merge this branch: bzr merge lp:~robertcarr/mir/dedupe-null-display-config
Reviewer Review Type Date Requested Status
PS Jenkins bot (community) continuous-integration Approve
Daniel van Vugt Approve
Kevin DuBois (community) Approve
Review via email: mp+184664@code.launchpad.net

Commit message

Deduplicate mtd::NullDisplayConfig and mtd::NullDisplayConfiguration

Description of the change

Dedupe NullDisplayConfig/Configuration

To post a comment you must log in.
Revision history for this message
PS Jenkins bot (ps-jenkins) wrote :
review: Approve (continuous-integration)
Revision history for this message
Kevin DuBois (kdub) wrote :

ok

review: Approve
Revision history for this message
Daniel van Vugt (vanvugt) :
review: Approve
Revision history for this message
PS Jenkins bot (ps-jenkins) wrote :
review: Needs Fixing (continuous-integration)
Revision history for this message
PS Jenkins bot (ps-jenkins) :
review: Approve (continuous-integration)

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'include/test/mir_test_doubles/null_display_changer.h'
2--- include/test/mir_test_doubles/null_display_changer.h 2013-08-28 03:41:48 +0000
3+++ include/test/mir_test_doubles/null_display_changer.h 2013-09-09 19:12:27 +0000
4@@ -20,7 +20,7 @@
5 #define MIR_TEST_DOUBLES_NULL_DISPLAY_CHANGER_H_
6
7 #include "mir/frontend/display_changer.h"
8-#include "null_display_config.h"
9+#include "null_display_configuration.h"
10
11 namespace mir
12 {
13@@ -34,7 +34,7 @@
14 public:
15 virtual std::shared_ptr<graphics::DisplayConfiguration> active_configuration()
16 {
17- return std::make_shared<NullDisplayConfig>();
18+ return std::make_shared<NullDisplayConfiguration>();
19 }
20 virtual void configure(std::shared_ptr<frontend::Session> const&, std::shared_ptr<graphics::DisplayConfiguration> const&)
21 {
22
23=== removed file 'include/test/mir_test_doubles/null_display_config.h'
24--- include/test/mir_test_doubles/null_display_config.h 2013-09-06 03:46:37 +0000
25+++ include/test/mir_test_doubles/null_display_config.h 1970-01-01 00:00:00 +0000
26@@ -1,51 +0,0 @@
27-/*
28- * Copyright © 2013 Canonical Ltd.
29- *
30- * This program is free software: you can redistribute it and/or modify it
31- * under the terms of the GNU General Public License version 3,
32- * as published by the Free Software Foundation.
33- *
34- * This program is distributed in the hope that it will be useful,
35- * but WITHOUT ANY WARRANTY; without even the implied warranty of
36- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
37- * GNU General Public License for more details.
38- *
39- * You should have received a copy of the GNU General Public License
40- * along with this program. If not, see <http://www.gnu.org/licenses/>.
41- *
42- * Authored by: Kevin DuBois <kevin.dubois@canonical.com>
43- */
44-
45-#ifndef MIR_TEST_DOUBLES_NULL_DISPLAY_CONFIG_H_
46-#define MIR_TEST_DOUBLES_NULL_DISPLAY_CONFIG_H_
47-
48-#include "mir/graphics/display_configuration.h"
49-
50-namespace mir
51-{
52-namespace test
53-{
54-namespace doubles
55-{
56-
57-struct NullDisplayConfig : public graphics::DisplayConfiguration
58-{
59- NullDisplayConfig()
60- {
61- }
62- virtual void for_each_card(std::function<void(graphics::DisplayConfigurationCard const&)>) const
63- {
64- }
65- virtual void for_each_output(std::function<void(graphics::DisplayConfigurationOutput const&)>) const
66- {
67- }
68- virtual void configure_output(graphics::DisplayConfigurationOutputId, bool, geometry::Point, size_t, MirPowerMode)
69- {
70- }
71-};
72-
73-}
74-}
75-}
76-
77-#endif /*MIR_TEST_DOUBLES_NULL_DISPLAY_CONFIG_H_ */
78
79=== modified file 'tests/integration-tests/test_display_info.cpp'
80--- tests/integration-tests/test_display_info.cpp 2013-08-28 03:41:48 +0000
81+++ tests/integration-tests/test_display_info.cpp 2013-09-09 19:12:27 +0000
82@@ -30,7 +30,6 @@
83 #include "mir_test_doubles/stub_buffer.h"
84 #include "mir_test_doubles/null_display.h"
85 #include "mir_test_doubles/null_event_sink.h"
86-#include "mir_test_doubles/null_display_config.h"
87 #include "mir_test_doubles/null_display_changer.h"
88 #include "mir_test_doubles/stub_display_buffer.h"
89 #include "mir_test_doubles/null_platform.h"
90
91=== modified file 'tests/unit-tests/frontend/test_session_mediator.cpp'
92--- tests/unit-tests/frontend/test_session_mediator.cpp 2013-09-06 03:46:37 +0000
93+++ tests/unit-tests/frontend/test_session_mediator.cpp 2013-09-09 19:12:27 +0000
94@@ -61,7 +61,7 @@
95
96 namespace
97 {
98-struct StubConfig : public mtd::NullDisplayConfig
99+struct StubConfig : public mtd::NullDisplayConfiguration
100 {
101 StubConfig(std::shared_ptr<mg::DisplayConfigurationOutput> const& conf)
102 : outputs{conf, conf}

Subscribers

People subscribed via source and target branches