Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Angelfish
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
9
Issues
9
List
Boards
Labels
Service Desk
Milestones
Merge Requests
2
Merge Requests
2
Operations
Operations
Incidents
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Plasma Mobile
Angelfish
Commits
2f1e2985
Commit
2f1e2985
authored
Mar 05, 2020
by
Rinigus Saar
Committed by
Jonah Brüchert
Mar 05, 2020
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Add search fields to bookmarks/history and fix search for navigation entry
parent
815e6b40
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
51 additions
and
17 deletions
+51
-17
src/contents/ui/Bookmarks.qml
src/contents/ui/Bookmarks.qml
+22
-6
src/contents/ui/History.qml
src/contents/ui/History.qml
+24
-5
src/contents/ui/NavigationEntrySheet.qml
src/contents/ui/NavigationEntrySheet.qml
+3
-4
src/contents/ui/UrlDelegate.qml
src/contents/ui/UrlDelegate.qml
+2
-2
No files found.
src/contents/ui/Bookmarks.qml
View file @
2f1e2985
...
...
@@ -22,26 +22,43 @@
import
QtQuick
2.3
import
QtQuick
.
Layouts
1.0
import
org
.
kde
.
kirigami
2.7
as
Kirigami
import
org
.
kde
.
kirigami
2.8
as
Kirigami
import
org
.
kde
.
mobile
.
angelfish
1.0
Kirigami.ScrollablePage
{
// id: options
title
:
i18n
(
"
Bookmarks
"
)
Kirigami.ColumnView.fillWidth
:
false
header
:
Item
{
anchors.horizontalCenter
:
parent
.
horizontalCenter
height
:
Kirigami
.
Units
.
gridUnit
*
3
width
:
list
.
width
Kirigami.SearchField
{
id
:
search
anchors.centerIn
:
parent
width
:
parent
.
width
-
Kirigami
.
Units
.
gridUnit
clip
:
true
Kirigami.Theme.inherit
:
true
onDisplayTextChanged
:
list
.
model
.
filter
=
displayText
;
Keys.onEscapePressed
:
pageStack
.
pop
()
}
}
Component
{
id
:
delegateComponent
UrlDelegate
{
highlightText
:
list
.
model
.
filter
onClicked
:
pageStack
.
pop
()
onRemoved
:
BrowserManager
.
removeBookmark
(
url
);
}
}
ListView
{
id
:
list
anchors.fill
:
parent
interactive
:
height
<
contentHeight
...
...
@@ -52,9 +69,8 @@ Kirigami.ScrollablePage {
}
delegate
:
Kirigami.DelegateRecycler
{
width
:
paren
t
.
width
width
:
lis
t
.
width
sourceComponent
:
delegateComponent
}
}
Component.onCompleted
:
print
(
"
Bookmarks.qml complete.
"
);
}
src/contents/ui/History.qml
View file @
2f1e2985
...
...
@@ -22,24 +22,43 @@
import
QtQuick
2.3
import
QtQuick
.
Layouts
1.0
import
org
.
kde
.
kirigami
2.
7
as
Kirigami
import
org
.
kde
.
kirigami
2.
8
as
Kirigami
import
org
.
kde
.
mobile
.
angelfish
1.0
Kirigami.ScrollablePage
{
id
:
history
title
:
i18n
(
"
History
"
)
Kirigami.ColumnView.fillWidth
:
false
header
:
Item
{
anchors.horizontalCenter
:
parent
.
horizontalCenter
height
:
Kirigami
.
Units
.
gridUnit
*
3
width
:
list
.
width
Kirigami.SearchField
{
id
:
search
anchors.centerIn
:
parent
width
:
parent
.
width
-
Kirigami
.
Units
.
gridUnit
clip
:
true
Kirigami.Theme.inherit
:
true
onDisplayTextChanged
:
list
.
model
.
filter
=
displayText
;
Keys.onEscapePressed
:
pageStack
.
pop
()
}
}
Component
{
id
:
delegateComponent
UrlDelegate
{
highlightText
:
list
.
model
.
filter
onClicked
:
pageStack
.
pop
()
onRemoved
:
BrowserManager
.
removeFromHistory
(
url
);
}
}
ListView
{
id
:
list
anchors.fill
:
parent
interactive
:
height
<
contentHeight
...
...
@@ -49,11 +68,11 @@ Kirigami.ScrollablePage {
history
:
true
}
delegate
:
Kirigami.DelegateRecycler
{
width
:
paren
t
.
width
width
:
lis
t
.
width
sourceComponent
:
delegateComponent
}
}
Component.onCompleted
:
print
(
"
History.qml complete.
"
);
Component.onCompleted
:
search
.
forceActiveFocus
()
}
src/contents/ui/NavigationEntrySheet.qml
View file @
2f1e2985
...
...
@@ -75,14 +75,13 @@ Controls.Drawer {
Layout.fillWidth
:
true
clip
:
true
focus
:
false
selectByMouse
:
true
Kirigami.Theme.inherit
:
true
onActiveFocusChanged
:
if
(
activeFocus
)
selectAll
()
onAccepted
:
applyUrl
()
onTextChanged
:
{
on
Display
TextChanged
:
{
if
(
!
openedState
)
return
;
// avoid filtering
urlFilter
.
filter
=
t
ext
;
urlFilter
.
filter
=
displayT
ext
;
justOpened
=
false
;
}
Keys.onEscapePressed
:
if
(
overlay
.
sheetOpen
)
overlay
.
close
()
...
...
@@ -125,7 +124,7 @@ Controls.Drawer {
delegate
:
UrlDelegate
{
showRemove
:
false
onClicked
:
overlay
.
close
()
highlightText
:
urlInput
.
t
ext
highlightText
:
urlInput
.
displayT
ext
width
:
parent
.
width
}
...
...
src/contents/ui/UrlDelegate.qml
View file @
2f1e2985
...
...
@@ -32,7 +32,7 @@ Kirigami.SwipeListItem {
property
string
highlightText
property
var
regex
:
new
RegExp
(
highlightText
,
'
i
'
)
property
string
highlightedText
:
"
<b><font color=
\"
"
+
Kirigami
.
Theme
.
highligh
tColor
+
"
\"
>$&</font></b>
"
property
string
highlightedText
:
"
<b><font color=
\"
"
+
Kirigami
.
Theme
.
selectionTex
tColor
+
"
\"
>$&</font></b>
"
height
:
Kirigami
.
Units
.
gridUnit
*
3
...
...
@@ -55,7 +55,7 @@ Kirigami.SwipeListItem {
anchors.fill
:
parent
fillMode
:
Image
.
PreserveAspectFit
source
:
model
.
icon
?
model
.
icon
:
""
source
:
model
&&
model
.
icon
?
model
.
icon
:
""
}
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment