mirror of
https://git.dev.opencascade.org/repos/occt.git
synced 2025-08-04 13:13:25 +03:00
0024479: Ray Tracing mode does not work in Qt IE sample
Implementation of Ray Tracing mode in standard Qt sample Fix compile warnings in Qt samples. Fix tabs in Common-string.ts. Update Code style. 0024415: Update QT samples Code which was based on QT3 was removed. Some bugs and warnings has been also fixed. Porting from QT4 to QT5 sample files.
This commit is contained in:
@@ -3,6 +3,7 @@
|
||||
|
||||
#include <QFileDialog>
|
||||
#include <QStatusBar>
|
||||
#include <QMdiSubWindow>
|
||||
|
||||
ApplicationTut::ApplicationTut()
|
||||
: ApplicationCommonWindow( )
|
||||
@@ -33,7 +34,7 @@ void ApplicationTut::createMakeBottleOperation(){
|
||||
|
||||
void ApplicationTut::updateFileActions()
|
||||
{
|
||||
if ( getWorkspace()->windowList().isEmpty() )
|
||||
if ( getWorkspace()->subWindowList().isEmpty() )
|
||||
{
|
||||
if ( !isDocument() )
|
||||
{
|
||||
@@ -49,8 +50,8 @@ void ApplicationTut::updateFileActions()
|
||||
|
||||
void ApplicationTut::onMakeBottleAction()
|
||||
{
|
||||
QWorkspace* ws = ApplicationCommonWindow::getWorkspace();
|
||||
DocumentTut* doc = (DocumentTut*)((MDIWindow*)ws->activeWindow())->getDocument();
|
||||
QMdiArea* ws = ApplicationCommonWindow::getWorkspace();
|
||||
DocumentTut* doc = (DocumentTut*)( qobject_cast<MDIWindow*>( ws->activeSubWindow()->widget() )->getDocument() );
|
||||
statusBar()->showMessage( QObject::tr("INF_MAKE_BOTTLE"), 5000 );
|
||||
doc->onMakeBottle();
|
||||
statusBar()->showMessage(QObject::tr("INF_DONE"));
|
||||
@@ -58,7 +59,7 @@ void ApplicationTut::onMakeBottleAction()
|
||||
|
||||
QString ApplicationTut::getTutResourceDir()
|
||||
{
|
||||
static QString resDir( ::getenv( "CSF_TutorialResourcesDefaults" ) );
|
||||
return resDir;
|
||||
static QString resDir (qgetenv ("CSF_TutorialResourcesDefaults").constData());
|
||||
return resDir;
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user