~ubuntu-branches/ubuntu/vivid/mir/vivid

« back to all changes in this revision

Viewing changes to tests/integration-tests/graphics/android/test_internal_client.cpp

  • Committer: Package Import Robot
  • Author(s): Ubuntu daily release
  • Date: 2014-01-08 02:04:38 UTC
  • mto: This revision was merged to the branch mainline in revision 58.
  • Revision ID: package-import@ubuntu.com-20140108020438-e1npu0pm7qdv5wc4
Tags: upstream-0.1.3+14.04.20140108
ImportĀ upstreamĀ versionĀ 0.1.3+14.04.20140108

Show diffs side-by-side

added added

removed removed

Lines of Context:
16
16
 * Authored by: Kevin DuBois <kevin.dubois@canonical.com>
17
17
 */
18
18
 
19
 
#include "src/server/graphics/android/android_graphic_buffer_allocator.h"
20
 
#include "src/server/graphics/android/internal_client_window.h"
21
 
#include "src/server/graphics/android/interpreter_cache.h"
22
 
#include "src/server/graphics/android/internal_client.h"
 
19
#include "src/platform/graphics/android/android_graphic_buffer_allocator.h"
 
20
#include "src/platform/graphics/android/internal_client_window.h"
 
21
#include "src/platform/graphics/android/interpreter_cache.h"
 
22
#include "src/platform/graphics/android/internal_client.h"
23
23
#include "src/server/compositor/buffer_stream_factory.h"
24
24
#include "mir/graphics/buffer_initializer.h"
25
25
#include "mir/graphics/null_display_report.h"
68
68
    }
69
69
};
70
70
 
71
 
struct StubInputFactory : public mi::InputChannelFactory 
 
71
struct StubInputFactory : public mi::InputChannelFactory
72
72
{
73
73
    std::shared_ptr<mi::InputChannel> make_input_channel()
74
74
    {
80
80
TEST_F(AndroidInternalClient, internal_client_creation_and_use)
81
81
{
82
82
    auto size = geom::Size{334, 122};
83
 
    auto pf  = geom::PixelFormat::abgr_8888;
 
83
    auto pf  = mir_pixel_format_abgr_8888;
84
84
    msh::SurfaceCreationParameters params;
85
85
    params.name = std::string("test");
86
 
    params.size = size; 
 
86
    params.size = size;
87
87
    params.pixel_format = pf;
88
88
    params.buffer_usage = mg::BufferUsage::hardware;
89
89
    auto id = mf::SurfaceId{4458};
101
101
    auto mir_surface = as_internal_surface(
102
102
        surface_source->create_surface(nullptr, params, id, std::shared_ptr<mf::EventSink>()));
103
103
 
104
 
    auto options = std::shared_ptr<mo::ProgramOption>(); 
105
 
    auto report = std::shared_ptr<mg::NullDisplayReport>(); 
 
104
    auto options = std::shared_ptr<mo::ProgramOption>();
 
105
    auto report = std::shared_ptr<mg::NullDisplayReport>();
106
106
    auto internal_client = std::make_shared<mga::InternalClient>();
107
107
 
108
108
    int major, minor, n;