/* Copyright © 2010 yan Verdavaine This file is part of QExtend. QExtend 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 3 of the License, or any later version. QExtend 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. You should have received a copy of the GNU General Public License along with QExtend. If not, see . */ #ifndef QEXTEND_OBJECTEXTENDPTRPOLICY_H #define QEXTEND_OBJECTEXTENDPTRPOLICY_H namespace QExtend { struct SCOPE { template bool operator()(const T & /*obj*/) { return true; } }; struct WEAK { template bool operator()(const T & /*obj*/) { return false; } }; struct NOPARENT { bool operator()(QObject * obj) { return obj && obj->parent() == 0; } }; } #endif