1 /* === S Y N F I G ========================================================= */
2 /*! \file docks/dockmanager.h
3 ** \brief Template Header
8 ** Copyright (c) 2002-2005 Robert B. Quattlebaum Jr., Adrian Bentley
10 ** This package is free software; you can redistribute it and/or
11 ** modify it under the terms of the GNU General Public License as
12 ** published by the Free Software Foundation; either version 2 of
13 ** the License, or (at your option) any later version.
15 ** This package is distributed in the hope that it will be useful,
16 ** but WITHOUT ANY WARRANTY; without even the implied warranty of
17 ** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
18 ** General Public License for more details.
21 /* ========================================================================= */
23 /* === S T A R T =========================================================== */
25 #ifndef __SYNFIG_DOCKMANAGER_H
26 #define __SYNFIG_DOCKMANAGER_H
28 /* === H E A D E R S ======================================================= */
32 #include <synfig/string.h>
33 #include <sigc++/signal.h>
34 #include <sigc++/object.h>
35 #include <ETL/smart_ptr>
37 /* === M A C R O S ========================================================= */
39 /* === T Y P E D E F S ===================================================== */
41 /* === C L A S S E S & S T R U C T S ======================================= */
49 class DockManager : public sigc::trackable
51 friend class Dockable;
52 friend class DockDialog;
53 friend class DockSettings;
55 std::list<Dockable*> dockable_list_;
56 std::list<DockDialog*> dock_dialog_list_;
58 sigc::signal<void,Dockable*> signal_dockable_registered_;
60 etl::smart_ptr<DockSettings> dock_settings;
66 DockDialog& find_dock_dialog(int id);
67 const DockDialog& find_dock_dialog(int id)const;
69 sigc::signal<void,Dockable*>& signal_dockable_registered() { return signal_dockable_registered_; }
71 void register_dockable(Dockable& x);
72 bool unregister_dockable(Dockable& x);
73 Dockable& find_dockable(const synfig::String& x);
74 void present(synfig::String x);
75 void show_all_dock_dialogs();
77 }; // END of class DockManager
79 }; // END of namespace studio
81 /* === E N D =============================================================== */