Compare commits

...

131 Commits

Author SHA1 Message Date
d6829fcaee misc: bump daemon
Change-Id: I11c9a6b329037cdd3bd3e82192e540403bf6286f
2023-03-06 15:44:10 -05:00
ef4e6c1171 MainView: apply the new design for the button color of the main view in dark mode
Change-Id: Iedfda66405df58b758e88ff102f8c1a53cbf3a69
2023-03-06 15:43:14 -05:00
3f2afd2cfb sip: remove useless switchbox
This option is fully replaced by sded media exchange and the switch
is only enabling the two next checkboxes

Change-Id: Ida4736fd6aa8e2a9c5327aa3bc4b236ecaa0a69e
2023-03-06 15:43:09 -05:00
d2efaf5953 MessageListView: add border to message bubble when there is a reply
Change-Id: I461a8ecb4ea064b9b22dd1db7a96a71eb8082321
2023-03-06 14:46:56 -05:00
0de8f019b2 conversation: add the possibility to answer with a file
Also remove retryInteraction as useless in new versions.

Change-Id: I79a016c9fa7b8bc4d5fcdb0aeff51d78aea2f314
GitLab: #1017
2023-03-06 14:46:07 -05:00
bd3ee22c83 build.py: fix run_init
hooks must be installed after the module is cloned.

Change-Id: Ie09a87befbfd217b6c1ad404bf3a457e6d413065
2023-03-06 12:07:44 -05:00
e7e59eba63 callview: fix double click fullscreen
GitLab: #990
GitLab: #1016
Change-Id: Ia578493cb60271b284829dbef9179a0fccebbbd2
2023-03-06 10:48:20 -05:00
92ee3806bd recording settings: fix label
Change-Id: I1ede809e160cc7c58f098a6829bfe47a63e51770
2023-03-06 10:26:43 -05:00
b9ce9a4589 INSTALL.md: update command to run the client
Change-Id: I7a2931bae692b1bf68b7bfc85991e8e86b6fd51b
2023-03-06 08:38:26 -05:00
0679c0e04c conversationmenu: fix incorrect end call state
Change-Id: I6420f6233bbf9a92f7821735c02fcc29e478d111
GitLab: #942
2023-03-06 08:37:15 -05:00
98569e2c70 smartlist: reload messages on language change
Change-Id: I50893c6296040ad6bc972050d595cdedd27f635c
GitLab: #936
2023-03-03 15:19:24 -05:00
55977e748d currentcall: setCurrentCall only on active calls
Change-Id: I9f16e8a3633981d41429343885a3130b0496288d
GitLab: #1007
2023-03-03 15:07:57 -05:00
5380a86b5c messagelistview: fix sequencing on edition
No need to re-compute sequencing as deleted messages are just
replaced by "Deleted message" and edition should not change any
sequencing

Change-Id: I03e210ac88b919b76b409583de2221406e468f50
GitLab: #991
2023-03-03 14:49:05 -05:00
266aae543d wizard: fix focus on username
Change-Id: Ic925c96106d6c30eb8268af652b367029c5b7e70
GitLab: #1013
2023-03-03 14:41:17 -05:00
251d8d8123 misc: update audio devices and language list language changes
GitLab: #964
Change-Id: I70e5ba12c237a1623667c1783ead78fed76b3bc0
2023-03-03 13:40:53 -05:00
ad1bc98b6e fedora: use fmt-devel from system
Change-Id: I32c6dba09b01e87f7e9b48f7a4ab853d26526c63
2023-03-03 08:58:10 -05:00
16de04c0e5 libclient: Do not duplicate 'lib' prefix.
CMake takes care itself to prefix a library name with 'lib'.

* src/libclient/CMakeLists.txt (LIBCLIENT_NAME): Drop 'lib' prefix.

Change-Id: I9b6e0a8bd7bf2cfcec8b8b0996f87035a4f2e906
2023-03-02 22:27:53 -05:00
4712de7ed0 snap: use opus-dev from distribution
Change-Id: I9ce321779f578395719670433650f47987a32480
2023-03-02 16:30:03 -05:00
de7c182adc packaging: Improve PACKAGING_TARGETS parameter documentation.
* extras/packaging/gnu-linux/Jenkinsfile: Improve PACKAGING_TARGETS
parameter documentation.

Change-Id: I83de03a7d722ff391cc41098a0cce9334e014d75
2023-03-02 13:47:28 -05:00
1442d37ae8 packaging: Add support for RPM guix packs.
* extras/packaging/gnu-linux/Makefile (GUIX_PACK_FORMATS): New
variable.
(guix-pack-command): Add format argument.  Make the --postinst-file
argument conditional to the 'deb' format.
(define-deb-pack-rule): Rename to...
(define-guix-pack-rule): ... this.  Add a new format argument, and
move existing architecture argument into 2nd position.
* extras/packaging/gnu-linux/scripts/deploy-packages.sh
(package): Register 'guix-rpm-pack' as RPM packages.

Change-Id: I1b5501c02e917b2b0c5e92e775a85478dd67316e
2023-03-02 13:47:27 -05:00
b41f1d36c7 packaging: Restore first citizenship of Guix deb packs.
Build them by default again.

* extras/packaging/gnu-linux/Jenkinsfile [BUILD_DEB_PACK]: Remove parameter.
('Build packages'): Do not filter out deb packs by default.

Change-Id: Id65c00de0a50c263b672986a61776b02cf69a2e4
2023-03-02 13:47:27 -05:00
12b874e4f4 packaging: Sort output of 'list-package-targets' target.
* extras/packaging/gnu-linux/Makefile (list-package-targets): Sort output.

Change-Id: I5d4f51c502d6d99d1ddf99c91422706ef230f01a
2023-03-02 13:47:27 -05:00
e0cc1e301f packaging: Fix deb-pack package.
The with-libjami/latest rewriting procedure was not applied to the
customized jami package, hence it was using libjami at its current
version in GNU Guix and failing to build.

* extras/packaging/gnu-linux/guix/guix-pack-manifest.scm
(with-latest-sources): Apply patch.
(libjami/latest): Disable test suite.
(jami-with-certs): Re-introduce -DLIBJAMI_INCLUDE_DIR configure flag.
(jami-with-certs/latest): Apply to with-libjami/latest.

Change-Id: I6266fa691dc8995300afb15bdbc9ce1640ab4d1d
2023-03-02 13:47:27 -05:00
0bf99a8fee build: Use the new --symlink option instead of --expose.
Instead of leaking host TLS certificates at /etc/ssl/certs for GnuTLS,
we can now have the directory symlinked to the ones provided by the
nss-certs package in the Guix container, which is cleaner.

* extras/packaging/gnu-linux/Makefile
(portable-release-tarball): Replace --expose options with --symlink.
* build.py (run_install): Likewise.

Change-Id: Id3b8c2b3dd06fade10bbd280fd0af8f9ac8fde45
2023-03-02 13:47:27 -05:00
8a15f18d1c conversationmodel: handle double call at the same time
If both sides are calling at the same time, the daemon will chose
one of the call. We must use this one.

https://git.jami.net/savoirfairelinux/jami-daemon/-/issues/743

Change-Id: I09c991c0facf34cf7ed83d8782b7646b3075eed8
2023-03-02 13:00:00 -05:00
8716154b58 profile: minor fixes
+ ModalTextEdit should not change its editMode if isPersistent,
else some editions can be missed.
+ Do not emit profileChanged when the client changes only the
alias, as it's updated by the account's config.

Change-Id: I3381b7494366fcd2d6a8504f0dcf18b622dc1701
2023-03-02 12:13:48 -05:00
9e05e3e186 accountcombobox: force active focus on click
Change-Id: Iafbb43d57dd8efe56ca696e64f7193bb0b24b19a
GitLab: #950
2023-03-02 12:13:39 -05:00
048bdfba78 macOS: fix unified build
Change-Id: I01048863c6a60ba0f32d5a0daec6b504a54818ed
2023-03-02 10:53:05 -05:00
06e9e91c4d modalTextEdit: hide placeholder when selected
GitLab: #986
Change-Id: I4672ca2240a04a2a25780506750d0233b442aba5
2023-03-02 11:37:16 -03:00
410a15a09f misc: fix default initial width
Change-Id: Ia9c59045e85bd368496841c710e5438b70711437
2023-03-02 11:01:46 -03:00
4650c96848 currentconversation: fix property updates
Some local slots that rely on id change are called within the updateData method, and the late update to id_ was causing them to fail.

We just set the id and manually notify of a property change on scope exit if needed.

Change-Id: Ifd108c0eba492b0c5f8fb3dccb9e0d42c9a223a0
2023-03-02 08:41:49 -05:00
4e088783a4 misc: avoid weird crash
Change-Id: I6e42a4f494b42330bafcfa4c9616ab78818ddf00
2023-03-02 08:31:47 -05:00
9f42301b5c devicemodel: do not lock when emitting signal
This can cause a deadlock, also use onAccepted to avoid
sporadic changes

Change-Id: Ic7ff97b7e8fdd64da981eaf0b3148edd6d4eccd6
GitLab: #1011
2023-03-02 08:31:36 -05:00
b9f2ebd1a5 macOS: fix single architecture build
Change-Id: I2702cbc0c0fee71d17eb2902b5c7c242a237f06a
2023-03-01 20:57:27 -05:00
13ef62ea57 callactionbar: freeze bar when hovered
Change-Id: Ie899a956d352d4a285480c75392bf79751b63e60
GitLab: #1005
2023-03-01 13:42:32 -05:00
2f3d06859f wizardview: fix NoUsername popup opening
Change-Id: I95a2186f3a5f7b3fbaedced0f5629e7cd4a9d726
GitLab: #1010
2023-03-01 13:41:21 -05:00
d5064040d7 MessageListView: fix message bubble UI
+ redesign the "Scroll to end of conversation"
+ redesign the "bubble / screen ratio"
+ redesign the reply bubbles: color, shape(in & out a message sequence), "In reply To" message
+ change the configurable color of the main user's bubbles
+ show the display name when replying to a transfer message
+ fix incorrectly loaded reply message data by synchronizing to messages loaded request
+ fix reply to an internet link
+ redesign the call bubbles (the new design need to be applied but in another patch)

GitLab: #959
GitLab: #967

Change-Id: Id646ff875644425b03367838b5b46f2242294563
2023-03-01 13:38:05 -05:00
84d625c1b4 currentconversation: always set the current conversation id
This must be done even when empty and contributes to the deselection mechanism.

Change-Id: Ia97186ad8f37763ed2c8f61f4f44a0a04df7577b
2023-03-01 13:23:58 -05:00
7a844ee1ae misc: bump daemon (fix CI for macOS)
Change-Id: I62ba9ab56f0840ca568b4475c195cad945065ea0
2023-03-01 10:10:49 -05:00
6af096c9b4 misc: fix setCurrentCall when switching between two different calls
Change-Id: Ia84b8580e02eeba946209e472caafcea03b85444
2023-03-01 10:09:42 -05:00
1205231707 participantoverlay: fix buttons hover color
Change-Id: I981d3db41a2a2fecbece83d1d84f63c48de82888
GitLab: #996
2023-03-01 09:37:05 -03:00
030ed15021 conversationview: fix focus on callview
THis fixes mic and cam shortcuts

Change-Id: I51f8ea975a5d8bee0e9ceab712a58953646ce048
2023-03-01 08:56:16 -03:00
edeff74c52 callview: move swarm details access to the actionbar
Change-Id: I0a450ab0a82943bd5e929ccd281784867edebd30
GitLab: #998
2023-03-01 08:56:16 -03:00
eaec313a3c misc: fit edited message to area
Change-Id: I019fba4105bde11d049d64a8e94716c0e977f79e
GitLab: #1001
2023-03-01 06:51:05 -05:00
10e4b63414 callview: set minimumwidth for splited chatview
GitLab: #1000
GitLab: #974

Change-Id: I5f14dc9447bf88d1addebfccd07dc84c632af426
2023-02-28 17:57:26 -03:00
05c52e89fa materialradiobutton: fix in white theme
Change-Id: I40bf43240408f136557835e0dc536c6b4a894c17
2023-02-28 14:46:17 -05:00
ba867b0636 macos: support unified build
This patch adds a parameter arch to specify architecture
to build. This parameter could be arm64, x86_64 or unified.

Change-Id: I2907e03410e0c01b8505afbe283da04b8d0291b6
2023-02-28 14:30:05 -05:00
f88f566e89 sip account creation: radiobutton for TLS/UDP
- created MaterialRadioButton
- added tls/udp options in sip wizard
- Fix some focus issues and some spacing

Change-Id: I18c5b7205bbe1c8178a5c3a966c9bfa0cffa93b4
2023-02-28 14:08:22 -05:00
506eb7bc78 messagelistmodel: never ever edit body from client
This is impossible to follow correctly, causing weird things.
Now Body always contains the original Body from the libclient,
LinkifiedBody the linkified Body and Linkified is empty if the
message is not linkified.

Change-Id: I29e5f7cf1c5a2093f5e4b7785216e8b9b24e9ad8
GitLab: #961
2023-02-28 14:04:26 -05:00
5f6f86b2a9 contactsearchbar: replace label
Change-Id: Ib51a026cf5f31479d28a21f4cbc76396a44ae9b3
GitLab: #985
2023-02-28 14:03:57 -05:00
4ba641789d callmodel: update current call on conference creation
If a call starts in a swarm, the host must show the confId.
The current call wasn't updated when a call is upgraded to a conference
causing the wrong call to be shown due to the new logic

Change-Id: I990d39e6e04253bc087fd0ec73c5b6c7906f93d9
2023-02-28 14:03:52 -05:00
50ad6c5073 connectToAccountPage: fix jams connection
Change-Id: I4863d4c5db50ea7ef52de000ad901006bec723ae
2023-02-28 14:02:10 -05:00
77f051ce59 modaltextedit: accept state as soon as focus changes
So that pressing tab will emit onAccepted and the dynamic text
always show the correct value saved.

Change-Id: I64326f1f836d611776bcfaf7993e6254e5d5aefe
2023-02-28 14:02:10 -05:00
146afcd6a9 location sharing: fix on macOS
Qt::UniqueConnection should not be used with lambda. This patch
adds class function so it could be used with Qt::UniqueConnection

Change-Id: I98d84d7f60758d9f217abfe26102d4586f7bbc27
2023-02-28 10:54:50 -05:00
4612d5318b chatview: refactor msg options popup positioning
+ load the popup dynamically
+ calculate the position using the delegate's attached ListView geometry

Gitlab: #979
Change-Id: I9d3a8a31b4aba2f195c4d6453e9dca88e99685ae
2023-02-28 10:05:26 -05:00
42a46fe165 settingsview: homogenize ModalTextEdit usage
GitLab: #986
GitLab: #1004

Change-Id: Iea441cba4c258a82b9a553c93c81e4d76f0baa1c
2023-02-28 09:30:06 -05:00
05beb246e8 wizardview: fix focus, tooltip, ModalTextEdit
- replaced all line edit with ModalTextEdit components
- fixed keyboard navigation
- fixed focus and tooltips

Change-Id: I5605e1b4a7efe2910c4031e49abb78b39b1955f6
2023-02-28 09:30:06 -05:00
e932c37528 settingsview: updated lineEdits
- replaced line edits with ModalTextEdit components

Change-Id: I0e386b443d6d46dcc412e36a6956add595337b58
2023-02-28 09:30:06 -05:00
c722ddb280 ModalTextEdit: adapted for general use
- modified UsernameTextEdit
- added PasswordTextEdit
- changed focus
- added echoMode
- added second suffix icon

Change-Id: I16e0a248757a125bed28aefc375a09cd267f8db2
2023-02-28 09:30:06 -05:00
cf8e4a87e3 i18n: automatic bump
Change-Id: I6909535814e2a481b2455c0fcece6b32aaea28cb
2023-02-27 16:58:21 -05:00
2c5dfd85d5 mainview: preload the conversation view
This prevents a bug when loading into the call view before having loaded the conversation view at least once, can prevent the call action bar from displaying.


Gitlab: #1002
Change-Id: I1c9e3debc0341630b3ca104bfbdfa71339918e6b
2023-02-27 11:02:48 -05:00
708e53589e views: inhibit the conversation-view when priority views are present
The call-view shouldn't take priority, or be displayed at all while in these views under the current design.

Gitlab: #1003
Change-Id: I5e9ae140c11dc13c3b44014007e41857d528a49d
2023-02-27 11:02:48 -05:00
f808d42687 misc: move viewmanager into a separate file
Change-Id: Id5659ede0fc870926b4b627a5bbe12c67d4f9224
2023-02-27 11:02:48 -05:00
759e3ea310 sip: fix outgoing text message
Change-Id: I3aba2f02e375d47a9bfdacb923e2907c40f4f151
2023-02-27 09:26:40 -05:00
9afeea435f JamiIdentifier: share button not working
- Dialog through viewCoordinator

Change-Id: I799891a3f17b9fdde9a1c16c490c343c2eafc163
GitLab: #999
2023-02-23 15:23:42 -05:00
be1ee4e4f8 updater: fix overlapping download progress
+ also fixes the missing confirm-update string

Change-Id: Ib8d0dce0b09e7415795d96d5c45b2f8a0f19bd30
2023-02-23 13:55:20 -05:00
58031af31f messagelistview: hide "Scroll to end" after click
When scrolling up and clicking on "Scroll to end", sometimes, the
button didn't update correctly. Using contentY = 0 seems to be correct

Change-Id: I04576181d0b61006d4389be6ace3b09c1ac0a2f9
2023-02-23 09:11:18 -05:00
2baf76e74b videoprovider: remove frame subscription on QVideoSink::destroyed
We can observe that frame update signals can occur after a VideoOutput component's QVideoSink object has started destruction. The deregistration of the object pointer needs to be synchronized to the object's destruction.

Additionally:
+ scope the frame obj mutex locker around checks for no subs
+ rename (un)registerSink to (un)subscribe
+ subscribe will now remove the previous subscription
+ subscribe with an empty id will unsubscribe

Gitlab: #997
Change-Id: I21460564e49189b9276f153e8c1fd3a5cc52c6b2
2023-02-22 13:59:22 -05:00
7161858daf packaging: Update Guix revision.
* extras/packaging/gnu-linux/guix/channels.scm (channel): Bump Guix to
current commit.

Change-Id: Ib929a948f47a1d9ee73ba7340be6821fdd4f6a0d
2023-02-22 13:32:47 -05:00
3a8068f990 misc: open swarm after creation
Change-Id: I936abb96b5e232b63a917428892f716ca0985db2
GitLab: #952
2023-02-22 09:10:51 -05:00
e2d5da8151 windows: watch for system theme change
Requires Windows SDK version 10.0.18362.0 and Windows Runtime
10.0.10240.0.

