#include <STD_TabDesktop.h>
+#include "STD_LoadStudiesDlg.h"
+
#include <SUIT_Tools.h>
#include <SUIT_Session.h>
#include <qcombobox.h>
#include <qmessagebox.h>
#include <qapplication.h>
+#include <qlistbox.h>
+#include <qregexp.h>
#include "SALOMEDS_StudyManager.hxx"
return res;
}
+void SalomeApp_Application::onLoadDoc()
+{
+ QString name, studyname, ext;
+
+ STD_LoadStudiesDlg aDlg( desktop(), TRUE);
+
+ std::vector<std::string> List = studyMgr()->GetOpenStudies();
+ for (unsigned int ind = 0; ind < List.size(); ind++) {
+ studyname = List[ind];
+ aDlg.ListComponent->insertItem( studyname );
+ }
+
+ int retVal = aDlg.exec();
+ studyname = aDlg.ListComponent->currentText();
+
+ if (retVal == QDialog::Rejected)
+ return;
+
+ if ( studyname.isNull() || studyname.isEmpty() )
+ return;
+
+ name = studyname;
+ name.replace( QRegExp(":"), "/" );
+
+ onLoadDoc(name);
+}
+
+
+
bool SalomeApp_Application::onLoadDoc( const QString& aName )
{
bool res = CAM_Application::onLoadDoc( aName );
virtual void onOpenDoc();
virtual void onHelpAbout();
virtual bool onOpenDoc( const QString& );
+ virtual void onLoadDoc();
virtual bool onLoadDoc( const QString& );
virtual void onCopy();
virtual void onPaste();
-
+
private slots:
void onSelection();
void onRefresh();