X-Git-Url: https://git.pterodactylus.net/?a=blobdiff_plain;f=synfig-studio%2Ftags%2Fstable%2Fsrc%2Fsynfigapp%2Fselectionmanager.h;fp=synfig-studio%2Ftags%2Fstable%2Fsrc%2Fsynfigapp%2Fselectionmanager.h;h=0000000000000000000000000000000000000000;hb=91c14fb028f8cbf78be64623aded885725606f78;hp=f77fc6197050fcbfa6aa89243a67e7180a5476c1;hpb=f6184c2a9c2245aae802c31c8f3300e1b744359c;p=synfig.git diff --git a/synfig-studio/tags/stable/src/synfigapp/selectionmanager.h b/synfig-studio/tags/stable/src/synfigapp/selectionmanager.h deleted file mode 100644 index f77fc61..0000000 --- a/synfig-studio/tags/stable/src/synfigapp/selectionmanager.h +++ /dev/null @@ -1,147 +0,0 @@ -/* === S Y N F I G ========================================================= */ -/*! \file selectionmanager.h -** \brief Template Header -** -** $Id$ -** -** \legal -** Copyright (c) 2002-2005 Robert B. Quattlebaum Jr., Adrian Bentley -** -** This package is free software; you can redistribute it and/or -** modify it under the terms of the GNU General Public License as -** published by the Free Software Foundation; either version 2 of -** the License, or (at your option) any later version. -** -** This package 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 -** General Public License for more details. -** \endlegal -*/ -/* ========================================================================= */ - -/* === S T A R T =========================================================== */ - -#ifndef __SYNFIG_APP_SELECTIONMANAGER_H -#define __SYNFIG_APP_SELECTIONMANAGER_H - -/* === H E A D E R S ======================================================= */ - -#include -#include -#include -#include -#include -#include "value_desc.h" - -/* === M A C R O S ========================================================= */ - -/* === T Y P E D E F S ===================================================== */ - -/* === C L A S S E S & S T R U C T S ======================================= */ - -namespace synfigapp { - -class SelectionManager : public etl::shared_object -{ -public: - typedef std::pair LayerParam; - typedef std::list LayerParamList; - - typedef std::list LayerList; - typedef std::list ChildrenList; - //typedef std::list ValueNodeList; - - virtual ~SelectionManager() { } - - //! Returns the number of layers selected. - virtual int get_selected_layer_count()const=0; - - //! Returns a list of the currently selected layers. - virtual LayerList get_selected_layers()const=0; - - //! Returns the first layer selected or an empty handle if none are selected. - virtual synfig::Layer::Handle get_selected_layer()const=0; - - //! Sets which layers should be selected - virtual void set_selected_layers(const LayerList &layer_list)=0; - - //! Sets which layer should be selected. Empty handle if none. - virtual void set_selected_layer(const synfig::Layer::Handle &layer)=0; - - //! Clears the layer selection list - virtual void clear_selected_layers()=0; - - - - //! Returns the number of childrens selected. - virtual int get_selected_children_count()const=0; - - //! Returns a list of the currently selected childrens. - virtual ChildrenList get_selected_children()const=0; - - //! Returns the first children selected or an empty handle if none are selected. - virtual ChildrenList::value_type get_selected_child()const=0; - - //! Sets which childrens should be selected - virtual void set_selected_children(const ChildrenList &children_list)=0; - - //! Sets which children should be selected. Empty handle if none. - virtual void set_selected_child(const ChildrenList::value_type &children)=0; - - //! Clears the children selection list - virtual void clear_selected_children()=0; - - - //! Returns the number of layer parameters selected. - virtual int get_selected_layer_parameter_count()const=0; - - //! Returns a list of the currently selected layer parameters. - virtual LayerParamList get_selected_layer_parameters()const=0; - - //! Returns the first layer parameter selected or an empty handle if none are selected. - virtual LayerParam get_selected_layer_parameter()const=0; - - //! Sets which layer parameters should be selected - virtual void set_selected_layer_parameters(const LayerParamList &layer_param_list)=0; - - //! Sets which layer parameter should be selected. Empty handle if none. - virtual void set_selected_layer_param(const LayerParam &layer_param)=0; - - //! Clears the layer parameter selection list - virtual void clear_selected_layer_parameters()=0; -}; // END of class SelectionManager - -//! A place holding selection manager that does nothing -class NullSelectionManager : public SelectionManager -{ -public: - int get_selected_layer_count()const { return 0; } - LayerList get_selected_layers()const { return LayerList(); } - synfig::Layer::Handle get_selected_layer()const { return 0; } - void set_selected_layers(const LayerList &layer_list) { return; } - void set_selected_layer(const synfig::Layer::Handle &layer) { return; } - void clear_selected_layers() { return; } - - - int get_selected_children_count()const { return 0; } - ChildrenList get_selected_children()const { return ChildrenList(); } - ChildrenList::value_type get_selected_child()const { return ChildrenList::value_type(); } - void set_selected_children(const ChildrenList &children_list) { return; } - void set_selected_child(const ChildrenList::value_type &child) { return; } - void clear_selected_children() { return; } - - int get_selected_layer_parameter_count()const { return 0; } - LayerParamList get_selected_layer_parameters()const { return LayerParamList(); } - LayerParam get_selected_layer_parameter()const { return LayerParam(); } - void set_selected_layer_parameters(const LayerParamList &layer_param_list) { return; } - void set_selected_layer_param(const LayerParam &layer_param) { return; } - void clear_selected_layer_parameters() { return; } - -}; // END of class NullSelectionManager - -}; // END of namespace synfigapp - -/* === E N D =============================================================== */ - -#endif