Commit bbed1cf6 authored by Christian Kandeler's avatar Christian Kandeler
Browse files

Maemo: Make it possible to filter remote process list by name.

parent 6357afcb
...@@ -60,7 +60,11 @@ MaemoRemoteProcessesDialog::MaemoRemoteProcessesDialog(const Core::SshConnection ...@@ -60,7 +60,11 @@ MaemoRemoteProcessesDialog::MaemoRemoteProcessesDialog(const Core::SshConnection
m_ui->tableView->setSelectionBehavior(QAbstractItemView::SelectRows); m_ui->tableView->setSelectionBehavior(QAbstractItemView::SelectRows);
m_proxyModel->setSourceModel(m_processList); m_proxyModel->setSourceModel(m_processList);
m_proxyModel->setDynamicSortFilter(true); m_proxyModel->setDynamicSortFilter(true);
m_proxyModel->setFilterKeyColumn(1);
m_ui->tableView->setModel(m_proxyModel); m_ui->tableView->setModel(m_proxyModel);
connect(m_ui->processFilterLineEdit, SIGNAL(textChanged(QString)),
m_proxyModel, SLOT(setFilterRegExp(QString)));
m_ui->processFilterLineEdit->setText(QLatin1String("[^ ]+"));
connect(m_ui->tableView->selectionModel(), connect(m_ui->tableView->selectionModel(),
SIGNAL(selectionChanged(QItemSelection,QItemSelection)), SIGNAL(selectionChanged(QItemSelection,QItemSelection)),
SLOT(handleSelectionChanged())); SLOT(handleSelectionChanged()));
......
...@@ -11,16 +11,36 @@ ...@@ -11,16 +11,36 @@
</rect> </rect>
</property> </property>
<property name="windowTitle"> <property name="windowTitle">
<string>Dialog</string> <string>List of Remote Processes</string>
</property> </property>
<layout class="QVBoxLayout" name="verticalLayout_2"> <layout class="QVBoxLayout" name="verticalLayout_2">
<item> <item>
<widget class="QLabel" name="label"> <layout class="QHBoxLayout" name="horizontalLayout_2">
<item>
<widget class="QLabel" name="filterLabel">
<property name="text"> <property name="text">
<string>Processes running on remote host:</string> <string>Filter by process name:</string>
</property> </property>
</widget> </widget>
</item> </item>
<item>
<widget class="QLineEdit" name="processFilterLineEdit"/>
</item>
<item>
<spacer name="horizontalSpacer">
<property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>40</width>
<height>20</height>
</size>
</property>
</spacer>
</item>
</layout>
</item>
<item> <item>
<layout class="QHBoxLayout" name="horizontalLayout"> <layout class="QHBoxLayout" name="horizontalLayout">
<item> <item>
......
Supports Markdown
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