aboutsummaryrefslogtreecommitdiff
path: root/src/FbTk/XLayerItem.cc
diff options
context:
space:
mode:
Diffstat (limited to 'src/FbTk/XLayerItem.cc')
-rw-r--r--src/FbTk/XLayerItem.cc9
1 files changed, 5 insertions, 4 deletions
diff --git a/src/FbTk/XLayerItem.cc b/src/FbTk/XLayerItem.cc
index 31940a1..872216b 100644
--- a/src/FbTk/XLayerItem.cc
+++ b/src/FbTk/XLayerItem.cc
@@ -20,7 +20,7 @@
20// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER 20// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
21// DEALINGS IN THE SOFTWARE. 21// DEALINGS IN THE SOFTWARE.
22 22
23// $Id: XLayerItem.cc,v 1.2 2003/01/29 21:42:53 rathnor Exp $ 23// $Id: XLayerItem.cc,v 1.3 2003/02/02 16:32:41 rathnor Exp $
24 24
25#include "XLayerItem.hh" 25#include "XLayerItem.hh"
26#include "XLayer.hh" 26#include "XLayer.hh"
@@ -39,12 +39,13 @@ XLayerItem::XLayerItem(XLayer &layer):
39 }*/ 39 }*/
40 40
41XLayerItem::~XLayerItem() { 41XLayerItem::~XLayerItem() {
42 m_layer->remove(*this); 42 if (m_layer)
43 m_layer->remove(*this);
43} 44}
44 45
45void XLayerItem::setLayer(XLayer &layer) { 46void XLayerItem::setLayer(XLayer *layer) {
46 // make sure we don't try to set the same layer 47 // make sure we don't try to set the same layer
47 m_layer = &layer; 48 m_layer = layer;
48} 49}
49 50
50void XLayerItem::raise() { 51void XLayerItem::raise() {