camerauis/cameraxui/cxengine/inc/cxediskmonitorprivate.h
changeset 28 3075d9b614e6
child 29 699651f2666f
equal deleted inserted replaced
19:d9aefe59d544 28:3075d9b614e6
       
     1 /*
       
     2 * Copyright (c) 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 CXEDISKMONITORPRIVATE_H
       
    19 #define CXEDISKMONITORPRIVATE_H
       
    20 
       
    21 #include <QObject>
       
    22 #include <QTimer>
       
    23 #ifdef Q_OS_SYMBIAN
       
    24 #include <f32file.h>
       
    25 #endif // Q_OS_SYMBIAN
       
    26 
       
    27 class CxeSettings;
       
    28 
       
    29 class CxeDiskMonitorPrivate : public QObject
       
    30 {
       
    31     Q_OBJECT
       
    32 
       
    33     // Owner of this private implementation.
       
    34     friend class CxeDiskMonitor;
       
    35 
       
    36 private:
       
    37     explicit CxeDiskMonitorPrivate(CxeSettings &settings);
       
    38     ~CxeDiskMonitorPrivate();
       
    39 
       
    40 signals:
       
    41     void diskSpaceLow();
       
    42     void diskSpaceChanged();
       
    43 
       
    44 private slots:
       
    45     void checkSpace();
       
    46 
       
    47 private:
       
    48     void setLowWarningLevel(qint64 bytes);
       
    49     void start();
       
    50     void stop();
       
    51     bool isMonitoring() const;
       
    52     qint64 free(bool cached = true) const;
       
    53 
       
    54 private:
       
    55     CxeSettings &mSettings;
       
    56     QTimer mTimer;
       
    57 #ifdef Q_OS_SYMBIAN
       
    58     RFs& mFs;
       
    59     int mCameraDrive;
       
    60 #endif // Q_OS_SYMBIAN
       
    61     qint64 mTriggerLevelBytes;
       
    62     qint64 mLatestFreeBytes;
       
    63 };
       
    64 
       
    65 
       
    66 #endif // CXEDISKMONITORPRIVATE_H