Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
jami-client-qt
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
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
savoirfairelinux
jami-client-qt
Commits
f15233b3
Commit
f15233b3
authored
3 years ago
by
Sébastien Blin
Browse files
Options
Downloads
Patches
Plain Diff
draft: Implement new design for the draft indicator
GitLab:
#427
Change-Id: I73818240946ab7c42eb238c50ca0f38061ff13d9
parent
29c758a1
No related branches found
Branches containing commit
Tags
beta/202310101006
Tags containing commit
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
src/conversationlistmodelbase.cpp
+2
-9
2 additions, 9 deletions
src/conversationlistmodelbase.cpp
src/mainview/components/SmartListItemDelegate.qml
+9
-0
9 additions, 0 deletions
src/mainview/components/SmartListItemDelegate.qml
with
11 additions
and
9 deletions
src/conversationlistmodelbase.cpp
+
2
−
9
View file @
f15233b3
...
...
@@ -90,15 +90,8 @@ ConversationListModelBase::dataForItem(item_t item, int role) const
return
{};
}
case
Role
::
Draft
:
{
if
(
!
item
.
uid
.
isEmpty
())
{
const
auto
draft
=
lrcInstance_
->
getContentDraft
(
item
.
uid
,
item
.
accountId
);
if
(
!
draft
.
isEmpty
())
{
// Pencil Emoji
uint
cp
=
0x270F
;
auto
emojiString
=
QString
::
fromUcs4
(
reinterpret_cast
<
char32_t
*>
(
&
cp
),
1
);
return
emojiString
+
draft
;
}
}
if
(
!
item
.
uid
.
isEmpty
())
return
lrcInstance_
->
getContentDraft
(
item
.
uid
,
item
.
accountId
);
return
{};
}
case
Role
::
IsRequest
:
...
...
This diff is collapsed.
Click to expand it.
src/mainview/components/SmartListItemDelegate.qml
+
9
−
0
View file @
f15233b3
...
...
@@ -36,6 +36,8 @@ ItemDelegate {
property
string
accountId
:
""
property
string
convId
:
""
highlighted
:
ListView
.
isCurrentItem
onVisibleChanged
:
{
if
(
visible
)
return
...
...
@@ -129,6 +131,13 @@ ItemDelegate {
color
:
JamiTheme
.
primaryForegroundColor
}
// Draft indicator
ResponsiveImage
{
visible
:
Draft
&&
!
root
.
highlighted
source
:
JamiResources
.
round_edit_24dp_svg
color
:
JamiTheme
.
primaryForegroundColor
}
ColumnLayout
{
Layout.fillHeight
:
true
spacing
:
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
register
or
sign in
to comment