Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
F
flatpak-qt-creator
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container Registry
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Marco Bubke
flatpak-qt-creator
Commits
03d0b577
Commit
03d0b577
authored
15 years ago
by
Friedemann Kleint
Browse files
Options
Downloads
Patches
Plain Diff
First polish of options dialog find: Set item flags, match on category.
Strip buddy markers.
parent
1d9af6cc
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
src/plugins/coreplugin/dialogs/settingsdialog.cpp
+6
-2
6 additions, 2 deletions
src/plugins/coreplugin/dialogs/settingsdialog.cpp
src/plugins/vcsbase/vcsbasesettingspage.cpp
+3
-1
3 additions, 1 deletion
src/plugins/vcsbase/vcsbasesettingspage.cpp
with
9 additions
and
3 deletions
src/plugins/coreplugin/dialogs/settingsdialog.cpp
+
6
−
2
View file @
03d0b577
...
...
@@ -66,6 +66,7 @@ template<class Parent>
IOptionsPage
*
page
=
0
)
{
QStandardItem
*
rc
=
new
QStandardItem
(
text
);
rc
->
setFlags
(
Qt
::
ItemIsEnabled
|
Qt
::
ItemIsSelectable
);
rc
->
setData
(
QVariant
(
int
(
type
)),
TypeRole
);
rc
->
setData
(
QVariant
(
index
),
IndexRole
);
rc
->
setData
(
qVariantFromValue
(
page
),
PageRole
);
...
...
@@ -115,8 +116,11 @@ bool PageFilterModel::filterAcceptsRow(int source_row, const QModelIndex &source
// Regular contents check, then check page-filter.
if
(
QSortFilterProxyModel
::
filterAcceptsRow
(
source_row
,
source_parent
))
return
true
;
if
(
const
IOptionsPage
*
page
=
pageOfItem
(
sourceModel
(),
source_parent
.
child
(
source_row
,
0
)))
return
page
->
matches
(
filterRegExp
().
pattern
());
if
(
const
IOptionsPage
*
page
=
pageOfItem
(
sourceModel
(),
source_parent
.
child
(
source_row
,
0
)))
{
const
QString
pattern
=
filterRegExp
().
pattern
();
return
page
->
trCategory
().
contains
(
pattern
,
Qt
::
CaseInsensitive
)
||
page
->
matches
(
pattern
);
}
return
false
;
}
...
...
This diff is collapsed.
Click to expand it.
src/plugins/vcsbase/vcsbasesettingspage.cpp
+
3
−
1
View file @
03d0b577
...
...
@@ -88,6 +88,7 @@ QString VCSBaseSettingsWidget::searchKeyWordMatchString() const
rc
+=
m_ui
->
nickNameMailMapLabel
->
text
();
rc
+=
blank
;
rc
+=
m_ui
->
nickNameFieldsFileLabel
->
text
();
rc
.
remove
(
QLatin1Char
(
'&'
));
// Strip buddy markers.
return
rc
;
}
...
...
@@ -130,7 +131,8 @@ QWidget *VCSBaseSettingsPage::createPage(QWidget *parent)
{
m_widget
=
new
VCSBaseSettingsWidget
(
parent
);
m_widget
->
setSettings
(
m_settings
);
m_searchKeyWords
=
m_widget
->
searchKeyWordMatchString
();
if
(
m_searchKeyWords
.
isEmpty
())
m_searchKeyWords
=
m_widget
->
searchKeyWordMatchString
();
return
m_widget
;
}
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment