videocollection/tsrc/stubs/inc/testobjectstore.h
changeset 38 ff53afa8ad05
child 28 c48470be1ba7
equal deleted inserted replaced
37:4eb2df7f7cbe 38:ff53afa8ad05
       
     1 /*
       
     2 * Copyright (c) 2008-2009 Nokia Corporation and/or its subsidiary(-ies).
       
     3 * All rights reserved.
       
     4 * This component and the accompanying materials are made available
       
     5 * under the terms of "Eclipse Public License v1.0"
       
     6 * which accompanies this distribution, and is available
       
     7 * at the URL "http://www.eclipse.org/legal/epl-v10.html".
       
     8 *
       
     9 * Initial Contributors:
       
    10 * Nokia Corporation - initial contribution.
       
    11 *
       
    12 * Contributors:
       
    13 *
       
    14 * Description:  
       
    15 *
       
    16 */
       
    17 
       
    18 #ifndef TESTOBJECTSTORE.h
       
    19 #define TESTOBJECTSTORE.h
       
    20 
       
    21 #include <qobject.h>
       
    22 #include <qpointer.h>
       
    23 #include <qlist.h>
       
    24 
       
    25 class TestObjectStore : public QObject
       
    26 {
       
    27     Q_OBJECT
       
    28 
       
    29 public:
       
    30     
       
    31     static TestObjectStore &instance();
       
    32     
       
    33     void addObject(QObject *object);
       
    34     
       
    35 private slots:
       
    36 
       
    37     void objectDestroyed(QObject *obj);
       
    38     
       
    39 private:
       
    40     
       
    41     TestObjectStore();
       
    42 
       
    43     ~TestObjectStore();
       
    44     
       
    45     QList<QObject *> mObjects;
       
    46     
       
    47 };
       
    48 
       
    49 #endif