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
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Nheko Reborn
nheko
Commits
f5a693ac
Commit
f5a693ac
authored
3 years ago
by
Malte E
Browse files
Options
Downloads
Patches
Plain Diff
place metadata below message when the Layout is narrow (<350)
parent
3f7c15c7
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Pipeline
#2601
passed
3 years ago
Stage: build
Changes
2
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
resources/qml/TimelineRow.qml
+20
-19
20 additions, 19 deletions
resources/qml/TimelineRow.qml
src/UserSettingsPage.cpp
+2
-3
2 additions, 3 deletions
src/UserSettingsPage.cpp
with
22 additions
and
22 deletions
resources/qml/TimelineRow.qml
+
20
−
19
View file @
f5a693ac
...
...
@@ -97,10 +97,11 @@ Item {
topMargin
:
1
bottomMargin
:
1
}
property
bool
narrowLayout
:
(
row
.
width
<
350
)
&&
Settings
.
bubbles
rowSpacing
:
0
columnSpacing
:
0
columns
:
2
rows
:
2
columns
:
narrowLayout
?
1
:
2
rows
:
narrowLayout
?
3
:
2
// fancy reply, if this is a reply
Reply
{
...
...
@@ -147,7 +148,7 @@ Item {
Layout.leftMargin
:
4
Layout.rightMargin
:
4
Layout.topMargin
:
reply
.
visible
?
2
:
4
Layout.bottomMargin
:
Settings
.
bubbles
?
4
:
2
Layout.bottomMargin
:
Settings
.
bubbles
?
(
msg
.
narrowLayout
?
0
:
4
)
:
2
id
:
contentItem
blurhash
:
r
.
blurhash
...
...
@@ -174,17 +175,17 @@ Item {
}
RowLayout
{
Layout.column
:
1
Layout.row
:
0
Layout.rowSpan
:
2
Layout.column
:
msg
.
narrowLayout
?
0
:
1
Layout.row
:
msg
.
narrowLayout
?
2
:
0
Layout.rowSpan
:
msg
.
narrowLayout
?
1
:
2
Layout.alignment
:
Qt
.
AlignTop
|
Qt
.
AlignRight
Layout.topMargin
:
4
Layout.topMargin
:
msg
.
narrowLayout
?
0
:
4
Layout.rightMargin
:
Settings
.
bubbles
?
4
:
0
property
double
scaling
:
msg
.
narrowLayout
?
0.75
:
1
StatusIndicator
{
Layout.alignment
:
Qt
.
AlignRight
|
Qt
.
AlignTop
Layout.preferredHeight
:
16
width
:
16
Layout.preferredHeight
:
16
*
parent
.
scaling
width
:
16
*
parent
.
scaling
status
:
r
.
status
eventId
:
r
.
eventId
}
...
...
@@ -192,12 +193,12 @@ Item {
Image
{
visible
:
isEdited
||
eventId
==
chat
.
model
.
edit
Layout.alignment
:
Qt
.
AlignRight
|
Qt
.
AlignTop
Layout.preferredHeight
:
16
Layout.preferredWidth
:
16
height
:
16
width
:
16
sourceSize.width
:
16
*
Screen
.
devicePixelRatio
sourceSize.height
:
16
*
Screen
.
devicePixelRatio
Layout.preferredHeight
:
16
*
parent
.
scaling
Layout.preferredWidth
:
16
*
parent
.
scaling
height
:
16
*
parent
.
scaling
width
:
16
*
parent
.
scaling
sourceSize.width
:
16
*
Screen
.
devicePixelRatio
*
parent
.
scaling
sourceSize.height
:
16
*
Screen
.
devicePixelRatio
*
parent
.
scaling
source
:
"
image://colorimage/:/icons/icons/ui/edit.svg?
"
+
((
eventId
==
chat
.
model
.
edit
)
?
Nheko
.
colors
.
highlight
:
Nheko
.
colors
.
buttonText
)
ToolTip.visible
:
editHovered
.
hovered
ToolTip.delay
:
Nheko
.
tooltipDelay
...
...
@@ -214,8 +215,8 @@ Item {
encrypted
:
isEncrypted
trust
:
trustlevel
Layout.alignment
:
Qt
.
AlignRight
|
Qt
.
AlignTop
Layout.preferredHeight
:
16
Layout.preferredWidth
:
16
Layout.preferredHeight
:
16
*
parent
.
scaling
Layout.preferredWidth
:
16
*
parent
.
scaling
}
Label
{
...
...
@@ -226,7 +227,7 @@ Item {
ToolTip.visible
:
ma
.
hovered
ToolTip.delay
:
Nheko
.
tooltipDelay
ToolTip.text
:
Qt
.
formatDateTime
(
timestamp
,
Qt
.
DefaultLocaleLongDate
)
font.pointSize
:
10
*
parent
.
scaling
HoverHandler
{
id
:
ma
}
...
...
This diff is collapsed.
Click to expand it.
src/UserSettingsPage.cpp
+
2
−
3
View file @
f5a693ac
...
...
@@ -70,7 +70,7 @@ UserSettings::load(std::optional<QString> profile)
enlargeEmojiOnlyMessages_
=
settings
.
value
(
QStringLiteral
(
"user/timeline/enlarge_emoji_only_msg"
),
false
).
toBool
();
markdown_
=
settings
.
value
(
QStringLiteral
(
"user/markdown_enabled"
),
true
).
toBool
();
bubbles_
=
settings
.
value
(
QStringLiteral
(
"user/bubbles_enabled"
),
true
).
toBool
();
bubbles_
=
settings
.
value
(
QStringLiteral
(
"user/bubbles_enabled"
),
true
).
toBool
();
animateImagesOnHover_
=
settings
.
value
(
QStringLiteral
(
"user/animate_images_on_hover"
),
false
).
toBool
();
typingNotifications_
=
...
...
@@ -1059,8 +1059,7 @@ UserSettingsModel::data(const QModelIndex &index, int role) const
"Allow using markdown in messages.
\n
When disabled, all messages are sent as a plain "
"text."
);
case
Bubbles
:
return
tr
(
"Messages received a bubble background."
);
return
tr
(
"Messages received a bubble background."
);
case
AnimateImagesOnHover
:
return
tr
(
"Plays media like GIFs or WEBPs only when explicitly hovering over them."
);
case
TypingNotifications
:
...
...
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