/***************************************************************************
                          AudioEstimatePnl.h -  description
                             -------------------
    begin                : Fri Jun 1 2001
    copyright            : (C) 2001 by Alexy Podolsky
    email                : alexpod@users.sourceforge.net
 ***************************************************************************/

/***************************************************************************
 *                                                                         *
 *   This program 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 2 of the License, or     *
 *   (at your option) any later version.                                   *
 *                                                                         *
 ***************************************************************************/
#ifndef AUDIOESTIMATEPNL_H
#define AUDIOESTIMATEPNL_H

#include <qvariant.h>
#include <qwidget.h>
class QVBoxLayout; 
class QHBoxLayout; 
class QGridLayout; 
class QComboBox;
class QFrame;
class QGroupBox;
class QLCDNumber;
class QLabel;
class QPushButton;

class AudioEstimatePnl : public QWidget
{ 
    Q_OBJECT

public:
    AudioEstimatePnl( QWidget* parent = 0, const char* name = 0, WFlags fl = 0 );
    ~AudioEstimatePnl();
	void saveOptions();

	bool add(int length, int type = readyTrack);
	void subtract(int length, int type = readyTrack);
	void reset();
	
	inline QPushButton* getRecalculateBtn() { return recalcEstBtn; }

	static const int readyTrack = 0;
	static const int mp3Track = 1;
	static const int oggTrack = 2;
	
protected slots:
    void capacityChangedSlot(int);
    void synchUp();

protected:
	void readOptions();

    QVBoxLayout* AudioEstimatePnlLayout;
    QGridLayout* estFrmLayout;
    QHBoxLayout* GroupBox5Layout;
    QGridLayout* GroupBox2_2_2Layout;
	QGroupBox* estFrm;
    QPushButton* recalcEstBtn;
    QGroupBox* GroupBox5;
    QComboBox* capacityCmb;
    QLabel* capacityLbl;
    QGroupBox* GroupBox2_2_2;
    QLabel* TextLabel1_2;
    QLCDNumber* numMp3LCD;
    QLCDNumber* usedLCD;
    QLabel* TextLabel1;
    QLabel* TextLabel2;
    QLCDNumber* numOfSongsLCD;
    QLCDNumber* numOggLCD;
    QLCDNumber* wastedLCD;
    QLabel* TextLabel2_2;
    QFrame* Line2;
    QLabel* TextLabel1_2_2;

	int max;
	int usedSec;
	int wastedSec;
};

#endif // AUDIOESTIMATEPNL_H
