VR-Forces 4.0.4 Class Documentation
include/vrvCoreQt/DtPersistenceToolbarWidget.h
Go to the documentation of this file.
00001 /******************************************************************************
00002 ** Copyright (c) 2008 MAK Technologies, Inc.
00003 ** All rights reserved.
00004 ******************************************************************************/
00005 /******************************************************************************
00006 ** $RCSfile: DtPersistenceToolbarWidget.h,v $ $Revision: 1.12 $ $State: Exp $
00007 ******************************************************************************/
00008 
00011 
00012 #pragma once
00013 #include <vrvCoreQt/vrvCoreQt.h>
00014 #include <vrvCoreQt/DtPersistenceControlsInterface.h>
00015 #include <QtGui/QWidget>
00016 
00017 class QPushButton;
00018 class QLabel;
00019 class QFrame;
00020 class QHBoxLayout;
00021 
00022 namespace makVrv
00023 {
00024 
00025    class DtBackupInterface;
00026 
00030    class DT_DLL_VRVCOREQT DtPersistenceToolbarWidget : public QWidget,
00031       public DtPersistenceControlsInterface
00032    {
00033       Q_OBJECT;
00034 
00035    public:
00037       DtPersistenceToolbarWidget(DtDe& de, QWidget* p=0, Qt::WindowFlags f=0);
00038 
00040       virtual ~DtPersistenceToolbarWidget();
00041 
00043       virtual void setPersistentStateName(const QString& name);
00044 
00047       virtual void queryImportFilePath(DtDe& de, const std::string& importType,
00048          const std::string& path, const std::string& fileFilter);
00049 
00052       virtual void queryMergeFilePath(DtDe& de, const std::string& importType,
00053          const std::string& path, const std::string& fileFilter);
00054 
00057       virtual void queryExportFilePath(DtDe& de, const std::string& importType,
00058          const std::string& path, const std::string& fileFilter);
00059 
00061       virtual void setSaveButtonShown(bool shown);
00062 
00064       virtual void setSeparatorShown(bool shown);
00065 
00069       virtual void setMergeShown(bool shown);
00070 
00073       virtual void setExportShown(bool);
00074 
00077       virtual void setImportShown(bool);
00078 
00080       virtual void setExportEnabled(bool);
00081 
00085       virtual void setMergeEnabled(bool);
00086 
00089       virtual void setImportEnabled(bool);
00090 
00093       virtual void setExportSelectedEnabled(bool);
00094 
00097       virtual void setBackupRestoreEnabled(bool shown);
00098 
00101       virtual void setFactoryRestoreEnabled(bool shown);
00102 
00108       virtual void setBackup(DtBackupInterface*);
00109 
00111       virtual void disableAllButtons(bool);
00112 
00113    protected slots:
00114 
00115       virtual void on_myImportButton_clicked();
00116       virtual void on_myExportButton_clicked();
00117       virtual void on_myMergeButton_clicked();
00118       virtual void on_myExportSelectedButton_clicked();
00119       virtual void on_mySaveButton_clicked();
00120       virtual void on_myRestoreButton_clicked();
00121       virtual void on_myRestoreFactoryButton_clicked();
00122 
00123    protected:
00127       virtual void backupFileChanged(const DtBackupInterface*);
00128 
00129    protected:
00130 
00131       void setupGui();
00132 
00135       virtual QString willAlsoRestore(int) const;
00136 
00137    protected:
00138       DtDe& myDe;
00139       DtBackupInterface* myBackup;
00140       QLabel* myLabel;
00141       QPushButton* myImportButton;
00142       QPushButton* myExportButton;
00143       QPushButton* myMergeButton;
00144       QPushButton* myExportSelectedButton;
00145       QPushButton* mySaveButton;
00146       QPushButton* myRestoreButton;
00147       QPushButton* myRestoreFactoryButton;
00148       QFrame* mySeparator;
00149       QHBoxLayout* myButtonLayout;
00150    };
00151 }

Document ID: Generated on Fri Jun 29 16:33:32 EDT 2012 from SVN revision 116588
Copyright © 2005-2012 VT MÄK Inc. All Rights Reserved (www.mak.com)