1
0
Fork 0
mirror of https://git.jami.net/savoirfairelinux/jami-client-qt.git synced 2025-08-04 14:55:43 +02:00

ringtones: use qt API to get ringtones path and remove redundant folder

Use qt applicationDirPath to get ringtones path to avoid the complexity
of using windows API, and remove redundant ringtones folder.

Gitlab: #41
Change-Id: I5ae95531fb0e7627cdddb61334420bae3f37848b
This commit is contained in:
Ming Rui Zhang 2020-08-28 15:22:14 -04:00
parent a70e13082f
commit fcc2f41f6b
7 changed files with 1 additions and 30 deletions

View file

@ -1,5 +0,0 @@
ringringtonesdir = $(datadir)/ring/ringtones
dist_ringringtones_DATA = \
konga.ul\
default.wav \
default.opus

Binary file not shown.

View file

@ -1,4 +0,0 @@
Original file name: 171324__swidmark__ringtone.wav
Download location: https://freesound.org/people/swidmark/sounds/171324
Uploader: https://freesound.org/people/swidmark
License: CC0 1.0 Universal (CC0 1.0) (https://creativecommons.org/publicdomain/zero/1.0/)

Binary file not shown.

View file

@ -1,4 +0,0 @@
Original file name: 171324__swidmark__ringtone.wav
Download location: https://freesound.org/people/swidmark/sounds/171324
Uploader: https://freesound.org/people/swidmark
License: CC0 1.0 Universal (CC0 1.0) (https://creativecommons.org/publicdomain/zero/1.0/)

File diff suppressed because one or more lines are too long

View file

@ -197,12 +197,7 @@ QString
Utils::GetRingtonePath() Utils::GetRingtonePath()
{ {
#ifdef Q_OS_WIN #ifdef Q_OS_WIN
TCHAR workingDirectory[MAX_PATH]; return QCoreApplication::applicationDirPath() + "\\ringtones\\default.opus";
GetCurrentDirectory(MAX_PATH, workingDirectory);
QString ringtonePath = QString::fromWCharArray(workingDirectory);
ringtonePath += QStringLiteral("\\ringtones\\default.opus");
return ringtonePath;
#else #else
return QString("/usr/local"); return QString("/usr/local");
#endif #endif