command-line access
parent
b5307c3163
commit
a0e3a219d0
|
@ -85,6 +85,12 @@ MainWindow::MainWindow(QWidget *parent) :
|
||||||
ui->actionUpdateCheck->setMenuRole(QAction::ApplicationSpecificRole);
|
ui->actionUpdateCheck->setMenuRole(QAction::ApplicationSpecificRole);
|
||||||
ui->actionFeedback->setMenuRole(QAction::ApplicationSpecificRole);
|
ui->actionFeedback->setMenuRole(QAction::ApplicationSpecificRole);
|
||||||
ui->actionReportBug->setMenuRole(QAction::ApplicationSpecificRole);
|
ui->actionReportBug->setMenuRole(QAction::ApplicationSpecificRole);
|
||||||
|
ui->actionEnableCommandLine->setMenuRole(QAction::ApplicationSpecificRole);
|
||||||
|
|
||||||
|
#if !defined(__OSX__)
|
||||||
|
ui->actionEnableCommandLine->setVisible(false);
|
||||||
|
#endif
|
||||||
|
|
||||||
m_progressWidget = new QWidget(centralWidget());
|
m_progressWidget = new QWidget(centralWidget());
|
||||||
m_progressLabel = new QLabel(m_progressWidget);
|
m_progressLabel = new QLabel(m_progressWidget);
|
||||||
m_progress = new QProgressBar(m_progressWidget);
|
m_progress = new QProgressBar(m_progressWidget);
|
||||||
|
@ -194,7 +200,7 @@ MainWindow::MainWindow(QWidget *parent) :
|
||||||
|
|
||||||
m_networkManager = new QNetworkAccessManager(this);
|
m_networkManager = new QNetworkAccessManager(this);
|
||||||
|
|
||||||
#if defined(__OSX__)
|
#if defined(__OSX__) && 0 // Disable crash reports for now
|
||||||
/* Submit crash reports on OSX */
|
/* Submit crash reports on OSX */
|
||||||
QDir crashDir = QDir::home();
|
QDir crashDir = QDir::home();
|
||||||
crashDir.cd("Library/Logs/CrashReporter");
|
crashDir.cd("Library/Logs/CrashReporter");
|
||||||
|
@ -1517,6 +1523,16 @@ void MainWindow::on_actionStartServer_triggered() {
|
||||||
connect(m_serverWidget, SIGNAL(closed()), this, SLOT(onServerClosed()));
|
connect(m_serverWidget, SIGNAL(closed()), this, SLOT(onServerClosed()));
|
||||||
m_serverWidget->show();
|
m_serverWidget->show();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void MainWindow::on_actionEnableCommandLine_triggered() {
|
||||||
|
if (QMessageBox::question(this, tr("Enable command line access"),
|
||||||
|
tr("<p>If you proceed, Mitsuba will create symbolic links in <tt>/usr/bin</tt> and <tt>/Library/Python/2.6/site-packages</tt> "
|
||||||
|
"that make it possible to use the renderer via the command line and Python. Any old symlinks will simply be overwritten.</p>"),
|
||||||
|
QMessageBox::Yes | QMessageBox::No) == QMessageBox::Yes) {
|
||||||
|
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
void MainWindow::on_actionReportBug_triggered() {
|
void MainWindow::on_actionReportBug_triggered() {
|
||||||
QDesktopServices::openUrl(QUrl("https://www.mitsuba-renderer.org/bugtracker/projects/mitsuba"));
|
QDesktopServices::openUrl(QUrl("https://www.mitsuba-renderer.org/bugtracker/projects/mitsuba"));
|
||||||
|
|
|
@ -127,6 +127,7 @@ private slots:
|
||||||
void on_actionFeedback_triggered();
|
void on_actionFeedback_triggered();
|
||||||
void on_actionShowKDTree_triggered();
|
void on_actionShowKDTree_triggered();
|
||||||
void on_actionSceneDescription_triggered();
|
void on_actionSceneDescription_triggered();
|
||||||
|
void on_actionEnableCommandLine_triggered();
|
||||||
void on_tabBar_currentChanged(int index);
|
void on_tabBar_currentChanged(int index);
|
||||||
bool on_tabBar_tabCloseRequested(int index);
|
bool on_tabBar_tabCloseRequested(int index);
|
||||||
void on_tabBar_tabMoved(int from, int to);
|
void on_tabBar_tabMoved(int from, int to);
|
||||||
|
|
|
@ -100,7 +100,7 @@
|
||||||
<x>0</x>
|
<x>0</x>
|
||||||
<y>0</y>
|
<y>0</y>
|
||||||
<width>605</width>
|
<width>605</width>
|
||||||
<height>25</height>
|
<height>27</height>
|
||||||
</rect>
|
</rect>
|
||||||
</property>
|
</property>
|
||||||
<widget class="QMenu" name="menuFile">
|
<widget class="QMenu" name="menuFile">
|
||||||
|
@ -157,6 +157,7 @@
|
||||||
<addaction name="separator"/>
|
<addaction name="separator"/>
|
||||||
<addaction name="menuDeveloper"/>
|
<addaction name="menuDeveloper"/>
|
||||||
<addaction name="actionSettings"/>
|
<addaction name="actionSettings"/>
|
||||||
|
<addaction name="actionEnableCommandLine"/>
|
||||||
</widget>
|
</widget>
|
||||||
<addaction name="menuFile"/>
|
<addaction name="menuFile"/>
|
||||||
<addaction name="menuTools"/>
|
<addaction name="menuTools"/>
|
||||||
|
@ -463,6 +464,11 @@
|
||||||
<string>Scene Information ..</string>
|
<string>Scene Information ..</string>
|
||||||
</property>
|
</property>
|
||||||
</action>
|
</action>
|
||||||
|
<action name="actionEnableCommandLine">
|
||||||
|
<property name="text">
|
||||||
|
<string>Enable command line access</string>
|
||||||
|
</property>
|
||||||
|
</action>
|
||||||
</widget>
|
</widget>
|
||||||
<layoutdefault spacing="6" margin="11"/>
|
<layoutdefault spacing="6" margin="11"/>
|
||||||
<customwidgets>
|
<customwidgets>
|
||||||
|
|
Loading…
Reference in New Issue