Script launcher: add env profile configure dialog button to config UI

Provides quick access to edit environments profiles or create new ones,
as desired for the current script launcher.
The same is already present in the config UI for the binary app launcher.

BUG: 410914
FIXED-IN: 5.5.0
parent 4b9828a1
...@@ -18,6 +18,8 @@ target_link_libraries(kdevexecutescript ...@@ -18,6 +18,8 @@ target_link_libraries(kdevexecutescript
KDev::Interfaces KDev::Interfaces
KDev::Util KDev::Util
KDev::Project KDev::Project
KDev::OutputView) KDev::OutputView
KDev::Shell
)
install(FILES iexecutescriptplugin.h DESTINATION ${KDE_INSTALL_INCLUDEDIR}/kdevplatform/executescript COMPONENT Devel) install(FILES iexecutescriptplugin.h DESTINATION ${KDE_INSTALL_INCLUDEDIR}/kdevplatform/executescript COMPONENT Devel)
...@@ -98,6 +98,8 @@ ScriptAppConfigPage::ScriptAppConfigPage( QWidget* parent ) ...@@ -98,6 +98,8 @@ ScriptAppConfigPage::ScriptAppConfigPage( QWidget* parent )
//Set workingdirectory widget to ask for directories rather than files //Set workingdirectory widget to ask for directories rather than files
workingDirectory->setMode(KFile::Directory | KFile::ExistingOnly | KFile::LocalOnly); workingDirectory->setMode(KFile::Directory | KFile::ExistingOnly | KFile::LocalOnly);
configureEnvironment->setSelectionWidget(environment);
//connect signals to changed signal //connect signals to changed signal
connect( interpreter->lineEdit(), &QLineEdit::textEdited, this, &ScriptAppConfigPage::changed ); connect( interpreter->lineEdit(), &QLineEdit::textEdited, this, &ScriptAppConfigPage::changed );
connect( executablePath->lineEdit(), &KLineEdit::textEdited, this, &ScriptAppConfigPage::changed ); connect( executablePath->lineEdit(), &KLineEdit::textEdited, this, &ScriptAppConfigPage::changed );
......
...@@ -193,11 +193,24 @@ ...@@ -193,11 +193,24 @@
</widget> </widget>
</item> </item>
<item row="2" column="1"> <item row="2" column="1">
<widget class="KDevelop::EnvironmentSelectionWidget" name="environment"> <layout class="QHBoxLayout" name="horizontalLayout">
<property name="toolTip"> <item>
<string>Select an environment to be used</string> <widget class="KDevelop::EnvironmentSelectionWidget" name="environment">
</property> <property name="sizePolicy">
</widget> <sizepolicy hsizetype="MinimumExpanding" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="toolTip">
<string>Select an environment to be used</string>
</property>
</widget>
</item>
<item>
<widget class="KDevelop::EnvironmentConfigureButton" name="configureEnvironment"/>
</item>
</layout>
</item> </item>
<item row="3" column="0"> <item row="3" column="0">
<widget class="QLabel" name="label_6"> <widget class="QLabel" name="label_6">
...@@ -317,6 +330,11 @@ ...@@ -317,6 +330,11 @@
<extends>KComboBox</extends> <extends>KComboBox</extends>
<header>util/environmentselectionwidget.h</header> <header>util/environmentselectionwidget.h</header>
</customwidget> </customwidget>
<customwidget>
<class>KDevelop::EnvironmentConfigureButton</class>
<extends>QToolButton</extends>
<header>shell/environmentconfigurebutton.h</header>
</customwidget>
</customwidgets> </customwidgets>
<tabstops> <tabstops>
<tabstop>arguments</tabstop> <tabstop>arguments</tabstop>
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment