diff --git a/clutter/clutter/clutter-clone-accessible-private.h b/clutter/clutter/clutter-clone-accessible-private.h deleted file mode 100644 index 6f3a738a4..000000000 --- a/clutter/clutter/clutter-clone-accessible-private.h +++ /dev/null @@ -1,35 +0,0 @@ -/* CALLY - The Clutter Accessibility Implementation Library - * - * Copyright (C) 2010 Igalia, S.L. - * - * Author: Alejandro Piñeiro Iglesias - * - * This library is free software; you can redistribute it and/or - * modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation; either - * version 2 of the License, or (at your option) any later version. - * - * This library is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Lesser General Public License for more details. - * - * You should have received a copy of the GNU Lesser General Public - * License along with this library. If not, see . - */ - -#pragma once - -#include "clutter/clutter-actor-accessible.h" - -G_BEGIN_DECLS - -#define CLUTTER_TYPE_CLONE_ACCESSIBLE (clutter_clone_accessible_get_type ()) - -G_DECLARE_FINAL_TYPE (ClutterCloneAccessible, - clutter_clone_accessible, - CLUTTER, - CLONE_ACCESSIBLE, - ClutterActorAccessible) - -G_END_DECLS diff --git a/clutter/clutter/clutter-clone-accessible.c b/clutter/clutter/clutter-clone-accessible.c deleted file mode 100644 index cfc5d0257..000000000 --- a/clutter/clutter/clutter-clone-accessible.c +++ /dev/null @@ -1,100 +0,0 @@ -/* CALLY - The Clutter Accessibility Implementation Library - * - * Copyright (C) 2010 Igalia, S.L. - * - * Author: Alejandro Piñeiro Iglesias - * - * This library is free software; you can redistribute it and/or - * modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation; either - * version 2 of the License, or (at your option) any later version. - * - * This library is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Lesser General Public License for more details. - * - * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, see . - */ - -/** - * ClutterCloneAccessible: - * - * Implementation of the ATK interfaces for a #ClutterClone - * - * #ClutterCloneAccessible implements the required ATK interfaces of [class@Clutter.Clone] - * - * In particular it sets a proper role for the clone, as just a image, - * as it is the sanest and simplest approach. - */ - -/* Design rationale for ClutterCloneAccessible: - * - * In the old times, it was just ClutterCloneTexture. So, from a a11y POV - * ClutterCloneAccessibleTexture was just another image, like ClutterTexture, and if - * it was a clone was irrelevant. So on cally-0.8, ClutterCloneAccessibleTexture - * expose a object with role ATK_ROLE_IMAGE. But now, ClutterClone is more - * general. You can clone any object, including groups, and made things - * like have one text entry, and a clone with different properties in the - * same window, updated both at once. - * - * The question is if the idea is have a ClutterClone as a "first-class" - * citizen inside the stage hierarchy (full clone), or it is just supposed - * to be a mirror image of the original object. - * - * In the case of the a11y POV this would mean that if the text changes on - * the source, the clone should emit as well the text-changing signals. - * - * As ClutterClone smartly just paint the same object with different - * parameters, this would mean that it should be the cally object the one - * that should replicate the source clutter hierarchy to do that, - * something that just sound crazy. - * - * Taking into account that: - * - * - ClutterClone doesn't re-emit mirrored signals from the source - * I think that likely the answer would be "yes, it is just a - * mirrored image, not a real full clone". - * - * - You can't interact directly with the clone (ie: focus, and so on). - * Its basic usage (right now) is clone textures. - * - * Any other solution could be overwhelming. - * - * I think that the final solution would be that ClutterClone from the - * a11y POV should still be managed as a image (with the proper properties, - * position, size, etc.). - */ -#include "config.h" - -#include "clutter/clutter-clone-accessible-private.h" - -struct _ClutterCloneAccessible -{ - ClutterActorAccessible parent; -}; - -G_DEFINE_FINAL_TYPE (ClutterCloneAccessible, clutter_clone_accessible, CLUTTER_TYPE_ACTOR_ACCESSIBLE) - -static void -clutter_clone_accessible_real_initialize (AtkObject *obj, - gpointer data) -{ - ATK_OBJECT_CLASS (clutter_clone_accessible_parent_class)->initialize (obj, data); - - obj->role = ATK_ROLE_IMAGE; -} - -static void -clutter_clone_accessible_class_init (ClutterCloneAccessibleClass *klass) -{ - AtkObjectClass *class = ATK_OBJECT_CLASS (klass); - - class->initialize = clutter_clone_accessible_real_initialize; -} - -static void -clutter_clone_accessible_init (ClutterCloneAccessible *clone) -{ -} diff --git a/clutter/clutter/clutter-clone.c b/clutter/clutter/clutter-clone.c index edb9431f7..6080159bd 100644 --- a/clutter/clutter/clutter-clone.c +++ b/clutter/clutter/clutter-clone.c @@ -37,7 +37,6 @@ #include "config.h" -#include "clutter/clutter-clone-accessible-private.h" #include "clutter/clutter-actor-private.h" #include "clutter/clutter-clone.h" #include "clutter/clutter-debug.h" @@ -343,7 +342,6 @@ clutter_clone_class_init (ClutterCloneClass *klass) ClutterActorClass *actor_class = CLUTTER_ACTOR_CLASS (klass); actor_class->paint = clutter_clone_paint; - actor_class->get_accessible_type = clutter_clone_accessible_get_type; actor_class->get_paint_volume = clutter_clone_get_paint_volume; actor_class->get_preferred_width = clutter_clone_get_preferred_width; actor_class->get_preferred_height = clutter_clone_get_preferred_height; @@ -389,7 +387,10 @@ clutter_clone_init (ClutterClone *self) ClutterActor * clutter_clone_new (ClutterActor *source) { - return g_object_new (CLUTTER_TYPE_CLONE, "source", source, NULL); + return g_object_new (CLUTTER_TYPE_CLONE, + "source", source, + "accessible-role", ATK_ROLE_IMAGE, + NULL); } static void diff --git a/clutter/clutter/meson.build b/clutter/clutter/meson.build index b0ef2a423..c1c948362 100644 --- a/clutter/clutter/meson.build +++ b/clutter/clutter/meson.build @@ -104,7 +104,6 @@ clutter_sources = [ 'clutter-box-layout.c', 'clutter-brightness-contrast-effect.c', 'clutter-click-action.c', - 'clutter-clone-accessible.c', 'clutter-clone.c', 'clutter-color-manager.c', 'clutter-color-state.c', @@ -186,7 +185,6 @@ clutter_private_headers = [ 'clutter-actor-private.h', 'clutter-backend-private.h', 'clutter-blur-private.h', - 'clutter-clone-accessible-private.h', 'clutter-constraint-private.h', 'clutter-content-private.h', 'clutter-context-private.h',