Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
jami-client-ios
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Iterations
Wiki
Requirements
Code
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Locked files
Deploy
Releases
Model registry
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
Repository 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
savoirfairelinux
jami-client-ios
Commits
ec1d7963
Commit
ec1d7963
authored
1 year ago
by
Kateryna Kostiuk
Browse files
Options
Downloads
Patches
Plain Diff
smartList: add donation option to menu
Change-Id: Ib7f5fc7259f0dbae56277d252ff33f0296038123
parent
cc177a6c
No related branches found
No related tags found
No related merge requests found
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
Ring/Ring/Extensions/UIColor+Ring.swift
+1
-0
1 addition, 0 deletions
Ring/Ring/Extensions/UIColor+Ring.swift
Ring/Ring/Features/Conversations/SmartList/SmartlistViewController.swift
+8
-1
8 additions, 1 deletion
...res/Conversations/SmartList/SmartlistViewController.swift
with
9 additions
and
1 deletion
Ring/Ring/Extensions/UIColor+Ring.swift
+
1
−
0
View file @
ec1d7963
...
@@ -88,6 +88,7 @@ extension UIColor {
...
@@ -88,6 +88,7 @@ extension UIColor {
}
}
static
let
jamiMain
=
UIColor
(
red
:
0
,
green
:
86
,
blue
:
153
,
alpha
:
1.0
)
static
let
jamiMain
=
UIColor
(
red
:
0
,
green
:
86
,
blue
:
153
,
alpha
:
1.0
)
static
let
jamiDonation
=
UIColor
(
red
:
255
,
green
:
0
,
blue
:
69
,
alpha
:
1.0
)
static
let
conferenceRaiseHand
=
UIColor
(
red
:
0
,
green
:
184
,
blue
:
255
,
alpha
:
1.0
)
static
let
conferenceRaiseHand
=
UIColor
(
red
:
0
,
green
:
184
,
blue
:
255
,
alpha
:
1.0
)
static
let
jamiSecondary
=
UIColor
(
hex
:
0x1F4971
,
alpha
:
1.0
)
static
let
jamiSecondary
=
UIColor
(
hex
:
0x1F4971
,
alpha
:
1.0
)
static
let
jamiButtonLight
=
UIColor
(
named
:
"jamiButtonLight"
)
!
static
let
jamiButtonLight
=
UIColor
(
named
:
"jamiButtonLight"
)
!
...
...
This diff is collapsed.
Click to expand it.
Ring/Ring/Features/Conversations/SmartList/SmartlistViewController.swift
+
8
−
1
View file @
ec1d7963
...
@@ -704,7 +704,7 @@ extension SmartlistViewController: CNContactPickerDelegate {
...
@@ -704,7 +704,7 @@ extension SmartlistViewController: CNContactPickerDelegate {
// MARK: - menu
// MARK: - menu
extension
SmartlistViewController
{
extension
SmartlistViewController
{
private
func
createMenu
()
->
UIMenu
{
private
func
createMenu
()
->
UIMenu
{
return
UIMenu
(
title
:
""
,
children
:
[
createSwarmAction
(),
inviteFriendsAction
(),
accountsAction
(),
openAccountAction
(),
openSettingsAction
(),
aboutJamiAction
()])
return
UIMenu
(
title
:
""
,
children
:
[
createSwarmAction
(),
inviteFriendsAction
(),
accountsAction
(),
openAccountAction
(),
openSettingsAction
(),
donateAction
(),
aboutJamiAction
()])
}
}
private
func
createTintedImage
(
systemName
:
String
,
configuration
:
UIImage
.
SymbolConfiguration
,
tintColor
:
UIColor
)
->
UIImage
?
{
private
func
createTintedImage
(
systemName
:
String
,
configuration
:
UIImage
.
SymbolConfiguration
,
tintColor
:
UIColor
)
->
UIImage
?
{
...
@@ -732,6 +732,13 @@ extension SmartlistViewController {
...
@@ -732,6 +732,13 @@ extension SmartlistViewController {
}
}
}
}
private
func
donateAction
()
->
UIAction
{
let
image
=
createTintedImage
(
systemName
:
"heart"
,
configuration
:
configuration
,
tintColor
:
.
jamiDonation
)
return
UIAction
(
title
:
L10n
.
Global
.
donate
,
image
:
image
,
identifier
:
nil
,
discoverabilityTitle
:
nil
,
attributes
:
[],
state
:
.
off
)
{
_
in
SharedActionsPresenter
.
openDonationLink
()
}
}
private
func
accountsAction
()
->
UIAction
{
private
func
accountsAction
()
->
UIAction
{
let
image
=
createTintedImage
(
systemName
:
"list.bullet"
,
configuration
:
configuration
,
tintColor
:
.
jamiButtonDark
)
let
image
=
createTintedImage
(
systemName
:
"list.bullet"
,
configuration
:
configuration
,
tintColor
:
.
jamiButtonDark
)
return
UIAction
(
title
:
L10n
.
Smartlist
.
accounts
,
image
:
image
,
identifier
:
nil
,
discoverabilityTitle
:
nil
,
attributes
:
[],
state
:
.
off
)
{
[
weak
self
]
_
in
return
UIAction
(
title
:
L10n
.
Smartlist
.
accounts
,
image
:
image
,
identifier
:
nil
,
discoverabilityTitle
:
nil
,
attributes
:
[],
state
:
.
off
)
{
[
weak
self
]
_
in
...
...
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