summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorUcan, Emre (ADITG/SW1) <eucan@de.adit-jv.com>2017-03-03 14:21:28 +0000
committerPekka Paalanen <pekka.paalanen@collabora.co.uk>2017-07-24 13:32:48 +0300
commit9337197f8223897c7bbd17a33ad9d2a55ef89ddb (patch)
treedc9466ef4eb6354c80b2f065da35f8905d3631a3
parentdeee858b0b199d8cfa8033a46d7078f30b23725e (diff)
ivi-shell: remove surface_set_orientation API
This API is used to rotate the contents of application's buffer. But it is not needed because an application can rotate its buffers with set_buffer_transform request of wl_surface interface. Signed-off-by: Emre Ucan <eucan@de.adit-jv.com> Reviewed-by: Pekka Paalanen <pekka.paalanen@collabora.co.uk>
-rw-r--r--ivi-shell/ivi-layout-export.h9
-rw-r--r--ivi-shell/ivi-layout.c23
-rw-r--r--tests/ivi_layout-internal-test.c9
-rw-r--r--tests/ivi_layout-test-plugin.c34
-rw-r--r--tests/ivi_layout-test.c2
5 files changed, 0 insertions, 77 deletions
diff --git a/ivi-shell/ivi-layout-export.h b/ivi-shell/ivi-layout-export.h
index 39ffde13..f8802544 100644
--- a/ivi-shell/ivi-layout-export.h
+++ b/ivi-shell/ivi-layout-export.h
@@ -276,15 +276,6 @@ struct ivi_layout_interface {
int32_t width, int32_t height);
/**
- * \brief Sets the orientation of a ivi_surface.
- *
- * \return IVI_SUCCEEDED if the method call was successful
- * \return IVI_FAILED if the method call was failed
- */
- int32_t (*surface_set_orientation)(struct ivi_layout_surface *ivisurf,
- enum wl_output_transform orientation);
-
- /**
* \brief add a listener to listen property changes of ivi_surface
*
* When a property of the ivi_surface is changed, the property_changed
diff --git a/ivi-shell/ivi-layout.c b/ivi-shell/ivi-layout.c
index 8e4280ba..3a0d3198 100644
--- a/ivi-shell/ivi-layout.c
+++ b/ivi-shell/ivi-layout.c
@@ -1621,28 +1621,6 @@ ivi_layout_surface_set_destination_rectangle(struct ivi_layout_surface *ivisurf,
}
static int32_t
-ivi_layout_surface_set_orientation(struct ivi_layout_surface *ivisurf,
- enum wl_output_transform orientation)
-{
- struct ivi_layout_surface_properties *prop = NULL;
-
- if (ivisurf == NULL) {
- weston_log("ivi_layout_surface_set_orientation: invalid argument\n");
- return IVI_FAILED;
- }
-
- prop = &ivisurf->pending.prop;
- prop->orientation = orientation;
-
- if (ivisurf->prop.orientation != orientation)
- prop->event_mask |= IVI_NOTIFICATION_ORIENTATION;
- else
- prop->event_mask &= ~IVI_NOTIFICATION_ORIENTATION;
-
- return IVI_SUCCEEDED;
-}
-
-static int32_t
ivi_layout_screen_add_layer(struct weston_output *output,
struct ivi_layout_layer *addlayer)
{
@@ -2074,7 +2052,6 @@ static struct ivi_layout_interface ivi_layout_interface = {
.surface_set_opacity = ivi_layout_surface_set_opacity,
.surface_set_source_rectangle = ivi_layout_surface_set_source_rectangle,
.surface_set_destination_rectangle = ivi_layout_surface_set_destination_rectangle,
- .surface_set_orientation = ivi_layout_surface_set_orientation,
.surface_add_listener = ivi_layout_surface_add_listener,
.surface_get_weston_surface = ivi_layout_surface_get_weston_surface,
.surface_set_transition = ivi_layout_surface_set_transition,
diff --git a/tests/ivi_layout-internal-test.c b/tests/ivi_layout-internal-test.c
index 37a23563..f5e2763f 100644
--- a/tests/ivi_layout-internal-test.c
+++ b/tests/ivi_layout-internal-test.c
@@ -89,14 +89,6 @@ test_surface_bad_destination_rectangle(struct test_context *ctx)
}
static void
-test_surface_bad_orientation(struct test_context *ctx)
-{
- const struct ivi_layout_interface *lyt = ctx->layout_interface;
-
- iassert(lyt->surface_set_orientation(NULL, WL_OUTPUT_TRANSFORM_90) == IVI_FAILED);
-}
-
-static void
test_surface_bad_source_rectangle(struct test_context *ctx)
{
const struct ivi_layout_interface *lyt = ctx->layout_interface;
@@ -939,7 +931,6 @@ run_internal_tests(void *data)
test_surface_bad_visibility(ctx);
test_surface_bad_destination_rectangle(ctx);
- test_surface_bad_orientation(ctx);
test_surface_bad_source_rectangle(ctx);
test_surface_bad_properties(ctx);
diff --git a/tests/ivi_layout-test-plugin.c b/tests/ivi_layout-test-plugin.c
index 609c71ff..19eab81a 100644
--- a/tests/ivi_layout-test-plugin.c
+++ b/tests/ivi_layout-test-plugin.c
@@ -400,29 +400,6 @@ RUNNER_TEST(surface_opacity)
runner_assert(prop->opacity == wl_fixed_from_double(0.5));
}
-RUNNER_TEST(surface_orientation)
-{
- const struct ivi_layout_interface *lyt = ctx->layout_interface;
- struct ivi_layout_surface *ivisurf;
- const struct ivi_layout_surface_properties *prop;
-
- ivisurf = lyt->get_surface_from_id(IVI_TEST_SURFACE_ID(0));
- runner_assert(ivisurf != NULL);
-
- prop = lyt->get_properties_of_surface(ivisurf);
- runner_assert_or_return(prop);
- runner_assert(prop->orientation == WL_OUTPUT_TRANSFORM_NORMAL);
-
- runner_assert(lyt->surface_set_orientation(
- ivisurf, WL_OUTPUT_TRANSFORM_90) == IVI_SUCCEEDED);
-
- runner_assert(prop->orientation == WL_OUTPUT_TRANSFORM_NORMAL);
-
- lyt->commit_changes();
-
- runner_assert(prop->orientation == WL_OUTPUT_TRANSFORM_90);
-}
-
RUNNER_TEST(surface_dimension)
{
const struct ivi_layout_interface *lyt = ctx->layout_interface;
@@ -663,17 +640,6 @@ RUNNER_TEST(commit_changes_after_opacity_set_surface_destroy)
ivisurf, wl_fixed_from_double(0.5)) == IVI_SUCCEEDED);
}
-RUNNER_TEST(commit_changes_after_orientation_set_surface_destroy)
-{
- const struct ivi_layout_interface *lyt = ctx->layout_interface;
- struct ivi_layout_surface *ivisurf;
-
- ivisurf = lyt->get_surface_from_id(IVI_TEST_SURFACE_ID(0));
- runner_assert(ivisurf != NULL);
- runner_assert(lyt->surface_set_orientation(
- ivisurf, WL_OUTPUT_TRANSFORM_90) == IVI_SUCCEEDED);
-}
-
RUNNER_TEST(commit_changes_after_source_rectangle_set_surface_destroy)
{
const struct ivi_layout_interface *lyt = ctx->layout_interface;
diff --git a/tests/ivi_layout-test.c b/tests/ivi_layout-test.c
index 86e63b13..d2f4c935 100644
--- a/tests/ivi_layout-test.c
+++ b/tests/ivi_layout-test.c
@@ -192,7 +192,6 @@ ivi_window_destroy(struct ivi_window *wnd)
const char * const basic_test_names[] = {
"surface_visibility",
"surface_opacity",
- "surface_orientation",
"surface_dimension",
"surface_position",
"surface_destination_rectangle",
@@ -206,7 +205,6 @@ const char * const basic_test_names[] = {
const char * const surface_property_commit_changes_test_names[] = {
"commit_changes_after_visibility_set_surface_destroy",
"commit_changes_after_opacity_set_surface_destroy",
- "commit_changes_after_orientation_set_surface_destroy",
"commit_changes_after_source_rectangle_set_surface_destroy",
"commit_changes_after_destination_rectangle_set_surface_destroy",
};