2
* Inkscape::LayerManager - a view of a document's layers, relative
3
* to a particular desktop
5
* Copyright 2006 MenTaLguY <mental@rydia.net>
7
* Released under GNU GPL, read the file 'COPYING' for more information
10
#ifndef SEEN_INKSCAPE_LAYER_MANAGER_H
11
#define SEEN_INKSCAPE_LAYER_MANAGER_H
13
#include "document-subset.h"
14
#include "gc-finalized.h"
15
#include "gc-soft-ptr.h"
23
class LayerManager : public DocumentSubset,
27
LayerManager(SPDesktop *desktop);
29
void setCurrentLayer( SPObject* obj );
30
void renameLayer( SPObject* obj, gchar const *label );
32
sigc::connection connectCurrentLayerChanged(const sigc::slot<void, SPObject *> & slot) {
33
return _layer_changed_signal.connect(slot);
36
sigc::connection connectLayerDetailsChanged(const sigc::slot<void, SPObject *> & slot) {
37
return _details_changed_signal.connect(slot);
41
friend class LayerWatcher;
44
static void _objectModifiedCB( SPObject* obj, guint flags, LayerManager* mgr );
46
void _objectModified( SPObject* obj, guint flags );
47
void _setDocument(SPDocument *document);
49
void _selectedLayerChanged(SPObject *layer);
51
sigc::connection _layer_connection;
52
sigc::connection _document_connection;
53
sigc::connection _resource_connection;
55
GC::soft_ptr<SPDesktop> _desktop;
56
SPDocument *_document;
58
std::vector<LayerWatcher*> _watchers;
60
sigc::signal<void, SPObject *> _layer_changed_signal;
61
sigc::signal<void, SPObject *> _details_changed_signal;
70
c-file-style:"stroustrup"
71
c-file-offsets:((innamespace . 0)(inline-open . 0)(case-label . +))
76
// vim: filetype=cpp:expandtab:shiftwidth=4:tabstop=8:softtabstop=4:encoding=utf-8:textwidth=99 :