Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
nheko
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Iterations
Wiki
Requirements
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Test cases
Artifacts
Deploy
Releases
Package registry
Container registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Code review analytics
Issue analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
GitLab community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Nheko Reborn
nheko
Commits
c5d373e8
Commit
c5d373e8
authored
Apr 29, 2020
by
Lasath Fernando
Browse files
Options
Downloads
Patches
Plain Diff
Address CR comments
parent
5c57de07
Branches
Branches containing commit
Tags
Tags containing commit
No related merge requests found
Changes
3
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
resources/qml/ScrollHelper.qml
+3
-2
3 additions, 2 deletions
resources/qml/ScrollHelper.qml
resources/qml/TimelineView.qml
+7
-6
7 additions, 6 deletions
resources/qml/TimelineView.qml
resources/qml/delegates/Pill.qml
+2
-4
2 additions, 4 deletions
resources/qml/delegates/Pill.qml
with
12 additions
and
12 deletions
resources/qml/ScrollHelper.qml
+
3
−
2
View file @
c5d373e8
...
@@ -22,7 +22,7 @@ import QtQuick.Controls 2.12
...
@@ -22,7 +22,7 @@ import QtQuick.Controls 2.12
/*
/*
* Shamelessly stolen from:
* Shamelessly stolen from:
* https://git
lab.com/spectral-im/spectral/-/blob/master/imports/Spectral/Component
/ScrollHelper.qml
* https://
c
git
.kde.org/kube.git/tree/framework/qml
/ScrollHelper.qml
*
*
* The MouseArea + interactive: false + maximumFlickVelocity are required
* The MouseArea + interactive: false + maximumFlickVelocity are required
* to fix scrolling for desktop systems where we don't want flicking behaviour.
* to fix scrolling for desktop systems where we don't want flicking behaviour.
...
@@ -42,13 +42,14 @@ MouseArea {
...
@@ -42,13 +42,14 @@ MouseArea {
z
:
-
1
z
:
-
1
onFlickableChanged
:
{
onFlickableChanged
:
{
if
(
enabled
)
{
if
(
enabled
)
{
flickable
.
interactive
=
false
flickable
.
maximumFlickVelocity
=
100000
flickable
.
maximumFlickVelocity
=
100000
flickable
.
boundsBehavior
=
Flickable
.
StopAtBounds
flickable
.
boundsBehavior
=
Flickable
.
StopAtBounds
root
.
parent
=
flickable
root
.
parent
=
flickable
}
}
}
}
acceptedButtons
:
Qt
.
NoButton
function
calculateNewPosition
(
flickableItem
,
wheel
)
{
function
calculateNewPosition
(
flickableItem
,
wheel
)
{
//Nothing to scroll
//Nothing to scroll
if
(
flickableItem
.
contentHeight
<
flickableItem
.
height
)
{
if
(
flickableItem
.
contentHeight
<
flickableItem
.
height
)
{
...
...
This diff is collapsed.
Click to expand it.
resources/qml/TimelineView.qml
+
7
−
6
View file @
c5d373e8
...
@@ -114,7 +114,6 @@ Page {
...
@@ -114,7 +114,6 @@ Page {
model
:
timelineManager
.
timeline
model
:
timelineManager
.
timeline
boundsBehavior
:
Flickable
.
StopAtBounds
boundsBehavior
:
Flickable
.
StopAtBounds
pixelAligned
:
true
ScrollHelper
{
ScrollHelper
{
flickable
:
parent
flickable
:
parent
...
@@ -208,10 +207,8 @@ Page {
...
@@ -208,10 +207,8 @@ Page {
text
:
chat
.
model
.
formatDateSeparator
(
modelData
.
timestamp
)
text
:
chat
.
model
.
formatDateSeparator
(
modelData
.
timestamp
)
color
:
colors
.
brightText
color
:
colors
.
brightText
leftPadding
:
24
height
:
fontMetrics
.
height
*
1.4
rightPadding
:
24
width
:
contentWidth
*
1.2
topPadding
:
8
bottomPadding
:
8
horizontalAlignment
:
Text
.
AlignHCenter
horizontalAlignment
:
Text
.
AlignHCenter
background
:
Rectangle
{
background
:
Rectangle
{
...
@@ -327,4 +324,8 @@ Page {
...
@@ -327,4 +324,8 @@ Page {
}
}
}
}
}
}
FontMetrics
{
id
:
fontMetrics
}
}
}
This diff is collapsed.
Click to expand it.
resources/qml/delegates/Pill.qml
+
2
−
4
View file @
c5d373e8
...
@@ -5,10 +5,8 @@ Label {
...
@@ -5,10 +5,8 @@ Label {
color
:
colors
.
brightText
color
:
colors
.
brightText
horizontalAlignment
:
Text
.
AlignHCenter
horizontalAlignment
:
Text
.
AlignHCenter
leftPadding
:
24
height
:
fontMetrics
.
height
*
1.4
rightPadding
:
24
width
:
contentWidth
*
1.2
topPadding
:
8
bottomPadding
:
8
background
:
Rectangle
{
background
:
Rectangle
{
radius
:
parent
.
height
/
2
radius
:
parent
.
height
/
2
...
...
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
sign in
to comment