Provide option to enable application autocompletion in the run dialog

This fixes regression bug 557


git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdebase@1260897 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
v3.5.13-sru
tpearson 13 years ago
parent 4f0472c4a1
commit 9e1f287e32

@ -379,7 +379,7 @@
<!-- m_dlg->cbAutocomplete->setChecked( KDesktopSettings::miniCLIFilesystemAutoComplete() ); -->
</entry>
<entry key="MiniCLISystempathAutoComplete" type="Bool">
<default>true</default>
<default>false</default>
<label></label>
<whatsthis></whatsthis>
<!-- minicli.cpp:216 -->

@ -127,7 +127,7 @@ Minicli::Minicli( TQWidget *parent, const char *name)
// Autocomplete system
m_filesystemAutocomplete = 0;
m_histfilesystemAutocomplete = 0;
m_systempathAutocomplete = 1;
m_systempathAutocomplete = 0;
m_pURLCompletion = new KURLCompletion(KURLCompletion::FileCompletion);
m_pEXECompletion = new KURLCompletion(KURLCompletion::SystemExeCompletion);
//m_pURLCompletion->setCompletionMode( KGlobalSettings::completionMode() );
@ -153,6 +153,7 @@ Minicli::Minicli( TQWidget *parent, const char *name)
connect(m_dlg->cbPriority, TQT_SIGNAL(toggled(bool)), TQT_SLOT(slotChangeScheduler(bool)));
connect(m_dlg->slPriority, TQT_SIGNAL(valueChanged(int)), TQT_SLOT(slotPriority(int)));
connect(m_dlg->cbRealtime, TQT_SIGNAL(toggled(bool)), TQT_SLOT(slotRealtime(bool)));
connect(m_dlg->cbAppcomplete, TQT_SIGNAL(toggled(bool)), TQT_SLOT(slotAppcompleteToggled(bool)));
connect(m_dlg->cbAutocomplete, TQT_SIGNAL(toggled(bool)), TQT_SLOT(slotAutocompleteToggled(bool)));
connect(m_dlg->cbAutohistory, TQT_SIGNAL(toggled(bool)), TQT_SLOT(slotAutohistoryToggled(bool)));
connect(m_dlg->cbRunAsOther, TQT_SIGNAL(toggled(bool)), TQT_SLOT(slotChangeUid(bool)));
@ -219,6 +220,7 @@ void Minicli::loadConfig()
m_dlg->cbCommand->blockSignals( block );
m_dlg->cbAutocomplete->setChecked( KDesktopSettings::miniCLIFilesystemAutoComplete() );
m_dlg->cbAppcomplete->setChecked( KDesktopSettings::miniCLISystempathAutoComplete() );
m_dlg->cbAutohistory->setChecked( KDesktopSettings::miniCLIHistoryAndFilesystemAutoComplete() );
m_filesystemAutocomplete = KDesktopSettings::miniCLIFilesystemAutoComplete();
@ -1013,6 +1015,14 @@ void Minicli::slotAutocompleteToggled(bool enabled)
m_dlg->cbCommand->setCurrentText( current_text ); // Force an update of the autocompletion list
}
void Minicli::slotAppcompleteToggled(bool enabled)
{
m_systempathAutocomplete = enabled;
TQString current_text = m_dlg->cbCommand->currentText();
m_dlg->cbCommand->setCurrentText( current_text ); // Force an update of the autocompletion list
}
void Minicli::slotAutohistoryToggled(bool enabled)
{
if (enabled)

@ -78,6 +78,7 @@ private slots:
void slotParseTimer();
void slotPriority(int);
void slotRealtime(bool);
void slotAppcompleteToggled(bool);
void slotAutocompleteToggled(bool);
void slotAutohistoryToggled(bool);
void slotTerminal(bool);

@ -181,6 +181,18 @@
</property>
</widget>
<widget class="TQCheckBox" row="8" column="0" rowspan="1" colspan="4">
<property name="name">
<cstring>cbAppcomplete</cstring>
</property>
<property name="text">
<string>Autocomplete shows available &amp;applications</string>
</property>
<property name="whatsThis" stdset="0">
<string>&lt;qt&gt;When enabled, the system shows available applications in the autocompletion area.
&lt;/qt&gt;</string>
</property>
</widget>
<widget class="TQCheckBox" row="9" column="0" rowspan="1" colspan="4">
<property name="name">
<cstring>cbAutocomplete</cstring>
</property>
@ -192,7 +204,7 @@
&lt;/qt&gt;</string>
</property>
</widget>
<widget class="TQCheckBox" row="9" column="0" rowspan="1" colspan="4">
<widget class="TQCheckBox" row="10" column="0" rowspan="1" colspan="4">
<property name="name">
<cstring>cbAutohistory</cstring>
</property>

Loading…
Cancel
Save