File indexing completed on 2024-04-28 08:54:36
0001 /* 0002 * This file is part of TelepathyLoggerQt4 0003 * 0004 * Copyright (C) 2014 Daniel Vrátil <dvratil@redhat.com> 0005 * 0006 * This library is free software; you can redistribute it and/or modify 0007 * it under the terms of the GNU Lesser General Public License as published 0008 * by the Free Software Foundation; either version 2.1 of the License, or 0009 * (at your option) any later version. 0010 * 0011 * This program is distributed in the hope that it will be useful, 0012 * but WITHOUT ANY WARRANTY; without even the implied warranty of 0013 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 0014 * GNU General Public License for more details. 0015 * 0016 * You should have received a copy of the GNU Lesser General Public License 0017 * along with this program. If not, see <http://www.gnu.org/licenses/>. 0018 */ 0019 0020 #include "object.h" 0021 0022 #include <glib-object.h> 0023 0024 namespace Tpl 0025 { 0026 0027 Object::Object(void *tplPtr, bool ref): 0028 m_tplPtr(tplPtr) 0029 { 0030 if (ref) { 0031 g_object_ref(G_OBJECT(m_tplPtr)); 0032 } 0033 } 0034 0035 Object::~Object() 0036 { 0037 g_object_unref(G_OBJECT(m_tplPtr)); 0038 } 0039 0040 }