GitLab: #723
Change-Id: I166c236bf24419b4abfe323f88e470dd07afbd4f
2023-02-22 09:10:13 -05:00
003b6be691 packaging: Simplify 'Publish release artifacts stage' logic.
* extras/packaging/gnu-linux/Jenkinsfile
(Publish release artifacts'): Simplify logic.

Change-Id: I4cec0b8009256501d627453df26bd17024e55f45
2023-02-21 16:07:57 -05:00
9355c1a2df packaging: Cosmetic change to Makefile.
Change-Id: I9036912033aee53370d4f7cf5a854a2495de0485
2023-02-21 16:07:57 -05:00
4461ba6902 Jenkinsfile: Break long lines.
* extras/packaging/gnu-linux/Jenkinsfile: Break long lines.

Change-Id: Idd6f72e18e0b4489a22e7aa2a59b4cc8ac90dbee
2023-02-21 16:07:57 -05:00
f6606722d6 misc: cleanup set_currentRenderingDeviceType
The media is already stored in the call info.
Moreover, no need to hide "share monitor" when we are sharing
the screen, because we may want to switch between a monitor
and a window (or a file) and it should work.

Change-Id: I3db04f1fb11288f4a3288f4430e23704a71bdb3c
GitLab: #587
2023-02-21 15:59:14 -05:00
2f97d4edd9 LocationSharing: handle timers per conversation
Timers are now set per conversation to fit
the new design

Change-Id: I76411c68b12020ef18dc8f915bfb6cbefa8c5d7f
2023-02-21 15:36:09 -05:00
f6acfd3968 build.py: fix hooks installation with --init
+ add clang-format to client-qt/.git/hooks
+ only modify daemon and ignore other modules as not using gerrit.

Change-Id: Ib7f498d3a960da7ff739311409ad922c9976d5d7
2023-02-21 14:32:20 -05:00
07e7ae5310 misc: fix right click on self contact
Change-Id: I003bad0416c541e7e02f80d01734d71ccd453818
GitLab: #992
2023-02-21 13:56:19 -05:00
f95b0e2ed2 i18n: automatic bump
Change-Id: I948a6554fd972fb62f50499e7dadce943d6cef8f
2023-02-20 16:45:33 -05:00
3570b23d8a swarmdetailspanel: show kicked contacts if administrator
This patch avoid for non-admins to try to re-add kicked members
as filtered out from the list. However kicked members are only
visible for administrators.

Change-Id: Ie01b7071c072d147bbc0f39e477cc24d7fd58b1a
2023-02-20 09:05:24 -05:00
06ab19f213 Feature: search messages
Change-Id: Ia458e2e6ee183cad9d0418af0dbbbcd990f14281
GitLab: #918
2023-02-20 09:04:49 -05:00
c2d81149be chatview: hide the message bar scrollbars if there is no content
Gitlab: #978
Change-Id: Ifdc7306c6082c93f74fcb3e8472405d326faea74
2023-02-20 09:00:31 -05:00
ad7d8e136f callviewcontextmenu: cleanup
Change-Id: I76f77f7e5f7eb3e2c46e01f9cdd51b2d40af7739
GitLab: #975
2023-02-20 09:00:11 -05:00
5df521eb70 misc: fix plugin translation
Change-Id: Ia94e47c26ded5f3d7271c1d81253eca6d67001dd
2023-02-20 08:59:57 -05:00
cbdfe26dd1 callmodel: keep only one shared source in call
Change-Id: I561db4414c92419946cc1f7233979b1cf8841055
GitLab: #960
2023-02-20 08:59:47 -05:00
313b3bf2bd misc: open external link with reportbutton
Change-Id: I387dcb61393336e021227ada74a2b795d8ec15fa
GitLab: #980
2023-02-20 08:59:30 -05:00
1a9aa18680 sip: fix outgoing call messages
The author was empty instead of current uri

Change-Id: I4022c5e8bbbe4bd57c1a3fd7bc33ba8be6861bde
2023-02-17 16:40:05 -05:00
14ae000686 mainapp: dynamically load views
Introduces the ViewCoordinator component to promote dynamic view loading and reduce coupling between components.

The following objects are now created and destroyed as needed:
- SettingsView
- WizardView
- dialogs

Further refactoring will be required in order to do the same with the ConversationView, which now parents the ChatView and the CallStackView.

Gitlab: #897
Change-Id: Ice6a0c133e62e1e0c8d7fb99ec2c41234c049b59
2023-02-17 13:59:28 -05:00
52d3f4d92f gitignore: ignore git GUI .orig files
Change-Id: I21a716045be89eab83aeb64b200f396a32c509a6
2023-02-16 12:15:26 -05:00
8147baef2b fix: add default flag to sendAccountTextMessage
Change-Id: I08ef8b2f383c3aa1035518a2d4f92e941048e211
2023-02-16 09:40:27 -03:00
dfd1f6c78c MessageListView: wrong new message sequence
GitLab: #983

Change-Id: Ida7b6e84768aac69113af8d29b96a4627ae6c9f4
2023-02-15 11:06:28 -05:00
b568484453 fix: empty chatview
Bug:
Go to small size, open swarm details panel (it will take all width)
Then go to another conversation => No messages (need to re-click on swarm details panel).

Change-Id: I6b2d721e4b3645d60483ff1aca3cff24908cefb4
2023-02-15 06:44:03 -05:00
13f829d623 i18n: automatic bump
Change-Id: Ic3b5198be03e1eff04fdc16c3e88581cf4815beb
2023-02-13 16:45:19 -05:00
a0e2c4ac30 macOS: update connections when the system wakes up
Sometimes, it is not possible to place a call after the
system returns from sleep mode. This patch ensures
that the connectivity changed is called when the system
returns from sleep mode.
Change-Id: Id9f1331b89ae37a1244ea10a8c02282c4c8a35e5
2023-02-10 15:42:46 -05:00
010930febe misc: fix close file sharing
Change-Id: I9450db0658741059620c052e8ddf602976fc2983
GitLab: #968
2023-02-09 05:26:03 -05:00
48695d4672 misc: clean log warning
Change-Id: I0d546f676013e03f1b935279096b8829254e2ad7
2023-02-08 14:16:49 -05:00
94980cd3fc macOS: add ITSAppUsesNonExemptEncryption to plist
This is required to publish app in App Store.
ITSEncryptionExportComplianceCode will be set during
deployment.

Change-Id: If4f07c003c193b8dd1f08589c4cb3b04e671def3
2023-02-08 12:21:33 -05:00
6498dadd68 locationsharing: share button visibilty bug
binding of isSharingToCurrentConversation is now also done
when the webview is loaded (it was only done on conversationChange)

GitLab: #972

Change-Id: I5b767ed3f85334f97064112d125187b7093a1e26
2023-02-07 16:36:41 -05:00
049cb4583a SwarmDetailsPanel: contextMenu opens to wrong position
GitLab: #971

Change-Id: Id9c20660a57c677a137dbdaf54e8ee4b28eb3c02
2023-02-07 14:24:12 -05:00
e763f78866 i18n: automatic bump
Change-Id: I6e19d4b28ebb4ce0227ca8f886062e05755b317c
2023-02-06 17:08:46 -05:00
1d41dd427d avmodel: update renderer on queued thread
This avoid a double lock on SHM renderer and there is no need
for direct connection there.

Change-Id: I9cd4c862bbefd26ab01b3a685551ea95fad2c41e
2023-02-06 14:11:57 -05:00
2811d486e3 misc: fix multiple display sharing
Change-Id: Ida3bc1f9f49693715333736ac75adcfdc8f2b23a
GitLab: #965
2023-02-06 11:29:30 -05:00
08cb68366f avmodel.cpp: Segmentation fault error: mutex missing
Change-Id: Id0994bf32dccbc35422d8b96deeaeebebf8d61bc
2023-02-06 09:13:45 -05:00
2853d185b8 misc: bump daemon
Change-Id: I8a68eca0c384aaaef39b02d17c0c6970a795c8b0
2023-02-06 07:45:24 -05:00
24b761ae82 misc: Use 'Savoir-faire Linux Inc.' more consistently
Change-Id: Idc99880fedf8bb9f7a89b5b30c3f316dede89759
2023-02-06 01:52:34 -05:00
8d46acedf1 misc: Update copyright years to 2023
Change-Id: Idf38e82631a4e22540aa5dec8ec2db0ab4a38c2e
2023-02-06 01:47:15 -05:00
83bd5a0099 misc: bump daemon
Change-Id: I873b0a46b16b7e269882fa7b70966063047884bc
2023-02-05 16:38:13 -05:00
f1f6003048 swarmdetailspanel: add scrollbar to settings
Change-Id: I46e3ef0d00b3db97f4908d84e7b251ee67a861c7
2023-02-05 16:35:30 -05:00
fc0ee942df misc: fix link color
Change-Id: I7d59a8f1cfd01469463864905c3f2ad983afeb95
GitLab: #961
2023-02-05 16:35:30 -05:00
b2643f5967 messagelistmodel: correctly search for index in model
Iterate through CPP elements and use positionView(ListView.Center)
as other approach seems bugguy or slower.

Change-Id: I43879969ccb457166879a156efb482e77ff07d6b
2023-02-05 16:35:30 -05:00
977092171e callparticipantsmodel: fix participant equality
Else, changing the moderator state of a participant doesn't
refresh the controls

Change-Id: Ic00a7836b181bf9aa9c9d793720323bc2247196a
2023-02-05 16:35:30 -05:00
644550a302 chatviewfooter: fix focus on reply to
Change-Id: I3f26a4f38ae3e68e36c8121b33108363bbb06291
2023-02-05 16:35:30 -05:00
bcfc2ccf0e invitationview: sort per received timestamp
We sort the invites by last interactions. However on swarm, there
is no interaction yet. Add one with the received timestamp given
by the daemon.
(Regression appears because we were showing trust request before
not conversation requests)

Change-Id: Ic7f4d1a5d485325c95a19c2c38ae9c74630829ce
GitLab: #956
2023-02-05 16:35:30 -05:00
1a4fffffee ongoingcallpage: remove useless code
Calling a conference and stopping the call will lead the camera
opened. This code seems useless and bugguy.

Change-Id: Iff06b03838a2e13fe378f60f84df96ceb7735f1f
2023-02-05 16:35:30 -05:00
564581b1f7 contactmodel: use new avatar received for account
If the avatar for an account is set on a device, it will send
to detected devices on new connections. The client was ignoring
the new avatar if it was not empty, now we just use the last
received avatar

Change-Id: I0b2cde9c193d46014c4d600775743312219b84df
2023-02-05 16:35:30 -05:00
c8c8208378 chatview: do not show "A call is in progress" in a call
Change-Id: I6e04c8e01e87f66a9e6da4fb32524f085066a5d0
GitLab: #940
2023-02-05 16:35:30 -05:00
5db4d29b73 messageadapter: fix types filtering
Some types where missing, causing the chatview to not show all
messages.

Change-Id: I2ac1dfa03de8330b38f2828e66eead7114b2cfe6
2023-02-05 16:35:30 -05:00
88d6de8370 contactmessage: fix width for timestampinfo
If the timestamp is shown on a contact message, the line was not
taking the full width like other messages.

Change-Id: I94a448acb4f7fd6400365445dd912abc5103ea2a
2023-02-05 16:35:30 -05:00
9e84681856 emoji: fix background color
- isEmojiOnly changed to message containing only an emoji, not an edit or reply.
- adapted size

GitLab: #957

Change-Id: I78388a406a2a0b9c93f1c291850062fd9bf04a54
2023-02-05 11:04:19 -05:00
c0fdeb3f34 misc: improve minimum width swarm panels in chatview
GitLab: #954

Change-Id: I6fe7537b0de7fb904a05159072476003ee835eea
2023-02-03 13:50:40 -03:00
6348d3ee0b Smartlist: Date should show in correct locale format
- Standard time/date is now used
- If today, show local time, otherwise show local date

GitLab: #545
Change-Id: I07f1e706868c725d1c917c473dc0fdbad8d6810f
2023-02-03 09:06:27 -05:00
530c027068 projectcredits.html: contributor added
- Contributor added to credits

Change-Id: I27d459557c10e50c53b342472ed76c2c7966ff37
2023-02-03 09:05:35 -05:00
43c2197ef1 packaging: Update release tarball name and version scheme.
* extras/packaging/gnu-linux/scripts/release-version.sh: Add script
for deriving (reproducibly) a release version.  The format will follow
a 'YYYYMMDD.X' scheme, where 'YYYYMMDD' is the date of the last commit
on the current branch, and 'X' the number of releases tagged that day,
starting from zero.  Example: the first stable release with a newest
commit date of 2023-01-02 would have a version of '20230102.0', the
subsequent one '20230102.1', and so on.  This is derived by counting
the number of git tags with the prefix 'TYPE/YYYYMMDD', where 'TYPE'
is the release type: either 'stable', 'beta', or 'nightly'.
* extras/packaging/gnu-linux/Jenkinsfile: Call the above new script to
derive the release version to use for tagging.
* extras/packaging/gnu-linux/Makefile: Switch from the previous
'jami_YYYYMMDD.hhmm.COMMIT.tar.gz' tarball filename format to
'jami-YYYYMMDD.X.tar.gz'.  The new format is shorter, omits the
unnecessary and confusing commit id, and uses dash instead of
underscore.  Also, it contains everything in a top-level directory
with the same name as the tarball (without the .tar.gz extensions),
so that 'jami-YYYYMMDD.X.tar.gz' nicely extracts to 'jami-YYYYMMDD.X'.
With these changes, our release tarballs will follow more closely the
related instructions from the GNU maintainers manual:
https://www.gnu.org/prep/maintain/html_node/Distribution-tar-Files.html
Lastly, this change inadvertently 'fixes' a recent issue where the
'extras/ci/client-qt-gnulinux' subdirectory and its contents would be
moved to top-level in the tarball due to one of the tarball transforms
matching the 'client-qt' in the directory's name, replacing the
'extras/ci/client-qt' prefix with 'client-qt', thereby resulting in
'client-qt-gnulinux' being moved to the tarball's top-level.
* .gitignore: Ignore several packaging-related directories and files.
* extras/packaging/gnu-linux/rules/rpm/jami-daemon.spec:
* extras/packaging/gnu-linux/rules/rpm/jami-libclient.spec:
* extras/packaging/gnu-linux/rules/rpm/jami-qt.spec:
* extras/packaging/gnu-linux/rules/rpm/jami.spec: Update the expected
release tarball filename pattern in the 'Source' field.  Also replace
references to previous top-level directory name 'client-qt' with the
new one 'jami-%{version}' where needed.
* extras/packaging/gnu-linux/rules/rpm/jami-libqt.spec: Update the
'Source' field to follow new tarball name consistent with the main
Jami release tarball.
* extras/packaging/gnu-linux/scripts/build-package-rpm.sh: Update the
tarball top-level directory pattern for the new format, now passing
the --wildcards option to GNU Tar.  Also use a name for the jami-libqt
source tarball that is more consistent with the main Jami release
tarball.
* extras/packaging/gnu-linux/scripts/build-package-snap.sh: Update the
top-level directory pattern for the new format.
* extras/packaging/gnu-linux/tarballs.manifest: Drop file accidentally
checked into git.

Change-Id: I2695f560c0bc5e61fb99dc0244f8fbb8e7026a62
2023-02-03 08:59:33 -05:00
a791ab5a52 contextMenu: remove double separator
Change-Id: Ib11d464284effa5e78ca56441d0e535858071151
GitLab: #941
2023-02-03 08:45:15 -05:00
07c0f890da conversationmodel: get registered name for non contact members
Because in a swarm you can talk with non contacts, we should at
least retrieve the username when possible.

Change-Id: Ie01cd10cc1231fc4024bd5a08c30c08d69e8e7f0
GitLab: #948
2023-02-03 08:44:57 -05:00
ae0895fbfd photoboothview: do not show edit button in read only
Change-Id: I9eb8843d50fdeb914eae622c15555b366d246094
2023-02-03 08:44:37 -05:00
bb9b50ef99 messaging: revert to using QSortFilterProxyModel for the message list
SFPM performs poorly compared to its C++ counterpart in cases where re-filtering often is required. Tests show SFPM taking roughly 10x that of QSFPM in certain cases when the entire conversation needs to be loaded.

Change-Id: I25792f0ab376ae11d42073a548934b743e59fa3e
2023-02-02 12:13:40 -05:00
640b353703 chatview: re-show video and audio components
Change-Id: I6c36ab045667d01859a72dfec12e3e02130c57fe
GitLab: #947
2023-02-02 09:30:43 -05:00
feb53e6183 issue: Maximize and then Restore Select a screen to share window
Change-Id: I6ef8069de9012e235fe6f8907b9d2bb94a44cd40
GitLab: #634
2023-02-02 09:30:12 -05:00
b34f031251 contactmodel: keep repsence state after subscription
Change-Id: I3501d0ba072bc68685af8ba8c46c22979cc25493
2023-02-01 16:54:42 -05:00
92ab8951d2 call: fix recording state
Change-Id: I3fcb60aed90e3a7cf7edee7f8ac28c204dbb8952
2023-02-01 15:51:36 -05:00
710 changed files with 138442 additions and 124111 deletions

9
.gitignore vendored
View File

@ -25,7 +25,7 @@ install/
*.vcxproj.filters
*qmlcache.qrc
.deploy.stamp
*.orig
*.log
*.pid
@ -36,3 +36,10 @@ src/app/constant/JamiResources.qml
# macOS
.DS_Store
# packaging
.tarball-version
tarballs.manifest
jami-*.tar.gz
extras/packaging/gnu-linux/packages/
.docker-image-*

4
.gitmodules vendored
View File

@ -2,6 +2,10 @@
path = 3rdparty/qrencode-win32
url = https://github.com/BlueDragon747/qrencode-win32.git
ignore = dirty
[submodule "3rdparty/libqrencode"]
url = https://github.com/fukuchi/libqrencode.git
ignore = dirty
path = 3rdparty/libqrencode
[submodule "3rdparty/SortFilterProxyModel"]
path = 3rdparty/SortFilterProxyModel
url = https://github.com/atraczyk/SortFilterProxyModel.git

1
3rdparty/libqrencode vendored Submodule

Submodule 3rdparty/libqrencode added at 715e29fd4c

View File

@ -1,4 +1,4 @@
# Copyright (C) 2020-2022 Savoir-faire Linux Inc.
# Copyright (C) 2020-2023 Savoir-faire Linux Inc.
#
# Author: Albert Babí <albert.babi@savoirfairelinux.com>
# Author: Amin Bandali <amin.bandali@savoirfairelinux.com>
@ -158,17 +158,6 @@ execute_process(
WORKING_DIRECTORY ${APP_SRC_DIR})
set(QML_RESOURCES ${APP_SRC_DIR}/resources.qrc)
if (APPLE)
include(FetchContent)
FetchContent_Declare(
libqrencode
GIT_REPOSITORY https://github.com/fukuchi/libqrencode.git
GIT_TAG v4.1.1)
FetchContent_Populate(libqrencode)
add_subdirectory(${libqrencode_SOURCE_DIR} ${libqrencode_BINARY_DIR})
include_directories(${libqrencode_SOURCE_DIR})
endif()
# library compatibility (boost, libnotify, etc.)
add_definitions(-DQT_NO_KEYWORDS)
@ -215,6 +204,7 @@ set(COMMON_SOURCES
${APP_SRC_DIR}/wizardviewstepmodel.cpp
${APP_SRC_DIR}/avatarregistry.cpp
${APP_SRC_DIR}/currentconversation.cpp
${APP_SRC_DIR}/currentconversationmembers.cpp
${APP_SRC_DIR}/currentaccount.cpp
${APP_SRC_DIR}/videodevices.cpp
${APP_SRC_DIR}/videoprovider.cpp
@ -275,6 +265,7 @@ set(COMMON_HEADERS
${APP_SRC_DIR}/wizardviewstepmodel.h
${APP_SRC_DIR}/avatarregistry.h
${APP_SRC_DIR}/currentconversation.h
${APP_SRC_DIR}/currentconversationmembers.h
${APP_SRC_DIR}/currentaccount.h
${APP_SRC_DIR}/videodevices.h
${APP_SRC_DIR}/videoprovider.h
@ -297,6 +288,7 @@ set(LIBJAMI_CONTRIB_DIR "${DAEMON_DIR}/contrib")
find_path(AVUTIL_INCLUDE_DIR libavutil/avutil.h
PATHS
${LIBJAMI_CONTRIB_DIR}/native/ffmpeg
${LIBJAMI_CONTRIB_DIR}/apple-darwin/include/
${LIBJAMI_CONTRIB_DIR}/build/ffmpeg/Build/win32/x64/include)
include_directories(${AVUTIL_INCLUDE_DIR})
@ -441,6 +433,8 @@ else() # APPLE
${myApp_ICON}
PROPERTIES
MACOSX_PACKAGE_LOCATION Resources)
INCLUDE_DIRECTORIES(${PROJECT_SOURCE_DIR}/3rdparty/libqrencode/include)
LINK_DIRECTORIES(${PROJECT_SOURCE_DIR}/3rdparty/libqrencode/lib)
if(ENABLE_SPARKLE)
message("Sparkle auto-update enabled")
set(sparkle_dir "${PACKAGING_DIR}/update/sparkle")
@ -721,6 +715,19 @@ else()
endif(ENABLE_SPARKLE)
target_sources(${PROJECT_NAME} PRIVATE ${resources})
target_link_libraries(${PROJECT_NAME} PRIVATE ${libs})
FILE(GLOB CONTRIB ${LIBJAMI_CONTRIB_DIR}/apple-darwin/lib/*.a)
target_link_libraries(${PROJECT_NAME} PRIVATE ${CONTRIB})
find_package(Iconv REQUIRED)
target_link_libraries(${PROJECT_NAME} PRIVATE Iconv::Iconv)
target_link_libraries(${PROJECT_NAME} PRIVATE
"-framework AVFoundation"
"-framework CoreAudio -framework CoreMedia -framework CoreVideo"
"-framework VideoToolbox -framework AudioUnit"
"-framework Security"
compression
resolv
)
# translations
if(Qt${QT_VERSION_MAJOR}LinguistTools_FOUND)

View File

@ -85,10 +85,10 @@ specify its path using the `--qt` flag, e.g.
`./build.py --install --qt=/home/<username>/Qt/6.2.1/gcc_64`.
Now you will have the daemon in `daemon/bin/jamid` and the client in
`build/bin/jami`. You can now run Jami using
`build/jami`. You can now run Jami using:
```bash
./build.py --run
./build/jami
```
Notes:

View File

@ -38,7 +38,7 @@ cf [INSTALL.md](/INSTALL.md)
# License
Copyright (C) 2020-2022 Savoir-faire Linux Inc.
Copyright (C) 2020-2023 Savoir-faire Linux Inc.
Jami is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 3 of the License, or (at your option) any later version.

View File

@ -1,7 +1,7 @@
#!/usr/bin/env python3
# build.py --- Convenience script for building and running Jami
# Copyright (C) 2016-2022 Savoir-faire Linux Inc.
# Copyright (C) 2016-2023 Savoir-faire Linux Inc.
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
@ -303,32 +303,17 @@ def run_dependencies(args):
def run_init():
# Extract modules path from '.gitmodules' file
module_names = []
with open('.gitmodules') as fd:
for line in fd.readlines():
if line.startswith('[submodule "'):
module_names.append(line[line.find('"')+1:line.rfind('"')])
subprocess.run(["git", "submodule", "update", "--init"],
check=True)
subprocess.run(["git", "submodule", "update", "--init"], check=True)
subprocess.run(["git", "submodule", "foreach",
"git checkout master && git pull"], check=True)
for name in module_names:
hooks_dir = f'.git/modules/{name}/hooks'
hooks_directories = ['.git/hooks/', f'.git/modules/daemon/hooks']
for hooks_dir in hooks_directories:
if not os.path.exists(hooks_dir):
os.makedirs(hooks_dir)
copy_file("./extras/scripts/commit-msg", f'{hooks_dir}/commit-msg')
module_names_to_format = ['daemon']
for name in module_names_to_format:
hooks_dir = f'.git/modules/{name}/hooks'
copy_file("./extras/scripts/commit-msg", hooks_dir + "/commit-msg")
execute_script(['./extras/scripts/format.sh --install %(path)s'],
{"path": hooks_dir})
subprocess.run(["git", "submodule", "update", "--recursive", "--init"],
check=True)
def copy_file(src, dest):
print(f'Copying: {src} to {dest}')
@ -382,6 +367,8 @@ def run_install(args):
install_args.append('-W')
if args.no_webengine:
install_args.append('-w')
if args.arch:
install_args += ('-a', args.arch)
if args.distribution == OSX_DISTRIBUTION_NAME:
# The `universal_newlines` parameter has been renamed to `text` in
@ -419,11 +406,9 @@ def run_install(args):
print('info: consider setting the TARBALLS environment variable '
'to a stable writable location to avoid loosing '
'cached tarballs')
# Note: we must expose /gnu/store because /etc/ssl/certs
# contains certs that are symlinks to store items.
command = ['guix', 'shell', '--manifest=guix/manifest.scm',
'--expose=/gnu/store', '--expose=/etc/ssl/certs',
'--expose=/usr/bin/env',
'--symlink=/usr/bin/env=bin/env',
'--symlink=/etc/ssl/certs=etc/ssl/certs',
'--container', '--network'] + share_tarballs_args \
+ ['--'] + command
@ -612,6 +597,7 @@ def parse_args():
ap.add_argument('--no-webengine', dest='no_webengine',
default=False, action='store_true',
help='Do not use Qt WebEngine.')
ap.add_argument('--arch')
dist = choose_distribution()

2
daemon

Submodule daemon updated: 5e35e71d09...49e70f07d5

View File

@ -1,7 +1,7 @@
# Taken from:
# https://cmake.org/Wiki/CMake_FAQ#Can_I_do_.22make_uninstall.22_with_CMake.3F
#
# Copyright (C) 2021-2022 Savoir-faire Linux Inc.
# Copyright (C) 2021-2023 Savoir-faire Linux Inc.
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by

View File

@ -1,4 +1,4 @@
# Copyright (C) 2015-2022 Savoir-faire Linux Inc.
# Copyright (C) 2015-2023 Savoir-faire Linux Inc.
#
# Author: Alexandre Lision <alexandre.lision@savoirfairelinux.com>
# Author: Emmanuel Lepage Vallee <emmanuel.lepage@savoirfairelinux.com>
@ -39,6 +39,8 @@ else()
set(LIBJAMI_INCLUDE_DIRS ${RING_BUILD_DIR}/jami)
elseif(EXISTS ${CMAKE_INSTALL_PREFIX}/include/jami/jami.h)
set(LIBJAMI_INCLUDE_DIRS ${CMAKE_INSTALL_PREFIX}/include/jami)
elseif(EXISTS ${CMAKE_INSTALL_PREFIX}/daemon/include/jami/jami.h)
set(LIBJAMI_INCLUDE_DIRS ${CMAKE_INSTALL_PREFIX}/daemon/include/jami)
else()
message(STATUS "Jami daemon headers not found!
Set -DLIBJAMI_BUILD_DIR or -DCMAKE_INSTALL_PREFIX")
@ -55,6 +57,7 @@ if(WITH_DAEMON_SUBMODULE)
find_library(LIBJAMI_LIB NAMES jami ring
PATHS ${DAEMON_DIR}/src/.libs
PATHS ${CMAKE_INSTALL_PREFIX}/lib
PATHS ${CMAKE_INSTALL_PREFIX}/daemon/lib
PATHS ${CMAKE_INSTALL_PREFIX}/libexec
PATHS ${CMAKE_INSTALL_PREFIX}/bin
NO_DEFAULT_PATH)
@ -64,6 +67,7 @@ else()
PATHS ${LIBJAMI_BUILD_DIR}/.libs
PATHS ${RING_BUILD_DIR}/.libs
PATHS ${CMAKE_INSTALL_PREFIX}/lib
PATHS ${CMAKE_INSTALL_PREFIX}/daemon/lib
PATHS ${CMAKE_INSTALL_PREFIX}/libexec
PATHS ${CMAKE_INSTALL_PREFIX}/bin
NO_DEFAULT_PATH)
@ -83,6 +87,7 @@ if(NOT LIBJAMI_LIB)
PATHS ${DAEMON_DIR}/src/.libs
PATHS ${CMAKE_INSTALL_PREFIX}
PATHS ${CMAKE_INSTALL_PREFIX}/lib
PATHS ${CMAKE_INSTALL_PREFIX}/daemon/lib
PATHS ${CMAKE_INSTALL_PREFIX}/libexec
NO_DEFAULT_PATH)
else()
@ -92,6 +97,7 @@ if(NOT LIBJAMI_LIB)
PATHS ${RING_BUILD_DIR}/.libs
PATHS ${CMAKE_INSTALL_PREFIX}
PATHS ${CMAKE_INSTALL_PREFIX}/lib
PATHS ${CMAKE_INSTALL_PREFIX}/daemon/lib
PATHS ${CMAKE_INSTALL_PREFIX}/libexec
NO_DEFAULT_PATH)

View File

@ -1,5 +1,5 @@
/*
* Copyright (C) 2022 Savoir-faire Linux Inc.
* Copyright (C) 2022-2023 Savoir-faire Linux Inc.
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU Affero General Public License as

View File

@ -1,5 +1,5 @@
<?xml version="1.0" encoding="UTF-8"?>
<!-- Copyright (C) 2015-2022 Savoir-faire Linux Inc. -->
<!-- Copyright (C) 2015-2023 Savoir-faire Linux Inc. -->
<component type="desktop-application">
<id>net.jami.Jami</id>
<metadata_license>CC-BY-SA-3.0</metadata_license>

View File

@ -1,4 +1,4 @@
// Copyright (C) 2021-2022 Savoir-faire Linux Inc.
// Copyright (C) 2021-2023 Savoir-faire Linux Inc.
//
// Author: Maxim Cournoyer <maxim.cournoyer@savoirfairelinux.com>
//
@ -32,7 +32,10 @@
// - Allow publishing from any node, to avoid relying on a single machine.
// Configuration globals.
def SUBMODULES = ['daemon', '3rdparty/SortFilterProxyModel', '3rdparty/qrencode-win32', 'extras/packaging/update/sparkle/Sparkle']
def SUBMODULES = ['daemon',
'3rdparty/SortFilterProxyModel',
'3rdparty/qrencode-win32',
'extras/packaging/update/sparkle/Sparkle']
def TARGETS = [:]
def REMOTE_HOST = env.SSH_HOST_DL_RING_CX
def REMOTE_BASE_DIR = '/srv/repository/ring'
@ -43,6 +46,7 @@ def GIT_PUSH_URL = 'ssh://jenkins@review.jami.net:29420/jami-client-qt'
def JENKINS_SSH_KEY = '35cefd32-dd99-41b0-8312-0b386df306ff'
def DL_SSH_KEY = '5825b39b-dfc6-435f-918e-12acc1f56221'
def SNAPCRAFT_KEY = '106e398c-43ca-41c0-8f7e-4f45030f8bdd'
def PACKAGING_DIR = 'extras/packaging/gnu-linux'
pipeline {
agent {
@ -70,14 +74,13 @@ pipeline {
booleanParam(name: 'BUILD_ARM',
defaultValue: false,
description: 'Whether to build ARM packages.')
booleanParam(name: 'BUILD_DEB_PACK',
defaultValue: false,
description: 'Whether to build DEB PACK packages.')
string(name: 'PACKAGING_TARGETS',
defaultValue: '',
description: 'A whitespace-separated list of packaging ' +
'targets, e.g. "debian_10 snap". ' +
'When left unspecified, all the packaging targets are built.')
'targets, e.g. "debian_10 deb-pack-x86-64 rpm-pack-x86-64 snap". ' +
'When left unspecified, all the packaging targets are built. ' +
'To see the available targets, run: ' +
'make -f extras/packaging/gnu-linux/Makefile list-package-targets')
}
environment {
@ -122,7 +125,7 @@ See https://wiki.savoirfairelinux.com/wiki/Jenkins.jami.net#Configuration_client
steps {
sh """\
#!/usr/bin/env -S bash -l
make -f extras/packaging/gnu-linux/Makefile portable-release-tarball .tarball-version
make -f ${PACKAGING_DIR}/Makefile portable-release-tarball .tarball-version
"""
stash(includes: '*.tar.gz, .tarball-version',
name: 'release-tarball')
@ -140,22 +143,21 @@ make -f extras/packaging/gnu-linux/Makefile portable-release-tarball .tarball-ve
sshagent(credentials: [JENKINS_SSH_KEY, DL_SSH_KEY]) {
echo "Publishing to git repository..."
script {
def wantedTag = sh (
script: "echo ${params.CHANNEL}/\$(date +\"%Y%m%d\")",
def wantedTag = "${params.CHANNEL}/" + sh (
script: "${PACKAGING_DIR}/scripts/release-version.sh" +
" ${params.CHANNEL}",
returnStdout: true
).trim()
sh """
git tag -am \"Jami new ${params.CHANNEL} version\" ${wantedTag}
"""
sh "git tag -am \"Jami new ${params.CHANNEL} version\"" +
" ${wantedTag}"
sh "git push origin --tags"
if (params.CHANNEL == 'stable') {
// Only stables releases get tarballs and a tag.
sh "git push origin --tags"
// Only stable releases get a source
// tarball.
echo "Publishing release tarball..."
sh 'rsync --verbose jami*.tar.gz ' +
"${REMOTE_HOST}:${REMOTE_BASE_DIR}" +
"/release/tarballs/"
} else {
sh "git push origin --tags"
}
}
}
@ -170,17 +172,16 @@ make -f extras/packaging/gnu-linux/Makefile portable-release-tarball .tarball-ve
script {
def targetsText = params.PACKAGING_TARGETS.trim()
if (!targetsText) {
targetsText = sh(script: 'make -f extras/packaging/gnu-linux/Makefile -s list-package-targets',
returnStdout: true).trim()
targetsText = sh(
script: "make -f ${PACKAGING_DIR}/Makefile" +
' -s list-package-targets',
returnStdout: true).trim()
}
TARGETS = targetsText.split(/\s/)
if (!params.BUILD_ARM) {
TARGETS = TARGETS.findAll { !(it =~ /_(armhf|arm64)$/) }
}
if (!params.BUILD_DEB_PACK) {
TARGETS = TARGETS.findAll { !(it =~ /_(deb-pack)$/) }
}
def stages = [:]
@ -199,9 +200,9 @@ make -f extras/packaging/gnu-linux/Makefile portable-release-tarball .tarball-ve
echo Building on node \$NODE_NAME
whoami
tar xf *.tar.gz --strip-components=1
make -f extras/packaging/gnu-linux/Makefile ${target}
make -f ${PACKAGING_DIR}/Makefile ${target}
"""
stash(includes: 'extras/packaging/gnu-linux/packages/**',
stash(includes: "${PACKAGING_DIR}/packages/**",
name: target)
}
}
@ -236,15 +237,18 @@ make -f extras/packaging/gnu-linux/Makefile portable-release-tarball .tarball-ve
}
def distributionsText = sh(
script: 'find extras/packaging/gnu-linux/packages/* -maxdepth 1 -type d -print0 ' +
script: "find ${PACKAGING_DIR}/packages/* " +
'-maxdepth 1 -type d -print0 ' +
'| xargs -0 -n1 basename -z',
returnStdout: true).trim()
def distributions = distributionsText.split("\0")
distributions.each { distribution ->
echo "Deploying ${distribution} packages..."
withCredentials([string(credentialsId: SNAPCRAFT_KEY, variable: 'SNAPCRAFT_STORE_CREDENTIALS')]) {
sh """extras/packaging/gnu-linux/scripts/deploy-packages.sh \
withCredentials(
[string(credentialsId: SNAPCRAFT_KEY,
variable: 'SNAPCRAFT_STORE_CREDENTIALS')]) {
sh """${PACKAGING_DIR}/scripts/deploy-packages.sh \
--distribution=${distribution} \
--keyid="${JAMI_PUBLIC_KEY_FINGERPRINT}" \
--remote-repository-location="${REMOTE_HOST}:${REMOTE_BASE_DIR}/${params.CHANNEL}" \

View File

@ -1,5 +1,5 @@
# -*- mode: makefile; -*-
# Copyright (C) 2016-2021 Savoir-faire Linux Inc.
# Copyright (C) 2016-2023 Savoir-faire Linux Inc.
#
# Author: Maxim Cournoyer <maxim.cournoyer@savoirfairelinux.com>
#
@ -27,17 +27,17 @@ export TARBALLS ?= /var/cache/jami
TARBALL_VERSION := $(shell cat $(CURDIR)/.tarball-version 2> /dev/null)
ifeq ($(TARBALL_VERSION),)
LAST_COMMIT_DATE := $(shell git log -1 --format=%cd --date=format:'%Y%m%d.%H%M')
COMMIT_ID := $(shell git rev-parse --short HEAD)
RELEASE_VERSION := $(LAST_COMMIT_DATE).$(COMMIT_ID)
RELEASE_VERSION := $(shell ./extras/packaging/gnu-linux/scripts/release-version.sh)
else
$(warning Using version from the .tarball-version file: $(TARBALL_VERSION))
RELEASE_VERSION := $(TARBALL_VERSION)
endif
RELEASE_TARBALL_FILENAME := jami_$(RELEASE_VERSION).tar.gz
RELEASE_DIRNAME := jami-$(RELEASE_VERSION)
RELEASE_TARBALL_FILENAME := $(RELEASE_DIRNAME).tar.gz
# Export for consumption in child processes.
export RELEASE_VERSION
export RELEASE_DIRNAME
export RELEASE_TARBALL_FILENAME
# Debian versions
@ -57,8 +57,8 @@ QT_JAMI_PREFIX := /usr/lib/libqt-jami
## Other variables ##
#####################
TMPDIR := $(shell mktemp -d)
CURRENT_UID:=$(shell id -u)
CURRENT_GID:=$(shell id -g)
CURRENT_UID := $(shell id -u)
CURRENT_GID := $(shell id -g)
#############################
## Release tarball targets ##
@ -78,7 +78,7 @@ TAR_REPRODUCIBILITY_OPTIONS = \
echo $(RELEASE_VERSION) > $@
purge-release-tarballs:
rm -f jami_*.tar.* tarballs.manifest
rm -f jami-*.tar.* tarballs.manifest
release-tarball:
rm -f "$(RELEASE_TARBALL_FILENAME)" tarballs.manifest
@ -98,9 +98,9 @@ guix-share-tarball-arg = $${TARBALLS:+"--share=$$TARBALLS"}
portable-release-tarball: has-guix-p
guix shell --container --network \
--preserve=TARBALLS $(guix-share-tarball-arg) \
--expose=/usr/bin/env \
--expose=$$SSL_CERT_DIR=/etc/ssl/certs \
--manifest=$(CURDIR)/extras/packaging/gnu-linux/guix/minimal-manifest.scm \
--symlink=/usr/bin/env=bin/env \
--symlink=/etc/ssl/certs=etc/ssl/certs \
--manifest=extras/packaging/gnu-linux/guix/minimal-manifest.scm \
-- $(MAKE) -f extras/packaging/gnu-linux/Makefile release-tarball
daemon/contrib/native/Makefile:
@ -123,27 +123,27 @@ ifeq ($(TARBALL_VERSION),)
$(RELEASE_TARBALL_FILENAME): tarballs.manifest
# Prepare the sources of the top repository and relevant submodules.
rm -f "$@"
mkdir $(TMPDIR)/client-qt
git archive HEAD | tar xf - -C $(TMPDIR)/client-qt
mkdir $(TMPDIR)/$(RELEASE_DIRNAME)
git archive HEAD | tar xf - -C $(TMPDIR)/$(RELEASE_DIRNAME)
for m in \
./daemon \
. \
./3rdparty/SortFilterProxyModel; do \
(cd "$$m" && git archive --prefix "$$m/" HEAD \
| tar xf - -C $(TMPDIR)/client-qt); \
| tar xf - -C $(TMPDIR)/$(RELEASE_DIRNAME)); \
done
# Create the base archive.
tar -cf $(TMPDIR)/client-qt.tar $(TMPDIR)/client-qt \
--transform 's,.*/client-qt,client-qt,' \
tar -cf $(TMPDIR)/$(RELEASE_DIRNAME).tar $(TMPDIR)/$(RELEASE_DIRNAME) \
--transform "s,.*/$(RELEASE_DIRNAME),$(RELEASE_DIRNAME)," \
$(TAR_REPRODUCIBILITY_OPTIONS)
# Append the cached tarballs listed in the manifest.
tar --append --file $(TMPDIR)/client-qt.tar \
tar --append --file $(TMPDIR)/$(RELEASE_DIRNAME).tar \
--files-from $< \
--transform 's,^.*/,client-qt/daemon/contrib/tarballs/,' \
$(TAR_REPRODUCIBILITY_OPTIONS)
--transform "s,^.*/,$(RELEASE_DIRNAME)/daemon/contrib/tarballs/," \
$(TAR_REPRODUCIBILITY_OPTIONS)
# Compress the tarball and move it into place.
gzip --no-name $(TMPDIR)/client-qt.tar
mv $(TMPDIR)/client-qt.tar.gz "$@"
gzip --no-name $(TMPDIR)/$(RELEASE_DIRNAME).tar
mv $(TMPDIR)/$(RELEASE_DIRNAME).tar.gz "$@"
rm -rf $(TMPDIR)
else
# If TARBALL_VERSION is defined, assume it's already been generated,
@ -189,6 +189,7 @@ $(1)-docker-image-file := .docker-image-$$($(1)-docker-image-name)
$(1)-docker-run-command := docker run \
--rm --privileged --security-opt apparmor=docker-default \
-e RELEASE_VERSION="$(RELEASE_VERSION)" \
-e RELEASE_DIRNAME="$(RELEASE_DIRNAME)" \
-e RELEASE_TARBALL_FILENAME="$(RELEASE_TARBALL_FILENAME)" \
-e DEBIAN_VERSION="$(DEBIAN_VERSION)" \
-e DEBIAN_QT_VERSION="$(DEBIAN_QT_VERSION)" \
@ -238,42 +239,45 @@ $(foreach target,$(DISTRIBUTIONS),\
# Guix-generated Debian packages (deb packs) targets.
#
SUPPORTED_GNU_ARCHS = x86_64
DEB_PACK_TARGETS =
GUIX_PACK_FORMATS = deb rpm
# TODO: Add a postin script for the RPM pack.
# Arg1: the 'guix pack' format to use, e.g. 'deb' or 'rpm'.
define guix-pack-command
guix pack -C xz -f deb -m $(CURDIR)/extras/packaging/gnu-linux/guix/guix-pack-manifest.scm -v3 \
guix pack -C xz -f $(1) -m $(CURDIR)/extras/packaging/gnu-linux/guix/guix-pack-manifest.scm -v3 \
-S /usr/bin/jami=bin/jami \
-S /usr/share/applications/jami.desktop=share/applications/jami.desktop \
-S /usr/share/icons/hicolor/scalable/apps/jami.svg=share/icons/hicolor/scalable/apps/jami.svg \
-S /usr/share/icons/hicolor/48x48/apps/jami.png=share/icons/hicolor/48x48/apps/jami.png \
-S /usr/share/metainfo/jami.appdata.xml=share/metainfo/jami.appdata.xml \
--postinst-file=$(CURDIR)/extras/packaging/gnu-linux/guix/guix-pack-deb.postinst
$(and $(findstring deb,$(1)), \
--postinst-file=$(CURDIR)/extras/packaging/gnu-linux/guix/guix-pack-deb.postinst)
endef
# Arg1: the GNU architecture type (e.g., x86_64, i686, powerpcle, etc.)
define define-deb-pack-rule
deb-file-name := extras/packaging/gnu-linux/packages/guix-deb-pack/jami-$(RELEASE_VERSION)-$(1).deb
DEB_PACK_TARGETS += deb-pack-$(subst _,-,$(1))
.PHONY: deb-pack-$(subst _,-,$(1))
deb-pack-$(subst _,-,$(1)): $$(deb-file-name)
$$(deb-file-name): has-guix-p $(RELEASE_TARBALL_FILENAME)
output=$$$$($(guix-pack-command) --system=$(1)-linux $$(GUIX_PACK_ARGS)) && \
# Arg1: the 'guix pack' format to use, e.g. 'deb' or 'rpm'.
# Arg2: the GNU architecture type (e.g., x86_64, i686, powerpcle, etc.)
define define-guix-pack-rule
$(1)-file-name := extras/packaging/gnu-linux/packages/guix-$(1)-pack/jami-$(RELEASE_VERSION)-$(2).$(1)
PACKAGE-TARGETS += $(1)-pack-$(subst _,-,$(2))
.PHONY: $(1)-pack-$(subst _,-,$(2))
$(1)-pack-$(subst _,-,$(2)): $$($(1)-file-name)
$$($(1)-file-name): has-guix-p $(RELEASE_TARBALL_FILENAME)
output=$$$$($(call guix-pack-command,$(1)) --system=$(2)-linux $$(GUIX_PACK_ARGS)) && \
mkdir -p "$$$$(dirname "$$@")" && \
cp --reflink=auto "$$$$output" "$$@" && \
guix gc --delete "$$$$output"
chmod +w "$$@"
endef
$(foreach arch,$(SUPPORTED_GNU_ARCHS),\
$(eval $(call define-deb-pack-rule,$(arch))))
PACKAGE-TARGETS += $(DEB_PACK_TARGETS)
$(foreach format,$(GUIX_PACK_FORMATS),\
$(foreach arch,$(SUPPORTED_GNU_ARCHS),\
$(eval $(call define-guix-pack-rule,$(format),$(arch)))))
package-all: $(PACKAGE-TARGETS)
.PHONY: list-package-targets
list-package-targets:
@$(foreach p,$(PACKAGE-TARGETS),\
@$(foreach p,$(sort $(PACKAGE-TARGETS)),\
echo $(p);)
###################
@ -296,8 +300,7 @@ env:
clean:
rm -rf env
rm -rf docs/build
rm -f jami_*.tar.gz
rm -f jami-*.tar.gz
rm -rf extras/packaging/gnu-linux/packages
rm -f Makefile.packaging.distro_targets
rm -f .docker-image-*
rm -rf client-qt/daemon/contrib/tarballs/*
rm -rf daemon/contrib/tarballs/*

View File

@ -96,7 +96,8 @@ RUN dnf install -y \
libxshmfence-devel \
ninja-build \
clang \
cmake
cmake \
fmt-devel
ADD extras/packaging/gnu-linux/scripts/build-package-rpm.sh /opt/build-package-rpm.sh

View File

@ -96,7 +96,8 @@ RUN dnf install -y \
libxshmfence-devel \
ninja-build \
clang \
cmake
cmake \
fmt-devel
ADD extras/packaging/gnu-linux/scripts/build-package-rpm.sh /opt/build-package-rpm.sh

View File

@ -2,4 +2,4 @@
(list (channel
(inherit %default-guix-channel)
(commit
"f5cc7d03a778f20e2ad487e2c17cc8853bc871f0"))) ;2022-08-01
"fbbbc2088ce933d83f5b0be75308fdcb6b40fa57"))) ;2023-02-21

View File

@ -1,5 +1,5 @@
#!/bin/sh
# Copyright (C) 2021 Savoir-faire Linux Inc.
# Copyright (C) 2021-2023 Savoir-faire Linux Inc.
#
# Author: Maxim Cournoyer <maxim.cournoyer@savoirfairelinux.com>
#

View File

@ -1,4 +1,4 @@
;;; Copyright (C) 2021 Savoir-faire Linux Inc.
;;; Copyright (C) 2021-2023 Savoir-faire Linux Inc.
;;;
;;; Author: Maxim Cournoyer <maxim.cournoyer@savoirfairelinux.com>
;;;
@ -18,9 +18,9 @@
;;; This GNU Guix manifest is used along the Makefile to build the
;;; latest Jami as a Guix pack.
(use-modules (gnu packages certs)
(use-modules (gnu packages)
(gnu packages certs)
(gnu packages jami)
(gnu packages python)
(guix base32)
(guix gexp)
(guix packages)
@ -28,14 +28,14 @@
(guix store)
(guix utils))
;;; XXX: Below is a rather strenuous way to specify something that
;;; would have been nicer if it could have been specified via:
;;; Rather than using something like in the Makefile:
;;;
;;; --with-source=libjami=$(RELEASE_TARBALL_FILENAME) \
;;; --with-source=jami=$(RELEASE_TARBALL_FILENAME) in the Makefile.
;;; --with-source=jami=$(RELEASE_TARBALL_FILENAME)
;;;
;;; The above doesn't currently rewrite the dependency graph
;;; recursively, hence why it is not sufficient.
;;; the transformations must be made in this manifest file, because
;;; packages from manifest are not affected by input rewriting
;;; options, by design (see: https://issues.guix.gnu.org/61676).
(define %release-version (getenv "RELEASE_VERSION"))
@ -63,12 +63,30 @@
(uri %release-file-name)
(sha256 %release-file-hash)))
;;; 'with-source' cannot currently be combined with 'with-patch' (see:
;;; https://issues.guix.gnu.org/61684).
(define (with-latest-sources name)
(options->transformation
`((with-source . ,(format #f "~a@~a=~a" name
%release-version %release-file-name)))))
%release-version %release-file-name))
;; XXX: This is not effective, due to the above bug.
,@(if (string=? name "libjami")
`((with-patch . ,(string-append
name "="
(search-patch
"jami-disable-integration-tests.patch"))))
'()))))
(define libjami/latest ((with-latest-sources "libjami") libjami))
(define libjami/latest
((with-latest-sources "libjami")
(package
(inherit libjami)
;; FIXME: Disable test suite until #61684 above is fixed or the
;; 'jami-disable-integration-tests.patch' merged (also see:
;; https://git.jami.net/savoirfairelinux/jami-daemon/-/issues/824).
(arguments (substitute-keyword-arguments (package-arguments libjami)
((#:tests? _ #t)
#f))))))
(define with-libjami/latest
(package-input-rewriting `((,libjami . ,libjami/latest))))
@ -82,6 +100,13 @@
(append nss-certs)))
(arguments
(substitute-keyword-arguments (package-arguments jami)
;; This is necessary due to the missing
;; jami-libjami-headers-search.patch patch.
((#:configure-flags flags '())
#~(cons (string-append "-DLIBJAMI_INCLUDE_DIR="
#$(this-package-input "libjami")
"/include/jami")
#$flags))
((#:phases phases '%standard-phases)
#~(modify-phases #$phases
(add-after 'qt-wrap 'wrap-ssl-cert-dir
@ -93,6 +118,6 @@
exec-line)))))))))))
(define jami-with-certs/latest
((with-latest-sources "jami") jami-with-certs))
(with-libjami/latest ((with-latest-sources "jami") jami-with-certs)))
(packages->manifest (list jami-with-certs/latest))

View File

@ -1,9 +1,9 @@
Format: https://www.debian.org/doc/packaging-manuals/copyright-format/1.0/
Upstream-Name: jami
Upstream-Contact: Alexandre Viau <alexandre.viau@savoirfairelinux.net>
Upstream-Contact: Amin Bandali <bandali@gnu.org>
Source: https://dl.jami.net/release/tarballs/
Files: *
Copyright: 2004-2021 Savoir-faire Linux Inc.
Copyright: 2004-2023 Savoir-faire Linux Inc.
License: GPL-3+
Comment: Upstream embeds everything that is needed to build Jami inside the release tarball.
Everything that is already in Debian has been removed.
@ -50,7 +50,7 @@ Files: daemon/src/media/audio/opensl/audio_common.h
daemon/src/media/audio/opensl/audio_recorder.h
daemon/src/media/audio/opensl/buf_manager.h
Copyright: 2015 The Android Open Source Project
2015-2019 Savoir-faire Linux Inc.
2015-2023 Savoir-faire Linux Inc.
License: Apache-2.0
Files: daemon/extras/tools/bootstrap
@ -91,7 +91,7 @@ License: BSD-3-Clause
##################
Files: lrc/*
Copyright: 2009-2019 by Savoir-faire Linux
Copyright: 2009-2023 by Savoir-faire Linux Inc.
License: LGPL-2.1+
################

View File

@ -8,9 +8,9 @@ Release: %{release}%{?dist}
Summary: Daemon component of Jami
Group: Applications/Internet
License: GPLv3+
Vendor: Savoir-faire Linux
Vendor: Savoir-faire Linux Inc.
URL: https://jami.net/
Source: jami_%{version}.tar.gz
Source: jami-%{version}.tar.gz
Requires: jami-daemon = %{version}
# Build dependencies
@ -59,14 +59,14 @@ universal communication which respects the freedoms and privacy of its
users.
%prep
%setup -n client-qt
%setup -n jami-%{version}
%build
CFLAGS="${CFLAGS} -fno-lto"
CXXFLAGS="${CXXFLAGS} -fno-lto"
# Configure the Jami bundled libraries (ffmpeg & pjproject).
mkdir -p daemon/contrib/native
cd %{_builddir}/client-qt/daemon/contrib/native && \
cd %{_builddir}/jami-%{version}/daemon/contrib/native && \
../bootstrap \
--no-checksums \
--disable-ogg \
@ -83,19 +83,19 @@ cd %{_builddir}/client-qt/daemon/contrib/native && \
make %{_smp_mflags} V=1 && \
make %{_smp_mflags} V=1 .ffmpeg
# Configure the daemon.
cd %{_builddir}/client-qt/daemon && \
cd %{_builddir}/jami-%{version}/daemon && \
./autogen.sh && \
./configure \
--prefix=%{_prefix} \
--libdir=%{_libdir}
# Build the daemon.
make -C %{_builddir}/client-qt/daemon %{_smp_mflags} V=1
pod2man %{_builddir}/client-qt/daemon/man/jamid.pod \
> %{_builddir}/client-qt/daemon/jamid.1
make -C %{_builddir}/jami-%{version}/daemon %{_smp_mflags} V=1
pod2man %{_builddir}/jami-%{version}/daemon/man/jamid.pod \
> %{_builddir}/jami-%{version}/daemon/jamid.1
%install
DESTDIR=%{buildroot} make -C daemon install
cp %{_builddir}/client-qt/daemon/jamid.1 \
cp %{_builddir}/jami-%{version}/daemon/jamid.1 \
%{buildroot}/%{_mandir}/man1/jamid.1
rm -rfv %{buildroot}/%{_libdir}/*.a
rm -rfv %{buildroot}/%{_libdir}/*.la

View File

@ -13,9 +13,9 @@ Release: %{release}%{?dist}
Summary: Transitional package for Jami; can be safely removed
Group: Applications/Internet
License: GPLv3+
Vendor: Savoir-faire Linux
Vendor: Savoir-faire Linux Inc.
URL: https://jami.net/
Source: jami_%{version}.tar.gz
Source: jami-%{version}.tar.gz
%description
This is a transitional package. Jami libclient has been merged into

View File

@ -23,9 +23,9 @@ Release: %{release}%{?dist}
Summary: Library for Jami-qt
Group: Applications/Internet
License: GPLv3+
Vendor: Savoir-faire Linux
Vendor: Savoir-faire Linux Inc.
URL: https://jami.net/
Source: jami-qtlib_%{version}.tar.xz
Source: jami-libqt-%{version}.tar.xz
Patch0: 0001-qtbug-101201-fatal-error-getcurrenkeyboard.patch
%global gst 0.10

View File

@ -13,9 +13,9 @@ Release: %{release}%{?dist}
Summary: Transitional package for Jami; can be safely removed
Group: Applications/Internet
License: GPLv3+
Vendor: Savoir-faire Linux
Vendor: Savoir-faire Linux Inc.
URL: https://jami.net/
Source: jami_%{version}.tar.gz
Source: jami-%{version}.tar.gz
Requires: jami
%description

View File

@ -8,9 +8,9 @@ Release: %{release}%{?dist}
Summary: Qt client for Jami
Group: Applications/Internet
License: GPLv3+
Vendor: Savoir-faire Linux
Vendor: Savoir-faire Linux Inc.
URL: https://jami.net/
Source: jami_%{version}.tar.gz
Source: jami-%{version}.tar.gz
Requires: jami-daemon = %{version}
Requires: jami-libqt
Provides: jami-qt = %{version}
@ -36,12 +36,12 @@ software for universal communication which respects freedoms and
privacy of its users.
%prep
%setup -n client-qt
%setup -n jami-%{version}
%build
# Configure and build bundled ffmpeg (for libavutil/avframe).
mkdir -p %{_builddir}/client-qt/daemon/contrib/native
cd %{_builddir}/client-qt/daemon/contrib/native && \
mkdir -p %{_builddir}/jami-%{version}/daemon/contrib/native
cd %{_builddir}/jami-%{version}/daemon/contrib/native && \
../bootstrap \
--no-checksums \
--disable-ogg \
@ -57,19 +57,19 @@ cd %{_builddir}/client-qt/daemon/contrib/native && \
make fetch && \
make %{_smp_mflags} V=1 .ffmpeg
# Qt-related variables
cd %{_builddir}/client-qt && \
cd %{_builddir}/jami-%{version} && \
mkdir build && cd build && \
cmake -DENABLE_LIBWRAP=true \
-DLIBJAMI_BUILD_DIR=%{_builddir}/client-qt/daemon/src \
-DLIBJAMI_BUILD_DIR=%{_builddir}/jami-%{version}/daemon/src \
-DCMAKE_INSTALL_PREFIX=%{_prefix} \
-DCMAKE_INSTALL_LIBDIR=%{_libdir} \
-DWITH_DAEMON_SUBMODULE=true \
-DCMAKE_BUILD_TYPE=Release \
..
make -C %{_builddir}/client-qt/build %{_smp_mflags} V=1
make -C %{_builddir}/jami-%{version}/build %{_smp_mflags} V=1
%install
DESTDIR=%{buildroot} make -C %{_builddir}/client-qt/build install
DESTDIR=%{buildroot} make -C %{_builddir}/jami-%{version}/build install
%files
%defattr(-,root,root,-)
@ -81,4 +81,4 @@ DESTDIR=%{buildroot} make -C %{_builddir}/client-qt/build install
%{_datadir}/pixmaps/jami.xpm
%{_datadir}/metainfo/jami.appdata.xml
%{_datadir}/jami/translations/*
%doc %{_mandir}/man1/jami*
%doc %{_mandir}/man1/jami*

View File

@ -1,4 +1,4 @@
# Copyright (C) 2019-2022 Savoir-faire Linux Inc.
# Copyright (C) 2019-2023 Savoir-faire Linux Inc.
#
# Author: Sébastien Blin <sebastien.blin@savoirfairelinux.com>
# Author: Amin Bandali <amin.bandali@savoirfairelinux.com>
@ -312,6 +312,7 @@ parts:
- libdbus-c++-dev
- libpulse-dev # pulse
- libudev-dev
- libopus-dev # Avoid to build opus from contrib
- libglu1-mesa-dev # Qt 6
- zlib1g-dev
- libgl-dev

View File

@ -1,6 +1,6 @@
#!/usr/bin/env bash
#
# Copyright (C) 2016-2021 Savoir-faire Linux Inc.
# Copyright (C) 2016-2023 Savoir-faire Linux Inc.
#
# Author: Alexandre Viau <alexandre.viau@savoirfairelinux.com>
# Author: Amin Bandali <amin.bandali@savoirfairelinux.com>

View File

@ -1,6 +1,6 @@
#!/usr/bin/env bash
#
# Copyright (C) 2016-2021 Savoir-faire Linux Inc.
# Copyright (C) 2016-2023 Savoir-faire Linux Inc.
#
# Author: Alexandre Viau <alexandre.viau@savoirfairelinux.com>
# Author: Maxim Cournoyer <maxim.cournoyer@savoirfairelinux.com>
@ -26,7 +26,7 @@ set -e
# Import the spec file.
mkdir -p /opt/client-qt
cd /opt/client-qt
tar xf "/src/$RELEASE_TARBALL_FILENAME" client-qt/extras/packaging/gnu-linux/rules/rpm \
tar xf "/src/$RELEASE_TARBALL_FILENAME" --wildcards 'jami-*/extras/packaging/gnu-linux/rules/rpm' \
--strip-components=5 && mv rpm/* . && rmdir rpm
rm jami-libqt.spec
@ -74,7 +74,7 @@ if [ ! -f "${RPM_PATH}" ]; then
mkdir /opt/qt-jami-build
cd /opt/qt-jami-build
tar xf "/src/$RELEASE_TARBALL_FILENAME" \
client-qt/extras/packaging/gnu-linux/rules/rpm/jami-libqt.spec \
--wildcards 'jami-*/extras/packaging/gnu-linux/rules/rpm/jami-libqt.spec' \
--strip-components=6
# Fetch and cache the tarball, if not already available.
@ -93,7 +93,7 @@ if [ ! -f "${RPM_PATH}" ]; then
) 8>"${CACHED_QT_TARBALL}.lock"
fi
cp "$CACHED_QT_TARBALL" "/root/rpmbuild/SOURCES/jami-qtlib_$QT_MAJOR_MINOR_PATCH.tar.xz"
cp "$CACHED_QT_TARBALL" "/root/rpmbuild/SOURCES/jami-libqt-$QT_MAJOR_MINOR_PATCH.tar.xz"
sed -i "s/RELEASE_VERSION/$QT_MAJOR_MINOR_PATCH/g" jami-libqt.spec
rpmdev-bumpspec --comment="Automatic nightly release" \
--userstring="Jenkins <jami@lists.savoirfairelinux.net>" jami-libqt.spec

View File

@ -1,6 +1,6 @@
#!/usr/bin/env bash
#
# Copyright (C) 2020-2021 Savoir-faire Linux Inc.
# Copyright (C) 2020-2023 Savoir-faire Linux Inc.
#
# Author: Amin Bandali <amin.bandali@savoirfairelinux.com>
#
@ -24,7 +24,7 @@
set -e
tar xf "/src/$RELEASE_TARBALL_FILENAME" -C /opt
cd /opt/client-qt/
cd /opt/jami-*/
cp -r extras/packaging/gnu-linux/rules/snap/common .
cp -r extras/packaging/gnu-linux/rules/snap/${SNAP_PKG_NAME}/snapcraft.yaml .

View File

@ -1,6 +1,6 @@
#!/usr/bin/env bash
#
# Copyright (C) 2016-2021 Savoir-faire Linux Inc.
# Copyright (C) 2016-2023 Savoir-faire Linux Inc.
#
# Author: Alexandre Viau <alexandre.viau@savoirfairelinux.com>
# Author: Guillaume Roguez <guillaume.roguez@savoirfairelinux.com>
@ -272,7 +272,7 @@ function package()
{
if [[ $DISTRIBUTION =~ debian|ubuntu|raspbian|guix-deb-pack ]]; then
package_deb
elif [[ $DISTRIBUTION =~ fedora|rhel|opensuse ]]; then
elif [[ $DISTRIBUTION =~ fedora|rhel|opensuse|guix-rpm-pack ]]; then
package_rpm
elif [[ $DISTRIBUTION =~ snap ]]; then
package_snap

View File

@ -1,6 +1,6 @@
#!/usr/bin/env bash
#
# Copyright (C) 2021 Savoir-faire Linux Inc.
# Copyright (C) 2021-2023 Savoir-faire Linux Inc.
#
# Author: Amin Bandali <amin.bandali@savoirfairelinux.com>
#

View File

@ -0,0 +1,35 @@
#!/bin/sh
#
# Copyright (C) 2023 Savoir-faire Linux Inc.
#
# Author: Amin Bandali <amin.bandali@savoirfairelinux.com>
#
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/>.
#
# This script is used in the packaging containers to build a snap
# package on an ubuntu base distro.
if [ $# -gt 1 ]; then
echo "Usage: $0 {stable,beta,nightly}"
exit 1
fi
# default to stable if no release type given
release_type=${1:-stable}
last_commit_date=$(git log -1 --format=%cd --date=format:'%Y%m%d')
same_day_releases=$(git tag -l "${release_type}/${last_commit_date}*" | wc -l)
release_counter=${same_day_releases:-0}
release_version=${last_commit_date}.${release_counter}
printf "${release_version}"

View File

@ -1,16 +0,0 @@
/home/amarok/Projects/jami/daemon/contrib/tarballs/asio-asio-1-22-1.tar.gz
/home/amarok/Projects/jami/daemon/contrib/tarballs/ffmpeg-n5.0.tar.gz
/home/amarok/Projects/jami/daemon/contrib/tarballs/ffnvcodec-n11.1.5.1.tar.xz
/home/amarok/Projects/jami/daemon/contrib/tarballs/fmt-9.1.0.tar.gz
/home/amarok/Projects/jami/daemon/contrib/tarballs/gmp-6.2.1.tar.bz2
/home/amarok/Projects/jami/daemon/contrib/tarballs/http-parser-2.9.4.tar.gz
/home/amarok/Projects/jami/daemon/contrib/tarballs/libarchive-3.6.0.tar.xz
/home/amarok/Projects/jami/daemon/contrib/tarballs/libgit2-v1.1.0.tar.gz
/home/amarok/Projects/jami/daemon/contrib/tarballs/libnatpmp-20150609.tar.gz
/home/amarok/Projects/jami/daemon/contrib/tarballs/opendht-af7d88b057fa4c84ab9096c6a1932bd5d34634ef.tar.gz
/home/amarok/Projects/jami/daemon/contrib/tarballs/pjproject-513a3f14c44b2c2652f9219ec20dea64b236b713.tar.gz
/home/amarok/Projects/jami/daemon/contrib/tarballs/restinio-bbaa034dbcc7555ce67df0f8a1475591a7441733.tar.gz
/home/amarok/Projects/jami/daemon/contrib/tarballs/secp256k1-0b7024185045a49a1a6a4c5615bf31c94f63d9c4.tar.gz
/home/amarok/Projects/jami/daemon/contrib/tarballs/pupnp-release-1.14.13.tar.gz
/home/amarok/Projects/jami/daemon/contrib/tarballs/libvpx-v1.12.0.tar.gz
/home/amarok/Projects/jami/daemon/contrib/tarballs/webrtc-audio-processing-v0.3.1.tar.gz

View File

@ -0,0 +1,142 @@
#!/usr/bin/env bash
# Flags:
# -a: architecture to build. Accepted values arm64, x86_64, unified
# -d: debug
set -e
arch=''
debug=
while getopts "a:d:" OPT; do
case "$OPT" in
a)
arch="${OPTARG}"
;;
d)
debug=true
;;
\?)
exit 1
;;
esac
done
if [[ "$arch" == 'unified' ]]; then
echo "unified build"
ARCHS=("arm64" "x86_64")
elif [[ "$arch" == '' ]]; then
ARCHS=("arm64")
else
ARCHS=("$arch")
fi
TOP="$(pwd)"
INSTALL="${TOP}/install"
OS_VER=$(uname -r)
DAEMON=${TOP}/daemon
cd "$DAEMON"
FAT_CONTRIB_DIR=$DAEMON/contrib/apple-darwin
mkdir -p "$FAT_CONTRIB_DIR"
# build contrib for every arch
for ARCH in "${ARCHS[@]}"; do
HOST="${ARCH}-apple-darwin${OS_VER}"
mkdir -p contrib/native-"${ARCH}"
(
cd contrib/native-"${ARCH}"
../bootstrap --host="$HOST"
echo "Building contrib for $ARCH"
# force to build every contrib
for dir in "$DAEMON"/contrib/src/*/; do
PKG=$(basename -- "$dir")
if [ "$PKG" != "dbus-cpp" ] && [ "$PKG" != "natpmp" ] &&
[ "$PKG" != "portaudio" ] && [ "$PKG" != "pthreads" ] &&
[ "$PKG" != "lttng-ust" ] && [ "$PKG" != "openssl" ] &&
[ "$PKG" != "media-sdk" ] && [ "$PKG" != "jack" ] &&
[ "$PKG" != "onnx" ] && [ "$PKG" != "opencv" ] &&
[ "$PKG" != "opencv_contrib" ] && [ "$PKG" != "uuid" ] &&
[ "$PKG" != "webrtc-audio-processing" ] && [ "$PKG" != "liburcu" ]; then
make -j"$NPROC" ."$PKG"
fi
done
)
done
# make fat libs for contrib
mkdir -p "$FAT_CONTRIB_DIR"/lib
if ((${#ARCHS[@]} == "2")); then
echo "Making fat lib for ${ARCHS[0]} and ${ARCHS[1]}"
LIBFILES="$DAEMON/contrib/${ARCHS[0]}-apple-darwin$OS_VER/lib/*".a
for f in $LIBFILES; do
# filter out arch from file name
arch0=${ARCHS[0]}
if [ "$arch0" = "arm64" ]; then
arch0="aarch64"
fi
# file name for first arch
libfile0=${f##*/}
# file name without arch
libfile="${libfile0//"-$arch0"/}"
# replace arch0 with ARCHS[1] to get file name for second arch
libfile1="${libfile0//$arch0/${ARCHS[1]}}"
echo "Processing $libfile from $libfile0 and $libfile1 $ lib..."
lipo -create "$DAEMON/contrib/${ARCHS[0]}-apple-darwin$OS_VER/lib/$libfile0" \
"$DAEMON/contrib/${ARCHS[1]}-apple-darwin$OS_VER/lib/$libfile1" \
-output "$FAT_CONTRIB_DIR/lib/$libfile"
done
else
echo "No need for fat lib"
rsync -ar --delete "$DAEMON/contrib/${ARCHS[0]}-apple-darwin$OS_VER/lib/"*.a "$FAT_CONTRIB_DIR/lib"
fi
rsync -ar --delete "$DAEMON/contrib/${ARCHS[0]}-apple-darwin$OS_VER/include"* "$FAT_CONTRIB_DIR/"
# build deamon for every arch
for ARCH in "${ARCHS[@]}"; do
echo "$ARCH"
cd "$DAEMON"
HOST="${ARCH}-apple-darwin"
CONFIGURE_FLAGS=" --without-dbus --host=${HOST} -with-contrib=$DAEMON/contrib/${ARCH}-apple-darwin${OS_VER} --prefix=${INSTALL}/daemon/$ARCH"
if [ "${debug}" = "true" ]; then
CONFIGURE_FLAGS+=" --enable-debug"
fi
echo "$CONFIGURE_FLAGS"
./autogen.sh || exit
# We need to copy this file or else it's just an empty file
rsync -a "$DAEMON"/src/buildinfo.cpp ./src/buildinfo.cpp
mkdir -p "build-macos-${ARCH}"
cd "build-macos-${ARCH}"
"$DAEMON"/configure $CONFIGURE_FLAGS ARCH="$ARCH" || exit 1
echo "$CONFIGURE_FLAGS"
rsync -a "$DAEMON"/src/buildinfo.cpp ./src/buildinfo.cpp
make -j"$NPROC" || exit 1
make install || exit 1
cd "$DAEMON"
done
# make fat lib for daemon
FAT_INSTALL_DIR="${INSTALL}"/daemon/
mkdir -p "${FAT_INSTALL_DIR}"
if ((${#ARCHS[@]} == "2")); then
echo "Creating daemon fat lib"
mkdir -p "$FAT_INSTALL_DIR"/lib
lipo -create "${INSTALL}/daemon/${ARCHS[0]}/lib/libjami.a" \
"${INSTALL}/daemon/${ARCHS[1]}/lib/libjami.a" \
-output "${FAT_INSTALL_DIR}"/lib/libjami.a
else
echo "No need for daemon fat lib"
rsync -ar --delete "${INSTALL}/daemon/${ARCHS[0]}/lib/libjami.a" "${FAT_INSTALL_DIR}"/lib/
fi
rsync -ar --delete "${INSTALL}/daemon/${ARCHS[0]}/include/"* "$FAT_INSTALL_DIR"/include

View File

@ -0,0 +1,61 @@
#!/usr/bin/env bash
# Flags:
# -a: architecture to build. Accepted values arm64, x86_64, unified
arch=''
while getopts "a:" OPT; do
case "$OPT" in
a)
arch="${OPTARG}"
;;
\?)
exit 1
;;
esac
done
if [[ "$arch" == 'unified' ]]; then
ARCHS=("arm64" "x86_64")
elif [[ "$arch" == '' ]]; then
ARCHS=("arm64")
else
ARCHS=("$arch")
fi
TOP="$(pwd)"
QRENCODEDIR="${TOP}/3rdparty/libqrencode"
if [ -z "$NPROC" ]; then
NPROC=$(sysctl -n hw.ncpu || echo -n 1)
fi
for ARCH in "${ARCHS[@]}"; do
cd "$QRENCODEDIR" || exit 1
BUILDDIR="$ARCH-libqrencode"
mkdir "$BUILDDIR"
make clean
./autogen.sh
./configure --host="$ARCH" --without-png --prefix="${QRENCODEDIR}/${BUILDDIR}" CFLAGS=" -arch $ARCH $CFLAGS"
make -j"$NPROC"
make install
done
mkdir -p "$QRENCODEDIR"/lib
mkdir -p "$QRENCODEDIR"/include
if ((${#ARCHS[@]} == "2")); then
echo "Making fat lib for ${ARCHS[0]} and ${ARCHS[1]}"
LIBFILES="$QRENCODEDIR/${ARCHS[0]}-libqrencode/lib/*.a"
for f in $LIBFILES; do
libFile=${f##*/}
echo "$libFile"
lipo -create "$QRENCODEDIR/${ARCHS[0]}-libqrencode/lib/$libFile" \
"$QRENCODEDIR/${ARCHS[1]}-libqrencode/lib/$libFile" \
-output "${QRENCODEDIR}/lib/$libFile"
done
else
echo "No need for fat lib"
rsync -ar --delete "$QRENCODEDIR/${ARCHS[0]}-libqrencode/lib/"*.a "${QRENCODEDIR}/lib/"
fi
rsync -ar --delete "$QRENCODEDIR/${ARCHS[0]}-libqrencode/include/"* "${QRENCODEDIR}/include/"

View File

@ -1,7 +1,7 @@
#!/usr/bin/env bash
# format.sh --- set up clang-format for source files
# Copyright (C) 2020-2022 Savoir-faire Linux Inc.
# Copyright (C) 2020-2023 Savoir-faire Linux Inc.
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by

View File

@ -1,7 +1,7 @@
#!/usr/bin/env python3
# -*- coding: utf-8 -*-
# Copyright (C) 2022 Savoir-faire Linux Inc.
# Copyright (C) 2022-2023 Savoir-faire Linux Inc.
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by

View File

@ -1,7 +1,7 @@
#!/usr/bin/env python3
# -*- coding: utf-8 -*-
# Copyright (C) 2021-2022 Savoir-faire Linux Inc.
# Copyright (C) 2021-2023 Savoir-faire Linux Inc.
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by

View File

@ -1,4 +1,4 @@
# Copyright (C) 2019-2022 Savoir-faire Linux Inc.
# Copyright (C) 2019-2023 Savoir-faire Linux Inc.
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by

View File

@ -1,7 +1,7 @@
#!/usr/bin/env bash
# install.sh --- build and install Jami daemon and client
# Copyright (C) 2016-2022 Savoir-faire Linux Inc.
# Copyright (C) 2016-2023 Savoir-faire Linux Inc.
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
@ -28,6 +28,7 @@ export OSTYPE
# -u: disable use of privileges (sudo) during install
# -W: disable libwrap and shared library
# -w: do not use Qt WebEngine
# -a: arch to build
set -ex
@ -42,8 +43,9 @@ proc='1'
priv_install=true
enable_libwrap=true
enable_webengine=true
arch=''
while getopts gsc:dQ:P:p:uWw OPT; do
while getopts gsc:dQ:P:p:uWw:a: OPT; do
case "$OPT" in
g)
global='true'
@ -72,6 +74,9 @@ while getopts gsc:dQ:P:p:uWw OPT; do
w)
enable_webengine='false'
;;
a)
arch="${OPTARG}"
;;
\?)
exit 1
;;
@ -102,64 +107,68 @@ fi
# jamid
DAEMON="${TOP}/daemon"
cd "$DAEMON"
# Build the contribs.
mkdir -p contrib/native
(
cd contrib/native
../bootstrap ${prefix:+"--prefix=$prefix"}
make -j"${proc}"
)
if [[ "${enable_libwrap}" != "true" ]]; then
# Disable shared if requested
if [[ "$OSTYPE" != "darwin"* ]]; then
CONFIGURE_FLAGS+=" --disable-shared"
fi
fi
BUILD_TYPE="Release"
if [ "${debug}" = "true" ]; then
BUILD_TYPE="Debug"
CONFIGURE_FLAGS+=" --enable-debug"
fi
# Build the daemon itself.
test -f configure || ./autogen.sh
if [ "${global}" = "true" ]; then
./configure ${CONFIGURE_FLAGS} ${prefix:+"--prefix=$prefix"}
if [[ "$OSTYPE" == "darwin"* ]]; then
sh "${TOP}"/extras/scripts/build_daemon_macos.sh -a "$arch" -d "$debug"
else
./configure ${CONFIGURE_FLAGS} --prefix="${INSTALL_DIR}"
fi
make -j"${proc}" V=1
make_install "${global}" "${priv_install}"
cd "$DAEMON"
# Verify system's version if no path provided.
if [ -z "$qtpath" ]; then
sys_qtver=""
if command -v qmake6 &> /dev/null; then
sys_qtver=$(qmake6 -v)
elif command -v qmake-qt6 &> /dev/null; then
sys_qtver=$(qmake-qt6 -v) # Fedora
elif command -v qmake &> /dev/null; then
sys_qtver=$(qmake -v)
else
echo "No valid Qt found"; exit 1;
# Build the contribs.
mkdir -p contrib/native
(
cd contrib/native
../bootstrap ${prefix:+"--prefix=$prefix"}
make -j"${proc}"
)
if [[ "${enable_libwrap}" != "true" ]]; then
# Disable shared if requested
if [[ "$OSTYPE" != "darwin"* ]]; then
CONFIGURE_FLAGS+=" --disable-shared"
fi
fi
sys_qtver=${sys_qtver#*Qt version}
sys_qtver=${sys_qtver%\ in\ *}
BUILD_TYPE="Release"
if [ "${debug}" = "true" ]; then
BUILD_TYPE="Debug"
CONFIGURE_FLAGS+=" --enable-debug"
fi
installed_qtver=$(echo "$sys_qtver" | cut -d'.' -f 2)
required_qtver=$(echo $QT_MIN_VER | cut -d'.' -f 2)
# Build the daemon itself.
test -f configure || ./autogen.sh
if [[ $installed_qtver -ge $required_qtver ]] ; then
# Set qtpath to empty in order to use system's Qt.
qtpath=""
if [ "${global}" = "true" ]; then
./configure ${CONFIGURE_FLAGS} ${prefix:+"--prefix=$prefix"}
else
echo "No valid Qt found"; exit 1;
./configure ${CONFIGURE_FLAGS} --prefix="${INSTALL_DIR}"
fi
make -j"${proc}" V=1
make_install "${global}" "${priv_install}"
# Verify system's version if no path provided.
if [ -z "$qtpath" ]; then
sys_qtver=""
if command -v qmake6 &> /dev/null; then
sys_qtver=$(qmake6 -v)
elif command -v qmake-qt6 &> /dev/null; then
sys_qtver=$(qmake-qt6 -v) # Fedora
elif command -v qmake &> /dev/null; then
sys_qtver=$(qmake -v)
else
echo "No valid Qt found"; exit 1;
fi
sys_qtver=${sys_qtver#*Qt version}
sys_qtver=${sys_qtver%\ in\ *}
installed_qtver=$(echo "$sys_qtver" | cut -d'.' -f 2)
required_qtver=$(echo $QT_MIN_VER | cut -d'.' -f 2)
if [[ $installed_qtver -ge $required_qtver ]] ; then
# Set qtpath to empty in order to use system's Qt.
qtpath=""
else
echo "No valid Qt found"; exit 1;
fi
fi
fi
@ -172,6 +181,21 @@ client_cmake_flags=(-DCMAKE_BUILD_TYPE="${BUILD_TYPE}"
-DCMAKE_PREFIX_PATH="${qtpath}"
-DENABLE_LIBWRAP="${enable_libwrap}"
-DWITH_WEBENGINE="${enable_webengine}")
if [[ "$OSTYPE" == "darwin"* ]]; then
#detect arch for macos
CMAKE_OSX_ARCHITECTURES="arm64"
if [[ "$arch" == 'unified' ]]; then
CMAKE_OSX_ARCHITECTURES="x86_64;arm64"
elif [[ "$arch" != '' ]]; then
CMAKE_OSX_ARCHITECTURES="$arch"
fi
client_cmake_flags+=(-DCMAKE_OSX_ARCHITECTURES="${CMAKE_OSX_ARCHITECTURES}")
# build qrencode
(
cd ${TOP}
./extras/scripts/build_qrencode.sh -a "$arch"
)
fi
if [ "${global}" = "true" ]; then
client_cmake_flags+=(${prefix:+"-DCMAKE_INSTALL_PREFIX=$prefix"}

View File

@ -1,7 +1,7 @@
#!/usr/bin/python
##
## Copyright (C) 2016-2022 Savoir-faire Linux Inc.
## Copyright (C) 2016-2023 Savoir-faire Linux Inc.
##
## Author: Edric Milaret <edric.ladent-milaret@savoirfairelinux.com>
## Author: Guillaume Roguez <guillaume.roguez@savoirfairelinux.com>

View File

@ -36,5 +36,7 @@
<string>Jami requires to access your microphone to make calls and record audio</string>
<key>NSPhotoLibraryUsageDescription</key>
<string>Jami requires to access your photo library to show image on profile and send via chat</string>
<key>ITSAppUsesNonExemptEncryption</key>
<true/>
</dict>
</plist>

View File

@ -0,0 +1,13 @@
<?xml version="1.0" encoding="utf-8"?>
<!-- Generator: Adobe Illustrator 24.3.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) -->
<svg version="1.1" id="Layer_1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px"
viewBox="0 0 24 24" style="enable-background:new 0 0 24 24;" xml:space="preserve">
<g id="noun-about-3359358" transform="translate(-188.36 -188.36)">
<path id="Path_14" d="M200.4,190.4c-5.5,0-10,4.5-10,10s4.5,10,10,10s10-4.5,10-10C210.4,194.8,205.9,190.4,200.4,190.4z
M200.4,208.5c-4.5,0-8.2-3.7-8.2-8.2s3.7-8.2,8.2-8.2c4.5,0,8.2,3.7,8.2,8.2C208.5,204.9,204.9,208.5,200.4,208.5L200.4,208.5z"/>
<path id="Path_15" d="M200.4,197.7c-0.5,0-0.9,0.4-0.9,0.9c0,0,0,0,0,0v7.7c0,0.5,0.4,0.9,0.9,0.9s0.9-0.4,0.9-0.9l0,0v-7.7
C201.3,198.1,200.9,197.7,200.4,197.7C200.4,197.7,200.4,197.7,200.4,197.7z"/>
<path id="Path_16" d="M201.3,195.3c0,0.5-0.4,0.9-0.9,0.9c-0.5,0-0.9-0.4-0.9-0.9c0-0.5,0.4-0.9,0.9-0.9l0,0
C200.9,194.4,201.3,194.8,201.3,195.3"/>
</g>
</svg>

After

Width:  |  Height:  |  Size: 1022 B

View File

@ -0,0 +1,19 @@
<?xml version="1.0" encoding="utf-8"?>
<!-- Generator: Adobe Illustrator 24.3.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) -->
<svg version="1.1" id="Layer_1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px"
viewBox="0 0 24 24" style="enable-background:new 0 0 24 24;" xml:space="preserve">
<g>
<path d="M2.9,9.1c0.5,0,0.9-0.4,0.9-0.9V4.2c0-0.2,0.2-0.3,0.3-0.3h3.9c0.5,0,1-0.4,1-0.9S8.6,2,8.1,2H4.2C3,2,2,3,2,4.2v3.9
C2,8.6,2.4,9.1,2.9,9.1z"/>
<path d="M21.1,14.9c-0.5,0-0.9,0.4-0.9,0.9v3.9c0,0.2-0.2,0.3-0.3,0.3h-3.9c-0.5,0-0.9,0.4-0.9,0.9c0,0.5,0.4,1,0.9,1h3.9
c1.2,0,2.2-1,2.2-2.2v-3.9C22,15.4,21.6,14.9,21.1,14.9z"/>
<path d="M8.1,20.1H4.2c-0.2,0-0.3-0.2-0.3-0.3v-3.9c0-0.5-0.4-1-1-1c-0.5,0-0.9,0.4-0.9,1v3.9C2,21,3,22,4.2,22h3.9
c0.5,0,1-0.4,1-1C9.1,20.5,8.6,20.1,8.1,20.1z"/>
<path d="M15.9,3.9h3.9c0.2,0,0.3,0.2,0.3,0.3v3.9c0,0.5,0.4,0.9,0.9,0.9S22,8.6,22,8.1V4.2C22,3,21,2,19.8,2h-3.9
c-0.5,0-0.9,0.4-0.9,0.9S15.4,3.9,15.9,3.9z"/>
<path d="M16.8,12c0-1.3-0.5-2.5-1.4-3.4c-0.9-0.9-2.1-1.4-3.4-1.4c0,0,0,0,0,0c-1.3,0-2.5,0.5-3.4,1.4C7.7,9.5,7.2,10.7,7.2,12
c0,2.7,2.2,4.8,4.8,4.8c0,0,0,0,0,0C14.7,16.8,16.8,14.7,16.8,12z M12,9.1C12,9.1,12,9.1,12,9.1c1.6,0,2.9,1.3,2.9,2.9
c0,0.8-0.3,1.5-0.9,2.1c-0.5,0.5-1.3,0.9-2.1,0.9c0,0,0,0,0,0c-1.6,0-2.9-1.3-2.9-2.9c0-0.8,0.3-1.5,0.9-2.1
C10.5,9.4,11.2,9.1,12,9.1z"/>
</g>
</svg>

After

Width:  |  Height:  |  Size: 1.4 KiB

View File

@ -0,0 +1 @@
<svg xmlns="http://www.w3.org/2000/svg" height="48" width="48"><path d="M39.8 41.95 26.65 28.8q-1.5 1.3-3.5 2.025-2 .725-4.25.725-5.4 0-9.15-3.75T6 18.75q0-5.3 3.75-9.05 3.75-3.75 9.1-3.75 5.3 0 9.025 3.75 3.725 3.75 3.725 9.05 0 2.15-.7 4.15-.7 2-2.1 3.75L42 39.75Zm-20.95-13.4q4.05 0 6.9-2.875Q28.6 22.8 28.6 18.75t-2.85-6.925Q22.9 8.95 18.85 8.95q-4.1 0-6.975 2.875T9 18.75q0 4.05 2.875 6.925t6.975 2.875Z"/></svg>

After

Width:  |  Height:  |  Size: 417 B

View File

@ -85,5 +85,9 @@ function parseMessage(messageId, message, showPreview, color='#0645AD') {
}
if (showPreview)
getPreviewInfo(messageId, links[0].href)
window.jsbridge.emitLinkified(messageId, linkifyStr(message, color))
window.jsbridge.emitLinkified(messageId, linkifyStr(message, {
attributes: {
style: "color:" + color + ";"
}
}))
}

View File

@ -31,6 +31,7 @@ Mohamed Chibani<br>
Mohamed Amine Younes Bouacida<br>
Nicolas Jäger<br>
Nicolas Reynaud<br>
Nicolas Vengeon<br>
Olivier Gregoire<br>
Olivier Soldano<br>
Patrick Keroulas<br>

View File

@ -1,5 +1,5 @@
/*
* Copyright (C) 2019-2022 Savoir-faire Linux Inc.
* Copyright (C) 2019-2023 Savoir-faire Linux Inc.
* Author: Yang Wang <yang.wang@savoirfairelinux.com>
*
* This program is free software; you can redistribute it and/or modify

View File

@ -1,5 +1,5 @@
/*
* Copyright (C) 2020-2022 Savoir-faire Linux Inc.
* Copyright (C) 2020-2023 Savoir-faire Linux Inc.
* Author: Mingrui Zhang <mingrui.zhang@savoirfairelinux.com>
*
* This program is free software; you can redistribute it and/or modify

View File

@ -1,5 +1,5 @@
/*
* Copyright (C) 2022 Savoir-faire Linux Inc.
* Copyright (C) 2022-2023 Savoir-faire Linux Inc.
* Author: Andreas Traczyk <andreas.traczyk@savoirfairelinux.com>
*
* This program is free software; you can redistribute it and/or modify
@ -126,7 +126,7 @@ QtObject {
// Adds an item to the fullscreen item stack. Automatically puts
// the main window in fullscreen mode if needed. Callbacks should be used
// to perform component-specific tasks upon successful transitions.
function pushFullScreenItem(item, originalParent, pushedCb, removedCb) {
function pushFullScreenItem(item, prevParent, pushedCb, removedCb) {
if (item === null || item === undefined
|| priv.fullScreenItems.length >= 3) {
return
@ -138,10 +138,12 @@ QtObject {
// Add the item to our list and reparent it to appContainer.
priv.fullScreenItems.push({
"item": item,
"originalParent": originalParent,
"prevParent": prevParent,
"prevAnchorsFill": item.anchors.fill,
"removedCb": removedCb
})
item.parent = appContainer
item.anchors.fill = item.parent
if (pushedCb) {
pushedCb()
}
@ -164,7 +166,8 @@ QtObject {
}
if (obj !== undefined) {
if (obj.item !== appWindow) {
obj.item.parent = obj.originalParent
obj.item.anchors.fill = obj.prevAnchorsFill
obj.item.parent = obj.prevParent
if (obj.removedCb) {
obj.removedCb()
}

View File

@ -1,5 +1,5 @@
/*
* Copyright (C) 2020-2022 Savoir-faire Linux Inc.
* Copyright (C) 2020-2023 Savoir-faire Linux Inc.
* Author: Aline Gondim Santos <aline.gondimsantos@savoirfairelinux.com>
* Author: Andreas Traczyk <andreas.traczyk@savoirfairelinux.com>
* Author: Albert Babí <albert.babi@savoirfairelinux.com>
@ -51,6 +51,10 @@ ApplicationWindow {
property LayoutManager layoutManager: LayoutManager {
appContainer: appContainer
}
property ViewManager viewManager: ViewManager {}
property ViewCoordinator viewCoordinator: ViewCoordinator {
viewManager: root.viewManager
}
property bool windowSettingsLoaded: false
property bool allowVisibleWindow: true
@ -85,6 +89,7 @@ ApplicationWindow {
!UtilsAdapter.getAccountListSize()) {
// Save the window geometry and state before quitting.
layoutManager.saveWindowSettings()
viewCoordinator.dismissAll()
Qt.quit()
} else {
layoutManager.closeToTray()
@ -105,10 +110,6 @@ ApplicationWindow {
anchors.fill: parent
}
DaemonReconnectPopup {
id: daemonReconnectPopup
}
Loader {
id: mainApplicationLoader
@ -117,7 +118,14 @@ ApplicationWindow {
asynchronous: true
visible: status == Loader.Ready
source: ""
Connections {
target: viewCoordinator
function onRequestAppWindowWizardView() {
mainApplicationLoader.setSource(JamiQmlUtils.wizardViewLoadPath)
}
}
Connections {
target: mainApplicationLoader.item
@ -149,6 +157,14 @@ ApplicationWindow {
// Main window, load any valid app settings, and allow the
// layoutManager to handle as much as possible.
layoutManager.restoreWindowSettings()
// Present the welcome view once the viewCoordinator is setup.
viewCoordinator.initialized.connect(function() {
viewCoordinator.present("WelcomePage")
viewCoordinator.preload("ConversationView")
})
// Set the viewCoordinator's root item.
viewCoordinator.setRootView(item)
}
if (Qt.platform.os.toString() === "osx") {
MainApplication.setEventFilter()
@ -206,14 +222,11 @@ ApplicationWindow {
ignoreUnknownSignals: true
function onShowDaemonReconnectPopup(visible) {
if (visible)
daemonReconnectPopup.open()
else
daemonReconnectPopup.close()
}
function onDaemonReconnectFailed() {
daemonReconnectPopup.connectionFailed = true
if (visible) {
viewCoordinator.presentDialog(
appWindow,
"commoncomponents/DaemonReconnectPopup.qml")
}
}
}

340
src/app/ViewCoordinator.qml Normal file
View File

@ -0,0 +1,340 @@
/*
* Copyright (C) 2023 Savoir-faire Linux Inc.
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 3 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program. If not, see <https://www.gnu.org/licenses/>.
*/
import QtQuick
import QtQuick.Controls
import QtQuick.Layouts
import net.jami.Constants 1.1
import net.jami.Models 1.1
// This object should be implemented as a QML singleton, or be instantiated
// once in the main application window component. The top-level application window
// contains a loader[mainview, wizardview] and "rootView" MUST parent a horizontal
// SplitView with a StackView in each pane.
QtObject {
id: root
required property QtObject viewManager
signal requestAppWindowWizardView
// A map of view names to file paths for QML files that define each view.
property variant resources: {
"WelcomePage": "mainview/components/WelcomePage.qml",
"SidePanel": "mainview/components/SidePanel.qml",
"ConversationView": "mainview/ConversationView.qml",
"NewSwarmPage": "mainview/components/NewSwarmPage.qml",
"WizardView": "wizardview/WizardView.qml",
"SettingsView": "settingsview/SettingsView.qml",
}
// Maybe this state needs to be toggled because the SidePanel content is replaced.
// This makes it so the state can't be inferred from loaded views in single pane mode.
property bool inSettings: viewManager.hasView("SettingsView")
property bool inWizard: viewManager.hasView("WizardView")
property bool inNewSwarm: viewManager.hasView("NewSwarmPage")
property bool inhibitConversationView: inSettings || inWizard || inNewSwarm
property bool busy: false
// The `main` view of the application window.
property Item rootView: null
// HACKS.
property real mainViewWidth: rootView ? rootView.width : 0
property real previousWidth: mainViewWidth
property real mainViewSidePanelRectWidth: sv1 ? sv1.width : 0
property real lastSideBarSplitSize: mainViewSidePanelRectWidth
onMainViewWidthChanged: resolvePanes()
function resolvePanes(force=false) {
if (forceSinglePane) return
const isExpanding = previousWidth < mainViewWidth
if (mainViewWidth < JamiTheme.chatViewHeaderMinimumWidth + mainViewSidePanelRectWidth
&& sv2.visible && (!isExpanding || force)) {
lastSideBarSplitSize = mainViewSidePanelRectWidth
singlePane = true
} else if (mainViewWidth >= lastSideBarSplitSize + JamiTheme.chatViewHeaderMinimumWidth
&& !sv2.visible && (isExpanding || force) && !layoutManager.isFullScreen) {
singlePane = false
}
previousWidth = mainViewWidth
}
// Must be the child of `rootView`.
property Item splitView: null
// StackView objects, which are children of `splitView`.
property StackView sv1: null
property StackView sv2: null
// The StackView object that is currently active, determined by the value
// of singlePane.
readonly property StackView activeStackView: singlePane ? sv1 : sv2
readonly property string currentViewName: {
if (activeStackView == null || activeStackView.depth === 0) return ''
return activeStackView.currentItem.objectName
}
readonly property var currentView: {
return activeStackView ? activeStackView.currentItem : null
}
// Handle single/dual pane mode.
property bool forceSinglePane: false
property bool singlePane
onForceSinglePaneChanged: {
if (forceSinglePane) singlePane = true
else resolvePanes(true)
}
onSinglePaneChanged: {
// Hiding sv2 before moving items from, and after moving
// items to, reduces stack item visibility change events.
if (singlePane) {
sv2.visible = false
if (forceSinglePane) Qt.callLater(move, sv2, sv1)
else move(sv2, sv1)
} else {
move(sv1, sv2)
sv2.visible = true
}
}
// Emitted once at the end of setRootView.
signal initialized()
// Create, present, and return a dialog object.
function presentDialog(parent, path, props={}) {
// Open the dialog once the object is created
return viewManager.createView(path, parent, function(obj) {
const doneCb = function() { viewManager.destroyView(path) }
if (obj.closed !== undefined) {
obj.closed.connect(doneCb)
} else {
if (obj.accepted !== undefined) { obj.accepted.connect(doneCb) }
if (obj.rejected !== undefined) { obj.rejected.connect(doneCb) }
}
obj.open()
}, props)
}
// Dismiss all views.
function dismissAll() {
for (var path in viewManager.views) {
viewManager.destroyView(path)
}
}
// Get a view regardless of whether it is currently active.
function getView(viewName) {
if (!viewManager.hasView(viewName)) {
return null
}
return viewManager.views[viewManager.viewPaths[viewName]]
}
// Sets object references, onInitialized is a good time to present views.
function setRootView(obj) {
rootView = obj
splitView = rootView.splitView
sv1 = rootView.sv1
sv1.parent = Qt.binding(() => singlePane ? rootView : splitView)
sv1.anchors.fill = Qt.binding(() => singlePane ? rootView : undefined)
sv2 = rootView.sv2
initialized()
resolvePanes()
}
// Finds a view and gets its index within the StackView it's in.
function getStackIndex(viewName) {
for (const [key, value] of Object.entries(viewManager.views)) {
if (value.objectName === viewName) {
return value.StackView.index
}
}
return -1
}
// Load a view without presenting it.
function preload(viewName) {
if (!viewManager.createView(resources[viewName], null)) {
console.log("Failed to load view: " + viewName)
}
}
// This function presents the view with the given viewName in the
// specified StackView. Return the view if successful.
function present(viewName, sv=activeStackView) {
if (!rootView) return
if (viewName === "ConversationView" && inhibitConversationView) {
return
}
// If the view already exists in the StackView, the function will attempt
// to navigate to its StackView position by dismissing elevated views.
if (sv.find(function(item) {
return item.objectName === viewName;
})) {
const viewIndex = getStackIndex(viewName)
if (viewIndex >= 0) {
for (var i = (sv.depth - 1); i > viewIndex; i--) {
dismissObj(sv.get(i, StackView.DontLoad))
}
return true
}
return false
}
// If we are in single-pane mode and the view was previously forced into
// sv2, we can move it back to the top of sv1.
if (singlePane && sv === sv1) {
// See if the item is at the top of sv2
if (sv2.currentItem && sv2.currentItem.objectName === viewName) {
// Move it to the top of sv1
const view = sv2.pop(StackView.Immediate)
sv1.push(view, StackView.Immediate)
view.presented()
return view
}
}
const obj = viewManager.createView(resources[viewName], appWindow)
if (!obj) {
print("could not create view:", viewName)
return null
}
if (obj === currentView) {
print("view is current:", viewName)
return null
}
// If we are in single-pane mode and the view should start hidden
// (requiresIndex), we can push it into sv2.
if (singlePane && sv === sv1 && obj.requiresIndex) {
sv = sv2
} else {
forceSinglePane = obj.singlePaneOnly
}
const view = sv.push(obj, StackView.Immediate)
if (!view) {
return null
}
if (view.objectName === '') {
view.objectName = viewName
}
view.presented()
return view
}
// Dismiss by object.
function dismissObj(obj, sv=activeStackView) {
if (obj.StackView.view !== sv) {
print("view not in the stack:", obj)
return
}
// If we are dismissing a view that is not at the top of the stack,
// we need to store each of the views on top into a temporary stack
// and then restore them after the view is dismissed.
// So we get the index of the view we are dismissing.
const viewIndex = obj.StackView.index
var tempStack = []
for (var i = (sv.depth - 1); i > viewIndex; i--) {
var item = sv.pop(StackView.Immediate)
tempStack.push(item)
}
// And we define a function to restore and resolve the views.
var resolveStack = () => {
for (var i = 0; i < tempStack.length; i++) {
sv.push(tempStack[i], StackView.Immediate)
}
forceSinglePane = sv.currentItem.singlePaneOnly
sv.currentItem.presented()
}
// Now we can dismiss the view at the top of the stack.
const depth = sv.depth
if (obj === sv.get(depth - 1, StackView.DontLoad)) {
var view = sv.pop(StackView.Immediate)
if (!view) {
print("could not pop view:", obj.objectName)
resolveStack()
return
}
// If the view is managed, we can destroy it, otherwise, it can
// be reused and destroyed by it's parent.
if (view.managed) {
var objectName = view ? view.objectName : obj.objectName
if (!viewManager.destroyView(resources[objectName])) {
print("could not destroy view:", objectName)
}
} else {
view.dismissed()
}
}
resolveStack()
}
// Dismiss by view name.
function dismiss(viewName) {
if (!rootView) return
const depth = activeStackView.depth
for (var i = (depth - 1); i >= 0; i--) {
const view = activeStackView.get(i, StackView.DontLoad)
if (view.objectName === viewName) {
dismissObj(view)
return
}
}
// Check if the view is hidden on the top of sv2 (if in single-pane mode),
// and dismiss it in that case.
if (singlePane && sv2.currentItem && sv2.currentItem.objectName === viewName) {
dismissObj(sv2.currentItem, sv2)
}
}
// Move items from one stack to another. We avoid the recursive technique to
// avoid visibility change events.
function move(from, to, depth=1) {
busy = true
var tempStack = []
while (from.depth > depth) {
var item = from.pop(StackView.Immediate)
tempStack.push(item)
}
while (tempStack.length) {
to.push(tempStack.pop(), StackView.Immediate)
}
busy = false
}
// Effectively hide the current view by moving it to the other StackView.
// This function only works when in single-pane mode.
function hideCurrentView() {
if (singlePane) move(sv1, sv2)
}
}

87
src/app/ViewManager.qml Normal file
View File

@ -0,0 +1,87 @@
/*
* Copyright (C) 2023 Savoir-faire Linux Inc.
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 3 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program. If not, see <https://www.gnu.org/licenses/>.
*/
import QtQuick
QtObject {
id: viewManager
// A map of path strings to view objects.
property variant views: ({})
// A map of view names to path strings.
property variant viewPaths: ({})
// The number of views.
property int nViews: 0
function createView(path, parent=null, cb=null, props={}) {
if (views[path] !== undefined) {
// an instance of <path> already exists
return views[path]
}
const component = Qt.createComponent(Qt.resolvedUrl(path))
if (component.status === Component.Ready) {
const obj = component.createObject(parent, props)
if (obj === null) {
print("error creating object")
return null
}
views[path] = obj
// Set the view name to the object name if it has one.
const viewName = obj.objectName.toString() !== '' ?
obj.objectName :
path.replace(/^.*[\\\/]/, '').replace(/\.[^/.]+$/, "")
viewPaths[viewName] = path
nViews = Object.keys(views).length
if (cb !== null) {
cb(obj)
}
return views[path]
}
print("error creating component", path)
console.error(component.errorString())
Qt.exit(1)
return null
}
function destroyView(path) {
if (views[path] === undefined) {
print(path, "instance does not exist", Object.keys(views))
return false
}
views[path].destroy()
views[path] = undefined
// QObject::destroy is queued, and we can't connect to its completion,
// so we queue the resulting mutation to our view storage.
Qt.callLater(function() {
delete views[path]
// Remove the view name from the viewPaths map.
for (var viewName in viewPaths) {
if (viewPaths[viewName] === path) {
delete viewPaths[viewName]
break
}
}
nViews = Object.keys(views).length
})
return true
}
function hasView(viewName) {
return nViews && viewPaths[viewName] !== undefined
}
}

View File

@ -1,5 +1,5 @@
/*
* Copyright (C) 2019-2022 Savoir-faire Linux Inc.
* Copyright (C) 2019-2023 Savoir-faire Linux Inc.
* Author: Mingrui Zhang <mingrui.zhang@savoirfairelinux.com>
*
* This program is free software; you can redistribute it and/or modify

View File

@ -1,5 +1,5 @@
/*
* Copyright (C) 2020-2022 Savoir-faire Linux Inc.
* Copyright (C) 2020-2023 Savoir-faire Linux Inc.
* Author: Mingrui Zhang <mingrui.zhang@savoirfairelinux.com>
* Author: Yang Wang <yang.yang@savoirfairelinux.com>
* Author: Andreas Traczyk <andreas.traczyk@savoirfairelinux.com>
@ -183,7 +183,8 @@ AccountAdapter::createSIPAccount(const QVariantMap& settings)
confProps.hostname = settings["hostname"].toString();
confProps.username = settings["username"].toString();
confProps.password = settings["password"].toString();
confProps.routeset = settings["proxy"].toString();
confProps.TLS.enable = settings["tls"].toBool();
#ifdef Q_OS_WIN
confProps.Ringtone.ringtonePath = Utils::GetRingtonePath();
#endif
@ -327,23 +328,6 @@ AccountAdapter::getDefaultModerators(const QString& accountId)
return lrcInstance_->accountModel().getDefaultModerators(accountId);
}
bool
AccountAdapter::hasPassword()
{
auto confProps = lrcInstance_->accountModel().getAccountConfig(
lrcInstance_->get_currentAccountId());
return confProps.archiveHasPassword;
}
void
AccountAdapter::setArchiveHasPassword(bool isHavePassword)
{
auto confProps = lrcInstance_->accountModel().getAccountConfig(
lrcInstance_->get_currentAccountId());
confProps.archiveHasPassword = isHavePassword;
lrcInstance_->accountModel().setAccountConfig(lrcInstance_->get_currentAccountId(), confProps);
}
bool
AccountAdapter::exportToFile(const QString& accountId,
const QString& path,

View File

@ -1,5 +1,5 @@
/*
* Copyright (C) 2021-2022 Savoir-faire Linux Inc.
* Copyright (C) 2021-2023 Savoir-faire Linux Inc.
* Author: Mingrui Zhang <mingrui.zhang@savoirfairelinux.com>
*
* This program is free software; you can redistribute it and/or modify
@ -50,8 +50,6 @@ public:
QObject* parent = nullptr);
~AccountAdapter() = default;
void safeInit() override {}
// Change to account corresponding to combox box index.
Q_INVOKABLE void changeAccount(int row);
@ -64,8 +62,6 @@ public:
Q_INVOKABLE void deleteCurrentAccount();
// Conf property
Q_INVOKABLE bool hasPassword();
Q_INVOKABLE void setArchiveHasPassword(bool isHavePassword);
Q_INVOKABLE bool exportToFile(const QString& accountId,
const QString& path,
const QString& password = {}) const;

View File

@ -1,5 +1,5 @@
/*
* Copyright (C) 2019-2022 Savoir-faire Linux Inc.
* Copyright (C) 2019-2023 Savoir-faire Linux Inc.
* Author: Andreas Traczyk <andreas.traczyk@savoirfairelinux.com>
* Author: Mingrui Zhang <mingrui.zhang@savoirfairelinux.com>
*

View File

@ -1,5 +1,5 @@
/*
* Copyright (C) 2019-2022 Savoir-faire Linux Inc.
* Copyright (C) 2019-2023 Savoir-faire Linux Inc.
* Author: Andreas Traczyk <andreas.traczyk@savoirfairelinux.com>
* Author: Mingrui Zhang <mingrui.zhang@savoirfairelinux.com>
*

View File

@ -1,5 +1,5 @@
/*
* Copyright (C) 2021-2022 Savoir-faire Linux Inc.
* Copyright (C) 2021-2023 Savoir-faire Linux Inc.
* Author: Andreas Traczyk <andreas.traczyk@savoirfairelinux.com>
*
* This program is free software; you can redistribute it and/or modify
@ -57,6 +57,13 @@ AppSettingsManager::setValue(const Settings::Key key, const QVariant& value)
settings_->setValue(Settings::toString(key), value);
}
QString
AppSettingsManager::getLanguage()
{
auto pref = getValue(Settings::Key::LANG).toString();
return pref == "SYSTEM" ? QLocale::system().name() : pref;
}
void
AppSettingsManager::loadTranslations()
{
@ -75,9 +82,7 @@ AppSettingsManager::loadTranslations()
qApp->removeTranslator(tr);
installedTr_.clear();
auto pref = getValue(Settings::Key::LANG).toString();
QString locale_name = pref == "SYSTEM" ? QLocale::system().name() : pref;
QString locale_name = getLanguage();
qDebug() << QString("Using locale: %1").arg(locale_name);
QString locale_lang = locale_name.split('_')[0];

View File

@ -1,5 +1,5 @@
/*
* Copyright (C) 2020-2022 Savoir-faire Linux Inc.
* Copyright (C) 2020-2023 Savoir-faire Linux Inc.
* Author: Andreas Traczyk <andreas.traczyk@savoirfairelinux.com>
*
* This program is free software; you can redistribute it and/or modify
@ -111,6 +111,7 @@ public:
Q_INVOKABLE QVariant getValue(const Settings::Key key);
Q_INVOKABLE void setValue(const Settings::Key key, const QVariant& value);
QString getLanguage();
void loadTranslations();

View File

@ -1,5 +1,5 @@
/*
* Copyright (C) 2021-2022 Savoir-faire Linux Inc.
* Copyright (C) 2021-2023 Savoir-faire Linux Inc.
* Author: Andreas Traczyk <andreas.traczyk@savoirfairelinux.com>
*
* This program is free software; you can redistribute it and/or modify

View File

@ -1,5 +1,5 @@
/*
* Copyright (C) 2021-2022 Savoir-faire Linux Inc.
* Copyright (C) 2021-2023 Savoir-faire Linux Inc.
* Author: Andreas Traczyk <andreas.traczyk@savoirfairelinux.com>
*
* This program is free software; you can redistribute it and/or modify

View File

@ -1,5 +1,5 @@
/*
* Copyright (C) 2019-2022 Savoir-faire Linux Inc.
* Copyright (C) 2019-2023 Savoir-faire Linux Inc.
* Author: Yang Wang <yang.wang@savoirfairelinux.com>
*
* This program is free software; you can redistribute it and/or modify

View File

@ -1,5 +1,5 @@
/*
* Copyright (C) 2019-2022 Savoir-faire Linux Inc.
* Copyright (C) 2019-2023 Savoir-faire Linux Inc.
* Author: Yang Wang <yang.wang@savoirfairelinux.com>
*
* This program is free software; you can redistribute it and/or modify

View File

@ -1,5 +1,5 @@
/*
* Copyright (C) 2020-2022 Savoir-faire Linux Inc.
* Copyright (C) 2020-2023 Savoir-faire Linux Inc.
* Author : Edric Ladent Milaret<edric.ladent - milaret @savoirfairelinux.com>
* Author : Andreas Traczyk<andreas.traczyk @savoirfairelinux.com>
* Author: Mingrui Zhang <mingrui.zhang@savoirfairelinux.com>
@ -267,7 +267,7 @@ AvAdapter::getSharingResource(int screenId, const QString& windowProcessId, cons
rect.moveTop(0);
#endif
return lrcInstance_->getCurrentCallModel()->getDisplay(screenId,
return lrcInstance_->getCurrentCallModel()->getDisplay(getScreenNumber(screenId),
rect.x(),
rect.y(),
rect.width()
@ -290,14 +290,23 @@ AvAdapter::getListWindows()
}
void
AvAdapter::stopSharing()
AvAdapter::stopSharing(const QString& source)
{
auto callId = lrcInstance_->getCurrentCallId();
if (!callId.isEmpty()) {
lrcInstance_->getCurrentCallModel()->removeMedia(callId,
libjami::Media::Details::MEDIA_TYPE_VIDEO,
libjami::Media::VideoProtocolPrefix::DISPLAY,
muteCamera_);
if (!source.isEmpty() && !callId.isEmpty()) {
if (source.startsWith(libjami::Media::VideoProtocolPrefix::DISPLAY)) {
qDebug() << "Stopping display: " << source;
lrcInstance_->getCurrentCallModel()->removeMedia(callId,
libjami::Media::Details::MEDIA_TYPE_VIDEO,
libjami::Media::VideoProtocolPrefix::DISPLAY,
muteCamera_);
} else {
qDebug() << "Stopping file: " << source;
lrcInstance_->getCurrentCallModel()->removeMedia(callId,
libjami::Media::Details::MEDIA_TYPE_VIDEO,
libjami::Media::VideoProtocolPrefix::FILE,
muteCamera_);
}
}
}
@ -338,13 +347,6 @@ AvAdapter::onRendererStarted(const QString& id, const QSize& size)
return;
auto rendererInfo = rendererInfoList.first();
rendererInformationListModel_->addElement(qMakePair(id, rendererInfo));
auto callModel = lrcInstance_->getCurrentCallModel();
auto renderDevice = callModel->getCurrentRenderedDevice(callId);
if (!id.contains("://"))
return;
set_currentRenderingDeviceId(id);
set_currentRenderingDeviceType(renderDevice.type);
}
void

View File

@ -1,5 +1,5 @@
/*!
* Copyright (C) 2020-2022 Savoir-faire Linux Inc.
* Copyright (C) 2020-2023 Savoir-faire Linux Inc.
* Author: Mingrui Zhang <mingrui.zhang@savoirfairelinux.com>
*
* This program is free software; you can redistribute it and/or modify
@ -31,10 +31,6 @@
class AvAdapter final : public QmlAdapterBase
{
Q_OBJECT
// TODO: currentRenderingDeviceType is only used in QML to check if
// we're sharing or not, so it should maybe just be a boolean.
QML_RO_PROPERTY(lrc::api::video::DeviceType, currentRenderingDeviceType)
QML_RO_PROPERTY(QString, currentRenderingDeviceId)
QML_PROPERTY(bool, muteCamera)
QML_RO_PROPERTY(QStringList, windowsNames)
QML_RO_PROPERTY(QList<QVariant>, windowsIds)
@ -50,8 +46,6 @@ Q_SIGNALS:
void audioDeviceListChanged(int inputs, int outputs);
protected:
void safeInit() override {};
/**
* Check if user is sharing a media
*/
@ -89,12 +83,14 @@ protected:
Q_INVOKABLE void shareWindow(const QString& windowProcessId, const QString& windowId);
// Returns the screensharing resource
Q_INVOKABLE QString getSharingResource(int screenId = -2, const QString& windowProcessId = "", const QString& key = "");
Q_INVOKABLE QString getSharingResource(int screenId = -2,
const QString& windowProcessId = "",
const QString& key = "");
Q_INVOKABLE void getListWindows();
// Stop sharing the screen or file
Q_INVOKABLE void stopSharing();
Q_INVOKABLE void stopSharing(const QString& source = {});
Q_INVOKABLE void startAudioMeter();
Q_INVOKABLE void stopAudioMeter();

View File

@ -1,5 +1,5 @@
/*
* Copyright (C) 2020-2022 Savoir-faire Linux Inc.
* Copyright (C) 2020-2023 Savoir-faire Linux Inc.
* Author: Mingrui Zhang <mingrui.zhang@savoirfairelinux.com>
* Author: Andreas Traczyk <andreas.traczyk@savoirfairelinux.com>
*

View File

@ -1,5 +1,5 @@
/*
* Copyright (C) 2021-2022 Savoir-faire Linux Inc.
* Copyright (C) 2021-2023 Savoir-faire Linux Inc.
* Author: Andreas Traczyk <andreas.traczyk@savoirfairelinux.com>
*
* This program is free software; you can redistribute it and/or modify

View File

@ -1,5 +1,5 @@
/*
* Copyright (C) 2021-2022 Savoir-faire Linux Inc.
* Copyright (C) 2021-2023 Savoir-faire Linux Inc.
* Author: Andreas Traczyk <andreas.traczyk@savoirfairelinux.com>
*
* This program is free software; you can redistribute it and/or modify

View File

@ -1,5 +1,5 @@
/*
* Copyright (C) 2019-2022 Savoir-faire Linux Inc.
* Copyright (C) 2019-2023 Savoir-faire Linux Inc.
* Author: Isa Nanic <isa.nanic@savoirfairelinux.com>
* Author: Yang Wang <yang.wang@savoirfairelinux.com>
*

View File

@ -1,5 +1,5 @@
/*
* Copyright (C) 2019-2022 Savoir-faire Linux Inc.
* Copyright (C) 2019-2023 Savoir-faire Linux Inc.
* Author: Isa Nanic <isa.nanic@savoirfairelinux.com>
* Author: Yang Wang <yang.wang@savoirfairelinux.com>
*

View File

@ -1,5 +1,5 @@
/*
* Copyright (C) 2020-2022 Savoir-faire Linux Inc.
* Copyright (C) 2020-2023 Savoir-faire Linux Inc.
* Author: Edric Ladent Milaret <edric.ladent-milaret@savoirfairelinux.com>
* Author: Anthony Léonard <anthony.leonard@savoirfairelinux.com>
* Author: Olivier Soldano <olivier.soldano@savoirfairelinux.com>
@ -416,8 +416,6 @@ CallAdapter::acceptACall(const QString& accountId, const QString& convUid)
return;
lrcInstance_->getAccountInfo(accountId).callModel->accept(convInfo.callId);
auto& accInfo = lrcInstance_->getAccountInfo(convInfo.accountId);
accInfo.callModel->setCurrentCall(convInfo.callId);
}
void
@ -518,7 +516,13 @@ CallAdapter::updateCall(const QString& convUid, const QString& accountId, bool f
if (convInfo.uid == lrcInstance_->get_selectedConvUid()) {
auto& accInfo = lrcInstance_->accountModel().getAccountInfo(accountId_);
if (accInfo.profileInfo.type != lrc::api::profile::Type::SIP) {
accInfo.callModel->setCurrentCall(call->id);
// Only setCurrentCall if call is actually answered
try {
if (call->status == call::Status::IN_PROGRESS
|| call->status == call::Status::PAUSED)
accInfo.callModel->setCurrentCall(call->id);
} catch (...) {
}
}
}

View File

@ -1,5 +1,5 @@
/*
* Copyright (C) 2020-2022 Savoir-faire Linux Inc.
* Copyright (C) 2020-2023 Savoir-faire Linux Inc.
* Author: Mingrui Zhang <mingrui.zhang@savoirfairelinux.com>
* Author: Sébastien Blin <sebastien.blin@savoirfairelinux.com>
* Author: Andreas Traczyk <andreas.traczyk@savoirfairelinux.com>
@ -49,9 +49,6 @@ public:
explicit CallAdapter(SystemTray* systemTray, LRCInstance* instance, QObject* parent = nullptr);
~CallAdapter() = default;
protected:
void safeInit() override {};
public:
Q_INVOKABLE void startTimerInformation();
Q_INVOKABLE void stopTimerInformation();

View File

@ -1,5 +1,5 @@
/*
* Copyright (C) 2021-2022 Savoir-faire Linux Inc.
* Copyright (C) 2021-2023 Savoir-faire Linux Inc.
* Author: Andreas Traczyk <andreas.traczyk@savoirfairelinux.com>
* Author: Mingrui Zhang <mingrui.zhang@savoirfairelinux.com>
*
@ -54,7 +54,9 @@ PendingConferenceesListModel::PendingConferenceesListModel(LRCInstance* instance
, lrcInstance_(instance)
{
connectSignals();
connect(lrcInstance_, &LRCInstance::currentAccountIdChanged, [this]() { connectSignals(); });
connect(lrcInstance_, &LRCInstance::currentAccountIdChanged, this, [this]() {
connectSignals();
});
}
int
@ -128,10 +130,14 @@ PendingConferenceesListModel::connectSignals()
return;
using namespace PendingConferences;
callsStatusChanged_
= connect(currentCallModel, &CallModel::callStatusChanged, [this](const QString&, int) {
Q_EMIT dataChanged(index(0, 0), index(rowCount() - 1), {Role::CallStatus});
});
callsStatusChanged_ = connect(currentCallModel,
&CallModel::callStatusChanged,
this,
[this](const QString&, int) {
Q_EMIT dataChanged(index(0, 0),
index(rowCount() - 1),
{Role::CallStatus});
});
beginInsertPendingConferencesRows_ = connect(
currentCallModel,

View File

@ -1,5 +1,5 @@
/*
* Copyright (C) 2021-2022 Savoir-faire Linux Inc.
* Copyright (C) 2021-2023 Savoir-faire Linux Inc.
* Author: Andreas Traczyk <andreas.traczyk@savoirfairelinux.com>
* Author: Mingrui Zhang <mingrui.zhang@savoirfairelinux.com>
*

View File

@ -1,5 +1,5 @@
/*
* Copyright (C) 2022 Savoir-faire Linux Inc.
* Copyright (C) 2022-2023 Savoir-faire Linux Inc.
* Author: Aline Gondim Santos <aline.gondimsantos@savoirfairelinux.com>
*
* This program is free software; you can redistribute it and/or modify

View File

@ -1,5 +1,5 @@
/*
* Copyright (C) 2022 Savoir-faire Linux Inc.
* Copyright (C) 2022-2023 Savoir-faire Linux Inc.
* Author: Aline Gondim Santos <aline.gondimsantos@savoirfairelinux.com>
*
* This program is free software; you can redistribute it and/or modify

View File

@ -1,5 +1,5 @@
/*
* Copyright (C) 2020-2022 Savoir-faire Linux Inc.
* Copyright (C) 2020-2023 Savoir-faire Linux Inc.
* Author: Mingrui Zhang <mingrui.zhang@savoirfairelinux.com>
* Author: Andreas Traczyk <andreas.traczyk@savoirfairelinux.com>
*

View File

@ -1,5 +1,5 @@
/*
* Copyright (C) 2021-2022 Savoir-faire Linux Inc.
* Copyright (C) 2021-2023 Savoir-faire Linux Inc.
* Author: Mingrui Zhang <mingrui.zhang@savoirfairelinux.com>
*
* This program is free software; you can redistribute it and/or modify

View File

@ -1,5 +1,5 @@
/*
* Copyright (C) 2020-2022 Savoir-faire Linux Inc.
* Copyright (C) 2020-2023 Savoir-faire Linux Inc.
* Author: Andreas Traczyk <andreas.traczyk@savoirfairelinux.com>
*
* This program is free software; you can redistribute it and/or modify

View File

@ -0,0 +1,42 @@
/*
* Copyright (C) 2023 Savoir-faire Linux Inc.
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 3 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program. If not, see <https://www.gnu.org/licenses/>.
*/
import QtQuick
Rectangle {
id: viewNode
// True if this view is managed by the view coordinator.
// False if this view is managed by its parent view, and will
// only be destroyed when its parent is destroyed.
property bool managed: true
// True if this view functions in a single-pane context only.
property bool singlePaneOnly: false
// True if this view requires and initial selection from
// a group of menu options when in single-pane mode (e.g. settings).
property bool requiresIndex: false
function dismiss() { viewCoordinator.dismiss(objectName) }
signal presented
signal dismissed
Component.onCompleted: { if (managed) presented() }
Component.onDestruction: { if (managed) dismissed() }
}

View File

@ -1,5 +1,5 @@
/*
* Copyright (C) 2021-2022 Savoir-faire Linux Inc.
* Copyright (C) 2021-2023 Savoir-faire Linux Inc.
* Author: Mingrui Zhang <mingrui.zhang@savoirfairelinux.com>
*
* This program is free software; you can redistribute it and/or modify

View File

@ -1,5 +1,5 @@
/*
* Copyright (C) 2022 Savoir-faire Linux Inc.
* Copyright (C) 2022-2023 Savoir-faire Linux Inc.
* Author: Sébastien Blin <sebastien.blin@savoirfairelinux.com>
*
* This program is free software; you can redistribute it and/or modify
@ -61,12 +61,10 @@ SBSMessageBase {
if (ConfId === "" && Duration === 0) {
// If missed, we can add a darker pattern
return isOutgoing ?
Qt.darker(JamiTheme.messageOutBgColor, 1.5) :
Qt.lighter(CurrentConversation.color, 1.5) :
Qt.darker(JamiTheme.messageInBgColor, 1.5)
}
return isOutgoing ?
JamiTheme.messageOutBgColor :
CurrentConversation.isCoreDialog ? JamiTheme.messageInBgColor : Qt.lighter(CurrentConversation.color, 1.5)
return isOutgoing ? CurrentConversation.color : JamiTheme.messageInBgColor
}
innerContent.children: [
@ -88,8 +86,13 @@ SBSMessageBase {
return Body
}
horizontalAlignment: Qt.AlignHCenter
font.pointSize: JamiTheme.contactEventPointSize
font.pixelSize: JamiTheme.emojiBubbleSize
font.hintingPreference: Font.PreferNoHinting
font.bold: true
renderType: Text.NativeRendering
textFormat: Text.MarkdownText
color: UtilsAdapter.luma(bubble.color) ?
JamiTheme.chatviewTextColorLight :
JamiTheme.chatviewTextColorDark
@ -115,4 +118,4 @@ SBSMessageBase {
opacity: 0
Behavior on opacity { NumberAnimation { duration: 100 } }
Component.onCompleted: opacity = 1
}
}

View File

@ -1,5 +1,5 @@
/*
* Copyright (C) 2022 Savoir-faire Linux Inc.
* Copyright (C) 2022-2023 Savoir-faire Linux Inc.
* Author: Sébastien Blin <sebastien.blin@savoirfairelinux.com>
*
* This program is free software; you can redistribute it and/or modify
@ -29,11 +29,13 @@ BaseModalDialog {
signal accepted
width: Math.min(mainView.width - 2 * JamiTheme.preferredMarginSize, JamiTheme.preferredDialogWidth)
height: Math.min(mainView.height - 2 * JamiTheme.preferredMarginSize, JamiTheme.preferredDialogHeight)
width: Math.min(appWindow.width - 2 * JamiTheme.preferredMarginSize,
JamiTheme.preferredDialogWidth)
height: Math.min(appWindow.height - 2 * JamiTheme.preferredMarginSize,
JamiTheme.preferredDialogHeight)
property var confirmLabel: ""
property var textLabel: ""
property string confirmLabel: ""
property string textLabel: ""
popupContent: ColumnLayout {
id: column

View File

@ -1,5 +1,5 @@
/*
* Copyright (C) 2022 Savoir-faire Linux Inc.
* Copyright (C) 2022-2023 Savoir-faire Linux Inc.
* Author: Sébastien Blin <sebastien.blin@savoirfairelinux.com>
*
* This program is free software; you can redistribute it and/or modify
@ -39,6 +39,7 @@ Column {
ColumnLayout {
anchors.horizontalCenter: parent.horizontalCenter
width: parent.width
TimestampInfo {
id:timestampItem
@ -56,7 +57,7 @@ Column {
width: childrenRect.width
height: JamiTheme.contactMessageAvatarSize + 12
radius: JamiTheme.contactMessageAvatarSize / 2 + 6
Layout.alignment: Qt.AlignVCenter
Layout.alignment: Qt.AlignCenter
color: "transparent"
border.width: 1
border.color: CurrentConversation.isCoreDialog ? JamiTheme.messageInBgColor : CurrentConversation.color

View File

@ -1,5 +1,5 @@
/*
* Copyright (C) 2020-2022 Savoir-faire Linux Inc.
* Copyright (C) 2020-2023 Savoir-faire Linux Inc.
* Author: Mingrui Zhang <mingrui.zhang@savoirfairelinux.com>
*
* This program is free software; you can redistribute it and/or modify

View File

@ -1,5 +1,5 @@
/*
* Copyright (C) 2020-2022 Savoir-faire Linux Inc.
* Copyright (C) 2020-2023 Savoir-faire Linux Inc.
* Author: Mingrui Zhang <mingrui.zhang@savoirfairelinux.com>
*
* This program is free software; you can redistribute it and/or modify
@ -31,6 +31,26 @@ BaseModalDialog {
autoClose: false
Connections {
target: {
if (Qt.platform.os.toString() !== "windows" && Qt.platform.os.toString() !== "osx")
return DBusErrorHandler
return null
}
ignoreUnknownSignals: true
function onShowDaemonReconnectPopup(visible) {
if (!visible) {
viewCoordinator.dismiss(this)
}
}
function onDaemonReconnectFailed() {
connectionFailed = true
}
}
onPopupContentLoadStatusChanged: {
if (popupContentLoadStatus === Loader.Ready) {
root.height = Qt.binding(function() {

View File

@ -1,5 +1,5 @@
/*
* Copyright (C) 2021-2022 Savoir-faire Linux Inc.
* Copyright (C) 2021-2023 Savoir-faire Linux Inc.
* Author: Trevor Tabah <trevor.tabah@savoirfairelinux.com>
* Author: Andreas Traczyk <andreas.traczyk@savoirfairelinux.com>
* Author: Mingrui Zhang <mingrui.zhang@savoirfairelinux.com>

View File

@ -1,5 +1,5 @@
/*
* Copyright (C) 2020-2022 Savoir-faire Linux Inc.
* Copyright (C) 2020-2023 Savoir-faire Linux Inc.
* Author: Yang Wang <yang.wang@savoirfairelinux.com>
*
* This program is free software; you can redistribute it and/or modify
@ -35,8 +35,8 @@ BaseModalDialog {
title: JamiStrings.deleteAccount
width: Math.min(mainView.width - 2 * JamiTheme.preferredMarginSize, JamiTheme.preferredDialogWidth)
height: Math.min(mainView.height - 2 * JamiTheme.preferredMarginSize, JamiTheme.preferredDialogHeight)
width: Math.min(appWindow.width - 2 * JamiTheme.preferredMarginSize, JamiTheme.preferredDialogWidth)
height: Math.min(appWindow.height - 2 * JamiTheme.preferredMarginSize, JamiTheme.preferredDialogHeight)
popupContent: ColumnLayout {
id: deleteAccountContentColumnLayout

View File

@ -1,5 +1,5 @@
/*
* Copyright (C) 2022 Savoir-faire Linux Inc.
* Copyright (C) 2022-2023 Savoir-faire Linux Inc.
* Author: Sébastien blin <sebastien.blin@savoirfairelinux.com>
* Author: Mingrui Zhang <mingrui.zhang@savoirfairelinux.com>
*

View File

@ -1,5 +1,5 @@
/*
* Copyright (C) 2022 Savoir-faire Linux Inc.
* Copyright (C) 2022-2023 Savoir-faire Linux Inc.
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
@ -95,4 +95,4 @@ BaseModalDialog {
onClicked: close()
}
}
}
}

View File

@ -1,5 +1,5 @@
/*
* Copyright (C) 2020-2022 Savoir-faire Linux Inc.
* Copyright (C) 2020-2023 Savoir-faire Linux Inc.
* Author: Albert Babí <albert.babig@savoirfairelinux.com>
*
* This program is free software; you can redistribute it and/or modify

View File

@ -1,5 +1,5 @@
/*
* Copyright (C) 2022 Savoir-faire Linux Inc.
* Copyright (C) 2022-2023 Savoir-faire Linux Inc.
* Author: Nicolas Vengeon <nicolas.vengeon@savoirfairelinux.com>
*
* This program is free software; you can redistribute it and/or modify

View File

@ -1,5 +1,5 @@
/*
* Copyright (C) 2022 Savoir-faire Linux Inc.
* Copyright (C) 2022-2023 Savoir-faire Linux Inc.
* Author: Nicolas Vengeon <nicolas.vengeon@savoirfairelinux.com>
*
* This program is free software; you can redistribute it and/or modify

View File

@ -1,5 +1,5 @@
/*
* Copyright (C) 2021-2022 Savoir-faire Linux Inc.
* Copyright (C) 2021-2023 Savoir-faire Linux Inc.
* Author: Trevor Tabah <trevor.tabah@savoirfairelinux.com>
* Author: Andreas Traczyk <andreas.traczyk@savoirfairelinux.com>
* Author: Mingrui Zhang <mingrui.zhang@savoirfairelinux.com>

View File

@ -1,5 +1,5 @@
/*
* Copyright (C) 2021-2022 Savoir-faire Linux Inc.
* Copyright (C) 2021-2023 Savoir-faire Linux Inc.
* Author: Andreas Traczyk <andreas.traczyk@savoirfairelinux.com>
*
* This program is free software; you can redistribute it and/or modify

View File

@ -1,5 +1,5 @@
/*
* Copyright (C) 2022 Savoir-faire Linux Inc.
* Copyright (C) 2022-2023 Savoir-faire Linux Inc.
* Author: Fadi Shehadeh <fadi.shehadeh@savoirfairelinux.com>
*
* This program is free software; you can redistribute it and/or modify

View File

@ -1,5 +1,5 @@
/*
* Copyright (C) 2020-2022 Savoir-faire Linux Inc.
* Copyright (C) 2020-2023 Savoir-faire Linux Inc.
* Author: Mingrui Zhang <mingrui.zhang@savoirfairelinux.com>
*
* This program is free software; you can redistribute it and/or modify
@ -27,6 +27,17 @@ FileDialog {
// Use enum to avoid importing Qt.labs.platform when using JamiFileDialog.
property int mode: JamiFileDialog.Mode.OpenFile
signal fileAccepted(string file)
signal filesAccepted(var files)
onAccepted: {
switch(fileMode) {
case FileDialog.OpenFile: fileAccepted(file); break
case FileDialog.OpenFiles: filesAccepted(files); break
default: fileAccepted(file)
}
}
enum Mode {
OpenFile = 0,
OpenFiles,

View File

@ -1,5 +1,5 @@
/*
* Copyright (C) 2020-2022 Savoir-faire Linux Inc.
* Copyright (C) 2020-2023 Savoir-faire Linux Inc.
* Author: Mingrui Zhang <mingrui.zhang@savoirfairelinux.com>
*
* This program is free software; you can redistribute it and/or modify

View File

@ -1,5 +1,5 @@
/*
* Copyright (C) 2019-2022 Savoir-faire Linux Inc.
* Copyright (C) 2019-2023 Savoir-faire Linux Inc.
* Author: Yang Wang <yang.wang@savoirfairelinux.com>
* Author: Mingrui Zhang <mingrui.zhang@savoirfairelinux.com>
*
@ -26,6 +26,8 @@ import net.jami.Models 1.1
ListView {
id: root
property alias verticalScrollBar: verticalScrollBar
layer.mipmap: false
clip: true
maximumFlickVelocity: 1024
@ -36,11 +38,6 @@ ListView {
attachedFlickableMoving: root.moving
}
property bool isScrolling: verticalScrollBar.active
onIsScrollingChanged: {
JamiQmlUtils.isChatviewScrolling = isScrolling
}
Keys.onUpPressed: verticalScrollBar.decrease()
Keys.onDownPressed: verticalScrollBar.increase()
}

Some files were not shown because too many files have changed in this diff Show More