Compare commits

..

5700 Commits

Author SHA1 Message Date
Jonas Kvinge
c435464972 Add visualizations 2025-12-29 00:33:14 +01:00
Strawberry Bot
da2f28811a New translations 2025-12-29 00:02:45 +01:00
Jonas Kvinge
0bfa736081 GstEnginePipeline: Add audioresample elements 2025-12-28 22:01:42 +01:00
Jonas Kvinge
1392bcbbe1 FilesystemMusicStorage: Fallback to delete if moving to trash fails
Fixes #1679
2025-12-28 21:28:49 +01:00
Jonas Kvinge
11705889f1 Show playlist load errors
Fixes #1470
2025-12-28 20:54:36 +01:00
dependabot[bot]
604dd2dbde Bump vmactions/freebsd-vm from 1.3.1 to 1.3.2
Bumps [vmactions/freebsd-vm](https://github.com/vmactions/freebsd-vm) from 1.3.1 to 1.3.2.
- [Release notes](https://github.com/vmactions/freebsd-vm/releases)
- [Commits](https://github.com/vmactions/freebsd-vm/compare/v1.3.1...v1.3.2)

---
updated-dependencies:
- dependency-name: vmactions/freebsd-vm
  dependency-version: 1.3.2
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-12-28 19:00:35 +01:00
Stickman
25065ba98f Song: Include Opus for supported sort tags 2025-12-28 18:57:52 +01:00
Jonas Kvinge
7b16ec62bb Defer playcount and rating tag writes for currently playing Ogg songs
Fixes #1816
2025-12-28 18:33:49 +01:00
Jonas Kvinge
d8f31592b9 Remove settings member variables 2025-12-28 00:39:22 +01:00
Jonas Kvinge
80bb0f476d CollectionModel: Remove sort tags from container keys
Fixes #1899
2025-12-27 21:25:54 +01:00
dependabot[bot]
b7222ac85c Bump vmactions/openbsd-vm from 1.2.8 to 1.2.9
Bumps [vmactions/openbsd-vm](https://github.com/vmactions/openbsd-vm) from 1.2.8 to 1.2.9.
- [Release notes](https://github.com/vmactions/openbsd-vm/releases)
- [Commits](https://github.com/vmactions/openbsd-vm/compare/v1.2.8...v1.2.9)

---
updated-dependencies:
- dependency-name: vmactions/openbsd-vm
  dependency-version: 1.2.9
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-12-27 20:02:32 +01:00
dependabot[bot]
241bca0828 Bump vmactions/openbsd-vm from 1.2.7 to 1.2.8
Bumps [vmactions/openbsd-vm](https://github.com/vmactions/openbsd-vm) from 1.2.7 to 1.2.8.
- [Release notes](https://github.com/vmactions/openbsd-vm/releases)
- [Commits](https://github.com/vmactions/openbsd-vm/compare/v1.2.7...v1.2.8)

---
updated-dependencies:
- dependency-name: vmactions/openbsd-vm
  dependency-version: 1.2.8
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-12-25 19:51:35 +01:00
dependabot[bot]
90d86b10a3 Bump vmactions/freebsd-vm from 1.3.0 to 1.3.1
Bumps [vmactions/freebsd-vm](https://github.com/vmactions/freebsd-vm) from 1.3.0 to 1.3.1.
- [Release notes](https://github.com/vmactions/freebsd-vm/releases)
- [Commits](https://github.com/vmactions/freebsd-vm/compare/v1.3.0...v1.3.1)

---
updated-dependencies:
- dependency-name: vmactions/freebsd-vm
  dependency-version: 1.3.1
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-12-25 16:51:53 +01:00
dependabot[bot]
4130c6670f Bump vmactions/openbsd-vm from 1.2.5 to 1.2.7
Bumps [vmactions/openbsd-vm](https://github.com/vmactions/openbsd-vm) from 1.2.5 to 1.2.7.
- [Release notes](https://github.com/vmactions/openbsd-vm/releases)
- [Commits](https://github.com/vmactions/openbsd-vm/compare/v1.2.5...v1.2.7)

---
updated-dependencies:
- dependency-name: vmactions/openbsd-vm
  dependency-version: 1.2.7
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-12-22 21:10:30 +01:00
Jonas Kvinge
8d262959c1 GstEnginePipeline: Fix buffering issue near track end during gapless playback
Ignore buffering messages when within 5 seconds of track end and about-to-finish has been signaled. This prevents spurious buffering from blocking playback during track transitions with local files.

Fixes #1725
2025-12-20 01:36:49 +01:00
Jonas Kvinge
b9b70399d8 GstEnginePipeline: Fix possible race condition in pipeline destructor
Wait for ongoing state changes to complete before setting pipeline to NULL.
This prevents race conditions with async state transitions that can cause crashes in GStreamer elements.

Fixes #1875
2025-12-20 01:28:53 +01:00
Jonas Kvinge
527ccd212a SmartPlaylistsViewContainer: Ask for confirmation before resetting smart playlists 2025-12-19 01:03:46 +01:00
Jonas Kvinge
4a5afbeb1e SmartPlaylists: Add option to restore smart playlists to the defaults
Fixes #1848
2025-12-19 00:49:05 +01:00
Jonas Kvinge
63c14e014b EditTagDialog: Ignore unused const variables 2025-12-19 00:47:35 +01:00
Jonas Kvinge
801658c6b9 MainWindow: Check that current is the active playlist
Fixes #1783
2025-12-19 00:38:32 +01:00
Jonas Kvinge
16fe665295 TagReaderTagLib: Remove unused constants 2025-12-19 00:35:02 +01:00
Rob Stanfield
2bb0dbada2 Qobuz: Fix authentication and add automatic credential fetching
Qobuz API now requires intent=stream parameter for stream URL requests,
and the app_secret must be extracted using the Spoofbuz decoding method
from bundle.js rather than plain-text values.

Changes:
- Add intent=stream parameter to stream URL requests
- Add QobuzCredentialFetcher class to extract credentials from web player
- Add "Fetch Credentials" button to Qobuz settings page
- Decode obfuscated app secrets using seed/timezone/info/extras method

This fixes "Invalid Request Signature" errors that prevented playback.
2025-12-18 23:12:52 +01:00
Jonas Kvinge
2cd9498469 Add option to select ID3v2 version
Fixes #1861
2025-12-18 22:18:26 +01:00
Jonas Kvinge
d1ee27fff9 QobuzService: Remove QNetworkReply 2025-12-18 20:39:21 +01:00
Jonas Kvinge
91adf5ba32 NetworkAccessManager: Handle network state changes after system suspend/resume
Fixes #1521
2025-12-18 20:32:07 +01:00
Jonas Kvinge
d68f464269 Playlist: Don't automatically sort playlist before it's fully loaded
Fixes #1690
2025-12-18 20:14:36 +01:00
Jonas Kvinge
c684a95f89 GstEnginePipeline: Fix file descriptor exhaustion by using shared thread pool
Replace per-pipeline QThreadPool with a shared static pool to prevent
file descriptor and thread exhaustion. Each GstEnginePipeline was creating
its own thread pool, leading to resource accumulation during frequent
pipeline creation/destruction (track changes, seeking, crossfade).

The shared pool is limited to 2 threads max since state changes are
typically sequential per pipeline. This prevents the crash in g_wakeup_new()
when creating eventfd for new thread event dispatchers.

Fixes #1687
2025-12-18 19:58:23 +01:00
copilot-swe-agent[bot]
1d03bb2178 GstEnginePipeline: Fix crash in GStreamer decodebin3 when switching tracks
Add guard in AboutToFinishCallback to prevent race condition when pipeline is being torn down. This prevents the callback from trying to set next URL while the pipeline is being destroyed, which caused crashes in GStreamer's decodebin3.

Fixes issue where rapidly switching tracks could cause segmentation fault in gst_decodebin_input_link_to_slot.

See: https://gitlab.freedesktop.org/gstreamer/gstreamer/-/issues/4626

Fixes #1863

Co-Authored-By: Jonas Kvinge <jonas@jkvinge.net>
2025-12-18 19:44:03 +01:00
Jonas Kvinge
39f9128ecf gitignore: Add _codeql_detected_source_root 2025-12-18 19:39:10 +01:00
Jonas Kvinge
ca2e802239 GstEngine: Make sure device is set for pipeline
Fixes #1852
2025-12-18 00:21:00 +01:00
Jonas Kvinge
9a513a9a56 AutoExpandingTreeView: Scroll if cursor is out of visible area
Fixes #1489
2025-12-17 23:14:57 +01:00
Jonas Kvinge
1c2e87b741 Organize: Skip existing files if not overwriting
Fixes #1484
2025-12-17 22:58:17 +01:00
Jonas Kvinge
fe4d9979ce CollectionWatcher: Avoid re-scan of restored songs unless mtime is changed
Fixes #1819
2025-12-17 22:15:21 +01:00
Jonas Kvinge
d8ae790ebf Turn on git revision 2025-12-17 01:05:45 +01:00
Jonas Kvinge
ac31d79294 Release 1.2.16 2025-12-17 00:08:06 +01:00
Jonas Kvinge
4ffebd77b1 Update Changelog 2025-12-17 00:07:41 +01:00
Strawberry Bot
6682efae2f New translations 2025-12-16 22:41:10 +01:00
Jonas Kvinge
480161c6b7 Update Changelog 2025-12-16 22:38:55 +01:00
Jonas Kvinge
a8ba420d72 ErrorDialog: Use QApplication::activeWindow 2025-12-16 22:32:11 +01:00
dependabot[bot]
fc0ec91652 Bump actions/download-artifact from 6 to 7
Bumps [actions/download-artifact](https://github.com/actions/download-artifact) from 6 to 7.
- [Release notes](https://github.com/actions/download-artifact/releases)
- [Commits](https://github.com/actions/download-artifact/compare/v6...v7)

---
updated-dependencies:
- dependency-name: actions/download-artifact
  dependency-version: '7'
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-12-15 18:15:02 +01:00
dependabot[bot]
0701b97324 Bump actions/upload-artifact from 5 to 6
Bumps [actions/upload-artifact](https://github.com/actions/upload-artifact) from 5 to 6.
- [Release notes](https://github.com/actions/upload-artifact/releases)
- [Commits](https://github.com/actions/upload-artifact/compare/v5...v6)

---
updated-dependencies:
- dependency-name: actions/upload-artifact
  dependency-version: '6'
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-12-15 18:14:44 +01:00
Jonas Kvinge
3867932e1e PlaylistView: Don't automatically scroll on dynamic playlists
Fixes #1427
2025-12-14 04:55:20 +01:00
Jonas Kvinge
e2907f6051 PlaylistView: Use Qt::CopyAction for drag
Fixes #1815
2025-12-14 04:41:58 +01:00
Jonas Kvinge
0827ec7f16 PlaylistSequence: Fix icon size
Fixes #1838
2025-12-14 04:28:25 +01:00
Jonas Kvinge
24d2adf363 PlaylistView: Set current index when automatically selecting track
Fixes #1825
2025-12-14 04:02:40 +01:00
Jonas Kvinge
592729d00b SliderSlider: Use SC_SliderGroove
Fixes #1675
2025-12-14 01:57:47 +01:00
Jonas Kvinge
c4a564bb56 NetworkAccessManager: Use full application name for user agent 2025-12-14 01:36:53 +01:00
Jonas Kvinge
812a02a3a1 Update Changelog 2025-12-14 01:04:45 +01:00
Strawberry Bot
944936914b New translations 2025-12-14 01:01:06 +01:00
Jonas Kvinge
e7c901d4f3 Update Changelog 2025-12-14 00:59:42 +01:00
Jonas Kvinge
8e996119af Make using sort tags optional 2025-12-14 00:52:19 +01:00
Jonas Kvinge
4348a654ca TagReaderResult: Fix file save error message 2025-12-14 00:52:19 +01:00
dependabot[bot]
f0be1c782a Bump vmactions/openbsd-vm from 1.2.4 to 1.2.5
Bumps [vmactions/openbsd-vm](https://github.com/vmactions/openbsd-vm) from 1.2.4 to 1.2.5.
- [Release notes](https://github.com/vmactions/openbsd-vm/releases)
- [Commits](https://github.com/vmactions/openbsd-vm/compare/v1.2.4...v1.2.5)

---
updated-dependencies:
- dependency-name: vmactions/openbsd-vm
  dependency-version: 1.2.5
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-12-11 00:36:57 +01:00
dependabot[bot]
e9898d08bc Bump vmactions/freebsd-vm from 1.2.9 to 1.3.0
Bumps [vmactions/freebsd-vm](https://github.com/vmactions/freebsd-vm) from 1.2.9 to 1.3.0.
- [Release notes](https://github.com/vmactions/freebsd-vm/releases)
- [Commits](https://github.com/vmactions/freebsd-vm/compare/v1.2.9...v1.3.0)

---
updated-dependencies:
- dependency-name: vmactions/freebsd-vm
  dependency-version: 1.3.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-12-11 00:36:24 +01:00
Jonas Kvinge
1ad13cd3b0 Add lyrics from lrclib.net 2025-12-09 18:45:57 +01:00
Jonas Kvinge
5c640e0e36 LyricsFetcherSearch: Improve handling timeout 2025-12-09 18:41:55 +01:00
Jonas Kvinge
059def8d0c Add duration to lyrics search request 2025-12-09 18:40:45 +01:00
Jonas Kvinge
cf15a1f423 CDDALister: Add Q_UNUSED 2025-12-09 01:33:13 +01:00
Jonas Kvinge
5d35b0eedd BlockAnalyzer: Formatting 2025-12-09 01:19:02 +01:00
Jonas Kvinge
5fcb71d08f Formatting 2025-12-09 01:16:41 +01:00
Jonas Kvinge
15c2237d4a AlbumCoverChoiceController: Fix incorrectly formatted switch 2025-12-08 23:55:13 +01:00
Jonas Kvinge
93af866185 Formatting 2025-12-08 23:49:48 +01:00
dependabot[bot]
109ff90401 Bump vmactions/freebsd-vm from 1.2.8 to 1.2.9
Bumps [vmactions/freebsd-vm](https://github.com/vmactions/freebsd-vm) from 1.2.8 to 1.2.9.
- [Release notes](https://github.com/vmactions/freebsd-vm/releases)
- [Commits](https://github.com/vmactions/freebsd-vm/compare/v1.2.8...v1.2.9)

---
updated-dependencies:
- dependency-name: vmactions/freebsd-vm
  dependency-version: 1.2.9
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-12-08 17:11:17 +01:00
Jonas Kvinge
d4b06289c3 clang-format: Add new KeepEmptyLines option 2025-12-07 01:20:39 +01:00
dependabot[bot]
4351c555a0 Bump apple-actions/import-codesign-certs from 5 to 6
Bumps [apple-actions/import-codesign-certs](https://github.com/apple-actions/import-codesign-certs) from 5 to 6.
- [Release notes](https://github.com/apple-actions/import-codesign-certs/releases)
- [Commits](https://github.com/apple-actions/import-codesign-certs/compare/v5...v6)

---
updated-dependencies:
- dependency-name: apple-actions/import-codesign-certs
  dependency-version: '6'
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-12-07 00:51:50 +01:00
Strawberry Bot
ce4db40983 New translations 2025-12-07 00:06:44 +01:00
Jonas Kvinge
d37fb7410c ResizableTextEdit: Set word wrap 2025-12-01 23:23:23 +01:00
Jonas Kvinge
f1cdd71494 ResizableTextEdit: Move updateGeometry after resize 2025-12-01 23:23:05 +01:00
Jonas Kvinge
000ba997fb Playlist: Preserve track order in album shuffle mode
Fixes #1623
2025-12-01 22:47:12 +01:00
dependabot[bot]
579efffd14 Bump vmactions/openbsd-vm from 1.2.3 to 1.2.4
Bumps [vmactions/openbsd-vm](https://github.com/vmactions/openbsd-vm) from 1.2.3 to 1.2.4.
- [Release notes](https://github.com/vmactions/openbsd-vm/releases)
- [Commits](https://github.com/vmactions/openbsd-vm/compare/v1.2.3...v1.2.4)

---
updated-dependencies:
- dependency-name: vmactions/openbsd-vm
  dependency-version: 1.2.4
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-12-01 19:47:08 +01:00
dependabot[bot]
3a098c8a0c Bump vmactions/freebsd-vm from 1.2.7 to 1.2.8
Bumps [vmactions/freebsd-vm](https://github.com/vmactions/freebsd-vm) from 1.2.7 to 1.2.8.
- [Release notes](https://github.com/vmactions/freebsd-vm/releases)
- [Commits](https://github.com/vmactions/freebsd-vm/compare/v1.2.7...v1.2.8)

---
updated-dependencies:
- dependency-name: vmactions/freebsd-vm
  dependency-version: 1.2.8
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-12-01 18:46:03 +01:00
bastimeyer
5bce0ae87f GlobalShortcutsBackendKGlobalAccel: Add globalShortcutRepeated signal 2025-11-30 18:25:26 +01:00
Jonas Kvinge
afe6967c46 GstEnginePipeline: Handle "missing-plugin" messages 2025-11-30 18:13:30 +01:00
Jonas Kvinge
e91bab6d42 GstEngine: Only emit error for debugstr if it's set 2025-11-30 18:13:30 +01:00
Jonas Kvinge
5a64247761 PlaylistView: Use lamda in sort 2025-11-30 16:58:08 +01:00
Jonas Kvinge
9ed89afdb2 SpotifyService: Use 127.0.0.1 in redirect URL 2025-11-30 16:32:56 +01:00
Jonas Kvinge
0ac338026c About: Update sponsor info 2025-11-30 02:47:39 +01:00
Jonas Kvinge
4e5f84a7b7 RichPresence: Use pretty title 2025-11-26 19:14:16 +01:00
Jonas Kvinge
320a3c6815 RichPresence: Add copyright 2025-11-26 19:14:05 +01:00
Jonas Kvinge
72dd1d783a Turn on git revision 2025-11-25 21:13:00 +01:00
Jonas Kvinge
d2205cfe81 Release 1.2.15 2025-11-25 02:50:34 +01:00
Jonas Kvinge
5830f247f6 Update Changelog 2025-11-25 02:05:26 +01:00
Jonas Kvinge
8b4c57d933 GroupedIconView: Remove deprecated QStyle::State_Editing 2025-11-23 03:14:57 +01:00
Jonas Kvinge
67cec09176 gitignore: Add .qtcreator 2025-11-23 03:14:24 +01:00
Jonas Kvinge
2df658e1f3 ListenBrainzScrobbler: Ignore connection closed 2025-11-23 01:11:59 +01:00
Jonas Kvinge
f3bc9b151c README: Update OBS URL's 2025-11-23 00:47:56 +01:00
Jonas Kvinge
b06b59d0c5 nsi: Bump ffmpeg for msvc x86_64 2025-11-22 14:20:40 +01:00
Jonas Kvinge
99d75ade06 CI: Bump MSVC SDK version 2025-11-22 02:15:20 +01:00
Jonas Kvinge
3f63246068 Add macos-15-intel runner 2025-11-22 00:47:30 +01:00
dependabot[bot]
b205a5f964 Bump actions/checkout from 5 to 6
Bumps [actions/checkout](https://github.com/actions/checkout) from 5 to 6.
- [Release notes](https://github.com/actions/checkout/releases)
- [Changelog](https://github.com/actions/checkout/blob/main/CHANGELOG.md)
- [Commits](https://github.com/actions/checkout/compare/v5...v6)

---
updated-dependencies:
- dependency-name: actions/checkout
  dependency-version: '6'
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-11-21 19:46:25 +01:00
dependabot[bot]
aeaef12dd4 Bump vmactions/freebsd-vm from 1.2.6 to 1.2.7
Bumps [vmactions/freebsd-vm](https://github.com/vmactions/freebsd-vm) from 1.2.6 to 1.2.7.
- [Release notes](https://github.com/vmactions/freebsd-vm/releases)
- [Commits](https://github.com/vmactions/freebsd-vm/compare/v1.2.6...v1.2.7)

---
updated-dependencies:
- dependency-name: vmactions/freebsd-vm
  dependency-version: 1.2.7
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-11-21 19:45:43 +01:00
Jonas Kvinge
02d76f17f7 CollectionModel: Make SortText static 2025-11-15 22:10:55 +01:00
Strawberry Bot
e4e12c6fa6 New translations 2025-11-13 23:25:27 +01:00
uninstall-your-browser
270ae6085b FilterParser: Convert number to nanoseconds for length filter 2025-11-13 23:23:19 +01:00
Jonas Kvinge
7065a405a5 CI: Remove macos-13 2025-11-12 01:10:19 +01:00
Jonas Kvinge
d8c72c3dd9 ParserBase: Remove use of QString::removeFirst 2025-11-11 21:37:19 +01:00
Jonas Kvinge
b65502e167 XSPFParser: Handle platform and url 2025-11-11 00:56:36 +01:00
Jonas Kvinge
132f8df853 ParserBase: Convert spotify URLs 2025-11-11 00:56:13 +01:00
Jonas Kvinge
12e3cffe63 CI: Fix ssh command 2025-11-10 20:43:09 +01:00
dependabot[bot]
56a637682d Bump vmactions/freebsd-vm from 1.2.5 to 1.2.6
Bumps [vmactions/freebsd-vm](https://github.com/vmactions/freebsd-vm) from 1.2.5 to 1.2.6.
- [Release notes](https://github.com/vmactions/freebsd-vm/releases)
- [Commits](https://github.com/vmactions/freebsd-vm/compare/v1.2.5...v1.2.6)

---
updated-dependencies:
- dependency-name: vmactions/freebsd-vm
  dependency-version: 1.2.6
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-11-10 20:01:38 +01:00
dependabot[bot]
d9b105f89e Bump vmactions/openbsd-vm from 1.2.2 to 1.2.3
Bumps [vmactions/openbsd-vm](https://github.com/vmactions/openbsd-vm) from 1.2.2 to 1.2.3.
- [Release notes](https://github.com/vmactions/openbsd-vm/releases)
- [Commits](https://github.com/vmactions/openbsd-vm/compare/v1.2.2...v1.2.3)

---
updated-dependencies:
- dependency-name: vmactions/openbsd-vm
  dependency-version: 1.2.3
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-11-10 17:26:57 +01:00
dependabot[bot]
bd6b45e43f Bump vmactions/freebsd-vm from 1.2.4 to 1.2.5
Bumps [vmactions/freebsd-vm](https://github.com/vmactions/freebsd-vm) from 1.2.4 to 1.2.5.
- [Release notes](https://github.com/vmactions/freebsd-vm/releases)
- [Commits](https://github.com/vmactions/freebsd-vm/compare/v1.2.4...v1.2.5)

---
updated-dependencies:
- dependency-name: vmactions/freebsd-vm
  dependency-version: 1.2.5
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-11-03 18:54:16 +01:00
dependabot[bot]
539172fb70 Bump vmactions/openbsd-vm from 1.2.1 to 1.2.2
Bumps [vmactions/openbsd-vm](https://github.com/vmactions/openbsd-vm) from 1.2.1 to 1.2.2.
- [Release notes](https://github.com/vmactions/openbsd-vm/releases)
- [Commits](https://github.com/vmactions/openbsd-vm/compare/v1.2.1...v1.2.2)

---
updated-dependencies:
- dependency-name: vmactions/openbsd-vm
  dependency-version: 1.2.2
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-11-03 18:11:33 +01:00
Jonas Kvinge
ebd92b3a7f nsi: Bump ffmpeg 2025-11-01 12:22:43 +01:00
Jonas Kvinge
b00ae5b210 nsi: Bump icu 2025-10-31 23:47:49 +01:00
Jonas Kvinge
c8e3cf981b main: Try different language codes for QtSparkle 2025-10-31 23:06:00 +01:00
Jonas Kvinge
038f69779f CI: Manually codesign libbrotli 2025-10-30 23:56:17 +01:00
Jonas Kvinge
a4de7559ac Fix loading language from system UI languages
Fixes #1847
2025-10-30 23:54:42 +01:00
dependabot[bot]
0537b072fe Bump actions/download-artifact from 5 to 6
Bumps [actions/download-artifact](https://github.com/actions/download-artifact) from 5 to 6.
- [Release notes](https://github.com/actions/download-artifact/releases)
- [Commits](https://github.com/actions/download-artifact/compare/v5...v6)

---
updated-dependencies:
- dependency-name: actions/download-artifact
  dependency-version: '6'
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-10-30 01:36:11 +01:00
dependabot[bot]
2657c9f96a Bump actions/upload-artifact from 4 to 5
Bumps [actions/upload-artifact](https://github.com/actions/upload-artifact) from 4 to 5.
- [Release notes](https://github.com/actions/upload-artifact/releases)
- [Commits](https://github.com/actions/upload-artifact/compare/v4...v5)

---
updated-dependencies:
- dependency-name: actions/upload-artifact
  dependency-version: '5'
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-10-30 01:35:56 +01:00
Jonas Kvinge
7e178b1f1a PlaylistView: Always keep EditKeyPressed 2025-10-30 01:35:30 +01:00
Jonas Kvinge
dd8513d02c PlaylistView: Disable EditKeyPressed when inline metadata editing is disabled 2025-10-27 20:19:50 +01:00
Andrew Tribick
5f0175094b Support unofficial::getopt-win32::getopt as a getopt library target
Handles the vcpkg case
2025-10-26 13:06:11 +01:00
Jonas Kvinge
b4c5b9e1e1 Turn on git revision 2025-10-26 13:05:56 +01:00
Jonas Kvinge
2ce0ed2ef8 Release 1.2.14 2025-10-25 23:03:51 +02:00
dependabot[bot]
176768f7f8 Bump vmactions/openbsd-vm from 1.2.0 to 1.2.1
Bumps [vmactions/openbsd-vm](https://github.com/vmactions/openbsd-vm) from 1.2.0 to 1.2.1.
- [Release notes](https://github.com/vmactions/openbsd-vm/releases)
- [Commits](https://github.com/vmactions/openbsd-vm/compare/v1.2.0...v1.2.1)

---
updated-dependencies:
- dependency-name: vmactions/openbsd-vm
  dependency-version: 1.2.1
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-10-25 02:03:03 +02:00
Jonas Kvinge
50b954034c OpenTidalCoverProvider: Check for already finished 2025-10-23 00:39:40 +02:00
Jonas Kvinge
cab7b6c335 Update Changelog 2025-10-23 00:34:46 +02:00
Jonas Kvinge
fce1dacafc OpenTidalCoverProvider: Adapt to new API 2025-10-23 00:34:06 +02:00
Jonas Kvinge
94aa6fb940 MusicBrainzClient: Add missing clear 2025-10-22 20:44:22 +02:00
Jonas Kvinge
0cfd4aaad1 Update Changelog 2025-10-22 20:29:54 +02:00
Strawberry Bot
9e72b4fe80 New translations strawberry_en_us.ts (Swedish) 2025-10-20 21:28:23 +02:00
Jiří Pinkava
1151443372 Add support to play webm media files 2025-10-20 21:28:00 +02:00
Jonas Kvinge
8f6993e7c8 nsi: Add libgstwasapi2 for mingw 2025-10-20 20:39:38 +02:00
Jonas Kvinge
a6ab1a7689 GstEngine: Enable exclusive mode for wasapi2sink 2025-10-19 19:09:49 +02:00
Jonas Kvinge
098b21d818 Use MMDeviceFinder for wasapi2sink 2025-10-19 18:32:42 +02:00
Jonas Kvinge
d61adeb595 Add option not to remove "Remastered", etc from song titles 2025-10-18 19:57:38 +02:00
Cesar Enrique Garcia Dabo
8bfc3bc41c SubsonicRequest: Use coverArt from album 2025-10-08 21:49:04 +02:00
Jonas Kvinge
0dda2feec3 Improve README.md 2025-10-06 00:17:29 +02:00
Jonas Kvinge
1d0d03ed83 Rewrite MusicBrainzClient
Use Json instead of XML, make Disc ID requests respect rate limiting, handle sort names.
2025-10-05 21:42:14 +02:00
Jonas Kvinge
330284f03e CollectionModel: Log when song already exists 2025-10-05 21:33:41 +02:00
Jonas Kvinge
fc3ed3a2ce CollectionModel: Avoid duplicate resets 2025-10-05 21:33:22 +02:00
dependabot[bot]
6a656036fe Bump vmactions/freebsd-vm from 1.2.3 to 1.2.4
Bumps [vmactions/freebsd-vm](https://github.com/vmactions/freebsd-vm) from 1.2.3 to 1.2.4.
- [Release notes](https://github.com/vmactions/freebsd-vm/releases)
- [Commits](https://github.com/vmactions/freebsd-vm/compare/v1.2.3...v1.2.4)

---
updated-dependencies:
- dependency-name: vmactions/freebsd-vm
  dependency-version: 1.2.4
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-09-22 18:26:55 +02:00
Jonas Kvinge
5c76c633a5 CI: Use copydlldeps for msvc arm64 too 2025-09-21 20:59:16 +02:00
Jonas Kvinge
d487c3ea07 nsi: Remove gstwinrt-1.0-0.dll 2025-09-21 20:58:39 +02:00
Jonas Kvinge
83dca405af CI: Remove copy of liblzma.dll 2025-09-19 21:29:34 +02:00
Strawberry Bot
acd0b6d3ea New translations 2025-09-19 20:43:20 +02:00
Jonas Kvinge
159242aff4 nsi: Remove liblzma.dll 2025-09-19 01:51:28 +02:00
Jonas Kvinge
4b014253cf Remove libre.fm 2025-09-18 00:22:11 +02:00
Jonas Kvinge
1ec6b5582e nsi: Move files 2025-09-12 22:02:39 +02:00
Jonas Kvinge
08b8d04500 nsi: Use gnutls with static deps 2025-09-12 21:28:49 +02:00
7xnl
54679b1d57 discord: fixed timestamp update when seeking
When seeking in a song, `RichPresence::Seeked()` receives the new
position in microseconds and is supposed to update the RPC timestamp
with the new position in seconds. However, it actually converts the
value to milliseconds, meaning that if, for example, you seek to 0:05 in
a song, Discord will think you seeked to 83:20, or 5000 seconds from the
beginning of the song.

This commit fixes this by simply dividing the microseconds value by one
million instead of one thousand.
2025-09-11 23:40:40 +02:00
Jonas Kvinge
8d648e668e nsi: Update to new MSVC gnutls dependencies 2025-09-10 18:30:51 +02:00
Jonas Kvinge
5897e786dc Remove unused macversion script 2025-09-08 22:06:32 +02:00
Jonas Kvinge
7f549aa991 CI: Fix ssh command for MSVC rsync 2025-09-07 17:08:19 +02:00
Jonas Kvinge
792e7b6274 BackendSettingsPage: Remove unused errordialog.h include 2025-09-07 16:46:41 +02:00
Jonas Kvinge
92c58b0b60 Fix showing error dialog minimized when main window is not active
Fixes #1739
2025-09-07 15:46:26 +02:00
Jonas Kvinge
5fac9a1c8d BackendSettingsPage: Remove unused ErrorDialog 2025-09-07 14:22:42 +02:00
Jonas Kvinge
7f4f715003 ContextView: Remove EBU R 128
It breaks wordwrap
2025-09-07 13:53:59 +02:00
Jonas Kvinge
75d1d4098e CI: Install KDSingleApplication on Ubuntu 2025-09-01 23:50:16 +02:00
Jonas Kvinge
30e80068a3 CI: Add Ubuntu Questing 2025-09-01 23:49:50 +02:00
Jonas Kvinge
5fe9a1528f CI: Only build KDSingleApplication on bookworm 2025-09-01 23:45:49 +02:00
Jonas Kvinge
7777eda115 CI: Add Debian Forky 2025-09-01 23:45:17 +02:00
Jonas Kvinge
ce4f2ece93 CI: Add openSUSE Leap 16.0 2025-09-01 21:36:46 +02:00
Strawberry Bot
52399d73fe New translations 2025-09-01 00:27:28 +02:00
Jonas Kvinge
6e98166148 Turn on git revision 2025-09-01 00:26:22 +02:00
Jonas Kvinge
c658a77b05 Release 1.2.13 2025-08-31 22:33:48 +02:00
Jonas Kvinge
1880dc8153 Update Changelog 2025-08-31 22:27:00 +02:00
7xnl
b5fd3d5717 Add settings customize Discord status text
The new settings let you customize the "Listening to" status text, according to the [status display types](https://discord.com/developers/docs/events/gateway-events#activity-object).

Fixes #1796.
2025-08-31 22:11:59 +02:00
Jonas Kvinge
3c3480fb84 SystemTrayIcon: Respect device aspect ratio
Fixes #1782
2025-08-31 02:34:13 +02:00
Jonas Kvinge
f628914173 MainWindow: Rename systemtrayicon 2025-08-31 00:37:09 +02:00
Jonas Kvinge
c100fb1bb8 TagReaderTagLib: Fallback to "Other" cover type
Fixes #1793
2025-08-31 00:20:00 +02:00
Jonas Kvinge
8c804c4fba Refactor CDDA loading signal/slots
Fixes #1803
2025-08-31 00:01:55 +02:00
Jonas Kvinge
912a7c7da9 MusicBrainzClient: Fix typo 2025-08-30 23:55:27 +02:00
Jonas Kvinge
0a5815c82e StyleSheetLoader: Set alpha on other platforms than macOS
Fixes #1806
2025-08-26 22:48:58 +02:00
Jonas Kvinge
6513b3032b CMake: Check additional names for getopt 2025-08-24 22:36:13 +02:00
Jonas Kvinge
8c51401bdc MacOsDeviceLister: Fix build without MTP
Fixes #1804
2025-08-24 01:28:22 +02:00
dependabot[bot]
45fc9c83d4 Bump vmactions/openbsd-vm from 1.1.8 to 1.2.0
Bumps [vmactions/openbsd-vm](https://github.com/vmactions/openbsd-vm) from 1.1.8 to 1.2.0.
- [Release notes](https://github.com/vmactions/openbsd-vm/releases)
- [Commits](https://github.com/vmactions/openbsd-vm/compare/v1.1.8...v1.2.0)

---
updated-dependencies:
- dependency-name: vmactions/openbsd-vm
  dependency-version: 1.2.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-08-20 23:57:47 +02:00
dependabot[bot]
be57d8147a Bump vmactions/freebsd-vm from 1.2.1 to 1.2.3
Bumps [vmactions/freebsd-vm](https://github.com/vmactions/freebsd-vm) from 1.2.1 to 1.2.3.
- [Release notes](https://github.com/vmactions/freebsd-vm/releases)
- [Commits](https://github.com/vmactions/freebsd-vm/compare/v1.2.1...v1.2.3)

---
updated-dependencies:
- dependency-name: vmactions/freebsd-vm
  dependency-version: 1.2.3
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-08-19 18:25:13 +02:00
Jonas Kvinge
a97908fb6b CI: Bump msvc sdk 2025-08-17 13:44:57 +02:00
Lars Wendler
c0417d4bb3 cdda: fix build without musicbrainz
With -DENABLE_MUSICBRAINZ=NO the following build error occurs since 1.2.12:

/var/tmp/portage/media-sound/strawberry-1.2.12_pre/work/strawberry-1.2.12/src/de
vice/cddasongloader.cpp:58:91: error: ‘LoadMusicBrainzCDTags’ is not a member of
 ‘CDDASongLoader’
   58 |   QObject::connect(this, &CDDASongLoader::MusicBrainzDiscIdLoaded, this,
 &CDDASongLoader::LoadMusicBrainzCDTags);
      |
                  ^~~~~~~~~~~~~~~~~~~~~
2025-08-13 19:49:41 +02:00
Jonas Kvinge
062e2cfb84 Turn on git revision 2025-08-13 00:20:05 +02:00
Jonas Kvinge
700f7dbe36 Release 1.2.12 2025-08-12 22:57:10 +02:00
Jonas Kvinge
0487118dad Update Changelog 2025-08-12 22:54:54 +02:00
Jonas Kvinge
f3d088e48b Rename sort functions 2025-08-12 22:14:22 +02:00
Jonas Kvinge
f8afd49fcf Update Changelog 2025-08-12 01:46:46 +02:00
dependabot[bot]
363fcb5aba Bump actions/checkout from 4 to 5
Bumps [actions/checkout](https://github.com/actions/checkout) from 4 to 5.
- [Release notes](https://github.com/actions/checkout/releases)
- [Changelog](https://github.com/actions/checkout/blob/main/CHANGELOG.md)
- [Commits](https://github.com/actions/checkout/compare/v4...v5)

---
updated-dependencies:
- dependency-name: actions/checkout
  dependency-version: '5'
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-08-11 22:52:06 +02:00
Jonas Kvinge
183aba4181 main: Workaround crash on exit on mingw with win32 threads 2025-08-10 22:41:38 +02:00
Jonas Kvinge
742be01aa6 nsi: Add /norestart to vc redist install 2025-08-10 18:34:12 +02:00
Jonas Kvinge
38c8054873 nsi: Only include gstwinrt-1.0-0.dll on arm64 2025-08-10 02:13:44 +02:00
Jonas Kvinge
da9e9840b8 Add BPM, mood and initial key support 2025-08-10 01:34:44 +02:00
Jonas Kvinge
c4646531b0 Refactor use of sort tags 2025-08-10 00:11:28 +02:00
dependabot[bot]
65d9b6a9e9 Bump actions/download-artifact from 4 to 5
Bumps [actions/download-artifact](https://github.com/actions/download-artifact) from 4 to 5.
- [Release notes](https://github.com/actions/download-artifact/releases)
- [Commits](https://github.com/actions/download-artifact/compare/v4...v5)

---
updated-dependencies:
- dependency-name: actions/download-artifact
  dependency-version: '5'
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-08-06 23:31:07 +02:00
Jonas Kvinge
046f40fbca CollectionModel: Remove const reference on SortBehaviour enum 2025-08-04 22:54:18 +02:00
Strawberry Bot
a0ca50ac30 New translations 2025-08-04 22:43:33 +02:00
Jonas Kvinge
d939733675 CI: Remove Ubuntu oracular 2025-08-04 22:42:13 +02:00
Mark
61a8a3a84a SmartPlaylists: Add sort fields 2025-08-04 22:24:50 +02:00
Mark
d4858a338c Propose collection rescan on upgrade 2025-08-04 22:24:21 +02:00
Mark
31380a5bd4 CDDASongLoader: Add sort tags 2025-08-04 22:24:12 +02:00
Mark
e45b9aabeb Add sort tags to context view 2025-08-04 22:23:52 +02:00
Mark
27e782d8cf Allow editing new sort tags 2025-08-04 22:23:33 +02:00
Mark
0bfc2ee198 Add sort columns to playlists
Increment playlist state version from 1 to 2 to get sort columns next to
their "original" column. Discard old stored playlist state in config file.
2025-08-04 22:23:19 +02:00
Mark
e7fc4b1706 Collection: Use sort tags and add sort behaviour 2025-08-04 22:21:49 +02:00
Mark
6dea1a2149 Add support for sort tags 2025-08-04 22:21:33 +02:00
Jonas Kvinge
7844a2b932 Update Spotify access token
Fixes #1769
2025-08-04 22:11:44 +02:00
Jonas Kvinge
96a53bfbe5 SavedGroupingManager: Fix removing saved grouping 2025-07-30 00:47:54 +02:00
Jonas Kvinge
fe5fbae4b4 Use percent encoding for saved groupings
Fixes #1758
2025-07-30 00:41:12 +02:00
Jonas Kvinge
a9140232e5 Add workaround for QTBUG-135641
Fixes #1594
2025-07-29 23:42:38 +02:00
Jonas Kvinge
835090dd96 RichPresence: Disable Discord desktop file creation
Fixes #1771
2025-07-29 00:45:36 +02:00
Jonas Kvinge
af5590dcb1 NetworkAccessManager: Fix setting prefer cache setting 2025-07-28 22:40:26 +02:00
Jonas Kvinge
26b5588d7d NetworkAccessManager: Rename variables 2025-07-28 22:39:32 +02:00
Jonas Kvinge
390bf049f2 Don't set window icon on Wayland
Fixes #1753
2025-07-27 14:40:01 +02:00
Jonas Kvinge
321272b695 MainWindow: Remove hard-coded icon 2025-07-27 14:39:22 +02:00
Jonas Kvinge
342805e0f3 MainWindow: Automatically added UI changes 2025-07-27 14:39:05 +02:00
Jonas Kvinge
e614626913 TidalStreamURLRequest: Fix parsing manifest urls 2025-07-19 21:38:55 +02:00
Mark
2ddacf2f98 Database: Add *sort fields, bpm, mood, initial_key
Upgrade from schema version 20 to 21. This includes:

- six fields for sort tags
- new fields bpm, mood, initial_key

See https://github.com/strawberrymusicplayer/strawberry/pull/1779#pullrequestreview-3003042802
2025-07-12 18:27:32 +02:00
Jonas Kvinge
a47531d4ce Database: Remove FTS hack 2025-07-09 22:45:52 +02:00
Jonas Kvinge
84b758e395 README: Fix broken md link 2025-07-09 22:37:52 +02:00
Jonas Kvinge
51b69a85c4 GeniusLyricsProvider: Remove unused includes 2025-07-09 22:35:47 +02:00
Jonas Kvinge
52774a3222 ChartLyricsProvider: Fix empty results 2025-07-09 22:34:35 +02:00
gitlost
9030b2567b GeniusLyrics: update to parse latest HTML of returned lyrics,
devolving the removal of various crud to `HtmlLyricsProvider`;
  log initial query and use new `StartsOrEndsMatch()` static to
  match JSON replies, log each request, and break if full match;
  `StartsOrEndsMatch()` ignores some common punctuation variations
   & normalizes single quotes and allows match at beginning or end
HtmlLyricsProvider: fix `multiple` mode not to terminate on first
  batch, and defer processing till have whole HTML (avoids issues
  with tags spanning batches);
  add param to take list of regular expressions to remove from HTML
  prior to general processing (used only by `GeniusLyrics` for now)
README.md etc: update list of lyrics providers supported
2025-07-09 22:32:17 +02:00
gitlost
ee7bb449a5 Revert: Remove Genius lyrics [d9e38fb] 2025-07-09 22:32:17 +02:00
Madeline Schreiber
d901258f11 GstEnginePipeline: Ignore about-to-finish when position is 0 2025-07-07 01:05:47 +02:00
Madeline Schreiber
6372c5ee7d TagReaderClient: Call TagReaderGME when reading files 2025-07-07 01:05:47 +02:00
Madeline Schreiber
75f0402793 Add space to fix broken file filters 2025-07-04 17:25:34 -04:00
Ty
20e5c014ef PlaylistView: support alpha channel in background images 2025-07-04 20:42:32 +02:00
Strawberry Bot
1ebc32c3aa New translations 2025-07-03 21:06:02 +02:00
Piper McCorkle
a5f94b608b ListenBrainzScrobbler: Report more info to ListenBrainz
Report music service, URL, and Spotify ID to ListenBrainz.
ListenBrainz accepts the music service in listen reports, in both a canonical domain format and a human-readable display name format. This commit makes Strawberry report both, for maximum flexibility. I've also set it up to report a shareable track URL for supported streaming services. I am already using this data in my homepage's "Now Playing" widget.

Fixes #1768
2025-06-30 22:54:51 +02:00
Jonas Kvinge
e0d61223a4 CDDASongLoader: Fix freeing tag 2025-06-30 20:04:39 +02:00
Jonas Kvinge
459eea5bc4 FreeSpaceBar: Make sure bar size isn't negative
Fixes crash with CD drives.
2025-06-28 19:33:04 +02:00
Jonas Kvinge
09d02c53a3 StyleSheetLoader: Add back macOS hack 2025-06-23 21:12:54 +02:00
Jonas Kvinge
61a701554e style: Add back customized playlist background style 2025-06-23 20:44:00 +02:00
Jonas Kvinge
d280e6426f StyleSheetLoader: Add back alternate base color handling 2025-06-23 20:43:12 +02:00
Jonas Kvinge
5b9bb3efa7 Update Changelog 2025-06-23 20:06:35 +02:00
Jonas Kvinge
b8cbe49f8c StyleSheetLoader: Remove alternate base color handling 2025-06-23 20:05:35 +02:00
Jonas Kvinge
633e5707ef style: Remove customized playlist background style 2025-06-23 20:04:23 +02:00
Jonas Kvinge
d54290c3a7 Update Changelog 2025-06-23 19:01:55 +02:00
Jonas Kvinge
3ef2b53e46 Add back device view on Windows 2025-06-22 20:40:43 +02:00
Jonas Kvinge
d3a4dd6da6 CollectionView: Remove unused declaration 2025-06-22 20:36:57 +02:00
Jonas Kvinge
0158f7f08a Port DeviceManager to enum class 2025-06-22 17:35:19 +02:00
Jonas Kvinge
8cea020fac DeviceManager: Move creating device info to main thread 2025-06-22 17:21:12 +02:00
Jonas Kvinge
f6b38fecb0 DeviceManager: Set database ID when existing device info is found 2025-06-22 16:30:28 +02:00
Jonas Kvinge
5e2729fafe DeviceManager: Formatting 2025-06-22 16:29:27 +02:00
Jonas Kvinge
19dce1c25d DeviceInfo: Rename variables 2025-06-22 16:27:04 +02:00
Jonas Kvinge
00bb722e25 CDDALister: Trim friendly name 2025-06-22 16:26:35 +02:00
Jonas Kvinge
cbaf4d3121 DeviceManager: Rename variables 2025-06-22 00:49:01 +02:00
Jonas Kvinge
4b5370044b CDDASongLoader: Use cdiocddasrc 2025-06-22 00:39:09 +02:00
Jonas Kvinge
ffbe1ec9fd CDDASongLoader: Load tags from CD 2025-06-22 00:27:23 +02:00
Jonas Kvinge
53e43db91b CI: Add Fedora 43 2025-06-19 01:18:56 +02:00
dependabot[bot]
2858cdabc2 Bump vmactions/freebsd-vm from 1.2.0 to 1.2.1
Bumps [vmactions/freebsd-vm](https://github.com/vmactions/freebsd-vm) from 1.2.0 to 1.2.1.
- [Release notes](https://github.com/vmactions/freebsd-vm/releases)
- [Commits](https://github.com/vmactions/freebsd-vm/compare/v1.2.0...v1.2.1)

---
updated-dependencies:
- dependency-name: vmactions/freebsd-vm
  dependency-version: 1.2.1
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-06-18 00:04:29 +02:00
Jonas Kvinge
cf74eeb120 CollectionSettingsPage: Remove edit triggers
Fixes #1767
2025-06-17 23:54:41 +02:00
Jonas Kvinge
790a1b4dbf ListenBrainzScrobbler: Use std::max 2025-06-17 23:47:46 +02:00
Jonas Kvinge
ee6332af1e ScrobblingAPI20: Replace std::min with std::max
Mistakenly written std::min instead of std::max here causing streams to never be scrobbled.
2025-06-17 23:47:37 +02:00
Jonas Kvinge
bf0704f6b2 Rename Cdda to CDDA 2025-06-09 04:21:17 +02:00
Jonas Kvinge
ae13fe7f52 Fix loading CD tracks in devices
Fixes #1676
2025-06-09 04:16:07 +02:00
Jonas Kvinge
90678e72ac DeviceManager: Remove device refresh 2025-06-09 04:12:23 +02:00
Jonas Kvinge
a0ec244008 CddaSongLoader: Fix some leaks 2025-06-09 02:27:11 +02:00
Jonas Kvinge
fba4f84fb6 CollectionModel: Move model reset to regular model updates 2025-06-09 02:24:53 +02:00
gitlost
950774f1c8 ExtendedEditor: padding for TextEdit & RTL LineEdit
`UpdateButtonGeometry()`: specify "QPlainTextEdit" for `TextEdit`
  padding (Comment and Lyrics) and invert left/right padding for
  `LineEdit` if layout direction RTL
2025-06-03 22:34:22 +02:00
gitlost
340bc21537 EditTagDialog: Make reset feedback work by calling
`set_reset_button()` in `UpdateModifiedField()` and catering for
  non-text in `IsValueModified()` (-1 original being same as 0);
  use new `ExtendedEditor::set_font()`;
  connect reset for "rating".
  Make "comment" `tabChangesFocus` to keep tab chain.
ExtendedEditor: New `set_font()` to get emboldened font to work and
  make reset feedback work for `CheckBox` and `RatingBox` by
  overriding `Resize()`.
RatingWidget: Allow tabbed focus and implement keyboard input.
2025-05-25 03:20:18 +02:00
Paper
a86ba4dffc GPodDevice: Add ALAC to supported file types for iPods
There are some iPods which do not support ALAC, but they are quite rare. Anything 3rd gen
and newer, which most people are likely to be using, will work if upgraded to the latest
firmware (they probably are already on it...)
2025-05-20 22:13:12 +02:00
Paper
d6bc6e33c0 Transcoder: Allow transcoding to ALAC 2025-05-20 22:13:12 +02:00
Paper
7e128a9af5 Song: Add ALAC song type 2025-05-20 22:13:12 +02:00
Jonas Kvinge
0f0746be9d CI: Remove Fedora 39 and 40 2025-05-15 22:39:15 +02:00
Jonas Kvinge
bec3fe9fd5 Turn on git revision 2025-05-15 22:38:32 +02:00
Jonas Kvinge
83c666baf9 Release 1.2.11 2025-05-15 21:09:19 +02:00
Strawberry Bot
b9b54e6e96 New translations 2025-05-13 22:11:19 +02:00
Jonas Kvinge
b2ff6240eb Update Changelog 2025-05-13 22:10:30 +02:00
Jonas Kvinge
26a7c74a24 nsi: Remove gioopenssl, except for msvc arm64 2025-05-13 22:10:25 +02:00
Jonas Kvinge
a34954ec4a PlaylistListContainer: Always check that playlist is open
Fixes #1741
2025-05-13 19:48:01 +02:00
Jonas Kvinge
349ab62e75 PlaylistListView: Check for valid current index 2025-05-13 19:42:25 +02:00
Jonas Kvinge
65e960f2c5 Update Changelog 2025-05-12 22:21:27 +02:00
Jonas Kvinge
e22fef8ca4 ContextView: Fix album cover visible check
Fixes #1744
2025-05-12 18:52:12 +02:00
Jonas Kvinge
3e99045e2c nsi: Update sqlite3 dll name 2025-05-08 22:31:43 +02:00
Jonas Kvinge
4fcade273e Update Changelog 2025-05-08 21:20:53 +02:00
Strawberry Bot
5eaff0d26e New translations 2025-05-08 21:17:36 +02:00
Strawberry Bot
5b22f12b4a New translations 2025-05-01 23:50:07 +02:00
OlegAckbar
5f85c2e7a5 Linux: enable startup notify
It was very odd for me why Strawberry doesn't have any feedback when launching from application menu. Turns out its desktop file had "StartupNotify=false" for some reason?
2025-05-01 23:41:35 +02:00
dependabot[bot]
4fb5a7b6bc Bump vmactions/openbsd-vm from 1.1.7 to 1.1.8
Bumps [vmactions/openbsd-vm](https://github.com/vmactions/openbsd-vm) from 1.1.7 to 1.1.8.
- [Release notes](https://github.com/vmactions/openbsd-vm/releases)
- [Commits](https://github.com/vmactions/openbsd-vm/compare/v1.1.7...v1.1.8)

---
updated-dependencies:
- dependency-name: vmactions/openbsd-vm
  dependency-version: 1.1.8
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-04-30 18:59:21 +02:00
Jonas Kvinge
04c6c862c4 Refactor playlist items
Fix a bug where playlist items cover is not updated
2025-04-27 03:03:58 +02:00
Jonas Kvinge
baec45f742 CollectionBackend: Add updating collection database task 2025-04-27 02:27:46 +02:00
Jonas Kvinge
9efdbd2c10 CollectionWatcher: Add missing updates 2025-04-27 02:25:42 +02:00
Jonas Kvinge
d8800b80d5 CMake: Move discord-rpc to same target_link_libraries 2025-04-23 19:23:01 +02:00
Jonas Kvinge
ec715abb0d CI: Use macOS 12 SDK when available 2025-04-21 14:40:12 +02:00
Jonas Kvinge
1485801efb CI: Add support for Windows arm64 2025-04-20 02:14:42 +02:00
Jonas Kvinge
4f9ac3d33a nsi: Add support for arm64 2025-04-20 02:13:58 +02:00
Jonas Kvinge
1577ce4d67 Turn on git revision 2025-04-18 21:59:18 +02:00
Jonas Kvinge
7eee74a2e9 Release 1.2.10 2025-04-18 20:04:22 +02:00
Jonas Kvinge
d9e38fb3be Remove Genius lyrics
No longer working properly because of website changes.
2025-04-18 15:56:30 +02:00
Jonas Kvinge
81cc90e54a Update Changelog 2025-04-18 02:38:37 +02:00
Jonas Kvinge
bd9771a88f TagReaderTagLib: Use TagLib::Tag::comment
Makes it use only commercial frames without description for comments, reading other commercial frames picks different iTunes tags we don't want.
2025-04-18 02:15:17 +02:00
Jonas Kvinge
f5cd81fe09 nsi: Re-enable Spotify 2025-04-16 23:25:03 +02:00
Gregor Santner
277e2cff59 Linux: Add Clementine search keyword to .desktop shortcut 2025-04-15 21:46:15 +02:00
Jonas Kvinge
6fa9514059 RichPresence: Only initialize discord when enabled 2025-04-13 21:45:55 +02:00
Jonas Kvinge
c5e38b71f7 discord_rpc: Use anonymous namespace 2025-04-13 21:34:40 +02:00
Jonas Kvinge
3746915ae7 RichPresence: Always include album 2025-04-13 19:19:53 +02:00
Jonas Kvinge
21bdf88d09 RichPresence: Remove unused variable 2025-04-13 12:16:57 +02:00
Jonas Kvinge
ff032c3cd7 RichPresence: Remove rate limit 2025-04-13 12:01:56 +02:00
Jonas Kvinge
c083110051 RichPresence: Move variable declaration
Fixes #1718
2025-04-13 11:52:16 +02:00
Jonas Kvinge
a7dbeb5d76 discord-rpc: Add copyright 2025-04-12 13:17:13 +02:00
Jonas Kvinge
634f6ea9f5 discord-rpc: Formatting 2025-04-12 13:17:00 +02:00
Jonas Kvinge
f9e4f9a09a discord-rpc: Formatting 2025-04-11 22:50:14 +02:00
Jonas Kvinge
aab9889174 Turn on git revision 2025-04-09 19:59:48 +02:00
Jonas Kvinge
3b560e4e4f Release 1.2.9 2025-04-08 23:52:00 +02:00
Jonas Kvinge
9e327c9556 Update Changelog 2025-04-08 23:52:00 +02:00
Jonas Kvinge
1ec640e088 LastFMImport: Fix progress 2025-04-08 23:05:44 +02:00
Jonas Kvinge
463aaf6942 Update Changelog 2025-04-08 21:19:29 +02:00
Jonas Kvinge
71287dd77e Add option to turn off playbin3 2025-04-08 21:19:29 +02:00
dependabot[bot]
b66c0f5573 Bump vmactions/openbsd-vm from 1.1.6 to 1.1.7
Bumps [vmactions/openbsd-vm](https://github.com/vmactions/openbsd-vm) from 1.1.6 to 1.1.7.
- [Release notes](https://github.com/vmactions/openbsd-vm/releases)
- [Commits](https://github.com/vmactions/openbsd-vm/compare/v1.1.6...v1.1.7)

---
updated-dependencies:
- dependency-name: vmactions/openbsd-vm
  dependency-version: 1.1.7
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-04-08 20:53:01 +02:00
Jonas Kvinge
a9f2c384fa RichPresence: Use class for activity 2025-04-08 20:52:34 +02:00
Jonas Kvinge
ae9584c213 Rename is_enabled to enabled 2025-04-08 20:33:54 +02:00
Jonas Kvinge
4db1c5ceb8 AlbumCoverFetcherSearch: Add debug for results 2025-04-08 20:33:27 +02:00
Jonas Kvinge
1738259467 SubsonicBaseRequest: Fix parsing
Fixes #1719
2025-04-08 20:18:54 +02:00
Jonas Kvinge
fcee02edc1 DeezerCoverProvider: Fix parsing
Fixes #1716
2025-04-08 20:04:02 +02:00
dependabot[bot]
4fff5820c5 Bump vmactions/freebsd-vm from 1.1.9 to 1.2.0
Bumps [vmactions/freebsd-vm](https://github.com/vmactions/freebsd-vm) from 1.1.9 to 1.2.0.
- [Release notes](https://github.com/vmactions/freebsd-vm/releases)
- [Commits](https://github.com/vmactions/freebsd-vm/compare/v1.1.9...v1.2.0)

---
updated-dependencies:
- dependency-name: vmactions/freebsd-vm
  dependency-version: 1.2.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-04-07 19:32:24 +02:00
Jonas Kvinge
9aa6da2faf Mpris2: Ignore -Warray-bounds 2025-04-05 19:10:28 +02:00
Jonas Kvinge
279934411c Add Ubuntu Plucky 2025-04-05 18:31:08 +02:00
Jonas Kvinge
fd829551e8 Turn on git revision 2025-04-05 18:13:40 +02:00
Jonas Kvinge
be8f515388 Release 1.2.8 2025-04-05 12:38:22 +02:00
Jonas Kvinge
dd12462fbb Update Changelog 2025-04-05 12:38:22 +02:00
Strawberry Bot
5c3ded0099 New translations 2025-04-05 12:24:00 +02:00
Jonas Kvinge
2c9b14f5f2 GstEnginePipeline: Simplify version checks 2025-04-04 22:12:38 +02:00
Jonas Kvinge
8c195382c4 nsi: Disable spotify plugin 2025-04-03 22:51:12 +02:00
Jonas Kvinge
6e5198799c OAuthenticator: Rename function 2025-04-03 22:37:50 +02:00
Jonas Kvinge
389d04bbec OAuthenticator: Don't clear refresh token 2025-04-03 22:34:55 +02:00
Jonas Kvinge
6f0f88dd01 RichPresence: Simplify code 2025-04-03 22:21:51 +02:00
Jonas Kvinge
3dce84c73c MainWindow: Delay command line options until playlists are loaded
Fixes #1546
2025-03-30 16:45:34 +02:00
Jonas Kvinge
e798349aca Mpris2: Emit notifications when playlists are loaded
Fixes #1546
2025-03-30 16:43:29 +02:00
Jonas Kvinge
41ecf8e535 main: Add missing ifdef 2025-03-30 01:56:58 +01:00
Jonas Kvinge
70c96ded28 rpm: Add BuildRequires for cmake(RapidJSON) 2025-03-30 01:22:57 +01:00
Jonas Kvinge
d9cc6bf238 debian/control: Add rapidjson-dev 2025-03-30 01:22:57 +01:00
Jonas Kvinge
0a70ac1c95 Song: Update supported tags 2025-03-30 01:22:20 +01:00
Jonas Kvinge
e3a3f44513 TagReaderTagLib: Add full support for AIFF 2025-03-30 01:22:07 +01:00
Jonas Kvinge
c2e42ebf3a Song: Include fingerprints in IsSimilar
Fixes #1710
2025-03-30 00:34:43 +01:00
Jonas Kvinge
d71b344e77 MainWindow: Add missing ifdef 2025-03-30 00:07:22 +01:00
Jonas Kvinge
d5f7a4b883 RichPresence: Formatting and add settings reload 2025-03-30 00:06:05 +01:00
Jonas Kvinge
34fb289e33 serialization: Remove unneeded pragams 2025-03-29 23:01:41 +01:00
Jonas Kvinge
6d4d8251ad Update Changelog 2025-03-29 22:53:37 +01:00
Jonas Kvinge
fc69ef27e8 README: Add Discord rich presence 2025-03-29 22:46:50 +01:00
Jonas Kvinge
bbd8a24b75 discord: Add namespace and cleanup CMakeLists 2025-03-29 22:41:58 +01:00
fruityloops1
9fa9012c70 Discord RPC implementation 2025-03-29 22:41:58 +01:00
fruityloops1
2a4fc185ac Add discord-rpc library 2025-03-29 22:41:58 +01:00
Jonas Kvinge
fa0703246b Equalizer: Ignore -Warray-bounds 2025-03-28 23:09:49 +01:00
corubba
954c21e21e AlsaDeviceFinder: Use card id instead of card index
Like the card index, the card id is guaranteed to be unique. While card
index can easily change between reboots, the card id is based on the
actual audio hardware and does not change between reboots; or even
hardware changes. This makes using the card id preferable, because it
will "just work" 99% of the time, and removes the need to force cards to
have a specific index.

There is a corner case where card ids may change between reboots: If you
have two (or more) of the same audio hardware in the system. But that
should be rare enough, and requires explicit system configuration
anyway, so using the "custom" option should work here.

If there is an previously-saved index-based ALSA device in the config,
it will continue to work as-is and does not need to be migrated. There
is only a small UI side-effect: Because the index-based device will no
longer match any found id-based device, the settings window will show it
as "custom". Simply selecting the ALSA device from the drop-down again
will change it to the id-based device.
2025-03-28 19:54:32 +01:00
Jonas Kvinge
8954dfb0aa CMake: Add -W4 with MSVC 2025-03-25 18:05:41 +01:00
Jonas Kvinge
5e031be42c Fix cast warnings with MSVC 2025-03-25 18:05:41 +01:00
dependabot[bot]
d5281abb22 Bump apple-actions/import-codesign-certs from 3 to 5
Bumps [apple-actions/import-codesign-certs](https://github.com/apple-actions/import-codesign-certs) from 3 to 5.
- [Release notes](https://github.com/apple-actions/import-codesign-certs/releases)
- [Commits](https://github.com/apple-actions/import-codesign-certs/compare/v3...v5)

---
updated-dependencies:
- dependency-name: apple-actions/import-codesign-certs
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-03-25 17:22:05 +01:00
Jonas Kvinge
f5368d8108 Revert "Bump apple-actions/import-codesign-certs from 3 to 4"
This reverts commit e2dc22c2c8.
2025-03-21 20:35:36 +01:00
dependabot[bot]
e2dc22c2c8 Bump apple-actions/import-codesign-certs from 3 to 4
Bumps [apple-actions/import-codesign-certs](https://github.com/apple-actions/import-codesign-certs) from 3 to 4.
- [Release notes](https://github.com/apple-actions/import-codesign-certs/releases)
- [Commits](https://github.com/apple-actions/import-codesign-certs/compare/v3...v4)

---
updated-dependencies:
- dependency-name: apple-actions/import-codesign-certs
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-03-21 18:21:12 +01:00
Strawberry Bot
817ca828e6 New translations 2025-03-18 22:44:29 +01:00
dependabot[bot]
61dc2cc640 Bump vmactions/freebsd-vm from 1.1.8 to 1.1.9
Bumps [vmactions/freebsd-vm](https://github.com/vmactions/freebsd-vm) from 1.1.8 to 1.1.9.
- [Release notes](https://github.com/vmactions/freebsd-vm/releases)
- [Commits](https://github.com/vmactions/freebsd-vm/compare/v1.1.8...v1.1.9)

---
updated-dependencies:
- dependency-name: vmactions/freebsd-vm
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-03-18 17:58:35 +01:00
Jonas Kvinge
cd4adf6f89 ebur128analysis: Handle extra enums with GStreamer 1.25 and higher 2025-03-17 22:57:36 +01:00
Jonas Kvinge
91ebcc948e debian/rules: Build with -DBUILD_WERROR=ON 2025-03-17 22:28:24 +01:00
Jonas Kvinge
e7e6d59172 Remove KDSingleApplication from 3rdparty 2025-03-17 21:38:11 +01:00
Jonas Kvinge
95b12a01a4 OAuthenticator: Fix logging 2025-03-17 19:42:59 +01:00
Jonas Kvinge
5947aeae24 nsi: Bump icu 2025-03-15 23:29:12 +01:00
Jonas Kvinge
0298fa0b73 TidalBaseRequest: Don't clear session 2025-03-14 20:18:53 +01:00
Jonas Kvinge
05d72c8bd6 nsi: Add asio for mingw 2025-03-13 00:10:37 +01:00
Roman Lebedev
70b7c4560d gst_channel_to_ebur_channel(): handle new top-surround channels
These seem to have appeared in gstreamer 1.26,
which is the version we need to use to guard the handling.

These are effectively geometrically located on the same azimuth,
but on the layer above than the non-top (i.e. middle layer)
surround channels. But they are still surround channels,
which ebur128 does not bias loudness-wise.

At least this is my understanding.
2025-03-12 22:20:56 +01:00
Roman Lebedev
2687dc31cc Support arbitrarily large EBU R 128 loudness normalization
While i have fixed gstreamer's `volume` in
https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/5063
i did not see anything that followed after it was merged, namely, in
https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/6222,
the feature was moved, `"volume"` was reverted to only handle `x10` gain,
and one needs to use `"volume-full-range"` instead to do arbitrary gain.
So let's do that.

This, of course, requires run-time detection of the version
of gstreamer base plugins that we are running with,
specifically, we need version `1.24`.
2025-03-12 22:20:56 +01:00
Jonas Kvinge
cabf1cb78d CI: Bump macOS runner 2025-03-11 22:54:34 +01:00
Jonas Kvinge
d9f68ab944 Application: Add QTimer include
Fixes #1695
2025-03-09 11:29:51 +01:00
Jonas Kvinge
8630c5329d LyricsFetcherSearch: Fix authentication check 2025-03-09 02:11:12 +01:00
Jonas Kvinge
66e175f6d1 PlaylistItem: Add dtor 2025-03-08 23:46:12 +01:00
Jonas Kvinge
1173d5f865 Lyrics: Refactor 2025-03-08 23:26:44 +01:00
Jonas Kvinge
b02b114caf Scrobbler: Refactor 2025-03-08 23:19:42 +01:00
Jonas Kvinge
cd516c37b9 Refactor Tidal, Spotify, Qobuz, Subsonic and cover providers
Use common HTTP, Json and OAuthenticator class
2025-03-08 23:11:07 +01:00
Jonas Kvinge
7de8a44709 Add OAuthenticator 2025-03-08 22:46:59 +01:00
Jonas Kvinge
bb345b14de Add base classes for HTTP and Json 2025-03-08 22:46:46 +01:00
Jonas Kvinge
baa82966d8 Move SearchType to StreamingService 2025-03-08 22:41:43 +01:00
Jonas Kvinge
f85d60f5cd Formatting 2025-03-08 22:31:00 +01:00
Jonas Kvinge
6f731fcf4a MainWindow: Add const 2025-03-08 22:30:27 +01:00
Jonas Kvinge
bdbe66b116 Support more collections 2025-03-08 22:24:28 +01:00
Jonas Kvinge
5ae0320911 CollectionBackend: Add delete songs by URLs function 2025-03-08 21:46:27 +01:00
Jonas Kvinge
31671af5f5 MultiLoadingIndicator: Only emit task count change when needed 2025-03-08 21:45:34 +01:00
Jonas Kvinge
27184eb001 Utilities: Add StringListToHTML 2025-03-08 21:45:00 +01:00
Jonas Kvinge
2e30f5c585 StreamTagReader: Rename variable 2025-03-08 21:44:33 +01:00
Jonas Kvinge
109d3f9ec3 PlaylistBackend: Move query to static function 2025-03-08 21:36:42 +01:00
Jonas Kvinge
e9d413c7dc QTcpServer: Add success and port 2025-03-08 21:26:47 +01:00
Jonas Kvinge
ee60191b6c MusicBrainzClient: Formatting 2025-03-08 21:24:59 +01:00
Jonas Kvinge
a6d8627129 AcoustidClient: Formatting 2025-03-08 21:24:29 +01:00
Jonas Kvinge
d317c9158b UrlHandler: Formatting 2025-03-08 21:23:02 +01:00
Jonas Kvinge
3716e8c3ef CollectionModel: Rename variable 2025-03-08 21:22:40 +01:00
Jonas Kvinge
ce0e1e900e Update README.md 2025-03-04 23:31:23 +01:00
Jonas Kvinge
f1aa92ec9f Update README.md 2025-03-04 21:25:35 +01:00
Jonas Kvinge
25bdfcdb76 nsi: Update sqlite3 dll name 2025-02-20 22:37:43 +01:00
Jonas Kvinge
6a3de3937a AppearanceSettingsPage: Add tooltip about restart
You need to restart Strawberry for this setting to take affect.
2025-02-20 16:11:24 +01:00
Jonas Kvinge
5f775e87ae BackendSettingsPage: Add tooltip for HTTP/2
You need to restart Strawberry for this setting to take affect
2025-02-20 16:10:21 +01:00
Jonas Kvinge
1fd83c55ee Equalizer: Add tooltip that playback must be restarted 2025-02-20 16:09:10 +01:00
Jonas Kvinge
e6e9edef7d tests: Remove unused TestObjectDecorators 2025-02-18 23:00:01 +01:00
Jonas Kvinge
1bae665f76 CI: Fix OpenMandriva build 2025-02-18 22:02:22 +01:00
Jonas Kvinge
5bfc8b74f5 CI: Fix Mageia build 2025-02-18 22:02:12 +01:00
Jonas Kvinge
e588896729 FilterParser: Update tooltip
Fixes #1680
2025-02-18 17:08:17 +01:00
Jonas Kvinge
0cd0f7f2e7 FilesystemMusicStorage: Use QFile::supportsMoveToTrash 2025-02-18 16:55:02 +01:00
Jonas Kvinge
6db540a3a7 nsi: Bump libFLAC version 2025-02-12 01:25:12 +01:00
Jonas Kvinge
82679e0cea Fix issue template 2025-02-12 01:07:04 +01:00
Jonas Kvinge
d571bc3305 TagReaderTagLib: Fix build without stream tagreader
Fixes #1672
2025-02-10 23:29:40 +01:00
Jonas Kvinge
2b52553864 Add stream tagreader 2025-02-08 02:53:10 +01:00
Jonas Kvinge
215627b0e4 TagReaderGME: Fix use of Qt::CaseInsensitive and length check 2025-02-08 01:17:44 +01:00
Jonas Kvinge
b17cae6ec7 rpm: Exclude %debug_package on tumbleweed 2025-02-07 22:23:04 +01:00
Jonas Kvinge
30ac9697ea BackendSettingsPage: Increase device lineedit height
Bottom of the text was cut off with the breeze style
2025-02-07 21:27:17 +01:00
Jonas Kvinge
61e3ea249d Turn off "Grey out unavailable songs in playlists on startup" by default 2025-02-02 23:48:05 +01:00
Jonas Kvinge
d1986eeae2 Tidal: Save token type 2025-02-01 22:25:53 +01:00
Jonas Kvinge
ba354207d2 Tidal: Remove deprecated username/password login 2025-02-01 22:10:53 +01:00
Jonas Kvinge
eac5674891 TidalService: Clear refresh token on sign out 2025-02-01 00:50:17 +01:00
Jonas Kvinge
8349a8b0ee Port back to "output" and "device" settings in lowercase
Was accidentally changed to capitalized.
2025-02-01 00:48:57 +01:00
Jonas Kvinge
b9b4e9f831 TidalSettingsPage: Add HI_RES_LOSSLESS 2025-01-31 23:17:19 +01:00
Jonas Kvinge
98ff2525f0 Turn on git revision 2025-01-31 18:26:03 +01:00
Jonas Kvinge
3fd29c6dcc Release 1.2.7 2025-01-31 16:35:19 +01:00
Jonas Kvinge
4429e9973f StandardItemIconLoader : Rename LoadIcon
Avoids conflict on Windows where windows headers define LoadIcon to LoadIconW with unicode.
2025-01-31 16:20:03 +01:00
Jonas Kvinge
1572d241d5 Replace Windows conflicting "LoadIcon" with "SetIcon"
Windows headers defines LoadIcon to LoadIconW when UNICODE is defined.
2025-01-31 16:10:23 +01:00
Jonas Kvinge
eae7e2a9e6 Update Changelog 2025-01-31 13:09:38 +01:00
Jonas Kvinge
251e5b379b Disable OSD Pretty on Wayland 2025-01-29 22:12:29 +01:00
Jonas Kvinge
0db082fca0 Replace Q_OS_WIN with Q_OS_WIN32 2025-01-28 20:30:43 +01:00
Jonas Kvinge
2799e55076 OSDPretty: Set window title 2025-01-28 20:24:27 +01:00
Jonas Kvinge
440ee43a91 Update Changelog 2025-01-27 14:56:06 +01:00
Jonas Kvinge
98c72ec1f8 import-from-clementine: Minor tidy 2025-01-27 14:55:51 +01:00
Jonas Kvinge
759488ae1a CMake: Reword QPlatformNativeInterface option 2025-01-27 14:55:30 +01:00
Jonas Kvinge
055cb413c9 import-from-clementine: Handle NULL filename and remove FTS
Fixes #1660
2025-01-27 14:41:14 +01:00
Jonas Kvinge
f760b87b58 CI: Add missing dependencies for PPA 2025-01-25 19:37:58 +01:00
Jonas Kvinge
39f228f862 CMake: Add QPA Platform interface as optional component 2025-01-25 18:31:22 +01:00
Jonas Kvinge
a683a279f5 CMake: Define NOMINMAX on Windows 2025-01-24 12:46:49 +01:00
Jonas Kvinge
e800926f57 Ignore -Wcpp for gtest.h/gmock.h 2025-01-24 12:46:48 +01:00
Strawberry Bot
dd9f80d539 New translations 2025-01-24 10:58:02 +01:00
Jonas Kvinge
8484cac4ed Add strawberry_fr_BE.ts 2025-01-24 10:42:40 +01:00
Strawberry Bot
e24097582f New translations 2025-01-24 10:40:12 +01:00
Jonas Kvinge
58fc8c82bb MainWindow: Maximize error dialog when window is shown 2025-01-22 17:51:16 +01:00
Jonas Kvinge
02bb875bb3 ErrorDialog: Only raise window if parent is maximized
Fixes #1627
2025-01-22 17:50:41 +01:00
Jonas Kvinge
5db01482eb Lazy: Fix bool 2025-01-22 17:49:52 +01:00
Jonas Kvinge
719fa6ffb3 MainWindow: Only hide window when system tray and keep running is enabled 2025-01-22 17:26:08 +01:00
Jonas Kvinge
159be5d79e MainWindow: Change close() to hide() in SetHiddenInTray
Otherwise close event is triggered causing Strawberry to quit.
2025-01-19 09:45:13 +01:00
Jonas Kvinge
911237e281 AnalyzerBase: Add missing parameter names 2025-01-19 09:42:00 +01:00
Jonas Kvinge
ae89ca8123 Turn on git revision 2025-01-17 12:34:43 +01:00
Jonas Kvinge
b832675893 Release 1.2.6 2025-01-17 10:27:48 +01:00
Jonas Kvinge
b4cfe636c9 TranscodeDialog: Fix mismatched definition 2025-01-17 09:15:55 +01:00
Jonas Kvinge
e6a0945dfa Call QObject::metaObject 2025-01-17 09:08:59 +01:00
Jonas Kvinge
726c105ed6 MoodbarItemDelegate: Remove delete of data
Memory is deleted in QCache::insert
2025-01-17 08:29:17 +01:00
Jonas Kvinge
d73cbc3a1d EngineBase: Fix mismatched definition 2025-01-17 08:26:11 +01:00
Jonas Kvinge
121f45d3b6 Playlist: Use sizeof playlist pointer to pointer 2025-01-17 07:22:49 +01:00
Jonas Kvinge
3a9ea81929 Queue: Fix sizeof, should be the pointer not the class 2025-01-17 07:12:25 +01:00
Jonas Kvinge
b919472241 Playlist: Correct sizeof 2025-01-17 06:56:08 +01:00
Jonas Kvinge
e8c8b39410 Turn on git revision 2025-01-17 04:29:05 +01:00
Jonas Kvinge
6904efef47 Release 1.2.5 2025-01-17 01:40:38 +01:00
Jonas Kvinge
fafa89baff CI: Disable GIO on Windows 2025-01-16 07:18:31 +01:00
Strawberry Bot
d9062446f5 New translations 2025-01-16 06:39:23 +01:00
Jonas Kvinge
9256b92d8f Update Changelog 2025-01-16 06:32:35 +01:00
Jonas Kvinge
f66459f3cb Make optional feature required unless disabled, add QtSparkle for macOS 2025-01-16 06:22:13 +01:00
Jonas Kvinge
f8ea9631ca Add sparkle 2025-01-15 23:03:40 +01:00
Jonas Kvinge
ab558f87b5 GstEnginePipeline: Use SetStateAsync in finish if needed 2025-01-15 07:01:43 +01:00
Jonas Kvinge
ab73eda2be Add mutex_protected_test 2025-01-15 07:00:28 +01:00
Jonas Kvinge
92f34ff36e mutex_protected: Add more operators 2025-01-15 07:00:16 +01:00
Strawberry Bot
d0bf2d7a9c New translations 2025-01-14 07:10:07 +01:00
Jonas Kvinge
b2cd3afe55 TagReaderClient: Add [[nodiscard]] 2025-01-14 06:36:15 +01:00
Jonas Kvinge
decd0a1dc6 TagReaderClient: Connect TagReaderReplyPtr
Makes sure TagReaderReplyPtr is not deleted too early.

Partial fix for #1633
2025-01-14 06:35:51 +01:00
Jonas Kvinge
3e0a9fa388 SettingsProvider: Use Settings
Fixes #1649
2025-01-13 12:22:31 +01:00
Jonas Kvinge
e5b6c5959f CMake: Use find_package for qtsparkle 2025-01-12 04:16:17 +01:00
Jonas Kvinge
8a9db5440d rpm: Enable unit tests on Fedora 2025-01-11 01:39:26 +01:00
Jonas Kvinge
28a25c5763 CMake: Fix add_test 2025-01-11 01:37:06 +01:00
dependabot[bot]
ea49fbcbee Bump vmactions/openbsd-vm from 1.1.5 to 1.1.6
Bumps [vmactions/openbsd-vm](https://github.com/vmactions/openbsd-vm) from 1.1.5 to 1.1.6.
- [Release notes](https://github.com/vmactions/openbsd-vm/releases)
- [Commits](https://github.com/vmactions/openbsd-vm/compare/v1.1.5...v1.1.6)

---
updated-dependencies:
- dependency-name: vmactions/openbsd-vm
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-01-11 00:37:52 +01:00
Jonas Kvinge
d9807b358e GioLister: Fix use of deprecated functions 2025-01-11 00:35:24 +01:00
Jonas Kvinge
3e53d2b237 CI: Add -Wno-maybe-uninitialized for Fedora 2025-01-11 00:35:24 +01:00
Jonas Kvinge
9122881f74 CI: Bump GCC on openSUSE Leap 2025-01-11 00:35:24 +01:00
Jonas Kvinge
9c36d7fd43 rpm: Add BUILD_WERROR 2025-01-11 00:35:24 +01:00
Jonas Kvinge
a4a365cbee CI: Set RPM_BUILD_NCPUS to 4 2025-01-11 00:35:24 +01:00
Jonas Kvinge
00f06b22b8 CMake: Check for gmock 2025-01-11 00:35:24 +01:00
Jonas Kvinge
e2d8838fca rpm: Run unit tests 2025-01-11 00:35:24 +01:00
Jonas Kvinge
9427691f39 CI: Install gtest and gmock for openSUSE, Fedora and Mageia 2025-01-11 00:35:24 +01:00
Jonas Kvinge
bebdcc4e7f CollectionModel: Simply data function 2025-01-10 17:47:30 +01:00
Jonas Kvinge
041f761921 test_utils: Fix Q_ASSERT 2025-01-10 15:35:15 +01:00
Jonas Kvinge
1435ae6dc0 Turn on git revision 2025-01-10 15:08:04 +01:00
Jonas Kvinge
33ae53a90f Release 1.2.4 2025-01-10 02:26:41 +01:00
Strawberry Bot
01c28867b7 New translations 2025-01-10 02:10:44 +01:00
Jonas Kvinge
08fb2ae331 Update Changelog 2025-01-10 01:58:19 +01:00
Jonas Kvinge
99970f9e52 Update strawberry_en_US.ts 2025-01-10 01:58:19 +01:00
Jonas Kvinge
bc206f43b4 TranscodeDialog: Minor adjustments 2025-01-10 01:58:19 +01:00
dependabot[bot]
018448159c Bump vmactions/freebsd-vm from 1.1.7 to 1.1.8
Bumps [vmactions/freebsd-vm](https://github.com/vmactions/freebsd-vm) from 1.1.7 to 1.1.8.
- [Release notes](https://github.com/vmactions/freebsd-vm/releases)
- [Commits](https://github.com/vmactions/freebsd-vm/compare/v1.1.7...v1.1.8)

---
updated-dependencies:
- dependency-name: vmactions/freebsd-vm
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-01-10 01:27:57 +01:00
Jonas Kvinge
81fe90bdef Update Changelog 2025-01-10 01:07:32 +01:00
Jonas Kvinge
319558c535 tests: Fixed ignored return value 2025-01-10 00:58:41 +01:00
Jonas Kvinge
9095b0d6b2 Always run MSVC runtime installer 2025-01-08 19:34:27 +01:00
Jonas Kvinge
558eae1ca1 Remove unneeded slots 2025-01-08 04:57:17 +01:00
Jonas Kvinge
2c64f05cea MoodbarProxyStyle: Add const 2025-01-08 04:54:45 +01:00
Jonas Kvinge
c80e7071a1 StandardPaths: Fix namespace 2025-01-07 22:13:24 +01:00
Jonas Kvinge
038e679000 SmartPlaylistWizard: Apply dark mode workaround for all styles except vista
Fixes #1639
2025-01-07 22:04:28 +01:00
Jonas Kvinge
72447fecfb StandardPaths: Remove inheritance 2025-01-07 21:40:06 +01:00
Jonas Kvinge
c7830f6f05 MoodbarPipeline: Cleanup on finish 2025-01-07 01:09:49 +01:00
Jonas Kvinge
af525e42b6 MoodbarPipeline: Remove Q_ASSERT 2025-01-06 21:28:44 +01:00
Jonas Kvinge
eb83f23125 MoodbarPipeline: Use bytearray directly 2025-01-06 21:28:33 +01:00
Jonas Kvinge
7527d2ea9a MoodbarLoader: Set object name 2025-01-06 18:11:38 +01:00
Jonas Kvinge
69d38879d2 Use QCoreApplication::applicationName() directly 2025-01-06 00:38:51 +01:00
Jonas Kvinge
cbce9f7191 Override config, data and cache location 2025-01-05 23:45:29 +01:00
Jonas Kvinge
f938129d81 CI: Fix deb copy command 2025-01-05 21:22:08 +01:00
Jonas Kvinge
415a40ea04 FilterParser: Ignore space after operator 2025-01-05 20:25:48 +01:00
Jonas Kvinge
6e7aaed4ee Use QSharedPointer for GstEnginePipeline 2025-01-05 19:03:16 +01:00
Jonas Kvinge
7afae70bb0 GstEnginePipeline: Make sure all set states are finished before finishing pipeline 2025-01-05 18:58:03 +01:00
Jonas Kvinge
be8097919b mutex_protected: Add operator ++ and -- 2025-01-05 18:56:22 +01:00
Jonas Kvinge
1990a42e1d CI: Don't run build on l10n_master branch 2025-01-05 18:53:19 +01:00
Kyle Hopkins
8fcee4511d TranscodeDialog: update to optionally preserve directory structure 2025-01-05 18:34:14 +01:00
Leandro Matheus
24af1be666 Subsonic: Add support for using album id to retrieve album covers 2025-01-05 18:30:24 +01:00
Jonas Kvinge
8302a95bc1 Use shared pointers for moodbar pipelines
Possible fix for #1633
2025-01-05 18:28:41 +01:00
Jonas Kvinge
36a8ab49a0 MoodbarItemDelegate: Format comment 2025-01-05 03:51:00 +01:00
Jonas Kvinge
5c64dc9c4d MoodbarItemDelegate: Delete data if it fails to insert to cache 2025-01-05 03:50:51 +01:00
Strawberry Bot
c271743208 New translations 2025-01-05 00:22:50 +01:00
Jonas Kvinge
ee49b1ddc8 Update strawberry_en_US.ts 2025-01-04 04:56:08 +01:00
Jonas Kvinge
bf98633f16 Load XSPF title as playlist name 2025-01-04 04:52:17 +01:00
Jonas Kvinge
e2a928f2dc Save XSPF playlist with title
Fixes #1624
2025-01-04 03:48:53 +01:00
Jonas Kvinge
47d3312a6b PlaylistManager: Remove slash from playlist filename 2025-01-04 03:46:03 +01:00
Jonas Kvinge
4f97325953 CollectionSettingsPage: Fix string conversion 2025-01-04 03:32:50 +01:00
Jonas Kvinge
91e8fe0943 ScrobblerSettingsPage: Add tooltip 2025-01-04 03:15:38 +01:00
Jonas Kvinge
dc5894b38a CollectionWatcher: Ignore special filesystem paths
Fixes #1615
2025-01-04 03:06:46 +01:00
Jonas Kvinge
52ee50a2a4 CollectionSettingsPage: Add check for filesystem type 2025-01-04 02:58:59 +01:00
Jonas Kvinge
f545b028ee Add filesystem constants 2025-01-04 02:58:17 +01:00
Jonas Kvinge
a96627c5a9 Playlist: Invalidate deleted songs in main thread
Fixes #1625
2025-01-04 00:16:36 +01:00
Jonas Kvinge
a13fc31f83 PlaylistManager: Remove unused InvalidateDeletedSongs function 2025-01-04 00:09:26 +01:00
Jonas Kvinge
9ee5c8dc17 Playlist: Update copyright 2025-01-03 23:41:43 +01:00
Jonas Kvinge
82cd425ece Playlist: Add const 2025-01-03 23:41:30 +01:00
Jonas Kvinge
3b02d364ba Playlist: Rename some variables 2025-01-03 23:41:15 +01:00
dependabot[bot]
73e7947487 Bump vmactions/openbsd-vm from 1.1.4 to 1.1.5
Bumps [vmactions/openbsd-vm](https://github.com/vmactions/openbsd-vm) from 1.1.4 to 1.1.5.
- [Release notes](https://github.com/vmactions/openbsd-vm/releases)
- [Commits](https://github.com/vmactions/openbsd-vm/compare/v1.1.4...v1.1.5)

---
updated-dependencies:
- dependency-name: vmactions/openbsd-vm
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2024-12-30 17:38:02 +01:00
dependabot[bot]
cfc9a43b88 Bump vmactions/freebsd-vm from 1.1.6 to 1.1.7
Bumps [vmactions/freebsd-vm](https://github.com/vmactions/freebsd-vm) from 1.1.6 to 1.1.7.
- [Release notes](https://github.com/vmactions/freebsd-vm/releases)
- [Commits](https://github.com/vmactions/freebsd-vm/compare/v1.1.6...v1.1.7)

---
updated-dependencies:
- dependency-name: vmactions/freebsd-vm
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2024-12-30 17:37:32 +01:00
dependabot[bot]
969500023a Bump vmactions/freebsd-vm from 1.1.5 to 1.1.6
Bumps [vmactions/freebsd-vm](https://github.com/vmactions/freebsd-vm) from 1.1.5 to 1.1.6.
- [Release notes](https://github.com/vmactions/freebsd-vm/releases)
- [Commits](https://github.com/vmactions/freebsd-vm/compare/v1.1.5...v1.1.6)

---
updated-dependencies:
- dependency-name: vmactions/freebsd-vm
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2024-12-26 00:44:32 +01:00
Jonas Kvinge
53c72d4f8e CollectionModel: Don't use artist sort text for album 2024-12-17 22:38:04 +01:00
Jonas Kvinge
f971c92f32 Move debian back to source dir
PPA failed to build
2024-12-17 21:57:37 +01:00
Strawberry Bot
82156e8a13 New translations 2024-12-17 00:01:04 +01:00
dependabot[bot]
6a6285861e Bump actions/checkout from 3 to 4
Bumps [actions/checkout](https://github.com/actions/checkout) from 3 to 4.
- [Release notes](https://github.com/actions/checkout/releases)
- [Changelog](https://github.com/actions/checkout/blob/main/CHANGELOG.md)
- [Commits](https://github.com/actions/checkout/compare/v3...v4)

---
updated-dependencies:
- dependency-name: actions/checkout
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
2024-12-16 23:59:25 +01:00
Jonas Kvinge
dae8c8730b debian: Remove whitespaces 2024-12-14 18:33:40 +01:00
Jonas Kvinge
20b47eae8f CI: Use -j 4 for Ubuntu 2024-12-14 18:33:29 +01:00
Jonas Kvinge
2ce8220d88 Move generated files to binary directory 2024-12-14 17:59:26 +01:00
Jonas Kvinge
35b0b5df57 CMake: Fix backtrace linking 2024-12-14 15:47:45 +01:00
Jonas Kvinge
63631d6b0c CMake: Fix backtrace linking 2024-12-14 05:30:31 +01:00
Jonas Kvinge
21ab2ef1a7 CI: Add FreeBSD and OpenBSD 2024-12-14 05:01:40 +01:00
Jonas Kvinge
a3f96d2b85 CMake: Link Backtrace 2024-12-14 05:01:14 +01:00
Jonas Kvinge
e2c1cb0116 Formatting 2024-12-14 00:55:53 +01:00
Jonas Kvinge
07e295776b Add Spotify to scrobbler 2024-12-10 01:29:57 +01:00
Jonas Kvinge
8604a39d94 Turn on git revision 2024-12-08 17:29:14 +01:00
Jonas Kvinge
315240fec7 Release 1.2.3 2024-12-08 16:21:28 +01:00
Jonas Kvinge
fbc6d326f8 Update Changelog 2024-12-08 16:15:24 +01:00
Strawberry Bot
c082377e7a New translations 2024-12-07 19:21:29 +01:00
Jonas Kvinge
448445a38a CI: Replace redhat-lsb-core with lsb_release 2024-12-07 14:42:15 +01:00
Jonas Kvinge
18f835d7e5 Mpris2: Check for valid current row 2024-12-07 14:36:44 +01:00
Jonas Kvinge
fd427dac29 Handle missing HTTP status code 2024-12-07 14:02:59 +01:00
Jonas Kvinge
e1afe03d51 Check for valid http status code 2024-12-07 00:32:06 +01:00
Jonas Kvinge
1b49653974 Update Changelog 2024-12-06 23:55:25 +01:00
Jonas Kvinge
d66126f998 GstEngine: Add missing seek
Fixes #1568
2024-12-06 23:44:27 +01:00
Jonas Kvinge
0fff5f672a Rename variables 2024-12-06 23:43:44 +01:00
Strawberry Bot
2726f01fb3 New translations 2024-12-04 22:41:27 +01:00
Jonas Kvinge
9a74fce53d DiscogsCoverProvider: Use anonymous namespace for constants 2024-12-02 22:01:00 +01:00
Jonas Kvinge
b3be8387f1 Song: Add .zst to rejected file extensions
Fixes #1612
2024-11-29 23:37:49 +01:00
Jonas Kvinge
d396cb515d Include cstddef before libcdio includes
Fixes #1610
2024-11-29 22:50:49 +01:00
Jonas Kvinge
2548b4648e Turn on git revision 2024-11-23 19:34:13 +01:00
Jonas Kvinge
df0ec6b709 Release 1.2.2 2024-11-23 17:25:42 +01:00
Jonas Kvinge
376af26f0e Playlist: Move new QMimeData 2024-11-23 15:19:31 +01:00
Jonas Kvinge
9bff55e1ee PlaylistView: Ignore invalid QHeaderView::sectionResized
Workaround a possible Qt bug: moving a song in the playlist triggers `QHeaderView::sectionResized` with the state reset for each column, this causes an an invalid state for the last column since SetHeaderState is called before the last column state is restored, which again is used when restoring the playlist columns after switching to different playlist. To workaround this, only call SetHeaderState when the new column size is not zero.
2024-11-23 11:07:15 +01:00
Jonas Kvinge
8f7e29f503 PlaylistView: Use constants 2024-11-23 10:56:29 +01:00
Jonas Kvinge
c3aa885a0f SmartPlaylistSearchPreview: Remove early SetItemDelegates
It's called too early before MoodbarLoader is set, Init() already calls SetItemDelegates.

Fixes #1609
2024-11-22 17:04:42 +01:00
Jonas Kvinge
77ea5729c3 Turn on git revision 2024-11-21 18:34:29 +01:00
Jonas Kvinge
fac323a4a5 Release 1.2.1 2024-11-21 16:05:21 +01:00
Jonas Kvinge
a26066d70f Disconnect tagreader reply metaobject connection in lambda
Otherwise the tagreader reply is deleted to early causing crashes.
2024-11-21 15:59:07 +01:00
Strawberry Bot
d500d38e63 Update translations 2024-11-20 19:10:59 +01:00
Jonas Kvinge
295d4d9d05 Update strawberry_en_US.ts 2024-11-20 19:09:45 +01:00
Jonas Kvinge
01aaa0ba0b Disable SPMediaKeyTap
Workaround issue #1606
2024-11-20 18:12:20 +01:00
Jonas Kvinge
7b23118475 BehaviourSettingsPage: Disable song progress on taskbar for macOS 2024-11-19 06:52:23 +01:00
Jonas Kvinge
0c7806ab0a Turn on git revision 2024-11-17 07:34:18 +01:00
Jonas Kvinge
93c10fd77d Release 1.2.1-rc1 2024-11-16 06:08:33 +01:00
Jonas Kvinge
14e8cc511a Update .gitignore 2024-11-16 05:56:28 +01:00
Jonas Kvinge
7674bd1926 Update Changelog 2024-11-16 04:57:55 +01:00
Jonas Kvinge
be351f3118 Update Changelog 2024-11-16 04:56:02 +01:00
Jonas Kvinge
47aa0b05b6 Update Changelog 2024-11-16 04:53:26 +01:00
Jonas Kvinge
6d32cc9c4e nsi: Add back giognutls 2024-11-14 22:24:48 +01:00
Jonas Kvinge
fd9f4575eb CI: Copy all GIO modules for MSVC 2024-11-14 22:23:31 +01:00
Jonas Kvinge
c62fd2b58a GstEnginePipeline: Add more logging for fader 2024-11-14 22:05:06 +01:00
Jonas Kvinge
712db598f7 GstEnginePipeline: Fix setting volume after fader timeout 2024-11-14 22:04:53 +01:00
Jonas Kvinge
0cccc30c98 CI: Add Fedora 42 2024-11-14 18:57:13 +01:00
Jonas Kvinge
19e6ebe9c4 CI: Only copy gioopenssl for MSVC 2024-11-14 18:57:13 +01:00
Jonas Kvinge
24ed5413b2 nsi: Remove giognutls from MSVC 2024-11-14 18:57:13 +01:00
Jonas Kvinge
a239c127bd CI: Enable Spotify for MSVC 2024-11-14 18:57:13 +01:00
Jonas Kvinge
61daec6597 nsi: Add back Spotify 2024-11-14 18:57:13 +01:00
Jonas Kvinge
544db75eb4 main: Move GstStartup::Initialize after QApplication 2024-11-14 18:56:23 +01:00
Strawberry Bot
6a60eff5cd Update translations 2024-11-12 23:46:46 +01:00
Jonas Kvinge
63aa04241c Update Changelog 2024-11-12 23:45:39 +01:00
Jonas Kvinge
7a7550388d Rename KDE global shortcuts to KGlobalAccel 2024-11-12 23:03:57 +01:00
Jonas Kvinge
f2845b6632 Remove deprecated gnome/mate SettingsDaemon global shortcuts 2024-11-12 22:38:21 +01:00
Jonas Kvinge
deaeab3cbb CMake: Fix build without Chromaprint 2024-11-12 20:15:10 +01:00
Jonas Kvinge
16c9a0f974 GstEnginePipeline: Set final fader volume on timeout 2024-11-11 16:17:57 +01:00
Jonas Kvinge
18000b1b2c GstEnginePipeline: Increase fader timeout 2024-11-11 16:17:35 +01:00
Jonas Kvinge
f1b56028b7 GstEnginePipeline: Use fully-qualified names for QTimeLine 2024-11-11 16:17:11 +01:00
Jonas Kvinge
3d2315f754 GstEnginePipeline: Add mutex locker for Spotify access token 2024-11-11 16:16:29 +01:00
Jonas Kvinge
07c898581c CommandlineOptions: Pass absolute paths for urls 2024-11-11 16:15:06 +01:00
Jonas Kvinge
6612eeb9e3 GstEnginePipeline: Simplify next uri reset code 2024-11-10 15:38:00 +01:00
Jonas Kvinge
04064ebf68 mutex_protected: Return bool for operator== 2024-11-10 15:37:35 +01:00
Jonas Kvinge
3de3c52c01 Update Changelog 2024-11-10 02:18:58 +01:00
Jonas Kvinge
93929c73ee GstEnginePipeline: Add fader timeout 2024-11-10 02:07:22 +01:00
Jonas Kvinge
d68bede374 GstEnginePipeline: Fix fader fudge timer naming 2024-11-10 01:53:38 +01:00
Jonas Kvinge
b659b27f95 GstEnginePipeline: Replace QBasicTimer with QTimer 2024-11-10 01:50:53 +01:00
Jonas Kvinge
70d0772e04 GstEnginePipeline: Add separate set state async function 2024-11-10 01:36:48 +01:00
Jonas Kvinge
0a361bfb3b BackendSettingsPage: Add HAVE_ALSA 2024-11-10 01:23:39 +01:00
Jonas Kvinge
f9f47458d5 Remove engine type 2024-11-10 01:21:43 +01:00
Jonas Kvinge
218dd439b6 Player: Use shared pointer for engine 2024-11-10 01:21:25 +01:00
Jonas Kvinge
7f3293609b Player: Always use GStreamer 2024-11-10 01:11:43 +01:00
Jonas Kvinge
356b7d8e64 MainWindow: Remove engine changed 2024-11-10 01:11:01 +01:00
Jonas Kvinge
d26c291a2a BackendSettingsPage: Remove engine setting 2024-11-10 01:10:04 +01:00
Jonas Kvinge
82d34eea7b FilesystemDevice: Ignore compile warning C4250 2024-11-10 00:30:01 +01:00
Jonas Kvinge
4b0b0aa989 Player: Simplify creating engine 2024-11-10 00:16:04 +01:00
Jonas Kvinge
975d0dff25 Move GstStartup 2024-11-09 23:39:31 +01:00
Jonas Kvinge
b75410abc6 Song: Remove spaces and replace semicolon with slash in MBID's
Fixes #1581
2024-11-09 20:23:34 +01:00
Jonas Kvinge
c0f5b53aaf GstEnginePipeline: Simplify checking for NULL state 2024-11-09 19:36:41 +01:00
Jonas Kvinge
ba285925ca GstEnginePipeline: Check that state is actually NULL before finishing pipeline
Possible fix for #1582
2024-11-09 19:30:28 +01:00
Jonas Kvinge
a0dd2c66e4 GstEnginePipeline: Always set state to NULL 2024-11-09 19:26:39 +01:00
Jonas Kvinge
64a9d557a4 GstEnginePipeline: Add missing declarations 2024-11-09 19:26:09 +01:00
Jonas Kvinge
3a5e5d4aaa GstEngine: Improve pipeline finish handling 2024-11-09 19:24:07 +01:00
Jonas Kvinge
f59c6c356e GstEnginePipeline: Get audio-sink 2024-11-09 19:22:56 +01:00
Jonas Kvinge
65b6e6d540 GstEnginePipeline: Save fader state 2024-11-09 19:21:56 +01:00
Jonas Kvinge
0d2e933ed1 MoodbarProxyStyle: Stop timeline if already running 2024-11-09 19:18:38 +01:00
Jonas Kvinge
b16fbb3040 PlaylistView: Check timeline not running instead of running 2024-11-09 19:18:16 +01:00
Jonas Kvinge
638fc2881c ContextAlbum: Use fully-qualified QTimeLine::Direction and QTimeLine::State 2024-11-09 18:08:58 +01:00
Jonas Kvinge
2656cfd3ad ContextAlbum: Stop timeline if not running 2024-11-09 18:08:24 +01:00
Jonas Kvinge
80c5829792 CMake: Make QtSparkle optional
Fixes #1595
2024-11-08 21:39:35 +01:00
Jonas Kvinge
957a850adc FilterParser: Fix "OR" and "AND"
Fixes #1599
2024-11-08 21:39:35 +01:00
Jonas Kvinge
2a5e425b71 FavoriteWidget: Add parameter names 2024-11-08 21:39:35 +01:00
Jonas Kvinge
904ffb1417 TagReaderTagLib: Handle multiple values for ID3v2 tags 2024-11-08 21:39:35 +01:00
Jonas Kvinge
777fec9a92 Playlist: Remove deleteLater() as it uses QSharedPointer 2024-11-08 21:36:43 +01:00
Jonas Kvinge
a2017c003e CollectionModel: Always create QNetworkDiskCache
Fixes #1593
2024-11-03 16:29:41 +01:00
Jonas Kvinge
95842225fb FancyTabBar: Remove newlines 2024-11-03 04:44:28 +01:00
Jonas Kvinge
7cfb175a45 FancyTabWidget: Move functions 2024-11-03 04:42:44 +01:00
Jonas Kvinge
b7165e0124 FancyTabWidget: Use tab pointer directly 2024-11-03 04:41:26 +01:00
Jonas Kvinge
7132b06d6a Move nsi file to binary directory 2024-11-02 15:02:07 +01:00
Jonas Kvinge
4f79b8692c FancyTabWidget: Only set text and tooltip for inserted tab 2024-11-02 15:01:48 +01:00
Jonas Kvinge
a8e307bb6a Playlist: Only move album for current row first
The logic was flawed as current_virtual_index_ can be set even when current_row isn't causing crash.

Fixes #1588
2024-11-02 01:52:01 +01:00
Jonas Kvinge
a30aca4759 FancyTabWidget: Set tab text after setting data
Fixes crash when enabling a tab.
2024-11-02 01:29:44 +01:00
Jonas Kvinge
4c0220d10a FancyTabBar: Check that tab data is valid 2024-11-02 01:29:44 +01:00
Strawberry Bot
5fede2551e Update translations 2024-11-02 00:41:10 +01:00
Jonas Kvinge
e83b521ee0 Add const 2024-11-01 23:23:46 +01:00
Jonas Kvinge
8da2b9cd94 Refactoring 2024-11-01 23:04:42 +01:00
Jonas Kvinge
dfcf715291 nsi: Disable Spotify 2024-10-26 17:30:18 +02:00
Erriez
24c89b8ca3 nsi: Update ICU dependencies after update to 76.1 2024-10-26 17:19:31 +02:00
Jonas Kvinge
b106e94494 CMake: Add missing STATIC for strawberry_lib
Fixes #1580
2024-10-23 18:16:13 +02:00
Jonas Kvinge
28222b1832 Translations: Remove QObject 2024-10-21 00:30:12 +02:00
Jonas Kvinge
c818dabe92 Remove Pot translator 2024-10-21 00:29:21 +02:00
Jonas Kvinge
60f4a57425 tests: Port to QStringLiteral operator 2024-10-20 23:19:38 +02:00
Jonas Kvinge
a9ea686577 Fix unit tests 2024-10-20 22:54:33 +02:00
Jonas Kvinge
756f7cf6af CMake: Fix finding qplatformnativeinterface.h 2024-10-20 22:52:41 +02:00
Jonas Kvinge
ef9ef63f02 Port to QStringLiteral operator 2024-10-20 06:38:55 +02:00
Jonas Kvinge
722035913e BehaviourSettingsPage: Remove duplicate English language 2024-10-20 01:12:01 +02:00
Jonas Kvinge
50aa2dcc2b CMake: Prefix TS_FILES path with CMAKE_SOURCE_DIR 2024-10-20 01:11:39 +02:00
Jonas Kvinge
b6cbebcc8a CMake: Only run lupdate on strawberry_en_US.ts 2024-10-20 00:50:41 +02:00
Strawberry Bot
ba127c57d8 Update translations 2024-10-20 00:32:49 +02:00
Jonas Kvinge
ef261455a2 Update Changelog 2024-10-20 00:11:07 +02:00
Jonas Kvinge
1b1ab2e833 Port to Qt translations 2024-10-20 00:06:42 +02:00
Jonas Kvinge
fbf7fa51e5 CMake: Remove unused QT_DBUSXML2CPP_EXECUTABLE 2024-10-19 22:19:24 +02:00
Jonas Kvinge
b0d2da04ac EditTagDialog: Move hint texts to class 2024-10-19 21:53:22 +02:00
Strawberry Bot
0ab16c9ebf Update translations 2024-10-18 21:55:21 +02:00
Jonas Kvinge
d930ee205f CI: Turn off spotify for Windows MSVC 2024-10-18 21:54:28 +02:00
Jonas Kvinge
0e330b81db Use Qt::Literals::StringLiterals 2024-10-18 20:17:23 +02:00
Jonas Kvinge
6931538ebf Update README.md 2024-10-18 19:58:50 +02:00
Jonas Kvinge
b166396ef3 Update Changelog 2024-10-18 19:58:40 +02:00
Jonas Kvinge
026c2677f9 PlaylistManager: Use album artist for new playlist name 2024-10-18 19:58:34 +02:00
Jonas Kvinge
34e2e01992 CollectionWatcher: Monitoring always on for devices 2024-10-18 19:58:04 +02:00
Jonas Kvinge
7b2d8ac1a2 CMake: Simplify linking 2024-10-07 20:51:38 +02:00
Jonas Kvinge
256cc7d15c SongLoader: Try resolve symbolic links to match collection directory 2024-10-06 15:42:03 +02:00
Jonas Kvinge
1d9b8f464a CMake: Only include Qobuz cover provider if Qobuz is enabled 2024-10-06 14:42:48 +02:00
Jonas Kvinge
a8d1bf7e73 CollectionModel: Use song sort text if any group by is set to album
Fixes #1573
2024-10-06 14:39:14 +02:00
Jonas Kvinge
c58207dd2f CMake: Specify languages 2024-10-06 01:10:28 +02:00
Jonas Kvinge
1720ddc808 CMake: Remove unneeded windres and RC compiler hack 2024-10-06 01:10:03 +02:00
Jonas Kvinge
056d8817b2 main: Use QLocale::TagSeparator::Underscore 2024-10-05 15:43:29 +02:00
Jonas Kvinge
e12f27a945 Translations: Add debug logging 2024-10-05 15:43:03 +02:00
Jonas Kvinge
39fd89cb90 main: Use Qt stringliterals 2024-10-05 15:41:57 +02:00
Jonas Kvinge
756215544a GlobalShortcutsManager: Fix incorrect ifdef 2024-10-04 22:18:02 +02:00
Jonas Kvinge
0768298b95 Refactor CMake files 2024-10-04 22:05:20 +02:00
Jonas Kvinge
525ebbb9b7 CollectionModel: Fix updating song when disc is changed 2024-10-04 16:56:59 +02:00
Jonas Kvinge
c47ec3e70a DynamicPlaylistControls: Use QPalette::AlternateBase 2024-10-04 16:29:21 +02:00
Jonas Kvinge
20394271c7 DynamicPlaylistControls: Replace u'%' with u"%"_s
Fixes #1572
2024-10-04 16:29:04 +02:00
Strawberry Bot
731f670a2b Update translations 2024-10-01 21:14:11 +02:00
Jonas Kvinge
d35c8e5b93 CI: Ignore translations commits 2024-10-01 21:10:50 +02:00
Strawberry Bot
b1161d3542 Update translations 2024-10-01 20:49:57 +02:00
Jonas Kvinge
47a01fc659 CMake: Remove Spotify GStreamer dependency 2024-10-01 20:46:53 +02:00
Jonas Kvinge
d72694ce06 CollectionModel: Only use song sort text if album is the parent group by 2024-09-30 17:14:43 +02:00
Jonas Kvinge
85af736bfd CI: Add back Windows x86 builds 2024-09-30 00:36:01 +02:00
Jonas Kvinge
b50da3eba4 GstEnginePipeline: Add missing end of stream
A bug was introduced when I added the mutex locker for the URLs, it did nothing when it was supposed to emit end of stream.

Fixes #1568
2024-09-29 23:40:09 +02:00
Jonas Kvinge
4479daeaf1 GstEngine: Finish pipeline before resetting in end of stream 2024-09-29 23:35:14 +02:00
Jonas Kvinge
a123de06c6 GstEngine: Add mutex lock for checking stream url 2024-09-29 23:33:47 +02:00
Jonas Kvinge
62f2aee00c README: Remove tagparser and add Qt D-Bus 2024-09-29 11:56:00 +02:00
Jonas Kvinge
b59cc4d038 TagReaderTagLib: Set source and init from file 2024-09-29 03:25:06 +02:00
Jonas Kvinge
3468737e14 Song: Add init from file setter 2024-09-29 03:24:44 +02:00
Jonas Kvinge
5292e53b4a CMake: Remove GStreamer optional component 2024-09-28 16:43:13 +02:00
Jonas Kvinge
bae3fcfaba Update Changelog 2024-09-28 16:38:36 +02:00
Jonas Kvinge
e4a57aa768 Remove VLC 2024-09-28 16:38:23 +02:00
Jonas Kvinge
25451d361c CI: Remove unused CMake options 2024-09-28 15:38:14 +02:00
Jonas Kvinge
daaacf4663 Remove external tagreader 2024-09-28 15:29:10 +02:00
Jonas Kvinge
3cb0f60900 Add missing names for parameter variables 2024-09-28 12:32:12 +02:00
Jonas Kvinge
f2e28d18bc Player: Initialize variable 2024-09-28 12:27:51 +02:00
Jonas Kvinge
6cb54b9f9f MimeData: Remove useless initialization 2024-09-28 12:27:33 +02:00
Jonas Kvinge
ce3db115a3 MainWindow: Remove unused variable 2024-09-28 12:27:02 +02:00
Jonas Kvinge
dae4943593 Replace Spotify username/password with access token 2024-09-28 00:09:23 +02:00
Jonas Kvinge
ca8aa40034 SystemTrayIcon: Add missing visible method 2024-09-27 20:42:24 +02:00
Jonas Kvinge
a239374c4b MainWindow: Simplify hiding to tray logic 2024-09-27 19:44:02 +02:00
Jonas Kvinge
1c833a28dc BehaviourSettingsPage: Remember keep running option 2024-09-27 18:35:22 +02:00
Jonas Kvinge
c30de78bf1 BehaviourSettingsPage: Add const 2024-09-27 18:21:42 +02:00
Jonas Kvinge
19b3adeb96 MainWindow: Keep running require system tray icon
Fixes bug where Strawberry remains running when system tray icon is disabled.
2024-09-27 18:13:38 +02:00
Jonas Kvinge
4b55150515 PlaylistListView: Remove newlines from tr text
Fixes #1564
2024-09-26 02:33:50 +02:00
Strawberry Bot
5bcfd5dd25 Update translations 2024-09-26 01:21:58 +02:00
Jonas Kvinge
722f93b090 CMake: Use CMAKE_COMPILE_WARNING_AS_ERROR 2024-09-26 01:08:47 +02:00
Jonas Kvinge
1ef50333a6 UWPDeviceFinder: Silence codecvt deprecation warning 2024-09-26 01:06:15 +02:00
Jonas Kvinge
fa6ac4df41 Include fixes 2024-09-25 23:52:56 +02:00
Jonas Kvinge
517a8baea2 Fix missing includes 2024-09-24 21:35:31 +02:00
Jonas Kvinge
5473a6f8ac CollectionTask: Replace QtClassHelperMacros with QtGlobal 2024-09-24 20:51:12 +02:00
Jonas Kvinge
4d4dd6b249 Replace QVector with QList 2024-09-24 20:47:43 +02:00
Jonas Kvinge
2e6408a4f7 Remove unneeded includes 2024-09-24 20:41:11 +02:00
Jonas Kvinge
3c984ac8cf AnalyzerContainer: Add missing newlines 2024-09-24 20:40:45 +02:00
Jonas Kvinge
e52ea2a255 Add parameter variable names 2024-09-24 20:40:35 +02:00
Jonas Kvinge
cf22b183a5 Move gstfastspectrum to src 2024-09-24 16:29:19 +02:00
Jonas Kvinge
11d4151a82 CollectionWatcher: Mark variable unused
Fixes #1560
2024-09-24 16:28:39 +02:00
Jonas Kvinge
c5f9e43d10 CollectionWatcher: Remove unused ctor 2024-09-24 16:27:47 +02:00
Jonas Kvinge
3329bc7d76 CollectionWatcher: Add missing newline 2024-09-24 16:27:32 +02:00
Jonas Kvinge
4c8ada2b80 CollectionWatcher: Add missing const 2024-09-24 16:27:09 +02:00
Jonas Kvinge
6b446eb693 CollectionWatcher: Fix typos 2024-09-24 16:26:08 +02:00
Jonas Kvinge
1663fa3ef1 ebur128analysis: Fix typo 2024-09-24 16:25:23 +02:00
Jonas Kvinge
7da0df2178 CMake: Exclude -Wno-missing-declarations on MSVC 2024-09-23 23:38:36 +02:00
Jonas Kvinge
254c442a69 kdsingleapplication: Add -Wno-missing-declarations 2024-09-23 23:33:22 +02:00
Jonas Kvinge
0568c47a37 Build with -Werror by default 2024-09-23 23:26:58 +02:00
Jonas Kvinge
c9c6c2ad12 libstrawberry-tagreader: Add -Wno-missing-declarations 2024-09-23 23:25:14 +02:00
Jonas Kvinge
f8ce2f1705 Remove MacFSListener
It's no longer needed. This code dates back to before Qt had a FSEvents-based filesystem listener.
2024-09-23 16:05:02 +02:00
Jonas Kvinge
f9c35edd7c Update debian/copyright 2024-09-23 16:01:34 +02:00
Jonas Kvinge
4cd490d871 gstfastspectrum: Use G_GUINT64_FORMAT 2024-09-23 16:00:27 +02:00
Jonas Kvinge
936521981b README: Update required TagLib version 2024-09-22 22:24:59 +02:00
Jonas Kvinge
fa96cdfaea MoodbarPipeline: Add newline 2024-09-22 21:40:50 +02:00
Jonas Kvinge
2c13942ed5 MoodbarPipeline: Remove unused include 2024-09-22 21:39:00 +02:00
Jonas Kvinge
af8a7d5093 MoodbarPipeline: Rename variables 2024-09-22 20:43:44 +02:00
Jonas Kvinge
04eb97ef93 MoodbarPipeline: Remove unused NewBufferCallback 2024-09-22 20:39:25 +02:00
Jonas Kvinge
0b49dcaa2d Remove 3rdparty/SPMediaKeyTap 2024-09-22 13:15:35 +02:00
Jonas Kvinge
c3008b4179 Silence Clang Wunused-const-variable 2024-09-22 13:15:19 +02:00
Jonas Kvinge
28a29d219e moodbar: Formatting 2024-09-22 12:41:22 +02:00
Strawberry Bot
0919d5d3de Update translations 2024-09-22 00:54:47 +02:00
Christian Kr
167e0d73d1 Add icons only sidebar mode 2024-09-22 00:12:17 +02:00
Jonas Kvinge
d87560b73e Update Changelog 2024-09-21 23:17:13 +02:00
Jonas Kvinge
e6607fef6e Bump version to 1.2.0 2024-09-21 23:16:37 +02:00
Jonas Kvinge
f815b2b699 Turn on git revision 2024-09-21 23:12:15 +02:00
Jonas Kvinge
247c0ae46a Release 1.1.3 2024-09-21 23:12:05 +02:00
Jonas Kvinge
f62d22f94a CI: Upload PPA on 1.1 branch 2024-09-21 23:11:53 +02:00
Jonas Kvinge
78a9cb35a3 filterparser: Optimize filter term
Fixes #1536
2024-09-21 00:57:36 +02:00
Jonas Kvinge
e72b001d02 FilterParser: Add check for empty column 2024-09-20 23:51:25 +02:00
Jonas Kvinge
5bdbb9f13f appdata: Update description 2024-09-19 16:06:36 +02:00
Jonas Kvinge
0e7ab1cab8 GeniusLyricsProvider: Convert client ID and secret from base64
Fixes #1554
2024-09-18 22:51:28 +02:00
Jonas Kvinge
f11de5bfc2 CI: Fix source upload path 2024-09-17 23:15:01 +02:00
Jonas Kvinge
6d68f7f008 GstEngine: Don't set state to play if already playing 2024-09-17 22:23:17 +02:00
Jonas Kvinge
2bed827eb6 gstfastspectrum: Use %lu in GST_LOG_OBJECT 2024-09-17 22:19:01 +02:00
Jonas Kvinge
98cfef3306 gstfastspectrum: Change guint to guint64 2024-09-17 22:13:11 +02:00
Jonas Kvinge
f44839137c GstEngine: Use beginning nanosec on play
Fixes #1549
2024-09-16 00:34:39 +02:00
Jonas Kvinge
0decbdc2fb nsi: Move libgetopt.dll to minw section 2024-09-13 20:55:27 +02:00
Jonas Kvinge
23b5ceb6c9 Remove 3rdparty\getopt 2024-09-13 20:41:23 +02:00
Jonas Kvinge
4b36beec40 Remove macdeploycheck 2024-09-13 19:56:50 +02:00
Alexander Bikadorov
b60ca9f6fa Settings: Add "Restart or previous" global shortcut 2024-09-13 19:54:47 +02:00
Jonas Kvinge
718c24ee47 spec: Remove Qt 5 specific requires 2024-09-13 00:41:59 +02:00
Jonas Kvinge
86dd2886d2 Settings: Remove compatibility code 2024-09-13 00:41:35 +02:00
Jonas Kvinge
23fb4651be Remove remaining X11Extras stuff 2024-09-13 00:30:37 +02:00
Jonas Kvinge
877c9ca41a CurrentAlbumCoverLoader: Should be not empty 2024-09-12 23:57:40 +02:00
Jonas Kvinge
99fb775e30 CurrentAlbumCoverLoader: Port away from QTemporaryFile 2024-09-12 23:09:38 +02:00
Jonas Kvinge
1bb764a2d2 CurrentAlbumCoverLoader: Use standard temp location
Addresses #1540
2024-09-12 23:00:36 +02:00
Jonas Kvinge
a3eab902ff SpotifySettingsPage: Fix gst reg lookup leak 2024-09-12 22:55:52 +02:00
Jonas Kvinge
e9684cd1a1 Move gstfastspectrum to 3rdparty 2024-09-12 22:51:01 +02:00
Jonas Kvinge
9ae0afaaf7 Require TagLib 1.12 or newer 2024-09-12 22:15:13 +02:00
Jonas Kvinge
48bb5a3e9f PlaylistListModel: Use const_iterator 2024-09-12 22:13:21 +02:00
Jonas Kvinge
f642513587 StreamingSearchView: Use const_iterator 2024-09-12 22:13:21 +02:00
Jonas Kvinge
255623bbfd Replace QStringLiteral with u""_s operator 2024-09-12 22:13:21 +02:00
Jonas Kvinge
4270b12cd1 Replace QLatin1String with operator _L1 2024-09-12 22:13:21 +02:00
Jonas Kvinge
e3e6a22172 Drop Qt 5 support
Qt 6 has been available for almost 4 years. Qt 5 is no longer officially supported by Qt for opensource, it's time to drop Qt 5.
2024-09-12 22:13:21 +02:00
Strawberry Bot
eb30c654c5 Update translations 2024-09-12 22:12:34 +02:00
Jonas Kvinge
3b925c24ad Turn on git revision 2024-09-12 21:57:12 +02:00
Jonas Kvinge
beefdabc64 Release 1.1.2 2024-09-12 19:49:52 +02:00
Jonas Kvinge
91e06cadf3 Update Changelog 2024-09-12 19:49:23 +02:00
Jonas Kvinge
4ea5eb8292 GstEnginePipeline: Set volume internal in notify volume callback
Fixes #1541
2024-09-10 17:04:24 +02:00
Jonas Kvinge
af06f8e70a Playlist: Remove flawed sorting logic for filename
Possible fix for #1538
2024-09-08 13:12:13 +02:00
Jonas Kvinge
3238e295ba Update Changelog 2024-09-07 16:45:33 +02:00
Jonas Kvinge
26fbd5c144 Update 3rdparty/README.md 2024-09-07 16:42:43 +02:00
Jonas Kvinge
e64a2b98c4 Turn on git revision 2024-09-07 01:17:57 +02:00
Jonas Kvinge
42417e5554 Release 1.1.2-rc1 2024-09-06 23:08:22 +02:00
Jonas Kvinge
82e613206e CollectionQuery: Add const 2024-09-06 22:58:21 +02:00
Jonas Kvinge
f1038152e9 Update Changelog 2024-09-06 22:31:12 +02:00
Jonas Kvinge
2597a8faed CMake: Add option to turn off debug output 2024-09-03 23:41:49 +02:00
Jonas Kvinge
8008ec895a logging: Respect QT_NO_INFO_OUTPUT 2024-09-03 23:10:55 +02:00
Jonas Kvinge
d85d25b931 TagReaderTagLib: Use Strawberry for editor 2024-09-03 23:10:16 +02:00
Jonas Kvinge
de62552ad1 AlbumCoverManager: Queue album cover loading using timer
Helps reduce memory growth.
2024-09-03 22:02:05 +02:00
Jonas Kvinge
155485173b AlbumCoverLoader: Process tasks using timer
Helps reduce memory growth.
2024-09-03 22:01:13 +02:00
Strawberry Bot
82079fcf70 Update translations 2024-09-03 01:56:28 +02:00
Jonas Kvinge
3b2eea5292 nsi: Add utf8_validity.dll 2024-09-02 23:56:26 +02:00
Jonas Kvinge
1f2ad9c177 CI: Manually sign libutf8_validity.dylib 2024-09-02 23:51:47 +02:00
Jonas Kvinge
cc6e5a6c69 TagReaderTagLib: Handle multiple mbids for MP4
Fixes #1531
2024-09-02 23:48:25 +02:00
Jonas Kvinge
c77c7a247a ListenBrainzScrobbler: Split work mbids 2024-09-02 23:46:13 +02:00
Jonas Kvinge
552440f50e Add mutexes 2024-09-02 22:27:45 +02:00
Jonas Kvinge
2a9ccd7480 Set object names 2024-09-02 22:26:36 +02:00
Jonas Kvinge
f265c055a5 metatypes: Add LyricsSearchResults 2024-09-02 22:25:12 +02:00
Jonas Kvinge
837e5388ea CMake: Use target_link_directories 2024-08-27 19:39:53 +02:00
Jonas Kvinge
9883dc6925 TemporaryFile: Use int 2024-08-25 18:09:09 +02:00
Jonas Kvinge
e3ad00e930 CI: Adjust manual codesign 2024-08-25 18:05:20 +02:00
Jonas Kvinge
6428ae8b3a GPodDevice: Use own temporary file class
QTemporaryFile keeps files open.

Fixes #1527
2024-08-25 17:59:56 +02:00
Jonas Kvinge
07c182d5b8 Add temporary file class 2024-08-25 17:58:27 +02:00
Jonas Kvinge
64aa15842c Organize: Correct debug message 2024-08-25 17:30:09 +02:00
Jonas Kvinge
19c8da06e6 PlaylistTest: Replace forever with Q_FOREVER 2024-08-25 16:58:56 +02:00
Jonas Kvinge
7dd959f4a1 CMake: Skip pot on MSVC 2024-08-25 15:40:18 +02:00
Jonas Kvinge
148ae530d8 Playlist: Add missing reference for Columns 2024-08-25 06:24:55 +02:00
Jonas Kvinge
e75698ee9a CMake: Add QT_NO_KEYWORDS 2024-08-25 06:24:26 +02:00
Jonas Kvinge
80bea31b98 Replace forever with Q_FOREVER 2024-08-25 06:24:02 +02:00
Jonas Kvinge
4ea57d1181 searchfield_mac: Replace emit with Q_EMIT 2024-08-25 06:23:20 +02:00
Jonas Kvinge
854847ca8a nsi: Update ffmpeg DLL's 2024-08-25 05:59:32 +02:00
Jonas Kvinge
bd39e7cb0d smartplaylists: Move classes to own files 2024-08-25 05:49:41 +02:00
Jonas Kvinge
20ef621a20 Rename SearchField 2024-08-25 05:48:37 +02:00
Jonas Kvinge
145c276c97 PlayingWidget: Remove unused variables 2024-08-25 05:46:53 +02:00
Jonas Kvinge
1c5d0dceb1 Replace emit with Q_EMIT 2024-08-25 05:46:17 +02:00
Jonas Kvinge
359f320b06 MacFSListener: Formatting 2024-08-25 05:45:33 +02:00
Jonas Kvinge
108d522dcf OrganizeFormat: Move to own classes 2024-08-25 03:09:11 +02:00
Jonas Kvinge
96e746c508 AlbumCoverLoaderOptions: Fix incorrect enum number 2024-08-25 02:08:12 +02:00
Jonas Kvinge
b2c862e7d5 CollectionModel: Use chrono literals 2024-08-25 02:07:31 +02:00
Jonas Kvinge
9334fe9f24 Remove const from qHash 2024-08-25 01:37:46 +02:00
Jonas Kvinge
b964385024 AlbumCoverLoader: Remove const 2024-08-25 01:16:29 +02:00
Jonas Kvinge
3f3059c98b Replace QLatin1String with QStringLiteral 2024-08-25 01:08:25 +02:00
Jonas Kvinge
8da616491d Replace emit with Q_EMIT 2024-08-25 01:06:30 +02:00
Jonas Kvinge
cb0db8750f CollectionModelUpdate: Remove reference from enum 2024-08-24 23:20:20 +02:00
Jonas Kvinge
08224443e3 MainWindow: Don't use the playlists backend on right click
Fixes #1478
2024-08-24 22:43:16 +02:00
Jonas Kvinge
5c2989196f MainWindow: Fix comments 2024-08-24 22:40:20 +02:00
Jonas Kvinge
4c4c84e104 PlaylistManager: Add methods for accessing playlists 2024-08-24 22:39:55 +02:00
Jonas Kvinge
232399ea28 DynamicPlaylistControls: Make background follow system colors
Fixes #1483
2024-08-24 22:07:46 +02:00
Jonas Kvinge
9d22e4ec07 SongLoader: Use Song::kRejectedExtensions
Fixes #1525
2024-08-24 21:12:19 +02:00
Jonas Kvinge
ee5bc16e47 CollectionWatcher: Use Song::kRejectedExtensions 2024-08-24 21:10:52 +02:00
Jonas Kvinge
74f0f885b9 Song: Add rejected extensions 2024-08-24 21:10:27 +02:00
Jonas Kvinge
b914d9aaba Update translations.pot 2024-08-24 21:09:22 +02:00
Jonas Kvinge
136f150d67 Translations: Remove deprecated sort option 2024-08-24 21:08:00 +02:00
Jonas Kvinge
5b50cbb61b Update .gitignore 2024-08-24 21:03:53 +02:00
Jonas Kvinge
cb3a9bf195 Update translations.pot 2024-08-24 20:44:46 +02:00
Strawberry Bot
cb847951e6 Update translations 2024-08-24 20:43:21 +02:00
Jonas Kvinge
11228f0634 Player: Add missing override 2024-08-24 20:38:08 +02:00
Jonas Kvinge
a0889d60f1 Update translations.pot 2024-08-24 20:21:45 +02:00
Jonas Kvinge
0055ebe8a7 CMake: Move translations.pot to src dir 2024-08-24 20:21:37 +02:00
Jonas Kvinge
58c7a9b9cc Translations: Add --no-location to xgettext 2024-08-24 20:21:20 +02:00
Strawberry Bot
6afc081ff0 Update translations 2024-08-24 20:15:38 +02:00
Jonas Kvinge
2c0ad2fc88 Move lyrics providers to own thread 2024-08-24 20:07:36 +02:00
Jonas Kvinge
77e934beab SpotifyService: Use LoginError 2024-08-24 19:29:00 +02:00
Jonas Kvinge
368022ec43 concurrentrun_test: Remove QtConcurrent include 2024-08-24 19:28:44 +02:00
Jonas Kvinge
69f8ca95bc Add missing reference 2024-08-24 19:28:15 +02:00
Jonas Kvinge
dde8661e93 Use QDateTime::currentSecsSinceEpoch() 2024-08-24 17:28:29 +02:00
Jonas Kvinge
2604e1a0ff Use multi-arg 2024-08-24 17:27:47 +02:00
Jonas Kvinge
e8471bcc66 MusixmatchCoverProvider: Use static QRegularExpression 2024-08-24 17:27:05 +02:00
Jonas Kvinge
d230dd7365 Use fully-qualified namespaces in slot parameters 2024-08-24 17:25:56 +02:00
Jonas Kvinge
74dce24e91 Mpris2: Remove QtDBus include 2024-08-24 17:24:56 +02:00
Jonas Kvinge
bc667a6474 Use static QRegularExpression 2024-08-24 17:23:10 +02:00
Jonas Kvinge
a2cae06582 Remove QtConcurrent include 2024-08-24 17:01:53 +02:00
Jonas Kvinge
5212587055 TagReaderGME: Mark variable unused 2024-08-24 17:00:00 +02:00
Jonas Kvinge
efd42bc68f MusicBrainzClient: Remove unneeded values from qDeleteAll 2024-08-23 20:40:36 +02:00
Jonas Kvinge
ebaa2e7918 BlockAnalyzer: Replace value with at 2024-08-23 20:32:56 +02:00
Jonas Kvinge
7ebcc73a49 More const detach fixes 2024-08-23 20:30:59 +02:00
Jonas Kvinge
be09011bb7 CollectionWatcher: Use mutex for stop and abort 2024-08-23 20:22:18 +02:00
Jonas Kvinge
2778a55e8e SpotifySettingsPage: Update Wiki page URL 2024-08-23 19:16:17 +02:00
Jonas Kvinge
9b5fe3bfd6 GstEnginePipeline: Rename PlaybinProbe to PadProbe 2024-08-23 00:17:33 +02:00
Jonas Kvinge
91eef0d695 GstEnginePipeline: Sort variables 2024-08-23 00:08:14 +02:00
Jonas Kvinge
88704efad8 Add lyricfind.com lyrics provider 2024-08-18 20:35:09 +02:00
Jonas Kvinge
f4e4483392 HtmlLyricsProvider: Remove extra QRegularExpression 2024-08-18 19:58:57 +02:00
Jonas Kvinge
63102bce23 Update Changelog 2024-08-17 23:13:30 +02:00
Jonas Kvinge
8890a3dd0f Delay play until playlists have finished loading
Fixes #1465
2024-08-17 22:38:48 +02:00
Jonas Kvinge
3d9dec2c27 nsi: Add libbrotlienc.dll 2024-08-17 15:39:35 +02:00
Jonas Kvinge
c96ad61c80 CMake: Add QT_NO_SHOW_OLD_QT_WRAP_CPP_WARNING 2024-08-17 14:31:51 +02:00
Jonas Kvinge
acd74d5b54 README: Remove buildbot URL 2024-08-12 23:16:24 +02:00
Strawberry Bot
4808188964 Update translations 2024-08-12 22:36:10 +02:00
Jonas Kvinge
1bb045b3b0 Mpris2: Remove .desktop file extension in DesktopEntry
According to the specifications it should be the desktop entry without .desktop file extension: https://specifications.freedesktop.org/mpris-spec/latest/Media_Player.html#Property:DesktopEntry

Fixes #1516
2024-08-12 21:49:25 +02:00
Jonas Kvinge
bdca60c0ad Add missing const 2024-08-12 18:12:26 +02:00
Jonas Kvinge
8d9c135498 DeviceManager: Remove no longer relevant comment 2024-08-12 01:09:59 +02:00
Jonas Kvinge
0f76482916 GioLister: Remove undef signals 2024-08-12 01:09:33 +02:00
Jonas Kvinge
38eb86bdee CMake: Add QT_NO_SIGNALS_SLOTS_KEYWORDS 2024-08-12 01:09:01 +02:00
Jonas Kvinge
cbce9892d5 Replace slots with Q_SLOTS 2024-08-12 01:06:15 +02:00
Jonas Kvinge
f624b7a331 Add cpp files for classes with only header files 2024-08-12 00:48:16 +02:00
Jonas Kvinge
1ebcd61a75 PlaylistListView: Fix incorrect header guard 2024-08-11 23:30:03 +02:00
Jonas Kvinge
358da72ffe Replace signals with Q_SIGNALS 2024-08-11 23:23:12 +02:00
Jonas Kvinge
9666feca37 GstEngine: Rename variable 2024-08-11 18:40:07 +02:00
Jonas Kvinge
03eb52eac8 GstEngine: Ensure no fading is done with exclusive mode 2024-08-11 17:37:23 +02:00
Jonas Kvinge
6562cc710c GstEngine: Disconnect old pipelines
Fixes #1518
2024-08-11 15:53:41 +02:00
Jonas Kvinge
222001bc13 GstEnginePipeline: Fix buffering 2024-08-11 14:52:00 +02:00
Jonas Kvinge
e93f14248a Update appdata xml file 2024-08-11 00:44:27 +02:00
Jonas Kvinge
7119f1bc81 Add filename and url to text search columns 2024-08-11 00:12:41 +02:00
Jonas Kvinge
548fa3f6ee Wait for set state to finish before deleting pipeline
Setting state to GST_STATE_NULL sometimes blocks, to fix this use the threadpool to set the state to NULL and wait with deleting the pipeline until the state is changed.
This fixes blocking the main thread when switching Spotify songs.
2024-08-10 18:22:56 +02:00
Jonas Kvinge
8ddd309d5d FilterTree: Use Song::PrettyTitle for title
Uses the filename instead if the title tag is emtpy.
2024-08-10 12:43:38 +02:00
Jonas Kvinge
8c8acbb546 GstEnginePipeline: Rename variables 2024-08-09 19:29:12 +02:00
Jonas Kvinge
fe30f27af3 GstEngine: Simplify use of State 2024-08-09 19:26:15 +02:00
Jonas Kvinge
d5d2eaba8a CollectionWatcher: Make const 2024-08-08 17:13:14 +02:00
Jonas Kvinge
e8f64bfe8f CollectionWatcher: Formatting 2024-08-08 17:12:51 +02:00
Jonas Kvinge
79b03993b0 Update .gitignore 2024-08-08 17:12:23 +02:00
Jonas Kvinge
e3b8f9cb8c Windows7ThumbBar: Fix namespace 2024-08-07 01:15:26 +02:00
Jonas Kvinge
819463a865 Use anonymous namespace for constants 2024-08-07 00:52:58 +02:00
Jonas Kvinge
c69777ca39 ContextView: Only update top text when changed 2024-08-06 23:24:58 +02:00
Jonas Kvinge
40f3e828aa ResizableTextEdit: Store current text 2024-08-06 23:23:27 +02:00
Jonas Kvinge
dc8520ebec Move translations.pot to binary directory 2024-08-06 23:05:26 +02:00
Jonas Kvinge
7ffbedf0dd AnalyzerContainer: Fix setting default analyzer 2024-08-06 22:59:26 +02:00
Jonas Kvinge
826fad1ad4 SpotifyRequest: Limit returned albums to queried artists 2024-08-05 18:24:47 +02:00
Jonas Kvinge
1c4d3aebad Rename enums 2024-08-05 17:53:07 +02:00
Jonas Kvinge
ff6e93fc15 CollectionWatcher: Only start transaction with scan on startup
Fixes #1469
2024-08-03 00:44:47 +02:00
Jonas Kvinge
17e88bb97d Add const 2024-08-02 23:35:52 +02:00
Jonas Kvinge
d3dd26c596 GstEnginePipeline: Set Spotify bitrate to 320 2024-08-01 23:22:19 +02:00
Jonas Kvinge
c2a7509e0e Update Changelog 2024-08-01 21:56:44 +02:00
Jonas Kvinge
079040b721 CI: Build on macos-13 for x86 and macos-14 for arm 2024-07-31 20:16:37 +02:00
Strawberry Bot
b80d239820 Update translations 2024-07-31 17:26:35 +02:00
Jonas Kvinge
c3ff43dac2 CI: Build macOS public with spotify 2024-07-30 19:59:09 +02:00
Jonas Kvinge
4ac51afd8f macgstcopy: Add spotify plugin 2024-07-30 19:59:09 +02:00
luzpaz
26eab51698 README: Tweak Repology badge
Use 3 column format + Add header
2024-07-30 16:56:24 +02:00
Jonas Kvinge
388dcf2a1f Fix dtor compile warnings with Clang 2024-07-30 16:34:20 +02:00
Jonas Kvinge
9bfd14d067 FancyTabBar: Add missing override 2024-07-30 16:33:50 +02:00
Jonas Kvinge
061e0562d1 CollectionView: Fix search for this
Fixes #1510
2024-07-29 20:23:42 +02:00
Jonas Kvinge
2ba20b013d Move fancy tabbar classes into separate files 2024-07-29 18:19:41 +02:00
Jonas Kvinge
dc36f87a6e FancyTabWidget: Remove use of QTabBar::tabText
Fixes #1476
Fixes #1389
2024-07-29 17:15:33 +02:00
Jonas Kvinge
e82ecb48b8 PlaylistTabBar: Don't use QTabBar::tabText
Fixes #1499
2024-07-29 16:17:46 +02:00
Jonas Kvinge
c56a134179 Update translations.pot 2024-07-29 13:02:37 +02:00
Jonas Kvinge
11028456ad LocalRedirectServer: Remove unused declaration 2024-07-29 01:53:16 +02:00
Jonas Kvinge
81fcb02974 OpenTidalCoverProvider: Only login when required
Fixes #1500
2024-07-29 00:48:16 +02:00
Jonas Kvinge
5ef4976c53 SpotifyRequest: Remove unused variable 2024-07-28 14:55:42 +02:00
Jonas Kvinge
160356072f TagReaderTagLib: Add missing override 2024-07-28 02:35:35 +02:00
Strawberry Bot
c10df5b634 Update French translations 2024-07-28 01:26:26 +02:00
Jonas Kvinge
70fdd5b0b3 Use anonymous namespace instead of static for constants 2024-07-28 01:24:56 +02:00
Jonas Kvinge
6c1ec51fab README: Add translations URL 2024-07-25 02:30:38 +02:00
Strawberry Bot
66b1c22174 Update translations 2024-07-25 02:27:38 +02:00
Strawberry Bot
97138fd6b9 Update Crowdin configuration file 2024-07-25 01:34:54 +02:00
Jonas Kvinge
03c69be421 Rename translation files 2024-07-25 01:29:40 +02:00
Jonas Kvinge
3a9a952cb0 Add translations.pot 2024-07-24 22:39:05 +02:00
Eri the Switch
3bd0331aa3 Use accumulator for seeking via scrolling
This results in much smoother experience on my touchpad.
The value of 120 was chosen as the most common for mice,
according to Qt 6 documentation.
2024-07-24 20:02:33 +02:00
Eri the Switch
3ecf224d91 Use accumulator for volume scrolling events
This results in much smoother experience on my touchpad.
2024-07-24 20:02:33 +02:00
Jonas Kvinge
37743606a2 CollectionModel: Remove unused ExpandAll function 2024-07-24 19:58:53 +02:00
Jonas Kvinge
58587f4a9a Turn on git revision 2024-07-23 01:14:57 +02:00
Jonas Kvinge
464fde1851 Release 1.1.1 2024-07-22 23:44:17 +02:00
Jonas Kvinge
2639498642 Update Changelog 2024-07-22 23:37:46 +02:00
Jonas Kvinge
49f074737c Remove placeholder text 2024-07-22 20:48:46 +02:00
Jonas Kvinge
3d53a8b434 AppearanceSettingsPage: Remove translatable 2024-07-22 19:00:24 +02:00
Jonas Kvinge
e260433c7a settings: Remove translatable 2024-07-22 18:58:18 +02:00
Jonas Kvinge
88ef8bff0b Update .gitignore 2024-07-22 18:29:43 +02:00
Jonas Kvinge
fbdac36f6f PlaylistView: Adjust initial header layout 2024-07-20 15:19:50 +02:00
Jonas Kvinge
da3876bd83 StretchHeaderView: Properly implement reset 2024-07-20 15:19:28 +02:00
Jonas Kvinge
d303e700ae CollectionFilter: Override mimedata function 2024-07-20 01:55:53 +02:00
Jonas Kvinge
92a1173b9e Remove unused FilterParserRatingComparatorDecorator 2024-07-19 18:18:02 +02:00
Jonas Kvinge
9f7ebb1ac7 CI: Remove Ubuntu mantic and add oracular for PPA 2024-07-19 18:14:10 +02:00
Jonas Kvinge
1a8690e1f2 StretchHeaderView: Make sure section size never is zero
Fixes #1085
2024-07-19 17:51:49 +02:00
Jonas Kvinge
6543e4c5da Use common filter parser for collection and playlist 2024-07-19 17:29:05 +02:00
Jonas Kvinge
dd904fe3c2 Remove unused CollectionQueryOptions class 2024-07-18 02:06:48 +02:00
ajtribick
c14cc6bf0b CMake: Use result of find_program instead of calling xgettext directly 2024-07-18 00:20:25 +02:00
Jonas Kvinge
95c265ffd3 CollectionFilter: Match individual words 2024-07-17 01:41:25 +02:00
Jonas Kvinge
31c1ae68df EditTagDialog: Fix build without MusicBrainz
Fixes #1492
2024-07-17 00:00:17 +02:00
Jonas Kvinge
f2eb0c3b6b CollectionModel: Add ItemNeverHasChildren 2024-07-15 14:28:29 +02:00
Jonas Kvinge
32be33847c CollectionFilter: Move early return 2024-07-15 14:16:56 +02:00
Jonas Kvinge
3100b0c044 CollectionFilter: Use recursive filtering
Fixes #1486
Fixes #1487
2024-07-15 13:44:50 +02:00
Jonas Kvinge
f4ec3ab379 CollectionModel: Don't append artist if song is compilation 2024-07-14 20:21:08 +02:00
Jonas Kvinge
cdd7faa9bb CI: Add Fedora 41 and Ubuntu Oracular 2024-07-14 17:47:43 +02:00
Jonas Kvinge
e7b35aeaf7 CMake: Use find_package CONFIG for Boost 2024-07-14 17:47:43 +02:00
Jonas Kvinge
696256eb5b README: Update macOS and Windows download info 2024-07-14 17:46:11 +02:00
Mikel Pérez
8ad560ce0e simplify CreateElementForMimeType + good practices
suggestions from gstreamer dev slomo on gst's matrix:
- whole static_pad_templates loop can be avoided with
  gst_element_factory_can_src_any_caps
- ffmpeg elements have been av* prefixed for a while now
- should be looking for Muxer instead of Codec/Muxer,
  Encoder/Audio instead of Codec/Encoder/Audio,
  and there are constants for that
2024-07-14 17:24:42 +02:00
Jonas Kvinge
1c71506f62 Turn off git revision 2024-07-14 17:20:58 +02:00
Jonas Kvinge
8bea6ec5b0 Release 1.1.0 2024-07-14 14:55:14 +02:00
Jonas Kvinge
e8144487ee Update Changelog 2024-07-14 14:48:29 +02:00
Jonas Kvinge
41d9d15dda MainWindow: Only show sponsor dialog if update dialog is answered 2024-07-13 18:24:47 +02:00
Jonas Kvinge
124b97c024 Turn on git revision 2024-07-10 21:58:29 +02:00
Jonas Kvinge
98e0b45403 Release 1.1.0-rc4 2024-07-10 20:07:01 +02:00
Jonas Kvinge
1f2b8d8bf6 Rename playlist filter classes 2024-07-10 18:27:17 +02:00
Jonas Kvinge
8327751b91 CollectionFilter: Optimize use of QRegularExpression
Possible fix for #1482
2024-07-09 22:06:42 +02:00
Jonas Kvinge
6417f89596 CollectionFilter: Add std::as_const 2024-07-09 18:06:46 +02:00
Jonas Kvinge
2e53656f44 Turn on git revision 2024-07-09 17:52:21 +02:00
Jonas Kvinge
822cf0ad07 Release 1.1.0-rc3 2024-07-09 16:23:10 +02:00
Jonas Kvinge
67f04a81b3 Playlist: Add data changed when setting current row 2024-07-09 16:21:09 +02:00
Jonas Kvinge
9232ad0125 TagReaderTagLib: Use QString for converting TagLib::String
Converting directly to std::string does not seem to work correctly.
2024-07-09 15:56:07 +02:00
Jonas Kvinge
0de87b3e1e TagReaderTagLib: Use UTF-8 when converting to CString
Fixes #1481
2024-07-09 15:06:07 +02:00
Jonas Kvinge
74b8cd6156 StretchHeaderView: Formatting 2024-07-09 11:35:01 +02:00
Jonas Kvinge
ac959387fe StretchHeaderView: Fix infinite loop
Fixes #1480
2024-07-09 11:14:31 +02:00
Jonas Kvinge
ffd8ce9281 Turn on git revision 2024-07-09 10:44:11 +02:00
Jonas Kvinge
d8052b295f Release 1.1.0-rc2 2024-07-09 04:39:48 +02:00
Jonas Kvinge
625929133c Rename analyzers and add turbine analyzer 2024-07-09 04:39:48 +02:00
Jonas Kvinge
79c28e7e1d sqlite_test: Remove fts5 2024-07-09 03:24:13 +02:00
Jonas Kvinge
01f4a79f07 schema: Bump schema version to 20 2024-07-09 03:19:29 +02:00
Jonas Kvinge
47c5a2215e device-schema: Remove fts5 table 2024-07-09 03:18:43 +02:00
Jonas Kvinge
bb6e38630f Turn on git revision 2024-07-09 03:18:04 +02:00
Jonas Kvinge
85acf69d4f Release 1.1.0-rc1 2024-07-09 02:49:49 +02:00
Jonas Kvinge
69ba56ebef CMake: Fix rc versioning 2024-07-09 02:37:51 +02:00
Jonas Kvinge
527a61f909 OpenTidalCoverProvider: Handle authentication required 2024-07-09 02:37:21 +02:00
Jonas Kvinge
a15ebcde24 Song: Update supported fields for ASF 2024-07-05 21:27:49 +02:00
Jonas Kvinge
e80629cc40 tagreader_test: Add more fields for ASF test 2024-07-05 21:27:24 +02:00
Jonas Kvinge
d956ae9726 TagReaderTagLib: Add consts for all fields, add more support for ASF 2024-07-05 21:26:28 +02:00
Jonas Kvinge
0435d6d7b9 TagReader: Cleanup string functions 2024-07-05 16:21:50 +02:00
Jonas Kvinge
59752e6fe9 CI: Minor adjustments 2024-07-05 00:05:18 +02:00
Jonas Kvinge
d3ee0bfdf4 CI: Use rsync for Windows builds 2024-07-05 00:01:52 +02:00
Jonas Kvinge
463df825f0 nsi: Remove libbrotlienc.dll 2024-07-04 23:21:54 +02:00
Jonas Kvinge
480559ef0b Update Changelog 2024-07-03 20:33:28 +02:00
Jonas Kvinge
2a4fd346f9 Rename QueryType to Type 2024-07-02 18:34:27 +02:00
Jonas Kvinge
6200fed224 Add missing const 2024-07-02 18:33:15 +02:00
Jonas Kvinge
e1b4585dc7 CollectionModel: Minor change in debug log 2024-07-02 17:53:14 +02:00
Jonas Kvinge
c5eb72fa9f SpotifyRequest: Use artist from albums reply 2024-07-02 17:50:55 +02:00
Jonas Kvinge
d2e19ef4c3 SpotifyRequest: Add include_groups for albums query 2024-07-02 17:50:11 +02:00
Jonas Kvinge
4509c43b81 SpotifyRequest: Check for download covers 2024-07-02 17:49:56 +02:00
Jonas Kvinge
e2ffe716e7 SpotifyRequest: Remove unused variable 2024-07-02 17:49:40 +02:00
Jonas Kvinge
0d9ededea9 tagreadermessages: Switch back to proto2 2024-07-01 17:39:42 +02:00
Jonas Kvinge
2edc4369d2 CollectionModel: Only prepend artist on album group by 2024-07-01 17:11:14 +02:00
Jonas Kvinge
32baa95500 Add better error handling for Tag reader 2024-07-01 02:06:42 +02:00
Jonas Kvinge
ad9f3ce078 playlistparsers: Rename collection_search to collection_lookup 2024-07-01 02:06:42 +02:00
Jonas Kvinge
c1f66b1885 CueParser: Remove unused variable 2024-06-29 15:24:54 +02:00
Jonas Kvinge
e0be15cf01 CMakeLists: Add QCoreApplication to SQLite test
Fixes #1471
2024-06-27 18:15:53 +02:00
Jonas Kvinge
93660bfc81 Formatting 2024-06-27 18:00:44 +02:00
Jonas Kvinge
6446942e73 Add error handling to playlist parsers 2024-06-24 20:20:49 +02:00
Jonas Kvinge
0038cf8c4e CollectionWatcher: Make sure periodic scan is stopped 2024-06-24 19:43:09 +02:00
Jonas Kvinge
7f177aef08 CollectionModel: Always separate albums by different artists
Fixes #1276
2024-06-24 19:21:24 +02:00
Jonas Kvinge
a7a42ea5ec AnalyzerContainer: Use constexpr 2024-06-22 00:48:21 +02:00
Jonas Kvinge
14cddfd42f AnalyzerContainer: Add parameter 2024-06-22 00:48:03 +02:00
Jonas Kvinge
ae0ce65674 AnalyzerContainer: Remove unused declaration 2024-06-22 00:47:52 +02:00
Jonas Kvinge
9c9926d5a7 PlaylistHeader: Cast column to int
Fixes #1468
2024-06-22 00:43:20 +02:00
Jonas Kvinge
95a3c41baa CI: Disable Spotify for MinGW and macOS 2024-06-20 23:39:42 +02:00
Jonas Kvinge
f2518baef9 nsi: Add spotify plugin for MSVC 2024-06-20 23:39:23 +02:00
Jonas Kvinge
4be9265546 PlaylistView: Use Playlist::ColumnCount 2024-06-20 23:00:33 +02:00
Jonas Kvinge
9f9c46e370 Update individual playlist columns, use enum class 2024-06-20 22:52:27 +02:00
Jonas Kvinge
5816d0bb12 About: Update contributors 2024-06-20 16:48:45 +02:00
Jonas Kvinge
70c2b99771 ContextAlbum: Delete timeline to delete previous cover
QTimeLine was holding the previous covers shared pointer in the signal/slot connection, which caused it to never be free'd even though it's removed from the previous_covers_ list.
To fix this, make sure the QTimeLine is deleted.

This fixes a huge memory leak.

Addresses issue #1464
2024-06-20 16:05:07 +02:00
Jonas Kvinge
6177d4a2c4 ContextAlbum: Use const reference for image parameter 2024-06-20 15:59:34 +02:00
Jonas Kvinge
05f012e590 ContextAlbum: Formatting 2024-06-20 15:58:24 +02:00
Jonas Kvinge
cc0506490f ContextAlbum: Use constexpr for kFadeTimeLineMs 2024-06-20 15:57:53 +02:00
Jonas Kvinge
06114c9835 ContextAlbum: Add explicit for PreviousCover 2024-06-20 15:57:12 +02:00
Jonas Kvinge
2518e4d47d ContextAlbum: Remove unused function declaration 2024-06-20 15:56:49 +02:00
Jonas Kvinge
ceea805196 main: Remove QCoreApplication::setQuitLockEnabled(false);
This was a workaround for QTBUG-124386.
2024-06-19 21:33:01 +02:00
Jonas Kvinge
ae7e515945 Update Changelog 2024-06-19 00:39:13 +02:00
Jonas Kvinge
b275f91a58 PlaylistView: Set new default column sizes 2024-06-18 19:52:51 +02:00
Jonas Kvinge
b8ef96028c StretchHeaderView: Refactor code and improve header view
Save what sections are visible, and always save sizes.
Do not set section size to zero when hiding sections.
When resizing columns in stretch mode, only resize the right column to fit the left column.

Fixes #1085
2024-06-18 19:52:34 +02:00
Jonas Kvinge
6ba1fdb744 CI: Remove openSUSE 15.5 2024-06-16 18:18:43 +02:00
Jonas Kvinge
dcef38427b CI: Remove protobuf workaround for openSUSE 2024-06-15 01:48:20 +02:00
Jonas Kvinge
20d7ae7144 CI: Fix setting ENABLE_WIN32_CONSOLE for MSVC 2024-06-15 01:20:57 +02:00
Jonas Kvinge
d576777d94 CueParser: Always set track 2024-06-14 21:19:18 +02:00
Jonas Kvinge
1f7344ca1b CueParser: Move artist / album variables
Fixes #1463
2024-06-14 21:19:04 +02:00
Jonas Kvinge
87c69f7456 CueParser: Formatting 2024-06-14 21:17:59 +02:00
Jonas Kvinge
a684b35203 ParserBase: Always read file, CUE depends on it 2024-06-14 21:03:52 +02:00
Jonas Kvinge
37855fe836 CollectionBackend: Remove QUrl::FullyDecoded from QUrl::toString() 2024-06-14 18:46:48 +02:00
Jonas Kvinge
f596695f61 CollectionModel: Don't process model updates when loading 2024-06-14 18:40:52 +02:00
Jonas Kvinge
076d065f7c nsi: Replace libxml2-2.dll with libxml2.dll 2024-06-14 00:20:33 +02:00
Jonas Kvinge
70a7a7bbdd CI: Cleanup PATH for MSVC build 2024-06-13 23:01:33 +02:00
Jonas Kvinge
5f540a4c08 Add Spotify support 2024-06-13 17:09:06 +02:00
Jonas Kvinge
f33b30fe79 OrganizeFormat: Replace QLatin1String with QStringLiteral 2024-06-13 00:40:08 +02:00
Jonas Kvinge
2f546f214d Replace QLatin1String with QStringLiteral 2024-06-12 23:51:09 +02:00
Jonas Kvinge
7ba4fda346 SnapDialog: Replace QLatin1String with QStringLiteral 2024-06-12 23:23:30 +02:00
Jonas Kvinge
299415a889 Rename "Internet" to "Streaming" 2024-06-12 22:23:05 +02:00
Jonas Kvinge
718af984ab Move LocalRedirectServer to core 2024-06-12 21:21:11 +02:00
Jonas Kvinge
5d51657f32 Drop FTS tables 2024-06-12 21:17:01 +02:00
Jonas Kvinge
a2958ba808 ListenBrainzScrobbler: Replace QLatin1String with QStringLiteral 2024-06-12 21:00:25 +02:00
Jonas Kvinge
79c2130152 ScrobblingAPI20: Replace QLatin1String with QStringLiteral 2024-06-12 20:59:09 +02:00
Jonas Kvinge
98d3cc2637 AnalyzerBase: Add static_cast 2024-06-12 20:58:51 +02:00
Jonas Kvinge
8339aa0934 CI: Remove Fedora 41 2024-06-12 20:32:34 +02:00
Jonas Kvinge
5451c110b1 Replace QStringLiteral with QLatin1String 2024-06-12 20:30:36 +02:00
Jonas Kvinge
20595a11bc SmartPlaylistSearchTermWidget: Add const 2024-06-12 18:56:21 +02:00
Jonas Kvinge
c92a1b516c GstEngine: Fix swapped media_url / stream_url 2024-06-12 18:52:53 +02:00
Jonas Kvinge
a8f1a881ff GioLister: Remove useless else 2024-06-12 18:52:33 +02:00
Jonas Kvinge
ec21a55271 CollectionModelTest: Remove unused test 2024-06-12 18:14:37 +02:00
Jonas Kvinge
89990624ec CollectionBackendTest: Use std::make_shared 2024-06-12 18:14:24 +02:00
Jonas Kvinge
6caf7f356b SubsonicRequest: Add const 2024-06-12 18:12:20 +02:00
Jonas Kvinge
241a6c5818 EditTagDialog: Initialize cover_menu_ 2024-06-12 18:12:08 +02:00
Jonas Kvinge
57fb52e8f0 Add LL 2024-06-12 18:11:43 +02:00
Jonas Kvinge
7b00385155 Udisks2Lister: Add static_cast 2024-06-12 18:11:10 +02:00
Jonas Kvinge
2b4aa1d6b2 AlbumCoverChoiceController: Add missing close 2024-06-12 18:09:59 +02:00
Jonas Kvinge
4ba5113842 Remove const 2024-06-12 18:09:23 +02:00
Jonas Kvinge
a36bf2df65 Replace QStringLiteral with QLatin1String 2024-06-12 18:08:54 +02:00
Jonas Kvinge
f5002cae36 Make static 2024-06-12 18:07:58 +02:00
Jonas Kvinge
cb8022c55d WaveRubber: use static_cast 2024-06-12 18:06:37 +02:00
Jonas Kvinge
2a65e00988 WaveRubber: Remove trailing whitespaces and fix formatting 2024-06-12 17:45:01 +02:00
Jonas Kvinge
05358cdfe4 Add default to switch 2024-06-12 17:41:17 +02:00
Jonas Kvinge
7b43a94055 CollectionBackend: Use static QMetaObject::invokeMethod 2024-06-12 17:40:08 +02:00
Jonas Kvinge
36e19e82e7 FHT: Remove void 2024-06-12 17:39:46 +02:00
Jonas Kvinge
c52a802b83 AnalyzerBase: Remove static_cast 2024-06-12 17:39:37 +02:00
Jonas Kvinge
b233600b8c Remove useless else 2024-06-12 17:38:58 +02:00
Jonas Kvinge
93df859aa4 About: Replace QLatin1String with QStringLiteral 2024-06-12 17:31:17 +02:00
Jonas Kvinge
f1f79fb961 Move default constructor to header 2024-06-12 17:30:40 +02:00
Jonas Kvinge
92fa75b6c2 gstmoodbarplugin: Remove namespace 2024-06-12 17:28:23 +02:00
Jonas Kvinge
1d5f3a0486 CI: Remove MSVC abseil workaround 2024-06-12 17:09:21 +02:00
Jonas Kvinge
b89c200076 Replace QStringLiteral with QLatin1String 2024-06-12 02:13:27 +02:00
Jonas Kvinge
597a8cd6c8 Remove QStringBuilder include 2024-06-12 00:44:48 +02:00
Jonas Kvinge
e477449cd4 Rewrite collection model and search
Fixes #392
2024-06-11 23:18:38 +02:00
Jonas Kvinge
ea1e4541c0 CI: Use MSVC protoc from debug to workaround a crash 2024-06-09 23:03:57 +02:00
Guzpido
50572ac40f WaveRubber: a simple waveform analyzer
This kinda elastic analyzer uses no transformations and is colored by a gradient based on the user QT "Highlight" palette.

WaveRubber: a kinda elastic waveform analyzer

Update src/analyzer/waverubber.cpp

better pointer declaration

Co-authored-by: Jonas Kvinge <jonas@jkvinge.net>
2024-06-09 18:01:28 +02:00
Guzpido
fd81036909 GstEnginePipeline: Divide samples and format by channels for buffer duration 2024-06-09 15:56:29 +02:00
Jonas Kvinge
0e27886e28 CI: Add Boost_INCLUDE_DIR for MSVC build 2024-06-09 14:12:38 +02:00
whatwareweb
45bad3be04 Fix integer underflow bug 2024-06-08 11:49:35 +02:00
Jonas Kvinge
30b268dc3a Remove msvc toolset 2024-06-08 00:48:43 +02:00
jj
ef99f0ef36 Add volume increment setting 2024-06-06 21:53:16 +02:00
Jonas Kvinge
e357ba0125 GstEngine: Check individual classes when parsing outputs 2024-06-04 19:43:54 +02:00
Jonas Kvinge
36b75a5928 CI: Manually codesign libraries 2024-06-03 17:13:28 +02:00
Jonas Kvinge
64d3ea2804 Udisks2Lister: Fix mountpoint 2024-06-03 17:12:23 +02:00
Jonas Kvinge
0a93affeef SongLoader: Use QObject::connect 2024-06-03 00:00:20 +02:00
Jonas Kvinge
402d13a322 CI: Bump macOS to 12 2024-06-02 12:49:05 +02:00
Jonas Kvinge
adf0efc859 CI: Remove Fedora 38 2024-06-02 12:48:23 +02:00
Jonas Kvinge
d1c65fd273 Bump default LSMinimumSystemVersion to 12.0 2024-06-02 12:30:48 +02:00
Jonas Kvinge
8a27c6a52f GstEnginePipeline: Use playbin3 with GStreamer 1.24 and higher
playbin3 is buggy with GStreamer 1.22, for some reason the bug is only reproducible on Gnome.

https://forum.strawberrymusicplayer.org/topic/1506/buffering-forever/23
2024-06-02 12:09:38 +02:00
Jonas Kvinge
d7cc52bc99 EngineBase: Use fully qualified namespace in StateChanged
Makes sure the metatype matches with Qt 5:
QObject::connect: Cannot queue arguments of type 'State'
(Make sure 'State' is registered using qRegisterMetaType().)

Fixes #1446
2024-05-30 20:09:32 +02:00
Jonas Kvinge
f0f5300891 ParserBase: Make the path absolute and try canonical path
Somehow I got this mixed up in commit 2953f9e :(

Fixes #1448
2024-05-29 00:18:39 +02:00
Jonas Kvinge
6e90e72b4a CollectionModel: Add content to fake header for pixmap cache
QNetworkCacheMetaData requires this now.
2024-05-26 02:49:26 +02:00
Jonas Kvinge
c655963483 Use checkStateChanged(Qt::CheckState) with Qt >= 6.7 2024-05-24 02:13:48 +02:00
Jonas Kvinge
9f2e4ac312 CueParser: Detect and handle different text encodings
Fixes #1429
2024-05-19 01:49:37 +02:00
Jonas Kvinge
9e25366f85 Add function for detecting text encoding 2024-05-19 01:47:44 +02:00
Jonas Kvinge
c102d8731a Require ICU 2024-05-19 01:45:19 +02:00
Jonas Kvinge
0983ba1339 MoodbarLoader: Add header name for disk cache 2024-05-13 00:44:37 +02:00
dependabot[bot]
0a99eca7cd Bump apple-actions/import-codesign-certs from 2 to 3
Bumps [apple-actions/import-codesign-certs](https://github.com/apple-actions/import-codesign-certs) from 2 to 3.
- [Release notes](https://github.com/apple-actions/import-codesign-certs/releases)
- [Commits](https://github.com/apple-actions/import-codesign-certs/compare/v2...v3)

---
updated-dependencies:
- dependency-name: apple-actions/import-codesign-certs
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
2024-05-13 00:27:33 +02:00
Jonas Kvinge
116bbec73e Replace qPrintable with qUtf8Printable
Fixes #1440
2024-05-13 00:05:58 +02:00
Jonas Kvinge
bf19540f8d Set LSMinimumSystemVersion from MACOSX_DEPLOYMENT_TARGET
Fixes #1436
2024-05-12 23:10:43 +02:00
Jonas Kvinge
dff3ae7410 CI: Remove --skip-broken from dnf for Fedora 2024-05-12 21:41:38 +02:00
Jonas Kvinge
76614bcde0 Only apply collection directories changes on save 2024-05-12 21:40:51 +02:00
Jonas Kvinge
2953f9eefc ParserBase: Use original paths 2024-05-12 21:38:59 +02:00
Jonas Kvinge
4a24605361 FileViewList: Use original paths instead of canonical paths 2024-05-12 21:38:15 +02:00
Jonas Kvinge
decabe8d47 CommandlineOptions: Use original paths instead of canonical paths 2024-05-12 21:37:54 +02:00
Jonas Kvinge
51adcf0f1e MainWindow: Use original paths instead of canonical paths 2024-05-12 21:37:32 +02:00
Jonas Kvinge
2a6a07fef6 CollectionBackendTest: Remove use of QFileInfo::canonicalFilePath 2024-05-12 21:36:52 +02:00
Jonas Kvinge
315cf63118 CI: Remove Windows 32 bit 2024-05-11 23:23:56 +02:00
Wedone
e28d362aad Update fr.po 2024-05-04 16:22:51 +02:00
Jonas Kvinge
e0d9b8f715 ResizableTextEdit: Remove tab 2024-05-04 16:21:59 +02:00
Jonas Kvinge
eff6b75c43 nsi: Remove /SOLID from SetCompressor for debug 2024-04-24 02:25:05 +02:00
Robert Gingras
e8be0adf37 TagReaderTagLib: Remove redundant ID3v2 validity check
TagLib will have created a valid ID3v2 tag on this file by this point in the code, due to the way it handles the tag() method for WAV::File. Thus the null pointer check is redundant and the hasID3v2() call is at best redundant and at worst will cause tags to not save when they otherwise should have
2024-04-24 01:23:51 +02:00
Robert Gingras
9f4a82bb62 TagReaderTagLib: Remove file_mpeg argument from the SetEmbeddedArt ID3v2 overload 2024-04-24 01:23:51 +02:00
Robert Gingras
8d7e14f21d Song: Added WAV to list of supported filetypes 2024-04-24 01:23:51 +02:00
Robert Gingras
d03d3622aa TagReaderTagLib: Have RIFF WAV files save ID3v2 tags, when applicable 2024-04-24 01:23:51 +02:00
Robert Gingras
821c32992d TagReaderTagLib: Refactor ID3v2 saving to a dedicated function 2024-04-24 01:23:51 +02:00
Robert Gingras
b52cf9f3cd TagReaderTagLib: Reposition ParseID3v2Tag 2024-04-24 01:23:51 +02:00
Robert Gingras
ab8e687f96 TagReaderTagLib: Add id3v2 parsing for RIFF WAV files 2024-04-24 01:23:51 +02:00
Robert Gingras
90703703aa TagReaderTagLib: Make id3v2 parsing reusable 2024-04-24 01:23:51 +02:00
Jonas Kvinge
176984afe0 RadioPlaylistItem: Set correct col position for InitFromQuery
Fixes #1430
2024-04-23 22:34:00 +02:00
Jonas Kvinge
542efa17ff Fix position for song and internet playlist items
Fixes #1430
2024-04-23 20:18:28 +02:00
Jonas Kvinge
6a2c2dbba1 Song: Fix loading length 2024-04-23 20:16:41 +02:00
Jonas Kvinge
426de61525 Add const and std::as_const 2024-04-23 17:15:42 +02:00
Jonas Kvinge
24c8d06d41 SongPlaylistItem: Use static_cast 2024-04-23 17:00:10 +02:00
Jonas Kvinge
227f5e5176 Replace QStringLiteral with QLatin1String 2024-04-23 16:57:49 +02:00
Jonas Kvinge
92e39a3e21 GlobalShortcut: Use optional 2024-04-23 16:54:54 +02:00
Jonas Kvinge
fb2300e2fa EBUR128State: Add missing const reference 2024-04-23 16:54:22 +02:00
Jonas Kvinge
78becae5e9 AlbumCoverLoader: Use fully qualified namespace in slot 2024-04-23 16:53:40 +02:00
Jonas Kvinge
d10eb4370e Player: Use chrono_literals 2024-04-23 16:53:12 +02:00
Jonas Kvinge
9c92ef941f CollectionModel: Remove redundant const_cast 2024-04-23 16:52:17 +02:00
Jonas Kvinge
7aefe3d71b Change QList<QString> to QStringList 2024-04-23 16:51:42 +02:00
Jonas Kvinge
398db964b8 Use QDateTime::currentSecsSinceEpoch 2024-04-23 16:48:51 +02:00
Jonas Kvinge
579349b104 ResizableTextEdit: Add Q_OBJECT macro 2024-04-23 16:44:44 +02:00
Jonas Kvinge
5f9a83871d Playlist: Cast to int 2024-04-23 02:45:27 +02:00
Jonas Kvinge
da0c5e67c5 Playlist: Use optional::has_value 2024-04-23 02:45:11 +02:00
Jonas Kvinge
a0cfde18c3 PlaylistSequence: Use constexpr 2024-04-23 02:44:48 +02:00
Jonas Kvinge
0ad4889936 PlaylistSequence: Remove unused member variable 2024-04-23 02:44:36 +02:00
Jonas Kvinge
36e809d530 InternetPlaylistItem: Cast to int 2024-04-23 02:18:24 +02:00
Jonas Kvinge
78096658e2 Chromaprinter: Remove useless cast 2024-04-23 02:18:08 +02:00
Jonas Kvinge
3edd218e3a Remove redundant casts 2024-04-23 01:58:08 +02:00
Jonas Kvinge
569bf6335b CollectionView: Add action_search_for_this_ to initialization list 2024-04-23 01:57:16 +02:00
Jonas Kvinge
7b8919d706 CommandlineOptions: Add const 2024-04-23 01:56:55 +02:00
Jonas Kvinge
147fd87d8c MainWindow: Only pass progress to UpdateTaskbarProgress 2024-04-23 01:56:30 +02:00
Jonas Kvinge
ac0926d40b Song: Add ColumnIndex helper function 2024-04-23 01:55:57 +02:00
Jonas Kvinge
105d472f5d README: Fix badge 2024-04-21 22:35:15 +02:00
Jonas Kvinge
c1a49da385 tests: Use QStringLiteral 2024-04-21 19:37:39 +02:00
Jonas Kvinge
c3f596e64e CI: Add devel-tools-building repo for Leap 2024-04-21 17:03:06 +02:00
Jonas Kvinge
adfda84c41 nsi: Bump icu from 74 to 75 2024-04-21 16:44:07 +02:00
Jonas Kvinge
345cc118a3 CI: Use different mirror for Mageia 2024-04-21 16:10:26 +02:00
Jonas Kvinge
df070ac0cf Optimize Song::InitFromQuery
Use `QSqlQuery::value(int)` or `QSqlRecord::value(int)` instead of `QSqlQuery::value(QString)`.
Make `SqlRow` use `QSqlRecord` directly instead iterating over all columns.
2024-04-21 15:42:29 +02:00
Jonas Kvinge
7b88be2635 CollectionModel: Only set grouping if it's selected 2024-04-21 15:42:29 +02:00
Kientz Arnaud
c30a39d29a Fix infinitive in french translations 2024-04-16 00:24:59 +02:00
Jonas Kvinge
36db41a1f0 Add sidebar background 2024-04-13 23:47:48 +02:00
Jonas Kvinge
8b249dc06a QSearchField: Remove NSSearchField workaround
This was a workaround for QTBUG-124160.
2024-04-13 05:39:19 +02:00
Jonas Kvinge
0c6872b352 Disable automatic conversions from 8-bit strings 2024-04-13 05:05:33 +02:00
Jonas Kvinge
58944993b8 Use QStringLiteral 2024-04-09 23:20:26 +02:00
Olivier HUMBERT
3cfffa5fbb Adds French to the menu item 2024-04-07 19:26:23 +02:00
Jonas Kvinge
4873b8b413 CI: Move OpenMandriva if false 2024-04-06 21:24:19 +02:00
Jonas Kvinge
0b85f5192c CI: Enable Mageia 2024-04-06 21:19:03 +02:00
Jonas Kvinge
3e9a1776a1 CI: Run upload and attach independent of failure 2024-04-06 21:10:10 +02:00
Jonas Kvinge
e1fbe9ae54 Resolve song from collection using track with Cue in XSPF
Fixes #1181
2024-04-04 22:22:02 +02:00
Jonas Kvinge
f48d1a8017 OrganizeDialog: Don't save settings unless button is pressed
Fixes #1404
2024-04-04 21:43:57 +02:00
rimasx
0debc90695 Create estonian translation
I hope this is OK. Strawberry compiled without any problems and Estonian was automatically selected. I mostly used the Clementine translation, which I tweaked a bit. Many thanks to the Clementine translators, especially Priit Jõerüüt.
2024-04-04 21:29:48 +02:00
Jonas Kvinge
8d42ea7cfd README: Remove link to zanata 2024-04-04 21:18:57 +02:00
Jonas Kvinge
1dae80a633 Add scrobbler option for stripping "remastered" etc
Fixes #1387
2024-04-04 21:17:07 +02:00
Jonas Kvinge
d398c86b0c Make showing song progress on taskbar optional 2024-04-04 16:49:53 +02:00
Jonas Kvinge
70809e0647 MainWindow: Add error dialog when file deletion fails
Fixes #1384
2024-04-03 21:37:20 +02:00
Jonas Kvinge
4c1a5168f0 CollectionModel: Reset model before deletion 2024-04-03 21:17:20 +02:00
Jonas Kvinge
f9acfbc224 SimpleTreeModel: Handle null root 2024-04-03 21:17:20 +02:00
Jonas Kvinge
5f78e1a983 MergedProxyModel: Fix beginRemoveRows first
Fixes #1314
2024-04-03 21:17:06 +02:00
Jonas Kvinge
7bc5579fb7 Song: Check that filetype is supported for writing tags
Fixes #1413
2024-04-03 20:45:52 +02:00
Jonas Kvinge
57750efcb2 CI: Remove openSUSE Leap 15.5
Protobuf is broken
2024-04-03 20:09:07 +02:00
Jonas Kvinge
a33ee1cda9 CI: Use GCC 13 for Leap 2024-04-03 20:08:05 +02:00
Jonas Kvinge
cd20a0679a CI: Replace qwindowsvistastyle with qmodernwindowsstyle 2024-04-02 17:37:58 +02:00
Jonas Kvinge
20e546e02b nsi: Replace qwindowsvistastyle with qmodernwindowsstyle 2024-04-02 17:37:38 +02:00
Jonas Kvinge
f5547f093e Player: Use timer for saving volume
Fixes #1272
2024-04-02 17:16:29 +02:00
Jonas Kvinge
c00d95242d Utilities: Handle missing XDG_DATA_DIRS variable 2024-04-02 16:39:48 +02:00
Jonas Kvinge
05c4d23df6 Utilities: Remove --new-window parameter from dolphin
Fixes #1412
2024-04-02 00:48:29 +02:00
Jonas Kvinge
06fa17f33f CI: Run apt upgrade for debian/ubuntu 2024-04-01 00:38:21 +02:00
Jonas Kvinge
194285289c Update Changelog 2024-03-31 22:56:46 +02:00
Jonas Kvinge
a61fa61330 CI: Disable OpenMandriva 2024-03-31 01:49:30 +01:00
Jonas Kvinge
68c922ee12 SmartPlaylistWizard: Set classic style if using fusion on Windows
Workaround a Qt bug.

Fixes #1399
2024-03-29 02:54:25 +01:00
Jonas Kvinge
d1042b276b GstEnginePipeline: Set volume_set_ to false in ElementRemovedCallback 2024-03-24 19:44:47 +01:00
Jonas Kvinge
9bbffe150f GstEnginePipeline: Add back volume sync for auto
We need to remove the volume sync when the element is deleted on "deep-element-removed", then re-add it on the next "deep-element-added" that isn't a fakesink.

Fixes #1123
2024-03-24 19:36:32 +01:00
Jonas Kvinge
b95be526d3 HtmlLyricsProvider: Use QNetworkRequest::UserAgentHeader 2024-03-24 07:04:07 +01:00
Jonas Kvinge
165f9d769b MusixmatchCoverProvider: Fix parsing 2024-03-24 06:59:01 +01:00
Jonas Kvinge
a0ea75b74e NetworkAccessManager: Use QNetworkRequest::setHeader 2024-03-24 06:58:33 +01:00
Jonas Kvinge
4075f92eec OpenTidalCoverProvider: Adjust settings 2024-03-24 05:27:43 +01:00
Jonas Kvinge
035aff5454 Add Open Tidal cover provider 2024-03-24 05:23:35 +01:00
Jonas Kvinge
52dc7ad259 CI: Add Fedora 41 2024-03-23 14:18:17 +01:00
Jonas Kvinge
c3c83f608c CI: Add Leap 15.6 and remove 15.4 2024-03-23 14:05:11 +01:00
Strawbs Bot
ffba351a16 Update translations 2024-03-23 01:43:24 +01:00
Jonas Kvinge
a12623e142 Update Changelog 2024-03-23 01:04:29 +01:00
Jonas Kvinge
1a691a103e Fix Qt 5 and mpris2 build errors 2024-03-22 20:26:13 +01:00
Jonas Kvinge
5e725e0bbe Fix playlist shuffle
- Shuffle all indexes
- Use persistent indexes to store play history
- Update virtual items to keep original shuffle order when the playlist is reordered
- Make sure to always set virtual index on manual shuffle
- Ignore repeat and shuffle when dynamic playlist is activated

Fixes #707
Fixes #1381
Fixes #1366
Fixes #1353
2024-03-22 20:00:12 +01:00
Jonas Kvinge
93c2fa4c73 MusixmatchLyricsProvider: Parse metadata 2024-03-17 23:41:05 +01:00
Jonas Kvinge
f412fb21d6 SettingsPage: Double spinboxes are double, not int 2024-03-17 21:56:39 +01:00
Jonas Kvinge
bd4b6c1f01 main: Add QCoreApplication::setQuitLockEnabled(false);
Fixes #1401
2024-03-17 21:46:15 +01:00
Jonas Kvinge
d1839d87e7 MusixmatchLyricsProvider: Fix parsing lyrics 2024-03-16 22:46:45 +01:00
Jonas Kvinge
1fc163eb5f Playlist: Comments formatting 2024-03-13 21:59:17 +01:00
Reverier-Xu
cd2b3cb73e mpris2: Fix mpris:trackid type with Plasma 6 2024-03-13 21:31:25 +01:00
Reverier-Xu
88b5cf2461 mpris2: Fix mpris:trackid type with Plasma 6 2024-03-13 21:31:25 +01:00
Jonas Kvinge
2ccb0af75e Song: Only include mpris when built with DBUS 2024-03-13 18:15:51 +01:00
Célestin Matte
27ee6e7643 EditTagDialog: Add button to fetch lyrics
Co-Authored-By: Jonas Kvinge <jonas@jkvinge.net>
2024-03-13 17:54:19 +01:00
Jonas Kvinge
a3207a5703 macgstcopy: Update gstreamer plugins list 2024-03-12 18:25:06 +01:00
Jonas Kvinge
72ff64a7f8 nsi: Remove unused gstreamer plugins 2024-03-12 16:29:48 +01:00
Jonas Kvinge
9c06d1d0ae nsi: Add gstreamer dsd plugin 2024-03-12 00:52:49 +01:00
Jonas Kvinge
f11afd4414 GstEnginePipeline: Add default to switch 2024-03-12 00:40:11 +01:00
Sami Boukortt
2aa70b6ab8 Add an option not to skip “The” when sorting artist names 2024-03-11 23:34:42 +01:00
Jonas Kvinge
4626a6f609 GstEnginePipeline: Use playbin3 with gstreamer >= 1.22 2024-03-08 18:52:22 +01:00
Jonas Kvinge
9152f8559f Song: Split remastered and explicit regex 2024-03-03 01:50:05 +01:00
Jonas Kvinge
7f4c61b15a Improve album and title disc, remastered, etc matching
Don't partial remove things like "(Mono / Remastered)".

Fixes #1387
2024-03-02 19:48:19 +01:00
Jonas Kvinge
b365131363 Playlist: Remove veto listeners
We have never used this, it's basically dead code.
2024-02-28 23:00:24 +01:00
Jonas Kvinge
a6ea4dd0d7 Remove unused includes 2024-02-28 21:37:14 +01:00
Jonas Kvinge
9c6649f077 Add letras lyrics provider 2024-02-28 21:33:30 +01:00
Jonas Kvinge
04ba202e12 HtmlLyricsProvider: Use browser-like user-agent 2024-02-25 04:32:09 +01:00
Jonas Kvinge
352a6c5691 Remove lyricsmode.com provider
They have a "Verifying you are human" thing now.
2024-02-25 04:23:04 +01:00
Jonas Kvinge
72bccad82d Add accessible name for QToolButton css
Make sure it does not apply to other buttons.

Fixes #1255
2024-02-25 02:50:40 +01:00
Jonas Kvinge
6d52a2b409 QSearchField: Replace QToolButton with QPushButton 2024-02-25 02:46:51 +01:00
Jonas Kvinge
9b1035a5f2 Translations: Fix generating pot with NMake
Using GETTEXT_XGETTEXT_EXECUTABLE causes issues with NMake, possibly because of spaces in path.
2024-02-24 19:45:58 +01:00
Jonas Kvinge
ce7c3e8039 CI: Use gh instead of hub 2024-02-24 01:18:02 +01:00
Jonas Kvinge
9baec288c3 CI: Set FFTW3_DIR 2024-02-23 22:57:00 +01:00
Jonas Kvinge
82894b94f4 CI: Set vsversion to 2022 2024-02-23 21:59:06 +01:00
Jonas Kvinge
fb00d68aa7 Update Changelog 2024-02-20 22:47:55 +01:00
Jonas Kvinge
12288a2622 BackendSettingsPage: Fix enabling/disabling exclusive mode 2024-02-20 01:22:40 +01:00
Jonas Kvinge
f84ce3f1d1 Add exclusive mode option for WASAPI 2024-02-20 01:08:00 +01:00
Jonas Kvinge
306b3f72d8 SettingsPage: Pass on scroll event to page
If the settings widget does not have focus, pass the event to the page for scrolling down instead of changing the setting.

Fixes #1380
2024-02-19 23:07:27 +01:00
buckmelanoma
593a04d047 InternetSearchView: Use DescriptionForSource instead of TextForSource
DescriptionForSource provides uppercase names in the filter menu instead of the lowercase names provided by TextForSource
2024-02-18 20:14:01 +01:00
buckmelanoma
667548f3ed InternetSongsView: Use DescriptionForSource instead of TextForSource
DescriptionForSource provides uppercase names in the filter menu instead of the lowercase names provided by TextForSource
2024-02-18 20:14:01 +01:00
Jonas Kvinge
8f89bf6402 Replace tabs with spaces 2024-02-18 14:24:20 +01:00
Jonas Kvinge
ff28e7c86e Add ASIO device finder 2024-02-17 00:40:55 +01:00
Jonas Kvinge
67cc69179b nsi: Update gstreamer plugins 2024-02-16 21:51:45 +01:00
Jonas Kvinge
06fac2b7a3 CI: Copy all gstreamer plugins for mingw and msvc 2024-02-16 21:51:45 +01:00
Jonas Kvinge
a354f6bdc5 GstEnginePipeline: Set device-clsid 2024-02-16 21:38:33 +01:00
Jonas Kvinge
cb44c71733 DirectSoundDeviceFinder: Add waveformsink 2024-02-16 21:38:08 +01:00
Jonas Kvinge
6b1c14f875 GstEngine: Make sure asiosink is detected 2024-02-16 00:29:17 +01:00
Jonas Kvinge
7770aba877 GstEngine: Add pipewiresink 2024-02-14 18:46:23 +01:00
Jonas Kvinge
05381096aa RadioParadiseService: Use API to receive streams 2024-02-12 16:57:51 +01:00
Jonas Kvinge
6bdd9ad4dd GstEnginePipeline: Only hard-code playbin3 with gst 1.22 2024-02-11 23:52:22 +01:00
Jonas Kvinge
19836e8898 CI: Fix variable typo 2024-02-11 12:24:29 +01:00
Jonas Kvinge
5e4b193260 CI: Fix greping variable 2024-02-11 12:17:04 +01:00
Jonas Kvinge
923d0f2b7a CI: Use common SSH upload job 2024-02-11 12:12:54 +01:00
Jonas Kvinge
56f1a93c4e CI: Fix tag name variable typo 2024-02-11 01:19:39 +01:00
Jonas Kvinge
0168182af5 CddaDevice: Add missing override 2024-02-11 00:14:19 +01:00
Jonas Kvinge
679f0e1cd8 CI: Trigger on release 2024-02-11 00:10:36 +01:00
Adam Hill
dd6b9bb38d MainWindow: Add function to display progress on taskbar 2024-02-09 21:48:12 +01:00
Jonas Kvinge
5bd8f35dc0 Update Changelog 2024-02-07 01:46:12 +01:00
Jonas Kvinge
53fc939e35 ScrobblingAPI20: Ignore permission related error
Last.fm returns permission denied error when servers are overloaded, ignore this error instead.

Fixes #442
2024-02-07 01:34:46 +01:00
Strawbs Bot
42d6c79710 Update translations 2024-02-01 21:43:21 +01:00
Jonas Kvinge
882869255b CI: Remove Ubuntu Lunar 2024-01-30 18:42:32 +01:00
Jonas Kvinge
19903751c1 CI: Codesign png.framework for macOS private 2024-01-27 17:39:26 +01:00
Jonas Kvinge
836074fb60 CI: Manually codesign png framework 2024-01-26 18:58:10 +01:00
Jonas Kvinge
5865a70c2e CI: Add --skip-broken to dnf install for Fedora 2024-01-26 00:29:25 +01:00
Jacob Henner
fa057ee9d3 CollectionView: Add "search for this"
Add selection search in the collection view, to allow users to quickly
search for similarly-named songs, artists, albums, etc.
2024-01-25 19:16:14 +01:00
Jonas Kvinge
2d88fcb249 CI: Add Ubuntu Noble 2024-01-24 23:05:46 +01:00
Jonas Kvinge
920bb04b00 CMakeLists: Find TagLib using CMake 2024-01-24 21:30:10 +01:00
Jonas Kvinge
a915e62e2c GPodDevice: Fix error message 2024-01-24 19:52:24 +01:00
Jonas Kvinge
226a6c50e0 Add better error messages for device and organize
Fixes #1364
2024-01-24 19:27:30 +01:00
Jonas Kvinge
269f13de76 MtpLoader: Allow empty artist 2024-01-24 19:21:02 +01:00
Jonas Kvinge
3ee796a663 macgstcopy: Add adaptivedemux2 and mpeg mux/demux 2024-01-22 19:26:21 +01:00
Jonas Kvinge
d24af2f4db nsi: Add adaptivedemux2 and mpeg demux/mux plugins 2024-01-22 16:53:43 +01:00
Enrique Garcia
f86c3cfd91 SubsonicSettingsPage: Add recommended to MD5 authentication 2024-01-21 04:25:31 +01:00
William Andrea
11061bdd07 CONTRIBUTING: Clarify "Commit messages" section.
Specifically:
- Clarify what "class" is referring to
- Use an actual example, which requires moving out two bits of explanation
2024-01-19 23:43:44 +01:00
Jonas Kvinge
f901f802bb CollectionView: Implement add to playlist with enter
Fixes #1360
2024-01-19 23:04:03 +01:00
Jonas Kvinge
a98c209101 AutoExpandingTreeView: Remove doubleClicked on enter 2024-01-19 23:03:37 +01:00
Jonas Kvinge
6a459682ca Playlist: Check for valid index
Fixes #1359
2024-01-19 22:37:14 +01:00
Jonas Kvinge
1a7194b3a9 Turn on git revision 2024-01-11 22:32:36 +01:00
Jonas Kvinge
b6c9ef4a15 Release 1.0.23 2024-01-11 20:44:55 +01:00
Jonas Kvinge
20e550bc7d Update Changelog 2024-01-11 17:40:09 +01:00
Jonas Kvinge
a4b7766947 DeviceManager: Add nullptr check for connected device
Possible fix for #1313
2024-01-11 17:03:00 +01:00
Jonas Kvinge
8d1a0071b6 Playlist: Use effective original year for sorting
Fixes #1349
2024-01-11 16:40:12 +01:00
Jonas Kvinge
a3c00e607b README: Update sponsoring info 2024-01-09 18:08:40 +01:00
Jonas Kvinge
de7ca8b736 CI: Enable OpenMandriva 2024-01-04 03:05:44 +01:00
Jonas Kvinge
04e593dc62 CollectionWatcher: Add unavailable song restored logging 2024-01-03 00:45:30 +01:00
Jonas Kvinge
2294c38aa9 CollectionBackend: Rename SqlQuery variable 2024-01-03 00:44:54 +01:00
Jonas Kvinge
6f41d39a9c CI: Remove Mageia from upload release 2024-01-02 23:47:15 +01:00
Jonas Kvinge
7c4e33b676 GstEngine: Treat all stream errors as non-fatal
Fixes #1347
2024-01-02 19:54:19 +01:00
Jonas Kvinge
4cc66bccad CI: Disable Mageia and OpenMandriva
OpenMandriva Cooker has package conflict issues. Mageia 8 is end of life and there is no docker image for Mageia 9 yet.
2024-01-02 19:49:10 +01:00
Jonas Kvinge
55b1d34f48 CI: Use unique artifact names 2024-01-01 06:56:53 +01:00
dependabot[bot]
4da0e8d8ad Bump actions/download-artifact from 3 to 4
Bumps [actions/download-artifact](https://github.com/actions/download-artifact) from 3 to 4.
- [Release notes](https://github.com/actions/download-artifact/releases)
- [Commits](https://github.com/actions/download-artifact/compare/v3...v4)

---
updated-dependencies:
- dependency-name: actions/download-artifact
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
2024-01-01 04:48:34 +01:00
dependabot[bot]
b95bfba676 Bump actions/upload-artifact from 3 to 4
Bumps [actions/upload-artifact](https://github.com/actions/upload-artifact) from 3 to 4.
- [Release notes](https://github.com/actions/upload-artifact/releases)
- [Commits](https://github.com/actions/upload-artifact/compare/v3...v4)

---
updated-dependencies:
- dependency-name: actions/upload-artifact
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
2024-01-01 04:48:19 +01:00
Jonas Kvinge
1ff2bfd390 Organize: Only update song path for collection songs
Possible fix for #1341
2023-12-28 23:30:07 +01:00
Jonas Kvinge
a35fa5b158 Require KDSingleApplication 1.1.0 2023-12-26 23:30:25 +01:00
Strawbs Bot
22169bda0d Update translations 2023-12-13 23:59:26 +01:00
Jonas Kvinge
faf5f6c69d CI: Remove Fedora 37 and add 40 2023-12-09 23:51:07 +01:00
Jonas Kvinge
1ae01d4078 Turn on git revision 2023-12-09 23:50:14 +01:00
Jonas Kvinge
eb6289dd1c Release 1.0.22 2023-12-09 23:21:35 +01:00
Jonas Kvinge
671df6eafb Update Changelog 2023-12-09 23:17:19 +01:00
Jonas Kvinge
579563b32c README: Fix emojis 2023-12-09 21:02:18 +01:00
Jonas Kvinge
135b93a5af StretchHeaderView: Set default section size
As of Qt 6.6.1, style changes are resetting the column sizes. To prevent this, we set a default section size.

Fixes #1328
2023-12-09 01:47:37 +01:00
BetterCallMolly
84c6e09c42 Player: Fix crossfade crash when decoding fails
When the decoding of a track fails, `current_item_` is set to an invalid address, if the Crossfade option is enabled, the `Player::TrackAboutToEnd` method does not check whether `current_item_` is a valid pointer or not, causing a segmentation fault.

Player: Removed extra space
2023-12-03 22:07:09 +01:00
Strawbs Bot
b4f9808d11 Update translations 2023-12-02 04:30:54 +01:00
Jonas Kvinge
d96d4224a2 Collection: Use normal pointer for watcher
Fixes #1316
2023-11-29 22:26:40 +01:00
Jonas Kvinge
f65927e308 metatypes: Register QAbstractSocket::SocketState 2023-11-29 22:25:03 +01:00
Jonas Kvinge
eeeea8566e nsi: Handle silent uninstall
Fixes #1323
2023-11-26 21:35:48 +01:00
Jonas Kvinge
54c42b276f GstEnginePipeline: Increase thread priority 2023-11-26 13:12:03 +01:00
Jonas Kvinge
8e4b4d6e41 nsi: Fix faad dll filename 2023-11-15 16:42:02 +01:00
Jonas Kvinge
ac9fd9070f GstEnginePipeline: Only set max size buffer if > 0
Fixes #1302
2023-11-12 22:04:31 +01:00
Jonas Kvinge
6348649bc6 GstEnginePipeline: Run QTimer::singleShot in main thread
Partial fix for #1302
2023-11-12 21:57:59 +01:00
Strawbs Bot
c95886d8db Update translations 2023-11-05 22:10:17 +01:00
Michał Walenciak
117b965a7b Translate number of tracks with nice plural forms 2023-11-05 19:37:56 +01:00
Michał Walenciak
1b6b5f9afa Use plurals 2023-11-05 19:37:56 +01:00
Michał Walenciak
83bc8d9e86 Select target language 2023-11-05 19:37:56 +01:00
Michał Walenciak
33f0421d3f Use 'n' for proper plurar form 2023-11-05 19:37:56 +01:00
Sergei B
661615e546 Allow drag and drop of songs to favorite playlists
- allows adding songs from active playlist
to any favorite by drag & drop
- after 500msec hovering with the songs over
desired playlist it becomes current
- drag & drop multiple songs is supported
2023-11-04 21:06:04 +01:00
Jonas Kvinge
c52fc90306 CI: Don't run SSH upload or macOS codesign on forks 2023-11-03 22:47:25 +01:00
Jonas Kvinge
eeb55fbc42 nsi: Update icu to 74 2023-11-01 23:07:47 +01:00
Jonas Kvinge
5d77eb1901 Change URL for KDSingleApplication submodule to https 2023-10-28 19:26:11 +02:00
Jonas Kvinge
654a94fe3d nsi: Add libabsl_kernel_timeout_internal.dll 2023-10-28 15:32:49 +02:00
Jonas Kvinge
4238708226 README: Update build instructions 2023-10-28 00:56:08 +02:00
Jonas Kvinge
5f02072bf3 CMake: Fix KDSingleApplication version check
Fixes #1300
2023-10-23 23:56:59 +02:00
Jonas Kvinge
eec5b448b6 CI: Add fftw3-devel for openSUSE 2023-10-23 19:45:50 +02:00
Jonas Kvinge
5cda756f92 CI: Remove get release version for macOS private 2023-10-23 19:37:40 +02:00
Jonas Kvinge
e9588dd85b CI: Remove SSH key setup from macOS private 2023-10-22 21:34:12 +02:00
Jonas Kvinge
dda0e4aa06 CI: Use MACOS_KEYCHAIN_PASSWORD 2023-10-22 21:13:28 +02:00
Jonas Kvinge
2282406166 CI: Build on self-hosted runner only on private repo 2023-10-22 18:51:23 +02:00
Jonas Kvinge
b3f0dee8e9 CI: Add "if: true" to easily disable steps 2023-10-22 17:20:28 +02:00
Jonas Kvinge
f9f7381247 CI: Fix APPLE_DEVELOPER_ID echo 2023-10-22 17:15:49 +02:00
Jonas Kvinge
48685325e6 Use KDSingleApplication as a submodule 2023-10-22 16:32:55 +02:00
Jonas Kvinge
e8bcaf415c CI: Only run SSH upload on this repo 2023-10-22 15:26:23 +02:00
Ondrej Mosnáček
c9197e8df7 CMake: Fix KDSingleApplication package name for Qt5
The name of the Qt5 KDSingleApplication CMake package is just
"KDSingleApplication", not "KDSingleApplication-qt".

Signed-off-by: Ondrej Mosnáček <omosnacek@gmail.com>
2023-10-22 14:24:52 +02:00
Jonas Kvinge
2bb09cf575 Song: Handle MP2 in Song::FiletypeByDescription 2023-10-21 05:07:25 +02:00
Jonas Kvinge
7bf4ad3884 Song: Handle MP2 in Song::FiletypeByExtension 2023-10-21 04:59:50 +02:00
Jonas Kvinge
5154d7ac84 Song: Rename MP3 to MPEG 2023-10-21 04:59:33 +02:00
Jonas Kvinge
9299653722 Turn on git revision 2023-10-21 04:57:53 +02:00
Jonas Kvinge
b0f0133d29 Release 1.0.21 2023-10-21 03:53:40 +02:00
Jonas Kvinge
9211b6f0c0 GstStartup: Remove macOS libsoup workarounds 2023-10-21 03:05:04 +02:00
Strawbs Bot
ab6a0ed6dd Update translations 2023-10-21 01:33:19 +02:00
Jonas Kvinge
c975c1e4aa CI: Remove unused homebrew and macports build 2023-10-20 00:53:49 +02:00
Jonas Kvinge
f9a593dc74 CI: Remove conflicting files for MSVC 2023-10-19 23:25:06 +02:00
Jonas Kvinge
9151520d50 CI: Remove uninstalling mingw 2023-10-18 23:19:50 +02:00
Jonas Kvinge
8f72d877bd CI: Manually sign libraries missing signature 2023-10-18 20:47:17 +02:00
Jonas Kvinge
e1990c9315 macgstcopy: Add rpath to gst plugin scanner 2023-10-18 20:46:24 +02:00
Jonas Kvinge
4cd5dcbfcf Update Changelog 2023-10-15 20:21:41 +02:00
Jonas Kvinge
3ee2125e8f CI: Verify code-signing 2023-10-15 16:51:13 +02:00
Jonas Kvinge
4652f3b449 CI: Manually codesign libsoup dependencies 2023-10-15 16:51:04 +02:00
Jonas Kvinge
697717eb1e CI: Use apple-actions/import-codesign-certs 2023-10-15 16:09:25 +02:00
Jonas Kvinge
cbde71f5f1 CI: Remove macOS lconvert and jenkins workaround 2023-10-15 07:48:20 +02:00
Jonas Kvinge
bf52afa21d GstStartup: Add back LIBSOUP3_LIBRARY_PATH 2023-10-15 07:46:49 +02:00
Jonas Kvinge
2083e008ab CI: Add macOS code-signing 2023-10-15 06:28:38 +02:00
Jonas Kvinge
2be0d23b1b macgstcopy: Change ID with install_name_tool 2023-10-14 23:24:56 +02:00
Jonas Kvinge
fda56dda25 main: Use Utilities::SetEnv 2023-10-14 23:18:16 +02:00
Jonas Kvinge
ed259781e9 CI: Remove rsync install and -DBUILD_WERROR 2023-10-14 23:17:58 +02:00
Jonas Kvinge
0c7fcd5a7a CMake: Fix USE_BUNDLE default 2023-10-14 22:09:14 +02:00
Jonas Kvinge
310b7b9065 CollectionQuery: Add F for float 2023-10-14 22:08:50 +02:00
Jonas Kvinge
cd534bbda7 CMake: Remove USE_BUNDLE_DIR 2023-10-14 03:30:09 +02:00
Jonas Kvinge
1a66eaf7bf GstStartup: Refactor environment code 2023-10-14 03:29:54 +02:00
Jonas Kvinge
a94d6e3dd8 CI: macgstcopy.sh copies libsoup now 2023-10-14 03:29:14 +02:00
Jonas Kvinge
54cfb2bbc4 main: Don't override library paths 2023-10-14 03:28:28 +02:00
Jonas Kvinge
00bc3f76cf macgstcopy: Copy libsoup 2023-10-14 03:27:57 +02:00
Jonas Kvinge
71a6d378d9 workerpool: Always search plugin path for tagreader on macOS 2023-10-14 03:27:32 +02:00
Jonas Kvinge
99a5aee8b3 GstEnginePipeline: Change debug logging for active/inactive 2023-10-13 23:38:19 +02:00
Jonas Kvinge
89d2a23dac CollectionBackend: Use QString::arg() 2023-10-13 23:06:29 +02:00
Jonas Kvinge
ee1bf47f5c DeviceInfo: Simplify hint 2023-10-13 22:58:53 +02:00
Jonas Kvinge
13ac20f8b3 Add/remove reference for parameters 2023-10-13 22:58:18 +02:00
Jonas Kvinge
adef05bbdf Use QString::arg() 2023-10-13 22:55:20 +02:00
Jonas Kvinge
f03ff452b8 SavePlaylistsDialog: Add parent to ctor 2023-10-13 22:53:27 +02:00
Jonas Kvinge
c39489060b Mpris2: Add static_cast 2023-10-13 22:52:36 +02:00
Jonas Kvinge
002fa8f4aa Fix mismatched definition 2023-10-13 22:49:20 +02:00
Jonas Kvinge
d2c747258c Song: Add MPC to FiletypeByMimetype and FiletypeByDescription 2023-10-12 01:16:40 +02:00
Jonas Kvinge
53e3664726 CI: Install hub in upload release step 2023-10-11 17:37:47 +02:00
Jonas Kvinge
26ff9f6b53 Update Changelog 2023-10-10 23:44:34 +02:00
Jonas Kvinge
f542f1c854 GstEnginePipeline: Remove volume sync for Auto
Workaround crash in #1123
2023-10-10 23:17:03 +02:00
Jonas Kvinge
33041ffa75 GstEnginePipeline: Delay seek when when resetting next URI
When seeking after the next URI is set, we set the state to READY to switch the URI back. The seek in after going to ready sometimes does not work, delay the seek to workaround this.

Fixes #1258
2023-10-10 23:00:11 +02:00
Jonas Kvinge
1493164df9 CollectionQuery: Strip off whitespaces after colon and simplify code
Fixes #1290
2023-10-10 19:15:20 +02:00
Strawbs Bot
8ffef558ff Update translations 2023-10-10 01:37:19 +02:00
Jonas Kvinge
8b3f44ffca Update Changelog 2023-10-10 01:32:33 +02:00
Jonas Kvinge
2706529006 DeviceDatabaseBackend: Add missing ebur128 fields 2023-10-10 01:27:39 +02:00
Jonas Kvinge
7e331a2055 DeviceManager: Fix creating connected device 2023-10-10 01:26:47 +02:00
Jonas Kvinge
505329730c Improve lyrics match 2023-10-08 23:55:05 +02:00
Jonas Kvinge
1a07404c10 Simplify RPM spec file 2023-10-08 16:15:59 +02:00
Jonas Kvinge
b02adc7758 Simplify RPM spec file 2023-10-08 13:54:36 +02:00
Jonas Kvinge
952252ebcd Simplify RPM spec file 2023-10-08 02:55:22 +02:00
Jonas Kvinge
eee0c40132 Playlist: Use InternetServicePtr 2023-10-07 17:05:51 +02:00
Jonas Kvinge
567bad33e1 Playlist: Use PlaylistItemPtr 2023-10-07 17:05:36 +02:00
Jonas Kvinge
b5c0e93989 FancyTabWidget: Use QApplication::style(), not style() 2023-10-07 15:36:49 +02:00
Jonas Kvinge
ac17df2a86 PlaylistContainer: Remove unused signals 2023-10-07 15:34:37 +02:00
Jonas Kvinge
a9a5899252 FancyTabWidgetProxyStyle: Create proxy style from application style 2023-10-07 15:23:41 +02:00
Jonas Kvinge
395d85c1b4 Move PlaylistProxyStyle to it's own file 2023-10-07 15:16:39 +02:00
Jonas Kvinge
52ba1ce17f PlaylistView: Fix build with Qt 5 2023-10-07 15:04:00 +02:00
Jonas Kvinge
604a246fe8 PlaylistProxyStyle: Use CE_HeaderLabel instead of CE_Header 2023-10-07 14:50:46 +02:00
Jonas Kvinge
e172c4871c PlaylistView: Create proxy style based on application style
Fixes #1275
2023-10-07 14:48:40 +02:00
Jonas Kvinge
2a9b32690d Update Changelog 2023-10-07 02:52:47 +02:00
Jonas Kvinge
76fa4745d0 GstEnginePipeline: Only update last known position when possible
Fixes flaky seeking where gst_element_query_position() returns -1 when seeking.
2023-10-07 02:47:12 +02:00
Strawbs Bot
6f4d26e9d3 Update translations 2023-10-04 00:33:42 +02:00
Jonas Kvinge
f40f43861d EngineBase: Use enum class for TrackChangeType 2023-10-03 20:18:52 +02:00
Jonas Kvinge
717ebbbb24 CI: Install openssh-clients for openSUSE 2023-10-02 21:32:46 +02:00
Jonas Kvinge
79c69e1b1e CollectionWatcher: Match extension case-insensitive 2023-10-02 17:39:10 +02:00
Jonas Kvinge
8fc95e08dc CollectionWatcher: Ignore compressed files
Fixes #1274
2023-10-02 17:23:47 +02:00
Jonas Kvinge
3f06528ba3 Fix version without git tags 2023-10-02 17:04:15 +02:00
Jonas Kvinge
0e44b10eec Add Ko-fi to funding options 2023-09-28 16:55:25 +02:00
Jonas Kvinge
d74fe92ce8 Use system KDSingleApplication when available 2023-09-27 20:19:43 +02:00
Jonas Kvinge
8037948f7f Dmg: Remove extra macdeployqt executable parameters
macdeployqt is patched and should handle .so libraries too now.
2023-09-26 23:46:11 +02:00
Jonas Kvinge
ab29170972 CI: Disable macOS homebrew build 2023-09-26 23:45:11 +02:00
Jonas Kvinge
6f843e2499 CI: Disable macports build
Issue #1278
2023-09-26 18:22:43 +02:00
Jonas Kvinge
6b8a816ce6 macgstcopy: Check for both .dylib and .so extensions for plugins
Require at least coreelements to be found in plugins directory
2023-09-26 17:04:20 +02:00
Jonas Kvinge
2c0541fb79 CI: Delete conflicting ICU case-insensitive 2023-09-26 00:34:13 +02:00
Jonas Kvinge
cb22890d79 CI: Simplify setting CMAKE_BUILD_TYPE and ENABLE_WIN32_CONSOLE 2023-09-26 00:34:13 +02:00
Jonas Kvinge
5a9346cc80 Add libebur128 to strawberry.spec 2023-09-25 20:50:43 +02:00
Jonas Kvinge
1c85220ffa Add libebur128-dev to debian control 2023-09-25 20:50:43 +02:00
Jonas Kvinge
39d4818def CI: Fix PPA upload 2023-09-25 20:16:26 +02:00
Jonas Kvinge
db0cc66ba0 CI: Fix Mageia rpm upload 2023-09-25 20:15:56 +02:00
Strawbs Bot
c10a64f08a Update translations 2023-09-25 02:37:58 +02:00
Jonas Kvinge
5a3d60b203 Turn on git revision 2023-09-25 00:10:41 +02:00
Jonas Kvinge
28b9bf1f76 Release 1.0.20 2023-09-25 00:03:45 +02:00
Jonas Kvinge
27dbb2dd9e Release 1.0.19 2023-09-24 23:19:15 +02:00
Jonas Kvinge
9b7b790f21 CI: Fix upload 2023-09-24 23:18:24 +02:00
Jonas Kvinge
e3666e5bf3 Remove OTHER_SOURCES 2023-09-24 19:53:49 +02:00
Jonas Kvinge
9e38cd8dc2 CI: Remove fixed path 2023-09-24 18:16:01 +02:00
Jonas Kvinge
b105b9fd8f CI: Use CREATEDMG_SKIP_JENKINS on macOS arm64 2023-09-24 17:45:18 +02:00
Jonas Kvinge
6a018f3e25 MainWindow: Add sponsorship mesage 2023-09-24 15:09:20 +02:00
Jonas Kvinge
ab26d422e9 MainWindow: Update rosetta message 2023-09-24 15:08:57 +02:00
Jonas Kvinge
f4e18fb87c MessageDialog: Set minimum width 2023-09-24 15:08:35 +02:00
Jonas Kvinge
2b20ff4e67 Update README.md 2023-09-24 13:19:05 +02:00
Jonas Kvinge
28d5cd481b Add macOS code-signing 2023-09-24 03:03:52 +02:00
Jonas Kvinge
42f3340190 Update Changelog 2023-09-23 23:56:36 +02:00
Jonas Kvinge
0ef50e1b6d Remove unused variables 2023-09-23 23:55:49 +02:00
Jonas Kvinge
01ddded603 CI: Use create-dmg with --skip-jenkins only for macOS arm64 2023-09-23 21:58:35 +02:00
Jonas Kvinge
fe7e0ffbba CI: Add macOS arm64 build and upload path 2023-09-23 03:08:51 +02:00
Jonas Kvinge
5df6066150 Update Changelog 2023-09-20 20:54:28 +02:00
Jonas Kvinge
8393cdb2de Add lyrics from elyrics.net and lyricsmode.com 2023-09-20 19:02:28 +02:00
Jonas Kvinge
da19272eb6 HtmlLyricsProvider: Rename GetUrl to Url 2023-09-20 17:39:44 +02:00
Jonas Kvinge
60fb83d770 HtmlLyricsProvider: Remove <script> tags and content between 2023-09-20 17:38:45 +02:00
Jonas Kvinge
1c90b03476 Add HTML lyrics provider 2023-09-20 01:09:08 +02:00
Jonas Kvinge
50502ce720 Add azlyrics.com lyrics provider 2023-09-19 22:47:07 +02:00
Jonas Kvinge
39f9d02454 Add songlyrics.com lyrics provider 2023-09-19 16:56:10 +02:00
Jonas Kvinge
ce627b0e18 Update Changelog 2023-09-19 00:30:56 +02:00
Jonas Kvinge
cdb4980337 CollectionBackend: Don't expire unavailable songs part of playlists 2023-09-17 21:54:27 +02:00
Jonas Kvinge
878148ac32 Use system macdeployqt 2023-09-17 01:23:53 +02:00
Jonas Kvinge
0bc29f0563 nsi: Disable wasapi2 2023-09-17 00:31:42 +02:00
Jonas Kvinge
e201f71a74 CMake: Simplify Qt detection 2023-09-16 14:55:42 +02:00
buckmelanoma
7e684885cf Capitalize column names
Capitalize column names for consistency with OS
2023-09-15 15:33:07 +02:00
dependabot[bot]
e600c1b50c Bump crazy-max/ghaction-import-gpg from 5 to 6
Bumps [crazy-max/ghaction-import-gpg](https://github.com/crazy-max/ghaction-import-gpg) from 5 to 6.
- [Release notes](https://github.com/crazy-max/ghaction-import-gpg/releases)
- [Commits](https://github.com/crazy-max/ghaction-import-gpg/compare/v5...v6)

---
updated-dependencies:
- dependency-name: crazy-max/ghaction-import-gpg
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-09-14 21:13:53 +02:00
Jonas Kvinge
5da2faa400 CI: Replace actions-download-file with curl 2023-09-07 23:03:49 +02:00
Jonas Kvinge
05cd134a24 CI: Remove macOS homebrew upload 2023-09-07 21:19:34 +02:00
Jonas Kvinge
2f27a7d00b CI: Add new macOS build 2023-09-07 19:48:41 +02:00
Jonas Kvinge
d61d4d0a74 macdeploycheck: Use static QFile::exists 2023-09-06 22:59:16 +02:00
Jonas Kvinge
4033cd61c2 logging: Ignore -Wold-style-cast for glib.h 2023-09-05 23:42:56 +02:00
Jonas Kvinge
7cd6f372e6 MacOsDeviceLister: Move kind variable inside #ifdef HAVE_AUDIOCD 2023-09-05 23:42:32 +02:00
Jonas Kvinge
ffe6eb3de7 KDSingleApplicationLocalSocket: Ignore -Wgnu-zero-variadic-macro-arguments 2023-09-05 23:34:43 +02:00
Jonas Kvinge
e2b0b1b1fb CI: Use latest MSVC dependencies download URL 2023-09-05 18:29:59 +02:00
Jonas Kvinge
1f15ca70a3 CI: Remove install_name_tool step from macports 2023-09-05 18:15:54 +02:00
dependabot[bot]
904ee6a9b3 Bump actions/checkout from 3 to 4
Bumps [actions/checkout](https://github.com/actions/checkout) from 3 to 4.
- [Release notes](https://github.com/actions/checkout/releases)
- [Changelog](https://github.com/actions/checkout/blob/main/CHANGELOG.md)
- [Commits](https://github.com/actions/checkout/compare/v3...v4)

---
updated-dependencies:
- dependency-name: actions/checkout
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-09-04 20:24:34 +02:00
Jonas Kvinge
0461e98a4c nsi: Add libspeexd.dll for MSVC debug 2023-09-04 19:06:07 +02:00
Jonas Kvinge
dc01a18b87 Remove lyrics.com lyrics provider
Does not provider full lyrics in API. The URL we used only points to a page with "Get the lyrics for <song> at Lyrics.com" now.
2023-08-31 23:22:22 +02:00
Strawbs Bot
7be0e284c2 Update translations 2023-08-31 22:52:37 +02:00
Jonas Kvinge
6dd79d5b8f MainWindow: Bound volume between 0 and 100
Fixes #1262
2023-08-30 21:43:52 +02:00
Jonas Kvinge
f81b725d42 CI: Uninstall all homebrew packages 2023-08-30 19:37:10 +02:00
Jonas Kvinge
cfeecd98f6 Dmg: Remove DEPENDS deploy deploycheck 2023-08-30 16:22:33 +02:00
Jonas Kvinge
d054dd33e2 CI: Replace relative library @loader_path paths, macdeployqt does not understand these 2023-08-30 15:22:33 +02:00
Jonas Kvinge
45ad84a9bc Fix build with macOS < 12.0 2023-08-27 13:54:23 +02:00
Jonas Kvinge
a333662f56 CI: Add macOS brew tap step 2023-08-27 01:33:01 +02:00
Jonas Kvinge
59f716563f QSearchField: Use static_cast 2023-08-27 01:15:01 +02:00
Jonas Kvinge
6815f8c9b7 MacOsDeviceFinder: Rename kAudioObjectPropertyElementMaster to kAudioObjectPropertyElementMain 2023-08-27 01:14:42 +02:00
Jonas Kvinge
8e5360ac38 MacOsDeviceLister: Rename kIOMasterPortDefault to kIOMainPortDefault 2023-08-27 01:14:24 +02:00
Jonas Kvinge
aa6809ad5f DeviceManager: Use pointer directly 2023-08-27 01:14:00 +02:00
Jonas Kvinge
d8a7d427c3 BehaviourSettingsPage: Simplify Load 2023-08-27 01:12:38 +02:00
Jonas Kvinge
bc1b45d912 MainWindow: Fix build on macOS 2023-08-27 00:09:49 +02:00
Jonas Kvinge
50c5283599 BehaviourSettingsPage: Use QSystemTrayIcon::isSystemTrayAvailable directly 2023-08-26 21:21:31 +02:00
Jonas Kvinge
02ef65bcfd MainWindow: Only keep running when system tray icon is enabled 2023-08-26 21:20:50 +02:00
Jonas Kvinge
904245bb21 keymapper_x11: Qt::Key_mu renamed Qt::Key_micro from Qt 6.7 2023-08-26 21:15:26 +02:00
Jonas Kvinge
57e29b2be9 CI: Fix macOS rpaths 2023-08-13 12:19:14 +02:00
Jonas Kvinge
53a5603f64 CI: Fix dnf 2023-08-11 17:03:39 +02:00
Jonas Kvinge
8805a21567 CI: Remove Fedora workarounds 2023-08-11 00:17:45 +02:00
Jonas Kvinge
c6fee92450 CI: Fix macOS build 2023-08-10 01:40:51 +02:00
Jonas Kvinge
46c90f3712 CI: Check for missing Delete entries in NSI 2023-08-09 19:53:31 +02:00
Jonas Kvinge
e3c1c6ee9a nsi: Add missing double-quote 2023-08-09 19:52:01 +02:00
Jonas Kvinge
8bfbd69a2c nsi: Add libabsl_log_internal_conditions.dll 2023-08-09 19:41:06 +02:00
Jonas Kvinge
6a6649823e CI: List copied MinGW dependencies 2023-08-09 19:40:51 +02:00
Jonas Kvinge
bfb95d503a ErrorDialog: Clear messages on close instead of hide
Fixes an issue where the error dialog is cleared because the hide event gets triggered.
2023-08-07 19:38:48 +02:00
Jonas Kvinge
d1b4736ef9 ErrorDialog: Give name to layouts 2023-08-07 19:36:20 +02:00
Jonas Kvinge
e56e58b634 GstEnginePipeline: Always set use-buffering 2023-08-06 13:44:57 +02:00
Jonas Kvinge
fed5b6b695 GstEnginePipeline: Rename ebur128 volume variable 2023-08-06 13:36:25 +02:00
Jonas Kvinge
e96870cfbd nsi: Update to ffmpeg 6.0 for MSVC 2023-08-04 19:40:00 +02:00
Jonas Kvinge
acda7c13b2 GlobalShortcutsBackendMacOSPrivate: Replace boost::noncopyable with Q_DISABLE_COPY 2023-08-04 03:36:01 +02:00
Jonas Kvinge
7d5c7f8493 MacOsDeviceLister: Replace BOOST_SCOPE_EXIT with QScopeGuard 2023-08-04 03:36:01 +02:00
Jonas Kvinge
4ef3f3568d CI: Remove Ubuntu Kinetic 2023-08-03 20:14:54 +02:00
Jonas Kvinge
f81bd26649 MergedProxyModelPrivate: Formatting 2023-08-03 20:03:48 +02:00
Jonas Kvinge
2a407bfe47 ScopedTransaction: Replace boost::noncopyable with Q_DISABLE_COPY 2023-08-03 19:58:16 +02:00
Jonas Kvinge
f70f126f76 AlsaDeviceFinder: Replace BOOST_SCOPE_EXIT with QScopeGuard 2023-08-03 17:29:42 +02:00
Jonas Kvinge
f06591fde8 Database: Replace BOOST_SCOPE_EXIT with QScopeGuard 2023-08-03 17:29:11 +02:00
Strawbs Bot
e0c9a9dc17 Update translations 2023-08-03 01:03:54 +02:00
Jonas Kvinge
0f16fc2776 CI: Remove FreeBSD 2023-08-02 17:21:14 +02:00
Dakes
7aa7cdf6f3 Add filtering of numerical cols to collection
CollectionFilterWidget: Updated the tooltip, to reflect the changes.
CollectionQuery: Add parsing for SQL operators and insert right SQL
"where" searches.
Song: Add list of numerical columns
playlistfilterparser.cpp/FilterParser: move time and rating parsing
functions to new file:
searchparserutils.cpp: Contains common code used to parse search terms
in playlist and collection filters.
2023-08-02 16:52:27 +02:00
Dakes
82a8a890de PlaylistContainer: Add tooltip to search field 2023-08-02 16:52:27 +02:00
Dakes
f8df901963 PlaylistFilter: Add playcount and skipcount 2023-08-02 16:52:27 +02:00
Jonas Kvinge
8b08d1d599 Mpris2: Always use QGuiApplication::desktopFileName 2023-08-02 15:27:24 +02:00
Jonas Kvinge
f3ddba3edc main: Set desktop filename
Fixes #1254
2023-08-02 14:37:24 +02:00
Jonas Kvinge
acbec6db7e main: Set application display name 2023-08-02 14:25:40 +02:00
Jonas Kvinge
d2390473bc Update Changelog 2023-08-01 19:29:38 +02:00
Jonas Kvinge
e273d64be3 Player: Always stop after 100 errors
Fixes #1199
2023-08-01 16:59:43 +02:00
Jonas Kvinge
2a90256d32 GstEnginePipeline: Disable volume sync on Windows
Fixes #1220
2023-08-01 16:39:57 +02:00
Jonas Kvinge
560712db21 ebur128analysis: Check for valid channel-mask 2023-07-30 03:18:48 +02:00
Jonas Kvinge
483b42d2b8 GstStartup: Use directsoundsink as primary sink 2023-07-29 22:54:49 +02:00
Jonas Kvinge
d1a6e53f5c TagReaderTagLib: Read FMPS_Playcount
Fixes #1248
2023-07-29 18:33:50 +02:00
Dakes
f5a55abf58 Mpris2: Add new property to read/write the rating 2023-07-27 11:24:19 +02:00
Jonas Kvinge
0bc94b90d7 SmartPlaylistSearchTerm: Handle unrated (-1) as zero
Fixes #1244
2023-07-26 01:45:28 +02:00
Strawbs Bot
9ed4bd9366 Update translations 2023-07-24 09:46:20 +02:00
Jonas Kvinge
d3352e476f Remove < 0 check on unsigned 2023-07-21 07:17:58 +02:00
Jonas Kvinge
4b4c5fc0ab Use const reference for AlbumCoverLoaderOptions::Types 2023-07-21 07:17:26 +02:00
Jonas Kvinge
38b9c7c38a MusixmatchCoverProvider: Add const 2023-07-21 07:16:32 +02:00
Jonas Kvinge
c71ce41c83 LastFMImport: Move variable declaration 2023-07-21 07:16:23 +02:00
Jonas Kvinge
4cd030215d Transcoder: Remove useless empty check 2023-07-21 07:16:08 +02:00
Jonas Kvinge
2ce5d6f727 Database: Add missing const 2023-07-21 07:15:55 +02:00
Jonas Kvinge
b55a0df8e1 CollectionView: Remove useless variable 2023-07-21 07:15:42 +02:00
Jonas Kvinge
ee5fa23a7a LocalRedirectServer: Remove unused https variable 2023-07-21 07:15:08 +02:00
Jonas Kvinge
75ab6f25f4 Check return of QSqlQuery::prepare 2023-07-21 07:12:20 +02:00
Jonas Kvinge
eaed82c9b2 CollectionItemDelegate: Remove check for nullptr, already done 2023-07-21 07:11:21 +02:00
Jonas Kvinge
2a4be6fcd7 BoomAnalyzer: Move variable declaration 2023-07-21 07:10:31 +02:00
Jonas Kvinge
e6198500f7 BlockAnalyzer: Remove useless continue 2023-07-21 07:10:17 +02:00
Jonas Kvinge
7db36c83c1 MainWindow: Don't use our network manager for Qt Sparkle 2023-07-21 06:20:46 +02:00
Jonas Kvinge
0e1921698c TidalUrlHandler: service is already a pointer 2023-07-21 06:11:16 +02:00
Jonas Kvinge
95eed1ecec Fix QtConcurrent::run build with Qt 5 2023-07-21 06:10:44 +02:00
Jonas Kvinge
2e61235403 Application: Use shared pointers
Fixes #1239
2023-07-21 05:55:24 +02:00
Jonas Kvinge
d6b53f78ab Cleanup includes 2023-07-21 05:25:57 +02:00
Jonas Kvinge
a2c7ff63df Formatting 2023-07-21 05:11:27 +02:00
Roman Lebedev
9fb15545bd GstEnginePipeline: Perform EBU R 128 Loudness Normalization in floating-point 2023-07-19 03:07:22 +02:00
Jonas Kvinge
277e08b94a README: Add libebur128 to optional dependencies 2023-07-19 02:40:31 +02:00
Jonas Kvinge
46224fe9b8 nsi: Add gst-play-1.0.exe 2023-07-18 21:28:39 +02:00
Jonas Kvinge
56180ca419 LocalRedirectServer: Remove https option and gnutls dependency 2023-07-18 19:44:45 +02:00
Jonas Kvinge
dc65753a0b ebur128analysis: Remove extra semicolon 2023-07-16 23:26:17 +02:00
Jonas Kvinge
d8857d8e72 Add missing QMetaType include 2023-07-12 18:13:02 +02:00
Jonas Kvinge
fdc3e0a5f5 LyricsSearchResult: Add missing QList include 2023-07-12 18:12:48 +02:00
Jonas Kvinge
8f7180eb6c Song: Pass double by value 2023-07-12 18:12:08 +02:00
Jonas Kvinge
8945602eae Song: Add missing newlines between functions 2023-07-12 18:11:43 +02:00
Jonas Kvinge
7826f77425 Formatting 2023-07-12 16:27:59 +02:00
Jonas Kvinge
00372e85c5 FilterParser: Silence double / float warning 2023-07-12 16:27:28 +02:00
Jonas Kvinge
a1ffc5c33b ebur128analysis: Rename dsc variable 2023-07-12 16:26:39 +02:00
Jonas Kvinge
8a44a41abb ebur128analysis: Initialize variables to silence warnings 2023-07-12 16:26:17 +02:00
Jonas Kvinge
23f0c56eba Song: Move ebur128 functions 2023-07-12 16:23:27 +02:00
Jonas Kvinge
3d25863ccb CollectionWatcher: Make PerformEBUR128Analysis const 2023-07-12 16:22:17 +02:00
Jonas Kvinge
bb6daca735 GME: Add static_cast to silence warnings 2023-07-12 16:22:02 +02:00
Roman Lebedev
4bd993b1e3 GstEngine/GstEnginePipeline: support gap-less playback w/ loudness-normalizing gain
Ok, it does appear that it is that simple.

In principle this (even the non-update case) results in volume jumps,
so maybe we'll want gradual gain change...

Notably, i thought we'd always seek if the pipeline
was already operating on the same URL as the new one,
but apparently only for adjacent songs?
2023-07-12 14:34:04 +02:00
Roman Lebedev
f81816b0cd EBUR128Analysis: handle channel map
Loudness measurement is channel-dependent.
This perhaps matters most for mono audio.
2023-07-12 14:34:04 +02:00
Roman Lebedev
7ac605c038 EBU R 128: update ChangeLog/README 2023-07-12 14:34:04 +02:00
Roman Lebedev
2a8b67d11e Handle libebur to windows installers 2023-07-12 14:34:04 +02:00
Roman Lebedev
16893cca24 CI: install libebur128 package 2023-07-12 14:34:04 +02:00
Roman Lebedev
94ab788032 GstEnginePipeline: actually perform (EBU R 128) loudness normalization
The magic: if EBU R 128 loudness normalization is enabled,
just insert `volume` GST element into the pipeline
(where ReplayGain would be inserted) and configure it.

We currently don't support changing said gain after the pipeline
was created. We might need to, though, for a number of reasons.
2023-07-12 14:34:04 +02:00
Roman Lebedev
e3a333564a GstEngine::Load(): different loudness-normalizing gain means new pipeline
This is a bit of a gotcha, there should be a point (where we seek?)
where we'd be able to change said gain, but for now this is a simple[r]
stop-gap fix.
2023-07-12 14:34:04 +02:00
Roman Lebedev
13d6cf201f Engine: pipe-in the EBU R 128 loudness normalization gain stuff
The idea is that Integrated Loudness is an integral part
of the song, much like knowing it's beginning / ending
in the file, and we must handle it the exact same way,
and pipe it through all the way.

At the same time, `EngineBase` knows Target Level (from settings),
and these two combined tell us the Gain needed to normalize the
Loudness of the particular Song (`EngineBase::Load()` does that).
So the actual backend only needs to handle the Volume.

We don't currently support changing Target Level on the fly.
We don't currently support changing Loudness-normalizing Gain on the fly.

This does not handle the case when the song is loaded from URL
and thus the EBU R 128 measures, that exist, are not nessesairly correct.
2023-07-12 14:34:04 +02:00
Roman Lebedev
40ef3191fc EBUR128Analysis: place a queue before appsink
This improves the performance of the analysis (by 2x!),
by offloading non-`libebur128`-computations (i.e. decode-convert)
to a separate thread, thus reducing walltime.
2023-07-12 14:34:04 +02:00
Roman Lebedev
bda2b91c92 Collectionwatcher: sink PerformEBUR128Analysis() into ScanNewFile & friends 2023-07-12 14:34:04 +02:00
Roman Lebedev
1462bfa297 CollectionWatcher: support EBU R 128 analysis
Again, somewhat pretty similar to the existing fingerprint analysis,
we must support performing it both for the new files,
and re-performing it on (some of) already-existing songs,
because it might have been disabled before.

Admittedly, i quite don't like some of this code,
maybe this can be done in a more concise way.

NOTE: this only supports scanning each separate songs.
Should we ever want to support per-album loudness normalization,
this will need massive changes...
2023-07-12 14:34:04 +02:00
Roman Lebedev
bafcb97fa1 Implement EBUR128Analysis
The most juicy bit!

This is based on Song Fingerprint Analysis,
but here we must know the actual song, and not just the file.

The library supports only interleaved S16/S32/F32/F64,
so we must be sure we insert `audioconvert` into pipeline.

One point of contention here for me, is whether we should
feed the frames to the library the moment we get them
in `NewBufferCallback`, or collect them in a buffer
and pass them all at once. I've gone with the former,
because it seems like that is not the worst choice:
https://github.com/strawberrymusicplayer/strawberry/pull/1216#issuecomment-1610075876

In principle, the analysis *could* fail,
so we want to handle that gracefully.
2023-07-12 14:34:04 +02:00
Roman Lebedev
f905676b1c CollectionBackend/CollectionWatcher: add HasSongsWithMissingLoudnessCharacteristics logic
Exactly identical to the "missing fingerprint" logic,
just for the two new fields being added.
2023-07-12 14:34:04 +02:00
Roman Lebedev
0ea81b13b9 BackendSettingsPage: add "EBU R 128 loudness normalization"-related settings
Change `Use Replay Gain metadata if it is available` checkbox
into a radio button and add button to disable any loudness normalization.

Add second group(+radio button), for EBU R 128 loudness normalization.

There is only one tunable: Target Level,
defaulting to EBU R 128-recommended `-23 LUFS`.

Care should be taken when changing Target Level!
You probably don't want to go outside of `-30..-16` range!

At least as implemented, there is only support for per-song normalization,
i.e. no per-album normalization.

We do not do anything with loudness range,
although i have some further thoughts about compression.

We do not do anything about clipping / peak level.

NOTE: we do not need `libebur128` to *perform* the audio normalization,
      only for the initial analysis.


Co-authored-by: Jonas Kvinge <jonas@jkvinge.net>
2023-07-12 14:34:04 +02:00
Roman Lebedev
9a7949297e CollectionSettingsPage: add option to toggle libebur128-based song analysis
Much like song fingerprinting, performing EBU R 128 analysis is optional.

If you will want to enable EBU R 128 loudness normalization
(which does not depend on the presence of `libebur128`!)
you will probably want to enable it, but it is not enabled by default.

There will be support for rescanning songs for which it is missing.
2023-07-12 14:34:04 +02:00
Roman Lebedev
29342fa9ac CMake: when optional component EBUR128 is detected, link to libebur128 2023-07-12 14:34:04 +02:00
Roman Lebedev
bd4438d99b CMake: define new optional component EBUR128 (libebur128+gstreamer)
To perform the analysis using said library, we need to first somehow
get the PCM of the song, and it makes sense to use GStreamer for that.
2023-07-12 14:34:04 +02:00
Roman Lebedev
f8e14e8fd5 CMake: look for libebur128
We are going to use said library to calculate the two measures in question
from decoded audio.

I am adding this in default-on state, since this library
should be well-packaged everywhere, and this is something that,
i presume, we want.
2023-07-12 14:34:04 +02:00
Roman Lebedev
b2c66c9cda Playlist: add newly-added columns
Still mostly boilter-plate-y. It is somewhat interesting to see that info
in playlist view, so add the two fileds as columns.

At least for Integrated loudness, since it's normally negative,
we need to add a specialized Delegate.
2023-07-12 14:34:04 +02:00
Roman Lebedev
44e5c32bcb ContextView: show newly-added fields
And still very boilerplate-y, same as in previous change,
just show the two new Song fields in `Context` view.
2023-07-12 14:34:04 +02:00
Roman Lebedev
e7fc4e7f89 EditTagDialog: show newly-added fields (read-only)
Still very boilerplate-y. Add two placeholders to the UI
(in the middle of the existing table, so the diff is a mess),
and populate them with data.
2023-07-12 14:34:04 +02:00
Roman Lebedev
e589486907 Song: add pretty-printers for EBU R 128 Integrated Loudness and Loudness Range fields
They end up being used in a quite a number of places later on,
it makes sense to have them in a common place.

Integrated Loudness (LUFS) is *usually* negative, so we really want to
always print a sign. But Loudness Range is non-negative.

I think it makes sense to print one or at most two decimal places for these.
2023-07-12 14:34:04 +02:00
Roman Lebedev
459c4c5d86 Song: add EBU R 128 Integrated Loudness and Loudness Range fields, DB [de]serialization
Again, pretty boring boilerplate, rather identical to the handling of
other fields. We do need to be careful when [de]serializing it, though,
we don't want to accidentally loose the `NULL` (i.e. unknown) state!
2023-07-12 14:34:04 +02:00
Roman Lebedev
73c56f038e SqlQuery: add BindDoubleOrNullValue() method
To facilitate serializing of the two DB fields added by the previous change.
2023-07-12 14:34:04 +02:00
Roman Lebedev
0a4888f861 Database scheme: add EBU R 128 Integrated Loudness and Loudness Range columns
Nothing really ground-breaking, just add those two fields
to each table that already has `bitrate`/`samplerate`/`bitdepth` fields.

Those new fields do need to be able to represent an invalid state
which is their default state, thus they are non-`NOT NULL`.
In principle, the actual field type could be `INTEGER`
(i.e. fixed point w/ 2 fractional digits), but unless we really want to
save a few bytes, it doesn't seem worthwhile.

FIXME: i'm not sure if `device-schema` should be changed too.
2023-07-12 14:34:04 +02:00
Jonas Kvinge
da27ca98b3 CI: Only upload release when INCLUDE_GIT_REVISION is OFF 2023-07-12 14:25:59 +02:00
Jonas Kvinge
f1e1ccad28 CI: Fix stable PPA upload 2023-07-12 14:22:15 +02:00
Jonas Kvinge
7616c06ff9 Use find_package(Protobuf CONFIG) for macOS too 2023-07-12 01:25:41 +02:00
Jonas Kvinge
0c1f4750ea KDSingleApplication: Add LICENSES
Fixes #1219
2023-07-02 22:17:36 +02:00
Strawbs Bot
0a26c295a0 Update translations 2023-07-02 14:10:05 +02:00
Jonas Kvinge
32d23e0484 Turn on git revision 2023-07-02 04:00:38 +02:00
Jonas Kvinge
c028770f8e Release 1.0.18 2023-07-02 01:27:51 +02:00
Jonas Kvinge
8f1a99b37e CI: Remove Fedora 36 2023-07-02 01:02:10 +02:00
Jonas Kvinge
e66651a4cb Song: Remove unused application include 2023-07-02 00:29:30 +02:00
Jonas Kvinge
1d9a052870 AlbumCoverChoiceController: Move result declaration 2023-07-02 00:29:19 +02:00
Jonas Kvinge
d3ee749c14 CollectionBackendTest: Fix build 2023-07-01 22:34:51 +02:00
Jonas Kvinge
33076aa33a Update Changelog 2023-07-01 22:26:52 +02:00
Jonas Kvinge
2a2663eeb5 Update Changelog 2023-06-29 20:31:16 +02:00
Jonas Kvinge
fa04eb67db Convert old embedded and unset art in the new schema 2023-06-29 20:21:50 +02:00
Jonas Kvinge
f8ad8a7211 Disable clang-format 2023-06-29 19:06:27 +02:00
Jonas Kvinge
5f4d6dffef AlbumCoverLoader: Fix loading existing album covers from disk 2023-06-29 00:44:00 +02:00
Jonas Kvinge
b9c7510946 AlbumCoverLoader: Fix Handling default image in finish task 2023-06-28 23:52:39 +02:00
dependabot[bot]
c0e709a0e3 Bump vmactions/freebsd-vm from 0.3.0 to 0.3.1
Bumps [vmactions/freebsd-vm](https://github.com/vmactions/freebsd-vm) from 0.3.0 to 0.3.1.
- [Release notes](https://github.com/vmactions/freebsd-vm/releases)
- [Commits](https://github.com/vmactions/freebsd-vm/compare/v0.3.0...v0.3.1)

---
updated-dependencies:
- dependency-name: vmactions/freebsd-vm
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-06-26 20:16:20 +02:00
Jonas Kvinge
e690be1bdd DeviceDatabaseBackend: Fix device schema version mismatch
schema_version in device-schema.sql is 4.
2023-06-26 20:06:11 +02:00
Jonas Kvinge
6ed5190276 Remove AudD lyrics 2023-06-25 01:14:12 +02:00
Jonas Kvinge
4c4a351fbd CI: Add ubuntu mantic for ppa 2023-06-25 00:28:21 +02:00
Jonas Kvinge
435ffc75b6 CI: Add debian trixie 2023-06-24 03:40:23 +02:00
Jonas Kvinge
4dbc06bdd0 CI: Add ubuntu mantic 2023-06-24 03:38:32 +02:00
Jonas Kvinge
5a7cbb2f3d CI: Add OpenMandriva Cooker, remove Lx 4.2 2023-06-24 00:56:53 +02:00
Jonas Kvinge
354b55cbbc Use QFileInfo::path instead of QUrl::RemoveFilename 2023-06-15 21:06:18 +02:00
Jonas Kvinge
b87a950357 CoverUtils: Only create path if it doesn't exist 2023-06-15 21:04:11 +02:00
Jonas Kvinge
950c236720 AlbumCoverManager: Fix clear and unset actions 2023-06-15 20:35:41 +02:00
Jonas Kvinge
32982be4f2 EditTagDialog: Allow clearing unset cover 2023-06-15 20:34:03 +02:00
Jonas Kvinge
f467331934 Add ifdefs around #pragma GCC diagnostic 2023-06-15 20:10:25 +02:00
Jonas Kvinge
ec839e6aae KDSingleApplicationLocalSocket: Ignore missing declaration 2023-06-15 19:48:00 +02:00
Jonas Kvinge
45f1521da6 Update Changelog 2023-06-14 23:10:56 +02:00
Jonas Kvinge
841a44a18e KDSingleApplicationLocalSocket: Remove extra semicolon 2023-06-14 23:10:50 +02:00
Dakes
1deacaecf9 FilterParser: Add ability to filter by rating
Playlists can now be filtered by the rating from 0-5 like:
rating:0 rating:<3 rating:!=0
or by a float value, like:
rating:f0.1 rating:>=f0.5
2023-06-09 21:31:15 +02:00
Jonas Kvinge
6af8e6c25b Update Changelog 2023-06-09 00:16:46 +02:00
Jonas Kvinge
b0849d21f3 TidalStreamURLRequest: Ignore different track ID 2023-06-08 17:36:24 +02:00
Jonas Kvinge
5b60ea8e77 MainWindow: Remove F2 from edit tag shortcut
Fixes #1210
2023-06-07 19:38:59 +02:00
Andrei Stepanov
ec3f95a260 Add Russian translation to desktop file 2023-06-07 17:41:17 +02:00
Jonas Kvinge
0bfd4d2e04 CI: Only run SSH key setup step for master branch 2023-06-07 16:57:27 +02:00
Jonas Kvinge
a6ba0cfc97 KDSingleApplicationLocalSocket: Exclude XDG_SESSION_ID from socket name 2023-06-07 01:23:01 +02:00
Jonas Kvinge
6d55eb5974 CollectionModel: Fix icon disk cache 2023-06-07 00:51:53 +02:00
Jonas Kvinge
972053c699 MoodbarLoader: Fix loading cached moodbars 2023-06-07 00:50:35 +02:00
Jonas Kvinge
9db7896828 Prefix class for ReloadSettings 2023-06-06 23:20:42 +02:00
Jonas Kvinge
be6f93735d Simplify if statements 2023-06-06 23:19:45 +02:00
Jonas Kvinge
3bcea249ac TagReaderTagLib: Initialize cover_format 2023-06-06 23:19:25 +02:00
Jonas Kvinge
8ee32dfa88 Add static_cast to silence narrowing conversion warnings 2023-06-06 23:18:49 +02:00
Jonas Kvinge
e2f9411b46 EditTagDialog: Initialize cover_action 2023-06-06 23:17:29 +02:00
Jonas Kvinge
0bd68c3817 KDSingleApplicationLocalSocket: Add static_cast to silence narrowing conversion warnings 2023-06-06 22:25:19 +02:00
Jonas Kvinge
f03505ab67 KDSingleApplicationLocalSocket: Remove useless std::move 2023-06-06 22:24:10 +02:00
Jonas Kvinge
f1ae795c0f KDSingleApplicationLocalSocket: Initialize socket 2023-06-06 22:23:54 +02:00
Jonas Kvinge
50fcda2763 OSDDBus: Remove use of QImage::isGrayscale, Always expect RGB
Fixes #1205
2023-06-06 21:43:05 +02:00
Jonas Kvinge
331aa382f9 Rewrite album cover loader 2023-06-06 20:41:01 +02:00
Jonas Kvinge
3c160c2f13 CI: Fix /etc/dnf/dnf.conf for Fedora 39 2023-06-06 00:09:48 +02:00
Jonas Kvinge
4fd617a32f nsi: Add libgcc_s_sjlj-1.dll and libwinpthread-1.dll for MSVC x86 2023-06-05 00:41:34 +02:00
Jonas Kvinge
0d294eb218 CI: Add /opt/local/bin to PATH for macports build 2023-06-05 00:35:11 +02:00
Jonas Kvinge
a49e3b90b0 CI: Use macOS 12 for FreeBSD vm 2023-06-03 19:19:57 +02:00
Jonas Kvinge
201392f22e CI: Use latest macports release 2023-06-03 19:11:18 +02:00
Jonas Kvinge
3fa4ee772f CI: Bump MACOSX_DEPLOYMENT_TARGET 2023-06-03 19:10:57 +02:00
Jonas Kvinge
529c83c572 CI: Bump macOS version 2023-06-03 15:50:53 +02:00
Jonas Kvinge
6a9e56e9d9 nsi: Add gstwinrt-1.0-0.dll 2023-06-01 21:37:18 +02:00
Jonas Kvinge
716e80fb84 UWPDeviceFinder: Fix EngineDeviceList 2023-06-01 21:35:48 +02:00
Jonas Kvinge
80067b806d TranscodeDialog: Append number to filename if it already exists
Fixes #1200
2023-06-01 20:42:47 +02:00
Jonas Kvinge
315073f9a7 Add EngineDevice class 2023-06-01 19:31:19 +02:00
Jonas Kvinge
a1dbbba1a1 ContextView: Remove engine and device 2023-06-01 19:29:52 +02:00
Jonas Kvinge
cb8a0b6853 ContextSettingsPage: Remove engine and device 2023-06-01 19:29:52 +02:00
Jonas Kvinge
a5a29f7ad3 DeviceFinder: Add typedef DeviceList 2023-06-01 18:43:43 +02:00
Jonas Kvinge
8e14ef7c0c GstStartup: Set rank for directsoundsink higher than wasapisink for MinGW
Fixes #1204
2023-06-01 18:31:55 +02:00
Jonas Kvinge
c270391772 Add WASAPI2 plugin
Fixes #1204
2023-06-01 18:16:51 +02:00
Jonas Kvinge
e466cb6e30 Add UWP device finder 2023-06-01 18:11:30 +02:00
Jonas Kvinge
f0df9dc0fb GstEngine: Append "2" to wasapi2sink description 2023-06-01 17:22:11 +02:00
Strawbs Bot
b31c08083a Update translations 2023-05-30 01:02:07 +02:00
Jonas Kvinge
145a8d5b67 Bump LSMinimumSystemVersion in Info.plist
Fixes #1206
2023-05-29 11:25:43 +02:00
Jonas Kvinge
60d7a4e7ee AlbumCoverManager: Fix invalid reference 2023-05-29 11:24:41 +02:00
Jonas Kvinge
b52ffd09b2 Use find_package Protobuf CONFIG 2023-05-14 23:54:36 +02:00
Jonas Kvinge
58278ab1e4 Replace protobuf_generate_cpp with protobuf_generate 2023-05-14 20:07:36 +02:00
Strawbs Bot
000cf5fd5a Update translations 2023-05-13 01:01:35 +02:00
Jonas Kvinge
216b58e392 CI: Upload *.xz to source path 2023-05-07 12:39:35 +02:00
Jonas Kvinge
279cce49ba CI: Fix MSVC tarball filename 2023-05-07 11:27:56 +02:00
Jonas Kvinge
8184b77b13 CI: Improve MSVC build 2023-05-07 05:25:47 +02:00
Jonas Kvinge
b8b731ab04 CI: Upload Ubuntu PPA 2023-05-07 04:28:56 +02:00
Jonas Kvinge
1d4c39d13d CI: Upload release 2023-05-07 02:24:39 +02:00
Jonas Kvinge
ac26f5b2ef Add git to debian/control 2023-05-07 02:24:24 +02:00
Jonas Kvinge
c07447d8f5 CI: Upload artifacts 2023-05-07 01:09:18 +02:00
Jonas Kvinge
833ddf5f4c CI: Use -S and -B for cmake command 2023-05-06 14:18:35 +02:00
Jonas Kvinge
4dc4f468bb CI: Add Mageia 2023-05-06 14:08:34 +02:00
Strawbs Bot
1aff69d3cf Update translations 2023-05-06 01:02:19 +02:00
Robert Marshall
f2f63a703e class CueParser Process composer metadata in cue files
Use composer as an alternative to songwriter

..and move a misplaced comment
2023-05-05 17:47:37 +02:00
Jonas Kvinge
97e6b17f96 ContextView: QFontDatabase::families is not static in Qt 5 2023-05-05 17:46:02 +02:00
Jonas Kvinge
b90d284b08 ContextView: Check for default font family 2023-05-05 16:43:34 +02:00
Jonas Kvinge
840a65c630 ContextSettingsPage: Use constant for default font family 2023-05-05 16:43:01 +02:00
Jonas Kvinge
e5c89d4881 KDSingleApplicationLocalSocket: Use namespace and constexpr 2023-05-05 16:42:12 +02:00
Jonas Kvinge
0fc6638294 KDSingleApplicationLocalSocket: Formatting 2023-05-05 16:41:50 +02:00
Strawbs Bot
7c7724e41c Update translations 2023-05-05 01:29:26 +02:00
Jonas Kvinge
31319711dd Remove fixed font size on macOS
Possible fix for #1184
2023-05-05 00:34:48 +02:00
Jonas Kvinge
8954729d55 KDSingleApplicationPrivate: Remove unused initialize declaration 2023-05-04 19:42:27 +02:00
Jonas Kvinge
ae4dc442b9 Update Changelog 2023-05-04 19:22:00 +02:00
Jonas Kvinge
919ff414e6 Replace SingleApplication with KDSingleApplication 2023-05-04 09:44:54 +02:00
Strawbs Bot
b861703dad Update translations 2023-05-04 01:15:19 +02:00
Jonas Kvinge
2f17647cd3 Use const reference for AlbumCoverLoaderResult 2023-05-03 21:43:22 +02:00
Jonas Kvinge
f8d2c7eba3 Bump required Qt version to 5.12 2023-05-03 20:50:58 +02:00
Jonas Kvinge
e511b2faf9 Use new connect syntax for QMetaObject::invokeMethod 2023-05-03 20:08:51 +02:00
Jonas Kvinge
301e6b194a Replace 0 msec singleshot with invoke method 2023-05-03 19:55:58 +02:00
Jonas Kvinge
1208ca3ad4 ContextView: Simplify font code 2023-05-03 01:59:13 +02:00
Jonas Kvinge
84e7cd0df8 CollectionWatcher: Connect PathChanged signal once 2023-05-03 01:17:10 +02:00
Strawbs Bot
7e1077426e Update translations 2023-05-02 01:01:40 +02:00
Jonas Kvinge
1e2c437a08 CMakeLists: Remove hardcoded sqlite3 link with MSVC 2023-05-01 19:20:00 +02:00
Jonas Kvinge
a7ce1d1225 CI: Strip gdb.exe 2023-05-01 17:26:12 +02:00
Jonas Kvinge
1d3223e9c6 Add getopt supporting unicode
Fixes #1191
2023-05-01 16:44:18 +02:00
Jonas Kvinge
b01f3f4bb5 CI: Build on macOS with macports 2023-04-29 21:11:05 +02:00
Strawbs Bot
ee4cd11ae1 Update translations 2023-04-29 01:01:40 +02:00
Jonas Kvinge
154f8b307e CI: Add openSUSE Leap 15.5 2023-04-28 21:28:24 +02:00
Jonas Kvinge
7aac7872e3 CI: Disable D-Bus on macOS
Fixes #1163
2023-04-28 16:59:28 +02:00
Jonas Kvinge
b2630032e7 CI: Remove CodeQL 2023-04-27 21:39:25 +02:00
Jonas Kvinge
80136b602b CI: Check that all files are included in nsi 2023-04-26 19:04:59 +02:00
Strawbs Bot
3df29ed2a9 Update translations 2023-04-25 01:01:22 +02:00
Jonas Kvinge
69658f2022 AlbumCoverChoiceController: Check for nullptr in SearchForCover 2023-04-23 19:27:01 +02:00
Jonas Kvinge
5fd0a0831f GstEngine: Include all outputs that starts with "Sink/Audio" 2023-04-23 01:28:52 +02:00
Strawbs Bot
43b299ebd1 Update translations 2023-04-23 01:21:40 +02:00
Jonas Kvinge
9612304023 GstEngine: Use _stricmp with MSVC 2023-04-23 01:20:11 +02:00
Jonas Kvinge
3154e59b36 EngineBase: Remove extra semicolon 2023-04-22 20:41:22 +02:00
Jonas Kvinge
2d5a496678 Update debian/copyright 2023-04-22 19:48:51 +02:00
Jonas Kvinge
4c1c322b54 Rename AnalyzerBase 2023-04-22 19:45:21 +02:00
Jonas Kvinge
e9f3281694 Rename EngineBase 2023-04-22 19:13:42 +02:00
Jonas Kvinge
c3534affdb EngineBase: Remove PluginDetails 2023-04-22 17:18:29 +02:00
Jonas Kvinge
c6e62b3263 GstStartup: Remove setting rank for wasapisink and directsoundsink 2023-04-22 17:15:41 +02:00
Jonas Kvinge
d8ce177ce7 GstEngine: Remove class comment 2023-04-22 17:14:49 +02:00
Jonas Kvinge
726bfbefb0 Replace gst_element_factory_get_klass with gst_element_factory_get_metadata 2023-04-22 16:49:37 +02:00
Jonas Kvinge
5c4a6487c0 Update Changelog 2023-04-22 15:27:46 +02:00
Jonas Kvinge
3145433099 SystemTrayIcon: Simply icon loading 2023-04-22 15:27:34 +02:00
Jonas Kvinge
bdf6844b74 Database: Move error_reported 2023-04-22 14:38:45 +02:00
Jonas Kvinge
9ad430915c CddaDevice: Remove application.h include 2023-04-22 14:31:25 +02:00
Jonas Kvinge
60bbd71a22 Remove NetworkAccessManager from song loader 2023-04-22 14:05:48 +02:00
Jonas Kvinge
c96498758f Fix and improve gapless playback
If "about-to-finish" was emitted before the preload time was reached, we never set the next uri, so gapless playback was broken.
Make sure to always set the next uri, and increase preload gap from 5 to 8 seconds.
2023-04-22 03:54:11 +02:00
Strawbs Bot
f4600bd8eb Update translations 2023-04-22 01:21:46 +02:00
Jonas Kvinge
7202a5734c ListenBrainzScrobbler: Only send duration_ms when valid 2023-04-21 20:54:18 +02:00
Jonas Kvinge
8edb6eaa81 Song: Add missing const 2023-04-21 20:48:30 +02:00
Jonas Kvinge
b8eecc05fd AlbumCoverLoader: Use own NetworkAccessManager instance
Since AlbumCoverLoader runs in it's own thread.
2023-04-21 20:29:43 +02:00
Jonas Kvinge
7fc5aef553 Use one instance of NetworkAccessManager 2023-04-21 20:20:53 +02:00
Jonas Kvinge
bee6b7f946 Rename original_url to media_url 2023-04-21 16:20:00 +02:00
Jonas Kvinge
3bedfb6ac8 GstEngine: Formatting 2023-04-21 15:07:17 +02:00
Jonas Kvinge
f49bf0192b Engine::Base: Formatting 2023-04-21 15:06:44 +02:00
Jonas Kvinge
f36ac5272b Scrobbler: Simplify error handling 2023-04-21 02:11:26 +02:00
Strawbs Bot
f0fe446f7f Update translations 2023-04-21 01:01:44 +02:00
Jonas Kvinge
d9c4720a3e ListenBrainzScrobbler: Split artist mbids by slash 2023-04-20 21:55:11 +02:00
monochromec
4de5d8f2a3 Fixed typo and improved wording of Rosetta notice 2023-04-20 16:29:48 +02:00
Strawbs Bot
8651311016 Update translations 2023-04-19 01:08:38 +02:00
Jonas Kvinge
1d27c5a14c MainWindow: Add missing QSettings declaration 2023-04-18 20:17:01 +02:00
Jonas Kvinge
b0b8ff2d49 CollectionModel: URL percent encode disk cache keys
Fixes #1183
2023-04-18 18:42:37 +02:00
Jonas Kvinge
cd03e1fc74 Make it possible to not show Rosetta warning
Fixes #1180
2023-04-18 18:03:39 +02:00
Jonas Kvinge
b273a449e3 Add common message dialog 2023-04-18 17:44:42 +02:00
Jonas Kvinge
b637867f9e MainWindow: Hide checkbox, set size, center rosetta warning 2023-04-18 16:54:43 +02:00
Jonas Kvinge
41d5792b27 Add screen utilities for screen and center widget on screen 2023-04-18 16:54:35 +02:00
Jonas Kvinge
d22712a25b nsi: Update ICU to 73 2023-04-15 17:50:57 +02:00
Jonas Kvinge
33968ee5da CI: Fix macOS build 2023-04-15 17:50:31 +02:00
Strawbs Bot
9baf1774e0 Update translations 2023-04-15 01:01:23 +02:00
Strawbs Bot
9ca66e4061 Update translations 2023-04-12 01:01:23 +02:00
Jonas Kvinge
db2d34f840 FavoriteWidget: Use icon loader for star icons
Fixes #1178
2023-04-10 21:29:52 +02:00
Strawbs Bot
195cc61df7 Update translations 2023-04-10 01:22:37 +02:00
Jonas Kvinge
aaa530e72b Add const/references to all signal parameters 2023-04-09 20:23:42 +02:00
Jonas Kvinge
fa856ee905 Remove directory.h 2023-04-09 20:17:45 +02:00
Strawbs Bot
2bf7a5c4d3 Update translations 2023-04-08 01:27:44 +02:00
Jonas Kvinge
780b982635 SmartPlaylistSearchTermWidget: Fix loading search terms
Fixes #1172
2023-04-07 23:05:07 +02:00
Jonas Kvinge
74bbc1f19f PlaylistGenerator: Use std::make_shared 2023-04-07 22:41:10 +02:00
Jonas Kvinge
e314545f2e Database: Fix SQL query error message 2023-04-07 20:54:31 +02:00
Jonas Kvinge
f1a3a12c1c CollectionBackend: Fix SQL query error message 2023-04-07 20:54:15 +02:00
Jonas Kvinge
ef080c3cb1 PlaylistView: Fix resetting album cover 2023-04-07 20:07:40 +02:00
Jonas Kvinge
7313db5ac0 Add compile test for QX11Application
if Qt was compiled without XCB, globalshortcut-x11 failed to compile.
2023-04-07 15:57:39 +02:00
Jonas Kvinge
bf9aa524ed CI: Fix macOS build 2023-04-07 02:31:59 +02:00
Jonas Kvinge
b59aa0827e GstEnginePipeline: Always set initial volume 2023-04-07 02:30:41 +02:00
Strawbs Bot
2584f1293e Update translations 2023-04-07 01:13:27 +02:00
Jonas Kvinge
de9d28adea CI: Add Fedora 39 2023-04-06 23:37:23 +02:00
Jonas Kvinge
b660287779 Use std::shared_ptrfor AlbumCoverLoaderResult
Reduces memory fragmentation with Qt 6
2023-04-06 23:18:10 +02:00
Jonas Kvinge
962536bc83 AlbumCoverLoaderResult: Use enum class for type 2023-04-06 01:23:42 +02:00
Strawbs Bot
ee4fcf8100 Update translations 2023-04-04 01:01:21 +02:00
Strawbs Bot
9a4ed1a19d Update translations 2023-03-31 21:56:09 +02:00
Gaganpreet Arora
c1d0702b4d QobuzRequest: Handle multiple discs in integration
Albums with multiple discs are not being handled which results in tracks
being listed out of order. If the disc (media_number) is present in
JSON, we use it to set the disc in the Song object.
2023-03-31 21:21:58 +02:00
Jonas Kvinge
af1c46543b Turn on git revision 2023-03-30 17:50:03 +02:00
Jonas Kvinge
e2f5486987 Release 1.0.17 2023-03-29 18:54:51 +02:00
Jonas Kvinge
b0d390aaf1 Update Changelog 2023-03-29 18:49:35 +02:00
Jonas Kvinge
bae1b42394 OSDPretty: Respect device pixel ratio 2023-03-29 18:23:06 +02:00
Jonas Kvinge
a2533edd57 PlayingWidget: Make previous pixmap respect device pixel ratio 2023-03-29 00:24:38 +02:00
Jonas Kvinge
7b88c198fe SongSourceDelegate: Fix compile with Qt 5 2023-03-29 00:14:21 +02:00
Jonas Kvinge
c49cb0c119 ImageUtils: Formatting 2023-03-29 00:09:40 +02:00
Jonas Kvinge
03aabeb848 AlbumCoverManager: Respect device pixel ratio 2023-03-29 00:06:56 +02:00
Jonas Kvinge
1d3a837f7a SongSourceDelegate: Respect device pixel ratio 2023-03-29 00:04:34 +02:00
Jonas Kvinge
92adc18b8f ContextAlbum: Make size hint respect device pixel ratio 2023-03-28 18:21:19 +02:00
Fletcher Dostie
e4697c8ff1 Render context art at correct size 2023-03-28 17:54:56 +02:00
Jonas Kvinge
b741f1a580 Turn on git revision 2023-03-28 01:48:09 +02:00
Jonas Kvinge
8ee6de4162 Release 1.0.16 2023-03-27 22:28:02 +02:00
Jonas Kvinge
2b9e7db924 TagReaderTagLib: Touch file over saving cover art 2023-03-26 22:37:21 +02:00
Jonas Kvinge
49384ce294 TagReaderTagLib: Fix reading MusicBrainz from ID3v2 tags 2023-03-26 04:33:15 +02:00
Jonas Kvinge
ac59fff346 TagReaderTagLib: Formatting 2023-03-26 04:14:03 +02:00
Jonas Kvinge
a3e9f152d8 CollectionSettingsPage: Remove iopriority hide 2023-03-26 03:14:52 +02:00
Jonas Kvinge
ffe6a81b9a Collection: Always use Idle priority for watcher 2023-03-26 00:10:29 +01:00
Jonas Kvinge
9bb051b4eb CollectionSettingsPage: Remove settings for IO and thread priority and workers 2023-03-26 00:09:41 +01:00
Jonas Kvinge
c1465a890f TagReaderClient: Always use 1 tagreader worker 2023-03-26 00:08:55 +01:00
Jonas Kvinge
c3ee3318d7 WorkerPool: Default to 1 worker 2023-03-26 00:08:23 +01:00
Jonas Kvinge
272976f0b7 TagReaderClient: Fix default save options 2023-03-25 23:54:15 +01:00
Jonas Kvinge
4724b170b1 AuddLyricsProvider: Disable provider by default
Since we are currently missing API key.
2023-03-25 19:20:10 +01:00
Jonas Kvinge
337bd4bcef ListenBrainzScrobbler: Make sure we only add the same artist id once 2023-03-25 19:14:26 +01:00
Jonas Kvinge
0604c78453 CollectionBackend: Check for changed fingerprint 2023-03-25 18:35:14 +01:00
Jonas Kvinge
c8169adf7c CollectionModel: Guard against invalid disc and year 2023-03-25 18:32:41 +01:00
Jonas Kvinge
7b610d131c CollectionModel: Replace qMax with std::max 2023-03-25 18:31:21 +01:00
Jonas Kvinge
18da55453f EditTagDialog: Not set for track, disc, year, etc to -1 2023-03-25 18:29:12 +01:00
Jonas Kvinge
2aeab8b672 CollectionModel: Remove unused QByteArray include 2023-03-25 18:26:53 +01:00
Jonas Kvinge
9c21707a55 Update Changelog 2023-03-25 16:49:19 +01:00
Jonas Kvinge
b02ac833ad CollectionWatcher: Fix rescan songs feature 2023-03-25 16:38:03 +01:00
Jonas Kvinge
4de912cf41 Song: Fix missing colon in SQL bind value 2023-03-25 16:34:26 +01:00
Jonas Kvinge
ed260c6e20 CollectionWatcher: Check for changed AcoustID and MusicBrainz 2023-03-25 14:35:12 +01:00
Jonas Kvinge
fab38f693d Scrobbler: Refactor and add MusicBrainz integration 2023-03-25 14:25:21 +01:00
Jonas Kvinge
aedbd52e9d Add AcoustID 2023-03-24 22:48:22 +01:00
Jonas Kvinge
4cbcb9d99c Update list of lyrics providers in README.md and dist files 2023-03-24 21:23:10 +01:00
Jonas Kvinge
e967d15b4e Add AudD lyrics provider 2023-03-24 21:16:11 +01:00
Fletcher Dostie
bb43cc63ec Fix album art rendering on High DPI displays 2023-03-24 21:02:55 +01:00
Jonas Kvinge
ca176c319d Add Acoustid and MusicBrainz tags to database schema 2023-03-24 21:00:58 +01:00
Jonas Kvinge
17c960ecd4 Song: Add Acoustid fingerprint and MusicBrainz tags 2023-03-24 20:57:46 +01:00
Jonas Kvinge
b766ae3498 Song: Use static_cast from int to Source 2023-03-24 20:54:42 +01:00
Jonas Kvinge
faf4c817cd TagReaderTagLib: Read AcoustID fingerprint 2023-03-24 20:54:05 +01:00
Jonas Kvinge
b4e1f283c9 tagreadermessages: Add AcoustID fingerprint tags to protobuf 2023-03-24 19:52:45 +01:00
Jonas Kvinge
52c83d592c Rename Stands4 to Lyrics.com 2023-03-22 23:36:15 +01:00
Jonas Kvinge
c8caea0d30 GstEnginePipeline: Use constexpr 2023-03-22 23:29:56 +01:00
Jonas Kvinge
7a6c54d8e7 GstEnginePipeline: Remove hard-coded num-bands 2023-03-22 23:29:24 +01:00
Strawbs Bot
7082e52a4f Update translations 2023-03-21 01:01:49 +01:00
Strawbs Bot
6cdca617e0 Update translations 2023-03-20 01:14:38 +01:00
Jonas Kvinge
a1adc1a75a Add option for strict SSL mode in backend settings 2023-03-19 23:02:17 +01:00
Jonas Kvinge
b16bec704a GstEnginePipeline: Use "source-setup" instead of "notify::source" signal
This works with both playbin 2 and 3.

Possible fix for #1148
2023-03-19 22:28:12 +01:00
Jonas Kvinge
664a8c79a1 GstEnginePipeline: Check for ssl-strict property 2023-03-19 22:13:16 +01:00
Jonas Kvinge
bbf3d8e1a4 Update Changelog 2023-03-19 22:03:55 +01:00
Jonas Kvinge
a35146440c TagReaderTagLib: Read MusicBrainz tags 2023-03-19 21:55:26 +01:00
Jonas Kvinge
8e79fafca9 tagreadermessages: Add MusicBrainz tags to protobuf 2023-03-19 21:50:54 +01:00
Jonas Kvinge
6f8780d3cc TagReaderGME: Add header guard comment 2023-03-19 21:29:45 +01:00
Jonas Kvinge
264065a355 TagreaderGME: Don't call QByteArray::operator[]() on temporary 2023-03-19 20:42:30 +01:00
Jonas Kvinge
b606e4cd1a TagReaderTagLib: Rename Decode to TStringToStdString 2023-03-19 20:35:47 +01:00
Jonas Kvinge
01d0eeaed0 FileViewList: Add reserve 2023-03-19 20:32:06 +01:00
Jonas Kvinge
8c4e24e65d filemanagerutils: Add namespace comment 2023-03-19 20:31:46 +01:00
Jonas Kvinge
19c9f9698d QobuzService: Make DecodeAppSecret const 2023-03-19 20:31:31 +01:00
Jonas Kvinge
ae87c1b578 Stands4LyricsProvider: Remove unused variable 2023-03-19 20:24:07 +01:00
Jonas Kvinge
c42b1f5548 GstEnginePipeline: Cast guint to int 2023-03-19 19:38:36 +01:00
Jonas Kvinge
87ffbb0a85 Equalizer: Remove redundant QString cast 2023-03-19 19:38:12 +01:00
Jonas Kvinge
702851a958 TagReaderTagLib: Use constexpr 2023-03-19 19:34:05 +01:00
Jonas Kvinge
650f200a0b TagReaderBase: Remove unused Decode function 2023-03-19 19:33:34 +01:00
Jonas Kvinge
14d215bdf3 ContextView: Add static_cast for font size 2023-03-19 19:32:41 +01:00
Jonas Kvinge
12aebc2fe9 Sonogram: Remove unused destructor 2023-03-19 19:32:23 +01:00
Jonas Kvinge
f41b051ec7 LyricsSearchResult: Add missing const reference 2023-03-19 19:31:43 +01:00
Jonas Kvinge
25144eee89 Add CONTRIBUTING.md 2023-03-19 16:07:12 +01:00
Jonas Kvinge
0c62147536 SongLoader: Remove probe and bus watch 2023-03-19 05:08:35 +01:00
Jonas Kvinge
7b282e21de Fix compile with GStreamer disabled 2023-03-19 05:08:35 +01:00
Strawbs Bot
c1fbe6d84c Update translations 2023-03-19 01:20:59 +01:00
Jonas Kvinge
e20cbe4170 Save embedded cover in the same process as tags
Possible fix for #1158
2023-03-18 20:03:07 +01:00
Jonas Kvinge
394955a03f Replace QList<QByteArray> with QByteArrayList 2023-03-18 19:41:36 +01:00
Jonas Kvinge
16b4f5d065 DeviceDatabaseBackend: Remove use of QSqlDatabase::exec() 2023-03-18 02:20:03 +01:00
Jonas Kvinge
c95295d8b4 Console: Remove use of QSqlDatabase::exec() 2023-03-18 01:49:03 +01:00
Strawbs Bot
658dce2607 Update translations 2023-03-18 01:01:44 +01:00
Jonas Kvinge
01f8d0a27e SavedGroupingManager: Add missing collectionsettingspage include 2023-03-18 01:01:28 +01:00
Jonas Kvinge
39e1bfc84f CollectionBackend: Add default for ResetStatistics save_tags to false 2023-03-18 01:00:28 +01:00
Jonas Kvinge
e394416fa7 CollectionFilterWidget: Add missing collectionsettingspage include 2023-03-18 00:59:39 +01:00
Strawbs Bot
f1108bc0e2 Update translations 2023-03-15 01:01:28 +01:00
Jonas Kvinge
ff31815d49 SmartPlaylistSearchTerm: Revert if / else 2023-03-11 18:16:48 +01:00
Jonas Kvinge
604aa63b47 SmartPlaylists: Rename variable collection to collection_backend 2023-03-11 17:18:35 +01:00
Jonas Kvinge
ec4d036f50 SmartPlaylistsModel: Add missing endArray 2023-03-11 17:17:23 +01:00
Jonas Kvinge
1bf1c4ac63 nsi: Simplify macro code 2023-03-09 16:14:32 +01:00
Jonas Kvinge
981d46fbd4 Link abseil_dll for MSVC 2023-03-09 16:14:32 +01:00
Jonas Kvinge
eb6a353c31 nsi: Add libabsl 2023-03-09 16:14:32 +01:00
Strawbs Bot
ff673b1941 Update translations 2023-03-09 01:01:45 +01:00
Jonas Kvinge
8b55cf8a3a Check for policy 2023-03-08 19:01:18 +01:00
Jonas Kvinge
d8682b4403 Workaround absl linking errors on Windows with protobuf 3.22 2023-03-08 18:57:52 +01:00
Jonas Kvinge
40a4bf195a Link with Protobuf_LIBRARIES 2023-03-08 18:56:15 +01:00
Jonas Kvinge
312c5cbc3f macosutils: Formatting 2023-03-08 01:03:57 +01:00
Strawbs Bot
f314c56ef0 Update translations 2023-03-08 01:02:01 +01:00
Jonas Kvinge
ea8e5180ff Detect if running under Rosetta 2023-03-07 23:04:00 +01:00
Jonas Kvinge
7f76c3f2ce CI: Add Ubuntu Lunar 2023-03-07 20:53:49 +01:00
Jonas Kvinge
e4c5e99d0f MainWindow: Add macOS warning if running on different CPU 2023-03-07 20:14:37 +01:00
Jonas Kvinge
80cfca5de2 CI: Set HOMEBREW_NO_INSTALL_FROM_API for macOS 2023-03-07 01:15:38 +01:00
Strawbs Bot
9556a14de9 Update translations 2023-03-07 01:02:32 +01:00
Jonas Kvinge
2025fc8325 Update list of lyrics providers in README.md and dist files 2023-03-06 21:50:42 +01:00
Jonas Kvinge
2dd0f6a9ba Remove AudD lyrics provider 2023-03-06 21:46:00 +01:00
Jonas Kvinge
a42039d6e5 Lyrics: Match both album artist and artist in lyrics results 2023-03-06 21:42:59 +01:00
Jonas Kvinge
7fafa8adfb QtFSListener: Log watcher errors 2023-03-05 01:23:28 +01:00
Jonas Kvinge
f789657552 SingleApplication: Add boost include dirs 2023-03-05 01:04:57 +01:00
Jonas Kvinge
3e183bc10e SingleApplication: Change lambda capture order 2023-03-05 00:10:34 +01:00
Jonas Kvinge
16e5d93be3 SingleApplication: Add memory include 2023-03-05 00:08:45 +01:00
Jonas Kvinge
6515e06a13 SingleApplication: Refactor startup code 2023-03-04 23:47:36 +01:00
Jonas Kvinge
9ae0b32318 nsi: Update ffmpeg dlls for MinGW 2023-03-04 23:43:40 +01:00
Jonas Kvinge
4cb3bc4185 SingleApplication: Share code between SingleApplication and SingleCoreApplication 2023-03-04 20:48:21 +01:00
Jonas Kvinge
f9ca24598e Turn on git revision 2023-03-04 16:13:45 +01:00
Jonas Kvinge
3ccc892d6a Release 1.0.15 2023-03-04 15:46:51 +01:00
Jonas Kvinge
d7cacea843 Update Changelog 2023-03-04 15:45:33 +01:00
Strawbs Bot
e30233ac74 Update translations 2023-03-03 01:01:55 +01:00
Jonas Kvinge
7c57631fcf SingleApplication: Only include QNativeIpcKey with Qt 6.6 and higher 2023-03-02 23:03:33 +01:00
Jonas Kvinge
0adc084dad SingleApplication: Use new QSharedMemory constructor with Qt 6.6 and higher 2023-03-02 22:57:33 +01:00
Jonas Kvinge
e22199817c SingleApplicationPrivate: Move variable 2023-03-02 22:56:41 +01:00
Jonas Kvinge
78f691d006 SingleApplication: Remove semicolon 2023-03-02 22:56:17 +01:00
Jonas Kvinge
749bae1f16 SingleApplication: Use enum class for Mode 2023-03-02 22:55:50 +01:00
Jonas Kvinge
1043e24322 SingleApplication: Remove exit 2023-03-02 22:55:21 +01:00
Jonas Kvinge
a6d10b1fa7 GstEnginePipeline: Check that audio bin exists before unref 2023-02-27 18:50:09 +01:00
Jonas Kvinge
a3159423f8 nsi: Update libiconv for MSVC 2023-02-24 22:09:35 +01:00
Jonas Kvinge
ecb5ca321b CI: Use Windows 2022 and msvc toolset 14.3 2023-02-24 22:03:30 +01:00
Jonas Kvinge
fd827fdfd8 Add CodeQL 2023-02-22 18:53:21 +01:00
Jonas Kvinge
92d77b14d5 CI: Minor cleanup 2023-02-21 18:43:01 +01:00
dependabot[bot]
be67d89d8b Bump vmactions/freebsd-vm from 0.2.9 to 0.3.0
Bumps [vmactions/freebsd-vm](https://github.com/vmactions/freebsd-vm) from 0.2.9 to 0.3.0.
- [Release notes](https://github.com/vmactions/freebsd-vm/releases)
- [Commits](https://github.com/vmactions/freebsd-vm/compare/v0.2.9...v0.3.0)

---
updated-dependencies:
- dependency-name: vmactions/freebsd-vm
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2023-02-21 01:59:45 +00:00
Jonas Kvinge
ddd1ce732a dependabot formatting 2023-02-20 20:32:04 +01:00
Jonas Kvinge
012d82183c Add dependabot 2023-02-20 20:28:41 +01:00
Jonas Kvinge
f9c98ebcb3 CI: Use build_type specific container image for mingw 2023-02-20 18:47:28 +01:00
Jonas Kvinge
10fe861dde nsi: Move protobuf to common files 2023-02-19 11:01:28 +01:00
Strawbs Bot
16c027ecab Update translations 2023-02-19 01:21:50 +01:00
Jonas Kvinge
cc578e7cc5 Sonogram: Remove unused parameter variable 2023-02-18 18:44:14 +01:00
Jonas Kvinge
6972d3c4f9 Sonogram: Change int to size_t 2023-02-18 17:52:01 +01:00
Jonas Kvinge
46b164f2fb nsi: Update protobuf dll 2023-02-18 17:30:38 +01:00
Jonas Kvinge
5431307527 CollectionFilterOptions: Match album artist too 2023-02-18 17:05:41 +01:00
Jonas Kvinge
79bf194ed6 CollectionModel: Fix compilation requirement query
Fixes #1140
2023-02-18 16:40:12 +01:00
Jonas Kvinge
506e670aa7 CI: Fix macOS build 2023-02-18 15:21:59 +01:00
Jonas Kvinge
fdfe164dd1 SmartPlaylistsModel: Save smart playlist type as int 2023-02-18 14:34:02 +01:00
Jonas Kvinge
af37056179 Change TrackChangeType to enum 2023-02-18 14:33:43 +01:00
Jonas Kvinge
b0fc7187cf PlaylistSettingsPage: Add Q_DECLARE_METATYPE for PathType 2023-02-18 14:33:19 +01:00
Jonas Kvinge
33ad1a7a86 Song: Add Q_DECLARE_METATYPE for Source and FileType 2023-02-18 14:33:01 +01:00
Jonas Kvinge
dd72fb4ca5 Use C++11 enum class 2023-02-18 14:09:30 +01:00
Jonas Kvinge
e6c5f76872 FancyTabWidget: Remove extra namespace 2023-02-18 14:09:30 +01:00
Jonas Kvinge
14aa22d590 Stands4LyricsProvider: Use direct URL if API usage limit exceeds 2023-02-18 14:09:30 +01:00
Strawbs Bot
5ed4293641 Update translations 2023-02-12 01:02:28 +01:00
Jonas Kvinge
f9fefcda57 Update Changelog 2023-02-11 01:49:10 +01:00
Jonas Kvinge
99b40293db Stands4LyricsProvider: Use percent encoding 2023-02-11 01:39:14 +01:00
Jonas Kvinge
9b06e85f94 Stands4LyricsProvider: Use API for search 2023-02-11 01:33:33 +01:00
Jonas Kvinge
93d1d40ea5 LyricsProvider: Default to empty results 2023-02-11 01:33:33 +01:00
Strawbs Bot
98597c047a Update translations 2023-02-11 01:19:51 +01:00
Jonas Kvinge
a5c1f4b0ee EditTagDialog: Fix saving play statistics
Fixes #1124
2023-02-10 22:51:48 +01:00
Jonas Kvinge
3d4c98d981 Playlist: Fix tag inline editing for steams
Fixes #1130
2023-02-10 22:49:57 +01:00
Jonas Kvinge
384e7dedb5 PlaylistView: Move ifdef 2023-02-10 22:47:55 +01:00
Jonas Kvinge
7df4453560 OrganizeFormat: Use suffix instead of complete suffix
Fixes #1136
2023-02-10 22:47:11 +01:00
Jonas Kvinge
d406a1c341 GstEnginePipeline: Use playbin3 with GStreamer 1.22.0 and higher 2023-02-10 22:43:55 +01:00
Jonas Kvinge
6671d97b4a GstEnginePipeline: Free audio bin in destructor
When the audio bin failed to initialize, we tried to disconnect signals and probes after the audio bin was already freed.
Instead, free the audio bin in the destructor after disconnecting signals and probes.

Fixes #1133 and #1123
2023-02-10 22:42:37 +01:00
Strawbs Bot
d02de72830 Update translations 2023-02-06 01:01:22 +01:00
Strawbs Bot
08f5172028 Update translations 2023-01-23 01:01:39 +01:00
4fury-c3440d8
04f062547d TagReaderTagParser: Fix timeconstants.h include 2023-01-22 13:22:02 +01:00
Jonas Kvinge
4717d783dc Stands4LyricsProvider: Finish search when no lyrics are found 2023-01-21 15:55:47 +01:00
Strawbs Bot
93af064b36 Update translations 2023-01-21 01:02:43 +01:00
Jonas Kvinge
c78d73d727 LastPlayedItemDelegate: Show blank for zero or invalid time 2023-01-20 23:45:33 +01:00
Jonas Kvinge
b69b3228be DateItemDelegate: Show blank for zero or invalid time 2023-01-20 23:45:19 +01:00
Jonas Kvinge
377f54700d TidalRequest: Make cover optional 2023-01-20 23:35:47 +01:00
Jonas Kvinge
d276339c80 Add lyrics from stands4 (lyrics.com) 2023-01-20 22:48:52 +01:00
Jonas Kvinge
b982a6a762 LyricsProvider: Improve parsing from HTML function 2023-01-20 22:45:05 +01:00
Jonas Kvinge
536fe637aa About: Remove e-mail addresses 2023-01-20 19:32:49 +01:00
Strawbs Bot
69f36eaa25 Update translations 2023-01-15 01:01:48 +01:00
Strawbs Bot
d6927a70bb Update translations 2023-01-14 01:01:51 +01:00
Jonas Kvinge
1b1892a187 Sonogram: Fix parameter mismatch in header 2023-01-13 23:46:38 +01:00
Sungrak Choi
5bea71cd5c Add Sonogram analyzer
Co-Authored-By: Jonas Kvinge <jonas@jkvinge.net>
2023-01-13 23:41:43 +01:00
Jonas Kvinge
bb8d4e70ae Turn on git revision 2023-01-13 22:53:39 +01:00
Jonas Kvinge
8d8c7e8b7b Release 1.0.14 2023-01-13 22:21:54 +01:00
Jonas Kvinge
9ff1f4d7b4 Update Changelog 2023-01-13 22:15:07 +01:00
Strawbs Bot
3a60dfe025 Update translations 2023-01-13 01:01:53 +01:00
Jonas Kvinge
d358854e16 Transcoder: Use static cast 2023-01-12 23:37:12 +01:00
Jonas Kvinge
129587e94a TranscoderOptionsMP3: Change default settings 2023-01-12 23:36:34 +01:00
Jonas Kvinge
0f575f4639 main: Remove explicitly enabling debug messages
Fixes #1106
2023-01-11 22:08:58 +01:00
Jonas Kvinge
7aac741571 GstEnginePipeline: Fix setting initial volume
Fixes #1104
2023-01-11 18:52:14 +01:00
Jonas Kvinge
b8a9da8a4e GstEngine: Use QUrl::isLocalFile 2023-01-10 18:26:42 +01:00
Jonas Kvinge
be6b974334 MoodbarPipeline: Fix saving moodbar if the URL contains host
Fixes #1101
2023-01-10 18:18:49 +01:00
knuxify
194e81205b CollectionBackendTest: Fix compile 2023-01-10 17:38:30 +01:00
Jonas Kvinge
d711dcc99d Turn on git revision 2023-01-10 00:46:49 +01:00
Jonas Kvinge
3b72a12540 Release 1.0.13 2023-01-09 22:46:59 +01:00
Strawbs Bot
38a1b7765a Update translations 2023-01-09 01:09:50 +01:00
Jonas Kvinge
02f2b8b6f0 CueParser: Detect encoding 2023-01-08 23:40:56 +01:00
Jonas Kvinge
7bfa75102c Remove QRegularExpressionMatch include 2023-01-08 23:24:25 +01:00
Jonas Kvinge
b0f3e7351c Update Changelog 2023-01-08 18:36:32 +01:00
Jonas Kvinge
b5fa401db9 Collection: Make sure RunQuery does not access collection items
- Rename `QueryOptions` to `CollectionFilterOptions`.
- Create new class `CollectionQueryOptions` for passing options from model to `CollectionQuery`.
- Rename `Directory` to `CollectionDirectory`.

Fixes #1095
2023-01-08 18:16:16 +01:00
Jonas Kvinge
41f2710dea GstEnginePipeline: Use linear volume 2023-01-08 15:25:24 +01:00
Jonas Kvinge
f19dda57f0 gstfastspectrum: Use static_cast 2023-01-08 06:21:34 +01:00
Jonas Kvinge
cc4a99ad80 CollectionModel: Close database with same mutex 2023-01-07 23:57:23 +01:00
Jonas Kvinge
1c1a3fc417 ResizableTextEdit: Don't delete setText 2023-01-07 23:38:59 +01:00
Jonas Kvinge
e97be5850b CollectionModel: Change while to for loop 2023-01-07 23:26:36 +01:00
Jonas Kvinge
2c302654b7 CollectionBackendInterface: Initialize filetype 2023-01-07 23:19:37 +01:00
Jonas Kvinge
3ee4dc77b2 Update Changelog 2023-01-06 23:14:28 +01:00
Jonas Kvinge
db55f314c9 Settings: Require tab icons to be minimum 32 2023-01-04 21:24:57 +01:00
Jonas Kvinge
0b536b287f MainWindow: Require tab icons to be minimum 32
Fixes #1084
2023-01-04 21:24:39 +01:00
Jonas Kvinge
6f298a9917 Use system icons for tabbar
Fixes #1093
2023-01-04 17:53:28 +01:00
Jonas Kvinge
70f829a2e5 PlaylistParser: Fix saving relative playlists to new files
Fixes #1092
2023-01-04 17:40:54 +01:00
Jonas Kvinge
1dfe07003f GstEnginePipeline: Set and notify volume only when changed
Another fix for #1089
2023-01-03 21:32:20 +01:00
Jonas Kvinge
286b908062 SliderSlider: Rename `value to new_value` 2023-01-03 19:53:53 +01:00
Jonas Kvinge
4ec028e736 GstEnginePipeline: Change callback ID's to long 2023-01-03 19:51:23 +01:00
Strawbs Bot
35a6d1437a Update translations 2023-01-03 01:01:50 +01:00
Jonas Kvinge
7e3cb3de89 OrganizeFormat: Parse the file path as a single block to avoid splitting brackets
Fixes #1091
2023-01-02 22:23:49 +01:00
Jonas Kvinge
bd945039f1 Turn on git revision 2023-01-02 22:10:13 +01:00
Jonas Kvinge
46743c8f15 Release 1.0.12 2023-01-02 18:56:51 +01:00
Jonas Kvinge
9b75284447 Update Changelog 2023-01-02 18:56:51 +01:00
Strawbs Bot
dca3b0052a Update translations 2023-01-02 01:02:18 +01:00
Jonas Kvinge
6d05bb2de5 GstEnginePipeline: Remove upstream events and buffer probes
Also rename some variables and callback functions

Possible fix for #1090
2023-01-02 00:06:18 +01:00
Jonas Kvinge
8b2e8d3804 OSDPretty: Change pensize back to 2
Removes workaround from commit 91eee99bab
2023-01-01 22:51:49 +01:00
Jonas Kvinge
1a2ab19ab4 GstEnginePipeline: Ignore core error when next song is set
Fixes #958
2023-01-01 20:25:57 +01:00
Jonas Kvinge
04f010aa7b Move SliderSlider and PrettySlider into own files 2023-01-01 18:45:21 +01:00
Jonas Kvinge
25323b4a3a VolumeSlider: Fix infinite loop when adjusting volume using mouse wheel
Fixes #1089
2023-01-01 17:46:26 +01:00
Jonas Kvinge
f353c022f6 LocalRedirectServer: Cast sizeof to int 2023-01-01 16:02:56 +01:00
Jonas Kvinge
9d8b3d3428 ContextView: Fix parameters for `IconLoader::Load()` 2023-01-01 16:02:17 +01:00
Strawbs Bot
e4b06772c0 Update translations 2023-01-01 01:08:45 +01:00
Jonas Kvinge
a2b5c3ea08 Remove settings for changing palette colors
Fixes #1087
2022-12-31 18:20:28 +01:00
Jonas Kvinge
f632e95600 Turn on git revision 2022-12-30 22:47:49 +01:00
Jonas Kvinge
4b5da8c6d4 Release 1.0.11 2022-12-30 18:52:59 +01:00
Jonas Kvinge
77d7ffd10a Update Changelog 2022-12-30 18:52:34 +01:00
Jonas Kvinge
d2f720011a macdeployqt: Disable libgstgme 2022-12-29 22:26:21 +01:00
Jonas Kvinge
6329a7711d Fix includes 2022-12-29 21:39:03 +01:00
Jonas Kvinge
fd14d044e3 CI: Bump macOS version to 11 2022-12-29 20:32:54 +01:00
Strawbs Bot
6368d507e1 Update translations 2022-12-29 01:06:59 +01:00
Jonas Kvinge
205b7f2401 Split utilities functions into separate files 2022-12-28 22:53:59 +01:00
Strawbs Bot
f7d10f9530 Update translations 2022-12-28 01:19:59 +01:00
Jonas Kvinge
66154bb51e Song: Add xesam:userRating in Song::ToXesam 2022-12-27 21:18:40 +01:00
Jonas Kvinge
fac4ad5313 Scrobbler: Allow album artists to be "Various Artists"
Fixes #1082
2022-12-27 21:15:20 +01:00
Jonas Kvinge
fee63891ac FilesystemMusicStorage: QFile::moveToTrash recursively moves files to trash 2022-12-27 20:59:09 +01:00
Strawbs Bot
efa979ee03 Update translations 2022-12-27 01:01:39 +01:00
Jonas Kvinge
c756346357 GstEnginePipeline: Add audio converter for sink 2022-12-11 01:14:17 +01:00
Strawbs Bot
cc95db25cc Update translations 2022-12-11 01:05:26 +01:00
Jonas Kvinge
44970c3321 GstEnginePipeline: Use converter for event probe 2022-12-11 00:21:16 +01:00
Jonas Kvinge
43c7934af7 Mpris2: Use art manual or automatic directly when available
Fixes #1079
2022-12-10 23:22:46 +01:00
Jonas Kvinge
3e7b51163c Don't use system icons for tabbar
Fixes #1084
2022-12-10 18:49:01 +01:00
Jonas Kvinge
4d5f8a53f0 CI: Remove unneeded "shell: bash" 2022-12-05 18:14:40 +01:00
Jonas Kvinge
0b73ca8318 CI: Add Remove Fedora 35 and add 38 2022-12-05 18:07:27 +01:00
Jonas Kvinge
754cfc3bfd Mpris2: Rename function parameter variable 2022-12-04 21:42:36 +01:00
Jonas Kvinge
2ed1a5c06a Add keywords to desktop file 2022-12-04 21:36:45 +01:00
Jonas Kvinge
b2073df3c3 GstEnginePipeline: Detect if autoaudiosink has volume
Fixes #1037
2022-12-04 08:37:33 +01:00
Jonas Kvinge
6267edaa81 Update Changelog 2022-12-04 03:18:04 +01:00
Jonas Kvinge
292f2de3e6 GstEnginePipeline: Add more info when ignoring error 2022-12-04 03:18:04 +01:00
Strawbs Bot
7803dc8be3 Update translations 2022-12-04 02:44:03 +01:00
Jonas Kvinge
2a1260b79e PlaylistParser: Resolve symbolic links when creating relative paths
Fixes #1071
2022-12-04 00:18:55 +01:00
Jonas Kvinge
f9ec438b7f Don't remove disc from album title when creating cover hash
Fixes #1069
2022-12-03 23:23:18 +01:00
Jonas Kvinge
de544c4856 CI: Fix Fedora 37 build 2022-12-03 13:06:21 +01:00
Jonas Kvinge
55e04dd520 Player: Fix volume adjustment 2022-12-03 05:29:39 +01:00
Jonas Kvinge
b2d06f900b GstEnginePipeline: Correct parameter name for SetFaderVolume function 2022-12-03 04:47:41 +01:00
Jonas Kvinge
b92ec71810 Use system volume when possible
Fixes #1037
2022-12-03 04:33:22 +01:00
Jonas Kvinge
3a4199240e Change constexpr to const 2022-11-27 03:27:40 +01:00
Jonas Kvinge
157de12bdf Improve Tidal and Qobuz request 2022-11-27 01:28:29 +01:00
Jonas Kvinge
7c0c9fccdb Organize: Don't allow organizing files without unique tags
Fixes #1077
2022-11-26 23:37:41 +01:00
Jonas Kvinge
2cb29d06b3 EditTagDialog: Disable fields for unsupported tags 2022-11-23 22:06:45 +01:00
Jonas Kvinge
1fdeb50d93 TagReaderTagLib: Don't use TPE1 as performer for ID3 tags
Fixes #1076
2022-11-23 00:03:23 +01:00
Jonas Kvinge
f59632ae59 TagReaderTest: Add tests for reading and writing compilation tag 2022-11-22 21:27:26 +01:00
Jonas Kvinge
67b503da44 TagReaderTagLib: Fix compilation tag read/write for MP4
Partial fix for #1076
2022-11-22 21:09:18 +01:00
Jonas Kvinge
a351de6904 TagReaderTagLib: Fix saving FMPS_Playcount
Fixes #1074
2022-11-22 19:34:11 +01:00
Jonas Kvinge
f94742abd5 EditTagDialog: Fix tab order
Fixes #1075
2022-11-22 19:06:40 +01:00
Jonas Kvinge
891182637e Update README.md 2022-11-21 23:40:30 +01:00
bhrgunatha
086681c915 Add spacefm support to core/utilities.cpp OpenInFileManager 2022-11-19 12:36:21 +01:00
Strawbs Bot
3970d2d02b Update translations 2022-11-17 01:01:49 +01:00
Jonas Kvinge
2b3fddd015 main: Set PULSE_PROP_media.role 2022-11-17 00:59:22 +01:00
Jonas Kvinge
30fa0480a3 main: Set PULSE_PROP_application.icon_name
Fixes #1066
2022-11-17 00:57:10 +01:00
Jonas Kvinge
320a81ce69 main: Use capitalized name in g_set_application_name()
Partial fix for #1066
2022-11-16 23:53:53 +01:00
Jonas Kvinge
950411ef56 ResizableTextEdit: Force updating geometry
Possible fix for
2022-11-16 21:10:30 +01:00
Strawbs Bot
cb9cf084c0 Update translations 2022-11-12 01:01:38 +01:00
Strawbs Bot
bb18af09ae Update translations 2022-11-11 01:12:18 +01:00
Jonas Kvinge
049bf0c7f9 TrackSlider: Remove extra parentheses 2022-11-10 19:19:33 +01:00
Jonas Kvinge
ebc73ef775 CI: Move macOS remove problematic files step 2022-11-10 01:03:50 +01:00
Strawbs Bot
1bd6f59355 Update translations 2022-11-10 01:01:50 +01:00
Jonas Kvinge
c16396a690 GstEnginePipeline: Log pipeline initialized 2022-11-09 22:42:43 +01:00
Strawbs Bot
32a9fe3e9c Update translations 2022-10-30 01:01:54 +02:00
Jonas Kvinge
f48d133bc6 TidalRequest: Fix returning empty results 2022-10-30 00:17:38 +02:00
Jonas Kvinge
0678526d7d CI: Build on FreeBSD with Qt 6 2022-10-29 22:16:15 +02:00
Jonas Kvinge
26d3e8371f CollectionWatcher: Only run periodic scan when monitoring is on 2022-10-29 19:12:04 +02:00
Jonas Kvinge
6768f614c7 GstEngine: Call SetState right before setFuture 2022-10-29 18:45:09 +02:00
Jonas Kvinge
171dc84df1 GstEngine: Use QUrl::clear() 2022-10-29 18:43:49 +02:00
Jonas Kvinge
5ca6513c04 TidalRequest: Only return error when no songs are received
Fixes #1061
2022-10-28 21:46:14 +02:00
Strawbs Bot
41aeb0ac80 Update translations 2022-10-27 01:01:24 +02:00
Strawbs Bot
f871c4adef Update translations 2022-10-25 01:01:27 +02:00
Jonas Kvinge
ad4d0e89b1 Turn off git revision 2022-10-22 10:14:20 +02:00
Jonas Kvinge
0d0c49caa1 Release 1.0.10 2022-10-21 23:39:59 +02:00
Jonas Kvinge
7cbc7bdcfb Update Changelog 2022-10-21 23:38:29 +02:00
Jonas Kvinge
6b46c8ed4a CI: Fix macOS build 2022-10-21 22:14:38 +02:00
Jonas Kvinge
e33ffd1c8a MusixmatchLyricsProvider: Fix error message 2022-10-21 20:54:16 +02:00
Strawbs Bot
8dce9cc938 Update translations 2022-10-21 01:02:47 +02:00
Jonas Kvinge
f06218f8e3 Qobuz: Add option for base64 app secret 2022-10-20 20:47:06 +02:00
Strawbs Bot
5711eef2be Update translations 2022-10-20 01:20:20 +02:00
Jonas Kvinge
db6aac603c nsi: Bump icu 2022-10-19 19:23:54 +02:00
Jonas Kvinge
f10e928106 Organize: Only load embedded cover if the destination is a device 2022-10-19 18:37:49 +02:00
Jonas Kvinge
99d963b99c MusicStorage: Add source 2022-10-19 18:36:33 +02:00
Jonas Kvinge
5d35c22238 OrganizeDialog: Use QUrl::isLocalFile 2022-10-19 18:34:30 +02:00
Jonas Kvinge
54fc11a235 CollectionBackend: Rename source accessor 2022-10-19 17:11:56 +02:00
Jonas Kvinge
ec99df3144 Create common class for Musixmatch 2022-10-18 22:49:15 +02:00
Jonas Kvinge
d722035883 VLCEngine: Only emit stopped when still playing
VLC sends the stopped signal too late, the player has already moved on based on the end reached signal. Emitting Stopped afterwards will interrupt the player in the middle of the song change.

Fixes #1054
2022-10-18 20:12:21 +02:00
Jonas Kvinge
52139fbaa0 Player: Reverse if 2022-10-18 20:09:38 +02:00
Jonas Kvinge
88854eb558 nsi: Bump libunistring 2022-10-17 21:41:14 +02:00
Jonas Kvinge
c82bba01ee MusixmatchLyricsProvider: Remove unused declaration 2022-10-17 20:34:51 +02:00
Jonas Kvinge
eaa33a03d7 MusixmatchLyricsProvider: Use API for lyrics search when possible 2022-10-17 20:29:44 +02:00
Jonas Kvinge
89e8518f31 GeniusLyricsProvider: Make private 2022-10-17 20:28:51 +02:00
Jonas Kvinge
c7bf2e1da8 LyricsProvider: Add missing newline 2022-10-16 22:52:06 +02:00
Jonas Kvinge
bf904a6afa LyricsProvider: Parse multiple sections of the same tag 2022-10-16 01:27:54 +02:00
Jonas Kvinge
43c14ae71b Replace pragma once with header guards for consistency
Only 2 headers have this.
2022-10-15 19:54:09 +02:00
Jonas Kvinge
4abb8ef3c9 Update Changelog 2022-10-15 14:39:49 +02:00
Jonas Kvinge
e46b92dd7d GeniusLyricsProvider: Use new function for parsing HTML 2022-10-15 14:34:09 +02:00
Jonas Kvinge
1a25faa5b9 LyricsProvider: Add function for parsing lyrics from HTML 2022-10-15 14:33:35 +02:00
Strawbs Bot
3f4bf5f512 Update translations 2022-10-14 01:18:29 +02:00
Jonas Kvinge
ae7dbf15ed nsi: Remove avresample-4.dll 2022-10-14 00:10:30 +02:00
Jonas Kvinge
b22320c48f Replace typedef with using 2022-10-13 22:39:31 +02:00
Jonas Kvinge
61204e8d35 CMakeLists: cmake_minimum_required before project 2022-10-13 21:41:46 +02:00
Jonas Kvinge
b0704c654c utilities_test: Fix QByteArray conversion 2022-10-13 21:37:11 +02:00
Strawbs Bot
f40f8a8873 Update translations 2022-10-13 01:01:31 +02:00
Jonas Kvinge
560a7db506 Update .clang-format 2022-10-12 21:28:14 +02:00
Strawbs Bot
15baa8f70e Update translations 2022-10-12 01:01:48 +02:00
Jonas Kvinge
97a7637294 FileView: Use QFileIconProvider instead of QAbstractFileIconProvider
Fixes compile with Qt 5
2022-10-12 00:36:16 +02:00
Jonas Kvinge
3454656207 PlaylistContainer: Fix search field crash on macOS
Fixes #1053
2022-10-12 00:11:12 +02:00
Iridias
7dff6f26bc FileView: Create new file icon provider if icons are missing 2022-10-11 23:52:00 +02:00
Jonas Kvinge
9e835a23fd Rename QSearchField 2022-10-11 23:34:22 +02:00
Jonas Kvinge
c0259fb6ce CI: Remove unused macOS brew packages 2022-10-11 00:27:26 +02:00
Jonas Kvinge
acf106220b CI: Upgrade packages for macOS 2022-10-10 22:31:35 +02:00
Strawbs Bot
5d4dc9c907 Update translations 2022-10-10 01:02:17 +02:00
Jonas Kvinge
2b9a56af7f Update Changelog 2022-10-09 22:18:20 +02:00
Jonas Kvinge
f1e3ac65ac TidalRequest: Simplify no results
Fixes #1047
2022-10-09 22:07:59 +02:00
Jonas Kvinge
143f72cf6b PlaylistView: Fix scaling mid bar for currently playing track
Fixes #1051
2022-10-09 21:41:16 +02:00
Jonas Kvinge
5c8e49296c CI: Add Fedora 37 2022-10-05 00:08:09 +02:00
Jonas Kvinge
b2558b703c nsi: Add jpeg62.dll for MSVC 2022-10-02 22:33:36 +02:00
Jonas Kvinge
bf9d87106e CI: Build Jammy with Qt 6 2022-10-02 19:38:22 +02:00
Jonas Kvinge
5b7f507d9b Windows7ThumbBar: Use QString length instead of count 2022-10-01 14:03:28 +02:00
Jonas Kvinge
59a7835ace CI: Fix if lines 2022-10-01 01:40:32 +02:00
Jonas Kvinge
2495838fe3 CI: Use matrix 2022-09-30 23:58:25 +02:00
Jonas Kvinge
bab687bedf Add USE_RPATH option 2022-09-30 01:00:29 +02:00
Jonas Kvinge
6467c3c8ee Update CMakeLists.txt 2022-09-30 01:00:15 +02:00
Jonas Kvinge
66c2b7aaa6 Update Version.cmake 2022-09-30 00:59:33 +02:00
Jonas Kvinge
ab72c52661 CI: Remove custom libsoup step for macOS 2022-09-29 22:33:47 +02:00
Jonas Kvinge
f0bf1b8a54 Rename CI 2022-09-29 22:32:04 +02:00
Strawbs Bot
119251719f Update translations 2022-09-24 01:01:45 +02:00
Jonas Kvinge
0348400132 ContextView: Remove use of fixed font
Fixes #1040
2022-09-23 18:10:01 +02:00
Jonas Kvinge
813473805b CI: Get latest MSVC dependencies 2022-09-17 01:45:42 +02:00
Strawbs Bot
fe6368561b Update translations 2022-09-17 01:01:19 +02:00
Strawbs Bot
7ff06f424d Update translations 2022-09-15 01:01:21 +02:00
Jonas Kvinge
31958592c7 main: Always create initial style settings 2022-09-13 22:44:24 +02:00
Jonas Kvinge
adc21f4f75 Remove subdir for generated dbus files 2022-09-13 17:53:57 +02:00
Strawbs Bot
9cecd89d6f Update translations 2022-09-13 01:26:32 +02:00
Jonas Kvinge
d866b9b4d4 Update definitions i CMakeLists 2022-09-12 23:20:07 +02:00
Jonas Kvinge
93f12baf51 Fix narrowing conversions in connects 2022-09-12 23:18:54 +02:00
Jonas Kvinge
78d6fd634b Fix casts from QByteArray 2022-09-12 22:39:08 +02:00
Strawbs Bot
b5fc19f08a Update translations 2022-09-12 01:01:20 +02:00
Jonas Kvinge
2dae6a6546 nsi: Update flac dll version 2022-09-10 23:52:27 +02:00
Jonas Kvinge
b6bba46391 CI: Update vmactions/freebsd-vm 2022-09-09 23:02:28 +02:00
Jonas Kvinge
b791d97116 CI: Use variable for workspace 2022-09-09 22:40:37 +02:00
Strawbs Bot
6aa8255f34 Update translations 2022-09-08 01:01:22 +02:00
Jonas Kvinge
98e2140761 Turn on git revision 2022-09-04 00:48:35 +02:00
Jonas Kvinge
a59e064778 Release 1.0.9 2022-09-03 20:40:14 +02:00
Jonas Kvinge
655c4c66a7 Update Changelog 2022-09-03 20:34:25 +02:00
Jonas Kvinge
407c128f65 GstStartup: Set LIBSOUP3_LIBRARY_PATH for macOS 2022-09-03 00:19:25 +02:00
Jonas Kvinge
59a261a5be main: Add Frameworks to library paths for macOS 2022-09-03 00:19:25 +02:00
Jonas Kvinge
ba4e1afefe CI: Compile entire gstreamer from source for macOS 2022-09-02 23:55:25 +02:00
Jonas Kvinge
98b53b81d8 Update Changelog 2022-09-01 22:06:00 +02:00
Jonas Kvinge
8270cc0aa2 macdeploycheck: Fail on parse error 2022-09-01 21:58:11 +02:00
Jonas Kvinge
74207b1a87 Update ISSUE_TEMPLATE.md 2022-09-01 21:35:33 +02:00
Jonas Kvinge
77983445ce debian: Fix icu dependency 2022-09-01 19:18:40 +02:00
Ondrej Mosnáček
162190bcb8 Mark collectionmodel_test as not requiring GUI
The test doesn't seem to acually need gui_required = true, so set it to
false.
2022-08-31 12:40:46 -07:00
Jonas Kvinge
86b92b20b7 macdeployqt: Add back extra changeInstallName 2022-08-30 21:35:11 +02:00
Jonas Kvinge
2f5b60d548 macdeployqt: Fix deploying libgcc
Fixes #1025
2022-08-30 19:33:59 +02:00
Jonas Kvinge
c19661c977 macdeploycheck: Fix check for libgcc 2022-08-30 19:32:59 +02:00
Jonas Kvinge
82d101ca27 macdeployqt: Merge changes from upstream 2022-08-30 17:48:16 +02:00
Jonas Kvinge
32f9c4e670 GstEnginePipeline: Parse album from stream title tag
Fixes #1023
2022-08-30 16:56:08 +02:00
Jonas Kvinge
34c7225ab7 Turn back git revision 2022-08-29 22:05:07 +02:00
Jonas Kvinge
b02eb502e4 Release 1.0.8 2022-08-29 17:54:05 +02:00
Jonas Kvinge
7d6b3dfd20 Update maketarball.sh.in 2022-08-29 17:53:49 +02:00
Strawbs Bot
3ac39968d2 Update translations 2022-08-29 01:16:24 +02:00
Jonas Kvinge
2b24ac54a0 Remove unused includes 2022-08-28 03:09:33 +02:00
Jonas Kvinge
6da6b794c7 VolumeSlider: Remove unused Background and Foreground 2022-08-28 02:52:40 +02:00
Jonas Kvinge
ed689e27c9 Transcoder: Change return type for QueuedJobsCount to qint64 2022-08-28 02:51:10 +02:00
Jonas Kvinge
186f9c3f18 SmartPlaylistWizard: Add missing override 2022-08-28 02:50:33 +02:00
Jonas Kvinge
42cdde3203 SmartPlaylistsViewContainer: Add missing override 2022-08-28 02:50:17 +02:00
Jonas Kvinge
b9091702e9 SmartPlaylistSearchTermWidget: Add missing override 2022-08-28 02:50:02 +02:00
Jonas Kvinge
d42ecbe74e SmartPlaylistQueryWizardPlugin: Add missing override 2022-08-28 02:49:45 +02:00
Jonas Kvinge
e6c5446d63 PlaylistQueryGenerator: Add missing override 2022-08-28 02:49:30 +02:00
Jonas Kvinge
cc277211b3 LibreFMScrobbler: Call base class for ReloadSettings 2022-08-28 02:48:47 +02:00
Jonas Kvinge
6703c15c52 RadioPlaylistItem: Fix header guard comment 2022-08-28 02:48:22 +02:00
Jonas Kvinge
4ecdaf573e MoodbarRenderer: Remove unused kNumHues 2022-08-28 02:47:45 +02:00
Jonas Kvinge
71ec3e61be signalchecker: Remove useless return 2022-08-28 02:46:23 +02:00
Jonas Kvinge
216fdb2393 FileSystemWatcherInterface: Change signal to non const 2022-08-28 02:45:56 +02:00
Jonas Kvinge
c39acc6e3c Database: Remove useless return 2022-08-28 02:45:34 +02:00
Jonas Kvinge
d97b0478a7 Fix typos 2022-08-28 02:44:37 +02:00
Jonas Kvinge
d15d64eb67 nsi: Add nghttp2.dll for MSVC 2022-08-27 23:43:39 +02:00
Jonas Kvinge
3acd2656ee Update Changelog 2022-08-27 23:14:56 +02:00
Jonas Kvinge
a4b003534a CI: Switch to libsoup 3 2022-08-27 19:36:29 +02:00
Jonas Kvinge
8752538a02 nsi: Switch to libsoup 3 2022-08-27 19:36:29 +02:00
Strawbs Bot
bde435753a Update translations 2022-08-25 01:02:52 +02:00
Jonas Kvinge
d347e6fc5f Add setting for turning off HTTP/2 2022-08-24 20:34:10 +02:00
Jonas Kvinge
27b01d3642 Analyzer::Base: Set Qt::WA_OpaquePaintEvent 2022-08-24 20:32:08 +02:00
Jonas Kvinge
b78677e285 nsi: Use libsoup 2 2022-08-22 23:19:49 +02:00
Jonas Kvinge
f8f6c74bcb CI: Use libsoup 2 2022-08-22 23:19:40 +02:00
Strawbs Bot
7ce123939b Update translations 2022-08-21 01:19:35 +02:00
Jonas Kvinge
e7b02cfb15 TagReaderGME: Use UTF-16 2022-08-21 00:36:06 +02:00
Jonas Kvinge
5931077b08 macdeployqt: Add GStreamer GME plugin 2022-08-20 19:52:32 +02:00
Jonas Kvinge
a521bdc0e3 TagReaderGME: Compare file extension case-insensitive 2022-08-20 19:08:58 +02:00
Eoin O'Neill
80da565609 Initial support for GME's VGM/SPC playback and tag management.
Co-Authored-By: Jonas Kvinge <jonas@jkvinge.net>
2022-08-20 18:33:13 +02:00
Jonas Kvinge
6bc46e4598 CollectionModel: Make separate_albums_by_grouping optional 2022-08-20 16:47:09 +02:00
Jonas Kvinge
6562258db5 CollectionModel: Make separating albums by grouping optional
Fixes #1018
2022-08-20 14:51:19 +02:00
Jonas Kvinge
c219995218 Update .gitignore 2022-08-19 21:15:08 +02:00
Jonas Kvinge
62035431ed Install Visual C++ runtime 2022-08-18 22:47:34 +02:00
Jonas Kvinge
fa1fbca7dc DirectSoundDeviceFinder: Remove __attribute__((stdcall)) 2022-08-15 19:55:55 +02:00
Strawbs Bot
391b7476b3 Update translations 2022-08-15 01:01:37 +02:00
Jonas Kvinge
9c04ce665f DirectSoundDeviceFinder: Add CALLBACK to EnumerateCallback 2022-08-14 10:37:31 +02:00
Jonas Kvinge
dd87268197 CI: Build Windows x86 2022-08-14 10:37:31 +02:00
Jonas Kvinge
8d9af59db2 MainWindow: Use different Sparkle URL for x86 2022-08-14 10:37:31 +02:00
Strawbs Bot
1b754a35ff Update translations 2022-08-14 01:01:17 +02:00
Jonas Kvinge
7230f91f61 CI: Update actions 2022-08-10 21:32:18 +02:00
Strawbs Bot
93edfc315c Update translations 2022-08-10 01:01:34 +02:00
Strawbs Bot
74c8269531 Update translations 2022-08-09 18:02:04 +02:00
Jonas Kvinge
acb6c0fc83 Use PlaylistFilter directly 2022-08-09 17:23:46 +02:00
Jonas Kvinge
553d4cce93 PlaylistContainer: Translate Undo/Redo
Fixes #1017
2022-08-09 17:04:59 +02:00
Jonas Kvinge
ca81f144e6 README: Add ICU to dependencies 2022-08-08 00:37:37 +02:00
Jonas Kvinge
ec84960347 nsi: Move icu to common files 2022-08-08 00:37:19 +02:00
Jonas Kvinge
38db0764af Require ICU 2022-08-07 20:23:23 +02:00
Jonas Kvinge
a647f63bb0 CI: Add macOS 2022-08-07 17:35:53 +02:00
Jonas Kvinge
5b7087cc9e nsi: Add files for MSVC 2022-08-07 12:32:31 +02:00
Jonas Kvinge
1a6fcd5da6 QSearchField: Replace use of C-style cast 2022-08-07 05:14:38 +02:00
Jonas Kvinge
e31dd9f553 MacSystemTrayIcon: Replace use of C-style cast 2022-08-07 05:14:05 +02:00
Jonas Kvinge
22844716d1 RadioView: Remove duplicate double clicked
Already done in AutoExpandingTreeView::ItemDoubleClicked

Fixes #1015
2022-08-07 02:40:09 +02:00
Jonas Kvinge
6abed76f70 nsi: Add gme 2022-08-06 17:02:00 +02:00
Jonas Kvinge
72ff502e0f OSDDBus: Set timeout 2022-07-31 03:28:13 +02:00
Jonas Kvinge
2b781df32b CI: Use openSUSE Leap 15.4 for source builder 2022-07-29 16:27:21 +02:00
Strawbs Bot
bf601c3906 Update translations 2022-07-29 01:25:43 +02:00
Jonas Kvinge
b753e0ebb0 CI: Remove macOS 2022-07-28 16:56:35 +02:00
Jonas Kvinge
564211aceb Prefer ICU to transliterate characters when available
Fixes #1008
2022-07-28 16:31:16 +02:00
Strawbs Bot
538c759fef Update translations 2022-07-28 01:02:19 +02:00
Jonas Kvinge
95edc34100 Update README and issue template 2022-07-27 20:43:03 +02:00
Jonas Kvinge
98682a2da9 Use C++17 fallthrough 2022-07-26 20:37:06 +02:00
Jonas Kvinge
33581fa61d PlaylistContainer: Fix filter text when switching playlist
Fixes #1005
2022-07-26 07:35:43 +02:00
Jonas Kvinge
b02e0aae98 PlaylistListSortFilterModel: Add header guard 2022-07-26 07:33:11 +02:00
Jonas Kvinge
6fa4e1cb6d Turn on git revision 2022-07-25 23:37:33 +02:00
Jonas Kvinge
9f2ec22e95 Release 1.0.7 2022-07-25 21:45:27 +02:00
Jonas Kvinge
65b2e506b1 CI: Remove Ubuntu Impish 2022-07-25 17:29:35 +02:00
Jonas Kvinge
8bc07b5286 nsi: Add libgpg-error-0.dll 2022-07-25 15:51:05 +02:00
Jonas Kvinge
fe0af63795 Update Changelog 2022-07-25 15:28:25 +02:00
Jonas Kvinge
44ce7f4c67 CI: Disable audio cd for Windows MinGW build 2022-07-25 15:27:17 +02:00
Jonas Kvinge
252936134b nsi: Remove gstwinrt-1.0-0.dll 2022-07-25 04:25:08 +02:00
Jonas Kvinge
e255b06945 macdeployqt: Update gstreamer plugins 2022-07-25 03:56:38 +02:00
Jonas Kvinge
d726568a23 nsi: Add gstwavenc 2022-07-25 03:55:38 +02:00
Jonas Kvinge
66880a6de7 nsi: Update gstreamer plugins 2022-07-25 03:23:34 +02:00
Jonas Kvinge
fda622a0c0 Update Changelog 2022-07-24 23:44:54 +02:00
Jonas Kvinge
efa7d10f40 nsi: Add twolame 2022-07-21 03:04:48 +02:00
Strawbs Bot
348a3fabab Update translations 2022-07-21 01:09:44 +02:00
Jonas Kvinge
1bbaee605c PlaylistParser: Check file extension case-insensitive 2022-07-20 14:56:55 +02:00
Jonas Kvinge
22edf7a2b3 TagReaderTagParser: Fix reading and writing rating 2022-07-20 11:44:46 +02:00
Jonas Kvinge
3ffcc29249 Add back save all playlists action 2022-07-20 01:09:00 +02:00
Jonas Kvinge
21f1fe52c0 Remove save all playlists action
It's hard-coded to m3u, needs a new select directory dialog with option to select different playlist formats.

Fixes #987
2022-07-18 22:56:32 +02:00
Jonas Kvinge
99840c9e4f Turn on git revision 2022-07-18 00:40:00 +02:00
Jonas Kvinge
3194fe7d8e Release 1.0.6 2022-07-17 23:36:45 +02:00
Jonas Kvinge
81df72b0cb Update debian/copyright 2022-07-17 21:47:35 +02:00
Jonas Kvinge
57b056ac43 WorkerPool: Search for tagreader in libexec 2022-07-17 17:21:11 +02:00
Jonas Kvinge
c5876d0d48 Update Changelog 2022-07-17 01:53:39 +02:00
Jonas Kvinge
b5e65401b6 Update Changelog 2022-07-17 01:52:21 +02:00
Jonas Kvinge
ebea5b48ea Update Changelog 2022-07-17 01:50:58 +02:00
Jonas Kvinge
7d081e581a CI: Remove extra Qt 6 repo 2022-07-17 01:16:06 +02:00
Jonas Kvinge
5e819cf04b Remove defining _WIN32_WINNT 2022-07-17 01:16:10 +02:00
Jonas Kvinge
fd9ab43681 Windows7ThumbBar: Create taskbar list once 2022-07-17 00:13:37 +02:00
Jonas Kvinge
4935cdc722 Transcoder: Formatting 2022-07-16 16:31:04 +02:00
Jonas Kvinge
26a3c7ad6a Transcoder: Fix caps leak 2022-07-16 16:10:49 +02:00
Strawbs Bot
c358216ad9 Update translations 2022-07-16 01:01:40 +02:00
Yaroslav Chvanov
bb9302143c Send the media player name and version to ListenBrainz 2022-07-15 20:50:00 +02:00
Yaroslav Chvanov
3a73553aac Send more information to ListenBrainz
- Track duration and number.
- Player name and version.
2022-07-15 20:50:00 +02:00
Strawbs Bot
6447a17e3e Update translations 2022-07-15 01:01:45 +02:00
Jonas Kvinge
4bd5c8ffb3 EditTagDialog: Remove useless HTML 2022-07-14 23:56:00 +02:00
Jonas Kvinge
89f137b211 SmartPlaylistSearchTermWidget: Remove tr from Strawberry 2022-07-14 23:41:38 +02:00
Strawbs Bot
3425572c66 Update translations
Fixes #994
2022-07-14 22:09:06 +02:00
Jonas Kvinge
ad50875f9c SnapDialog: Remove HTML tag from tr text 2022-07-14 22:04:23 +02:00
Strawbs Bot
34e5645dab Update translations 2022-07-14 20:54:57 +02:00
Jonas Kvinge
e8ae91c230 nsi: Add pcre2-8 2022-07-13 17:25:14 +02:00
Jonas Kvinge
44b83994fa Remove libpcre-1.dll 2022-07-13 16:58:28 +02:00
Jonas Kvinge
201f585350 CI: Use official Qt 6 repo for Leap 15.3 and 15.4 2022-07-11 23:12:26 +02:00
Strawbs Bot
e4d2f1925e Update translations 2022-07-11 01:04:46 +02:00
Jonas Kvinge
658c116eac Utilities: Remove unnecessary constData() in Sha1CoverHash 2022-07-10 19:14:05 +02:00
Jonas Kvinge
dbbedee77f CollectionBackendTest: Remove invalid song test 2022-07-10 19:09:09 +02:00
Jonas Kvinge
16ac9ea061 TagReaderTest: Remove use of deprecated QCryptographicHash constructor 2022-07-10 19:08:43 +02:00
Jonas Kvinge
6afbc71b4a Remove old schemas 2022-07-10 18:57:00 +02:00
Jonas Kvinge
71263863ad Allow invalid ctime/mtime
Possible fix for #815 and #947
2022-07-10 03:24:02 +02:00
Jonas Kvinge
05232065f8 schema: Remove DEFAULT for TEXT 2022-07-10 01:56:39 +02:00
Jonas Kvinge
f289ae4143 Add Ubuntu Kinetic 2022-07-08 19:36:43 +02:00
Jonas Kvinge
91703ecec4 macdeployqt: Add hls plugin 2022-07-07 21:47:05 +02:00
Strawbs Bot
6fb0858b87 Update translations 2022-07-04 01:01:17 +02:00
Jonas Kvinge
f1c6620df9 Add Wiki link to README 2022-07-02 22:38:55 +02:00
Jonas Kvinge
08fed9a5ee CI: Update libsoup dll 2022-07-02 10:21:15 +02:00
Jonas Kvinge
eb28b3b05b Update libsoup in nsi 2022-07-01 23:33:19 +02:00
Strawbs Bot
f0c354b0c9 Update translations 2022-07-01 01:01:44 +02:00
Yaroslav Chvanov
07d88e86a2 Add support for prefer album artist option to ListenBrainz 2022-06-30 21:59:30 +02:00
Jonas Kvinge
f41a3b9bb2 CommandlineOptions: Change quint64 to quint32 to match operator>>
Fixes #986
2022-06-24 17:18:54 +02:00
Jonas Kvinge
bfd9e76f40 Remove capture of ‘this’ via ‘[=]’ 2022-06-20 23:52:18 +02:00
Strawbs Bot
38ce208a43 Update translations 2022-06-18 01:01:29 +02:00
Jonas Kvinge
fcd148b8d5 Playlist: Fix "Stop after this track" greys out next track in dynamic mode
Fixes #912
2022-06-16 17:53:07 +02:00
Ondrej Mosnacek
fc6c3774b0 README: Exclude unsupported repos in the repology badge
Showing them provides little value, as they are no longer maintained
and thus expected to contain outdated packages.

Signed-off-by: Ondrej Mosnacek <omosnace@redhat.com>
2022-06-15 17:12:43 +02:00
Chongo Bong
18023d2e18 Update desktop file action, use play/pause instead of play and pause
Condenses it a bit. looks cleaner, yet provides the same functionality as before.
2022-06-15 17:08:15 +02:00
Strawbs Bot
467e834ad6 Update translations 2022-06-15 01:01:41 +02:00
Jonas Kvinge
629d9e7ae0 FileViewList: Sort files with QCollator in numeric mode
Fixes #977
2022-06-14 17:21:59 +02:00
Jonas Kvinge
4487d292e8 Set C standard to C99 for MSVC 2022-06-14 16:16:49 +02:00
Jonas Kvinge
76711b9a66 Set C standard to C17 2022-06-13 21:20:41 +02:00
Jonas Kvinge
b54c749e43 Replace use of C-style casts 2022-06-13 00:40:31 +02:00
Jonas Kvinge
d82fd421ed Replace use of C-style casts 2022-06-13 00:23:42 +02:00
Jonas Kvinge
abdcadb5fa Flush correct queue 2022-06-12 02:28:02 +02:00
Jonas Kvinge
fa3891e383 Use list instead of map for songs in internet search
Fixes issues with sorting
2022-06-12 01:59:46 +02:00
Strawbs Bot
f1dc0f95c8 Update translations 2022-06-12 01:28:33 +02:00
Jonas Kvinge
5c721d243a Turn on git revision 2022-06-11 00:27:38 +02:00
Jonas Kvinge
2770384f1f Release 1.0.5 2022-06-10 21:50:35 +02:00
Jonas Kvinge
f4e5b83039 Replace use of C-style casts 2022-06-10 02:30:39 +02:00
Jonas Kvinge
124681605b Change -Wno-old-style-cast to -Wold-style-cast 2022-06-10 01:23:55 +02:00
Jonas Kvinge
a217faae7c OSDPretty: Remove use of C-style cast 2022-06-10 00:47:11 +02:00
Jonas Kvinge
184c39bbb7 Update Changelog 2022-06-10 00:01:21 +02:00
Jonas Kvinge
508e2a70bb Update Changelog 2022-06-09 23:38:25 +02:00
Jonas Kvinge
5aac56fe96 ContextView: Cleanup spacers 2022-06-09 23:09:41 +02:00
Strawbs Bot
dab7dad966 Update translations 2022-06-09 01:02:32 +02:00
Jonas Kvinge
25e48d6cae Add option for disabling bars on currently playing track
Fixes #972
2022-06-09 00:50:21 +02:00
Jonas Kvinge
9b743e55d1 ContextView: Update album width from context 2022-06-09 00:46:39 +02:00
Jonas Kvinge
dc1f9edfaf Organize: Only notify song path changed for collection and device songs 2022-06-07 22:43:39 +02:00
Strawbs Bot
b6b68edf1e Update translations 2022-06-07 01:01:51 +02:00
Jonas Kvinge
a2320b99ae ContextView: Use fixed size to avoid scrollbar issues 2022-06-06 20:54:15 +02:00
Jonas Kvinge
be01e28068 ContextAlbum: Use sizeHint() 2022-06-06 18:24:00 +02:00
Jonas Kvinge
d6084083a5 Update data/style/strawberry.css 2022-06-06 18:23:34 +02:00
Jonas Kvinge
019bf5102c ResizableTextEdit: Add Q_OBJECT macro 2022-06-06 18:23:12 +02:00
Jonas Kvinge
a1633224d1 CI: Add g++ for debian/ubuntu 2022-06-06 18:22:06 +02:00
Strawbs Bot
e62bd26cb9 Update translations 2022-06-06 01:26:37 +02:00
Jonas Kvinge
c29f517292 Update debian/control.in 2022-06-05 23:47:04 +02:00
Jonas Kvinge
d80144f80c Remove -fpermissive 2022-06-05 23:19:40 +02:00
Jonas Kvinge
4733c84a86 ContextAlbum: Move rescaling back to paintevent 2022-06-05 19:02:34 +02:00
Jonas Kvinge
23f3d2095b ContextAlbum: Improve album cover fading 2022-06-05 18:20:44 +02:00
Jonas Kvinge
4f1f2b6fc6 ContextView: Change condition for showing context menu 2022-06-05 18:19:14 +02:00
Jonas Kvinge
1ea70b085f Context: Remove albums 2022-06-05 11:58:53 +02:00
Jonas Kvinge
6c0b395f4a Add option for overwriting playcounts
Fixes #962
2022-06-05 04:59:50 +02:00
Jonas Kvinge
0ee67f186f Remove widgets/resizabletextedit.h from CMakeLists.txt 2022-06-05 04:57:58 +02:00
Jonas Kvinge
d133addbaa Context: Use custom textedits instead of labels
Also improve album cover scaling

Fixes #965
2022-06-05 04:41:36 +02:00
Jonas Kvinge
683991b1c9 Add ResizableTextEdit 2022-06-05 04:41:36 +02:00
Strawbs Bot
32ac02007b Update translations 2022-06-05 01:01:44 +02:00
Jonas Kvinge
d716617ae0 FancyTabWidget: Make sure context menu does not popup outside of tabbar 2022-06-05 00:25:48 +02:00
Jonas Kvinge
26e1f015d2 Add streaming to description in CMakeLists.txt 2022-06-04 16:16:19 +02:00
Jonas Kvinge
1c94093a4b Update debian/copyright 2022-06-04 16:16:19 +02:00
Strawbs Bot
27eccd456a Update translations 2022-06-04 01:02:03 +02:00
Jonas Kvinge
eed4447560 Update protobuf in nsi 2022-05-31 19:02:31 +02:00
Jonas Kvinge
3c8d0ebd52 CollectionModel: Use grouping in all album groupings 2022-05-31 00:53:47 +02:00
Jonas Kvinge
7ec0d2f2cc Update fftw3 in nsi 2022-05-22 02:14:07 +02:00
Strawbs Bot
35da91a997 Update translations 2022-05-22 01:02:14 +02:00
Jonas Kvinge
788747c071 MainWindow: Remove unnecessary hide() 2022-05-21 19:12:53 +02:00
Jonas Kvinge
36eb131289 MainWindow: Remove QEvent::spontaneous() check in close event
Fixes #964
2022-05-21 19:12:53 +02:00
Jonas Kvinge
f231f28818 Move QGuiApplication::setQuitOnLastWindowClosed before QApplication 2022-05-21 19:12:53 +02:00
Strawbs Bot
aebdc89f77 Update translations 2022-05-20 01:04:44 +02:00
Jonas Kvinge
4a3a379871 Increase icons to include 128x128 and set global application icon
Fixes #954
2022-05-19 22:02:35 +02:00
Jonas Kvinge
a7f27add2d Combine definitions 2022-05-17 23:40:53 +02:00
Strawbs Bot
cd1d4247cf Update translations 2022-05-16 01:01:29 +02:00
Strawbs Bot
6d618c4b78 Update translations 2022-05-14 01:11:35 +02:00
Jonas Kvinge
ad469531ff SPFParser: Use percent-encoding for image too 2022-05-13 23:36:38 +02:00
Jonas Kvinge
cf9b4b1246 XSPFParser: Use percent-encoding when loading and saving playlists
Fixes #821
2022-05-13 23:32:35 +02:00
Jonas Kvinge
18a2692dc1 PlaylistParser: Refactor code and exclude CUE from save playlist filters
Fixes #953
2022-05-13 23:14:56 +02:00
Jonas Kvinge
a2dad982f8 Move sqlrow to core 2022-05-13 18:15:04 +02:00
Jonas Kvinge
8f27b6a4c9 CI: Update Fedora 2022-05-10 01:06:04 +02:00
Jonas Kvinge
21c4022fca PlaylistView: Fix invalidating cached pixmap on scroll
Fixes #952
2022-05-09 23:46:33 +02:00
Jonas Kvinge
237933855a Remove unused PKGBUILD file 2022-05-06 18:31:32 +02:00
Jonas Kvinge
dff7068a03 Move debian configuration to separate CMakeLists.txt 2022-05-06 18:26:46 +02:00
Jonas Kvinge
8f28a85a6d RadioParadiseService: Change URLs to https 2022-05-06 18:07:20 +02:00
Jonas Kvinge
2414eb2598 GstEnginePipeline: Replace char with int8_t in HandoffCallback 2022-05-06 17:42:08 +02:00
Strawbs Bot
4851f6bffd Update translations 2022-05-06 01:01:57 +02:00
Jonas Kvinge
948be36d3c SmartPlaylistSearchTerm: Move value assigment
Mistake done in commit 3f3ae7c38f
2022-05-05 20:41:30 +02:00
Jonas Kvinge
edd088927d macdeployqt: List missing gstreamer plugins instead of failing
Fixes #936
2022-05-04 23:11:53 +02:00
Jonas Kvinge
4cfe8dd95e nsi: Fix pcre2 dll for debug 2022-05-03 20:08:40 +02:00
Jonas Kvinge
e1ce81c5bf Update pcre2 filename in nsi 2022-04-30 21:03:09 +02:00
Jonas Kvinge
0f40b5f022 VLCEngine: Fix track progress
Fixes #941
2022-04-29 00:09:29 +02:00
FireFragment
94c5ffa92e Allow setting blur amount of background image up to 100px 2022-04-27 20:53:29 +02:00
FireFragment
3c9bf56767 Improve CMake error message in case of missing libvlc
When running CMake with VLC installed, but without libvlc there pops out following error message:
 > You need to have eithoer GStreamer or VLC to compile!

This may be confusing for some users, because they might have VLC already installed, but not libvlc. This commit fixes it.
2022-04-26 17:39:07 +02:00
Jonas Kvinge
9024acb16e debian: Add qt6-qpa-plugins to depends
Fixes #937
2022-04-23 23:48:16 +02:00
Jonas Kvinge
7732402122 Add ffmpeg to MSVC 2022-04-23 18:06:38 +02:00
Jonas Kvinge
2059bce6a7 Add Qt 6 support to debian files 2022-04-23 02:15:22 +02:00
Jonas Kvinge
499c86a8b8 Add safe git directory 2022-04-20 01:23:02 +02:00
Strawbs Bot
ef084eb145 Update translations 2022-04-20 01:02:20 +02:00
Jonas Kvinge
3f3ae7c38f SmartPlaylistSearchTerm: Fix filetype search 2022-04-19 23:11:13 +02:00
Strawbs Bot
83d762287f Update translations 2022-04-18 01:01:58 +02:00
Strawbs Bot
5af0acf147 Update translations 2022-04-16 01:05:16 +02:00
Jonas Kvinge
907dfee6f7 Utilities: Use inconv with MSVC 2022-04-15 17:44:04 +02:00
Strawbs Bot
d587d24603 Update translations 2022-04-15 01:03:02 +02:00
Jonas Kvinge
c246b8f164 GstEngine: Show debug information in error dialog 2022-04-14 20:56:57 +02:00
Strawbs Bot
deecafa053 Update translations 2022-04-11 01:02:28 +02:00
Jonas Kvinge
f8810106a2 Turn on git revision 2022-04-10 17:34:26 +02:00
Jonas Kvinge
8e35fbe532 Release 1.0.4 2022-04-10 14:08:25 +02:00
Jonas Kvinge
b1fdccde6e ContextView: Specify alternative fonts for no song playing 2022-04-10 14:05:51 +02:00
Jonas Kvinge
6741f100a1 Update Changelog 2022-04-10 12:19:23 +02:00
Jonas Kvinge
e05e9ea1b2 timeconstants: Use constexpr 2022-04-08 17:35:44 +02:00
Jonas Kvinge
197341de5e Update debian/copyright-scan-patterns.yml 2022-04-08 17:35:31 +02:00
Jonas Kvinge
2933482be3 Update debian/copyright 2022-04-08 17:35:23 +02:00
Jonas Kvinge
c7ce23239f Disable gstwasapi2 in nsi 2022-04-07 23:18:08 +02:00
Jonas Kvinge
79115f7439 Update README and issue template 2022-04-07 01:22:21 +02:00
Jonas Kvinge
4457103672 Add pcre2 to nsi for MSVC 2022-04-06 23:23:20 +02:00
Jonas Kvinge
d204875f72 globalshortcut-x11: Fix minor code issues 2022-04-06 21:22:10 +02:00
Strawbs Bot
c690e73b1a Update translations 2022-04-05 01:02:10 +02:00
Jonas Kvinge
b5d39c5f21 Context: Remove use of custom font
Fixes #932
2022-04-04 20:26:38 +02:00
Strawbs Bot
7f8834cb04 Update translations 2022-04-04 01:02:50 +02:00
Jonas Kvinge
0dab7e293c GstEngine: Append "2" to wasapi2sink output description 2022-04-02 01:37:43 +02:00
Jonas Kvinge
8f016880af globalshortcut-win: Register 0-9 as num keys too 2022-04-02 00:43:41 +02:00
Jonas Kvinge
f471462a84 AnalyzerBase: Refactor code 2022-04-01 22:30:22 +02:00
Strawbs Bot
58eec8df1e Update translations 2022-03-30 01:02:21 +02:00
Jonas Kvinge
2655b8b43a TagReaderTagLib: Replace use of QByteArray::count() 2022-03-29 01:43:07 +02:00
Jonas Kvinge
ea86c043a4 AlsaPCMDeviceFinder: Fix use of deleted memory 2022-03-29 01:23:35 +02:00
Strawbs Bot
c1faa616bc Update translations 2022-03-29 01:04:21 +02:00
Strawbs Bot
a68bf5a30d Update translations 2022-03-28 01:02:14 +02:00
Jonas Kvinge
9568b8e0e5 Add hls to nsi 2022-03-28 00:34:20 +02:00
Jonas Kvinge
b34321ef87 GlobalShortcutsManager: Translate shortcuts
Fixes #928
2022-03-27 14:31:58 +02:00
Strawbs Bot
4971f1c5bf Update translations 2022-03-27 01:04:49 +01:00
Maxime Haselbauer
962b52bd5b Add save all playlists action 2022-03-26 22:38:21 +01:00
Jonas Kvinge
9449bfa414 Update protobuf in nsi 2022-03-26 21:02:56 +01:00
Strawbs Bot
5b8e9066c6 Update translations 2022-03-26 01:03:00 +01:00
Jonas Kvinge
8690be7fd2 Use separate sparkle feed for mingw and msvc 2022-03-25 21:38:37 +01:00
Jonas Kvinge
497267016b Turn on git revision 2022-03-25 01:22:31 +01:00
Jonas Kvinge
0468f850c2 Release 1.0.3 2022-03-24 21:23:36 +01:00
Jonas Kvinge
b9e7d4e30c Update Changelog 2022-03-24 21:21:24 +01:00
Jonas Kvinge
0e7734b555 Update README.md 2022-03-24 20:32:50 +01:00
Jonas Kvinge
e81dcce5b3 Update nsi for msvc dependencies 2022-03-23 19:13:40 +01:00
Strawbs Bot
38bd1f7e1c Update translations 2022-03-23 01:16:48 +01:00
Jonas Kvinge
36ad9704a2 Update libspeex for msvc in nsi 2022-03-22 21:24:54 +01:00
Jonas Kvinge
a6c05df362 Formatting 2022-03-22 21:19:59 +01:00
Jonas Kvinge
f6b70fda71 Formatting 2022-03-22 21:09:05 +01:00
Jonas Kvinge
8cb4e75f70 Update nsi for msvc dependencies 2022-03-22 17:32:49 +01:00
Jonas Kvinge
da1815ac2b Qobuz: Fix albums request limited to 50 albums
Fixes #922
2022-03-21 21:54:27 +01:00
Jonas Kvinge
f7357f2d10 Add libbrotlienc.dll to nsi 2022-03-21 21:30:33 +01:00
Jonas Kvinge
d9c92c5ddd CI: Use new MSVC dependencies 2022-03-21 18:37:31 +01:00
Jonas Kvinge
c82bdb6405 Add musepack, bs2b, faac and faad to nsi for msvc 2022-03-19 20:15:56 +01:00
Jonas Kvinge
eec8ee5830 Add qtsparkle for msvc in nsi 2022-03-17 14:46:12 +01:00
Strawbs Bot
e67eb3c0d8 Update translations 2022-03-17 01:02:02 +01:00
Jonas Kvinge
9c101759f6 CI: Update CI for MSVC dependencies 2022-03-17 00:06:18 +01:00
Jonas Kvinge
a55ee92590 Update nsi for MSVC library changes 2022-03-17 00:05:27 +01:00
Jonas Kvinge
5ccfc97dab Database: Fix schema update with Windows line-endings 2022-03-17 00:04:12 +01:00
Jonas Kvinge
d6dd88ec3d Add registry inetc plugin to nsi 2022-03-14 22:13:14 +01:00
Strawbs Bot
8557d83599 Update translations 2022-03-13 01:02:01 +01:00
Jonas Kvinge
94cf1f8698 macdeployqt: Remove optional plugins 2022-03-11 20:45:15 +01:00
Strawbs Bot
9ada35c3a3 Update translations 2022-03-11 01:03:01 +01:00
Jonas Kvinge
79b0c906fa CI: Fix path to gst-plugin-scanner for macOS 2022-03-10 22:14:51 +01:00
Jonas Kvinge
a0688f1dba CI: Fix path to gst-plugin-scanner for macOS 2022-03-10 21:09:12 +01:00
Jonas Kvinge
f91e8fecee CI: Reduce installed macports packages 2022-03-10 16:24:01 +01:00
Jonas Kvinge
1b363babe2 Use our own macOS dependencies 2022-03-10 15:51:07 +01:00
Jonas Kvinge
73843cb54d Switch back to libsoup 2 in nsi
libsoup 3.0 currently has issues with gstreamer
2022-03-08 21:53:10 +01:00
Jonas Kvinge
a2ccfc2116 Add libgioopenssl.dll to nsi 2022-03-07 22:32:50 +01:00
Jonas Kvinge
fe104e2bad Update gstreamer plugins in nsi 2022-03-07 19:28:38 +01:00
Jonas Kvinge
35e3e9f4ff RPM spec: Update release for OpenMandriva 2022-03-06 14:05:07 +01:00
Jonas Kvinge
b2a1cd9716 CI: Add openSUSE Leap 15.4 2022-03-05 21:26:51 +01:00
Jonas Kvinge
14f58eae4b CI: Add Fedora 36 2022-03-05 21:26:24 +01:00
Jonas Kvinge
5cec000618 Add fdk-aac to nsi 2022-03-05 12:15:48 +01:00
Jonas Kvinge
4805a5287d CI: Remove Ubuntu Hirsute 2022-03-05 03:27:09 +01:00
Jonas Kvinge
4789dc5b30 Add bs2b to nsi 2022-03-05 01:55:05 +01:00
Jonas Kvinge
5a35099043 Add support for bs2b
Improve headphone listening of stereo audio records
2022-03-05 01:30:49 +01:00
Strawbs Bot
4cd0128919 Update translations 2022-03-02 01:02:32 +01:00
Jonas Kvinge
61e9b80f67 Song: Remove playlists from accepted file extensions
Fixes #909
2022-03-01 21:26:08 +01:00
Strawbs Bot
dcd881ba6c Update translations 2022-02-23 01:02:20 +01:00
Strawbs Bot
d40a67ce68 Update translations 2022-02-22 01:02:35 +01:00
Jonas Kvinge
1c1e7ca62a nsi: Move libmpg123-0.dll to common files 2022-02-21 20:47:11 +01:00
Jonas Kvinge
d3831d511b nsi: Move libmpg123-0.dll to common files 2022-02-21 20:45:26 +01:00
Jonas Kvinge
0942e93144 Add mpg123 plugin to nsi 2022-02-21 20:33:10 +01:00
Jonas Kvinge
98d3eba8e8 AlbumCoverLoader: Use char for QString::remove() 2022-02-21 20:22:47 +01:00
Jonas Kvinge
ff3db03696 AlbumCoverLoader: Remove slash and backslash from cover filename
Fixes #903
2022-02-21 20:21:06 +01:00
Strawbs Bot
3608c31d22 Update translations 2022-02-21 01:03:09 +01:00
Jonas Kvinge
8d504d9cee Turn on git revision 2022-02-20 21:47:24 +01:00
Jonas Kvinge
782921f6e0 Release 1.0.2 2022-02-20 16:58:08 +01:00
Jonas Kvinge
0694aabb45 Update Changelog 2022-02-20 16:57:20 +01:00
Jonas Kvinge
604b35dfde Update 3rdparty/README.md 2022-02-17 22:14:05 +01:00
Strawbs Bot
4c308bf5d0 Update translations 2022-02-17 01:03:19 +01:00
Jonas Kvinge
7a53ca7f8e Scrobbler: Add extra submit delay on error
Fixes #898
2022-02-16 17:46:40 +01:00
Jonas Kvinge
7c51f04140 Update Changelog 2022-02-15 23:33:09 +01:00
Jonas Kvinge
488b326e0f globalshortcut-x11: Use XDefaultRootWindow with Qt >= 6.2 2022-02-14 22:50:28 +01:00
Strawbs Bot
1e0c0a35ba Update translations 2022-02-13 01:01:50 +01:00
Jonas Kvinge
bf044c1ccc CI: Switch to OpenMandriva Lx 4.2 2022-02-11 23:05:24 +01:00
Jonas Kvinge
c9caa7f034 Mpris2: Fix incorrect rounding when setting volume
Fixes #894
2022-02-11 20:26:41 +01:00
Jonas Kvinge
1b8966b3a4 globalshortcut-x11: Use private header for accessing app root window
QX11Application Currently lacks a method for this.

Fixes #893
2022-02-11 02:32:19 +01:00
Jonas Kvinge
01d4d404c0 globalshortcut-x11: Formatting 2022-02-11 02:32:09 +01:00
Jonas Kvinge
354bbf820f globalshortcut-x11: Drop use of variable for display 2022-02-11 02:31:45 +01:00
Strawbs Bot
7620f9ebbe Update translations 2022-02-09 01:04:47 +01:00
Jonas Kvinge
9c2c668a04 Add MSVC builder to CI 2022-02-08 23:22:50 +01:00
Jonas Kvinge
b6f5a5712b QobuzRequest: Fix setting composer and performer
Fixes #891
2022-02-08 21:28:11 +01:00
Jonas Kvinge
9e9df6eb16 Remove Fedora 36 2022-02-08 20:36:56 +01:00
Jonas Kvinge
f510c993a6 Remove openSUSE Leap 15.4 2022-02-08 20:36:20 +01:00
Jonas Kvinge
8ddcbaac27 Update nsi 2022-02-08 16:33:39 +01:00
Jonas Kvinge
3fcab72900 Change debug to uppercase in nsi 2022-02-07 23:55:49 +01:00
Jonas Kvinge
70aa2233e2 Change path to lockedlist in nsi 2022-02-07 23:46:24 +01:00
Jonas Kvinge
8123a2924d Update .gitignore 2022-02-07 22:46:01 +01:00
Jonas Kvinge
dd3c308b09 Only include qtsparkle directories when HAVE_QTSPARKLE is set 2022-02-07 21:17:36 +01:00
Jonas Kvinge
e56ca2ffd6 Update nsi for MSVC builds 2022-02-07 20:56:32 +01:00
Strawbs Bot
57c98c363c Update translations 2022-02-07 01:02:46 +01:00
Jonas Kvinge
2211508061 Transcoder: Use g_free 2022-02-06 18:47:23 +01:00
Jonas Kvinge
848e41919d SongLoader: Use g_free 2022-02-06 18:46:59 +01:00
Jonas Kvinge
dac613a8bb MoodbarPipeline: Use g_free 2022-02-06 18:37:11 +01:00
Jonas Kvinge
a1735278df Add 3rdparty getopt for MSVC 2022-02-06 17:29:07 +01:00
Jonas Kvinge
3730bd04a4 Add protobuf include dirs 2022-02-06 08:41:05 +01:00
Jonas Kvinge
eee3445d2f Silence some conversion warnings 2022-02-06 04:19:45 +01:00
Jonas Kvinge
8bf473dc3a SingleApplication: Simplify code 2022-02-06 04:18:59 +01:00
Jonas Kvinge
e106dda794 SingleApplication: Make const 2022-02-06 04:18:40 +01:00
Jonas Kvinge
fc35d2a35c Collection: Add I/O priority and thread priority to initialization list 2022-02-06 04:14:02 +01:00
Strawbs Bot
aef9ff0d38 Update translations 2022-02-06 01:03:48 +01:00
Jonas Kvinge
192fb46d1d Use deleteLater() for Subsonic, Tidal and QObuz requests 2022-02-06 00:58:50 +01:00
Jonas Kvinge
1dd4eb05f2 Update SingleApplication 2022-02-06 00:07:15 +01:00
Jonas Kvinge
79f0c494fa Update Changelog 2022-02-05 19:37:32 +01:00
Jonas Kvinge
7caeb47637 GstEnginePipeline: Use std::shared_ptr with deleteLater() for fader timeline
Fixes #890
2022-02-05 19:33:21 +01:00
Jonas Kvinge
ffef339ebd TrackSliderSlider: Fix compile with Qt 5 2022-02-05 19:06:58 +01:00
Jonas Kvinge
817153b20b SingleApplication: Remove use of deprecated QCryptographicHash::addData 2022-02-05 18:58:43 +01:00
Jonas Kvinge
686eb2e786 TrackSliderSlider: Use different constructor for QMouseEvent 2022-02-05 18:54:00 +01:00
Jonas Kvinge
53d5192477 Allow deleting CUE songs 2022-02-05 15:56:18 +01:00
Strawbs Bot
a172f5fe85 Update translations 2022-02-05 01:02:55 +01:00
Jonas Kvinge
288408795b Disable open audio CD menu when compiled without audio CD support 2022-02-04 19:45:30 +01:00
Jonas Kvinge
4b5a811b08 CI: Copy libsoup-3.0-0.dll 2022-02-04 19:09:53 +01:00
Jonas Kvinge
c1259d8b6e EditTagDialog: Add scrollarea
Fixes #888
2022-02-04 19:08:04 +01:00
Jonas Kvinge
3acbe431f7 Replace non-translated characters with underscore 2022-02-04 19:07:15 +01:00
Jonas Kvinge
40f381257d Use libsoup3 in nsi 2022-02-04 01:36:17 +01:00
Strawbs Bot
beec983f21 Update translations 2022-02-04 01:01:49 +01:00
Strawbs Bot
d20750012e Update translations 2022-01-31 01:21:46 +01:00
Jonas Kvinge
e31c9d74fa Add advanced settings for configuring collection watcher 2022-01-30 04:24:33 +01:00
Jonas Kvinge
78adc388df SubsonicRequest: Make sure covers are only requested once per cover ID
Fixes #885
2022-01-30 02:30:51 +01:00
Jonas Kvinge
609413cda4 SubsonicRequest: Fix requesting album covers 2022-01-30 01:56:29 +01:00
Jonas Kvinge
63e5d6a94a Require Qt 5.9 2022-01-29 21:33:33 +01:00
Jonas Kvinge
fd5970b647 Player: Don't set volume lower than 0 or higher than 100.
Fixes #884
2022-01-29 20:32:33 +01:00
Strawbs Bot
af38b8f92b Update translations 2022-01-29 01:32:04 +01:00
Jonas Kvinge
e676e65f9e Update Changelog 2022-01-29 00:31:28 +01:00
Jonas Kvinge
4c479301ff Register MtpConnection as metatype
Fixes:

```
00:13:02.210 WARN  unknown                          QObject::connect: Cannot queue arguments of type 'MtpConnection*'
00:13:02.210 WARN  unknown                          (Make sure 'MtpConnection*' is registered using qRegisterMetaType().)
```
2022-01-29 00:17:37 +01:00
Jonas Kvinge
98178947ae GioLister: Use nullptr 2022-01-29 00:07:00 +01:00
Jonas Kvinge
0dbf3b462b CollectionWatcher: Remove broken nomedia/nomusic handling
It causes songs to be stuck when adding a nomedia file to an existing
directory.
2022-01-28 23:56:10 +01:00
Jonas Kvinge
cd9f8b569b CollectionWatcher: Ignore temp files 2022-01-28 23:53:58 +01:00
Jonas Kvinge
6b23728efa Fix deleting songs from filesystemdevices 2022-01-28 23:32:49 +01:00
Jonas Kvinge
ff0f7ee483 SubsonicSettingsPage: Remove insecure from hex description 2022-01-28 22:35:58 +01:00
Jonas Kvinge
74498c3ac9 Remove remaining sparkle integration 2022-01-28 21:26:37 +01:00
Jonas Kvinge
7a61e740e8 Subsonic: Add button to delete songs
Fixes #883
2022-01-28 21:26:28 +01:00
Enrique Garcia
81e6b55c39 subsonic configuration: use the entered password when clicking Test 2022-01-22 14:11:37 +01:00
Jonas Kvinge
e439ac0e0e Update to ffmpeg 5 in nsi 2022-01-19 21:20:51 +01:00
Jonas Kvinge
7b9d784a64 AnalyzerBase: Remove obsolete code 2022-01-17 22:45:19 +01:00
Jonas Kvinge
56b2630a1c Fix QToolButton stylesheet for Qt 5 2022-01-16 17:53:57 +01:00
Strawbs Bot
6d5597a732 Update translations 2022-01-16 01:03:01 +01:00
Jonas Kvinge
c0a9345358 Add OpenMandriva to CI 2022-01-15 19:47:43 +01:00
Jonas Kvinge
2e4ad81fff Fix copying sparkle 2022-01-15 14:50:33 +01:00
Jonas Kvinge
1aad85a4f9 Add openmandriva support to rpm spec 2022-01-15 14:43:06 +01:00
Jonas Kvinge
fbd2993239 Remove use of sparkle 2022-01-15 02:24:48 +01:00
Jonas Kvinge
203228bd05 Remove use of brew install --cask 2022-01-15 02:20:54 +01:00
Strawbs Bot
da7edebe90 Update translations 2022-01-15 01:03:39 +01:00
Jonas Kvinge
c7444a189e Replace SUUpdater with SPUStandardUpdaterController 2022-01-15 00:04:21 +01:00
Jonas Kvinge
29235c5fa6 Update stylesheet to use property name for popupMode on QToolButton 2022-01-14 23:25:36 +01:00
Strawbs Bot
bf8374ff9f Update translations 2022-01-14 01:01:58 +01:00
Strawbs Bot
ba05e85e48 Update translations 2022-01-12 01:35:28 +01:00
WGH
a9aab0702c GIOLister: ignore system mounts as defined by GIO
Strawberry has some heuristics to exclude things
like the root mount, /boot, tmpfs, etc. from the devices list.

However, it's somewhat incomplete. GIO (GLib component)
has more complete definition of "internal system mounts"
that should not be presented to the user.

Additionally, don't try to query filesystems free/total size
if it's internal, as that triggers automounting for autofs
filesystems (#410).
2022-01-11 18:05:09 +01:00
Strawbs Bot
b5cf83d501 Update translations 2022-01-11 01:02:44 +01:00
Jonas Kvinge
1cc2e6303a Show menu when clicking icon for collection and internet search tool buttons 2022-01-10 22:51:27 +01:00
Jonas Kvinge
4509a07fff Add openSUSE Leap 15.4 2022-01-09 12:19:13 +01:00
Jonas Kvinge
ea419f6d40 Add Ubuntu Jammy 2022-01-09 03:26:33 +01:00
Jonas Kvinge
c9b6707468 Add Debian Bookworm 2022-01-09 03:26:33 +01:00
Jonas Kvinge
cf512a35a7 Add Fedora 36 2022-01-09 03:26:33 +01:00
Strawbs Bot
bdd3e5343d Update translations 2022-01-09 01:02:36 +01:00
Jonas Kvinge
80fd8cd338 Log Qt version on startup 2022-01-08 21:33:14 +01:00
Jonas Kvinge
eb48592083 Turn on git revision 2022-01-08 21:33:06 +01:00
Jonas Kvinge
a45cb25002 Release 1.0.1 2022-01-08 15:20:32 +01:00
Jonas Kvinge
21ec116769 Update Changelog 2022-01-08 14:42:53 +01:00
Jonas Kvinge
1d4775a94b Simplify stylesheet on QToolButton 2022-01-08 13:18:54 +01:00
Jonas Kvinge
4cde9a7e9e Fix padding on toolbuttons with menu button popup
Fixes #795
2022-01-08 13:10:48 +01:00
Jonas Kvinge
709ba72777 CollectionWatcher: Exclude hidden files 2022-01-07 21:16:38 +01:00
Strawbs Bot
0e56b8c575 Update translations 2022-01-07 01:05:42 +01:00
Jonas Kvinge
558a087e37 CollectionWatcher: Resume collection scan when adding directory 2022-01-06 23:29:20 +01:00
Jonas Kvinge
7d96fe8b65 CollectionWatcher: Abort collection scan on exit 2022-01-06 23:14:10 +01:00
Jonas Kvinge
2f3e8986ab AlbumCoverChoiceController: Clear manually set cover when setting embedded cover
Possible fix for #858
2022-01-06 02:14:33 +01:00
Strawbs Bot
df359ba0fa Update translations 2022-01-06 01:09:25 +01:00
Jonas Kvinge
31fa60884f Tagreader: Fix comment 2022-01-06 00:08:48 +01:00
Jonas Kvinge
15be227920 TagReader: Various fixes to embedded cover handling
- Add support for saving embedded for Opus
- Fix deleting cover for Ogg Vorbis, Opus and Speex
- Don't load empty covers
2022-01-06 00:06:20 +01:00
Jonas Kvinge
fdedfd54c7 Moodbar: Disable moodbar loader for CUE songs 2022-01-05 18:59:14 +01:00
Strawbs Bot
7d55eb4b44 Update translations 2022-01-03 12:42:15 +01:00
Jonas Kvinge
61ac7ae31e GeniusLyricsProvider: Move index past start tag 2022-01-02 21:47:16 +01:00
Jonas Kvinge
353e141036 Add Qt 5 warning 2022-01-02 14:48:45 +01:00
Jonas Kvinge
cb4332842f Save MP4 tags as UTF-8
Fixes #830
2022-01-02 02:47:42 +01:00
Jonas Kvinge
004d219c97 CollectionWatcher: Fix notify on path change, improve debug output
Possible fix for #860
2022-01-01 01:32:41 +01:00
Jonas Kvinge
94561e6815 Windows: Include ibgstxingmux.dll in installer 2021-12-27 18:12:55 +01:00
Jonas Kvinge
ce3af4961b GeniusLyricsProvider: Fix parsing of different HTML pages 2021-12-19 20:59:38 +01:00
Jonas Kvinge
bbd81e7d9c kglobalaccel: Attempt to register media shortcuts too 2021-12-18 20:18:37 +01:00
Jonas Kvinge
8b1d198efd Remove unused Avahi 2021-12-18 19:46:23 +01:00
Jonas Kvinge
7a3bafc961 Add Tumbleweed to CI 2021-12-18 13:00:33 +01:00
Jonas Kvinge
512eed9b04 Remove CMake release config from strawberry.spec 2021-12-14 22:16:44 +01:00
Strawbs Bot
38adf640e9 Update translations 2021-12-13 01:02:34 +01:00
Jonas Kvinge
f4d8d73970 Always save metadata in playlist for Tidal, Qobuz and Subsonic songs
Fixes #851
2021-12-12 01:43:46 +01:00
Strawbs Bot
5a50285dee Update translations 2021-12-08 12:29:11 +01:00
Jonas Kvinge
ca4ea0719f Playlist: Fix updating summary after reloading items
Fixes #848
2021-12-08 01:35:49 +01:00
Strawbs Bot
4c6251bf28 Update translations 2021-11-29 01:02:44 +01:00
Alexey Vazhnov
22c12c7366 Add dist/scripts/import-from-clementine.sh
Shell script for importing database from Clementine.

Fixes #838
Fixes #248
2021-11-28 13:14:45 +01:00
Jonas Kvinge
8f49d1591f Support more CUE filenames
Fixes #835
2021-11-27 20:28:00 +01:00
Jonas Kvinge
a97dbab2ae CollectionWatcher: Rename fileinfo variable 2021-11-27 19:25:25 +01:00
Jonas Kvinge
4cb8261d3b CueParser: Fix parsing tracks with 1-digit minutes
Fixes #836
2021-11-27 18:15:03 +01:00
Strawbs Bot
059e2d740f Update translations 2021-11-22 01:02:26 +01:00
Strawbs Bot
587d1c9d74 Add Spanish (Mexico) 2021-11-20 17:28:02 +01:00
Strawbs Bot
ab56c96170 Add Spanish (Argentina) 2021-11-20 17:27:23 +01:00
Strawbs Bot
efa4270429 Add Spanish/Spain 2021-11-20 17:14:43 +01:00
Strawbs Bot
0fbe5d888a Update translations 2021-11-13 01:02:59 +01:00
Strawbs Bot
b68f81179e Update translations 2021-11-11 01:05:36 +01:00
Jonas Kvinge
6a8c1af5f9 GstEnginePipeline: Set port-pattern for jackaudiosink 2021-11-11 00:58:00 +01:00
Jonas Kvinge
98f287559b GstEngine: Allow custom device for jackaudiosink 2021-11-11 00:58:00 +01:00
Strawbs Bot
1a53d85f6a Update translations 2021-11-10 01:19:03 +01:00
Jonas Kvinge
05b168aa04 Fix incorrect playlist column filesize for streams 2021-11-09 21:16:44 +01:00
Jonas Kvinge
a68d856074 AlbumCoverLoader: Change ID to quint64 2021-11-09 20:48:43 +01:00
Jonas Kvinge
d5dac9c6cc Add musicbrainz icon 2021-11-09 20:07:48 +01:00
Adam Hill
e9f7f42c03 PlaylistView: Fix for currenttrack_bar blocky rendering 2021-11-09 19:45:41 +01:00
Uint
7b8265d4a3 Prevent filtering when filter toolbar is hidden, clear when disabled 2021-11-09 19:41:23 +01:00
Jonas Kvinge
5715f4c2cb Remove use of macros in Song and TagReader 2021-11-09 19:34:43 +01:00
Jonas Kvinge
350debb66c Utilities: Add static_cast in Hmac() 2021-11-09 19:34:43 +01:00
Jonas Kvinge
267cd3660b InternetSearchSortModel: Replace use of macro 2021-11-09 19:34:43 +01:00
Jonas Kvinge
bc1c0c3c6d SqlQuery: Add more BindValue methods 2021-11-09 19:34:43 +01:00
Jonas Kvinge
c420f69da8 SqlRow: Replace class with a new that takes values by column field name 2021-11-09 19:34:43 +01:00
Jonas Kvinge
2151d96303 Use PlaylistItemList 2021-11-09 19:34:43 +01:00
Jonas Kvinge
c48c65d0ce InternetService: Change parameters to const 2021-11-09 19:34:43 +01:00
Jonas Kvinge
1c0b706b94 TranscoderOptionsVorbis: Remove use of macros 2021-11-09 19:34:43 +01:00
Jonas Kvinge
2dca3d6f5a gstfastspectrum: Remove some macros 2021-11-09 19:34:43 +01:00
Jonas Kvinge
0992636f8c playlistparsers: Change qt_endl macro to constexpr 2021-11-09 19:34:43 +01:00
Jonas Kvinge
86d3f2b4ed SliderSlider: Remove unused macros 2021-11-09 19:34:43 +01:00
Jonas Kvinge
b78b4038f6 InternetService: Fix overloaded signal 2021-11-09 19:34:43 +01:00
Jonas Kvinge
84c14349dc ContextAlbumsModel: Remove unused SqlRow 2021-11-09 19:34:43 +01:00
Strawbs Bot
9916e34006 Update translations 2021-11-09 01:05:40 +01:00
Jonas Kvinge
a729b42e5d Tidal: Fix reading keyId 2021-11-08 20:44:12 +01:00
Jonas Kvinge
01f8129ed0 Improve URL handler, return error for encrypted Tidal streams 2021-11-08 20:25:22 +01:00
Jonas Kvinge
fd85763fb4 Tidal: Make sure OAuth is enabled when sending access token 2021-11-08 19:47:17 +01:00
Jonas Kvinge
c278ffe2cb CI: Remove Windows Qt 5 builder 2021-11-05 21:41:30 +01:00
Jonas Kvinge
902c76a781 Remove Qt 5 support from Windows nsi 2021-11-05 21:38:09 +01:00
Jonas Kvinge
4daed0070a WorkerPool: Add missing config.h include 2021-11-04 00:42:49 +01:00
Jonas Kvinge
a4d055b3ac Remove obsolete cmake version check 2021-11-04 00:05:06 +01:00
Jonas Kvinge
e6ae6c6f04 Remove Fedora 33 2021-11-03 22:11:17 +01:00
Jonas Kvinge
de54ceeb40 Add Fedora 35 to CI 2021-11-03 21:21:12 +01:00
Strawbs Bot
77fe00df30 Update translations 2021-11-03 01:02:23 +01:00
Strawbs Bot
4ae3e63dea Update translations 2021-11-01 01:20:05 +01:00
Jonas Kvinge
3329839dbe CollectionWatcher: Add overwrite_rating_ to initialization list 2021-10-31 23:26:22 +01:00
Jonas Kvinge
ca10920bb5 Add option for overwriting database rating 2021-10-31 23:24:32 +01:00
Jonas Kvinge
b41957ce5c Add back css style for QToolButton only on macOS
Fixes #819
2021-10-31 16:55:33 +01:00
Jonas Kvinge
3db6699018 WorkerPool: Use variable 2021-10-31 14:48:42 +01:00
Jonas Kvinge
5284ca90ef Forward messages from tagreader worker process on Windows 2021-10-31 13:51:23 +01:00
Jonas Kvinge
628cdff4fa TagReaderTagParser: Return false from SaveSongPlaycountToFile 2021-10-31 13:19:52 +01:00
Jonas Kvinge
af0c6f9233 Logging: Use stdout unless critical or fatal, and flush stream 2021-10-31 13:18:26 +01:00
Jonas Kvinge
7697bbfa4e Logging: Formatting 2021-10-31 13:18:26 +01:00
buckmelanoma
642a455a9c Add icon mappings for download and scrobble
Adds mappings for download (Cover Manager) and scrobble (Import data from last.fm):
2021-10-31 02:23:15 +01:00
Strawbs Bot
6abfa2859b Update translations 2021-10-31 01:20:21 +02:00
buckmelanoma
20c2225d8f Add icon names for missing Tools menu entries
I noticed the abort_collection_scan and console menu entries were missing matching icons.  This change adds appropriate icons for each action.
2021-10-31 00:37:57 +02:00
Jonas Kvinge
5e7759b697 Utilities: Change return type for GetThreadId and SetThreadIOPriority to long 2021-10-31 00:26:02 +02:00
Jonas Kvinge
1ce8d2b31d RadioView: Remove overloaded signal 2021-10-31 00:24:16 +02:00
Jonas Kvinge
9fbecb5af6 macdeployqt: Use static QFile::exists() 2021-10-30 19:23:08 +02:00
Jonas Kvinge
1223469be9 Song: Add playcount and rating to Song::IsMetadataEqual() 2021-10-30 19:06:46 +02:00
Jonas Kvinge
5eae3ddd8a Use float for rating 2021-10-30 18:53:14 +02:00
Jonas Kvinge
3d0b6e6ea1 TagReader: Check for valid file times
Fixes #815
2021-10-30 17:57:13 +02:00
Jonas Kvinge
c6c53548ac GstEnginePipeline: Return true from BusCallback 2021-10-30 17:55:18 +02:00
Jonas Kvinge
3efe2d1e05 Initialize to 0 2021-10-30 17:10:05 +02:00
buckmelanoma
7c87b53517 PlaylistView: Use SmoothPixmapTransform when drawing play icon
Fixes #794
2021-10-30 03:36:17 +02:00
Jonas Kvinge
a461c97bcf IconLoader: Log when icon fails to load 2021-10-30 03:34:52 +02:00
Jonas Kvinge
67a6d6c1e3 LyricsFetcher: Change request ID to quint64 2021-10-30 03:15:03 +02:00
Jonas Kvinge
8b8e427a2b DeleteFiles: Fix compile with older Qt versions 2021-10-30 03:13:55 +02:00
Jonas Kvinge
7d5c263ab2 FHT: Change to static_cast double 2021-10-30 03:13:12 +02:00
Jonas Kvinge
79ac53b2d9 Fix narrowing conversions 2021-10-30 02:21:29 +02:00
Jonas Kvinge
a704412dee ContextAlbumsModel: Use const_iterator 2021-10-30 02:05:55 +02:00
Jonas Kvinge
24e2338769 ScrobblingAPI20: Add clazy:exclude=range-loop-detach 2021-10-30 02:02:37 +02:00
Jonas Kvinge
bc240f82ef SomaFMService: Add clazy:exclude=function-args-by-ref 2021-10-30 02:01:48 +02:00
Jonas Kvinge
a2ad68406d RadioView: Add clazy:exclude=reserve-candidates 2021-10-30 02:01:14 +02:00
Jonas Kvinge
3d807d2331 FilterParser: Add iter_ and end_ to initialization list 2021-10-30 02:00:26 +02:00
Jonas Kvinge
e6a7b484ba OSDBase: Remove redundant initialization 2021-10-30 01:59:51 +02:00
Jonas Kvinge
a62371829f Add ui_ to initialization list 2021-10-30 01:58:47 +02:00
Jonas Kvinge
fb98336713 Udisks2Lister: Remove redundant initialization 2021-10-30 01:58:01 +02:00
Jonas Kvinge
ebadb4db0a Use const_iterator 2021-10-30 01:57:12 +02:00
Jonas Kvinge
9a480eb710 SqlQuery: Make QSqlDatabase parameter const reference 2021-10-30 01:33:16 +02:00
Jonas Kvinge
03ecde8b83 Add default to switch 2021-10-30 01:08:35 +02:00
Strawbs Bot
0291b78bfa Update translations 2021-10-30 01:02:38 +02:00
Jonas Kvinge
377e6fad25 gstmoodbar: Formatting 2021-10-30 00:48:58 +02:00
Jonas Kvinge
e75c955a68 mac_startup: Remove unused functions 2021-10-30 00:48:58 +02:00
buckmelanoma
6df356327d Add 2px of padding for edit-clear icon
edit-clear icon tends to sit on left side of frame.  adding 2 px makes it look nicer.
2021-10-29 17:52:43 +02:00
buckmelanoma
7a57586f90 Map edit-clear-list system icons
Use system edit-clear-list icons when enabled instead of defaulting to edit-clear-locationbar-ltr.png
2021-10-29 17:52:43 +02:00
Strawbs Bot
1e2bad270d Update translations 2021-10-29 01:02:58 +02:00
Strawbs Bot
688d983b25 Update translations 2021-10-28 01:02:41 +02:00
Jonas Kvinge
fa834a76ef ContextView: Avoid unnecessary album resize 2021-10-27 22:16:48 +02:00
Jonas Kvinge
5cb88efc38 Remove debug line 2021-10-26 23:54:27 +02:00
Jonas Kvinge
6b64c43851 TagReaderTagLib: Read FMPS_Rating for MPEG ID3v2 tag 2021-10-26 01:10:01 +02:00
Jonas Kvinge
704e6c5448 TagReaderTagLib: Use double for ratings to match Song 2021-10-26 00:24:03 +02:00
Jonas Kvinge
072d7379df TagReaderTagLib: Add checks for nullptr 2021-10-26 00:02:36 +02:00
Strawbs Bot
df1b756a43 Update translations 2021-10-25 01:13:11 +02:00
Jonas Kvinge
30269d9d95 Organize: Remove unused "mark as listened" option 2021-10-24 23:19:01 +02:00
Jonas Kvinge
d29a1de980 Allow users to select native notifications on Windows
Setting will fallback to system tray notifications which are
native notifications on Windows.
2021-10-24 23:09:20 +02:00
Jonas Kvinge
57f5ccff81 InternetSearchView: Change tool button popup mode back to InstantPopup 2021-10-24 22:05:10 +02:00
buckmelanoma
69374bfa11 Revert collection options QToolButton mode
Changing this button type fixed the arrow problem but has a side effect of making the button only clickable on the arrow portion.   #795 fixed the issue with styling on QToolButtons and ends up fixing this issue too.  Therefore the change to MenuButtonPopup should be reverted in order to restore the original functionality.
2021-10-24 20:11:27 +02:00
Jonas Kvinge
d9fd330216 Update Changelog 2021-10-24 18:32:14 +02:00
Jonas Kvinge
312f62d98f Fix stop after this track button with Qt 6
Fixes #795
2021-10-24 18:15:42 +02:00
buckmelanoma
0d408055b2 Add settings to enable/disable playlist toolbar 2021-10-24 17:04:35 +02:00
Jonas Kvinge
496ae42d72 EditTagDialog: Change return to continue in EditTagDialog::SongRated 2021-10-24 16:11:53 +02:00
Jonas Kvinge
3ab86543ad Add support for saving playcounts and ratings to tags 2021-10-24 16:08:17 +02:00
Jonas Kvinge
ce7926cfa4 Update libffi in nsi 2021-10-23 11:35:52 +02:00
Strawbs Bot
48c81b188c Update translations 2021-10-23 01:02:17 +02:00
Luna
21b241bbbe add release info 2021-10-22 23:25:19 +02:00
Luna
934d6fc267 add oars content rating 2021-10-22 23:25:19 +02:00
Luna
a0ce2daa2e add type to appdata.xml 2021-10-22 23:25:19 +02:00
Jonas Kvinge
006d77239b Update protobuf in nsi 2021-10-21 18:40:04 +02:00
Jonas Kvinge
303d31bde7 Update Windows dependencies 2021-10-19 23:56:24 +02:00
Strawbs Bot
737fbeccde Update translations 2021-10-19 01:02:20 +02:00
Jonas Kvinge
ec17dc9830 TagReaderClient: Sort functions 2021-10-18 23:15:50 +02:00
Strawbs Bot
0f710ea3be Update translations 2021-10-18 01:01:58 +02:00
Jonas Kvinge
bd4eec4527 Song: Only merge user set playcount and rating if set
Fixes #790
2021-10-18 00:39:26 +02:00
Jonas Kvinge
c78252e0d5 Add dates to Changelog
Fixes #803
2021-10-17 20:30:57 +02:00
Jonas Kvinge
b1f70982bf Make playlist column text elided
Fixes #801
2021-10-17 02:33:26 +02:00
Strawbs Bot
6128fb4f19 Update translations 2021-10-17 01:10:41 +02:00
Jonas Kvinge
ee915254e7 Song: Sort code in Song::ToProtobuf() 2021-10-17 00:34:33 +02:00
Jonas Kvinge
d835d4aae6 Add rating to Song::InitFromProtobuf and Song::ToProtobuf 2021-10-17 00:27:31 +02:00
Jonas Kvinge
5945d0ebee Read rating from tags
Fixes #790
2021-10-16 23:33:03 +02:00
Jonas Kvinge
3d3aacdcb1 InternetSearchView: Change popupmode for toolbutton to QToolButton::MenuButtonPopup 2021-10-16 22:41:14 +02:00
Jonas Kvinge
c3ce6cff72 GstEngine: Move CreateElement() to GstEnginePipeline 2021-10-16 21:28:56 +02:00
Jonas Kvinge
6d7a01fb4e Logging: Remove custom debug level for gst pipeline 2021-10-16 21:25:36 +02:00
Jonas Kvinge
8582e09e73 CI: Remove Ubuntu Groovy and add Impish 2021-10-16 14:30:45 +02:00
buckmelanoma
90744f2965 Fix filter menu button arrow overlap
Change collection filter menu button's popupMode to MenuButtonPopup to prevent arrow overlapping with button icon
2021-10-16 13:21:15 +02:00
Jonas Kvinge
03d0776fdc Turn on git revision 2021-10-15 00:02:06 +02:00
Jonas Kvinge
9d18f40c5f Release 1.0.0 2021-10-14 20:50:41 +02:00
Jonas Kvinge
47e771ee37 Update Changelog 2021-10-14 20:50:20 +02:00
Jonas Kvinge
20760dcf0e Fix FreeBSD CI 2021-10-13 19:30:46 +02:00
Strawbs Bot
2edf12e4cd Update translations 2021-10-13 01:16:38 +02:00
Jonas Kvinge
c946c1d1c4 Player: Don't preload next song while playing module music
Workaround bug in GStreamer

Fixes #787
Fixes #772
2021-10-12 22:59:23 +02:00
Jonas Kvinge
bb5fe5a6d1 Add Song::is_module_music() 2021-10-12 22:58:39 +02:00
Jonas Kvinge
814d2fa9fc MainWindow: Use Song::PrettyTitle() in debug message 2021-10-12 22:57:59 +02:00
Jonas Kvinge
10d89cb6a6 FileView: Add module music formats to file filter 2021-10-12 21:44:30 +02:00
Jonas Kvinge
a6569d09ac Read XM and IT module music 2021-10-12 21:43:46 +02:00
staticssleever668
b38ad81928 Remove use of C-style casts 2021-10-12 18:50:17 +02:00
Jonas Kvinge
637772f8f0 GstEnginePipeline: Convert S24_32LE for analyzer 2021-10-12 18:46:12 +02:00
Jonas Kvinge
0093eb6c2c GstEnginePipeline: Refactor code 2021-10-12 18:36:58 +02:00
Jonas Kvinge
f3b70d1cb2 GstEnginePipeline: Rename variable 2021-10-12 18:36:13 +02:00
Strawbs Bot
5152f57f6e Update translations 2021-10-11 01:02:01 +02:00
Jonas Kvinge
e6112a311d Add openmpt to nsi 2021-10-10 23:31:08 +02:00
Jonas Kvinge
e069d069d2 GstEngine: Remove unused variables 2021-10-10 21:12:31 +02:00
Jonas Kvinge
fd74bbc868 Remove unused GstElementDeleter 2021-10-10 16:33:07 +02:00
Strawbs Bot
3b37aea3da Update translations 2021-10-10 01:02:39 +02:00
Jonas Kvinge
2fd4bbbd49 Update Changelog 2021-10-09 22:25:27 +02:00
Jonas Kvinge
17226b524b SubsonicSettingsPage: Rename HTTP2 to HTTP/2 2021-10-09 16:38:13 +02:00
Jonas Kvinge
f38b33ee50 Scrobbler: Use seconds instead of minutes for submit delay 2021-10-09 14:05:05 +02:00
Jonas Kvinge
0da0e0a6db macdeployqt: Fix typo 2021-10-09 01:50:19 +02:00
Jonas Kvinge
de2b6d1dee macdeployqt: Replace QSet with QList 2021-10-09 01:50:19 +02:00
Jonas Kvinge
c9a501ddc8 Update README.md 2021-10-09 00:39:11 +02:00
Jonas Kvinge
c5babbbb22 Update README.md 2021-10-09 00:34:28 +02:00
Jonas Kvinge
1fd0d1a330 macdeployqt: Remove FinalCheck from header 2021-10-08 23:47:33 +02:00
Jonas Kvinge
84d9b30fec macdeployqt: Replace bearer with tls 2021-10-08 23:40:41 +02:00
Jonas Kvinge
d0f1522f0d GstEnginePipeline: Use gst_bus_remove_watch to remove bus watch 2021-10-08 23:39:29 +02:00
Jonas Kvinge
6b2e25122d nsi: Remove tls dir 2021-10-07 23:48:23 +02:00
Strawbs Bot
ce3026f91c Update translations 2021-10-06 01:02:49 +02:00
Jonas Kvinge
4b384b3b59 Update ccpp.yml 2021-10-04 11:51:16 +02:00
Strawbs Bot
da7605a234 Update translations 2021-10-03 01:08:24 +02:00
Jonas Kvinge
3abdec1b91 Add qopensslbackend.dll to nsi and CI 2021-10-01 23:52:59 +02:00
Strawbs Bot
ef34199887 Update translations 2021-10-01 01:02:14 +02:00
Jonas Kvinge
08eca88e2f Add require for qt6-network-tls to RPM spec 2021-09-30 22:54:08 +02:00
Strawbs Bot
4636cc74dc Update translations 2021-09-29 01:03:09 +02:00
Jonas Kvinge
4cc54a2f05 PlaylistTabBar: Hide star option with clicked outside of a tab 2021-09-28 22:19:31 +02:00
Jonas Kvinge
9bd728889b PlaylistTabBar: Add right click option to star playlist
Fixes #782
2021-09-28 22:14:25 +02:00
Adam Hill
d870115467 Set SmoothPixmapTransform for playing-widget and context album art display 2021-09-28 21:52:31 +02:00
Jonas Kvinge
2b445fb563 StyleSheetLoader: Cleanup code and add workaround for macOS dark theme
Fixes #778
2021-09-28 17:25:22 +02:00
Strawbs Bot
44a3bad278 Update translations 2021-09-28 01:12:34 +02:00
Jonas Kvinge
8d2615547d Add keyboard shortcut for focusing search fields
Fixes #779
2021-09-27 21:42:30 +02:00
Jonas Kvinge
3292db8b77 Add missing override 2021-09-27 21:41:45 +02:00
Jonas Kvinge
8c6ad52437 Organize: Update collection directory ID and song path immediately
Fixes #781
2021-09-27 19:30:31 +02:00
Jonas Kvinge
62e53b53f0 Replace assert with Q_ASSERT 2021-09-27 19:30:31 +02:00
Strawbs Bot
35db157617 Update translations 2021-09-27 01:22:03 +02:00
Jonas Kvinge
cfb137a94b DeviceDatabaseBackend: Fix GetAllDevices() 2021-09-26 21:38:06 +02:00
Jonas Kvinge
9b4a33a612 MPris2: Remove static 2021-09-26 20:14:11 +02:00
Jonas Kvinge
918b7c1e03 Move chrono include 2021-09-26 20:06:04 +02:00
Jonas Kvinge
8fb354705c Update Changelog 2021-09-26 19:03:01 +02:00
Jonas Kvinge
b3826064b7 Bump device schema version 2021-09-26 18:35:03 +02:00
Jonas Kvinge
acba68dab9 MergedProxyModel: Add FIXME 2021-09-26 18:34:44 +02:00
Jonas Kvinge
32ea709350 Subsonic: Turn off HTTP/2 setting by default 2021-09-26 16:50:41 +02:00
Jonas Kvinge
c15dfc7c5d Subsonic: Make HTTP/2 setting visible with Qt 5.15.0 and higher 2021-09-26 16:49:53 +02:00
Jonas Kvinge
92f6a0c6c8 Add mod and s3m to filetypes 2021-09-26 16:23:02 +02:00
Jonas Kvinge
0235be538b Moodbar: Check for nullptr 2021-09-26 14:42:24 +02:00
Jonas Kvinge
abf19e7a27 Moodbar: Use gst_element_link_many 2021-09-26 14:42:05 +02:00
Jonas Kvinge
1d3540dca6 Remove unused MoodbarPipeline::IsAvailable function 2021-09-26 14:41:36 +02:00
Jonas Kvinge
ddfc9d911b Extend unit tests 2021-09-26 01:15:17 +02:00
Strawbs Bot
b952256988 Update translations 2021-09-26 01:02:42 +02:00
Jonas Kvinge
71868936d1 Subsonic: Use common static function CreateUrl() 2021-09-25 01:18:40 +02:00
Strawbs Bot
23ef4fb132 Update translations 2021-09-22 01:04:55 +02:00
Jonas Kvinge
f74f2ca3ef Subsonic: Remove redundant null check 2021-09-21 01:36:38 +02:00
Jonas Kvinge
f4f005cdd6 Subsonic: Fix auth method for URL handler 2021-09-21 01:30:01 +02:00
Jonas Kvinge
3137652280 Use ParamList 2021-09-21 01:30:01 +02:00
Strawbs Bot
88c6f0340a Update translations 2021-09-21 01:01:57 +02:00
Strawbs Bot
86146c7292 Update translations 2021-09-20 01:20:57 +02:00
Tom Kranz
fad39b6d67 Store Tidal MPEG-DASH file in data uri 2021-09-19 19:56:22 +02:00
Jonas Kvinge
09a9330f3e Show error when reading or saving album covers 2021-09-19 19:31:34 +02:00
Jonas Kvinge
d2d7f32c45 Add new method for updating songs based on song ID
Show status updating database.

Fixes #750
2021-09-19 15:43:36 +02:00
Tom Kranz
120b18b399 Use XSPF image elements as manually set artwork 2021-09-19 13:40:42 +02:00
Jonas Kvinge
32b9e6b73d Make error dialog larger 2021-09-18 17:12:59 +02:00
Jonas Kvinge
8d6e5272b9 Update protobuf in nsi 2021-09-17 01:35:20 +02:00
Strawbs Bot
b6f90a9715 Update translations 2021-09-15 01:02:18 +02:00
Jonas Kvinge
e3d0b777fc Add algorithm include 2021-09-14 22:57:09 +02:00
Jonas Kvinge
79a8450462 SpotifyCoverProvider: Fix trying to set timer to minus value 2021-09-14 22:12:28 +02:00
EmmanuelMess
1a967597e8 Fix roundings with lround() 2021-09-14 21:29:29 +02:00
Jonas Kvinge
d5b0794b00 Remove unneeded this 2021-09-13 20:49:33 +02:00
Jonas Kvinge
d78ee3d62b Fix total playlist length for songs without length 2021-09-13 20:46:55 +02:00
Strawbs Bot
03037a9a6b Update translations 2021-09-13 01:12:16 +02:00
Emmanuel
0637b65846 Fix a few narrowing conversions (#761)
* Fix narrowing conversion in album cover loader

* Fix narrowing conversions in discogs cover provider

* Fix narrowing conversions in spotify cover provider

* Add explicit conversion in moodbarbuilder

* Fix narrowing conversions in osd dbus

* Make WordyTimeNanosec use unsigned quint64

* Fix narrowing conversions in song

* Fix narrowing conversions in qobuz stream url request

* Make ConnectionInfo.msgLen use unsigned quint64

* Make AnalizerBase.timeout to signed int

* Fix narrowing conversions in album cover fetcher

* Make fht type be unsigned int

* Correct for type in blockanalizer and use std::fill where possible

* Revert "Fix narrowing conversions in song"

This reverts commit 3de291394d.
2021-09-12 21:24:22 +02:00
Jonas Kvinge
e77e914f44 Escape ampersands in playlist tabs
Fixes #760
2021-09-12 21:19:58 +02:00
EmmanuelMess
68c44daef2 Fix SingleApplication static functions called from instance 2021-09-10 18:44:36 +02:00
Strawbs Bot
8ca0b54b18 Update translations 2021-09-10 01:21:33 +02:00
Jonas Kvinge
b77d01baca CI: Use new image for Windows build 2021-09-09 23:06:59 +02:00
Jonas Kvinge
cd509bbbdc Update nsi for OpenSSL 3 2021-09-09 22:05:53 +02:00
Jonas Kvinge
24a3ac9811 Use static QMetaObject::invokeMethod 2021-09-09 21:53:14 +02:00
Jonas Kvinge
d35d3aabc3 Show error dialog for failed SQL queries 2021-09-09 21:45:46 +02:00
Jonas Kvinge
9e624a6c0d Remove openSUSE 15.2 from CI 2021-09-07 01:16:02 +02:00
Strawbs Bot
9823cd25d2 Update translations 2021-09-07 01:01:55 +02:00
Jonas Kvinge
416a8c8f5d Context: Hide albums widget in constructor 2021-09-07 00:10:05 +02:00
Strawbs Bot
c55bdd423e Update translations 2021-09-06 01:02:08 +02:00
Jonas Kvinge
e45e202c5e Subsonic: Make network replies timeout after 30 seconds
Fixes #754
2021-09-05 21:47:00 +02:00
Jonas Kvinge
2280a30ba9 Subsonic: Minor code style fix 2021-09-05 21:46:41 +02:00
Jonas Kvinge
9ac7518156 Subsonic: Remove obsolete return 2021-09-05 21:46:16 +02:00
Jonas Kvinge
0e6dbaf71a Settings: Fix loading subsonic auth method setting 2021-09-05 21:35:21 +02:00
Strawbs Bot
fe018ff8f7 Update translations 2021-09-02 01:03:13 +02:00
Jonas Kvinge
9b01e09302 GlobalShortcutsManager: Minor code fixes 2021-09-02 00:52:44 +02:00
Jonas Kvinge
3127474fd7 GlobalShortcutsManager: Fix reading settings 2021-09-02 00:52:21 +02:00
Jonas Kvinge
b849edfcca GlobalShortcutsBackend: Fix type return 2021-09-01 22:37:08 +02:00
Jonas Kvinge
20a23c2868 Various cleanup to global shortcuts code 2021-09-01 21:37:11 +02:00
Jonas Kvinge
49d9ded684 Fix null pointer crash
Possible fix for #752
2021-09-01 16:37:34 +02:00
Jonas Kvinge
fc57b437c2 Fix radio items leak 2021-08-31 22:45:28 +02:00
Jonas Kvinge
1ba20561ed Fix global shortcuts memory leak 2021-08-31 21:21:59 +02:00
Strawbs Bot
2c8b26e091 Update translations 2021-08-31 01:02:17 +02:00
Jonas Kvinge
62d2a97f38 Add make deploy to macOS CI 2021-08-30 18:13:29 +02:00
Strawbs Bot
44aa292bb5 Update translations 2021-08-30 01:02:16 +02:00
Strawbs Bot
5273b52c31 Update translations 2021-08-26 01:04:00 +02:00
Jonas Kvinge
f143efb810 Revert "Use std::as_const"
This reverts commit 0b15e29324.
2021-08-25 03:47:50 +02:00
Jonas Kvinge
978fb06349 clazy:exclude=range-loop-reference 2021-08-25 03:45:12 +02:00
Jonas Kvinge
e274e8070d Update Changelog 2021-08-25 03:19:42 +02:00
Jonas Kvinge
46bd5b42fa Use 4arg connect 2021-08-25 03:08:30 +02:00
Jonas Kvinge
0b15e29324 Use std::as_const 2021-08-25 03:00:34 +02:00
Jonas Kvinge
75b6669371 Simplify return 2021-08-25 02:58:54 +02:00
Jonas Kvinge
c1c34017e4 Remove get() 2021-08-25 02:58:20 +02:00
Jonas Kvinge
ed08818b6f Use multi-arg 2021-08-25 02:57:57 +02:00
Jonas Kvinge
71adfc0a74 Use std::chrono_literals 2021-08-25 02:57:09 +02:00
Jonas Kvinge
49ccbddb17 Add Q_DISABLE_COPY 2021-08-25 02:56:30 +02:00
Jonas Kvinge
be3c7eef60 Use default 2021-08-25 02:55:54 +02:00
Jonas Kvinge
336c6cdd9d Use 4arg connect 2021-08-25 02:55:00 +02:00
Jonas Kvinge
709a706853 Delete mimedata when returning early 2021-08-25 02:38:58 +02:00
Jonas Kvinge
dad62faf88 Use fully-qualified parameter for signal 2021-08-25 02:36:18 +02:00
Jonas Kvinge
6e0a5fb5c6 Make const 2021-08-25 02:29:05 +02:00
Jonas Kvinge
4b9551d27f Simplify if statement 2021-08-25 02:28:41 +02:00
Strawbs Bot
2a67bc9926 Update translations 2021-08-25 01:16:47 +02:00
Jonas Kvinge
d02241d32c Fix compile with MSVC 2021-08-24 21:49:06 +02:00
Strawbs Bot
55e038d345 Update translations 2021-08-24 01:08:33 +02:00
Jonas Kvinge
ea2bfbda44 Formatting 2021-08-23 21:21:08 +02:00
Jonas Kvinge
ed7794f396 macdeployqt: Replace foreach with C++11 for loop 2021-08-23 01:44:35 +02:00
Strawbs Bot
086646f311 Update translations 2021-08-23 01:02:20 +02:00
Jonas Kvinge
ad169ca5a5 Remove unneeded namespace prefix 2021-08-22 23:29:44 +02:00
Jonas Kvinge
671e636aef Remove some uses of auto 2021-08-22 23:27:25 +02:00
Jonas Kvinge
72d381e9ed Replace qAsConst with C++17 std::as_const 2021-08-22 23:26:53 +02:00
Jonas Kvinge
c076933b52 Use FREEBSD variable 2021-08-22 23:22:15 +02:00
Jonas Kvinge
fdb5c813ad Use actions/checkout@v1.2.0 for FreeBSD too 2021-08-20 22:36:44 +02:00
Strawbs Bot
1bda6633b1 Update translations 2021-08-20 01:02:15 +02:00
Jonas Kvinge
249a5bf3b7 macOS deploy CI improvements 2021-08-19 22:59:38 +02:00
Jonas Kvinge
679b468618 macdeployqt: Fix QLibraryInfo::LibraryExecutablesPath with Qt 5 2021-08-19 20:27:21 +02:00
Jonas Kvinge
cf2a0af3d9 Fix macdeploycheck link directories 2021-08-19 20:24:11 +02:00
Jonas Kvinge
82be53224d Simplify libgpod link directories 2021-08-19 20:23:20 +02:00
Jonas Kvinge
9cc995cb52 Add macdeploycheck 2021-08-19 19:17:43 +02:00
Jonas Kvinge
42d414797a macdeployqt: Formatting 2021-08-19 19:17:43 +02:00
Jonas Kvinge
b071a4df70 macdeployqt: Simplify code in changeInstallName 2021-08-19 19:17:43 +02:00
Jonas Kvinge
46d927291c macdeployqt: Adapt upstream change 2021-08-19 19:17:43 +02:00
Jonas Kvinge
50ab01d9c9 macdeployqt: Remove unused option to specify plugins dir 2021-08-19 19:17:43 +02:00
Jonas Kvinge
dc8fe63acf Add script to copy gstreamer plugins on macOS 2021-08-19 19:17:43 +02:00
Jonas Kvinge
4fc5863888 Add taglib and tagparser link directories 2021-08-19 19:17:43 +02:00
Jonas Kvinge
e2d8149dcf Formatting 2021-08-19 19:17:43 +02:00
Jonas Kvinge
5f156d6bab Only read local files in SongLoader::EffectiveSongLoad 2021-08-19 19:17:43 +02:00
Strawbs Bot
816cdcf4bf Update translations 2021-08-16 01:01:43 +02:00
Jonas Kvinge
75c94ae092 Always look for qpa/qplatformnativeinterface.h 2021-08-14 20:00:27 +02:00
Jonas Kvinge
ecf2c50a26 Use QX11Application with Qt >= 6.2, use QX11Info with Qt 5 2021-08-14 17:06:40 +02:00
Jonas Kvinge
cecb9293f6 Add QRegularExpression::CaseInsensitiveOption 2021-08-13 23:33:41 +02:00
Jonas Kvinge
1ebfa0ad7e Song::kAlbumRemoveDisc is already QRegularExpression 2021-08-13 23:32:54 +02:00
Jonas Kvinge
35c7b57308 Allow fading when a ALSA PCM device is selected 2021-08-13 22:39:34 +02:00
Strawbs Bot
36bfeffbcc Update translations 2021-08-13 01:03:08 +02:00
Jonas Kvinge
e6858719c9 Reduce network access managers 2021-08-12 23:00:42 +02:00
Strawbs Bot
f2d52f83fe Update translations 2021-08-10 01:02:54 +02:00
Jonas Kvinge
f1d3cadb3b Add better logging for file open and write errors 2021-08-09 23:32:26 +02:00
Jonas Kvinge
7d61d8e646 Replace C-style cast with reinterpret_cast 2021-08-09 23:32:09 +02:00
Jonas Kvinge
6ede400f3a CMakeLists.txt formatting 2021-08-07 03:02:36 +02:00
Strawbs Bot
78de45fee2 Update translations 2021-08-07 01:01:40 +02:00
Jonas Kvinge
4559e33331 Update .github/workflows/ccpp.yml 2021-08-01 15:32:51 +02:00
Jonas Kvinge
43875dd3fe Remove Fedora 35 from CI
It's broken.
2021-08-01 08:41:12 +02:00
Jonas Kvinge
fa10384a92 Add FreeBSD to CI 2021-08-01 08:32:50 +02:00
Strawbs Bot
7e144da6b9 Update translations 2021-07-31 01:02:51 +02:00
Jonas Kvinge
54af17e7bf Remove linker hack 2021-07-30 23:01:44 +02:00
Jonas Kvinge
d4a9f5bb2e Replace Iconv_LIBRARY with Iconv_LIBRARIES 2021-07-30 23:01:07 +02:00
Jonas Kvinge
8040813da8 Remove QUIET from find_package for Backtrace and Iconv 2021-07-30 23:00:34 +02:00
Jonas Kvinge
871e40c5c0 Update Changelog 2021-07-30 21:17:53 +02:00
Jonas Kvinge
7ce922b084 Simplify CMake by using macros 2021-07-30 21:17:50 +02:00
Jonas Kvinge
0c9989695a Subsonic: Use 500 albums per request
Fixes #740
2021-07-30 21:17:44 +02:00
Jonas Kvinge
88d7cb3ed5 Add MD5 token authentication for Subsonic 2021-07-30 21:16:41 +02:00
Strawbs Bot
5b7fc80f26 Update translations 2021-07-29 01:15:44 +02:00
Jonas Kvinge
553e8baa8b Fix async song load
Fixes #739
2021-07-28 22:25:33 +02:00
Jonas Kvinge
62a5031ccf Delay pause on resume playback 2021-07-23 21:54:46 +02:00
Jonas Kvinge
4abac65316 Properly disconnect PlaylistManager::AllPlaylistsLoaded on resume 2021-07-23 21:54:21 +02:00
Jonas Kvinge
c6e42e1032 Reset play offset when switching song while paused
Fixes #735
2021-07-23 21:32:12 +02:00
Jonas Kvinge
a353631892 Code tidy 2021-07-23 21:30:08 +02:00
Jonas Kvinge
f144c982e3 Minor CMakeLists.txt cleanup 2021-07-21 17:45:22 +02:00
Jonas Kvinge
16625b1dc7 Move some files from ext to src 2021-07-21 17:29:16 +02:00
Jonas Kvinge
78ccce7d1a Change USE_BUNDLE default 2021-07-21 17:29:16 +02:00
Strawbs Bot
ffba5f7d31 Update translations 2021-07-19 01:01:56 +02:00
Jonas Kvinge
2cb8fa62df Remove duplicate TAGLIB_LIBRARY_DIRS 2021-07-18 16:38:20 +02:00
Jonas Kvinge
853b936cdd Revert "Add sudo"
This reverts commit 4f0fdbab62.
2021-07-18 15:34:07 +02:00
Jonas Kvinge
4f0fdbab62 Add sudo 2021-07-18 15:33:13 +02:00
Jonas Kvinge
190b23b702 Fix build with macports 2021-07-18 15:23:57 +02:00
Strawbs Bot
e0bb79b2c4 Update translations 2021-07-15 01:03:31 +02:00
Jonas Kvinge
2eab763d74 Check that QIODevice::open() is successful, and explicitly call close() 2021-07-14 20:52:57 +02:00
Jonas Kvinge
f64c1dd9e5 Update Changelog 2021-07-14 13:12:20 +02:00
Jonas Kvinge
fab1d94d34 Delay resume playback on startup to make sure Tidal login is refreshed 2021-07-14 13:02:54 +02:00
Jonas Kvinge
facf49b2b7 Spotify: Decrease login delay on startup 2021-07-14 13:02:12 +02:00
Jonas Kvinge
da86b86776 Rename variable 2021-07-14 12:53:28 +02:00
Jonas Kvinge
a79d9d4e77 Move beginInsertRows() 2021-07-14 12:26:48 +02:00
Jonas Kvinge
d9e378211a Fix sorting of radios 2021-07-14 11:22:24 +02:00
Strawbs Bot
99fbbf70de Update translations 2021-07-14 01:03:06 +02:00
Jonas Kvinge
50a616457d Add missing const 2021-07-13 23:25:44 +02:00
Jonas Kvinge
2ad30ebe88 Add missing Qt::CaseInsensitive 2021-07-13 23:25:36 +02:00
Jonas Kvinge
68dbc29f2c Use QString::compare with Qt::CaseInsensitive to reduce allocations 2021-07-13 23:18:12 +02:00
Strawbs Bot
a87863229f Update translations 2021-07-13 01:07:37 +02:00
Jonas Kvinge
f39ffcb997 Simplify if condition 2021-07-12 13:45:51 +02:00
Jonas Kvinge
f20bb388be Rename variable 2021-07-12 13:27:14 +02:00
Jonas Kvinge
fc45015b13 Remove unused variable 2021-07-12 13:26:41 +02:00
Jonas Kvinge
7a5f047f8e Add parent to RadioMimeData 2021-07-12 13:26:20 +02:00
Jonas Kvinge
4251bee3ca Change some uses of QMap to QHash 2021-07-12 08:28:52 +02:00
Jonas Kvinge
f02741284c Tagparser: Fix reading and writing year/originalyear 2021-07-12 07:54:01 +02:00
Jonas Kvinge
fec7419fcc Make const 2021-07-12 07:38:49 +02:00
Jonas Kvinge
e8694531f6 Iterate QMap values 2021-07-12 07:34:20 +02:00
Jonas Kvinge
461491f742 Use multiarg 2021-07-12 07:33:40 +02:00
Jonas Kvinge
af29acf462 tagparser: Save release and record date 2021-07-12 07:32:41 +02:00
Jonas Kvinge
b47f29e87c tagparser: Parse tracks when saving 2021-07-12 07:32:17 +02:00
Jonas Kvinge
fc8ec6d7fa Replace INSTANTIATE_TEST_CASE_P with INSTANTIATE_TEST_SUITE_P 2021-07-12 05:51:01 +02:00
Jonas Kvinge
1d4c736cfa Initialize container to nullptr 2021-07-12 05:51:01 +02:00
Strawbs Bot
600450082a Update translations 2021-07-12 01:18:19 +02:00
Jonas Kvinge
c6da0864f2 Use std::make_shared 2021-07-11 19:57:18 +02:00
Jonas Kvinge
10fc6b4562 Fix tagreader test compile error with tagparser 2021-07-11 19:56:21 +02:00
Jonas Kvinge
e48b7d83a3 Formatting 2021-07-11 09:49:38 +02:00
Jonas Kvinge
a6742d401c Formatting 2021-07-11 07:40:57 +02:00
Jonas Kvinge
87b9a8c4c8 Use RadioPlaylistItem 2021-07-11 07:39:27 +02:00
Jonas Kvinge
134dc55891 Rename RadioView::SetModel 2021-07-11 05:53:10 +02:00
Jonas Kvinge
295cf98e70 Add missing override 2021-07-11 05:30:35 +02:00
Jonas Kvinge
7333155b8c Edit tab order in scrobbler settings 2021-07-11 05:23:37 +02:00
Jonas Kvinge
3960c7d8e6 Add SomaFM and Radio Paradise to scrobbler sources 2021-07-11 05:18:56 +02:00
Jonas Kvinge
b053f99690 Add Song::is_radio() 2021-07-11 05:18:39 +02:00
Jonas Kvinge
5700c3f72e Change GStreamer text 2021-07-11 05:17:45 +02:00
Jonas Kvinge
cdb3729a88 Use Song::SourceFromURL in SongLoader::AddAsRawStream 2021-07-11 05:17:17 +02:00
Jonas Kvinge
c33f2a1d27 Unref bus in SongLoader::LoadRemote() 2021-07-11 04:58:37 +02:00
Jonas Kvinge
9b9a32b053 tagparser: Fix opening file readonly 2021-07-11 04:36:44 +02:00
Jonas Kvinge
95eec369b5 Fix includes 2021-07-11 02:31:15 +02:00
Jonas Kvinge
5d5860683b Add missing includes 2021-07-11 02:29:24 +02:00
Jonas Kvinge
434b31b932 Formatting 2021-07-11 02:27:26 +02:00
Jonas Kvinge
f69e42e520 Use Q_ASSERT 2021-07-11 02:27:03 +02:00
Jonas Kvinge
c5cadfe0c6 Fix memory leak in InternetSearchView::ResultsContextMenuEvent 2021-07-11 01:52:21 +02:00
Jonas Kvinge
f21be30004 Use static QPixmapCache everywhere 2021-07-11 01:43:52 +02:00
Jonas Kvinge
b8b21d53e1 Use static QPixmapCache 2021-07-11 01:32:51 +02:00
Jonas Kvinge
09ec39c87a Remove unused functions from RadioService 2021-07-11 01:20:42 +02:00
Jonas Kvinge
dbf18db3a3 No need to pass Application to RadioBackend 2021-07-11 01:12:50 +02:00
Jonas Kvinge
d8f0ae0980 Remove unused variable 2021-07-11 01:11:25 +02:00
Jonas Kvinge
09bbf1f4d7 Add radios 2021-07-11 01:08:06 +02:00
Strawbs Bot
d07aff9872 Update translations 2021-07-11 01:02:12 +02:00
Jonas Kvinge
4cb3f9d177 Close files in song loader 2021-07-11 00:45:30 +02:00
Jonas Kvinge
c1a815778b Formatting 2021-07-10 21:52:21 +02:00
Jonas Kvinge
5b003b09ac Make CollectionBackendInterface to PlaylistParser optional 2021-07-10 21:52:01 +02:00
Jonas Kvinge
22d0697c77 Use Song::is_stream 2021-07-10 21:50:23 +02:00
Jonas Kvinge
432b0f3e54 songloader: Make sure timeout timer is started from correct thread 2021-07-10 21:48:31 +02:00
Jonas Kvinge
2bee41e90e Fix compile of Utilities::Hmac with Qt 6.3 2021-07-07 23:54:21 +02:00
Jonas Kvinge
2a7312f2b4 Fix tagreader test 2021-07-07 23:46:21 +02:00
Strawbs Bot
f5091339ad Update translations 2021-07-06 01:02:54 +02:00
Jonas Kvinge
3d06d68196 Fix broken context albums 2021-07-04 17:34:42 +02:00
Strawbs Bot
1a643bfa8c Update translations 2021-07-03 01:20:53 +02:00
Jonas Kvinge
cd82b0a669 Fix spelling and typos 2021-07-02 18:45:53 +02:00
Jonas Kvinge
57312e29e2 Build with tagparser on openSUSE 2021-07-02 11:25:02 +02:00
Jonas Kvinge
592df4819b Update Changelog 2021-07-02 02:26:34 +02:00
Jonas Kvinge
f36997c7c5 Close MediaFileInfo 2021-07-02 01:39:21 +02:00
Jonas Kvinge
b1640d3626 Remove tagparser/abstractattachment.h include 2021-07-02 01:38:56 +02:00
Jonas Kvinge
825c62c62b Fix typo in TagReaderTagLib constructor and destructor 2021-07-02 01:26:48 +02:00
Jonas Kvinge
a4b0c6f37d Remove unused QVector include 2021-07-02 01:26:32 +02:00
Jonas Kvinge
239b88aa3b Add support for TagParser as an alternative to TagLib 2021-07-02 01:16:46 +02:00
Jonas Kvinge
88819611f4 Remove TagLib dependency from Song class 2021-07-02 01:16:46 +02:00
Jonas Kvinge
e6ff8368a9 Fix filefilter 2021-07-02 01:16:46 +02:00
Jonas Kvinge
8315f572ea Remove default parameter 2021-07-02 01:16:46 +02:00
Strawbs Bot
89e2070419 Update translations 2021-07-02 01:04:47 +02:00
Jonas Kvinge
b5f4df0912 Refactor subsonic, tidal and qobuz code 2021-07-01 02:02:02 +02:00
Jonas Kvinge
b9f3f80d50 Use std::make_unique / std::make_shared 2021-07-01 02:02:02 +02:00
Jonas Kvinge
0e8ae1a206 Change to std::shared_ptr 2021-07-01 02:02:02 +02:00
Jonas Kvinge
32729174bb Make CollectionModelTest constructor public 2021-07-01 02:02:02 +02:00
Jonas Kvinge
2cf6fe8da7 Fix ConcurrentRunTest 2021-07-01 02:02:02 +02:00
Strawbs Bot
929b031f09 Update translations 2021-07-01 01:03:41 +02:00
Jonas Kvinge
57a36491ee Remove mpris.cpp and mpris.h 2021-06-30 16:26:07 +02:00
Jonas Kvinge
f3a8dde5f0 Use std::make_shared 2021-06-30 16:15:55 +02:00
Jonas Kvinge
ffa2489998 Formatting 2021-06-30 16:15:55 +02:00
Strawbs Bot
6cd7bcdae6 Update translations 2021-06-28 01:07:32 +02:00
Jonas Kvinge
e4f684f411 Change const_iterator to iterator 2021-06-28 00:27:28 +02:00
Jonas Kvinge
fdc9a71f9e Use protected kApiUrl 2021-06-28 00:21:50 +02:00
Jonas Kvinge
bb134ee7ac Rename NeedLogin to set_need_login 2021-06-28 00:21:50 +02:00
Jonas Kvinge
18dc6f3c88 Remove unused variables in InternetCollectionViewContainer 2021-06-28 00:21:50 +02:00
Jonas Kvinge
9327fd3aa1 Formatting 2021-06-28 00:21:50 +02:00
Jonas Kvinge
aa859b9002 Remove dead code 2021-06-28 00:21:50 +02:00
Jonas Kvinge
20a15ecd35 Replace while with for loop 2021-06-28 00:21:50 +02:00
Jonas Kvinge
062c59b321 Rename FindSongs 2021-06-28 00:21:50 +02:00
Jonas Kvinge
9ace66edb7 Rename CollectionFilterWidget::SetCollectionModel to CollectionFilterWidget::Init 2021-06-28 00:21:50 +02:00
Jonas Kvinge
a97d784f26 Rename filter to search_field 2021-06-28 00:21:50 +02:00
Jonas Kvinge
a2e7173983 Rename filter to filter_widget 2021-06-28 00:21:50 +02:00
Jonas Kvinge
0869651dc3 Change parameter order of CollectionBackend::Init 2021-06-28 00:21:50 +02:00
Strawbs Bot
ca42286354 Update translations 2021-06-26 01:07:31 +02:00
Jonas Kvinge
174bfcc597 Use higher resolution images from last.fm API 2021-06-25 22:41:17 +02:00
Jonas Kvinge
244d25ce53 Fix compile with Qt 5 2021-06-25 18:46:45 +02:00
Jonas Kvinge
8287efd51f Remove silencing -Wclazy-qt6-deprecated-api-fixes to workaround clazy bugs 2021-06-25 18:19:37 +02:00
Jonas Kvinge
df31b5d59f Replace Q_ENUMS with Q_ENUM 2021-06-25 18:06:30 +02:00
Jonas Kvinge
53cc47a8b1 Use localhost directly as redirect for scrobbling API 2.0 2021-06-25 16:04:19 +02:00
Jonas Kvinge
55f8294a38 Remove escape characters from playlist filter string
Fixes #728
2021-06-25 12:01:05 +02:00
Strawbs Bot
67a5e3f37e Update translations 2021-06-23 01:16:19 +02:00
Jonas Kvinge
06cd2f3a57 Remove static from IsMacAccessibilityEnabled 2021-06-22 16:17:51 +02:00
Jonas Kvinge
d614a94203 Remove const from SingleApplication methods 2021-06-22 16:15:04 +02:00
Jonas Kvinge
f66aca2164 Remove static from OSDPretty::current_screen 2021-06-22 14:17:24 +02:00
Jonas Kvinge
b071ecb45e Formatting 2021-06-22 14:04:42 +02:00
Jonas Kvinge
83a70fecca Use QWidget::tr() 2021-06-22 14:04:42 +02:00
Jonas Kvinge
dbc7c224c1 Fix setting PID 2021-06-22 14:04:42 +02:00
Jonas Kvinge
7876f9a8a5 Remove unneeded QFont in parameter initialization list 2021-06-22 14:04:42 +02:00
Jonas Kvinge
215057ce6f Remove unneeded get() 2021-06-22 14:04:42 +02:00
Jonas Kvinge
6d8b0b3ab6 Simplify return 2021-06-22 14:04:42 +02:00
Jonas Kvinge
e5c85ddd32 Pass task ID to SetTaskBlocksCollectionScans 2021-06-22 14:04:42 +02:00
Jonas Kvinge
6bf3c34fe5 Fix parameter name mismatch 2021-06-22 14:04:42 +02:00
Jonas Kvinge
584f5e5935 Change bool/int condition 2021-06-22 14:04:42 +02:00
Jonas Kvinge
58a5367015 Make const 2021-06-22 14:04:42 +02:00
Jonas Kvinge
8c2b907ff5 Make static 2021-06-22 14:04:42 +02:00
Strawbs Bot
e3ab0c0192 Update translations 2021-06-22 01:05:22 +02:00
Jonas Kvinge
8572e3eabb Fix volume slider regression 2021-06-21 20:21:40 +02:00
Jonas Kvinge
d4f10c61ef Change lambda capture 2021-06-21 20:10:02 +02:00
Jonas Kvinge
59e11d6caa Remove reference 2021-06-21 20:00:31 +02:00
Jonas Kvinge
67778198de Formatting 2021-06-21 19:55:47 +02:00
Jonas Kvinge
ebfd8cd6f7 Initialize variables and formatting 2021-06-21 19:55:18 +02:00
Jonas Kvinge
83b54f2ae6 Formatting 2021-06-21 19:54:42 +02:00
Jonas Kvinge
7ea60ed178 Update copyrights 2021-06-21 19:54:12 +02:00
Jonas Kvinge
c61d1ce6b4 Use std::any_of 2021-06-21 19:52:37 +02:00
Jonas Kvinge
6a7959547e Change CoverProvider quality return type to float 2021-06-21 18:16:04 +02:00
Jonas Kvinge
af3834672e Remove unneeded break 2021-06-21 18:14:59 +02:00
Jonas Kvinge
f95ff6cb89 Formatting 2021-06-21 16:08:53 +02:00
Jonas Kvinge
e85c13b3fe Change switch to if statement 2021-06-21 15:44:13 +02:00
Jonas Kvinge
ed09627fdb Use std::make_unique 2021-06-21 15:40:44 +02:00
Jonas Kvinge
99ba2c2e8b Make playlist parameter to queue not optional 2021-06-21 15:40:44 +02:00
Jonas Kvinge
589bdf5dcd Use default 2021-06-21 15:40:44 +02:00
Jonas Kvinge
1abbd5ecbc Pass parent to queue 2021-06-21 15:40:44 +02:00
Strawbs Bot
7619e8427a Update translations 2021-06-21 01:17:51 +02:00
Jonas Kvinge
069e24d713 Fix compile 2021-06-21 00:29:38 +02:00
Jonas Kvinge
8e9b45f80f Add override 2021-06-20 23:57:19 +02:00
Jonas Kvinge
2d604a80c9 Change 0 to nullptr 2021-06-20 23:56:56 +02:00
Jonas Kvinge
1f59a1b952 unsigned long int 2021-06-20 23:56:33 +02:00
Jonas Kvinge
6e5ff01db5 Remove unused variables 2021-06-20 23:55:59 +02:00
Jonas Kvinge
50be44adf8 Add namespace comments 2021-06-20 23:55:02 +02:00
Jonas Kvinge
e1bf4347ab Fix uninitialized variables 2021-06-20 23:53:28 +02:00
Jonas Kvinge
3a3305c020 Uppercase literal suffix 2021-06-20 23:49:04 +02:00
Jonas Kvinge
a83f174e1a Remove unused settingsdialog variable 2021-06-20 19:47:38 +02:00
Jonas Kvinge
1295033fae Clang-Tidy and Clazy fixes 2021-06-20 19:04:08 +02:00
Jonas Kvinge
755abec636 Use QProcess::startCommand with Qt 6 2021-06-20 02:48:58 +02:00
Jonas Kvinge
310995fb87 Use static QFileInfo::exists 2021-06-20 02:26:30 +02:00
Jonas Kvinge
bee30e572f Fix incorrect use of return 2021-06-20 02:25:36 +02:00
Jonas Kvinge
cd37a40bab Only link to chromaprint when song fingerprinting or musicbrainz is enabled 2021-06-16 22:54:23 +02:00
Jonas Kvinge
8699790e78 Always call QFutureWatcher::setFuture after connects 2021-06-16 00:30:21 +02:00
Strawbs Bot
d2d3f58a14 Update translations 2021-06-15 01:03:14 +02:00
Jonas Kvinge
081df59ed7 Only call QSystemTrayIcon::isSystemTrayAvailable once
Workaround file descriptor leak

Fixes #724
2021-06-15 00:25:54 +02:00
Strawbs Bot
ec3bcdcb26 Update translations 2021-06-14 01:02:38 +02:00
Jonas Kvinge
8265cf8a6a Use selected plug devices when loading automatic/custom device 2021-06-14 00:18:14 +02:00
Jonas Kvinge
dfb53fb3dd Change regex for CARD and DEV in ALSA devices 2021-06-13 23:58:47 +02:00
Jonas Kvinge
705fc920e5 Fix 2021-06-13 23:44:15 +02:00
Jonas Kvinge
99764741e4 Fix detecting ALSA PCM devices 2021-06-13 23:42:08 +02:00
Jonas Kvinge
35b3bc4522 Handle some chromaprinter error cases 2021-06-13 23:18:22 +02:00
Jonas Kvinge
91eee99bab Increase pen size for OSD Pretty border
Workaround for QTBUG-93476

Fixes #708
2021-06-13 20:56:14 +02:00
Jonas Kvinge
e56defdc50 Formatting 2021-06-13 20:55:37 +02:00
Jonas Kvinge
fbe4d3ce9f Add Subsonic option to turn off HTTP2
Fixes #718
2021-06-13 19:55:45 +02:00
Strawbs Bot
8cf5707575 Update translations 2021-06-13 01:16:37 +02:00
Jonas Kvinge
f786a17014 Formatting 2021-06-12 20:53:23 +02:00
Jonas Kvinge
427b9c1ebc Formatting 2021-06-12 19:22:38 +02:00
Jonas Kvinge
141957e4b5 Remove godaddy certificate 2021-06-12 19:14:47 +02:00
Jonas Kvinge
b911f4f34e Formatting 2021-06-12 16:06:41 +02:00
Jonas Kvinge
0caf76dfae Remove unneeded includes 2021-06-12 16:06:41 +02:00
Jonas Kvinge
00f09168d7 Update Changelog 2021-06-12 16:06:41 +02:00
Strawbs Bot
d636359c10 Update translations 2021-06-11 01:16:45 +02:00
Jonas Kvinge
8fd32aba4f Improve resume playback on startup, re-request stream URL when unpausing
Fixes #270
2021-06-10 23:14:05 +02:00
Strawbs Bot
9db59d5deb Update translations 2021-06-09 01:03:30 +02:00
Jonas Kvinge
d98321c703 Use newer compiler with Qt 6 on openSUSE Leap 2021-06-08 23:43:14 +02:00
Jonas Kvinge
a6424c005f Add Gui to QT_COMPONENTS 2021-06-08 22:49:34 +02:00
Jonas Kvinge
80d127c277 Use fingerprints from database if available when fetching tags from MusicBrainz 2021-06-08 20:59:56 +02:00
Strawbs Bot
3ca0c828c6 Update translations 2021-06-07 01:01:41 +02:00
Strawbs Bot
d3a8e03b2c Add Portuguese (Brazil) 2021-06-06 01:47:57 +02:00
Strawbs Bot
6e75de0dcb Add Chinese 2021-06-06 01:43:49 +02:00
Strawbs Bot
a7bed9741a Add Catalan 2021-06-06 01:42:38 +02:00
Strawbs Bot
f70e52a7a5 Add Japanese 2021-06-06 01:38:22 +02:00
Strawbs Bot
95d7de0654 Add Dutch 2021-06-06 01:36:50 +02:00
Strawbs Bot
3398d25b35 Add Ukrainian 2021-06-06 01:35:40 +02:00
Strawbs Bot
80a4a43680 Add Finnish 2021-06-06 01:34:54 +02:00
Strawbs Bot
01ac61f38c Update translations 2021-06-06 01:23:21 +02:00
Jonas Kvinge
a98be36684 Set DEFAULT '' for all TEXT 2021-06-06 00:36:35 +02:00
Jonas Kvinge
7f085c4012 Check fingerprint for NULL 2021-06-06 00:26:11 +02:00
Jonas Kvinge
5f008d1560 Edit collection settings tab order 2021-06-05 22:34:32 +02:00
Jonas Kvinge
0782b579d5 Update README and Changelog 2021-06-05 22:30:15 +02:00
Jonas Kvinge
f8ed2afef1 Add song fingerprinting and tracking
Fixes #296
2021-06-05 21:56:40 +02:00
Jonas Kvinge
a883508eca Fix marking CUE songs available 2021-06-05 02:50:20 +02:00
Jonas Kvinge
a4a20ec220 Make sure schedule playlist save timer is started from correct thread 2021-06-05 00:07:15 +02:00
Jonas Kvinge
faed63712f Remove Fedora 32 and CentOS 8 from CI 2021-06-04 00:25:11 +02:00
Jonas Kvinge
0032ec5036 Don't log access tokens 2021-06-04 00:15:35 +02:00
Strawbs Bot
9df24a841f Update translations 2021-06-02 01:01:56 +02:00
Jonas Kvinge
d2aa4ff2bd Remove duplicate line 2021-06-01 23:16:04 +02:00
Jonas Kvinge
171db01401 Set default for original year 2021-05-31 19:07:55 +02:00
Strawbs Bot
0112f1e11d Update translations 2021-05-31 01:01:58 +02:00
Jonas Kvinge
8f7b09b58e Update Changelog 2021-05-30 20:57:54 +02:00
Strawbs Bot
479c2b6cec Update translations 2021-05-30 01:25:46 +02:00
Jonas Kvinge
e6f50e6637 Strip mimetype when downloading covers 2021-05-29 23:27:40 +02:00
Jonas Kvinge
548f8bf23e Fix macOS compile 2021-05-29 22:47:53 +02:00
Jonas Kvinge
b6bfe81f9a Use HAVE_X11_GLOBALSHORTCUTS 2021-05-29 22:20:46 +02:00
Jonas Kvinge
ab95bcc028 Change text PulseAudio 2021-05-29 21:52:52 +02:00
Jonas Kvinge
8b7b3df0a3 Fix Qt 5 compile 2021-05-29 20:54:01 +02:00
Jonas Kvinge
69a6416146 Change to uppercase 2021-05-29 20:37:58 +02:00
Jonas Kvinge
1ced4e277b Add global shortcuts support on MATE 2021-05-29 20:35:55 +02:00
Jonas Kvinge
0c5236ebcb Fix crash when no system tray is available 2021-05-29 18:52:47 +02:00
Jonas Kvinge
66c55c5007 Remove remaining HAVE_X11EXTRAS 2021-05-29 18:36:58 +02:00
Jonas Kvinge
7f5a0f1b0c Update RPM spec, man page and debian control 2021-05-29 00:57:25 +02:00
Jonas Kvinge
0c766938f1 Update appdata 2021-05-29 00:49:27 +02:00
Jonas Kvinge
1455e87aef Update appdata 2021-05-29 00:48:23 +02:00
Jonas Kvinge
7c50eef8ad Add Fedora 35 2021-05-28 23:39:30 +02:00
Jonas Kvinge
aa9f972ccf Update Changelog 2021-05-26 17:05:07 +02:00
Strawbs Bot
45df99bb56 Update translations 2021-05-26 13:00:30 +02:00
Strawbs Bot
a2968e57cf Update translations 2021-05-21 01:15:12 +02:00
Jonas Kvinge
67f831beba Refactor systemtrayicon code 2021-05-20 21:40:08 +02:00
Jonas Kvinge
264d47caf4 Change playlist tabbar favorite tooltip 2021-05-20 17:12:28 +02:00
Jonas Kvinge
ef72b3273e Move private Qt GUI include 2021-05-20 17:10:08 +02:00
jonas@jkvinge.net
7d3ade7ae1 Automatically detect Qt version 2021-05-17 00:56:04 +02:00
Strawbs Bot
59897fdf55 Update translations 2021-05-14 01:02:10 +02:00
jonas@jkvinge.net
0b4ea04c91 Update protobuf dll in nsi 2021-05-13 21:06:43 +02:00
jonas@jkvinge.net
094b3b4636 Update Dmg.cmake: Move depends for macdeployqt 2021-05-13 12:18:06 +02:00
jonas@jkvinge.net
0298beeb06 Fix macOS build 2021-05-13 02:17:58 +02:00
Strawbs Bot
971542d6bc Update translations 2021-05-13 01:26:18 +02:00
jonas@jkvinge.net
5bdbc9f40d Add CMake test for Qt sqlite support 2021-05-13 00:18:06 +02:00
jonas@jkvinge.net
efcd35d4a1 Remove use of X11Extras and WinExtras
Modules are deprecated in Qt 6
See: QTBUG-83251
2021-05-12 23:15:04 +02:00
Strawbs Bot
a01541d7ca Update translations 2021-05-12 01:05:21 +02:00
jonas@jkvinge.net
7d96d7c066 Update README 2021-05-11 22:06:09 +02:00
jonas@jkvinge.net
639ea35921 Use wchar version of GetDiskFreeSpaceEx on Windows Qt 5 2021-05-11 20:32:28 +02:00
jonas@jkvinge.net
dee1905e16 Make the default tabbbar background color lighter
Fixes #711
2021-05-11 20:10:31 +02:00
jonas@jkvinge.net
1803705749 Add option to turn off playlist alternating row colors 2021-05-11 19:40:47 +02:00
jonas@jkvinge.net
5d96ee5492 Add ALSA PCM devices and option to set channels
Fixes #262
2021-05-11 19:14:00 +02:00
jonas@jkvinge.net
4a0a1a32a4 Rename ENABLE_CHROMAPRINT to ENABLE_MUSICBRAINZ 2021-05-10 21:17:50 +02:00
Strawbs Bot
c2108a35d0 Update translations 2021-05-09 01:01:51 +02:00
jonas@jkvinge.net
31ecdbae18 Update protobuf dll in nsi 2021-05-08 01:56:42 +02:00
jonas@jkvinge.net
e9c733e78f Turn off -Werror for Windows build in CI 2021-05-08 01:56:42 +02:00
Strawbs Bot
2320c5e04c Update translations 2021-05-08 01:01:55 +02:00
Jonas Kvinge
fb7b3b0295 Revert "Shuffle all songs instead of from the current to the end"
This reverts commit 316a3d51ee.
2021-05-04 23:16:18 +02:00
Jonas Kvinge
316a3d51ee Shuffle all songs instead of from the current to the end
Fixes #707
2021-05-04 22:48:18 +02:00
Jonas Kvinge
240dcf2e5c Improve device icon loading 2021-05-04 21:55:19 +02:00
Strawbs Bot
5fbdbffa23 Update translations 2021-05-04 01:04:38 +02:00
Jonas Kvinge
932c8b65fb Add Ubuntu Hirsute to CI 2021-05-03 23:33:59 +02:00
Strawbs Bot
e18e174947 Update translations 2021-05-02 01:02:16 +02:00
Jonas Kvinge
f2c7df3a3b Build on macOS with libgpod 2021-05-01 22:12:13 +02:00
Jonas Kvinge
2b15dae806 Strip misc from song title when sending now playing 2021-05-01 18:19:08 +02:00
Jonas Kvinge
2625d72818 Don't strip off "Live" from song title 2021-05-01 18:03:26 +02:00
Strawbs Bot
a8b4d72421 Update translations 2021-04-27 01:06:58 +02:00
Jonas Kvinge
88562890ae Use int in MainWindow::UpdateTrackSliderPosition 2021-04-26 23:36:59 +02:00
Jonas Kvinge
86c267eb89 Seconds is already qint64 2021-04-26 23:13:37 +02:00
Jonas Kvinge
3d1928cca9 Fix typo 2021-04-26 23:12:59 +02:00
Jonas Kvinge
8c64d3b55c Do most item reloading in the background, schedule playlist saving 2021-04-26 22:57:08 +02:00
Jonas Kvinge
41b238e87b Formatting 2021-04-26 22:56:14 +02:00
Jonas Kvinge
da83025fb0 Update temporary metadata when reloading song
Possible fix for #697
2021-04-26 20:33:57 +02:00
Jonas Kvinge
84d3b190c8 Update Changelog 2021-04-25 21:20:43 +02:00
Strawbs Bot
272fc5a72d Update translations 2021-04-25 01:04:39 +02:00
Strawbs Bot
0f709059e3 Update translations 2021-04-24 01:02:19 +02:00
Jonas Kvinge
0f91bb28a9 Remove CircleCI 2021-04-23 21:09:11 +02:00
Jonas Kvinge
63d75a8e17 Build common DMG for all macOS versions 2021-04-23 21:08:23 +02:00
Strawbs Bot
be95d8409b Update translations 2021-04-23 01:02:57 +02:00
Jonas Kvinge
9d3000498b Add setting for setting reply gain fallback gain 2021-04-22 21:55:26 +02:00
Jonas Kvinge
48f8468e65 Change direction to out for signals 2021-04-22 21:54:45 +02:00
Jonas Kvinge
9b60559855 Use QFile::encodeName() in Song::InitFromFilePartial
Fixes #693
2021-04-21 20:11:37 +02:00
Jonas Kvinge
e97acf7938 Fix errors in D-Bus XMLs 2021-04-21 16:05:23 +02:00
Jonas Kvinge
1cfb92e75c Remove quotation mark from org.gnome.SettingsDaemon.MediaKeys.xml 2021-04-21 16:00:34 +02:00
Strawbs Bot
4c617ccd49 Update translations 2021-04-19 01:01:46 +02:00
Jonas Kvinge
494517e767 Turn back git revision 2021-04-18 22:07:43 +02:00
Jonas Kvinge
655c872ac9 Release 0.9.3 2021-04-18 18:44:43 +02:00
Strawbs Bot
cb0f2b48fd Update translations 2021-04-18 01:03:10 +02:00
Strawbs Bot
20a84bdefc Update translations 2021-04-17 01:02:28 +02:00
Jonas Kvinge
83ad7d4935 Set exit before quit is called 2021-04-16 18:34:38 +02:00
Jonas Kvinge
ae2ca175d3 Fix remembering hidden state
Prevent SetHiddenInTray() or Exit() from being called again after
qApp->quit() in MainWindow::closeEvent()
2021-04-16 18:27:24 +02:00
Jonas Kvinge
c855108b94 Update Changelog 2021-04-15 21:06:19 +02:00
Strawbs Bot
5e80b694c2 Update translations 2021-04-15 01:02:00 +02:00
Jonas Kvinge
99640aa2ad Add Windows Qt 6 build to CI 2021-04-14 21:11:01 +02:00
Jonas Kvinge
4c0f7c3dd4 Add commandline option to resize window 2021-04-14 19:50:38 +02:00
Jonas Kvinge
2a8490ef31 Use modern user interface and locked list also for uninstalling 2021-04-14 18:07:23 +02:00
Jonas Kvinge
43dc694963 Include gst-discoverer-1.0.exe in windows setup 2021-04-14 16:56:30 +02:00
Strawbs Bot
e03ee00554 Update translations 2021-04-14 01:02:25 +02:00
Jonas Kvinge
01a07ec0e8 Enable stream discoverer on all systems
Fixes #689
2021-04-14 00:16:37 +02:00
Jonas Kvinge
74b7738a9d Create GLib main event loop on non-glib systems 2021-04-14 00:16:07 +02:00
Jonas Kvinge
10aaaebc38 Enable stream discoverer on all Unix except macOS 2021-04-13 22:11:44 +02:00
Jonas Kvinge
a8d072150d Remove avresample-4.dll from nsi 2021-04-13 19:11:48 +02:00
Jonas Kvinge
7877bb7956 Add setting for OSD Pretty fading 2021-04-13 17:27:10 +02:00
Strawbs Bot
bd31e3df89 Update translations 2021-04-13 01:01:55 +02:00
Jonas Kvinge
531e97b499 Only use QPlatformNativeInterface on X11 2021-04-12 19:40:34 +02:00
Jonas Kvinge
43876e967a Enable Qt6WinExtras.dll in nsi 2021-04-12 15:41:28 +02:00
Jonas Kvinge
efaf917939 Add pragma unused 2021-04-11 19:16:07 +02:00
Jonas Kvinge
7d3ceb7d8c Fix Tidal authentication on macOS 2021-04-11 18:33:35 +02:00
Jonas Kvinge
201ac47943 Add new screenshot 2021-04-11 09:11:24 +02:00
Jonas Kvinge
5a70285c10 Update Changelog 2021-04-11 03:24:21 +02:00
Jonas Kvinge
e13c27d32c Allow editing of playlist metadata for streams 2021-04-11 02:01:53 +02:00
Strawbs Bot
9c9b673eeb Update translations 2021-04-11 01:13:36 +02:00
Jonas Kvinge
7323fe0000 Fix queued item painting 2021-04-11 01:03:02 +02:00
Jonas Kvinge
460d045cbe Fix rescan when collection directory is removed and added 2021-04-11 01:01:57 +02:00
Jonas Kvinge
4983c1cfc9 FIx tidal search field not showing on macOS 2021-04-10 09:56:59 +02:00
Jonas Kvinge
c7bc9d471a Allow keep running option on macOS too 2021-04-10 08:22:08 +02:00
Jonas Kvinge
a36b91ffe8 Cast to quint32 2021-04-10 08:21:58 +02:00
Jonas Kvinge
88da0db0f7 Update copyrights 2021-04-10 07:32:38 +02:00
Jonas Kvinge
816c2b0ca8 Use qint32 for unique worker number 2021-04-10 07:20:36 +02:00
Jonas Kvinge
d6ff68339b Use qint64 for unique worker number 2021-04-10 07:02:08 +02:00
Jonas Kvinge
fdf483c98b Update README.md 2021-04-10 06:36:18 +02:00
Jonas Kvinge
eb020c1cb8 Register tidal URL scheme on macOS 2021-04-10 06:04:31 +02:00
Jonas Kvinge
6fa331ad06 Make macdeployqt work with Qt 5 too 2021-04-10 03:28:38 +02:00
Jonas Kvinge
5a58ac2845 Make CollectionQuery subclass QSqlQuery, don't copy QSqlQuery 2021-04-10 03:21:05 +02:00
Strawbs Bot
0c4edc4d17 Update translations 2021-04-09 01:02:09 +02:00
Jonas Kvinge
b5cea4c27e Make enabling FTS3 non-fatal 2021-04-08 22:33:43 +02:00
Jonas Kvinge
b7de5d6df3 Only enable FTS3 when schema needs upgrading 2021-04-08 22:13:21 +02:00
Strawbs Bot
d7310ba307 Update translations 2021-04-07 01:03:08 +02:00
Jonas Kvinge
cabb94b856 Move taglib include dir to system include dirs 2021-04-05 22:25:52 +02:00
Jonas Kvinge
82b649f67d Move taglib include dir to system include dirs 2021-04-05 22:22:25 +02:00
Strawbs Bot
8753782a0c Update translations 2021-04-04 01:02:57 +02:00
Strawbs Bot
566a139edc Update translations 2021-04-02 01:03:04 +02:00
Jonas Kvinge
39dda0f16b Check that rating position is to the right or left of the rectangle.
Adapted from Clementine.

Author: Jim Broadus
2021-04-02 00:47:53 +02:00
Jonas Kvinge
bddb371e31 Fix open in file browser when inode/directory mimetype is set to thunar
Fixes #677
2021-04-01 18:31:19 +02:00
Jonas Kvinge
128223a28a Add setting for configuring the color for the currently playing song
Fixes #676
2021-04-01 02:18:15 +02:00
Jonas Kvinge
45b9d0553f Update FUNDING.yml 2021-04-01 00:27:54 +02:00
Jonas Kvinge
a87f0e0475 Also strip variables with uppercase letters in OpenInFileManager() 2021-03-31 23:14:16 +02:00
Jonas Kvinge
beacea0482 Improve macdeployqt patch 2021-03-31 01:00:51 +02:00
Jonas Kvinge
85b59e79d3 Update ccpp.yml 2021-03-30 20:41:13 +02:00
Jonas Kvinge
9a947c5544 Use LockedList nsis plugin 2021-03-30 20:35:48 +02:00
Strawbs Bot
e4cebf4cbe Update translations 2021-03-30 01:03:27 +02:00
Jonas Kvinge
f63e05b7d4 Use QString::SkipEmptyParts for older Qt versions 2021-03-29 22:45:01 +02:00
Jonas Kvinge
84b7fa02bb Strip all variables from command in OpenInFileManager
Fixes #674
2021-03-29 22:37:55 +02:00
Strawbs Bot
36e597a045 Update translations 2021-03-29 01:28:10 +02:00
Strawbs Bot
f760b3f271 Update translations 2021-03-27 01:12:06 +01:00
Jonas Kvinge
d4c8fa6a24 Use const QJsonValueRef 2021-03-26 23:55:55 +01:00
Jonas Kvinge
c6604734c9 Remove using std::placeholders 2021-03-26 23:33:56 +01:00
Jonas Kvinge
91ab8e22b7 Use QJsonValueRef 2021-03-26 22:10:43 +01:00
Jonas Kvinge
14fb647647 Fix uninitialized variables 2021-03-26 21:30:13 +01:00
Jonas Kvinge
8a39a43ad5 Make sure QCache::insert is successful
Otherwise object is deleted by QCache::insert
2021-03-26 21:07:47 +01:00
Jonas Kvinge
a3d23a6f57 Turn back git revision 2021-03-26 20:35:18 +01:00
Jonas Kvinge
ae5da12afb Release 0.9.2 2021-03-25 23:24:16 +01:00
Jonas Kvinge
a3042b8f79 Update Changelog 2021-03-25 23:23:35 +01:00
Jonas Kvinge
29cbfe7c1a Change last played to qint64 2021-03-25 23:23:13 +01:00
Strawbs Bot
1ddc3292cc Update translations 2021-03-25 01:03:59 +01:00
Jonas Kvinge
658e1d122e Remove set current to all artists when opening cover manager
Caused sluggish opening
2021-03-24 22:30:58 +01:00
Jonas Kvinge
d936a080db Check for empty image 2021-03-24 22:30:37 +01:00
Jonas Kvinge
2a92af1e09 Change static_cast 2021-03-24 22:29:56 +01:00
Jonas Kvinge
9cde537066 Fix moodbar 2021-03-23 01:44:00 +01:00
Strawbs Bot
ffc5446914 Update translations 2021-03-22 01:23:51 +01:00
Jonas Kvinge
5f70b32795 Remove unused using std::shared_ptr 2021-03-21 20:23:42 +01:00
Jonas Kvinge
6b6117653a Allow audio formats unsupported by taglib to be added
Fixes #669
2021-03-21 19:19:35 +01:00
Jonas Kvinge
59bffed47f Use static_cast 2021-03-21 18:53:02 +01:00
Jonas Kvinge
f91a679cdf Add override 2021-03-21 18:40:33 +01:00
Jonas Kvinge
66b8d27d66 Change to QList 2021-03-21 06:26:48 +01:00
Jonas Kvinge
1219f504ea Update CI 2021-03-21 06:09:24 +01:00
Jonas Kvinge
ee5a191e39 Change to qint64 2021-03-21 06:07:11 +01:00
Jonas Kvinge
f577aa8d4f Update Changelog 2021-03-21 04:55:59 +01:00
Jonas Kvinge
2436c87372 Use variable 2021-03-21 04:55:00 +01:00
Jonas Kvinge
e90b5e63e5 Move variable 2021-03-21 04:49:22 +01:00
Jonas Kvinge
78588d8cdf Fix various clazy warnings 2021-03-21 04:47:11 +01:00
Jonas Kvinge
20c1c1d4be Remove unused variables 2021-03-21 04:43:55 +01:00
Jonas Kvinge
329dfb21b9 These don't need to be slots 2021-03-21 04:38:47 +01:00
Jonas Kvinge
02c30211a7 Call AbstractMessageHandler::AbortAll 2021-03-21 04:37:30 +01:00
Jonas Kvinge
645da2713d Remove emit from slots 2021-03-21 04:36:54 +01:00
Jonas Kvinge
20c5a79efa Fix playlist tabbar close and save 2021-03-21 04:28:22 +01:00
Jonas Kvinge
b224aeb0d8 Use 4arg connects for networkreplies 2021-03-21 00:37:17 +01:00
Jonas Kvinge
73eebd6162 Set album cover filename by pattern as default when saving cover to album directory 2021-03-20 23:13:54 +01:00
Strawbs Bot
99a1851f4d Update translations 2021-03-20 23:02:12 +01:00
Jonas Kvinge
d9d89d0927 Update Changelog 2021-03-20 21:21:36 +01:00
Jonas Kvinge
54f2aa5f77 Update copyrights 2021-03-20 21:14:47 +01:00
Jonas Kvinge
d022e9dd00 Close the file 2021-03-20 19:23:33 +01:00
Jonas Kvinge
17cf8ec1c6 Move declaration 2021-03-20 19:11:05 +01:00
Jonas Kvinge
c4a6d81cda Fix copying album covers to iPod
Cover file was deleted too soon.
File needs to be accessible until itdb_write is called.

Fixes #663
2021-03-20 19:00:42 +01:00
Jonas Kvinge
66ed485803 Check for existence of directory 2021-03-20 18:58:38 +01:00
Jonas Kvinge
6de585d1c8 Make sure process files isn't again called after finishing 2021-03-20 15:22:21 +01:00
Jonas Kvinge
9498638988 Make macdeployqt use environment variables for gstreamer 2021-03-20 14:19:49 +01:00
Jonas Kvinge
87dad82210 Update README.md 2021-03-19 00:35:13 +01:00
Jonas Kvinge
e37aec16ac Enable tumbleweed 2021-03-19 00:25:33 +01:00
Jonas Kvinge
6fb48af598 Fix macOS deployment 2021-03-18 23:08:50 +01:00
Jonas Kvinge
8193be36e5 Use a modified version of macdeployqt 2021-03-17 21:12:12 +01:00
Jonas Kvinge
a7df2bc4fb Use original file when loading cover from file in album cover manager 2021-03-16 17:18:11 +01:00
Jonas Kvinge
5eda028af3 Minor code improvements to album cover loader 2021-03-16 17:17:22 +01:00
Jonas Kvinge
f77475dbfe Specifically set get image 2021-03-16 17:16:40 +01:00
Jonas Kvinge
96c1a35c8e Use macdeploy.py for Qt plugins 2021-03-16 17:13:33 +01:00
Jonas Kvinge
0ef26be03f Remove DEBUG define 2021-03-16 17:12:44 +01:00
Jonas Kvinge
f5bb15f72e Fix QSearchField on macOS 2021-03-15 22:38:06 +01:00
Jonas Kvinge
d84aebd8f4 Format code 2021-03-15 22:37:49 +01:00
Jonas Kvinge
7d8d9f4c4d Format code 2021-03-14 23:20:16 +01:00
Jonas Kvinge
61b201810d Fix marking songs available 2021-03-14 23:08:05 +01:00
Jonas Kvinge
c75db8dc60 Turn back git revision 2021-03-14 02:32:42 +01:00
Jonas Kvinge
e0bf4091dd Update Changelog 2021-03-13 16:17:06 +01:00
Jonas Kvinge
1d89c46638 Release 0.9.1 2021-03-13 16:01:02 +01:00
Jonas Kvinge
88797424f1 Ignore empty lyrics from musixmatch 2021-03-13 15:58:34 +01:00
Jonas Kvinge
e0c57e77a9 Disable failed tagreader checksum test 2021-03-13 15:28:51 +01:00
Jonas Kvinge
e15a99f39f Remove Test from QT_LIBRARIES 2021-03-13 15:26:49 +01:00
Jonas Kvinge
9723c3606a Remove BUILD_TESTS cmake option 2021-03-13 15:18:38 +01:00
Jonas Kvinge
d2385d9287 Update Changelog 2021-03-13 15:18:09 +01:00
Jonas Kvinge
2695169514 Add type to metadata bundle to avoid updating previous song when it shouldn't 2021-03-13 03:14:30 +01:00
Jonas Kvinge
efcdfdf612 Remove unused include for macOS 2021-03-13 02:00:38 +01:00
Jonas Kvinge
f77e7334c5 Set album cover loader options in edit tag dialog 2021-03-13 01:52:37 +01:00
Jonas Kvinge
9079a7988c Turn off frame in edit tag dialog 2021-03-13 01:43:30 +01:00
Jonas Kvinge
5256d795b1 Fix tagreader process not starting on Windows in release build 2021-03-09 22:45:15 +01:00
Strawbs Bot
24a765814a Update translations 2021-03-08 01:12:33 +01:00
Jonas Kvinge
ef18a00362 Use mouse event variable 2021-03-07 23:26:08 +01:00
Jonas Kvinge
1823786344 Show fullsize cover on doubleclick in edit tag dialog 2021-03-07 23:23:58 +01:00
Jonas Kvinge
548a1f30ca Support saving by filename in SaveAndSetCover 2021-03-07 23:03:02 +01:00
Jonas Kvinge
e63859442a Ignore drop event in album cover manager
Fixes strange case where albums are duplicated by drag/drop.
2021-03-07 22:59:08 +01:00
Jonas Kvinge
69032db3c3 Remove unused function 2021-03-07 07:20:29 +01:00
Jonas Kvinge
d3e5b1b4e0 Move comment 2021-03-07 07:05:02 +01:00
Jonas Kvinge
e2cd68e3e8 Fix saving existing cover from file embedded for multiple albums 2021-03-07 07:01:22 +01:00
Jonas Kvinge
3e6029d33c Clear art automatic when embedded cover is deleted 2021-03-07 05:43:56 +01:00
Jonas Kvinge
89f1f8e6dc Check for empty art automatic 2021-03-07 05:41:49 +01:00
Jonas Kvinge
cff25374b5 Fix collection update for art_manual 2021-03-07 05:37:07 +01:00
Jonas Kvinge
04bbff338d Fix deleting multiple covers in album cover manager 2021-03-07 03:43:49 +01:00
Jonas Kvinge
bbcd6a3261 Fix saving empty cleared cover 2021-03-07 03:42:11 +01:00
Jonas Kvinge
e587e8cfc8 Use original file when loading cover from file in tag editor 2021-03-07 02:36:50 +01:00
Jonas Kvinge
869f8cf380 Enable cover actions based on current cover 2021-03-07 02:34:17 +01:00
Jonas Kvinge
1ff6ba9480 Only enable album cover options for collection songs 2021-03-07 01:49:38 +01:00
Jonas Kvinge
5807bee23b Load album cover controller settings when album cover manager is opened 2021-03-07 00:54:20 +01:00
Jonas Kvinge
b5bafbf23a Lowercase file extension 2021-03-07 00:53:33 +01:00
Jonas Kvinge
3954ccab8a Revert "Update libsoup in nsi"
This reverts commit 57207a72ea.
2021-03-05 00:02:37 +01:00
Strawbs Bot
24eb9d9e14 Update translations 2021-03-04 23:01:42 +01:00
Jonas Kvinge
57207a72ea Update libsoup in nsi 2021-03-04 22:04:16 +01:00
Jonas Kvinge
8771911931 Remove brew update and upgrade step 2021-03-04 01:35:36 +01:00
Jonas Kvinge
7b2411eec5 Change to info log 2021-03-04 01:14:06 +01:00
Jonas Kvinge
49a0b0bff2 Show info logging when debugging is off 2021-03-04 01:06:02 +01:00
Jonas Kvinge
3cea7ee1b9 Update Changelog 2021-03-03 22:18:04 +01:00
Jonas Kvinge
d366c1ac64 Update README.md 2021-03-03 22:02:41 +01:00
Jonas Kvinge
315858e410 Add sudo 2021-03-03 17:29:37 +01:00
Jonas Kvinge
a53965b824 Create symbolic link to make macdeployqt find plugins 2021-03-03 02:04:19 +01:00
Jonas Kvinge
cf973c3f25 Add REQUIRED to find_program for macdeployqt and createdmg 2021-03-03 02:03:52 +01:00
Jonas Kvinge
db09144624 Switch macOS builds to Qt 6 2021-03-03 00:43:47 +01:00
Jonas Kvinge
32b94555c3 Remove 3rdparty taglib 2021-02-27 16:55:41 +01:00
Jonas Kvinge
f507fef40d Use Leap 15.2 for Qt 6 build 2021-02-27 15:23:28 +01:00
Jonas Kvinge
d5caff58c7 Fix cover delete in edit tag dialog 2021-02-27 02:12:26 +01:00
Jonas Kvinge
ab4c725217 Fix embedded album cover default in edit tag dialog 2021-02-27 01:32:45 +01:00
Jonas Kvinge
901ba9cf13 Add QMap include 2021-02-27 01:02:37 +01:00
Jonas Kvinge
19b1bc6b3e Fix saving cover for multiple albums 2021-02-27 00:58:43 +01:00
Jonas Kvinge
c623ea7c2a Use reference 2021-02-26 23:10:36 +01:00
Jonas Kvinge
72e61106a9 Remove unused include 2021-02-26 22:15:04 +01:00
Jonas Kvinge
e15e7f0942 Fix compile with Qt 5
Forgot to test the changes from the last commit with Qt 5
2021-02-26 22:01:45 +01:00
Jonas Kvinge
133f094d72 Add support for saving embedded album covers
Fixes #286
2021-02-26 21:03:51 +01:00
Jonas Kvinge
e4c89c1aed Update ccpp.yml 2021-02-23 16:04:13 +01:00
Jonas Kvinge
193cf1c750 Rename protobuf namespace
Fixes #654
2021-02-20 17:06:55 +01:00
Jonas Kvinge
75c2a630f6 Bump protobuf version in NSI 2021-02-20 16:26:23 +01:00
Jonas Kvinge
3a7cecac31 Change message reply ID's back to int32
Fixes #653
2021-02-20 16:16:17 +01:00
Jonas Kvinge
0ab214fd5d Add methods to tagreader for saving embedded art 2021-02-16 22:50:35 +01:00
Jonas Kvinge
eb603e942f Move semaphore release 2021-02-16 18:53:51 +01:00
Jonas Kvinge
b1e1c704b1 Use QTimer::singleShot() to delay signal from MessageReply 2021-02-16 18:50:43 +01:00
Jonas Kvinge
f908336ec6 Add back old MPEG::File::File constructor
The unit tests still uses it.

Fixes #650
2021-02-15 21:47:50 +01:00
Strawbsbot
3ff97e43e1 Update translations 2021-02-15 10:15:23 +01:00
Jonas Kvinge
622434b457 Remove Fedora 34 from CI 2021-02-14 22:28:42 +01:00
Jonas Kvinge
877319a8e5 taglib: Change while to for loop in TableOfContentsFrame 2021-02-13 00:41:49 +01:00
Jonas Kvinge
295db43bca taglib: Remove unused methods 2021-02-13 00:31:54 +01:00
Jonas Kvinge
4285f43316 taglib: Make Frame::asProperties virtual 2021-02-13 00:15:51 +01:00
Jonas Kvinge
29e8316527 Add missing static_cast 2021-02-11 22:33:54 +01:00
Jonas Kvinge
2b988b8ab1 Handle more gstreamer errors as non-fatal
Adds GST_RESOURCE_ERROR_OPEN_READ and GST_STREAM_ERROR_TYPE_NOT_FOUND

Fixes #648
2021-02-11 22:23:54 +01:00
Jonas Kvinge
0abf991b05 Add back Big Sur to CI 2021-02-10 22:20:42 +01:00
Jonas Kvinge
7fc5b70553 Remove const reference from signals 2021-02-10 18:32:10 +01:00
Jonas Kvinge
b3681002a7 Change int to qint64 2021-02-10 18:27:40 +01:00
Strawbsbot
1f9af7a1e4 Update translations 2021-02-06 03:54:07 +01:00
Jonas Kvinge
9ed184edbf Simplify code 2021-02-06 00:32:01 +01:00
Jonas Kvinge
89572b07fb Remove default argument 2021-02-06 00:30:40 +01:00
Jonas Kvinge
443578e0ee Merge pull request #644 from gavinhoward/master
Fix playlist saving
2021-02-04 01:20:03 +01:00
Gavin Howard
0f96daec9a Fix playlist saving
The fix came from a suggestion by Jonas; I just tested it.
2021-02-03 16:38:24 -07:00
Strawbs Bot
59412c54de Update translations 2021-02-03 01:15:47 +01:00
Jonas Kvinge
16ca55e4ec Update Changelog 2021-02-02 21:41:31 +01:00
Jonas Kvinge
03959a68d5 Formatting 2021-02-02 21:08:58 +01:00
Jonas Kvinge
59b48ceb4a Use std::make_shared 2021-02-02 21:08:12 +01:00
Strawbs Bot
d499bfab8a Update translations 2021-02-02 01:02:36 +01:00
Strawbs Bot
b7b2b5089f Update translations 2021-02-01 01:43:46 +01:00
Jonas Kvinge
fcb417af17 Fix 'Except between tracks on the same album' backend fade option
Fixes #642
2021-01-30 23:16:19 +01:00
Jonas Kvinge
28c130a910 Add this as context to lambda connection 2021-01-30 22:42:21 +01:00
Jonas Kvinge
57a5eabd8f Use this and watcher instead of = 2021-01-30 22:41:57 +01:00
Jonas Kvinge
88874f0dcd Remove NewClosure 2021-01-30 21:53:53 +01:00
Jonas Kvinge
98d5e27a8c Remove use of NewClosure for playback resume 2021-01-30 21:52:17 +01:00
Jonas Kvinge
576956fa1d Use QTimer::singleShot directly for database backup 2021-01-30 21:51:32 +01:00
Jonas Kvinge
be051a4bb1 Use timers for submitting scrobbles 2021-01-30 21:50:28 +01:00
Jonas Kvinge
cc6c7430d4 Use a QTimer for writing scrobbler cache 2021-01-30 21:48:45 +01:00
Jonas Kvinge
477ee14b6d Remove unused waitforsignal class 2021-01-30 16:17:11 +01:00
Jonas Kvinge
2539b2333c Use new connect syntax in global shortcuts manager 2021-01-30 14:28:03 +01:00
Jonas Kvinge
ebf6ba9ca1 Use new connect syntax in DoAfter() 2021-01-30 14:27:25 +01:00
Jonas Kvinge
60528525e0 Use QObject::connect() everywhere for consistency 2021-01-29 18:53:20 +01:00
Jonas Kvinge
cb5a7f8c9d Replace NewClosure with lamdas 2021-01-29 18:47:50 +01:00
Jonas Kvinge
fd9c6d460a Fix lamda connect for audio CD tracks load finished 2021-01-29 18:45:09 +01:00
Jonas Kvinge
fa5b135439 Always add libdl.dll to Windows installer 2021-01-29 17:11:13 +01:00
Jonas Kvinge
9f5249e5b8 Make playlist moodbar column respect moodbar enabled setting 2021-01-28 21:43:06 +01:00
Jonas Kvinge
819800d3a4 Revert some lambda connects back to NewClosure 2021-01-28 21:22:50 +01:00
Jonas Kvinge
8ac5b55b3a Revert "Add macOS bigsur"
This reverts commit abe1079328.
2021-01-28 20:55:00 +01:00
Jonas Kvinge
abe1079328 Add macOS bigsur 2021-01-28 20:54:02 +01:00
Jonas Kvinge
775c62fbb4 Remove macOS bigsur builder as the CI is currently broken 2021-01-28 20:51:40 +01:00
Jonas Kvinge
daff2c1f84 Add option to append explicit to album titles for Tidal 2021-01-28 19:55:28 +01:00
Jonas Kvinge
1ea8b064cc Read/save vorbis comment grouping tag
Fixes #639
2021-01-28 18:11:49 +01:00
Strawbs Bot
a0e030a6ee Update translations 2021-01-28 01:02:00 +01:00
Strawbs Bot
690eb343ea Update translations 2021-01-27 01:22:31 +01:00
Jonas Kvinge
ad5e476920 Fix compile without moodbar
Fixes #638
2021-01-26 22:34:31 +01:00
Jonas Kvinge
2a92ce867a Rename global shortcuts classes 2021-01-26 20:48:51 +01:00
Jonas Kvinge
bf7c8df353 Connection syntax migration (#637) 2021-01-26 16:48:04 +01:00
Strawbs Bot
d57f6303f4 Update translations 2021-01-26 01:02:23 +01:00
Jonas Kvinge
9c6c26f424 Delete TagCompletionModel 2021-01-26 00:40:06 +01:00
Jonas Kvinge
00a98f6e30 Update Changelog 2021-01-25 23:39:18 +01:00
Jonas Kvinge
50d83dc070 Fix memory leak when moodbar is disabled
Only call MoodbarLoader::Load when moodbar is enabled.
2021-01-25 22:35:56 +01:00
Jonas Kvinge
010a0cc2a7 Fix playlist filter with Qt 6 2021-01-20 20:18:29 +01:00
Jonas Kvinge
71728bb3fe Remove snap 2021-01-20 20:07:21 +01:00
Strawbs Bot
fc1537fde8 Update translations 2021-01-17 01:02:48 +01:00
Jonas Kvinge
6e40f639b7 Turn off undo/redo stack for QTextDocument in playwidget details 2021-01-16 03:12:34 +01:00
Jonas Kvinge
21c5a97d15 Fix total album count 2021-01-15 21:17:32 +01:00
Jonas Kvinge
8a4d78ae4d Update Changelog 2021-01-14 21:33:18 +01:00
Strawbs Bot
001964f2f4 Update translations 2021-01-13 01:10:30 +01:00
Jonas Kvinge
a6a29d5c5a Set limits for collection pixmap cache based on size unit 2021-01-12 20:36:10 +01:00
Jonas Kvinge
706308cefd Update debian/copyright 2021-01-11 16:50:39 +01:00
Jonas Kvinge
72b194cd7e Rename network to networkaccessmanager 2021-01-11 16:48:46 +01:00
Jonas Kvinge
b85819ed9d Decode HTML entities in lyrics 2021-01-11 16:05:39 +01:00
Strawbs Bot
c5cd648b5d Update translations 2021-01-11 01:02:20 +01:00
Strawbs Bot
3743408543 Update translations 2021-01-10 01:05:51 +01:00
Jonas Kvinge
fd251c6e61 Use helper function for collection model container keys 2021-01-09 21:03:35 +01:00
Strawbs Bot
b7ab6c5c3e Update translations 2021-01-09 01:02:46 +01:00
Jonas Kvinge
5659fd5839 Use mimetype instead of description from stream discoverer when available 2021-01-08 22:38:37 +01:00
Jonas Kvinge
4dcd3e95df Append album ID to collection model container nodes 2021-01-08 22:35:07 +01:00
Mikalai Daronin
57709413e1 Add SPMediaKeyTap back (#621) 2021-01-06 14:46:21 +01:00
Jonas Kvinge
fb634bc2d4 Let watcher handle update of collection songs when organizing
Fixes bug duplicating songs in the db when moving songs across collection id's.

Fixes #623
2021-01-05 22:14:18 +01:00
Edgar Salgado
18a67e1f20 Last.fm last played date import: change date if it is newer than the … (#625)
* Last.fm last played date import: change date if it is newer than the one in database

* Last.fm lastplayed: make it more consistent with the code
2021-01-04 20:43:43 +01:00
Strawbs Bot
b4c2ae251b Update translations 2020-12-30 01:07:43 +01:00
Jonas Kvinge
bfaabafbfa Remove some unused utilities functions 2020-12-29 23:13:22 +01:00
Jonas Kvinge
c213d5b8d9 Find program create-dmg 2020-12-28 21:28:45 +01:00
Jonas Kvinge
50beda6621 Use same macdeployqt on Qt 5 and 6 2020-12-28 20:54:19 +01:00
Jonas Kvinge
8ea359ec8a Pass char16_t to QString::fromUtf16() 2020-12-28 20:33:09 +01:00
Strawbs Bot
c983c8e447 Update translations 2020-12-27 01:02:06 +01:00
Strawbs Bot
af96ce3e82 Update translations 2020-12-26 01:02:38 +01:00
Strawbs Bot
6a5928863c Update translations 2020-12-25 01:08:33 +01:00
Jonas Kvinge
514becc53a Bundle strawberry-tagreader on macOS using macdeployqt 2020-12-24 22:05:22 +01:00
Jonas Kvinge
1b140535a8 Add worker debug 2020-12-24 20:44:16 +01:00
Jonas Kvinge
cb5222e4d6 Fix albumcover searcher dialog not showing up on macOS 2020-12-24 16:56:00 +01:00
Jonas Kvinge
b6a9e1a996 Include cpu architecture in macOS dmg filename 2020-12-24 15:34:21 +01:00
Jonas Kvinge
b58a7c32c2 Update make dmg for Qt 6 2020-12-24 15:24:48 +01:00
Jonas Kvinge
fa0fd6b7d0 Ignore deprecated QString::fromUtf16() 2020-12-24 15:23:35 +01:00
Jonas Kvinge
057ec49a3e Remove hack in MergedProxyModel and use QAbstractProxyModel::modelAboutToBeReset() 2020-12-24 12:33:05 +01:00
Jonas Kvinge
3ae9092226 Prefer native notifications instead of D-Bus on macOS 2020-12-23 20:25:23 +01:00
Jonas Kvinge
351999a01b Use setContentsMargins 2020-12-23 20:24:37 +01:00
Jonas Kvinge
e407080057 Remove explicit for song 2020-12-23 20:24:15 +01:00
Jonas Kvinge
fa0bd8d31a Link Sparkle 2020-12-23 16:55:35 +01:00
Strawbs Bot
9b5fdb1345 Update translations 2020-12-23 01:02:31 +01:00
Jonas Kvinge
47fd30c23f Ignore NSUserNotificationCenter deprecation 2020-12-22 20:37:39 +01:00
Jonas Kvinge
ad469e4f61 Switch to official opensuse repo for Qt 6 build 2020-12-22 17:09:03 +01:00
Jonas Kvinge
eaed953614 Compile with -Werror 2020-12-22 16:34:59 +01:00
Jonas Kvinge
977ac16a1e Fix sparkle installation 2020-12-22 16:33:51 +01:00
Jonas Kvinge
c7986e4277 Build source and binary packages in same command 2020-12-22 16:32:09 +01:00
Jonas Kvinge
aff8fa1968 Seperate debugsource and debuginfo rpm 2020-12-22 16:30:47 +01:00
Strawbs Bot
0af767fff0 Update translations 2020-12-22 01:06:44 +01:00
Strawbs Bot
a928aa61ca Update translations 2020-12-21 01:02:14 +01:00
Jonas Kvinge
30cb0b1cae QNetworkRequest::Http2AllowedAttribute require Qt 5.15 2020-12-20 07:42:14 +01:00
Jonas Kvinge
32ae3cd567 QNetworkRequest::Http2AllowedAttribute require Qt 5.14 2020-12-20 07:24:44 +01:00
Jonas Kvinge
91b9602e12 Dont use empty lyrics from API 2020-12-20 07:09:12 +01:00
Jonas Kvinge
124eba6800 Remove mageia from CI 2020-12-20 06:58:43 +01:00
Jonas Kvinge
a5ab8ddf8b Disable http2 for musixmatch 2020-12-20 06:51:36 +01:00
Jonas Kvinge
1444a1578a Search all unicode letters in musixmatch cover search 2020-12-20 06:40:45 +01:00
Jonas Kvinge
5b8894b0ff Search all unicode letters in musixmatch lyrics search 2020-12-20 06:16:08 +01:00
Strawbs Bot
a4329dd9a0 Update translations 2020-12-20 01:02:08 +01:00
Jonas Kvinge
1cab25aa7d Turn back git revision 2020-12-19 22:18:28 +01:00
Jonas Kvinge
d3faf18251 Fix typo 2020-12-19 17:42:24 +01:00
Jonas Kvinge
ddcc296af4 Release 0.8.5 2020-12-19 17:38:24 +01:00
Jonas Kvinge
ee765bc210 Update strawberry.spec 2020-12-17 22:49:57 +01:00
Jonas Kvinge
630c67f7d0 Remove -U__STRICT_ANSI__ from compile flags 2020-12-17 19:47:46 +01:00
Jonas Kvinge
e78bb1b29c Use directsoundsink by default because of buggy wasapi plugin 2020-12-13 21:56:25 +01:00
Strawbs Bot
db312a7380 Update translations 2020-12-13 01:02:57 +01:00
Jonas Kvinge
48b4cbe1b9 Update ccpp.yml 2020-12-12 19:05:21 +01:00
Jonas Kvinge
edb1d4c747 Append Qt5 to Windows setups 2020-12-12 12:51:23 +01:00
Jonas Kvinge
128935b55e Use LPCSTR in RegisterWindowMessageA 2020-12-12 12:51:01 +01:00
Jonas Kvinge
d5a0d67c7b Use ScopedWCharArray 2020-12-12 12:50:33 +01:00
Jonas Kvinge
a86640fdee Exclude Windows from find D-Bus in CMake 2020-12-12 12:49:41 +01:00
Jonas Kvinge
03291b27d1 Mark unused 2020-12-12 12:49:35 +01:00
Strawbs Bot
acf81f116f Update translations 2020-12-12 00:51:58 +01:00
Jonas Kvinge
6564c405c1 Update Changelog 2020-12-12 00:50:46 +01:00
Jonas Kvinge
1bd586268c Update some copyrights 2020-12-12 00:33:27 +01:00
Jonas Kvinge
497952611d Fix HTML escaping for custom OSD notifications
Fixes #618
2020-12-11 23:59:38 +01:00
Jonas Kvinge
9149d1baa3 Add back mistakenly removed QT_MIN_VERSION in CMakeLists.txt 2020-12-11 21:01:51 +01:00
Jonas Kvinge
66c60ac5c7 Add back CentOS 8 to CI 2020-12-09 21:44:47 +01:00
Strawbs Bot
971fad4560 Update translations 2020-12-09 19:33:33 +01:00
Jonas Kvinge
8ed1ce4103 Move ThreadSafeNetworkDiskCache to own file 2020-12-09 18:41:07 +01:00
Jonas Kvinge
3112c34d11 Change to NetworkAccessManager 2020-12-09 18:39:37 +01:00
Jonas Kvinge
7ebf3cecc6 Only include Rpm.cmake and Deb.cmake on Linux 2020-12-09 18:29:30 +01:00
Jonas Kvinge
660fa99f9c Simplify Rpm.cmake 2020-12-09 18:09:49 +01:00
Jonas Kvinge
a997e53d8b Update RPM spec for Qt 6 2020-12-09 01:29:38 +01:00
Jonas Kvinge
1d1dd583e2 Remove CentOS from CI 2020-12-08 15:59:53 +01:00
Jonas Kvinge
d490b29265 Use regex 2020-12-07 22:43:00 +01:00
Jonas Kvinge
e8ca64f16b Replace empty quotes with empty strings for values in CUE parser 2020-12-07 22:34:55 +01:00
Jonas Kvinge
380aa7d884 Only set disc and year in CUE parser when valid 2020-12-07 21:57:15 +01:00
Jonas Kvinge
0a31a94ee8 Change double-click in cover manager to open fullsize cover
Fixes #612
2020-12-07 17:23:08 +01:00
Jonas Kvinge
e1d50ce28f Make URL in scrobbler settings clickable 2020-12-07 17:21:34 +01:00
Jonas Kvinge
38cc39f23d Workaround udisks2 mountpoint issue with Qt 6 2020-12-06 18:46:30 +01:00
Jonas Kvinge
8110035d71 Remove unref 2020-12-06 18:45:37 +01:00
Jonas Kvinge
9af409d6d6 Make sure URL is valid in giolister 2020-12-06 18:45:17 +01:00
Jonas Kvinge
8646829853 Update .travis.yml 2020-12-06 11:16:15 +01:00
Jonas Kvinge
b9e87813b1 Add back Travis-CI 2020-12-06 06:45:08 +01:00
Strawbs Bot
138e032746 Update translations 2020-12-05 01:03:29 +01:00
Jonas Kvinge
d94c6b5aba Set active playlist when playlist doubleclick behaviour is enqueue
Fixes #610
2020-12-04 22:11:35 +01:00
Jonas Kvinge
7c03a39316 Update Changelog 2020-12-04 19:38:00 +01:00
Jonas Kvinge
c482e264f4 Rename variable 2020-12-04 19:13:21 +01:00
Nicolas Toussaint
3a9a1f0a94 add CLI play-playlist option, to play given playlist name. (#608)
* add CLI play-playlist option, to play given playlist name.

* Apply MR change requests
2020-12-04 19:08:41 +01:00
Jonas Kvinge
5b5f728f49 Update README.md 2020-12-03 22:24:57 +01:00
Jonas Kvinge
179aac6b35 Update FUNDING.yml 2020-12-03 22:16:22 +01:00
Strawbs Bot
25de9126ca Update translations 2020-11-30 01:19:32 +01:00
Jonas Kvinge
87be5662ad Update .circleci/config.yml 2020-11-29 16:05:02 +01:00
Jonas Kvinge
053a59e3f4 Update .github/workflows/ccpp.yml 2020-11-29 16:03:44 +01:00
Jonas Kvinge
250857b3d4 Update .circleci/config.yml 2020-11-29 07:54:42 +01:00
Jonas Kvinge
dc288c584c Search qpa/qplatformnativeinterface.h for both Qt 5 and 6 2020-11-29 07:50:08 +01:00
Jonas Kvinge
fc02543f15 Make X11Extras and WinExtras optional
The initial release of Qt 6 does not have these.

These modules are not important.
X11Extras is only used for X11 global shortcuts, which in most cases is
overriden by KDE or Gnome shortcuts anyway.
It is also used in OSD Pretty to detect transparency, but this can be
done using private GUI headers instead.

WinExtras is only used in OSD Pretty to make it transparent.
2020-11-29 07:41:30 +01:00
Jonas Kvinge
0808db706f Remove libgstrealmedia.dylib from macdeploy 2020-11-29 06:43:24 +01:00
Strawbs Bot
1e649fc565 Update translations 2020-11-29 01:02:57 +01:00
Strawbs Bot
c523e959d7 Update translations 2020-11-27 01:02:59 +01:00
Strawbs Bot
1422f988c1 Update translations 2020-11-26 01:02:53 +01:00
Strawbs Bot
e86252b934 Update translations 2020-11-25 01:02:17 +01:00
Jonas Kvinge
e9c59b5c31 Add gst-launch-1.0.exe to windows setup 2020-11-24 15:45:24 +01:00
Strawbs Bot
f7bddee0ce Update translations 2020-11-24 01:05:32 +01:00
Jonas Kvinge
d56b76c9e3 Save both ID3v1 and ID3v2
Fixes #598
2020-11-23 22:25:47 +01:00
Jonas Kvinge
a41353ed03 Update progress even if QDateTime::fromString() fails 2020-11-23 21:54:58 +01:00
Strawbs Bot
7ea12cf2f9 Update translations 2020-11-23 01:05:20 +01:00
Jonas Kvinge
5bc5170112 Remove travis 2020-11-22 20:01:45 +01:00
Jonas Kvinge
946ed0c0b5 Check for valid datetime when importing last played 2020-11-22 19:01:53 +01:00
Jonas Kvinge
fcd4e5aca2 Save and restore geometry in edit tag dialog 2020-11-22 03:37:15 +01:00
Jonas Kvinge
6ab6e6d3a8 Format code 2020-11-22 03:36:46 +01:00
Strawbs Bot
0893d01b4a Update translations 2020-11-22 01:02:49 +01:00
Jonas Kvinge
bf04c45ebf Remove unused live scanning option 2020-11-21 09:40:48 +01:00
Jonas Kvinge
2786a1a97e Remove required version from cmake files 2020-11-21 07:41:43 +01:00
Strawbs Bot
cd9a4f1aa9 Update translations 2020-11-21 01:16:20 +01:00
Jonas Kvinge
91e5cafe76 Remove disabling repeat and shuffle buttons
It's more confusing than helpful
2020-11-20 21:48:10 +01:00
Jonas Kvinge
47754951f0 Format code 2020-11-20 21:47:01 +01:00
Strawbs Bot
fbef8ef32e Update translations 2020-11-20 01:08:25 +01:00
Jonas Kvinge
abd5bf3158 Update .github/workflows/ccpp.yml 2020-11-19 21:25:40 +01:00
Jonas Kvinge
fd024368a3 Update .github/workflows/ccpp.yml 2020-11-19 21:24:30 +01:00
Jonas Kvinge
cf4856a0c9 Fix signal not always emitted from messagreply 2020-11-19 18:29:03 +01:00
Jonas Kvinge
1b791c82fc Use qint64 for message request ID 2020-11-19 18:26:50 +01:00
Jonas Kvinge
3a27a3e868 Format code 2020-11-19 18:22:57 +01:00
Jonas Kvinge
7e6c16b287 Change progress and max progress to qint64 in taskmanager 2020-11-19 18:14:42 +01:00
Jonas Kvinge
f877639ed7 Fix repeat/shuffle disabled when a dynamic playlist is open
Fixes #593
2020-11-19 18:12:48 +01:00
Strawbs Bot
846309d4dd Add Swedish 2020-11-19 01:19:58 +01:00
Strawbs Bot
f2239ddfdf Update translations 2020-11-19 01:02:47 +01:00
Jonas Kvinge
742d455b0e Build on Big Sur 2020-11-18 22:48:16 +01:00
Strawbs Bot
20b08a78e7 Update translations 2020-11-18 01:17:34 +01:00
Jonas Kvinge
042da74955 Change return type of qHash with Qt 6 to size_t 2020-11-17 01:22:38 +01:00
Jonas Kvinge
4dcae4ce21 Use QChar::unicode() 2020-11-17 01:22:00 +01:00
Jonas Kvinge
fa0f07f553 Use QString::number() 2020-11-17 01:21:38 +01:00
Jonas Kvinge
39792d76cf Fix PlaylistGenerator::type() 2020-11-17 01:20:45 +01:00
Strawbs Bot
d181ee9101 Update translations 2020-11-17 01:02:12 +01:00
Jonas Kvinge
335ba1a5b0 Disable tagreader checksum tests
These don't match anymore because tags are now removed.
2020-11-15 12:17:35 +01:00
Jonas Kvinge
4934a360f1 Turn back git revision 2020-11-15 12:16:44 +01:00
Strawbs Bot
0559a4c6f2 Update translations 2020-11-15 01:03:31 +01:00
Jonas Kvinge
fc07919a75 Release 0.8.4 2020-11-15 00:31:32 +01:00
Jonas Kvinge
d7661edf67 Update Changelog 2020-11-15 00:20:16 +01:00
Jonas Kvinge
1c91693294 Ignore org.kde.kglobalaccel.NoSuchComponent error 2020-11-15 00:20:08 +01:00
Jonas Kvinge
3fc3cbc6d5 Update protobuf dll in nsi 2020-11-14 19:13:40 +01:00
Jonas Kvinge
11b5895e69 Update ccpp.yml 2020-11-14 18:36:59 +01:00
Jonas Kvinge
b4c614edbf Set volume bit 2020-11-14 04:36:38 +01:00
Jonas Kvinge
deddaed04a Remove use of std::bind where possible 2020-11-14 02:13:22 +01:00
Jonas Kvinge
a155e503f4 Never use reference when iterating QJsonArray 2020-11-13 21:10:50 +01:00
Jonas Kvinge
c0663bc19f Use reference 2020-11-13 20:34:29 +01:00
Strawbs Bot
7ffa51b83d Update translations 2020-11-13 01:02:53 +01:00
Jonas Kvinge
6d397b9988 Fix smart playlist by filename 2020-11-12 20:47:13 +01:00
Jonas Kvinge
571a7fa26b Fix single letter collection nodes showing before dividers 2020-11-12 20:30:58 +01:00
Jonas Kvinge
b3b5a38c3a Minor code style fix 2020-11-11 22:55:56 +01:00
Jonas Kvinge
a4b115f89b Update Changelog 2020-11-11 22:51:55 +01:00
Strawbs Bot
3d672bb145 Update translations 2020-11-11 01:03:35 +01:00
Jonas Kvinge
15b656b753 Merge pull request #587 from fbugno/issue515
Fix HiDPI scaling for glow animation and drag over playlist
2020-11-10 22:52:08 +01:00
Felipe Bugno
f5785db163 Code style changes to match the existing code
This changes the style of the private variable and the call
convention of the inherited functions.
2020-11-10 17:55:00 -03:00
Jonas Kvinge
1ff1bf3292 Only call deleteLater when proxystyle is set 2020-11-10 19:06:26 +01:00
Felipe Bugno
b062febea0 Fix HiDPI scaling for glow animation and drag over playlist
This set the proper scaling and pixel ratio of QPixmap widgets
used as cached objects.

Most of cached objects uses a custom QPaint instead of the default
painter object from the parent widget. The problem is that, unlike
the painter from the parent object, set by the main application,
and that has DPI and scaling settings from the device, these custom
QPainters don't know about the underlying device, thus uses a
scale of 1 to render artifacts.

When a cached object "edited" by a custom QPaint along his pipeline
where used on a paint or drawrow routine, his stored image is distorted
and burred in a effort to resize it to the display configuration.
2020-11-09 21:49:22 -03:00
Strawbs Bot
35301dc79e Update translations 2020-11-10 01:02:36 +01:00
Jonas Kvinge
30c336726b Only backup database if schema version is correct 2020-11-09 23:10:43 +01:00
Jonas Kvinge
3821680817 Increase sqlite busy timeout to 30 seconds
Possible fix for #533
2020-11-09 22:49:33 +01:00
Jonas Kvinge
74242ea24f Fix shortcut settings on macOS and Windows 2020-11-09 20:20:31 +01:00
Jonas Kvinge
73c7024e11 Dont return from SongSaveComplete early, needs to free TagReaderReply 2020-11-09 19:17:31 +01:00
Strawbs Bot
bbdec92dc6 Update translations 2020-11-09 01:01:55 +01:00
Jonas Kvinge
b4c289101c Strip summary but encode message 2020-11-08 21:54:16 +01:00
Jonas Kvinge
722d0797f6 Use QString::toHtmlEscaped() 2020-11-08 17:52:29 +01:00
Jonas Kvinge
deb27d5b55 Replace '&' with '&amp;' in D-BUS OSD messages 2020-11-08 14:24:09 +01:00
Jonas Kvinge
9cc4ffdf6e Only strip '&' from D-Bus OSD messages 2020-11-08 13:46:17 +01:00
Strawbs Bot
c76d63d1d9 Update translations 2020-11-08 13:32:51 +01:00
Jonas Kvinge
21bb4f33ad Update Changelog 2020-11-08 04:05:39 +01:00
Jonas Kvinge
2897b881d6 Only override fancy tabwidget style with adwaita 2020-11-08 04:04:37 +01:00
Jonas Kvinge
e9b89d0929 Simplify FancyTabWidget override 2020-11-08 03:23:18 +01:00
Jonas Kvinge
e801254b2e Log used style 2020-11-08 03:22:38 +01:00
Jonas Kvinge
6f49918ee9 Update Changelog 2020-11-08 02:10:20 +01:00
Jonas Kvinge
0ae7c18f1f Add setting to set style 2020-11-08 02:04:24 +01:00
Jonas Kvinge
c9c3fb396a Move ComboBoxLoadFromSettings function to settingspage 2020-11-08 02:02:48 +01:00
Strawbs Bot
91db4f1934 Update translations 2020-11-08 01:02:31 +01:00
Jonas Kvinge
9bbed6e95c Use QClipboard::setText instead of QClipboard::setMimeData
Fixes #581

Fixes clipboard copying on Windows too
2020-11-08 00:51:24 +01:00
Strawbs Bot
748bc27b25 Update translations 2020-11-06 11:50:48 +01:00
Jonas Kvinge
f42708e8bc Remove qt6-qt5compat-devel from ccpp.yml 2020-11-05 22:30:37 +01:00
Jonas Kvinge
160e4570a2 Use C++17 (#579)
* Use C++17

* Replace std::random_shuffle with std::shuffle

* Add random include
2020-11-05 22:28:49 +01:00
Jonas Kvinge
6272965143 Update Changelog 2020-11-05 00:10:16 +01:00
Jonas Kvinge
1e9613bf7f Update ccpp.yml 2020-11-04 23:45:40 +01:00
Jonas Kvinge
a061dac298 Check network proxy mode 2020-11-04 22:22:26 +01:00
Jonas Kvinge
914dee8571 Pass network proxy settings to gstreamer
Fixes #558
2020-11-04 22:16:20 +01:00
yavuzmert
47e2905edf Re-enable progress on system tray icon (#578)
* Re-enable progress on system tray icon

* fix copy-paste typo in mac sources

* Make tray icon progress optional

* Move tray icon progress setting control to MainWindow

* Move trayicon settings to behavioursettings

Co-authored-by: Yavuz Mert <yavuz.mert@darkbluesystems.net>
2020-11-04 21:01:04 +01:00
Jonas Kvinge
ee6675aee0 No longer need Core5Compat 2020-11-04 18:17:33 +01:00
Jonas Kvinge
62e0d9fe64 Remove all uses of QTextCodec 2020-11-04 18:16:23 +01:00
Jonas Kvinge
a174c142c1 Remove unused linked list includes 2020-11-04 18:06:36 +01:00
Jonas Kvinge
95afc5fdec Keep tabs in the middle on macOS 2020-11-04 18:05:58 +01:00
Strawbs Bot
04d69f66c0 Update translations 2020-11-04 01:02:16 +01:00
Jonas Kvinge
0347141edd Update snap dialog 2020-11-03 19:32:32 +01:00
Jonas Kvinge
1d6baae6e0 Set ssl-strict false in songloader too 2020-11-03 18:48:35 +01:00
yavuzmert
fb0f48f08a Make context view top label selectable (#576)
Co-authored-by: Yavuz Mert <yavuz.mert@darkbluesystems.net>
2020-11-03 01:34:09 +01:00
Jonas Kvinge
76e5e03d31 Change copy command in snap dialog 2020-11-02 21:26:20 +01:00
Jonas Kvinge
4cab743634 Center playlist tabbar star icon
Fixes #574
2020-11-02 17:57:12 +01:00
Jonas Kvinge
7c10ec97b7 Remove unused parameter 2020-11-02 17:47:16 +01:00
Jonas Kvinge
8718a16889 Star/unstar playlist with doubleclick 2020-11-02 17:45:29 +01:00
Strawbs Bot
75a0b924c3 Update translations 2020-11-02 01:02:00 +01:00
Jonas Kvinge
83a90e0c05 Make tabbar style hack less intrusive 2020-11-01 21:54:23 +01:00
Strawbs Bot
e5eadd1315 Update translations 2020-10-31 14:34:41 +01:00
Jonas Kvinge
f0142d90d4 Update comment 2020-10-31 14:27:53 +01:00
Jonas Kvinge
cabd6e6e9d Override QStyle::subElementRect in fancy tabbar to fix style problems
Something is causing the contents of the tabbar to be stretched from top to bottom with space between icons and text.
You can see this on the default Fedora (Gnome) installation.
Also fixes the tabbar on macOS where the content was in the middle instead of the top.
2020-10-31 14:05:06 +01:00
Jonas Kvinge
4804a05736 Remove fixed width in about dialog as it crashes on wayland 2020-10-31 02:41:42 +01:00
Jonas Kvinge
c258e5a3af Add KDE global shortcuts
Fixes #572
2020-10-31 02:08:19 +01:00
Jonas Kvinge
e8492940a5 Add -fPIC compiler flag for Redhat/Fedora/CentOS
Fixes #573
2020-10-30 18:12:42 +01:00
Jonas Kvinge
4bccb1ab47 Only save as ID3v2, and remove empty tags
Fixes #571
2020-10-29 18:47:09 +01:00
Strawbs Bot
b6d219e232 Update translations 2020-10-28 17:50:58 +01:00
Jonas Kvinge
23ee17594d Simplify CMake Qt 2020-10-27 20:54:25 +01:00
Jonas Kvinge
d9d39d8e25 Only override MainWindow::nativeEvent for Windows 2020-10-27 20:17:28 +01:00
Jonas Kvinge
224d5d46c1 Set QApplication::setQuitOnLastWindowClosed to false 2020-10-27 20:01:07 +01:00
Jonas Kvinge
09e0059930 Resize organize window when copying to device
Fixes #566
2020-10-27 17:50:16 +01:00
Jonas Kvinge
0ddff2b087 Fix stupid bug 2020-10-27 17:47:40 +01:00
Jonas Kvinge
2e6a29eacc Remove ifdef HAVE_GSTREAMER
Fixes #568
2020-10-27 17:17:12 +01:00
Jonas Kvinge
ad2fb82aa9 Don't edit playlist name on doubleclick in playlists view
Fixes #567
2020-10-27 17:11:17 +01:00
Strawbs Bot
a3f91c11e8 Update translations 2020-10-26 01:02:24 +01:00
Jonas Kvinge
a50c978ce3 Fix cancelling logout when window is maxmimized
Fixes #565
2020-10-25 19:59:27 +01:00
Strawbs Bot
27d6f881cd Update translations 2020-10-25 01:04:50 +02:00
Jonas Kvinge
944cd020af Only strip problematic characters when saving a playlist 2020-10-25 01:01:43 +02:00
Jonas Kvinge
bbe5d64b99 Add info about backing up configuration to snap dialog 2020-10-25 01:01:16 +02:00
Jonas Kvinge
f7b36ac4c7 Replace use of QVariant::type() with Qt 6 2020-10-24 03:32:40 +02:00
Jonas Kvinge
1d555ca17e Turn back git revision 2020-10-24 03:30:21 +02:00
Jonas Kvinge
f91b6c3468 Release 0.8.3 2020-10-24 01:32:25 +02:00
Jonas Kvinge
abe6eeb350 Update Changelog 2020-10-23 19:35:07 +02:00
Jonas Kvinge
64f90a7912 Remove Qt MacExtras, no longer used 2020-10-22 23:11:44 +02:00
Jonas Kvinge
5733966843 Dont reset settingspage changed status when window is shown
This is done by Init in Load() when the settings is opened.
2020-10-22 20:25:31 +02:00
Jonas Kvinge
eb1344fcec Unref caps in HandoffCallback 2020-10-22 17:49:13 +02:00
Strawbs Bot
c5fb29f00e Update translations 2020-10-22 01:02:03 +02:00
Jonas Kvinge
63135b9c54 Engine will never be in playing state on error 2020-10-21 23:27:15 +02:00
Jonas Kvinge
f7c666584e Remove debug line 2020-10-21 21:33:26 +02:00
Jonas Kvinge
6834324de2 Add more unit tests for organizeformat 2020-10-21 21:32:30 +02:00
Jonas Kvinge
3a0d59e66f Only append path if not empty 2020-10-21 21:32:12 +02:00
Jonas Kvinge
ffd2e2188a Fix crash with empty APE tag for MPC files 2020-10-21 20:29:06 +02:00
Jonas Kvinge
0e8d5bdc5d Fix crash with empty APE tag for WavPack and APE files 2020-10-21 20:27:43 +02:00
Jonas Kvinge
14806f6614 Update Changelog 2020-10-21 19:57:00 +02:00
Jonas Kvinge
00ece83b9d Tidal: Set default quality to lossless 2020-10-21 19:56:37 +02:00
Jonas Kvinge
8197ae2a2d Tidal: Guess filetype by filename extension in URL when missing codec. 2020-10-21 01:12:46 +02:00
Strawbs Bot
5fe658bb16 Update translations 2020-10-21 01:02:16 +02:00
Jonas Kvinge
617179f0c6 Always set state to NULL in destructor 2020-10-21 00:32:55 +02:00
Jonas Kvinge
95ac85f642 Move stream discoverer from pipeline to engine
Fixes #491
2020-10-21 00:07:58 +02:00
Jonas Kvinge
ca8877ad47 Revert gst_discoverer_stop 2020-10-20 18:47:40 +02:00
Jonas Kvinge
6d8f31048c Add call to gst_discoverer_stop
Stream discoverer currently only works on Linux
2020-10-20 18:28:09 +02:00
Jonas Kvinge
ac859eb576 Make sure we query empty instead of null 2020-10-20 17:14:38 +02:00
Jonas Kvinge
2dfa171b6a Save effective_albumartist as empty istead of null
Since we use the metadata now instead of the container keys for queries in
the model, there is a regression when the values are null.
2020-10-20 17:12:28 +02:00
Jonas Kvinge
6f72e3e2ea Always append divider key to sort text if the key is a digit 2020-10-20 17:11:14 +02:00
Strawbs Bot
c2b73ae963 Update translations 2020-10-20 01:04:50 +02:00
Jonas Kvinge
6c50077409 Fix concurrentrun test 2020-10-19 22:33:08 +02:00
Jonas Kvinge
06746449a1 Disable TestContainerNodes 2020-10-19 22:32:50 +02:00
Jonas Kvinge
da7b8edf51 Revert back to using PathWithoutFilenameExtension in organizedialog 2020-10-19 21:35:39 +02:00
Jonas Kvinge
6e29b41f23 Update Changelog 2020-10-19 21:07:25 +02:00
Jonas Kvinge
912bb069af Fix updating album cover to collection for edit tag dialog 2020-10-19 21:05:59 +02:00
Jonas Kvinge
6b2d7a67d8 Use Utilities::FiddleFileExtension in organize 2020-10-19 19:56:40 +02:00
Jonas Kvinge
dbb8ec0290 Remove debug in bus callbacks 2020-10-19 19:09:48 +02:00
Strawbs Bot
60b32760f2 Update translations 2020-10-19 01:03:27 +02:00
Jonas Kvinge
73a40bcb49 Update Changelog 2020-10-18 17:08:28 +02:00
Jonas Kvinge
0e258a5a32 Remove unused utilities functions 2020-10-18 14:12:01 +02:00
Jonas Kvinge
7ca65c81d8 Use QFileInfo instead of custom functions 2020-10-18 14:07:48 +02:00
Jonas Kvinge
2ad1a60e59 Use correct file extension in organize preview and resulting filename
Fixes #564
2020-10-18 13:24:33 +02:00
Jonas Kvinge
cf17ff4478 Update Changelog 2020-10-18 00:29:28 +02:00
Jonas Kvinge
fffc3aac68 Update Changelog 2020-10-17 21:11:06 +02:00
Jonas Kvinge
295ac3c458 Add back thumbbar 2020-10-17 21:10:57 +02:00
Jonas Kvinge
b6693a71f9 Rename initialise to initialize 2020-10-17 17:29:09 +02:00
Jonas Kvinge
5b21118a8c Replace gst_tag_list_free with gst_tag_list_unref 2020-10-17 04:54:46 +02:00
Jonas Kvinge
0235b19801 Only update buttons once 2020-10-17 04:21:11 +02:00
Jonas Kvinge
7426399aa2 Enable thumbbar for debug build 2020-10-17 03:41:28 +02:00
Jonas Kvinge
6861b0d668 Possible fix Windows thumbbar 2020-10-17 03:37:39 +02:00
Jonas Kvinge
c30fb0d38c Log errors in MM device finder 2020-10-17 03:19:13 +02:00
Jonas Kvinge
e45521c6c0 Fix updating playing widget song details in small mode 2020-10-16 23:57:18 +02:00
Strawbs Bot
d11fe8d4fc Update translations 2020-10-16 01:01:51 +02:00
Jonas Kvinge
8e83e63e3d Add snap warning dialog 2020-10-15 21:47:52 +02:00
Jonas Kvinge
c8fd0ac4b3 Update snapcraft.yaml 2020-10-15 18:51:21 +02:00
Jonas Kvinge
d78419eb33 Enable WASAPI plugin
Fixes #283
2020-10-15 16:08:59 +02:00
Jonas Kvinge
e44a3d013d Disable windows thumbbar
Fixes stability issues with WASAPI
2020-10-15 16:07:20 +02:00
Jonas Kvinge
aeb0d05017 Add CoInitializeEx() to mmdevice finder and refactor code 2020-10-15 16:06:07 +02:00
Jonas Kvinge
62702e4b3d Add space 2020-10-14 22:53:58 +02:00
Jonas Kvinge
5146cdfa2f Improve windows thumbbar code 2020-10-14 22:53:08 +02:00
Jonas Kvinge
246e7018c3 Remove concurrentrun.h 2020-10-14 22:50:19 +02:00
Jonas Kvinge
24286dbe9d Use QtConcurrent::run directly 2020-10-14 22:49:37 +02:00
Jonas Kvinge
2f442dfbe1 Ignore return value 2020-10-14 22:38:32 +02:00
Jonas Kvinge
b2fb01ee9c Use QtConcurrent 2020-10-14 22:35:54 +02:00
Jonas Kvinge
45e0a9a4ef Remove build-snap from CI 2020-10-14 18:36:29 +02:00
Jonas Kvinge
675b7b4bf4 Fix CI 2020-10-14 18:05:04 +02:00
Jonas Kvinge
be7a35443e Add gdb to nsi 2020-10-14 16:55:17 +02:00
Strawbs Bot
9918615fcd Update translations 2020-10-14 01:02:02 +02:00
Jonas Kvinge
4b72ef77c1 Turn back git revision 2020-10-14 00:26:35 +02:00
Jonas Kvinge
e427c61fbb Release 0.8.2 2020-10-13 18:03:05 +02:00
Jonas Kvinge
c78e8937d5 Update ISSUE_TEMPLATE.md 2020-10-13 01:50:32 +02:00
Jonas Kvinge
5d63f7a93d Update ISSUE_TEMPLATE.md 2020-10-13 01:50:03 +02:00
Jonas Kvinge
46551ada7f Update Changelog 2020-10-13 01:47:22 +02:00
Jonas Kvinge
83f17a37b1 Use format only when available 2020-10-13 01:38:09 +02:00
Strawbs Bot
9e23e0a623 Update translations 2020-10-13 01:05:54 +02:00
Jonas Kvinge
4a53d4f043 Ignore "IDirectSoundBuffer_GetStatus The operation completed successfully"
Fixes #557
2020-10-13 00:49:34 +02:00
Jonas Kvinge
0fd61945c7 Fix saving initial settings 2020-10-12 17:20:18 +02:00
Strawbs Bot
e3624eed30 Update translations 2020-10-12 01:03:47 +02:00
Jonas Kvinge
1923c8be0c Remove unused includes 2020-10-11 01:31:12 +02:00
Jonas Kvinge
a3e37fbfe2 Remove use of HTML in system tray icon tooltip 2020-10-11 01:29:26 +02:00
Jonas Kvinge
318c3bb422 Check if QNetworkRequest::ContentTypeHeader is filetype everwhere 2020-10-11 01:08:42 +02:00
Strawbs Bot
db96e24028 Update translations 2020-10-11 01:02:04 +02:00
Jonas Kvinge
cc2cce66df Make const 2020-10-11 00:07:38 +02:00
Jonas Kvinge
7afeabd288 Subsonic: Read created from album too
Fixes #526
2020-10-11 00:05:06 +02:00
Jonas Kvinge
eb43a812d6 Fix saving subsonic cover when ContentTypeHeader returns filetype 2020-10-10 23:46:29 +02:00
Jonas Kvinge
12cbcdb6f4 Fix SQL query by song id when song id is a string 2020-10-10 23:44:42 +02:00
Jonas Kvinge
a2e35e30dc Use lowercase for divider keys sort text
Fixes #556
2020-10-10 18:44:57 +02:00
Jonas Kvinge
b6ff7e6b47 Fix transition to next song in CUE files
Fixes #552
2020-10-10 01:57:02 +02:00
Jonas Kvinge
6dba40c6bb Turn back git revision 2020-10-10 01:21:13 +02:00
Jonas Kvinge
896da46422 Release 0.8.1 2020-10-09 21:38:00 +02:00
Jonas Kvinge
7c07f5eb2a Add clang-format file 2020-10-09 21:02:18 +02:00
Strawbs Bot
298cff37de Update translations 2020-10-09 01:01:57 +02:00
Jonas Kvinge
8add802fe9 Update Changelog 2020-10-08 19:42:33 +02:00
Jonas Kvinge
6d080a0d59 Fix crash when copying a closed playlist to a device
Fixes #551
2020-10-08 19:19:39 +02:00
Jonas Kvinge
f0ae1051ee Only set art manual for temporary metadata when temp metadata is set 2020-10-08 19:14:56 +02:00
Strawbs Bot
1ad0ffeaa6 Update translations 2020-10-08 01:02:36 +02:00
Jonas Kvinge
45b44d012d Fix source for CUE songs in collection watcher 2020-10-07 23:27:58 +02:00
Jonas Kvinge
cb6cbb9ee5 Remove unused screensaver classes 2020-10-07 22:10:31 +02:00
Jonas Kvinge
013a0d9cb0 Remove commented line 2020-10-07 21:28:52 +02:00
Jonas Kvinge
8abb3ea225 Fix backend settings tab order 2020-10-07 20:43:15 +02:00
Jonas Kvinge
74a5233b5d Replace use of deprecated gstreamer low-percent
- Add settings for low-watermark and high-watermark
- Add button to reset buffer settings to defaults
2020-10-07 20:29:26 +02:00
Strawbs Bot
cd695a4522 Update translations 2020-10-06 01:02:00 +02:00
Jonas Kvinge
eec4b2cc0e Call QLocalSocket::flush() after QLocalSocket::waitForBytesWritten() 2020-10-05 22:05:37 +02:00
Jonas Kvinge
616875d0d2 Log when sending message to primary instance fails 2020-10-05 22:04:58 +02:00
Jonas Kvinge
eb749bd76f Fix compile 2020-10-05 21:40:31 +02:00
Jonas Kvinge
7d1e404efd Fix header guard 2020-10-05 21:34:45 +02:00
Jonas Kvinge
4a01a578d1 Update singleapplication 2020-10-05 21:31:03 +02:00
Jonas Kvinge
393a2e0ea0 Set hide to false when window is shown 2020-10-05 19:08:09 +02:00
Jonas Kvinge
8e21decb8d Add WASAPI plugin to own setup file
Seem to still be stability issues.
2020-10-04 19:24:08 +02:00
Jonas Kvinge
22bfbab832 Add check for desktop notifications service version 2020-10-04 04:38:46 +02:00
Jonas Kvinge
28d0cc8795 Format singleapplication sources 2020-10-04 02:18:10 +02:00
Jonas Kvinge
51f2383a07 Remove lyrics from fandom.com
API no longer exists.
2020-10-04 02:13:06 +02:00
Jonas Kvinge
a6426c6eba Update Changelog 2020-10-04 02:00:12 +02:00
Jonas Kvinge
0631da6c8e Register Tidal URL Scheme in Windows installer 2020-10-04 01:59:40 +02:00
Jonas Kvinge
3960239cfe Add back WASAPI plugin again 2020-10-03 20:30:14 +02:00
Jonas Kvinge
b16e48af6f Add back WASAPI plugin again 2020-10-03 20:29:05 +02:00
Jonas Kvinge
4d3950565a Remove scangiomodulepath.cpp from CMakeLists.txt 2020-10-03 20:10:38 +02:00
Jonas Kvinge
8d24bc50c9 Change GST to GStreamer in debug logging 2020-10-03 20:08:33 +02:00
Jonas Kvinge
458efe9168 Remove gstreamer registry workaround for Windows 2020-10-03 20:05:30 +02:00
Jonas Kvinge
ae940a8681 Fix PRODUCT_NAME 2020-10-03 19:37:29 +02:00
Jonas Kvinge
d76b223b7c Fix typo 2020-10-03 19:36:10 +02:00
Jonas Kvinge
7243d5f7cb Add WASAPI plugin to own setup 2020-10-03 19:29:04 +02:00
Jonas Kvinge
387f74f66a Revert "Add back WASAPI plugin"
This reverts commit a553693f34.
2020-10-03 17:38:31 +02:00
Jonas Kvinge
61ffb7d97a Unref bus 2020-10-03 13:09:09 +02:00
Jonas Kvinge
a553693f34 Add back WASAPI plugin
Fixes #283
2020-10-03 02:03:37 +02:00
Jonas Kvinge
cdcfd64ec4 Possible fix for WASAPI crashes 2020-10-03 01:58:52 +02:00
Jonas Kvinge
7f4302ba20 Update Changelog 2020-10-02 22:09:40 +02:00
Jonas Kvinge
0d94f2d376 Update README 2020-10-02 22:09:33 +02:00
Jonas Kvinge
c1eb20a20b Force inform in Player::NextItem 2020-10-02 20:38:14 +02:00
Jonas Kvinge
634db67685 Change branch to master 2020-10-02 19:29:55 +02:00
Jonas Kvinge
86648258a3 Add CI for snap 2020-10-02 19:29:26 +02:00
Jonas Kvinge
287f0a3739 Remove redundant check for isNull() 2020-10-02 19:27:47 +02:00
Strawbs Bot
8f42df209a Update translations 2020-10-02 01:07:32 +02:00
Jonas Kvinge
390fd64a74 Save initial settings 2020-10-01 22:04:38 +02:00
Jonas Kvinge
48ee471def Remove force inform in PreviousItem 2020-10-01 20:30:31 +02:00
Jonas Kvinge
e862afcb78 Log song change 2020-10-01 20:09:36 +02:00
Jonas Kvinge
872da05ff6 Inform of song change on play restart, add playlist auto sorting.
Fixes #511
2020-10-01 19:58:16 +02:00
Jonas Kvinge
d09e2daf00 Mark backend settings changed if loaded engine, output or device does
not match the configured.
2020-10-01 19:53:07 +02:00
Jonas Kvinge
e2d5b44b0a Hide certain playlist list context menu options when items are not selected 2020-10-01 19:49:06 +02:00
Jonas Kvinge
52d42ef2a8 Use BUILD_WITH_QT6 2020-10-01 19:47:21 +02:00
Jonas Kvinge
b6abc34461 Set CollectionWatcher::sValidImages directly 2020-10-01 19:45:10 +02:00
Jonas Kvinge
ae6a50626d Change Qt 5/6 option 2020-10-01 19:43:39 +02:00
Jonas Kvinge
8f9dbfee2c Replace QMacCocoaViewContainer with QWidget::createWindowContainer 2020-10-01 19:40:55 +02:00
Jonas Kvinge
c71ccda967 Remove '&' in OSD messages
Causes weird problems with previous text getting stuck.
2020-10-01 19:39:49 +02:00
Strawbs Bot
0f284f2e1d Update translations 2020-10-01 01:01:35 +02:00
Jonas Kvinge
45ac80dd8c Change order of artist - title when song is paused/stopped in OSD 2020-09-30 01:14:00 +02:00
Jonas Kvinge
09cdba4b3d Fix minor code issues 2020-09-30 01:02:41 +02:00
Jonas Kvinge
d94ee8863c Fix playing widget stuck on error 2020-09-30 00:44:40 +02:00
Jonas Kvinge
cc8ced6430 Disable live scanning option 2020-09-30 00:03:06 +02:00
Jonas Kvinge
cdb144e6a6 Update Changelog 2020-09-29 23:26:55 +02:00
Jonas Kvinge
58fb8643c6 Fix typo in README 2020-09-29 23:26:26 +02:00
Jonas Kvinge
b81cfa8acb Update stream url to avoid requesting it twice 2020-09-29 23:03:50 +02:00
Jonas Kvinge
938ee20f1f Make sure song changed is only called once 2020-09-29 22:40:43 +02:00
Jonas Kvinge
d02dc54c1b Log remote cover loading 2020-09-29 22:30:44 +02:00
Jonas Kvinge
8680a54ae4 Only draw text when show/hide timeline is finished 2020-09-29 20:22:11 +02:00
Jonas Kvinge
30001be0ee Show song in OSD when pausing and stopping 2020-09-29 19:27:35 +02:00
Jonas Kvinge
4614cb5ec1 Make sure same cover isn't loaded twice 2020-09-29 17:51:31 +02:00
Jonas Kvinge
e390f3a399 Clear now playing in MainWindow::MediaPlaying() instead
Fixes #548
2020-09-29 17:38:00 +02:00
Jonas Kvinge
e22d463d11 Use QFileInfo::completeBaseName() instead of QFileInfo::baseName()
Fixes #550
2020-09-29 17:30:21 +02:00
Jonas Kvinge
5877aa822c Don't reset playing widget timeline 2020-09-29 01:07:04 +02:00
Strawbs Bot
a2915913bb Update translations 2020-09-29 01:02:40 +02:00
Jonas Kvinge
a8b40747b2 Attempt to improve playing widget up/down 2020-09-28 20:09:23 +02:00
Jonas Kvinge
b63030d302 Don't send now playing twice
Fixes #548
2020-09-28 17:47:45 +02:00
Strawbs Bot
4457e416db Update translations 2020-09-26 01:01:50 +02:00
Pascal Below
c7c1a8ede1 SubsonicRequest: create cover directory if it doesn't exist (#547) 2020-09-25 15:46:25 +02:00
Jonas Kvinge
fd1e9d7fb0 Fix clearing sent in scrobbler cache 2020-09-24 17:02:43 +02:00
Strawbs Bot
59a6d2317b Update translations 2020-09-24 01:02:04 +02:00
Jonas Kvinge
531c171542 Merge branch 'debian' into master 2020-09-23 19:06:22 +02:00
Jonas Kvinge
0c743452b0 Only compile Subsonic scrobbler when compiled with Subsonic support 2020-09-23 18:55:22 +02:00
Jonas Kvinge
4893d3da1f Add back debian bullseye and add dh-make to ubuntu too 2020-09-23 18:42:56 +02:00
Jonas Kvinge
5cdc24bfb0 Reload Subsonic scrobbler settings 2020-09-23 18:31:09 +02:00
Jonas Kvinge
523cdca449 Add back dh-make 2020-09-23 18:23:59 +02:00
Jonas Kvinge
09537d73da Remove debian bullseye CI 2020-09-23 18:10:13 +02:00
Jonas Kvinge
99c0c0b3b1 Update Changelog 2020-09-23 17:59:51 +02:00
Pascal Below
45bc353341 Add Subsonic scrobble support (#545)
* add SubsonicScrobbler, add Scrobble method in SubsonicService

* new class SubsonicScrobbleRequest, use queue again, clean up

* add checkbox to enable server-side scrobbling to Subsonic settings page

* Check serversidescrobbling in SubsonicScrobbler::ReloadSettings instead of SubsonicService

TODO: SubsonicScrobbler::ReloadSettings needs to be called when
SubsonicSettings change.
2020-09-23 17:55:12 +02:00
Strawbs Bot
b2fc41a911 Update translations 2020-09-23 01:02:50 +02:00
Jonas Kvinge
ebefe8b6d2 Update copyright 2020-09-23 00:55:34 +02:00
Jonas Kvinge
9e3508134b Add compilation to edit tag dialog 2020-09-23 00:52:41 +02:00
Jonas Kvinge
3166ca2127 Use QRecursiveMutex 2020-09-22 18:58:44 +02:00
Jonas Kvinge
204508478f Don't ignore closeevent if already hidden
Possible fix for #277
2020-09-22 18:40:37 +02:00
Strawbs Bot
51ce674c97 Update translations 2020-09-22 01:02:29 +02:00
Jonas Kvinge
6fcde9fe5f Add qobuz to scrobbler settings 2020-09-22 00:00:02 +02:00
Jonas Kvinge
c688e3431d Fix debian builds 2020-09-20 15:55:25 +02:00
Jonas Kvinge
230376c7f3 Ignore unused variable in MoveToTrashRecursive 2020-09-20 14:55:52 +02:00
Jonas Kvinge
91d0a2cd0c Fix uninitialized variable 2020-09-19 02:10:16 +02:00
Jonas Kvinge
1ffd010e4a Add windows.h include to MM device finder
Fixes compile error with mingw-w64 8.0.0
2020-09-19 02:06:15 +02:00
Strawbs Bot
ae366e141f Update translations 2020-09-19 01:01:38 +02:00
Strawbs Bot
eb869c6e97 Update translations 2020-09-18 01:08:32 +02:00
Jonas Kvinge
b559f7cd16 Fix minor code issues 2020-09-17 18:12:14 +02:00
Jonas Kvinge
375d32f08e Add missing utilities include 2020-09-17 18:01:24 +02:00
Jonas Kvinge
89d6b7cec0 Add smart playlists, ratings and Qobuz
Fixes #259
Fixes #264
2020-09-17 17:50:17 +02:00
Jonas Kvinge
fdf96e8342 Update README 2020-09-17 17:49:39 +02:00
Jonas Kvinge
c5d73d7b09 Update Changelog 2020-09-17 17:49:25 +02:00
Jonas Kvinge
34b4cc2d9e Remove unused function 2020-09-17 17:28:32 +02:00
Jonas Kvinge
40ed17e609 Change defaults for context 2020-09-17 17:12:01 +02:00
Jonas Kvinge
673d76af45 Change defaults for Tidal 2020-09-17 17:07:54 +02:00
Jonas Kvinge
c13fb6f9d5 Use QLibraryInfo::path with Qt 6 2020-09-17 17:00:45 +02:00
Jonas Kvinge
424b1e7d1f Fix strawberry.spec for Mageia 2020-09-17 16:28:16 +02:00
Jonas Kvinge
e80c9c4101 Fix strawberry.spec for CentOS and Mageia 2020-09-16 19:21:37 +02:00
Jonas Kvinge
f75c3633e9 Add Fedora 34 CI 2020-09-16 18:11:34 +02:00
Jonas Kvinge
d535cd8276 Add Fedora 33 to CI 2020-09-16 18:08:33 +02:00
Jonas Kvinge
c13f6ab2af Remove brew unlink python@2 2020-09-16 18:05:49 +02:00
Jonas Kvinge
d2a30bfb78 Simplify strawberry.spec 2020-09-16 18:03:34 +02:00
Jonas Kvinge
e5b17092b4 Fix stretchheaderview column widths too wide 2020-09-16 00:01:16 +02:00
Strawbs Bot
466cb4c78b Update translations 2020-09-15 01:01:29 +02:00
Strawbs Bot
9722e1ddc4 Update translations 2020-09-13 01:01:42 +02:00
Jonas Kvinge
e3a9b0b943 Use collection settings for group by settings 2020-09-12 15:48:26 +02:00
Jonas Kvinge
d668a8aee2 Change sort text for divider keys
Fixes problems on Windows with specific regionale settings, where
divider keys are all on the top, while albums are on the bottom
2020-09-12 13:30:45 +02:00
Strawbs Bot
75dc0aafcf Update translations 2020-09-12 01:02:03 +02:00
Jonas Kvinge
41b94233c6 Add group by version check in internet search view too 2020-09-12 00:32:50 +02:00
Jonas Kvinge
52cff01b9c Fix group by version 2020-09-12 00:18:08 +02:00
Jonas Kvinge
372fc6603d Update .github/workflows/ccpp.yml 2020-09-11 23:35:21 +02:00
Jonas Kvinge
9221797c9d Add sqlite3.exe to nsi 2020-09-11 22:58:56 +02:00
Strawbs Bot
7501131558 Update translations 2020-09-11 01:04:26 +02:00
Jonas Kvinge
bba7be99a3 Remove override.h 2020-09-10 23:41:53 +02:00
Jonas Kvinge
abb95534d0 Add musepack to macdeploy 2020-09-10 23:06:10 +02:00
Jonas Kvinge
0b7b4c12e4 Add test for collection model container nodes 2020-09-10 22:13:20 +02:00
Jonas Kvinge
4056f00169 Only initialize translations in test when compiled with translations 2020-09-10 22:11:40 +02:00
Jonas Kvinge
10303cb9c0 Use unique keys for all container nodes in collection model
Fixes #539 and probably many more issues with the model.
2020-09-10 22:09:24 +02:00
Jonas Kvinge
e3587d369e Add const 2020-09-10 22:05:12 +02:00
Jonas Kvinge
2a048502cc Add PlaylistItem::NewFromSong function 2020-09-10 22:04:11 +02:00
Jonas Kvinge
cac01fbde9 Dont seperate compilation albums by directory in GetAlbums
Fixes issue where multi-disc albums are showing more than once in cover
manager.
2020-09-10 21:27:07 +02:00
Jonas Kvinge
2d2ce191ec Change gstreamer libraries in macdeploy 2020-09-10 19:15:06 +02:00
Jonas Kvinge
6380cb8458 Add brew upgrade step in CI 2020-09-10 19:14:33 +02:00
Jonas Kvinge
48e0e6af71 Ignore Radio Paradise "commercial" break for cover and lyrics search 2020-09-10 17:17:55 +02:00
Jonas Kvinge
b756bccc7a Link to iconv to fix compile on Windows 2020-09-10 17:14:14 +02:00
Jonas Kvinge
ae8eed7a67 Add ffmpeg to nsi 2020-09-10 17:12:18 +02:00
Strawbs Bot
ae4882bec3 Update translations 2020-09-10 01:03:26 +02:00
Strawbs Bot
1379741859 Update translations 2020-09-09 01:02:25 +02:00
Jonas Kvinge
b45c7ace78 Fix show equalizer signal slot connect 2020-09-08 18:12:18 +02:00
Strawbs Bot
3843d9f55b Update translations 2020-09-06 01:02:20 +02:00
Jonas Kvinge
f3422cb2fe Call raise() on dialogs to make sure they are on top
Fixes #535
2020-09-05 19:54:21 +02:00
Jonas Kvinge
73692797dc Fix QWidget::enterEvent with Qt 6 2020-09-05 19:20:43 +02:00
Jonas Kvinge
31dd910289 Make sure albums in cover manager are unique
Fixes #529
2020-09-05 18:59:35 +02:00
Jonas Kvinge
da51580299 Fix year - album collection grouping
Fixes #534
2020-09-05 17:26:42 +02:00
Strawbs Bot
9db148b1ec Update translations 2020-09-05 01:03:16 +02:00
Jonas Kvinge
091b1b8209 Use QKeyCombination with Qt 6 2020-09-04 23:00:42 +02:00
Jonas Kvinge
900a4071ed Use bytearray for qChecksum with Qt 6 2020-09-04 21:54:59 +02:00
Jonas Kvinge
df4b2f7938 Add icon for edit tag playlist right click menu actions
Fixes #531
2020-09-04 20:55:57 +02:00
Jonas Kvinge
803f44d9bc Disable use system icons setting for macOS and Windows
Fixes #532
2020-09-04 20:51:43 +02:00
Jonas Kvinge
4b67aee020 Use | operator for QShortcut 2020-09-04 20:43:02 +02:00
Jonas Kvinge
71dc47d6c9 Use deleteLater() when destroying lazy initialized objects
Fixes #530
2020-09-04 20:25:46 +02:00
Strawbs Bot
9cb305fb0d Update translations 2020-09-04 01:02:02 +02:00
Jonas Kvinge
1672130486 Merge compilation off/off
Fixes #528
2020-09-03 19:20:59 +02:00
Jonas Kvinge
8e135e3e79 Set compilation for "Various Artists" in album artist tag too 2020-09-03 19:20:11 +02:00
Jonas Kvinge
aa1a4f6ea5 Update verify icons script 2020-09-03 17:04:40 +02:00
Jonas Kvinge
ba34cf5258 Possible fix for crash when deleting queued songs from playlist
See #527
2020-09-03 16:59:18 +02:00
Strawbs Bot
647089d2a8 Update translations 2020-09-03 01:02:25 +02:00
Jonas Kvinge
5211508eb4 Add multimedia-player-ipod-standard-black.png 2020-09-02 23:20:01 +02:00
Jonas Kvinge
e6f05ae465 Make sure icon exists in GuessIconForPath 2020-09-02 20:40:07 +02:00
Jonas Kvinge
a9193f9b76 Move itdb_device_free 2020-09-02 20:03:22 +02:00
Jonas Kvinge
e373a17cd3 Fallback to device-ipod for ipod icon name 2020-09-02 19:36:47 +02:00
Jonas Kvinge
ebab9b7e4a Delete deviceinfo using parent object 2020-09-02 19:35:13 +02:00
Jonas Kvinge
6de0399807 Guess icon for device in udisks2 lister 2020-09-02 19:34:46 +02:00
Strawbs Bot
5cc7bb80f6 Update translations 2020-09-02 01:11:51 +02:00
Jonas Kvinge
6e0bd9b3f8 Add override to LastFMImportDialog::closeEvent() 2020-09-01 22:27:34 +02:00
Jonas Kvinge
d1943f72d3 Remove use of Qt::AA_UseHighDpiPixmaps with Qt 6 2020-09-01 21:05:07 +02:00
Jonas Kvinge
81709873bd Use art_manual for itdb thumbnail 2020-09-01 20:59:19 +02:00
Jonas Kvinge
f6bb7cd8ed Only include Dmg.cmake on macOS 2020-09-01 20:40:14 +02:00
Jonas Kvinge
d1c19e431c Add check for gdk-pixbuf-2.0 2020-09-01 20:27:05 +02:00
Jonas Kvinge
9ab2dde8ab Read tumbnails from itdb tracks 2020-09-01 01:04:01 +02:00
Jonas Kvinge
71559bb125 Turn pretty covers on by default in collection model 2020-09-01 01:02:02 +02:00
Strawbs Bot
ae4c95262c Update translations 2020-09-01 01:01:45 +02:00
Jonas Kvinge
dbbf07c9c1 Specify JPG when saving cover to temp file for iPod's 2020-08-31 20:13:53 +02:00
Jonas Kvinge
ab8cd619d5 Save cover image to file before copying to iPod
Fixes #519
2020-08-31 18:38:54 +02:00
Jonas Kvinge
c30ad2819d Disable use of HTML in system tray tooltip on Cinnamon 2020-08-31 18:06:37 +02:00
Jonas Kvinge
311e91797a Update ISSUE_TEMPLATE.md 2020-08-31 17:53:46 +02:00
Jonas Kvinge
52be4df355 Use only one issue template 2020-08-31 17:52:16 +02:00
Jonas Kvinge
0364e81050 Remove mageia from Circle CI 2020-08-31 17:15:31 +02:00
Jonas Kvinge
2d49b71bc9 Read song creation time from subsonic API
Fixes #526
2020-08-31 17:05:09 +02:00
Jonas Kvinge
a18a4bdf31 Set wordwrap 2020-08-31 16:25:01 +02:00
Strawbs Bot
d3acbe8288 Update translations 2020-08-31 01:04:42 +02:00
Jonas Kvinge
22afcbcbb6 Only allow playlist editing if song is editable
Set proper flags in model instead of overriding edit in view.

Proper fix for #524
2020-08-30 22:23:38 +02:00
Jonas Kvinge
495c6bc21c Remove unused StyleHelper::drawIconWithShadow function 2020-08-30 21:51:26 +02:00
Jonas Kvinge
cfd1fe59f3 Only allow playlist editing if song is editable.
Fixes #524
2020-08-30 21:40:04 +02:00
Jonas Kvinge
c46cf5bc84 Check for missing lyrics 2020-08-30 21:13:31 +02:00
Jonas Kvinge
a8742557bd Add lyrics from fandom.com 2020-08-30 21:06:58 +02:00
Jonas Kvinge
3bea58cf56 Fix resetting last.fm import dialog on close when finished 2020-08-30 18:28:51 +02:00
Jonas Kvinge
5aaa5231b8 Add Last.fm import
Fixes #247
2020-08-30 18:09:13 +02:00
Jonas Kvinge
82d10dd7cb Remove debug line 2020-08-30 01:59:26 +02:00
Jonas Kvinge
841065fb91 Load icons for buttons before setting enabled/disabled
Fixes #500
2020-08-30 01:57:21 +02:00
Strawbs Bot
c7146ef138 Update translations 2020-08-30 01:02:19 +02:00
Jonas Kvinge
08f32d1de6 Refactor playlist view/header code
- Don't reload all settings when changing playlists
- Fix initial playlist header columns sizes
- Properly reset header state when resetting columns
2020-08-29 19:55:00 +02:00
Jonas Kvinge
4c3f86aa4d Remove use of Qt::AA_EnableHighDpiScaling with Qt 6 2020-08-29 19:18:56 +02:00
Jonas Kvinge
445cf22333 Use deleteLater 2020-08-29 16:24:40 +02:00
Strawbs Bot
4919de647a Update translations 2020-08-28 01:01:40 +02:00
Jonas Kvinge
77fae99528 Fix spacing for sources in scrobbling settings
Fixes #523
2020-08-27 23:36:09 +02:00
Jonas Kvinge
10bd4b40b9 Switch branch for macOS upload 2020-08-27 22:51:34 +02:00
Jonas Kvinge
9d8e6bb253 Merge branch 'macos' into master 2020-08-27 22:50:11 +02:00
Jonas Kvinge
49c71ecfad Update macOS CI 2020-08-27 22:11:19 +02:00
Strawbs Bot
d18834b415 Update translations 2020-08-27 01:02:03 +02:00
Jonas Kvinge
e52cda193e Replace QAbstractItemView::viewOptions with initViewItemOption 2020-08-26 23:35:33 +02:00
Jonas Kvinge
0d5edd35ea Register ColumnAlignmentMap 2020-08-26 22:36:09 +02:00
Strawbs Bot
f3f51c3d9d Update translations 2020-08-26 01:08:17 +02:00
Jonas Kvinge
1431916183 Add setting for enabling scrobbling based on song source
Fixes #416
2020-08-25 23:44:27 +02:00
Jonas Kvinge
ae48008803 Remove use of qRegisterMetaTypeStreamOperators with Qt 6 2020-08-25 22:48:21 +02:00
Jonas Kvinge
5664813931 Remove Mageia from GitHub CI 2020-08-25 21:57:09 +02:00
Jonas Kvinge
3948af80b8 Fix pixelated source icon for currently playing song in playlist 2020-08-25 21:51:23 +02:00
Strawbs Bot
343d6f9aff Update translations 2020-08-24 01:03:49 +02:00
Jonas Kvinge
51b379502f Always use qint32 for QDBusArgument 2020-08-23 21:55:34 +02:00
Jonas Kvinge
82142751de Improve playlist autoscrolling
Fixes #420
2020-08-23 19:37:24 +02:00
Jonas Kvinge
4e5755f218 Refactor some functions 2020-08-23 19:17:50 +02:00
Jonas Kvinge
2f4f29517e Create new contructor for UrlHandler 2020-08-23 18:52:30 +02:00
Strawbs Bot
e8a073651f Update translations 2020-08-23 05:53:13 +02:00
Jonas Kvinge
d23da7a612 Replace Qt::MidButton with Qt::MiddleButton 2020-08-23 03:27:24 +02:00
Jonas Kvinge
1ae4938da3 Register D-Bus metatype for QImage if system has D-Bus 2020-08-23 03:20:53 +02:00
Jonas Kvinge
b5e27d4d69 Declare QDBusArgument for QImage in osddbus.h 2020-08-23 03:19:40 +02:00
Jonas Kvinge
d74fc8d1ce Fix macoOS builds in Travis CI 2020-08-22 14:02:12 +02:00
Jonas Kvinge
c5d9a41967 Remove tumbleweed from CircleCI 2020-08-22 00:27:12 +02:00
Jonas Kvinge
7e3042c4f4 Remove AA_DontShowIconsInMenus
Possible fix for #516
2020-08-21 23:40:44 +02:00
Jonas Kvinge
1291dadbd6 Replace use of QStringRef 2020-08-21 22:39:01 +02:00
Jonas Kvinge
f645099a39 Remove FMPS parser 2020-08-21 22:38:40 +02:00
Jonas Kvinge
8f32038891 Add missing musicstorage include 2020-08-19 22:35:35 +02:00
Jonas Kvinge
a6fb1dcdf9 Add missing QWindow include 2020-08-19 22:35:22 +02:00
Jonas Kvinge
f01b469f3f Allow to delete files permanently in fileview with Qt < 5.15 2020-08-19 22:25:05 +02:00
Jonas Kvinge
47884919c8 Only show delete files option in setting with Qt >= 5.15 2020-08-19 22:11:03 +02:00
Jonas Kvinge
653a35496d Add optional delete from disk in collection and playlist
Fixes #284
2020-08-19 22:02:35 +02:00
Jonas Kvinge
9b14df6b27 Use static_cast in QComboBox::findData 2020-08-16 18:22:10 +02:00
Jonas Kvinge
09813f3c5a Turn back git revision 2020-08-16 03:02:27 +02:00
Jonas Kvinge
7d76b7e4c2 Update protobuf version in nsi 2020-08-15 23:15:51 +02:00
Jonas Kvinge
47b5dea95c Release 0.7.2 2020-08-15 23:01:56 +02:00
Jonas Kvinge
b0df63f1e8 Fix translations dir 2020-08-15 23:01:28 +02:00
Jonas Kvinge
3c4209b676 Add more compilation titles 2020-08-15 17:33:54 +02:00
Jonas Kvinge
d51b9a8e0e Add more compilation titles 2020-08-15 17:29:30 +02:00
Jonas Kvinge
3b56125bd2 Increase maximum time step for seeking to 120
Fixes #509
2020-08-15 15:18:58 +02:00
Jonas Kvinge
6e69e39007 Use static_cast instead for destroyed object 2020-08-15 15:16:06 +02:00
Jonas Kvinge
97208cb329 Add --auto to urpmi command for Mageia CI 2020-08-15 11:55:49 +02:00
Jonas Kvinge
414a4a97fb Use unicode option when replacing non-words
Fixes #513
2020-08-15 11:43:14 +02:00
Jonas Kvinge
2a809f96c4 Update Changelog 2020-08-15 11:31:29 +02:00
Jonas Kvinge
17799b03f3 Fix installation directory for translations
Fixes #512
2020-08-15 11:08:47 +02:00
Jonas Kvinge
efc55fc648 Fix typo in snapcraft.yaml 2020-08-15 02:36:54 +02:00
Jonas Kvinge
22bd41211a Turn back git revision 2020-08-15 02:36:37 +02:00
Jonas Kvinge
4cb0171bd0 Release 0.7.1 2020-08-15 00:44:28 +02:00
Strawbs Bot
ce6c5af72c Update translations 2020-08-15 00:25:52 +02:00
Jonas Kvinge
171575256c Remove broken iPhone (libimobiledevice) support
Fixes #212
2020-08-14 21:38:08 +02:00
Jonas Kvinge
d3664dcf78 Set QNetworkRequest::RedirectPolicyAttribute with Qt >= 5.9 2020-08-14 20:31:04 +02:00
Jonas Kvinge
0788981783 Set QNetworkRequest::RedirectPolicyAttribute with Qt >= 5.9 2020-08-14 20:20:41 +02:00
Jonas Kvinge
aeee7c02d5 Update Changelog 2020-08-14 18:39:56 +02:00
Jonas Kvinge
6e49a50461 Update Changelog 2020-08-14 18:38:50 +02:00
Jonas Kvinge
fbc99827ab Revert "Turn off sort indicators for playlist"
This reverts commit 7b50ec4630.
2020-08-14 17:30:27 +02:00
Jonas Kvinge
3b134320c4 Fix minor issue in cue parser with date and genre 2020-08-13 21:14:12 +02:00
Jonas Kvinge
c315e5016d Change mtime and ctime to qint64 2020-08-13 21:09:06 +02:00
Jonas Kvinge
7aebd6ed57 Only install translations if HAVE_TRANSLATIONS is set 2020-08-13 21:05:09 +02:00
Jonas Kvinge
1a8ca06495 Only install translations when INSTALL_TRANSLATIONS is set 2020-08-13 20:55:53 +02:00
Jonas Kvinge
a27ae7e4a6 Add CMake option to install translations
Fixes #485
2020-08-13 19:53:36 +02:00
Strawbs Bot
dd0ab897aa Update translations 2020-08-13 01:03:32 +02:00
Jonas Kvinge
00ad92fb6d Hide unavailable collection context menu actions 2020-08-12 21:34:42 +02:00
Jonas Kvinge
f84128ecbd Remove unused collection playlist container type 2020-08-12 21:33:38 +02:00
Jonas Kvinge
ba89e0f4e3 Fix MockPlaylistItem 2020-08-12 20:03:45 +02:00
Jonas Kvinge
832d36a4d4 Add Qt 6 option to strawberry.nsi 2020-08-12 18:07:21 +02:00
Jonas Kvinge
0b437b3bfb Use standard text color for links in about
Fixes #508
2020-08-12 17:27:08 +02:00
Jonas Kvinge
7b50ec4630 Turn off sort indicators for playlist
Fixes #511
2020-08-12 16:56:28 +02:00
Jonas Kvinge
4ddb13abac Increase maximum time step for seeking to 60
Fixes #509
2020-08-12 16:31:32 +02:00
Jonas Kvinge
d2ac081177 Fix taglib cmake type size checks 2020-08-11 16:23:07 +02:00
Strawbs Bot
9692fbf15b Update translations 2020-08-11 01:02:03 +02:00
Jonas Kvinge
be966488e8 Fix OSD D-Bus assertion with Qt 6 2020-08-10 23:05:07 +02:00
Jonas Kvinge
0ce613264f Make sure to always use original metadata when editing tags 2020-08-10 21:32:14 +02:00
Jonas Kvinge
34634d776e Make sure to always use original metadata when editing tags 2020-08-10 21:27:56 +02:00
Jonas Kvinge
673ded3819 Add proper check for collection song in edit tag dialog 2020-08-10 21:27:27 +02:00
Jonas Kvinge
b9a94ad3ae Default originalyear to -1 2020-08-10 18:06:20 +02:00
Jonas Kvinge
3f80b330cc Log artist and album name 2020-08-10 18:05:52 +02:00
Jonas Kvinge
01632d538c Decrease score for more compilation albums 2020-08-10 17:39:40 +02:00
Strawbs Bot
b0a9b1cd09 Update translations 2020-08-10 01:05:14 +02:00
Jonas Kvinge
1f772081fd Only update temporary metadata when set
Fixes #507
2020-08-10 00:32:57 +02:00
Jonas Kvinge
4ae54dbaad Decrease score for more compilation albums 2020-08-09 20:58:27 +02:00
Jonas Kvinge
e47f4ff731 Fix musixmatch cover size 2020-08-09 20:15:24 +02:00
Jonas Kvinge
465369d79e Base initial score on album cover sizes retrieved from API 2020-08-09 20:10:53 +02:00
Jonas Kvinge
15ddf6ff20 Save and restore playlist scrollbar position when switching between playlists 2020-08-09 14:00:56 +02:00
Jonas Kvinge
16a753bd95 Treat erors returned by the URL handler as non fatal
Fixes #505
2020-08-09 02:52:18 +02:00
Jonas Kvinge
c15103636c Fix NotificationPreview signal slot 2020-08-09 02:07:22 +02:00
Jonas Kvinge
8a5f82ee7d Tidal: Only return streamable songs in result
Fixes #505
2020-08-09 01:59:28 +02:00
Jonas Kvinge
5ec33ec821 Tidal: Show API error instead of network error when available 2020-08-09 01:50:03 +02:00
Jonas Kvinge
ab7d383cf1 Use virtual functions for OSD 2020-08-09 01:37:00 +02:00
Strawbs Bot
184e9a5c93 Update translations 2020-08-09 01:01:43 +02:00
Jonas Kvinge
c4f5363cde Properly enable/disable queue buttons depending on selection 2020-08-08 20:36:03 +02:00
Jonas Kvinge
002882cebf Build Qt 6 without linguist, qtbase code keeps updating breaking qt-tools 2020-08-08 19:20:27 +02:00
Jonas Kvinge
1cb3ec0c7b Only add autocomplete tags to playlist menu when we have chromaprint and gstreamer 2020-08-08 19:05:14 +02:00
Jonas Kvinge
6bf325c6f6 Fix QSslSocket::ignoreSslErrors compile error with Qt 6 2020-08-08 19:04:44 +02:00
Strawbs Bot
09c7ff9e8b Update translations 2020-08-08 01:01:46 +02:00
Jonas Kvinge
c2a94b61bf Fixes to playlist context menu
- Add all playlist actions to initialization list
- Make rescan songs work for non-collection songs by using playlist item reload
- Only show add to another playlist and remove from playlist when songs are selected
- Add some missing icons

Fixes #503
2020-08-07 22:13:02 +02:00
Jonas Kvinge
1db16232de Only show rescan songs for collection songs
Fixes #503
2020-08-07 21:18:48 +02:00
Jonas Kvinge
3da681a6b1 Add fatal error for missing protobuf compiler 2020-08-07 19:43:03 +02:00
Strawbs Bot
a79b3e7852 Update translations 2020-08-07 01:03:20 +02:00
Jonas Kvinge
b1099e6974 Handle metadata with tilde in title 2020-08-07 00:52:09 +02:00
Jonas Kvinge
4f6e06131c Change allow album cover search check 2020-08-07 00:28:46 +02:00
Jonas Kvinge
19f69e9e6c Allow cover search only using either artist, album or title 2020-08-07 00:18:31 +02:00
Jonas Kvinge
01481da773 Use Qt::QueuedConnection for cover fetcher 2020-08-06 23:55:44 +02:00
Jonas Kvinge
3e8f7e1cf1 Register CoverSearchStatistics metatype 2020-08-06 23:54:54 +02:00
Jonas Kvinge
5da69646f2 Add authentication for Qobuz cover provider 2020-08-06 22:57:44 +02:00
Jonas Kvinge
3cac01583b Add username password dialog 2020-08-06 22:54:21 +02:00
Jonas Kvinge
d16a26605e Fix updating playlist songs when there are multiple files with the same URL
Fixes #501
2020-08-06 21:40:42 +02:00
Jonas Kvinge
a4f692c788 Only show playlist add file(s) to transcoder when songs are selected 2020-08-06 18:37:17 +02:00
Jonas Kvinge
9f01206c57 Only show open in file browser when songs are selected 2020-08-06 18:36:52 +02:00
Jonas Kvinge
d34fc551ed Add playlist right click option to copy URL 2020-08-06 18:29:35 +02:00
Jonas Kvinge
7aa5f0d258 Only show delete and save playlist button when item is selected
Fixes #500
2020-08-06 16:00:03 +02:00
Jonas Kvinge
276a34bb66 Fix parsing Tidal track duration with Qt 6 2020-08-06 15:58:53 +02:00
Jonas Kvinge
0d820eda12 Remove diacritics in FTS search 2020-08-05 23:31:52 +02:00
Strawbs Bot
1991c1b677 Update translations 2020-08-05 01:02:22 +02:00
Jonas Kvinge
459404e3f0 Rename organise to organize
Prefer US spelling
2020-08-04 21:18:14 +02:00
Jonas Kvinge
badc623a3c Update Changelog 2020-08-03 21:53:31 +02:00
Jonas Kvinge
8e39f92cb7 Make album optional when reading scrobbles from cache 2020-08-03 21:50:26 +02:00
Jonas Kvinge
3ff4885973 Fix reading ASF comment tag 2020-08-03 21:03:14 +02:00
Jonas Kvinge
f9d45f7657 Fix reading and saving MP4 lyrics tag 2020-08-03 20:44:25 +02:00
Jonas Kvinge
789ff9df5c Add SUPublicEDKey Info.plist 2020-08-03 19:31:28 +02:00
Jonas Kvinge
a2064ed16b Always bundle libraries provided by homebrew
Fixes #343
2020-08-03 00:14:17 +02:00
Jonas Kvinge
b3d06c0868 Make macdeploy properly handle loader_path and libicudata 2020-08-02 17:02:28 +02:00
Jonas Kvinge
db1a6b3e38 Manually copy libicudata for macOS deploy
Fixes #498
2020-08-02 15:47:39 +02:00
Jonas Kvinge
8390237cc4 Fix Sparkle integration for macOS 2020-08-02 06:32:01 +02:00
Jonas Kvinge
9967eae7bb Decrease album cover score if artist doesn't match and cover isn't requested using album title 2020-08-02 04:34:15 +02:00
Jonas Kvinge
b3be7d1c6f Add CI for Qt 6 2020-08-02 04:19:39 +02:00
Jonas Kvinge
33ccb5dbb2 Remove duplicate check for X11 2020-08-02 04:18:40 +02:00
Strawbs Bot
5b90c0d695 Update translations 2020-08-02 01:07:53 +02:00
Jonas Kvinge
472a660239 Update README.md 2020-08-01 23:46:59 +02:00
Jonas Kvinge
ab67536d9a Prevent compilation and live albums from being picked before studio albums for album cover searches based on artist + song title 2020-08-01 23:17:35 +02:00
Jonas Kvinge
ee85fb3aec Use QString() on non-translated text in collection filter widget 2020-08-01 22:50:02 +02:00
Jonas Kvinge
214b6f4358 Use correct qt sparkle include for Qt 6 2020-08-01 03:41:48 +02:00
Jonas Kvinge
af0d092054 Use sparkle to check for updates on macOS and Windows 2020-08-01 03:37:16 +02:00
Jonas Kvinge
b07903c3e9 Register QVector<int> 2020-08-01 03:32:25 +02:00
Jonas Kvinge
ffa4c6bf09 Add SUFeedURL to Info.plist 2020-08-01 03:31:29 +02:00
Jonas Kvinge
b4125fa56c Remove create-dmg.sh script and use create-dmg directly from CMake 2020-08-01 03:31:01 +02:00
Jonas Kvinge
2c72302087 Install sparkle for macOS builds 2020-08-01 03:28:43 +02:00
Jonas Kvinge
0fa52bc64f Fix macdeploy script 2020-08-01 03:28:01 +02:00
Jonas Kvinge
f55a80b15a Use Q_UNUSED 2020-08-01 03:23:50 +02:00
Strawbs Bot
0735483321 Update translations 2020-08-01 01:01:36 +02:00
Jonas Kvinge
53fc2c7c21 Add extra safety for overwriting files for filesystem storage 2020-07-31 21:45:01 +02:00
Jonas Kvinge
f22133c3c5 Fix translations for Qt 6 2020-07-30 20:49:24 +02:00
Jonas Kvinge
2d5a6d6583 Use album artist for album repeat mode 2020-07-30 20:46:30 +02:00
Strawbs Bot
dc4adf2836 Update translations 2020-07-30 01:01:45 +02:00
Jonas Kvinge
dd6e254e4f Use quotes in collection query to allow special characters
Fixes #492
2020-07-29 21:41:35 +02:00
Jonas Kvinge
4c028c1659 Use position().toPoint() with Qt 6 2020-07-29 21:40:03 +02:00
Jonas Kvinge
d332a6777a Use QSortFilterProxyModel::filterRegularExpression only with Qt 6 2020-07-29 21:39:02 +02:00
Strawbs Bot
378251f229 Update translations 2020-07-29 01:01:35 +02:00
Strawbs Bot
b6b9b903ed Update translations 2020-07-28 01:01:37 +02:00
Strawbs Bot
143d68cfd5 Update translations 2020-07-27 01:01:53 +02:00
Jonas Kvinge
a31eac1426 Base warning for show in file browser on unique directories
Fixes #484
2020-07-26 15:10:00 +02:00
Jonas Kvinge
797196f7fc Register column aligment as int too 2020-07-26 15:05:00 +02:00
Chongo Bong
c9d0bc81dd simple addition of playlist actions to icon (#490)
very simple addition of playlist/playback actions to strawberry's icon. this re-introduces some nice little polish that was present in clementine's .desktop file.
2020-07-24 20:38:17 +02:00
Strawbs Bot
b5448ff607 Update translations 2020-07-22 01:01:41 +02:00
Jonas Kvinge
5ebd363d5d Fixes to last.fm scrobbling
- Start array notation for parameters at 0
- Correctly send trackNumber
2020-07-21 03:14:02 +02:00
Strawbs Bot
1d439e673e Update translations 2020-07-20 01:05:14 +02:00
Jonas Kvinge
0b7b7656b2 Replace use of QRegExp 2020-07-20 00:57:42 +02:00
Jonas Kvinge
eb270df835 Use std::bind in QtConcurrent::run() to fix compile with Qt 6 2020-07-19 22:43:58 +02:00
Jonas Kvinge
ff73dd2183 Partial revert commit af67de8 2020-07-19 19:07:12 +02:00
Strawbs Bot
e043a03eb6 Update translations 2020-07-19 15:23:03 +02:00
Jonas Kvinge
3cb4e8e373 Fix OSD Pretty margin 2020-07-19 04:09:34 +02:00
Jonas Kvinge
7e6de528b4 Update Last.fm error codes 2020-07-19 03:47:21 +02:00
Jonas Kvinge
df901c30ef Use QString() for html codes in about dialog 2020-07-19 03:46:41 +02:00
Jonas Kvinge
13856b33ec Fix playlist filter with Qt 5 2020-07-18 22:37:49 +02:00
Jonas Kvinge
a3a1c6f4c8 Fix saving playlist column alignment 2020-07-18 18:18:34 +02:00
Jonas Kvinge
638998a861 Replace QTimeLine::CurveShape with QEasingCurve 2020-07-18 17:53:14 +02:00
Jonas Kvinge
6e2ec89a05 Use QMouseEvent::pos() 2020-07-18 17:35:03 +02:00
Jonas Kvinge
af67de8aa6 Use lambdas for QtConcurrent::run instead of NewClosure 2020-07-18 16:28:39 +02:00
Jonas Kvinge
425dac478e Replace QProcess::error() with QProcess::errorOccurred() 2020-07-18 16:23:39 +02:00
Jonas Kvinge
b15c4ecd10 Fix check for context tab in TabSwitched
Broken with Qt 6
2020-07-18 15:52:36 +02:00
Jonas Kvinge
d7f88cf3a4 Register QItemSelection 2020-07-18 06:02:54 +02:00
Jonas Kvinge
5b7fbcd9b8 Remove debian stretch 2020-07-18 05:28:26 +02:00
Jonas Kvinge
7af64b0782 Fix QRegularExpressionMatch in FMPSParser 2020-07-18 05:02:34 +02:00
Jonas Kvinge
b84c70e811 Link Qt6::Core5Compat in libstrawberry-tagreader 2020-07-18 05:01:54 +02:00
Jonas Kvinge
f5b245c72d Add option to compile with Qt 6 2020-07-18 04:47:54 +02:00
Jonas Kvinge
4307183817 Fix utilities test 2020-07-18 04:32:37 +02:00
Jonas Kvinge
aeb32783d6 Only use QTextStream::setCodec() with Qt < 6 2020-07-18 04:27:21 +02:00
Jonas Kvinge
3927b3bf27 Remove QPainter::HighQualityAntialiasing 2020-07-18 04:26:19 +02:00
Jonas Kvinge
da9d2f9417 Replace QPalette::Background with QPalette::Window 2020-07-18 04:25:29 +02:00
Jonas Kvinge
1cec48e8f8 Use static_cast 2020-07-18 04:25:15 +02:00
Jonas Kvinge
f1105393da Replace QDateTime::toTime_t() with QDateTime::toSecsSinceEpoch() 2020-07-18 04:24:16 +02:00
Jonas Kvinge
dc7047e3c2 Use QLocale::LongFormat 2020-07-18 04:22:59 +02:00
Jonas Kvinge
08b2945623 Remove Qt 5.6 backward compatibility 2020-07-18 04:21:45 +02:00
Jonas Kvinge
cbcc223150 Replace QRegExp with QRegularExpression 2020-07-18 04:21:19 +02:00
Jonas Kvinge
9830f21e4a Use setContentsMargins() on layout 2020-07-18 04:20:20 +02:00
Jonas Kvinge
5f49567bf7 Make GlobalShortcut::nativeEventFilter compatible with Qt 6 2020-07-18 04:18:46 +02:00
Jonas Kvinge
6154ae7342 Move QDialogButtonBox signal/slot connect from UI file to class 2020-07-18 04:17:27 +02:00
Jonas Kvinge
978f3a3682 Add QSslError include 2020-07-18 04:16:31 +02:00
Jonas Kvinge
1f0961d574 Make MainWindow::nativeEvent compatible with Qt 6 2020-07-18 04:15:42 +02:00
Jonas Kvinge
a101252701 Make OSDPretty compatible with Qt 6 2020-07-18 04:15:19 +02:00
Jonas Kvinge
c96c29b1e3 Replace QRegExp with QRegularExpression 2020-07-18 04:14:51 +02:00
Jonas Kvinge
3b0fc180ff Make QListWidget::mimeData compatible with Qt 6 2020-07-18 04:13:53 +02:00
Jonas Kvinge
9b8bfdf33c Replace QPalette::Background with QPalette::Window 2020-07-18 04:12:50 +02:00
Jonas Kvinge
4328831fcd Use globalPosition() 2020-07-18 04:09:36 +02:00
Jonas Kvinge
e5b3df41e9 Replace QRegExp with QRegularExpression 2020-07-18 04:05:07 +02:00
Jonas Kvinge
cf5259e218 Add QActionGroup include 2020-07-18 03:54:52 +02:00
Jonas Kvinge
f24b6a520c Replace QDateTime::toTime_t() with QDateTime::toSecsSinceEpoch() 2020-07-18 03:53:30 +02:00
Jonas Kvinge
4140163ab2 Mark unused parameters 2020-07-17 16:36:24 +02:00
Jonas Kvinge
7afde0e93f Fix compile warning in qsearchfield_mac.mm 2020-07-17 16:35:57 +02:00
Jonas Kvinge
d27a571882 Ignore compile warning in SBSystemPreferences.h 2020-07-17 16:35:11 +02:00
Jonas Kvinge
1c70e3be25 Ignore format nonliteral in tutils.h 2020-07-17 16:34:37 +02:00
Jonas Kvinge
1819f64467 Disable deprecation warning for QMacCocoaViewContainer 2020-07-17 16:33:10 +02:00
Jonas Kvinge
9852e588c1 Change compile options 2020-07-17 16:32:37 +02:00
Jonas Kvinge
71a1ea481b Replace some uses of static_cast with qobject_cast 2020-07-17 01:32:07 +02:00
Jonas Kvinge
9e32f0d778 Silence some compile warnings with reinterpret cast 2020-07-16 22:46:31 +02:00
Jonas Kvinge
4478174dc2 Fix incorrectly mapped keys
Fixes #483
2020-07-16 22:28:35 +02:00
Jonas Kvinge
07553476d4 Remove xine 2020-07-16 00:59:46 +02:00
Jonas Kvinge
1773283456 Remove xine metronom.pts_per_smpls check 2020-07-16 00:44:41 +02:00
Jonas Kvinge
221ab51d90 Simply startup behaviour 2020-07-16 00:06:51 +02:00
Jonas Kvinge
43e0dd922b Hide settings that are unavailable on macOS in the settings 2020-07-16 00:05:49 +02:00
Jonas Kvinge
b3262652c3 Turn back git revision 2020-07-14 18:40:48 +02:00
Strawbs Bot
0cfa2b8c20 Update translations 2020-07-14 01:01:50 +02:00
Jonas Kvinge
c4600b2187 Release 0.6.13 2020-07-13 23:01:33 +02:00
Jonas Kvinge
89b15e3b57 Add taglib include dirs to unit test CMake file 2020-07-13 22:53:32 +02:00
Jonas Kvinge
07d8c3e770 Add .clang-format to excluded files in maketarball 2020-07-13 22:52:38 +02:00
Jonas Kvinge
c5ae64070e Add some include and link directories to unit test CMake
Fixes unit tests compile on macOS
2020-07-13 22:28:39 +02:00
Jonas Kvinge
2cb7c52147 Update README.md 2020-07-13 20:40:34 +02:00
Jonas Kvinge
c045b16213 Update README.md 2020-07-13 20:39:01 +02:00
Jonas Kvinge
b29387d409 More fancy tabbar fixes
- Only use custom size override for large and small sidebar modes
- Use scroll buttons by default
- Set elide text mode off because macOS has it on by default
- Set tooltip for top icon only mode
- Set icon sizes except for on macOS
2020-07-13 18:29:48 +02:00
Jonas Kvinge
614a09db1d Fix some compile warnings 2020-07-13 18:11:57 +02:00
Strawbs Bot
bcc5450aef Update translations 2020-07-13 01:02:37 +02:00
Jonas Kvinge
b0420a0566 Adjust width of settingspages 2020-07-13 00:57:50 +02:00
Jonas Kvinge
08d627bc9f Update Changelog 2020-07-13 00:39:33 +02:00
Jonas Kvinge
5b5f048faf Add missing taglib test files 2020-07-13 00:12:15 +02:00
Jonas Kvinge
212ebae043 Fix tab order in Appearance settings 2020-07-12 21:33:39 +02:00
Jonas Kvinge
a0c99df6b2 Make icon size for small tabbar configurable too 2020-07-12 21:02:29 +02:00
Jonas Kvinge
b0fabd7897 Adjust fancy tabbar size 2020-07-12 19:43:59 +02:00
Jonas Kvinge
938811f24f Fix sizes of horizontal modes and icon on top modes in fancy tabbar 2020-07-12 18:53:41 +02:00
Strawbs Bot
374d6e4d0f Update translations 2020-07-12 01:01:47 +02:00
Jonas Kvinge
5f54cdee0f Add new tagreader tests 2020-07-10 20:41:37 +02:00
Jonas Kvinge
c2bd452391 Fix playlist shuffle test, current index will never be at the end 2020-07-10 17:06:20 +02:00
Jonas Kvinge
d2bfc73b91 Only set playlist view item delegates once 2020-07-10 16:18:31 +02:00
Jonas Kvinge
42c62206c8 Move the currently playing song to the top when the playlist is manually shuffled
Fixes #304
2020-07-09 20:52:06 +02:00
Jonas Kvinge
4208b512f8 Remove some unused stuff in CMakeLists.txt 2020-07-09 20:09:07 +02:00
Strawbs Bot
3a3d5cd487 Update translations 2020-07-09 01:02:03 +02:00
Jonas Kvinge
e143a6d126 Enable playlist model tests 2020-07-08 20:52:50 +02:00
Jonas Kvinge
a99a19aa60 Fix broken playlist undostack when i.e. removing duplicates and unavailable songs 2020-07-08 20:43:46 +02:00
Jonas Kvinge
aba7d2b6a4 Fix mock_playlistitem.h 2020-07-08 18:22:12 +02:00
Jonas Kvinge
2fc6f835a8 Update sqlite test to use FTS5 instead of FTS3 2020-07-08 17:46:04 +02:00
Jonas Kvinge
27ce0e6d60 Add REQUIRED to find_package for GnuTLS 2020-07-08 17:29:58 +02:00
Strawbs Bot
05c70f2adb Update translations 2020-07-08 01:12:31 +02:00
Jonas Kvinge
904097b7b1 Add back option to use system taglib, add warning at the bottom 2020-07-07 23:44:04 +02:00
Jonas Kvinge
4e003c12a6 Add a taste of Strawbs background image 2020-07-07 23:02:24 +02:00
Jonas Kvinge
24f2cfb29f Fix playlist background image not loading 2020-07-07 22:21:07 +02:00
Jonas Kvinge
3f2b683fca Change pcmanfm-qt to pcmanfm 2020-07-07 18:28:47 +02:00
Strawbs Bot
83cee26d7d Update translations 2020-07-07 01:03:43 +02:00
Jonas Kvinge
c7df0c9b28 Use Q_UNUSED 2020-07-06 20:32:17 +02:00
Jonas Kvinge
26a8bfaac4 Open directory instead of file for PCManFM 2020-07-06 20:27:48 +02:00
Strawbs Bot
fc8a3be7d9 Update translations 2020-07-05 01:02:03 +02:00
Jonas Kvinge
b195c4033d Remove Ubuntu Eoan from CI 2020-07-04 11:34:47 +02:00
Jonas Kvinge
ab2732c55d Remove Fedora 33 from CI 2020-07-04 11:20:07 +02:00
Jonas Kvinge
7fd5c058be Fix buffer overflow when coverting S24LE 2020-07-04 01:55:36 +02:00
Jonas Kvinge
b22e8b4702 Convert S24LE and F32LE for analyzer
Fixes #155
2020-07-04 00:29:11 +02:00
Strawbs Bot
e2c2af3447 Update translations 2020-07-03 01:13:01 +02:00
Jonas Kvinge
4cd738ecb5 Properly calculate tab width 2020-07-02 04:24:55 +02:00
Strawbs Bot
e838470c26 Update translations 2020-07-02 01:01:57 +02:00
Jonas Kvinge
68e0bc40e1 Dont use fixed font size in fancy tabbar 2020-07-01 17:23:57 +02:00
Jonas Kvinge
9fc8bcdf62 Increase tab size 2020-07-01 14:32:30 +02:00
Jonas Kvinge
227b14a0b6 Make text in fancy tabbar wrap if too wide 2020-07-01 02:53:18 +02:00
Strawbs Bot
abcd184d5d Update translations 2020-06-30 01:02:57 +02:00
Jonas Kvinge
3fd9f4b0df Make fancy tabbar large mode icon size configurable 2020-06-29 03:03:04 +02:00
Jonas Kvinge
12ff3e963b Increase icon sizes in fancy tabbar large mode 2020-06-29 02:15:11 +02:00
Jonas Kvinge
558e392234 Make search field clear buttons follow icon size settings 2020-06-29 01:09:02 +02:00
Strawbs Bot
e747c2e263 Update translations 2020-06-29 01:03:02 +02:00
Jonas Kvinge
4d78b30e8c Make icon sizes configurable, increase default sizes for icons
Fixes #250
2020-06-28 18:36:48 +02:00
Strawbs Bot
9a1520d5e3 Update translations 2020-06-28 01:13:47 +02:00
Jonas Kvinge
04f3543424 Rename some layouts in mainwindow UI 2020-06-28 00:17:22 +02:00
Jonas Kvinge
eae287be37 Remove -Wno-bool-conversion 2020-06-27 03:00:25 +02:00
Jonas Kvinge
a0e698b058 Remove add_dependencies for singleapplication 2020-06-27 02:53:45 +02:00
Jonas Kvinge
cd2932adea taglib: Only match APE if MAC is found in the beginning of the file 2020-06-27 02:01:24 +02:00
Strawbs Bot
286b270592 Update translations 2020-06-27 01:13:13 +02:00
Jonas Kvinge
d1ebef2cc5 Remove DSF and DSDIFF from lists of supported audio formats 2020-06-27 00:58:37 +02:00
Jonas Kvinge
deb567fde7 Enable show in file browser based on local songs
Fixes #472
2020-06-27 00:52:26 +02:00
Jonas Kvinge
26586fb9ef Fix some includes in taglib 2020-06-27 00:06:02 +02:00
Jonas Kvinge
5f71a558b9 Adapt most changes from taglib2 2020-06-26 23:30:30 +02:00
Jonas Kvinge
08882639e0 Move SingleApplication includes to non-system includes 2020-06-26 23:27:38 +02:00
Jonas Kvinge
837ae2932f Add SYSTEM to system includes in target_include_directories 2020-06-26 23:26:04 +02:00
Jonas Kvinge
b51cc21140 Use override 2020-06-26 23:01:57 +02:00
Jonas Kvinge
f1115ba706 Remove explicit twice 2020-06-26 22:43:46 +02:00
Jonas Kvinge
dc36aee7ff Change some explicit usage 2020-06-26 22:41:38 +02:00
Jonas Kvinge
740f9581e6 Change 0 to nullptr 2020-06-26 22:06:23 +02:00
Jonas Kvinge
de0e3a7bc9 Use initialization list in tidalrequest 2020-06-26 22:05:07 +02:00
Jonas Kvinge
95e894fb4d Update README.md 2020-06-26 20:35:13 +02:00
Jonas Kvinge
faacb0d69f Subsonic: Dont strip words from title
Fixes #476
2020-06-26 17:35:05 +02:00
Jonas Kvinge
28b139e1b8 Disable wasapi plugin in nsi 2020-06-25 23:28:53 +02:00
Jonas Kvinge
39b1e0676b Fix memory include 2020-06-25 22:51:00 +02:00
Jonas Kvinge
c05fc5bd36 Update README.md 2020-06-25 14:12:54 +02:00
Jonas Kvinge
bbae9157fb Update README.md 2020-06-25 14:00:23 +02:00
Jonas Kvinge
fc5c63a869 Update README.md 2020-06-25 13:59:29 +02:00
Jonas Kvinge
e2e068f8e5 Remove .github/ISSUE_TEMPLATE/feature_request.md 2020-06-25 13:45:08 +02:00
Jonas Kvinge
43a068e30e Use QRandomGenerator 2020-06-22 15:22:14 +02:00
Jonas Kvinge
2beb4b8c6f taglib: Remove virtual functions workaround in audioproperties 2020-06-22 03:20:17 +02:00
Jonas Kvinge
ad4230f7fa taglib: Remove added explicit in tiostream 2020-06-22 03:11:58 +02:00
Jonas Kvinge
00369a2cfe taglib: Fix some formatting 2020-06-22 03:11:35 +02:00
Jonas Kvinge
248e487dd5 taglib: Remove unused functions + add virtual and explicit 2020-06-22 02:32:37 +02:00
Jonas Kvinge
3a3dc02a66 taglib: Rename Properties to AudioProperties 2020-06-22 00:49:25 +02:00
Jonas Kvinge
f49c47c20d Remove xine from NSI 2020-06-21 22:49:06 +02:00
Jonas Kvinge
417ef1a7a4 Add libgstwasapi.dll to debug release 2020-06-21 22:47:13 +02:00
Strawbs Bot
8e8889483f Update translations 2020-06-21 01:02:03 +02:00
Jonas Kvinge
b5818a9b62 Look for 2.0 module of libplist and libusbmuxd
Fixes #467
2020-06-20 17:39:43 +02:00
Jonas Kvinge
e709f676dc Remove unused tooltip files 2020-06-20 17:31:36 +02:00
Jonas Kvinge
bb611bf655 Dont use HTML in tooltip on KDE
Fixes #466
2020-06-20 17:30:37 +02:00
Strawbs Bot
24e8ca67c5 Update translations 2020-06-20 01:02:05 +02:00
Jonas Kvinge
0695941a77 Fix showing/hiding playing widget when playback is started while window is hidden 2020-06-19 17:32:08 +02:00
Strawbs Bot
7c71efd1b3 Update translations 2020-06-19 01:02:43 +02:00
Jonas Kvinge
5099aff5c3 Fix increasing play count when stop after track is enabled
Fixes #458
2020-06-18 22:18:49 +02:00
Jonas Kvinge
d3463250a9 Add on startup options to show maximized or minimized 2020-06-18 21:46:36 +02:00
Jonas Kvinge
3b58c02db0 Improve CMake files (#460) 2020-06-17 22:56:20 +02:00
Jonas Kvinge
64f0313d3c Remove ifdef's on slots in shortcutsettings page 2020-06-17 19:58:21 +02:00
Strawbs Bot
d3958e757b Update translations 2020-06-17 01:01:57 +02:00
Jonas Kvinge
651020388d Use override 2020-06-15 21:55:05 +02:00
Jonas Kvinge
72ede666d4 Replace use of C style casts 2020-06-15 17:59:02 +02:00
Jonas Kvinge
a68c249d4e Use parentheses for macro arguments 2020-06-15 00:33:47 +02:00
Jonas Kvinge
56caab4461 Remove redundant initialization 2020-06-15 00:11:52 +02:00
Jonas Kvinge
13b60351a6 Replace use of deprecated C++ headers 2020-06-14 23:54:18 +02:00
Jonas Kvinge
ad49d38e46 CI: Remove extra media for mageia 2020-06-14 23:20:40 +02:00
Jonas Kvinge
082c9097e4 Fix parameter name mispatches 2020-06-14 18:58:24 +02:00
Jonas Kvinge
2fbdb29ebc Replace 0 with nullptr 2020-06-14 17:02:47 +02:00
Jonas Kvinge
ef34dce4dc Additional manual formatting to taglib sources 2020-06-14 17:01:05 +02:00
Jonas Kvinge
577b7d8ec8 Use lengthInMilliseconds() 2020-06-14 16:08:18 +02:00
Jonas Kvinge
4ce099294c Format taglib sources 2020-06-13 19:02:42 +02:00
Strawbs Bot
72bff7fa35 Update translations 2020-06-13 01:02:48 +02:00
Jonas Kvinge
8c36b8803f Update .github/workflows/ccpp.yml 2020-06-12 19:22:29 +02:00
Strawbs Bot
c69993bd57 Update translations 2020-06-12 01:02:54 +02:00
Strawbs Bot
ea3e4982d2 Update translations 2020-06-10 01:01:56 +02:00
Strawbs Bot
9a5f6c7b9b Update translations 2020-06-09 01:02:35 +02:00
Jonas Kvinge
033d56a4b3 Use SetMinimumSize in about dialog 2020-06-08 23:40:15 +02:00
Jonas Kvinge
dfa684cccc Turn back git revision 2020-06-08 19:04:56 +02:00
Jonas Kvinge
b4e0f43dfc Update ccpp.yml 2020-06-07 23:59:31 +02:00
Jonas Kvinge
783cf7f1b0 Release 0.6.12 2020-06-07 23:49:11 +02:00
Jonas Kvinge
92d6fc3fad Change default grouping to album disc 2020-06-07 23:36:37 +02:00
Jonas Kvinge
436cdea4fd Add libgstfaac.dll 2020-06-06 15:08:30 +02:00
Jonas Kvinge
6b144b3b1f Add faac to nsi 2020-06-06 14:56:31 +02:00
Jonas Kvinge
7820082eb8 Add windows builder 2020-06-06 01:50:40 +02:00
Strawbs Bot
e732f921a3 Update translations 2020-06-06 01:02:52 +02:00
Jonas Kvinge
8b7c5d8585 Fix saving OSD pretty settings 2020-06-05 23:46:07 +02:00
Jonas Kvinge
9e959b189c Save settings when tabbar colors are changed 2020-06-05 23:39:22 +02:00
Jonas Kvinge
5c7a4cdc22 Fix deprecated use of QProcess::startDetached 2020-06-05 22:15:58 +02:00
Strawbs Bot
756e619e07 Update translations 2020-06-05 01:02:01 +02:00
Jonas Kvinge
eea6194b90 Add liborc-0.4-0.dll to nsi 2020-06-04 07:41:49 +02:00
Strawbs Bot
a09c1fa154 Update translations 2020-06-04 01:01:40 +02:00
Strawbs Bot
38c742328c Update translations 2020-05-31 01:01:44 +02:00
Jonas Kvinge
1d5db1446d Sort folders added from file view
Fixes #449
2020-05-30 21:59:55 +02:00
Jonas Kvinge
3f5f3d143f Fix compile without gstreamer 2020-05-30 21:39:16 +02:00
Jonas Kvinge
d297a7198a Update CI 2020-05-30 03:49:37 +02:00
Strawbs Bot
e5bd99dee4 Update translations 2020-05-30 01:04:25 +02:00
Jonas Kvinge
2720e13e88 Update libprotobuf DLL 2020-05-30 00:20:16 +02:00
Jonas Kvinge
0e9c1789ff Dont append disc to album title
Fixes #438
2020-05-29 20:38:19 +02:00
Jonas Kvinge
281cb10f84 Fix shadowing member 2020-05-29 18:30:27 +02:00
Jonas Kvinge
69a92ffe72 Remove mistankely added include 2020-05-29 18:30:09 +02:00
Jonas Kvinge
6447f159e5 Fix endl 2020-05-29 18:06:50 +02:00
Jonas Kvinge
94430883ad Use Qt::endl with Qt 5.14 and higher 2020-05-29 18:04:31 +02:00
Jonas Kvinge
046512eb3d Use Qt::endl 2020-05-29 17:47:26 +02:00
Jonas Kvinge
4479d97e90 Change use of Qt::KeyboardModifiers 2020-05-29 17:47:10 +02:00
Jonas Kvinge
bf5fea8951 Replace use of QMultiMap::insertMulti with QMultiMap::insert 2020-05-29 17:46:41 +02:00
Jonas Kvinge
07282e3de6 Change use of QLabel::pixmap 2020-05-29 17:45:00 +02:00
Jonas Kvinge
c2f90a20df Replace hex with Qt::hex 2020-05-29 17:43:44 +02:00
Jonas Kvinge
481d2d699e Replace QWheelEvent::delta with QWheelEvent::angleDelta 2020-05-29 17:42:40 +02:00
Jonas Kvinge
cf9a7e6ed3 Dont do qsrand on Qt versions higher than Qt 5.10 2020-05-29 17:40:34 +02:00
Jonas Kvinge
c35235371a Replace QString::SkipEmptyParts with Qt::SkipEmptyParts on Qt 5.14.0 or higher 2020-05-29 17:40:11 +02:00
Jonas Kvinge
5d5723ad58 Replace qrand with QRandomGenerator when using Qt 5.10 or higher 2020-05-29 17:37:46 +02:00
Jonas Kvinge
6c77294a86 Fixes to imobiledeviceconnection support 2020-05-29 17:36:01 +02:00
Strawbs Bot
823f65f1ca Add Czech 2020-05-29 01:52:17 +02:00
Strawbs Bot
0c378c1642 Update translations 2020-05-29 01:05:58 +02:00
Jonas Kvinge
bbb4162867 Make it possible to maximize console dialog 2020-05-26 18:27:01 +02:00
Jonas Kvinge
5dbdde3f2b Make scrobbler show error dialog for all errors when option is on 2020-05-26 17:51:23 +02:00
Jonas Kvinge
2521954bd9 Change layout name 2020-05-26 00:02:16 +02:00
Jonas Kvinge
5f1002894e Only save settings that has been changed 2020-05-25 23:56:54 +02:00
Jonas Kvinge
0489b312a3 Fix CircleCI 2020-05-25 23:56:29 +02:00
Jonas Kvinge
732be5a34f Use g_free 2020-05-24 23:22:18 +02:00
Jonas Kvinge
1f45c78ebb Unmap buffer references in error cases 2020-05-24 23:21:26 +02:00
Strawbs Bot
8b86c79bf9 Update translations 2020-05-18 01:01:33 +02:00
Jonas Kvinge
710ed81067 Require sqlite on centos too 2020-05-17 19:36:37 +02:00
Jonas Kvinge
24ac0e7b9b Fix CircleCI tumbleweed build 2020-05-17 18:34:25 +02:00
Jonas Kvinge
15b2bfbb29 Set library paths for Linux too when USE_BUNDLE is set 2020-05-17 17:01:35 +02:00
Jonas Kvinge
b7494eb381 Increase about dialog height 2020-05-17 16:25:18 +02:00
Strawbs Bot
27ac590250 Update translations 2020-05-17 01:01:49 +02:00
Jonas Kvinge
972076edab Move ClearDiskCache connect 2020-05-16 19:35:25 +02:00
Jonas Kvinge
bfa9a1eb8a Fix tests
Fixes #440
2020-05-16 19:17:06 +02:00
Jonas Kvinge
b0966f14e6 Only connect ClearPixmapDiskCache if app is set 2020-05-16 18:25:13 +02:00
Jonas Kvinge
37cf0c2fb6 Turn back git revision 2020-05-16 18:24:51 +02:00
Jonas Kvinge
4eb11c32b0 Release 0.6.11 2020-05-16 14:40:35 +02:00
Jonas Kvinge
25457bc09a Release 0.6.11 2020-05-16 14:39:53 +02:00
Jonas Kvinge
d5cfb5f733 Merge branch 'master' of github.com:strawberrymusicplayer/strawberry 2020-05-16 14:14:34 +02:00
Jonas Kvinge
79ba6e628e Use art id from the API as cover filename for Subsonic
Fixes #433
2020-05-16 14:13:22 +02:00
King_DuckZ
ef73add05a Warning fix on gcc 8.3.0 (#439)
Fixes warning:
assuming signed overflow does not occur when
simplifying conditional to constant [-Wstrict-overflow]

Signed-off-by: Michele Santullo <m.santullo@posteo.net>

Co-authored-by: Michele Santullo <m.santullo@posteo.net>
2020-05-16 13:34:42 +02:00
Strawbs Bot
ec3d11fb27 Update translations 2020-05-16 01:03:55 +02:00
Jonas Kvinge
3fbc7031b5 Update about dialog 2020-05-16 00:45:15 +02:00
Jonas Kvinge
40beb5e428 Update Changelog 2020-05-15 23:54:15 +02:00
Jonas Kvinge
0f608c8ef0 Update debian/copyright 2020-05-15 23:48:44 +02:00
Jonas Kvinge
8509cb4743 Spotify: Fix clearing access token 2020-05-15 23:36:01 +02:00
Jonas Kvinge
f4429e8c4a Make Musicbrainz cover provider respect rate limiting 2020-05-15 22:53:21 +02:00
Jonas Kvinge
e9e0829cdc Remove end dash from title 2020-05-15 22:15:52 +02:00
Strawbs Bot
93f0230423 Update translations 2020-05-15 01:03:01 +02:00
plonibarploni
f26a0df4a4 strip directory from OpenInFileManager command (#436) 2020-05-14 22:19:26 +02:00
Jonas Kvinge
c7d4624282 Update README.md 2020-05-14 22:12:55 +02:00
Jonas Kvinge
b03eee2a22 Update Changelog 2020-05-14 22:10:18 +02:00
Jonas Kvinge
7d4d72e706 Make Discogs provider respect rate limiting 2020-05-14 19:31:40 +02:00
Jonas Kvinge
e3c367984b Make it possible to receive SearchResults before SearchFinished 2020-05-14 19:30:29 +02:00
Jonas Kvinge
0ebfa10d32 Update details in playing widget 2020-05-14 19:29:34 +02:00
Jonas Kvinge
16d9a077f0 emit SearchCoverInProgress before SearchCoverAutomatically 2020-05-14 19:29:07 +02:00
Strawbs Bot
a9d8bbad42 Update translations 2020-05-14 01:03:53 +02:00
Jonas Kvinge
d78bb94af3 Fix Tidal OAuth login 2020-05-13 21:56:11 +02:00
Jonas Kvinge
b139c0a824 Dont use song count from backend for CDDA devices 2020-05-13 19:42:13 +02:00
Jonas Kvinge
5b0b924d34 Fix crash in CD songloader 2020-05-13 19:00:57 +02:00
Strawbs Bot
f75acf820c Update translations 2020-05-13 01:05:26 +02:00
Jonas Kvinge
43a47f33ac Dont link chromaprint unless its enabled
Fixes #432
2020-05-12 22:39:56 +02:00
Jonas Kvinge
fcea3a0877 Add option to scrobbler setting for showing login error
Fixes #430
2020-05-12 22:25:00 +02:00
Jonas Kvinge
a950ec3bd5 Adjust login state widget placement for covers and lyrics settings 2020-05-12 22:15:53 +02:00
Jonas Kvinge
e35501ff0a Delete remaining network replies and local redirct server in destructor 2020-05-12 21:28:42 +02:00
Jonas Kvinge
4bfad9dad8 Fix use of QString::right() 2020-05-12 21:12:08 +02:00
Jonas Kvinge
c5c7a07c12 Add QImageReader::imageFormatsForMimeType replacement function 2020-05-12 19:48:37 +02:00
Jonas Kvinge
7e22e0e552 Use original image format when saving images from Subsonic and Tidal
Fixes #435
2020-05-12 18:50:57 +02:00
Jonas Kvinge
84ec4bdc79 Check content type for image in album cover fetcher search 2020-05-12 18:47:32 +02:00
Jonas Kvinge
2bcad9b637 Do AddOrUpdateSongs in database thread 2020-05-12 18:45:24 +02:00
Jonas Kvinge
c8d5f03070 Dont use reference in AlbumSongsReplyReceived 2020-05-12 15:58:36 +02:00
Jonas Kvinge
168e101a5a Subsonic: Disconnect signal/slots 2020-05-12 15:55:13 +02:00
Jonas Kvinge
b4bc7333d9 Use album id as cover filename for Subsonic
Fixes #433
2020-05-12 15:53:15 +02:00
Strawbs Bot
e8b58c940e Update translations 2020-05-11 01:03:48 +02:00
Jonas Kvinge
ec7202e3f6 Use refresh token for ListenBrainz 2020-05-11 00:51:18 +02:00
Jonas Kvinge
9a740f7962 Change variable name 2020-05-11 00:49:54 +02:00
Jonas Kvinge
9210fdee0d Make spotify refresh login 2020-05-10 17:10:20 +02:00
Jonas Kvinge
d7661f0964 Fix possible crash in album cover fetcher 2020-05-10 16:54:14 +02:00
Jonas Kvinge
139e148912 Use shared_ptr for scrobbler cache items 2020-05-10 14:59:04 +02:00
Jonas Kvinge
1b8dedb4ed Clear access token when login is expired 2020-05-10 14:53:40 +02:00
Jonas Kvinge
5d6b0fa329 Reset last played song when playlist is finished 2020-05-10 13:08:29 +02:00
Jonas Kvinge
f35bbd89c9 Initialize QNetworkReply pointer 2020-05-10 12:56:12 +02:00
Jonas Kvinge
538a9e42f4 Remove these 2020-05-10 12:50:37 +02:00
Jonas Kvinge
623147dea7 Add Json cover provider class 2020-05-10 12:49:11 +02:00
Jonas Kvinge
dfecd0cd12 Show Json parse error 2020-05-10 12:48:48 +02:00
Jonas Kvinge
fe3af3a676 Clear albums on close in cover manager 2020-05-10 11:50:05 +02:00
Strawbs Bot
25f60331ed Update translations 2020-05-10 01:04:15 +02:00
Jonas Kvinge
d4860a3426 Use defaults from context UI 2020-05-09 18:37:43 +02:00
Jonas Kvinge
e7e77ed86b Add automatically search for album cover to context settings 2020-05-09 18:31:10 +02:00
Jonas Kvinge
dc80459c59 Remove debug print 2020-05-09 02:30:32 +02:00
Jonas Kvinge
2f2de59234 Fix AuthError function 2020-05-09 02:07:51 +02:00
Jonas Kvinge
7bccc21878 Add setting for cover providers 2020-05-09 01:48:08 +02:00
Strawbs Bot
40f9dafa44 Update translations 2020-05-09 01:04:23 +02:00
Jonas Kvinge
355d436d29 Sort settings pages 2020-05-08 20:25:02 +02:00
Jonas Kvinge
079b684388 Remove duplicate include 2020-05-08 20:17:33 +02:00
Jonas Kvinge
fd11f46d30 Add album cover provider from Musixmatch 2020-05-08 20:14:16 +02:00
Jonas Kvinge
cb7099199a Fix memory include 2020-05-08 18:47:55 +02:00
Jonas Kvinge
8566d91e89 Remove some unneeded includes, etc 2020-05-08 18:44:07 +02:00
Jonas Kvinge
f44ce49ea7 Add setting for lyric providers and add more providers
Fixes #335
2020-05-08 18:35:36 +02:00
Jonas Kvinge
6ef69f6b32 Format code 2020-05-08 18:34:33 +02:00
Strawbs Bot
f5983d5f10 Update translations 2020-05-07 01:03:30 +02:00
Jonas Kvinge
54cce5e089 Use album grouping function 2020-05-06 22:35:55 +02:00
Jonas Kvinge
4e4e596a1e Change some parameters to const 2020-05-06 22:26:29 +02:00
Jonas Kvinge
727a1f5ad1 Sort songs in collection by song title instead of track if previous
grouping is not the album.

Fixes #295
2020-05-06 22:14:59 +02:00
Jonas Kvinge
85fa86625b Fix infinite loop in stylesheetloader
Fixes #361
2020-05-06 21:43:44 +02:00
Jonas Kvinge
2c91877f83 Add option to show/hide sidebar
Fixes #393
2020-05-06 18:15:17 +02:00
Jonas Kvinge
7d1fac44e9 Update non collection songs with manually unset cover 2020-05-05 23:57:37 +02:00
Jonas Kvinge
2e34abfc0d Fix mpris:artUrl when using embedded cover
Fixes #426
2020-05-04 23:23:24 +02:00
Jonas Kvinge
81ba63e247 Turn on git revision 2020-05-02 15:18:39 +02:00
Strawbs Bot
8b11a65522 Update translations 2020-05-02 01:01:45 +02:00
Jonas Kvinge
7190ad1d15 Remove styles directory when uninstalling 2020-05-01 19:55:45 +02:00
Jonas Kvinge
1c9bae5df5 Update libnettle dll in nsi 2020-05-01 18:41:36 +02:00
Jonas Kvinge
cc7fd73916 Update libhogweed dll in nsi 2020-05-01 16:55:58 +02:00
Jonas Kvinge
6d8725f268 Release 0.6.10 2020-05-01 16:42:20 +02:00
Jonas Kvinge
373c7cdbc4 Update Changelog 2020-05-01 16:40:54 +02:00
Jonas Kvinge
a4855bb33b Decrease margin for top title in context a little 2020-05-01 16:40:29 +02:00
Jonas Kvinge
57c1358ded Ignore replies not containing images from Discogs 2020-05-01 12:02:15 +02:00
Jonas Kvinge
eb4ce1feab Use toUtf8() not toLocal8Bit() when converting string for UNC path
Fixes #418
2020-04-30 17:32:31 +02:00
Strawbs Bot
838c17e144 Update translations 2020-04-30 01:03:38 +02:00
Strawbs Bot
4499cbca3c Update translations 2020-04-29 01:08:07 +02:00
Jonas Kvinge
a835a4a2f7 Minor fixes to collection pixmap cache
- Add variables for cache size defaults
- Increase default disk cache size
- Change the pixmap cache settings UI to look better
- Add current pixmap disk cache used to settings
2020-04-29 00:33:38 +02:00
Jonas Kvinge
9cc6a94353 Replace some NewClosure's with lambda connects 2020-04-28 22:29:10 +02:00
Jonas Kvinge
5ed9d9c4a0 Update Changelog 2020-04-28 22:28:45 +02:00
Jonas Kvinge
9c5ac7080d Remove unused connect 2020-04-28 22:28:24 +02:00
Jonas Kvinge
6346370e86 Set some properties on font size spinboxes 2020-04-28 20:56:35 +02:00
Jonas Kvinge
80697f8f30 Add toolchain files to cmake dir 2020-04-28 16:24:40 +02:00
Jonas Kvinge
18b8b56367 Use leap 15.1 for source build 2020-04-28 16:23:27 +02:00
Jonas Kvinge
760aacca26 Make context fonts configurable
Fixes #362
2020-04-28 01:11:00 +02:00
Strawbs Bot
1a4f0dcf5a Update translations 2020-04-28 01:02:50 +02:00
Jonas Kvinge
947484a71c Set content margin for label top in context 2020-04-27 22:20:50 +02:00
Jonas Kvinge
a74439d038 Always load 32x32 icon for engine and device
Fixes #417
2020-04-27 21:36:49 +02:00
Jonas Kvinge
c338618593 Do size checking of icon sizes when loading system theme icons 2020-04-27 21:36:08 +02:00
Jonas Kvinge
011897da53 Remove gstreamer registry file on startup for Windows
Workaround for issue #266
2020-04-27 15:54:37 +02:00
Jonas Kvinge
3fcaa58947 Add back libtag.dll (required for GStreamer plugin) 2020-04-27 15:52:38 +02:00
Strawbs Bot
ef8bd4362a Update translations 2020-04-27 01:03:05 +02:00
Jonas Kvinge
627a2ef6dd Dont use system icon for clear search field icon
Fixes #413
2020-04-27 00:24:49 +02:00
Jonas Kvinge
2732536d6e Fix device state text color in devices
Fixes #414
2020-04-27 00:22:46 +02:00
Jonas Kvinge
5a1b4b3ff8 Remove logging include 2020-04-26 18:49:18 +02:00
Jonas Kvinge
d93ec82e4f Fix save album cover to file
Fixes #412
2020-04-26 18:48:07 +02:00
Jonas Kvinge
15080972f3 Turn off uniformItemSizes
Fixes #411
2020-04-26 18:32:42 +02:00
Strawbs Bot
171b58f737 Update translations 2020-04-26 01:09:51 +02:00
Jonas Kvinge
c008ab6141 Fix resume playback on startup for CUE 2020-04-25 15:57:02 +02:00
Jonas Kvinge
f14c3654dc Add search for lyrics as a seperate option
Double click album to show fullsize

Fixes #299
2020-04-25 14:48:43 +02:00
Jonas Kvinge
ae05a61551 Read date and genre from individual tracks in cue sheets
Fixes #347
2020-04-25 13:47:25 +02:00
Jonas Kvinge
8e1def225b Move some files 2020-04-25 01:59:21 +02:00
Jonas Kvinge
6e061764ee Remove phonon 2020-04-25 01:42:29 +02:00
Jonas Kvinge
ac55b22839 Fix scrobble duration 2020-04-25 01:15:23 +02:00
Jonas Kvinge
49f77d3b75 Change timeouts 2020-04-25 00:13:48 +02:00
Jonas Kvinge
4abc650edf Make scrobbler handle streams 2020-04-25 00:07:42 +02:00
Jonas Kvinge
5ba00b61be Remove unneeded includes 2020-04-25 00:07:18 +02:00
Jonas Kvinge
bc16a6c4cb Sort album cover search results by score and pick the first 3 2020-04-25 00:03:43 +02:00
Jonas Kvinge
ea4dc6f040 Add link directories 2020-04-24 19:48:57 +02:00
Strawbs Bot
749ae8d5eb Update translations 2020-04-24 01:10:40 +02:00
Jonas Kvinge
7a56ffb7c3 Use COMPILE_LANGUAGE when setting compile options 2020-04-24 00:01:59 +02:00
Jonas Kvinge
e62ab23de2 Add taglib includes 2020-04-24 00:01:23 +02:00
Jonas Kvinge
c6f6118506 Use system taglib on macOS 2020-04-24 00:00:07 +02:00
Jonas Kvinge
8a5d5ad952 Fix some compile warnings in taglib 2020-04-23 21:51:14 +02:00
Jonas Kvinge
49e2615d14 Fix missing declaration 2020-04-23 21:50:50 +02:00
Jonas Kvinge
9289394261 Remove some compile options 2020-04-23 21:50:25 +02:00
Jonas Kvinge
8da4c88fd3 Fix compile warnings 2020-04-23 21:08:28 +02:00
Jonas Kvinge
a303850341 Use initialization list in cueparser 2020-04-23 21:07:17 +02:00
Jonas Kvinge
fb33610672 Remove unneeded this 2020-04-23 21:06:54 +02:00
Jonas Kvinge
d024dd6563 Minor code fixes to Subsonic 2020-04-23 21:06:26 +02:00
Jonas Kvinge
0be48f9f59 Minor code fixes to Tidal 2020-04-23 21:05:57 +02:00
Jonas Kvinge
df9292bafe Remove unneeded this 2020-04-23 21:05:17 +02:00
Jonas Kvinge
c1dcef3477 Improve Musicbrainz cover provider 2020-04-23 21:04:37 +02:00
Jonas Kvinge
48bc1f8361 Improve Last.fm cover provider code 2020-04-23 21:03:36 +02:00
Jonas Kvinge
2b2b4dbcf4 Improve Discogs cover provider 2020-04-23 21:02:48 +02:00
Jonas Kvinge
a1eadecdef Fix compile warnings in tests 2020-04-23 21:01:34 +02:00
Jonas Kvinge
f0b529952d Fix some compile warnings in singleapplication 2020-04-23 21:00:43 +02:00
Jonas Kvinge
c1ac2debb8 Fix some compile warnings in taglib 2020-04-23 21:00:16 +02:00
Jonas Kvinge
ac40094d37 Update CMakeLists.txt files 2020-04-23 20:59:09 +02:00
Jonas Kvinge
cb2bb4cb67 Fix CI 2020-04-22 15:38:10 +02:00
Strawbs Bot
f2965940cc Update translations 2020-04-22 01:01:32 +02:00
Strawbs Bot
c9ca147898 Update translations 2020-04-21 01:08:13 +02:00
Jonas Kvinge
c379d7f846 Minor code improvements to Deezer cover provider 2020-04-20 23:52:06 +02:00
Jonas Kvinge
45ae1ed265 Make Tidal album cover provider search for tracks too 2020-04-20 23:26:36 +02:00
Jonas Kvinge
9bf00eff40 Minor changes to Qobuz cover provider (and fix compile) 2020-04-20 22:58:57 +02:00
Jonas Kvinge
1677b3d5b9 Add Qobuz album cover provider 2020-04-20 22:12:40 +02:00
Jonas Kvinge
2a6806004a Fix update song length in context 2020-04-20 18:52:59 +02:00
Jonas Kvinge
39347d69df Only show song length in context when available 2020-04-20 18:46:26 +02:00
Jonas Kvinge
a2c0e4d4b1 Improve album cover loader, lyrics search and streaming support
- Improve album cover loader
- Add album cover loader result struct
- Move album cover thumbnail scaling to album cover loader
- Make init art manual look for album cover images in song directory
- Make album cover search work for songs outside of collection and
  streams
- Make album cover search work based on artist + title if album is not
  present
- Update art manual in playlist for local files, devices and CDDA
- Make lyrics search work for streams
- Add stream dialog to menu
- Remove dead code in InternetSearchModel
- Simplify code in InternetSearchView
2020-04-20 18:03:18 +02:00
Jonas Kvinge
ab2ffd9ac1 Add configure internet service to menu 2020-04-20 18:01:45 +02:00
Jonas Kvinge
c69fff52cc Remove useless using std 2020-04-20 17:49:06 +02:00
Strawbs Bot
1cfe61dc72 Update translations 2020-04-20 01:01:39 +02:00
Strawbs Bot
a23f39d81e Update translations 2020-04-19 01:01:32 +02:00
Strawbs Bot
b7724ff583 Update translations 2020-04-18 01:01:40 +02:00
Jonas Kvinge
e5dba60fab Remove song_id and artist_id from initialization list 2020-04-17 22:17:57 +02:00
Jonas Kvinge
2ccf489a83 Remove debug line 2020-04-17 17:23:43 +02:00
Jonas Kvinge
068939ca0b Fallback to SHA1 hash for cover filename if artist / album is stripped 2020-04-17 17:22:50 +02:00
Strawbs Bot
94ba8614ec Update translations 2020-04-16 01:01:39 +02:00
Strawbs Bot
f12a0c2379 Update translations 2020-04-15 01:01:28 +02:00
Strawbs Bot
8ab257645b Update translations 2020-04-14 01:11:19 +02:00
Jonas Kvinge
6331a0615f Update device schema 2020-04-13 23:24:35 +02:00
Jonas Kvinge
a21855fa20 Merge pull request #406 from strawberrymusicplayer/tidal
Add back Tidal support
2020-04-13 22:37:41 +02:00
Jonas Kvinge
12150c2180 Change database file 2020-04-13 19:05:55 +02:00
Jonas Kvinge
d90aecb164 Add back Tidal support 2020-04-13 19:04:06 +02:00
Jonas Kvinge
e738f2bc9f Recreate indexes and views in upgrade schema 11 2020-04-13 16:32:31 +02:00
Jonas Kvinge
2f72c41cda Improve internet classes 2020-04-13 06:30:40 +02:00
Jonas Kvinge
aa43d42cdb Remove const from signal slot connects 2020-04-13 05:57:48 +02:00
Jonas Kvinge
be8228e33c Fix song_id check 2020-04-13 04:17:45 +02:00
Jonas Kvinge
5591472dbd Change artist and song ID to strings 2020-04-13 03:39:51 +02:00
Strawbs Bot
30e6ced4e9 Update translations 2020-04-13 01:01:36 +02:00
Strawbs Bot
5f4c2bae89 Update translations 2020-04-12 01:01:28 +02:00
Strawbs Bot
0f036d9a43 Update translations 2020-04-11 01:01:39 +02:00
Strawbs Bot
1695ac3a32 Update translations 2020-04-10 01:02:01 +02:00
Jonas Kvinge
07a19ba619 Use slash 2020-04-09 20:41:14 +02:00
Jonas Kvinge
4dd78d89a0 Add option to remove problematic filename characters 2020-04-09 19:59:31 +02:00
Jonas Kvinge
8f4056faa6 Allow all characters except slash and backslash when organising music
Fixes #404
2020-04-09 18:14:02 +02:00
Jonas Kvinge
7b40c33892 Add missing semicolon in desktop file 2020-04-09 16:02:06 +02:00
Jonas Kvinge
b06bb5142f Turn on git revision 2020-04-09 16:01:12 +02:00
Jonas Kvinge
d576156ee1 Update snap version 2020-04-09 03:41:08 +02:00
Jonas Kvinge
77079968a5 Release 0.6.9 2020-04-09 02:32:32 +02:00
Jonas Kvinge
e12aca6214 Update maketarball.sh.in 2020-04-09 02:32:17 +02:00
Strawbs Bot
2a72891f28 Update translations 2020-04-09 00:42:40 +02:00
Jonas Kvinge
6fe47e78f1 Remove APE file detection by content
Fixes #373
2020-04-09 00:26:25 +02:00
Jonas Kvinge
0094894b52 Update ccpp.yml 2020-04-08 23:57:59 +02:00
Jonas Kvinge
0951bfb7ac Update Changelog 2020-04-08 23:38:00 +02:00
Jonas Kvinge
60e8519b65 Fix track and title in playlist not being movable
Fixes #403
2020-04-08 22:44:39 +02:00
Jonas Kvinge
78df0ed707 Change variable name 2020-04-08 22:32:01 +02:00
Jonas Kvinge
e3da0d6c9f Update config.yml 2020-04-08 19:27:32 +02:00
Jonas Kvinge
5df30580a6 Switch GitHub actions to use openSUSE 2020-04-08 01:15:39 +02:00
Strawbs Bot
4816b7dcd8 Update translations 2020-04-08 01:09:21 +02:00
Jonas Kvinge
75bced198b Hide open Audio CD on Windows 2020-04-08 01:00:21 +02:00
Jonas Kvinge
b500813617 Disable open Audio CD on Windows 2020-04-08 00:56:19 +02:00
Jonas Kvinge
a80037f7fc Update .travis.yml 2020-04-08 00:42:00 +02:00
Jonas Kvinge
1a6345342f Add Travis-CI 2020-04-07 17:05:01 +02:00
Jonas Kvinge
21b2193cd0 Add explicit 2020-04-07 16:49:15 +02:00
Jonas Kvinge
3efc496c41 Add better error handling for CDDA loader 2020-04-07 16:48:12 +02:00
Strawbs Bot
16340fbb78 Add Hungarian 2020-04-07 02:02:31 +02:00
Jonas Kvinge
a858b28bc4 Remove unused QGuiApplication include 2020-04-07 01:44:03 +02:00
Jonas Kvinge
307961cc7e Center organise and transcoder dialog on same screen as mainwindow 2020-04-07 01:26:17 +02:00
Strawbs Bot
3074377b55 Update translations 2020-04-07 01:03:31 +02:00
Jonas Kvinge
5a3edc00ac Remove extra check for oversized window 2020-04-06 23:14:23 +02:00
Jonas Kvinge
5a5f50e1e4 Use current_screen() function in OSD Pretty 2020-04-06 23:01:50 +02:00
Jonas Kvinge
7f39a38d6c Center cover manager on same screen as mainwindow 2020-04-06 22:30:03 +02:00
Jonas Kvinge
8321a48af7 Add missing QGuiApplication include 2020-04-06 22:26:55 +02:00
Jonas Kvinge
7e613f032e Add upgrade step to GitHub Actions 2020-04-06 22:26:19 +02:00
Jonas Kvinge
1c38c39db2 Center settings on current screen 2020-04-06 22:02:32 +02:00
Jonas Kvinge
4a0235c2ed Check for null pointer in OSD Pretty 2020-04-06 22:01:44 +02:00
Jonas Kvinge
b92961fda0 Merge branch 'circleci' 2020-04-06 06:46:39 +02:00
Jonas Kvinge
a2a06be62f Merge pull request #399 from plonibarploni/patch-2
Fix 'Show in file browser' for Caja
2020-04-06 05:21:18 +02:00
plonibarploni
c0956ed3b0 Fix 'Show in file browser' for Caja 2020-04-05 22:33:06 -04:00
Jonas Kvinge
3705e4e4d4 Add Ubuntu Focal to CircleCI 2020-04-06 03:07:09 +02:00
Jonas Kvinge
3fdbe84573 Rewrite parts of context to be adjustable and adjust album to width 2020-04-06 02:47:57 +02:00
Strawbs Bot
fb8e7d803f Update translations 2020-04-06 01:01:36 +02:00
Strawbs Bot
b01821aa03 Add Polish
Fixes #397
2020-04-05 13:24:58 +02:00
Strawbs Bot
69f974c9d0 Update translations 2020-04-05 01:02:31 +02:00
Jonas Kvinge
5db8b743fe Subsonic: Fix setting size 2020-04-04 23:34:04 +02:00
Jonas Kvinge
c424b0c888 Subsonic: Check if int values are strings 2020-04-04 23:31:27 +02:00
Strawbs Bot
d035c7d3b8 Update translations 2020-04-01 01:01:37 +02:00
Jonas Kvinge
144ffbc428 Subsonic: Handle track as string 2020-04-01 00:33:00 +02:00
Jonas Kvinge
afa8486d40 Update bug_report.md 2020-03-22 20:33:46 +01:00
Jonas Kvinge
a4cd42c448 Update README.md 2020-03-22 19:39:24 +01:00
Jonas Kvinge
853f4b75fa Update README.md 2020-03-22 00:17:40 +01:00
Jonas Kvinge
b95612287f This is a combination of 2 commits. (#390)
Add CircleCI
2020-03-20 16:17:11 +01:00
Jonas Kvinge
64e779172c Remove Travis-CI from master branch 2020-03-20 00:33:05 +01:00
Jonas Kvinge
10a136b4a3 Update macdeploy.py 2020-03-19 21:54:02 +01:00
Jonas Kvinge
ddc3af28ab Add back Travis-CI for macOS builds 2020-03-19 19:21:24 +01:00
Strawbs Bot
f602948dcf Update translations 2020-03-19 01:03:27 +01:00
Jonas Kvinge
973229cf4e Dont allow copy music to optical drives
Fixes #387
2020-03-17 20:44:51 +01:00
Strawbs Bot
d1f5cbea4a Update translations 2020-03-17 01:01:55 +01:00
Jonas Kvinge
49fe670ddb Center text of track column in tag fetcher
Fixes #388
2020-03-16 23:30:53 +01:00
Strawbs Bot
d6d87675c9 Update translations 2020-03-16 01:02:00 +01:00
Jonas Kvinge
1ca1927904 Only search for cover automatically for collection songs 2020-03-15 02:56:22 +01:00
Jonas Kvinge
454c3d1a3c Fix macOS build 2020-03-15 02:00:13 +01:00
Jonas Kvinge
11f5004112 Use a shorter playlist name when songs are added from file view
Fixes #363
2020-03-15 01:56:48 +01:00
Jonas Kvinge
625343f698 Check xdg-mime on Unix to find default file manager on Unix
Fixes #382
2020-03-15 01:21:30 +01:00
Jonas Kvinge
89d96a3ec1 Update README.md 2020-03-12 19:36:07 +01:00
Jonas Kvinge
c4c47fa196 Update README.md 2020-03-12 19:28:42 +01:00
Jonas Kvinge
ca35894b82 Update README.md 2020-03-12 19:27:00 +01:00
Jonas Kvinge
0213b6556b Add missing memory include 2020-03-08 19:13:13 +01:00
Jonas Kvinge
4edfd9be30 Merge branch 'master' of github.com:strawberrymusicplayer/strawberry 2020-03-08 18:40:56 +01:00
Jonas Kvinge
e55d9cafb6 Update logger 2020-03-08 18:40:39 +01:00
Jonas Kvinge
8deb0ed556 Move setting highDPI options 2020-03-08 18:36:48 +01:00
Strawbs Bot
82f995f243 Add Korean 2020-03-07 15:26:13 +01:00
Jonas Kvinge
b41c2ca724 Update README.md 2020-03-07 15:19:11 +01:00
Strawbs Bot
06ddbaf2cc Update translations 2020-03-01 01:02:03 +01:00
Jonas Kvinge
2adbfe1fbd Update required Qt version in README 2020-02-29 21:50:59 +01:00
Jonas Kvinge
7ae049b559 Require Qt 5.6 or higher 2020-02-29 21:50:10 +01:00
Jonas Kvinge
72913ceb1a Check that Qt version is higher than 5.9 to use QDir::isEmpty() 2020-02-29 21:40:20 +01:00
Jonas Kvinge
6a2be22fa1 Remove empty directories when organizing music
Fixes #353
2020-02-28 22:23:12 +01:00
Strawbs Bot
eaf20ce8d2 Update translations 2020-02-26 01:07:17 +01:00
Jonas Kvinge
97f9e142b4 Set hiDPI options 2020-02-25 01:15:05 +01:00
Jonas Kvinge
2e0f7b367f Remove tidal and qobuz
Fixes #369
2020-02-25 01:08:03 +01:00
Jonas Kvinge
7312e3f452 Find backtrace quiet 2020-02-23 20:42:30 +01:00
Strawbs Bot
8faa9f075b Update translations 2020-02-23 01:02:20 +01:00
Jonas Kvinge
584dcae075 Change variables 2020-02-22 17:39:06 +01:00
Jonas Kvinge
910e869b8d Use selectedRows() where possible 2020-02-22 15:31:25 +01:00
Jonas Kvinge
469e00b396 Remove setBaseStyle() 2020-02-22 13:43:33 +01:00
Strawbs Bot
ec46c758ba Update translations 2020-02-22 01:01:59 +01:00
Jonas Kvinge
8970e46bce More code fixes to mainwindow 2020-02-22 00:09:45 +01:00
Jonas Kvinge
3a4107d903 Workaround crash when mapToSource() fails 2020-02-21 22:42:21 +01:00
Jonas Kvinge
52ee21d550 Remove C++11Compat.cmake 2020-02-18 01:22:04 +01:00
Strawbs Bot
cdda4826cb Update translations 2020-02-18 01:02:19 +01:00
Jonas Kvinge
6745df5041 Update libffi 2020-02-17 20:22:02 +01:00
Jonas Kvinge
3d3efe1117 Remove extra whitespace 2020-02-17 20:21:45 +01:00
Strawbs Bot
82e5ae05ce Update translations 2020-02-17 01:01:39 +01:00
Strawbs Bot
0dbdd55a6a Update translations 2020-02-12 01:09:03 +01:00
Jonas Kvinge
424b0e61cb Remove extra newlines 2020-02-12 00:07:05 +01:00
Jonas Kvinge
533da8f89c Use isLocalFile() 2020-02-12 00:06:19 +01:00
Strawbs Bot
31506662db Update translations 2020-02-10 01:08:12 +01:00
Jonas Kvinge
7ff1a88ca8 Add QCoreApplication to xineengine.cpp 2020-02-09 04:20:22 +01:00
Jonas Kvinge
1851f26e3f Reduce includes 2020-02-09 02:29:35 +01:00
Jonas Kvinge
84cd65dd6c Reduce includes 2020-02-08 15:03:11 +01:00
Jonas Kvinge
8e0d792bf0 Reduce includes 2020-02-08 03:40:30 +01:00
Strawbs Bot
e74548b991 Update translations 2020-02-08 01:04:53 +01:00
Jonas Kvinge
2356ff5ebb Fix tabs order
Fixes #366
2020-02-08 00:01:12 +01:00
Gavin D. Howard
691f5d99ca Implement disk caching of album art (#360)
* Implement disk caching of album art

This includes a button to clear the cache in the settings, as
requested.

Closes #358

* Make the cache size defaults match

* Implement the review by jonaski

* Fix more problems with the PR
2020-02-07 23:18:18 +01:00
Jonas Kvinge
ab7b65a30b Remove chartlyrics 2020-02-06 22:33:38 +01:00
Daniel Kolesa
814bb3006c libstrawberry-common: check for library/includes for backtrace() (#364)
This is a non-standard header, so it should be checked properly.
This fixes compilation with musl libc and possibly other C library
implementations.
2020-02-06 20:04:23 +01:00
Jonas Kvinge
4bd4d3ae03 Update ccpp.yml 2020-02-06 18:40:05 +01:00
Jonas Kvinge
af1b0ace19 Use bultin taglib on Windows too by default 2020-02-06 18:37:02 +01:00
Jonas Kvinge
fb54febe03 Update .gitignore 2020-02-06 18:36:34 +01:00
Strawbs Bot
28faae5a4a Update translations 2020-01-29 01:03:25 +01:00
Jonas Kvinge
624a920aec Dont update temporary metadata while editing song with inline editor 2020-01-28 19:41:46 +01:00
Jonas Kvinge
2bf8187bff Add missing signal 2020-01-28 18:19:15 +01:00
Jonas Kvinge
cf06bf91e3 Change git url 2020-01-24 17:27:29 +01:00
Jonas Kvinge
e96f0504c0 Move related stuff into Rpm/Deb Cmake files 2020-01-21 23:53:28 +01:00
Jonas Kvinge
5fd61725bd Fixes for debian packaging 2020-01-21 23:15:15 +01:00
Jonas Kvinge
3fddfa075b Update .gitignore 2020-01-21 23:14:40 +01:00
Strawbs Bot
d712e5c409 Update translations 2020-01-21 01:01:48 +01:00
Jonas Kvinge
6287afae6c Fix Subsonic compatibility with LMS
Fixes #354
2020-01-20 19:19:14 +01:00
Jonas Kvinge
925540055a Use QString::number 2020-01-20 18:15:37 +01:00
Jonas Kvinge
d4373aae93 Subsonic: Handle album id as string 2020-01-20 17:45:40 +01:00
Jonas Kvinge
c4be310081 Use static taglib on windows 2020-01-16 20:46:10 +01:00
Jonas Kvinge
d1aa276465 Move -DTAGLIB_STATIC 2020-01-16 01:56:47 +01:00
Jonas Kvinge
2af6fc7452 Add -DTAGLIB_STATIC 2020-01-16 01:40:30 +01:00
Jonas Kvinge
ed15394a96 Delete qwindowsvistastyle.dll on uninstall 2020-01-15 23:12:08 +01:00
Jonas Kvinge
3791d11162 Disable libgstwasapi.dll 2020-01-15 17:12:18 +01:00
Jonas Kvinge
032ddabc06 Add qwindowsvistastyle.dll to nsi 2020-01-15 01:27:14 +01:00
Jonas Kvinge
bfb93ac6ed Update alsa in snap 2020-01-12 18:42:50 +01:00
Jonas Kvinge
f6d889d752 Add qtwayland5 to snap
Fixes #344
2020-01-12 18:02:13 +01:00
Jonas Kvinge
a7053f4269 Update README.md 2020-01-12 17:02:46 +01:00
Jonas Kvinge
233a6d06be Update README.md 2020-01-12 17:02:19 +01:00
Jonas Kvinge
853224148f Remove macOS builds 2020-01-12 16:56:19 +01:00
Jonas Kvinge
c5c8c27b2e Update README.md 2020-01-12 16:34:04 +01:00
Jonas Kvinge
d352d5fcff Turn back git revision 2020-01-07 21:41:31 +01:00
Strawbs Bot
0003de9320 Update translations 2020-01-07 01:01:46 +01:00
Jonas Kvinge
04f43e77af Update Changelog 2020-01-05 23:49:34 +01:00
Jonas Kvinge
be7cc55488 Release 0.6.8 2020-01-05 23:27:31 +01:00
Jonas Kvinge
c8f3379a48 Fix crash when deleting playlist folder. 2020-01-05 23:26:07 +01:00
Jonas Kvinge
b5a7945e49 Use QModelIndex::model() 2020-01-05 23:25:23 +01:00
Strawbs Bot
0bdac2e97d Update translations 2020-01-05 22:52:27 +01:00
Jonas Kvinge
1468a821fb Fix restoring to correct screen when maximized 2020-01-05 22:21:55 +01:00
Jonas Kvinge
3cdc8dc4b6 Use QWidget::screen() with Qt 5.14 2020-01-05 19:15:28 +01:00
Jonas Kvinge
aa255aa7e6 Use current screen, not primary screen 2020-01-05 19:14:25 +01:00
Strawbs Bot
66e5ccb9cc Update translations 2020-01-05 01:02:24 +01:00
Jonas Kvinge
2215f300bf Added option to disable playlist clear button
Fixes #339
2020-01-04 06:38:25 +01:00
Jonas Kvinge
eec767406b Add confirmation before clearing playlists with more than 500 songs 2020-01-04 06:11:21 +01:00
Jonas Kvinge
31aa42c2fa Fix compile with translations on Windows 2020-01-03 02:07:37 +01:00
Strawbs Bot
e912c59402 Add Italian 2020-01-03 01:46:38 +01:00
Strawbs Bot
c9988976f3 Update translations 2020-01-03 01:02:34 +01:00
Jonas Kvinge
443be1c2c8 Increase lyrics score if lyrics text > 60 2020-01-02 19:21:27 +01:00
Jonas Kvinge
7f442cff3b Fix QProxyStyle 2020-01-02 18:57:53 +01:00
Strawbs Bot
3696ae44ad Update translations 2019-12-31 01:09:52 +01:00
Jonas Kvinge
fc2d601424 Remove useless stdbool.h include 2019-12-30 23:14:40 +01:00
Jonas Kvinge
8818f24114 Fix compile with Qt 5.14 and above 2019-12-30 02:28:54 +01:00
Jonas Kvinge
0e12c8249e Fix actions builds 2019-12-30 00:49:39 +01:00
Strawbs Bot
06d62a70a9 Update translations 2019-12-30 00:35:45 +01:00
Jonas Kvinge
76d8018ca2 Remove HTML from translations 2019-12-29 23:53:54 +01:00
Jonas Kvinge
4123b41a5e Merge branch 'master' of github.com:jonaski/strawberry 2019-12-29 23:47:07 +01:00
Jonas Kvinge
5930257fed Remove HTML from translations 2019-12-29 23:46:49 +01:00
Jonas Kvinge
d3d60327ab Remove the answer to life the universe and everything 2019-12-29 23:46:35 +01:00
Strawbs Bot
5080ffb9fc Update translations 2019-12-29 23:41:39 +01:00
Jonas Kvinge
9b688a5179 Remove HTML from translations
Fixes #260
2019-12-29 23:37:48 +01:00
Strawbs Bot
a603dc5227 Update translations 2019-12-29 01:02:01 +01:00
Jonas Kvinge
c25f682caf Emit ExitFinished if no internet services are enabled 2019-12-28 03:35:07 +01:00
Jonas Kvinge
27a2fd298d Add the device view container widget to the tabbar
Fixes bugs related to the tabbar and the widgets being unresponsive

Fixes #279
Fixes #321
2019-12-28 03:13:41 +01:00
Strawbs Bot
bb38053cb3 Update translations 2019-12-24 01:01:42 +01:00
Strawbs Bot
5e82ee8695 Add German 2019-12-22 14:56:55 +01:00
Strawbs Bot
6c691ff9a8 Update translations 2019-12-22 14:55:33 +01:00
Jonas Kvinge
ac5a14fe4a Add StartupWMClass to desktop file
Fixes #305
2019-12-22 14:16:24 +01:00
Jonas Kvinge
00402d13ef Fix collection watcher on macOS
Fixes #324
2019-12-22 14:15:25 +01:00
Gavin D. Howard
079a559247 Make context title and summary changeable (#329)
* Make context title and summary changeable

Closes #30

* Fix checkboxes on context settings page

So...I am new to Qt, and I forgot that checkboxes can have a label.
Duh. Fixed.

* Put context settings in a different place

* Put ReplaceMessage and ReplaceVariable in Utilities
2019-12-22 12:09:05 +01:00
Strawbs Bot
a19ea8fdba Update translations 2019-12-22 01:04:20 +01:00
Jonas Kvinge
c6e172f942 Remove unused afc_port_ variable 2019-12-22 00:54:56 +01:00
Jonas Kvinge
bdc9f3e8bf Use AFC_E_SUCCESS 2019-12-22 00:45:01 +01:00
Jonas Kvinge
8ec5a587fc Fix compile 2019-12-21 22:34:42 +01:00
Jonas Kvinge
9caf46f2fb Use QString::asprintf 2019-12-21 22:07:04 +01:00
Jonas Kvinge
13fdbfc5e8 Use QString::asprintf 2019-12-21 21:56:48 +01:00
Jonas Kvinge
882c94110e Update temporary metadata when tags are changed 2019-12-21 21:55:24 +01:00
Jonas Kvinge
97bc980611 Upgrade packages 2019-12-21 18:26:51 +01:00
Jonas Kvinge
be9bf5c173 Replace use of QSet::fromList with Qt 5.14 and above 2019-12-21 18:22:18 +01:00
Jonas Kvinge
6df38c389c Replace use of QSet::toList() with QSet::values() 2019-12-21 18:19:09 +01:00
Jonas Kvinge
6c6bceb8cc Replace use of QString::sprintf 2019-12-21 18:17:58 +01:00
Jonas Kvinge
b5a897bb4d Replace use of QString::sprintf 2019-12-21 18:15:45 +01:00
Jonas Kvinge
ab85b716bb Replace use of QTime::start() with QElapsedTimer 2019-12-21 18:11:54 +01:00
Jonas Kvinge
8e256e6d5c Fix indent 2019-12-21 17:55:24 +01:00
Jonas Kvinge
288036a63b Fix spelling 2019-12-21 17:54:43 +01:00
Jonas Kvinge
f2005c3343 Update README.md 2019-12-11 20:46:15 +01:00
Jonas Kvinge
79d516b899 Update README.md 2019-12-11 20:45:27 +01:00
Jonas Kvinge
28b2f6eae3 Update README.md 2019-12-11 20:21:03 +01:00
Strawbs Bot
09ed2b945c Update translations 2019-12-07 12:45:08 +01:00
Jonas Kvinge
74aec89ef0 Add French 2019-12-05 19:58:07 +01:00
Jonas Kvinge
4faa23d099 Add Indonesian 2019-12-05 19:57:14 +01:00
Jonas Kvinge
5c4997ab20 Turn back git revision 2019-12-05 19:53:41 +01:00
Jonas Kvinge
cd490ca946 Release 0.6.7 2019-11-27 23:09:49 +01:00
Jonas Kvinge
793f6b00e6 Allow 4 tagreader workers 2019-11-27 22:57:51 +01:00
Strawbs Bot
c1ec568fda Update translations 2019-11-27 01:03:22 +01:00
Jonas Kvinge
4e2b52975e Remove require for sqlite on centos since we use customized sqlite 2019-11-26 23:43:34 +01:00
Jonas Kvinge
c141df6b86 Remove low-latency setting for wasapisink 2019-11-26 22:30:56 +01:00
Jonas Kvinge
63b781765a Update copyrights 2019-11-26 22:30:14 +01:00
Jonas Kvinge
c121e141e7 Remove duplicate entries in Changelog 2019-11-26 22:29:13 +01:00
Jonas Kvinge
7544c9a9f5 Update nsi with libprotobuf-22.dll 2019-11-26 19:42:38 +01:00
Jonas Kvinge
722a088515 Only remove pixmap cache when removing parents in collection model 2019-11-26 19:42:05 +01:00
Jonas Kvinge
0ce75bff58 Remove unused code in context albums 2019-11-26 19:41:32 +01:00
Strawbs Bot
3744b6d3de Update translations 2019-11-26 01:02:03 +01:00
Jonas Kvinge
a4ebd91e8d Make sure QSqlQuery::exec() was successful 2019-11-25 22:43:09 +01:00
Jonas Kvinge
3bb0ee916d Update Changelog 2019-11-25 22:31:42 +01:00
Jonas Kvinge
fd6afdf5f3 Extend url test 2019-11-25 22:30:33 +01:00
Jonas Kvinge
47c13a840e Handle different urls in collection backend for backward compatibility 2019-11-25 22:29:12 +01:00
Jonas Kvinge
5b61992b3c Save cover urls encoded 2019-11-25 22:28:48 +01:00
Jonas Kvinge
36331dc253 Fix removing nodes from pending art 2019-11-25 22:25:29 +01:00
Strawbs Bot
4265cf31b2 Update translations 2019-11-25 01:05:00 +01:00
Jonas Kvinge
337e47269f Remove portable, we dont use it 2019-11-25 00:35:48 +01:00
Jonas Kvinge
7039234471 Fix compile collection model test 2019-11-25 00:35:16 +01:00
Jonas Kvinge
f7f9333d91 Add collection backend url tests 2019-11-25 00:34:59 +01:00
Jonas Kvinge
bf35665932 Update all songs for the same directory+album when updating compilations
- Fixes a bug where the songs are stuck in various artists, because the
album has child songs, it will be stuck with various artists as the
parent node.
2019-11-25 00:28:49 +01:00
Jonas Kvinge
089a2271c2 Add GitHub Actions 2019-11-24 20:04:05 +01:00
Jonas Kvinge
f8e83e3631 Fix loading replay gain setting
Fixes #311
2019-11-24 19:34:05 +01:00
Strawbs Bot
46fd329913 Update translations 2019-11-23 01:07:52 +01:00
Jonas Kvinge
6b9ba96e77 Revert "Tidal: Add explicit to album titles"
This reverts commit b7d360d850.
2019-11-21 22:55:39 +01:00
Jonas Kvinge
b7d360d850 Tidal: Add explicit to album titles 2019-11-20 22:13:28 +01:00
Jonas Kvinge
8e226302ab Allow scrobbling songs without album
Fixes #309
2019-11-20 21:30:41 +01:00
Jonas Kvinge
7795b9edaf Dont replace metadata when loading playlists 2019-11-20 19:34:57 +01:00
Jonas Kvinge
9375d9699a No 2019-11-19 21:51:15 +01:00
Jonas Kvinge
cf0442d5b8 Fix setting pixmap cache limit 2019-11-19 21:49:46 +01:00
Jonas Kvinge
b386ca14df Show fullsize cover on doubleclick 2019-11-19 21:20:36 +01:00
Jonas Kvinge
ea47fae31e Add seperator between "unset cover" and "show fullsize" 2019-11-19 21:19:44 +01:00
Jonas Kvinge
e0fed07b10 Change pixmap cache limit 2019-11-19 21:03:06 +01:00
Jonas Kvinge
779d5ff7b6 Dont reset pixmap cache on model reset 2019-11-19 20:56:03 +01:00
Jonas Kvinge
eb6fbd03ec Update Changelog 2019-11-19 20:49:54 +01:00
Jonas Kvinge
95409d1b0e Remove unused variables 2019-11-19 20:47:06 +01:00
Jonas Kvinge
49599c8731 Add back ChartLyrics
This reverts commit c992768efe.
2019-11-19 20:45:22 +01:00
Jonas Kvinge
572f94e000 Update Changelog 2019-11-18 17:25:57 +01:00
Jonas Kvinge
c0a2ad5f50 Change comment 2019-11-18 17:16:58 +01:00
Jonas Kvinge
71fa5acc74 Fix previous player and doubleclick playlist song behaviour settings 2019-11-17 23:46:10 +01:00
Jonas Kvinge
bac5b7679d Use killproc.exe instead in nsi 2019-11-17 16:34:30 +01:00
Strawbs Bot
93ade821a5 Update translations 2019-11-17 01:10:32 +01:00
Jonas Kvinge
a718e19979 Use KillProc in nsi 2019-11-15 23:25:12 +01:00
Jonas Kvinge
8ac83a46f5 Remove clang compiler flag 2019-11-15 23:24:37 +01:00
Jonas Kvinge
1b65dcd7df Fix comparison between signed/unsigned 2019-11-15 00:23:06 +01:00
Jonas Kvinge
bbad45f1e7 Minor cmake fixes 2019-11-15 00:22:41 +01:00
Jonas Kvinge
331b9cca18 Remove sudo 2019-11-14 21:23:50 +01:00
Jonas Kvinge
a9accb7d85 Refactor scrobbler authentication code
Fix a crash when authentication is cancelled
2019-11-14 21:07:30 +01:00
Jonas Kvinge
1862e70628 Declare song using source 2019-11-14 00:09:35 +01:00
Jonas Kvinge
c4f7054ca6 Use QUrl::FullyEncoded in update compilations 2019-11-13 23:51:04 +01:00
Jonas Kvinge
175e568a28 Minor improvements to update compilations 2019-11-13 21:27:04 +01:00
Jonas Kvinge
c8d580e7de No need to delete pixmap cache when deleting empty parents 2019-11-13 21:16:48 +01:00
Jonas Kvinge
bc0c50ee65 Remove commented code 2019-11-13 21:12:50 +01:00
Jonas Kvinge
45e9dd96d1 Remove left click on analyzer to popup menu
Fixes #294
2019-11-11 00:01:39 +01:00
Jonas Kvinge
1cc73562a3 Turn back git revision 2019-11-10 15:35:36 +01:00
Jonas Kvinge
d870ef0bd5 Release 0.6.6 2019-11-09 17:21:08 +01:00
Jonas Kvinge
53d308dac5 Exclude .github dir in maketarball.sh 2019-11-09 17:16:18 +01:00
Jonas Kvinge
89b06ae7c7 Mulitply samples by channels, dont hardcode to 2 2019-11-09 16:34:17 +01:00
Jonas Kvinge
d38485a8ad Update Changelog 2019-11-09 16:30:23 +01:00
Jonas Kvinge
834877c503 Refactor gstreamer engine code, equalizer and fix stereo balancer 2019-11-08 23:07:21 +01:00
Jonas Kvinge
d033b79af4 Remove exclusive for wasapisink
Fixes #283
2019-11-07 20:26:25 +01:00
Jonas Kvinge
daec2cc203 Remove g_type_init 2019-11-06 21:53:27 +01:00
Jonas Kvinge
4e593cebab Add const 2019-11-06 21:53:09 +01:00
Jonas Kvinge
73d7701e94 Update FUNDING.yml 2019-11-05 19:38:46 +01:00
Strawbs Bot
24f1d7a72f Update translations 2019-11-04 01:07:14 +01:00
Jonas Kvinge
6387a01d7b Fix updating compilations
Fixes #288
2019-11-03 23:23:04 +01:00
Jonas Kvinge
e838840548 Remove duplicate check 2019-11-03 19:56:10 +01:00
Jonas Kvinge
6a430b441e Remove debug line 2019-11-03 19:56:01 +01:00
Jonas Kvinge
7b977ea839 Rename EngineDevice --> DeviceFinders, Add MMDeviceFinder 2019-11-03 19:53:08 +01:00
Jonas Kvinge
62b8521cbe Update Changelog 2019-10-29 19:27:03 +01:00
Martin Delille
308244d901 Change email (#287)
I didn't noticed you mention me in the *About...* section. Thank you for that even if it is an oversized thank you for the contributions made! : sweat_smile:

I just update it to my personal address.
2019-10-29 19:12:29 +01:00
Jonas Kvinge
6f521183f9 Fix spelling 2019-10-28 20:20:13 +01:00
Jonas Kvinge
76c6f7e733 Update README.md 2019-10-28 20:06:22 +01:00
Strawbs Bot
80ebfbeb6b Update translations 2019-10-28 01:02:39 +01:00
Jonas Kvinge
793901b319 Revert accidental change to flac test file 2019-10-28 00:05:29 +01:00
Jonas Kvinge
3950df8ec9 Add libgstwasapi.dll to nsi 2019-10-27 23:55:03 +01:00
Jonas Kvinge
e800b236aa Simplify the pipeline
Fix issue where bitrate is updated incorrectly by stream discoverer
Fixes issue #282
Also make it possible to enable stereo balancer without enabling the
equalizer
2019-10-27 23:48:54 +01:00
Jonas Kvinge
4ab7871106 Add wasapisink to directsound devicefinder 2019-10-27 23:47:28 +01:00
Jonas Kvinge
3de85549b6 Add option to automatically select current playing track 2019-10-27 02:11:51 +01:00
Jonas Kvinge
73164f7182 Update scrobble point when song is restarted 2019-10-27 02:09:34 +01:00
Strawbs Bot
004b000890 Update translations 2019-10-21 01:23:16 +02:00
Jonas Kvinge
d9c703d944 Add gst/audio/audio.h include 2019-10-20 20:04:23 +02:00
Jonas Kvinge
364b650033 Convert S32LE to S16LE for analyzer 2019-10-20 18:52:58 +02:00
Jonas Kvinge
156eb874db Fix analyzer and cleanup old pipeline code
- Move HandoffCallback to audio queue
- Add new callback for detecting source format
- Remove old decodebin stuff
2019-10-20 02:56:47 +02:00
Strawbs Bot
1a28dd0311 Update translations 2019-10-20 01:24:47 +02:00
Jonas Kvinge
e29b4b8609 Add more alternative icon names 2019-10-20 01:11:40 +02:00
Jonas Kvinge
c02997e6d9 More icon fixes 2019-10-20 00:59:22 +02:00
Jonas Kvinge
7c9fc91af9 Enable system theme icons, add iconmapper and rename some icon names 2019-10-20 00:17:28 +02:00
Jonas Kvinge
cf5198ac64 Limit tagreader workers to 2 2019-10-19 15:09:18 +02:00
Strawbs Bot
e76ddd6dd2 Update translations 2019-10-19 14:56:24 +02:00
Jonas Kvinge
e3a4cf1cf5 Add option to prefer album artist when sending scrobbles
Fixes #274
2019-10-19 02:56:23 +02:00
Jonas Kvinge
5844616ea8 Only ignore closeEvent when minimizing to system tray
Fixes #277
2019-10-19 02:21:20 +02:00
Jonas Kvinge
abeb580228 Disable analyzer for other bit depths than 16
This removes the splitting of the pipeline with the tee.
Move HandoffCallback to the source, which makes it possible to convert the audio buffer in HandoffCallback later.
Until then just disable analyzer for other formats.

Removes tee and probe queue converter and sink
2019-10-19 01:45:24 +02:00
Ike Devolder
4d888dfce8 subsonic: change disc to discNumber (#278)
As found in the v1.13.0 xsd, the disc is named discNumber in the api,
currently there is a check for disc which will never be found in the
response.

@see http://www.subsonic.org/pages/inc/api/schema/subsonic-rest-api-1.13.0.xsd

Signed-off-by: BlackEagle <ike.devolder@gmail.com>
2019-10-17 17:06:30 +02:00
Jonas Kvinge
08ff6f0ede Only use gcc 2019-10-13 00:17:01 +02:00
Jonas Kvinge
c458c27231 Switch to opensuse leap 15.1 2019-10-12 23:49:41 +02:00
Jonas Kvinge
9821b70c38 Dont use gst_caps_to_string as it causes hang with some formats 2019-10-12 01:58:01 +02:00
Jonas Kvinge
8ab8401110 Update libprotobuf in nsi 2019-10-06 17:53:00 +02:00
Strawbs Bot
4f798c85cf Update translations 2019-10-05 01:01:44 +02:00
Jonas Kvinge
1949bdb43f Merge branch 'master' of github.com:jonaski/strawberry 2019-10-04 17:09:08 +02:00
Jonas Kvinge
8cf2e6b31b Remove all lines in settings 2019-10-04 17:08:35 +02:00
Jonas Kvinge
b1069f9f18 Disable use system icons option 2019-10-04 17:08:12 +02:00
Strawbs Bot
fb8dfa9ae9 Update translations 2019-10-04 01:07:02 +02:00
Jonas Kvinge
4402a56e94 Fix compile with optional components disabled 2019-10-03 23:29:52 +02:00
Jonas Kvinge
f449808ba3 Fix: imobiledevice depends on libgpod enabled 2019-10-03 22:54:40 +02:00
Jonas Kvinge
5599739433 Fix lowercased playlist album artist column
Fixes #275
2019-10-03 18:25:50 +02:00
Jonas Kvinge
197cf85f56 Turn back git revision 2019-10-01 21:42:08 +02:00
Jonas Kvinge
8c039c9c8b Release 0.6.5 2019-09-30 22:05:42 +02:00
Jonas Kvinge
c1d9bc046d Change context default 2019-09-30 22:05:03 +02:00
Jonas Kvinge
cd99fac7ed Fix OSD Pretty upper left (0,0) position and positioning on Windows
Fixes #269
2019-09-30 20:32:34 +02:00
Jonas Kvinge
f4489e6807 No need to initialize SimpleMetaBundle here 2019-09-30 20:31:18 +02:00
Jonas Kvinge
f2078271b6 Only update scrobble point in SetStreamMetadata when length is changed 2019-09-30 18:58:55 +02:00
Jonas Kvinge
a3ae9acebb Listenbrainz: don't send "various artists" as artist 2019-09-29 13:50:24 +02:00
Jonas Kvinge
b0580265ca Listenbrainz: don't send "various artists" as album artist
Fixes #273
2019-09-29 13:31:46 +02:00
Jonas Kvinge
b4f012392a Fix full validation of appdata file
Fixes #271
2019-09-29 13:29:52 +02:00
Jonas Kvinge
1598809f55 Fix OSD reposition image 2019-09-25 19:01:55 +02:00
Jonas Kvinge
6d4f7aa61f Turn back git revision 2019-09-25 18:54:22 +02:00
Jonas Kvinge
382080ae4e Release 0.6.4 2019-09-25 13:54:16 +02:00
Strawbs Bot
66ac529bca Update translations 2019-09-25 12:01:08 +02:00
Jonas Kvinge
ab72207027 Change domain 2019-09-24 00:06:37 +02:00
Jonas Kvinge
e3aebf1ca2 Update maketarball.sh.in 2019-09-23 22:23:30 +02:00
Jonas Kvinge
0e5820c038 Update file types 2019-09-23 21:52:48 +02:00
Jonas Kvinge
780e4d34df Update Changelog 2019-09-23 21:32:56 +02:00
Jonas Kvinge
a8700572b7 Allow empty artist and album in Subsonic song replies
Fixes #266
2019-09-23 19:20:11 +02:00
Jonas Kvinge
055516312a Fix signature in Qobuz stream url request
Fixes #267
2019-09-23 19:18:12 +02:00
Jonas Kvinge
76b4a6585e Update copyrights 2019-09-23 19:17:41 +02:00
Jonas Kvinge
b57535c5ad Make gstreamer discoverer handle next url too 2019-09-23 01:03:03 +02:00
Jonas Kvinge
eb10a15eee Reset next item temporary metadata 2019-09-23 01:00:55 +02:00
Jonas Kvinge
30ed362a8c Increase preload gap 2019-09-23 01:00:27 +02:00
Jonas Kvinge
34f071ed1d Change conflicting variable 2019-09-23 00:34:29 +02:00
Jonas Kvinge
3d3d641e1c Fix player not using preloaded stream url breaking gapless playback
Fixes #26
2019-09-22 22:47:07 +02:00
Jonas Kvinge
10c11f2c3d Fix compile on older Qt than 5.11 2019-09-22 22:43:54 +02:00
Jonas Kvinge
cec2745dc0 Qobuz: Send mac address as device_manufacturer_id in login 2019-09-22 17:10:04 +02:00
Jonas Kvinge
8d15edb063 Add function to get mac address 2019-09-22 17:06:45 +02:00
Jonas Kvinge
38cf3dc141 Only set user agent if it's missing in NetworkAccessManager 2019-09-22 17:05:26 +02:00
Jonas Kvinge
c146290e07 Add function to get mac address 2019-09-22 17:04:57 +02:00
Jonas Kvinge
a1745289be Correct app id header 2019-09-21 18:54:15 +02:00
Jonas Kvinge
5a7dbfc87a qobuz: add headers to requests 2019-09-21 18:53:12 +02:00
Jonas Kvinge
f645950a8f Change all API urls to https 2019-09-20 23:22:27 +02:00
Jonas Kvinge
b273da0b5e Switch to openssl 1.1 in nsi 2019-09-20 18:49:53 +02:00
Jonas Kvinge
689f1eb0c5 Add libgiognutls.dll to nsi 2019-09-20 18:31:35 +02:00
Jonas Kvinge
b0a2edf5fa tagreader: remove use of deprecated taglib functions 2019-09-20 18:07:43 +02:00
Jonas Kvinge
e7b5e02657 Update taglib 2019-09-20 18:07:13 +02:00
Jonas Kvinge
2d4efd6cf0 Add libbrotlicommon.dll 2019-09-19 20:56:39 +02:00
Jonas Kvinge
defc0ada78 Fix compile warnings 2019-09-19 17:44:14 +02:00
Jonas Kvinge
2f3f4f609c Rename libbrotlidec-0.dll to libbrotlidec.dll 2019-09-19 17:24:49 +02:00
Jonas Kvinge
4a9c9f8cd4 gstreamer: disconnect callbacks, avoid gst_discoverer_stop 2019-09-17 22:42:51 +02:00
Jonas Kvinge
bdc089290d Add fallthrough comments and remove -Wimplicit-fallthrough=0
Signed-off-by: Jonas Kvinge <jonas@jkvinge.net>
2019-09-16 21:20:12 +02:00
Strawbs Bot
cf9f48d8da Update translations 2019-09-16 20:57:06 +02:00
Jonas Kvinge
2d67279180 Fix minor code issues 2019-09-15 20:27:32 +02:00
Jonas Kvinge
83e10aac27 Fix exiting macos devicelister 2019-09-15 01:12:05 +02:00
Jonas Kvinge
9972124aa1 Add gstreamer plugins to macdeploy.py 2019-09-14 20:30:06 +02:00
Jonas Kvinge
d0eb1ba96e Avoid gst_discoverer_stop on all OSes except Linux 2019-09-14 20:11:29 +02:00
Jonas Kvinge
f5d2910638 Add libbrotlidec-0.dll and libpsl-5.dll to nsi 2019-09-12 20:38:13 +02:00
Jonas Kvinge
1cafaf3a79 Disable video for playbin 2019-09-12 18:07:10 +02:00
Jonas Kvinge
fccc133cb2 Update gstreamer plugins in nsi 2019-09-11 21:00:44 +02:00
Jonas Kvinge
9fb50b8a73 Update taglib 2019-09-11 00:36:03 +02:00
Jonas Kvinge
c66c1e17d3 Make gstreamer pipeline detect filetype 2019-09-09 22:11:13 +02:00
Jonas Kvinge
4496760340 Dont search for lyrics if tags are empty 2019-09-09 21:48:22 +02:00
Jonas Kvinge
506200d2ee Update supported audio in README 2019-09-09 21:47:54 +02:00
Jonas Kvinge
04898a3b01 Add Ogg Vorbis test audio file 2019-09-09 21:47:39 +02:00
Jonas Kvinge
f67fb53308 Fix conflicting variable 2019-09-09 18:17:56 +02:00
Jonas Kvinge
c5b78dde04 Convert remaining foreach to C++11 for loops 2019-09-09 00:53:05 +02:00
Jonas Kvinge
57d9c87de6 Replace NULL with nullptr 2019-09-08 21:18:26 +02:00
Jonas Kvinge
795f95d855 Add gstreamer stream discoverer workaround for Windows
- gst_discoverer_stop seem to block
2019-09-08 21:07:56 +02:00
Jonas Kvinge
c0ebbc8e2f Fix ampache compatibility 2019-09-08 19:46:51 +02:00
Jonas Kvinge
fb377c32ea Initialize filetype and bitrate 2019-09-08 17:36:50 +02:00
Jonas Kvinge
e13faff2d7 Add missing include for assert 2019-09-08 00:36:32 +02:00
Jonas Kvinge
b0c5348116 Remove comment 2019-09-07 23:50:36 +02:00
Jonas Kvinge
b462ec022a Remove unused variable 2019-09-07 23:50:26 +02:00
Jonas Kvinge
e45a0bf24b Add stream discoverer to gstreamer pipeline and continuous updating of bitrate 2019-09-07 23:34:13 +02:00
Jonas Kvinge
8962644ba8 Improvements to device manager
- Mount and unmount devices in lister thread
- Safely close watcher and backends for devices
- Enable abort loading device
- Fix MTP connection
2019-09-07 23:30:35 +02:00
Jonas Kvinge
ad5e04bbcc Always ignore closeEvent 2019-09-05 19:07:58 +02:00
Jonas Kvinge
6fc7baec39 Add Russian 2019-09-01 23:59:03 +02:00
Jonas Kvinge
acd49a9c40 Update translations 2019-09-01 18:00:04 +02:00
Jonas Kvinge
bf04358a47 Replace media buttons 2019-08-29 22:11:22 +02:00
Jonas Kvinge
b7e13c7b86 Fix windows thumbbar 2019-08-29 21:32:52 +02:00
Jonas Kvinge
9b45f0661e Add option to bundle gstreamer plugins on Linux 2019-08-27 22:29:48 +02:00
Jonas Kvinge
2a61b1202b Set subsonic API version to 1.13.0 2019-08-27 17:26:49 +02:00
Jonas Kvinge
114f862ea4 TagLib MP4 - setTrack()/setYear() accepts 0 to remove the tag 2019-08-26 23:50:14 +02:00
Jonas Kvinge
5a490a8b5a SingleApplication: Fallback to qgetenv for username on Windows too 2019-08-26 17:31:49 +02:00
Jonas Kvinge
8fdc1c1b21 SingleApplication: Use initialization list 2019-08-26 17:22:11 +02:00
Jonas Kvinge
32cac90720 SingleApplication: Remove debug output of username 2019-08-26 02:18:02 +02:00
Jonas Kvinge
b2160255d3 SingleApplication: Use geteuid / getpwuid to get username and reformat
sources
2019-08-26 02:00:47 +02:00
Jonas Kvinge
7fe1f4de93 Fix compile on OpenBSD 2019-08-26 01:37:22 +02:00
Jonas Kvinge
1fbb1b1524 Keep original window size when restoring from system tray 2019-08-23 20:43:58 +02:00
Jonas Kvinge
0105a53765 Use qgetenv instead of QProcess/whoami to get username 2019-08-22 21:38:54 +02:00
Jonas Kvinge
bd5ab80276 Use FollowRedirectsAttribute everywhere 2019-08-22 19:28:54 +02:00
Jonas Kvinge
387d790228 Fix spelling in contributor variables in about 2019-08-22 18:49:03 +02:00
Jonas Kvinge
d199a2be0d Fix typos and spelling 2019-08-22 18:45:32 +02:00
Jonas Kvinge
f81ecffda6 Don't treat songs with different album as duplicates 2019-08-21 20:46:08 +02:00
Jonas Kvinge
882f80de1e Add FollowRedirectsAttribute 2019-08-21 00:01:38 +02:00
Jonas Kvinge
4359f2a0ce Follow redirects in subsonic 2019-08-20 23:32:20 +02:00
Jonas Kvinge
9c485c4d94 Split NetworkTimeouts and RedirectFollower to it's own files
- Follow redirects by default
2019-08-20 23:31:23 +02:00
Jonas Kvinge
1330197036 Small subsonic changes
- Follow redirect in subsonic ping test
- Reset networkaccessmanager to make verify certificate setting take
affect immediately
2019-08-20 12:33:01 +02:00
Jonas Kvinge
0b0d5fa227 Add back libgstlame in macdeploy 2019-08-18 22:08:32 +02:00
Jonas Kvinge
45424b8a52 Change CFBundleIdentifier 2019-08-18 01:00:47 +02:00
Jonas Kvinge
0956acbdfb Add missing comma 2019-08-17 01:04:48 +02:00
Jonas Kvinge
654f553d8f Move InformOfCurrentSongChange() to fix crash when active playlist item
is reset
2019-08-17 00:52:29 +02:00
Jonas Kvinge
e4b6e20db6 Turn playlist glow effect off by default on macOS 2019-08-17 00:00:12 +02:00
Jonas Kvinge
b4f6c6f869 Include NSWindow in mac_startup.mm 2019-08-16 22:52:50 +02:00
Jonas Kvinge
16edc52bae Fix deprecated macOS key modifiers 2019-08-16 22:27:48 +02:00
Jonas Kvinge
a33e6c03e4 Use QPixmap::toImage() and QImage.toCGImage() instead 2019-08-16 22:26:30 +02:00
Jonas Kvinge
4dccb40bf9 Add missing uninstall for xine plugins in nsi 2019-08-14 23:29:44 +02:00
Jonas Kvinge
9ce1981f93 Fix copyright in iconloader 2019-08-14 23:28:55 +02:00
Jonas Kvinge
6374c77aa8 Read Json error when possible 2019-08-12 22:24:05 +02:00
Jonas Kvinge
871bb391d6 Add lyrics from lololyrics.com 2019-08-12 22:06:01 +02:00
Jonas Kvinge
c3903a7b35 Add lyrics from lyrics.ovh 2019-08-12 18:11:01 +02:00
Jonas Kvinge
6aabf82c11 Update issue templates 2019-08-11 23:33:15 +02:00
Jonas Kvinge
89b624aadf Update issue templates 2019-08-11 23:27:46 +02:00
Jonas Kvinge
67317292ee Create FUNDING.yml 2019-08-11 23:11:26 +02:00
Jonas Kvinge
42e7f64856 Make marking songs unavailable optional 2019-08-11 22:30:28 +02:00
Jonas Kvinge
79d963fd65 Change variable name 2019-08-11 22:29:02 +02:00
Jonas Kvinge
44649fd950 Remove remaining references to SPMediaKeyTap 2019-08-11 21:06:25 +02:00
Martin Delille
0e97f99f93 remove 3rdparty SPMediaKeyTap (#239) 2019-08-11 20:44:32 +02:00
Jonas Kvinge
4f52ceb3e0 Make fancy tabbar background color configurable 2019-08-08 23:16:45 +02:00
Jonas Kvinge
61253b5551 Update taglib 2019-08-07 19:29:40 +02:00
llucps
12bd6f0d9b Enable About Strawberry and QT menu on macOS (#237)
* Enable About Strawberry and QT menu on macOS

* Enable About Strawberry and QT menu on macOS
2019-08-07 18:26:11 +02:00
SamTShaw
a32010e03b Ipod Playlist Support (#220)
* Ipod Playlist Support

Copy a whole playlist to the ipod and create an entry in Playlists on
the iPod

* Fix formatting and indentation

Fix indenting and formatting to be consistent
2019-08-07 17:13:40 +02:00
Jonas Kvinge
4a934c9dab Remove use of some deprecated code and cleanup other macOS code 2019-08-06 20:31:54 +02:00
Jonas Kvinge
20766c1feb Fix systemtray icon on macOS 2019-08-06 20:31:31 +02:00
Jonas Kvinge
6cd4de548f Turn back git revision 2019-08-06 15:17:31 +02:00
Jonas Kvinge
8ac4dea8f1 Release 0.6.3 2019-08-05 23:26:19 +02:00
Jonas Kvinge
e8af3e8d3c Simplify if statement 2019-08-05 23:03:40 +02:00
Jonas Kvinge
cd05b10168 Remove extra debugging 2019-08-05 23:03:04 +02:00
Jonas Kvinge
140935bd8c Add album - disc grouping 2019-08-05 19:17:31 +02:00
Jonas Kvinge
ecb122d93c Make collection watcher unwatch removed directories
Fixes #233
2019-08-05 18:40:47 +02:00
Jonas Kvinge
c6e08e0039 Fix crash in internet services 2019-08-05 18:38:27 +02:00
Jonas Kvinge
be1e14df81 Fix musicbrainz tagfetcher 2019-08-04 16:02:22 +02:00
Jonas Kvinge
28bca261fb Fix mageia rpm suffix 2019-08-04 03:16:30 +02:00
Jonas Kvinge
2ab5bc1ad2 Turn back git revision 2019-08-04 03:16:08 +02:00
Jonas Kvinge
10c57cf6da Release 0.6.2 2019-08-03 13:57:54 +02:00
Jonas Kvinge
e65c5eeab1 Release 0.6.1 2019-08-03 13:29:22 +02:00
Jonas Kvinge
85fad35dc2 Update README.md 2019-08-03 13:15:43 +02:00
Jonas Kvinge
c992768efe Remove ChartLyrics (service is down) 2019-08-03 13:08:14 +02:00
Jonas Kvinge
7b13c0d059 Fix watching new subdirs in collection watcher 2019-08-02 23:58:47 +02:00
Jonas Kvinge
2d3f41da6f Automatically remove devices with old schemas when upgrading 2019-08-02 22:58:30 +02:00
Jonas Kvinge
43b9941dc8 Make sqlite3 fts5 check fatal 2019-08-02 21:12:18 +02:00
Jonas Kvinge
dcf27f54aa Add rpm syntax for mageia 2019-08-02 20:25:46 +02:00
Jonas Kvinge
fbf6b69e75 Update Changelog 2019-08-01 22:01:27 +02:00
Jonas Kvinge
0bfebd90da Add CMAKE_REQUIRED_FLAGS --std=c++11 to check_cxx_source_runs 2019-08-01 21:49:19 +02:00
Jonas Kvinge
e7c3dafa36 Handle a case where the playing widget is gets stuck when switch fast
between context and other widgets
2019-08-01 21:15:46 +02:00
Jonas Kvinge
e90a36da79 Fix track slider popup being stuck 2019-08-01 20:03:37 +02:00
Jonas Kvinge
93f33615ad Don't use check_cxx_source_runs when cross-compiling 2019-07-31 23:06:59 +02:00
Jonas Kvinge
99569081c9 Simply some song checks and make url always unique by using stream url
instead
2019-07-31 22:26:51 +02:00
Jonas Kvinge
588a0b3c41 Add cmake test for sqlite3 FTS5 2019-07-31 20:05:38 +02:00
Jonas Kvinge
4a1118ceb3 Fix macOS build 2019-07-31 20:03:24 +02:00
Jonas Kvinge
a65415bc10 Fix device schema 2019-07-30 22:56:33 +02:00
Jonas Kvinge
8a0e66bf11 Switch to FTS5 with unicode61 (#229)
* Switch to FTS5 with unicode61

* Update required sqlite version in README

* Update README

* Change back db file
2019-07-30 22:45:22 +02:00
Jonas Kvinge
02cda47c28 Disable trackslider popup on macos 2019-07-30 22:11:09 +02:00
Jonas Kvinge
d34a323a81 Handle cases where playlist background album gets stuck on error 2019-07-30 21:32:56 +02:00
Jonas Kvinge
4166ae8db0 Check HttpStatusCodeAttribute 2019-07-30 21:32:20 +02:00
Jonas Kvinge
955b906b52 Add Song() != operator 2019-07-30 21:31:26 +02:00
Jonas Kvinge
0d424aa81e Dont fetch lyrics again if only url is changed through url handler 2019-07-30 21:30:52 +02:00
Jonas Kvinge
80acbfa56a Update contributors 2019-07-30 21:30:08 +02:00
Jonas Kvinge
a7cac24004 Unref pipeline in moodbar on failure 2019-07-28 23:42:12 +02:00
Jonas Kvinge
2927bcf09d Merge branch 'master' of github.com:jonaski/strawberry 2019-07-28 14:58:52 +02:00
Jonas Kvinge
08dee6bb4f Fix error message from url handler 2019-07-28 14:58:34 +02:00
Jonas Kvinge
08c92f906a Update translations 2019-07-27 13:25:51 +02:00
Jonas Kvinge
8e9c9802d1 Change new line to unix 2019-07-27 12:34:27 +02:00
Jonas Kvinge
138df66d5e Use common nsi file 2019-07-27 12:32:28 +02:00
Jonas Kvinge
0a71347e9a Fix playlist shortcuts 2019-07-26 22:46:04 +02:00
Jonas Kvinge
2a541a7b9c Update README 2019-07-26 20:55:20 +02:00
Jonas Kvinge
705c12e8da Update README and Changelog 2019-07-26 20:52:47 +02:00
Jonas Kvinge
cf33df1339 Log system type on startup 2019-07-26 19:24:16 +02:00
Jonas Kvinge
87e543b5ef Fix collection query 2019-07-26 19:14:15 +02:00
Jonas Kvinge
81caec99b7 Fix closing databases 2019-07-25 17:56:28 +02:00
Jonas Kvinge
41484f8673 Fix exit 2019-07-24 23:29:09 +02:00
Jonas Kvinge
da0d61f36a Fix regression in playlist backend caused by previous commits 2019-07-24 21:37:09 +02:00
Jonas Kvinge
6f3bc74db0 Fix cross-compile for windows 2019-07-24 19:34:33 +02:00
Jonas Kvinge
af3bd6ec2f Use QNetworkAccessManager::supportedSchemes() 2019-07-24 19:27:00 +02:00
Jonas Kvinge
b5eb13449b Safely close database connections and delete backends
Also fix NewClosure leak caused by disconnected object signals
2019-07-24 19:16:51 +02:00
Jonas Kvinge
bd78e8c275 Fix memory leaks 2019-07-22 20:53:05 +02:00
Jonas Kvinge
2df21081a1 Fix pixmap cache in collection model
- Properly remove both from pixmap cache, pending art and pending cache keys when songs are deleted
- Increase default pixmap cache
- Clear pixmap cache when model is reset
2019-07-22 19:57:53 +02:00
Jonas Kvinge
ffebff4ea9 Fix uninitialized variable 2019-07-21 21:28:45 +02:00
Jonas Kvinge
2885bc99ca Fix memory leak in Database::BackupFile 2019-07-21 18:50:16 +02:00
Jonas Kvinge
2657b80adb Fix memory leak in tagreader 2019-07-21 15:12:28 +02:00
Jonas Kvinge
ebfc106701 Update libcdio 2019-07-21 13:19:27 +02:00
Jonas Kvinge
4d60ca951d Update Changelog 2019-07-21 00:05:54 +02:00
Jonas Kvinge
acf5c57599 Use InitArtManual in InitFromFilePartial 2019-07-20 22:53:01 +02:00
Jonas Kvinge
927df5ff39 Bump LSMinimumSystemVersion to 10.13.4 2019-07-20 15:26:36 +02:00
Jonas Kvinge
31fc031267 Fix missing qt plugins in macOS travis-ci build (#225) 2019-07-20 15:23:22 +02:00
Jonas Kvinge
02794e0ebd Add libzstd and libtasn1-6 2019-07-20 02:26:44 +02:00
Jonas Kvinge
ea6cce7068 Fix mtp device support 2019-07-19 19:56:37 +02:00
SamTShaw
e4cefeaa8f Ipod Support when listed from Udisks2 (#219)
Udisks2 didn't check to see if the device was actually an ipod, like
GIODeviceLister does.
2019-07-19 19:22:14 +02:00
Jonas Kvinge
d12d5fd8ae Update .travis.yml 2019-07-18 23:55:30 +02:00
Jonas Kvinge
0617c3fdc0 Update .travis.yml 2019-07-18 23:09:01 +02:00
Jonas Kvinge
f00eedf57e Update .travis.yml 2019-07-18 22:12:48 +02:00
Jonas Kvinge
6d36ae6197 Update .travis.yml 2019-07-18 21:35:07 +02:00
Martin Delille
45125abb8f Fix Finder icon (#216)
- Regenerate new strawberry.icns
- Fix Info.plist CFBundleIconFile
- Install Info.plist to strawberry.app
2019-07-17 23:13:15 +02:00
Jonas Kvinge
045b0cd075 Remove bogus svg 2019-07-17 22:35:19 +02:00
Martin Delille
ff3333e1bf Use create-dmg to generate MacOS release (#215) 2019-07-17 22:05:41 +02:00
Martin Delille
7663c5e149 MacOS CI improvement (#214)
* travis ci osx: simpler lib path

* Remove unnecessary sudo
2019-07-17 21:10:17 +02:00
Jonas Kvinge
4d4748a0a8 Update protobuf 2019-07-14 12:26:07 +02:00
Jonas Kvinge
f8f84ed09e Only replace non-ascii characters when not allowing extended ascii 2019-07-14 03:16:53 +02:00
Jonas Kvinge
e7de7ebbfa Use iconv to replace non-ascii characters 2019-07-14 03:08:19 +02:00
Jonas Kvinge
c9f01f4bc4 Remove old devicekit udisks backend 2019-07-13 23:00:25 +02:00
Jonas Kvinge
f2675adc05 Remove vlc, xine and phonon from deb 2019-07-13 22:52:05 +02:00
Jonas Kvinge
75beaa3684 Make sure device is valid before adding it 2019-07-13 18:28:29 +02:00
Jonas Kvinge
079495cc32 Remove usless include in cmake 2019-07-13 18:02:25 +02:00
Jonas Kvinge
c8bd89e56f Remove support for old imobiledevice uuid, it won't work anyway because
of other changes
2019-07-13 17:55:50 +02:00
Jonas Kvinge
b089ba2e04 Free memory of service descriptor and fix possible crashes 2019-07-13 17:33:58 +02:00
Jonas Kvinge
adbf8495c6 Add libgstaiff.so to macdeploy 2019-07-12 20:32:52 +02:00
Jonas Kvinge
ad062862d8 Add device url to mtp loader failure message 2019-07-12 20:32:30 +02:00
Gavin D. Howard
3a86a93154 Extend article sorting to artist and album artist (#210) 2019-07-11 16:51:25 +02:00
Jonas Kvinge
dcf0d6f72d Fix thread crash in mtpdevice 2019-07-11 00:28:19 +02:00
Jonas Kvinge
83d3725240 Fix MessageReply crash in tagreader 2019-07-10 22:40:30 +02:00
Jonas Kvinge
ce1dd69557 Change defaults in device schema 2019-07-10 20:04:05 +02:00
Jonas Kvinge
4081bdd752 Fix ctime in tagreader 2019-07-10 20:02:51 +02:00
Jonas Kvinge
c3f1e312b3 Change defaults in schemas 2019-07-10 20:02:21 +02:00
Jonas Kvinge
d820878b89 Fix oauth checkbox in tidal settings 2019-07-09 22:53:50 +02:00
Jonas Kvinge
7fa1461d5e Use QUrl::isLocalFile() 2019-07-09 21:43:56 +02:00
Jonas Kvinge
f4b1ef4d04 Set initial position of OSDPretty 2019-07-09 20:28:43 +02:00
Jonas Kvinge
656130a739 Replace QDesktopWidget in OSDPretty 2019-07-09 19:49:15 +02:00
Jonas Kvinge
aa8679dff5 Fix TryLoadPixmap and ShowCover 2019-07-09 01:14:58 +02:00
Jonas Kvinge
f94a3095fd Fix TryLoadPixmap and ShowCover 2019-07-09 01:05:42 +02:00
Jonas Kvinge
e11958dd58 Fix index in InternetSearchModel 2019-07-09 01:02:54 +02:00
Jonas Kvinge
a5a251a964 Remove use of QDesktopWidget in QSearchField 2019-07-09 00:05:08 +02:00
Jonas Kvinge
8cb1015a35 Remove use of QDesktopWidget in settingsdialog 2019-07-09 00:04:52 +02:00
Jonas Kvinge
b5dd90b2d5 Check QT_VERSION_CHECK for QImage::sizeInBytes() or QImage::byteCount() 2019-07-08 23:35:43 +02:00
Jonas Kvinge
5f7efee00e ifdef QFontMetrics::horizontalAdvance to make it work with older Qt 2019-07-08 23:27:45 +02:00
Jonas Kvinge
4150e3efde Use QT_VERSION to check whether to use QFileInfo::birthTime() or
QFileInfo::created()
2019-07-08 22:54:13 +02:00
Jonas Kvinge
8ebcb71e6e Replace all uses of QSignalMapper with lambda expressions 2019-07-08 22:27:45 +02:00
Jonas Kvinge
f3e852c042 Replace QImage::byteCount() with sizeInBytes() 2019-07-08 22:25:56 +02:00
Jonas Kvinge
5e2a07d144 Remove unused typedef 2019-07-08 22:24:47 +02:00
Jonas Kvinge
25f6231e9d Replace QString::null with QString() 2019-07-08 22:24:00 +02:00
Jonas Kvinge
beeba88ea5 Replace QModelIndex child() with index() 2019-07-08 22:23:15 +02:00
Jonas Kvinge
cc3d454d60 Add lyrics to edit tag dialog 2019-07-08 22:21:12 +02:00
Jonas Kvinge
afb583cff4 Remove unused typedef 2019-07-08 22:20:41 +02:00
Jonas Kvinge
561fa66393 Replace QFontMetrics::width with horizontalAdvance 2019-07-08 22:20:02 +02:00
Jonas Kvinge
870dc0d36f Replace QFontMetrics::width with horizontalAdvance, dark with darker, background() with window() and QString::null with QString() 2019-07-08 22:19:14 +02:00
Jonas Kvinge
51462dee1e Use QUrl::fromEncoded 2019-07-08 22:10:43 +02:00
Jonas Kvinge
c752d28c6a Change QFileInfo::created() to birthTime(), read lyrics from MP3 files 2019-07-08 22:01:34 +02:00
Jonas Kvinge
d5ca0ca283 Change compiler flags 2019-07-08 21:59:07 +02:00
Jonas Kvinge
f371b3a338 Fix tidal request 2019-07-08 17:08:10 +02:00
Jonas Kvinge
93fc4a2c86 Fix Tidal api URL 2019-07-08 08:10:52 +02:00
Jonas Kvinge
f10d3f86cc Fix Mpris2 AlbumCoverLoaded 2019-07-08 00:13:45 +02:00
Jonas Kvinge
af17b0015b Fix InitArtManual() to use album artist 2019-07-07 21:56:30 +02:00
Jonas Kvinge
61af1d1c72 Update file filter 2019-07-07 21:36:05 +02:00
Jonas Kvinge
65780e1672 Improve album cover searching and cover manager, use HttpStatusCodeAttribute and QSslError for services
- Improve album cover manager
- Change art_automatic and art_manual to QUrl
- Refresh collection album covers when new album covers are fetched
- Fix automatic album cover searching for local files outside of the collection
- Make all Json services check HttpStatusCodeAttribute
- Show detailed SSL errors for Subsonic, Tidal and Qobuz
2019-07-07 21:14:24 +02:00
Jonas Kvinge
c92a7967ea Change filename to url 2019-07-06 14:54:41 +02:00
Jonas Kvinge
60aed593b3 Fix download albumcovers setting 2019-07-06 00:16:13 +02:00
Jonas Kvinge
044f347729 Re-enable tidal oauth settings 2019-07-06 00:02:25 +02:00
Jonas Kvinge
aec9df1882 Switch to queue2 for probe queue (#204) 2019-07-05 23:50:57 +02:00
Jonas Kvinge
4f0a2515f8 Tweak the background image settings a bit
- Disable "do not cut" option when keep aspect ratio is unchecked
- Shorten text and add spacer to widget
2019-07-05 01:07:19 +02:00
Gavin D. Howard
5cde33711e Make playlist ignore articles when sorting (#202)
This is more correct, and the other way is driving me crazy.
2019-07-05 00:13:51 +02:00
Jonas Kvinge
64750025f6 Update libnettle 2019-07-04 22:51:17 +02:00
Jonas Kvinge
cd1cbfdffe Update libhogweed 2019-07-04 22:44:42 +02:00
Jonas Kvinge
d413f2c3a7 Revert "Try queue2 for probe queue"
This reverts commit a9c162476c.
2019-07-03 02:24:32 +02:00
Jonas Kvinge
ba314dd734 Set source in backends to fix losing source in InitFromFilePartial()
when updating path
2019-07-02 00:48:40 +02:00
Jonas Kvinge
9105b7615c Change to reference 2019-07-02 00:48:09 +02:00
Jonas Kvinge
a9c162476c Try queue2 for probe queue 2019-07-02 00:47:10 +02:00
Jonas Kvinge
732b37aca0 Use QMap::contains() 2019-07-01 19:20:57 +02:00
Jonas Kvinge
291b5fad7f Updated Changelog 2019-07-01 01:08:07 +02:00
Jonas Kvinge
c2a6def8b9 Rename cache album covers to download album covers and only do it for
favorite requests
2019-07-01 01:01:30 +02:00
Jonas Kvinge
9083c578cc Add live scanning (#199) 2019-06-30 21:06:07 +02:00
m4x3t
bcfd1d39bb Modify stretch background image functionality (#198)
* Modify stretch background image functionality

Changes the stretch functionality to fill out
the playlist background completely by zooming
the image (if keep aspect ratio is selected)
instead of filling it only height-wise.

* Add option to keep old background fill

* Fix playlist background image width and height

* Fix width calculation

* Remove old calculations
2019-06-30 19:37:05 +02:00
Jonas Kvinge
1185b910c4 Ops 2019-06-29 20:29:37 +02:00
Jonas Kvinge
540b6eba04 Fix hardcoded systemtray icon 2019-06-29 20:18:54 +02:00
Jonas Kvinge
47f4287e64 Merge remote-tracking branch 'origin/musicbrainz' 2019-06-29 19:58:10 +02:00
Jonas Kvinge
264c6e259b Respect rate limiting when fetching tags from musicbrainz 2019-06-29 19:57:20 +02:00
m4x3t
0bbe9838c4 Add option: notification on playback resume (#196)
* Add option: notification on playback resume

This adds an optional setting to show the
notification that is displayed when changing
the track when resuming playback as well.

* Modify resume notification calling

This adds a new signal "Resumed" that is emitted
when the player status is changed from Paused
to Playing.
The AlbumArtLoaded function will only be called
again when playback is manually resumed, and not
when the player is started for the first time
or when the track is changed.
2019-06-29 19:54:27 +02:00
Jonas Kvinge
2fe337eac3 Partial revert travis_terminate 2019-06-29 19:18:26 +02:00
Jonas Kvinge
5d7caafdf7 Terminate if one of the commands fail inside an if statement 2019-06-29 16:31:47 +02:00
Jonas Kvinge
f416ef925b Only create private key if DEPLOY_KEY_ENC is set 2019-06-29 15:57:30 +02:00
Jonas Kvinge
60bd90848b Add tests (#193) 2019-06-28 01:33:22 +02:00
Jonas Kvinge
b9f4407815 Change to const QString& 2019-06-23 18:34:03 +02:00
Jonas Kvinge
f9cd2639ff Remove annoying <year> Remaster from album and song titles 2019-06-23 18:32:15 +02:00
Jonas Kvinge
aeb36e8665 Simplify generating queries in lyrics providers 2019-06-23 16:45:00 +02:00
Jonas Kvinge
057482a3e5 Lower default search limits 2019-06-23 00:20:53 +02:00
Jonas Kvinge
15721da46e Read duration, samplerate and bit depth from stream url replies 2019-06-22 08:39:30 +02:00
Jonas Kvinge
f12b82b5ce Move checkboxes into preferences groupbox in Subsonic settings 2019-06-22 08:38:50 +02:00
Jonas Kvinge
10dc725942 Attempt to fix MessageReply crash when saving tags 2019-06-22 08:36:02 +02:00
Jonas Kvinge
5bd5cdf435 Make sure album_id is not null 2019-06-22 08:33:16 +02:00
Jonas Kvinge
84b3603c08 Fix initialization 2019-06-21 02:26:37 +02:00
Jonas Kvinge
8f59b96731 Update Changelog 2019-06-21 00:12:07 +02:00
Jonas Kvinge
e1de110dd7 Validate configuration better 2019-06-20 20:49:02 +02:00
Jonas Kvinge
8b6fd3d594 Make text selectable 2019-06-20 18:46:14 +02:00
Jonas Kvinge
d7761e8d79 Change parameters to const 2019-06-20 17:09:07 +02:00
Jonas Kvinge
751d652a2f Change title 2019-06-20 17:02:29 +02:00
Jonas Kvinge
647e7e708a Add confirmation box for opening songs in file browser 2019-06-20 17:00:10 +02:00
Jonas Kvinge
505c0eeae2 Set Unknown error if error is missing in Subsonic too 2019-06-20 16:37:37 +02:00
Jonas Kvinge
bf4001968e Change to const references, make search progress and status pass search id 2019-06-20 16:33:28 +02:00
Jonas Kvinge
9d222e2c57 Rename filename to url, change album_id to string and recreate songs tables (#182) 2019-06-20 02:14:44 +02:00
Jonas Kvinge
033300d659 Disable remove favorites from context menu in internetsongsview 2019-06-19 23:26:15 +02:00
Jonas Kvinge
4f2b04bd8f Enable login buttons when login attempt is complete 2019-06-19 23:15:15 +02:00
Jonas Kvinge
f8b9bb4b0f Remove user id and country code setting 2019-06-19 22:20:21 +02:00
Jonas Kvinge
8ce8e320c3 Change ids to qint64 2019-06-19 20:40:11 +02:00
Jonas Kvinge
7c0ab4212b Fix minor code issues with Qobuz 2019-06-19 12:57:12 +02:00
Jonas Kvinge
26633e0982 Fix compile error 2019-06-19 02:39:11 +02:00
Jonas Kvinge
d27a3f1f33 Set Subsonic API version to 1.15.0 2019-06-19 02:30:28 +02:00
Jonas Kvinge
89252d0dba Add Qobuz support (#181) 2019-06-19 02:22:11 +02:00
Jonas Kvinge
dbd2edf442 Fix minor code issues in tidal 2019-06-18 23:39:16 +02:00
Jonas Kvinge
dabd6f8284 Fix Subsonic API path 2019-06-18 23:25:10 +02:00
Jonas Kvinge
beb3ab463f Add missing subsonic fts songs table 2019-06-18 14:41:48 +02:00
Jonas Kvinge
1d67b623e0 Use single url setting instead for subsonic, check http code 2019-06-18 01:22:03 +02:00
Jonas Kvinge
2c8cde4d91 Add scheme setting for subsonic 2019-06-18 00:28:36 +02:00
Jonas Kvinge
8cc1d48115 Fix max concurrent requests in tidal 2019-06-18 00:02:43 +02:00
Jonas Kvinge
ec2468fb8d Remove unneeded include 2019-06-18 00:02:22 +02:00
Jonas Kvinge
7b54cef23b Add Subsonic support (#180) 2019-06-17 23:54:24 +02:00
Jonas Kvinge
a9da8811fc Turn off ssl-strict in gst pipeline 2019-06-17 23:01:38 +02:00
Jonas Kvinge
60e86b9881 Fix fading options 2019-06-17 02:23:51 +02:00
Jonas Kvinge
a6766f3c99 Fix gapless playback when using url handler 2019-06-15 19:32:26 +02:00
Jonas Kvinge
e59c3c6f70 Add MediaUrl function for playlistitems 2019-06-15 19:31:43 +02:00
Jonas Kvinge
49aa344d8b Change index to idx 2019-06-15 19:31:16 +02:00
Jonas Kvinge
4fed6ab298 Hide tidal oauth settings until streaming is possible 2019-06-14 23:02:57 +02:00
Jonas Kvinge
58eab4d3bc Fix verifying xml in tidal stream url 2019-06-14 23:02:33 +02:00
Jonas Kvinge
5ef5da687d Fix macOS build 2019-06-12 06:34:59 +02:00
Jonas Kvinge
4875d319dc Add love button 2019-06-12 00:38:52 +02:00
Jonas Kvinge
fb5a53435e Remove unused function 2019-06-11 19:28:48 +02:00
Jonas Kvinge
4f805d65b3 Fix need_login function 2019-06-11 19:26:00 +02:00
Jonas Kvinge
56ffb0deb1 Fix code challenge in tidal oauth 2019-06-10 02:29:57 +02:00
Jonas Kvinge
c0c1457073 Add optional oauth authentication for tidal 2019-06-09 19:29:25 +02:00
Jonas Kvinge
85a0748ad9 Add x-scheme-handler/tidal to desktop file 2019-06-09 03:10:37 +02:00
Jonas Kvinge
c1939a36dd Change CMakeLists.txt to use list APPEND for Qt5 2019-06-08 22:03:10 +02:00
Jonas Kvinge
b7c394b7a5 Disable fading when volume control is disabled 2019-06-08 12:04:04 +02:00
Jonas Kvinge
a070681f89 Move to private 2019-06-08 12:03:48 +02:00
Jonas Kvinge
d5e424eec8 Fix save/restore group by for internet collection 2019-06-08 00:15:54 +02:00
Jonas Kvinge
e0366d38f1 Change remove from favorites icon 2019-06-08 00:14:11 +02:00
Jonas Kvinge
cbf1d96b16 Avoid duplicate songs in the collection backend 2019-06-07 23:02:43 +02:00
Jonas Kvinge
7cc0d6bb5a Fix ItemFromSong() missing album id 2019-06-07 22:54:34 +02:00
Jonas Kvinge
e19b840ee6 Tidal artist id fixes 2019-06-07 21:02:28 +02:00
Jonas Kvinge
5c2ca1e3d9 Add tidal add/remove favorites + more tidal fixes 2019-06-07 20:23:05 +02:00
Jonas Kvinge
059c4beb30 Improve lyrics searcher 2019-06-06 18:22:41 +02:00
Jonas Kvinge
427808226f Change snap interface to network-manager-observe 2019-06-01 14:29:00 +02:00
Jonas Kvinge
5448245942 Update libprotobuf 2019-05-31 20:47:36 +02:00
Jonas Kvinge
34ab907007 Remove unused code 2019-05-31 20:47:15 +02:00
Jonas Kvinge
e5fde27859 Fix crash in tidal service 2019-05-31 02:32:01 +02:00
Jonas Kvinge
699e8e3ddb Fix schemas 2019-05-31 01:41:17 +02:00
Jonas Kvinge
28ee967371 Fix compile without xinescope 2019-05-31 01:29:56 +02:00
Jonas Kvinge
1b0b5f2554 Remove assert 2019-05-30 19:11:46 +02:00
Jonas Kvinge
1bcc86f989 Fix song search fetchalbums option 2019-05-30 18:46:17 +02:00
Jonas Kvinge
f26f932fd7 Queue tidal requests 2019-05-30 18:06:48 +02:00
Jonas Kvinge
2b7d48ce77 Distinguish albums with same name with album_id 2019-05-30 18:05:07 +02:00
Jonas Kvinge
111712fd6d Add artist_id, album_id and song id to songs 2019-05-30 18:04:30 +02:00
Jonas Kvinge
7609bc181e Implement offset to all Tidal requests 2019-05-29 17:39:51 +02:00
Jonas Kvinge
8b05af7ca3 Make xine analyzer optional 2019-05-28 18:37:51 +02:00
Jonas Kvinge
20f9108ebf Fix artists and albums limit 2019-05-28 17:34:44 +02:00
Jonas Kvinge
cecae7cdc3 Fix xine metronom compile 2019-05-27 21:56:07 +02:00
Jonas Kvinge
e5f3123567 Fix gst_pad_send_event block in ErrorMessageReceived() 2019-05-27 21:39:38 +02:00
Jonas Kvinge
27b0e27cfd initialize search id in the constructor. 2019-05-27 21:38:39 +02:00
Jonas Kvinge
890fba0f61 Add internet tabs view and tidal favorites (#167) 2019-05-27 21:10:37 +02:00
Jonas Kvinge
c4b732ff93 Add proper error handling to local redirectserver 2019-05-21 22:51:53 +02:00
Jonas Kvinge
b8fa2985d5 Fix Tidal SendLogin signal 2019-05-20 19:14:33 +02:00
Jonas Kvinge
ba741fbce8 Exclude version and path from singleapplication, dont start if message
could not be sent.
2019-05-20 18:41:12 +02:00
Jonas Kvinge
67d070c334 Increase default timeout 2019-05-20 18:40:34 +02:00
Jonas Kvinge
8576afe6f5 Fix return value of sendMessage() 2019-05-20 18:39:49 +02:00
Jonas Kvinge
36807fd376 Validate track duration 2019-05-14 19:07:02 +02:00
Jonas Kvinge
2ad1d27a59 Remove stream schema setting and add Add HI_RES option 2019-05-14 18:45:38 +02:00
Jonas Kvinge
7cc9c75d15 Make tidal token configurable 2019-05-13 23:49:09 +02:00
Jonas Kvinge
f33609bbf8 Compare artist and album case-insensitive 2019-05-13 22:38:24 +02:00
Jonas Kvinge
69eeb4b0f8 Move QSearchField to widgets and remove rest of qocoa 2019-05-08 23:34:44 +02:00
Jonas Kvinge
aa583ec1aa Set ContentTypeHeader for Tidal requests 2019-05-08 23:08:29 +02:00
Jonas Kvinge
2b9f153257 Add missing stage packages to snap 2019-05-07 21:04:52 +02:00
Jonas Kvinge
cb9b7fc917 Update appdata desktop file 2019-05-07 17:03:20 +02:00
Jonas Kvinge
74b36c8884 Remove some unneeded interfaces from the snap 2019-05-07 17:02:58 +02:00
Jonas Kvinge
89ff7d6dae Change api url of tidal cover provider 2019-05-06 18:18:31 +02:00
Jonas Kvinge
91df420cb4 Update Dockerfile 2019-05-05 23:51:59 +02:00
Jonas Kvinge
fc25c9f0bc Turn on git revision 2019-05-05 23:51:46 +02:00
Jonas Kvinge
12a27e3a8d Update snap version 2019-05-05 23:28:41 +02:00
Jonas Kvinge
125e32ff00 Release 0.5.5 2019-05-05 21:27:31 +02:00
Jonas Kvinge
4a110633e8 Use customized docker image for travis-ci 2019-05-05 21:20:39 +02:00
Jonas Kvinge
65648f8abd Change Tidal API url 2019-05-05 21:20:28 +02:00
Jonas Kvinge
50174861dc Turn back git revision 2019-05-05 21:20:05 +02:00
Jonas Kvinge
486eb1722e Release 0.5.4 2019-05-05 19:57:40 +02:00
Jonas Kvinge
740ead4059 Simplify enabling/disabling tabs code 2019-05-04 13:45:06 +02:00
Jonas Kvinge
96424be0da Fix fancy tabs loading 2019-05-03 17:32:55 +02:00
Jonas Kvinge
cd9d659672 Make sure to resume playback from correct playlist 2019-05-02 12:17:47 +02:00
Jonas Kvinge
ca140388d9 Fix resume playback on startup 2019-05-02 11:31:31 +02:00
Jonas Kvinge
8fe0229a2c Use static taglib on mageia and centos 2019-05-01 12:43:10 +02:00
Jonas Kvinge
1f43de9458 Update translations 2019-05-01 12:30:00 +02:00
Jonas Kvinge
2793f38c2d Update translations 2019-05-01 12:11:09 +02:00
Jonas Kvinge
42de7de21d Fix saving playlist columns 2019-04-28 14:14:19 +02:00
Jonas Kvinge
1072dc0a41 Update Changelog 2019-04-27 23:08:54 +02:00
Jonas Kvinge
9d8f310e30 Update Changelog 2019-04-27 23:02:46 +02:00
Jonas Kvinge
170adfd00c Save geometry, tabbar and playlist on exit only, fix loading tabs in
correct order
2019-04-27 22:32:39 +02:00
Jonas Kvinge
d0135a5ff7 Change namespaces for compatibility 2019-04-26 01:12:42 +02:00
Jonas Kvinge
1c926cca45 Use namespace for static taglib to avoid collision with taglib
linked to vlc
2019-04-25 23:00:25 +02:00
Jonas Kvinge
ace8ecbb4e Add missing taglib configure checks 2019-04-25 21:37:44 +02:00
Jonas Kvinge
193fa176dc Detach vlc callbacks 2019-04-25 00:54:57 +02:00
Jonas Kvinge
054db62cfa Dont translate file types 2019-04-25 00:54:20 +02:00
Jonas Kvinge
fe549cf4c5 Fix include 2019-04-25 00:01:26 +02:00
Jonas Kvinge
d347e49b6a Fix include 2019-04-25 00:00:49 +02:00
Jonas Kvinge
d6a3f7b329 Update stylehelper license in debian/control 2019-04-24 23:46:12 +02:00
Jonas Kvinge
4171bc4c70 Delete old stylehelper 2019-04-24 23:44:04 +02:00
Jonas Kvinge
deca5e5021 Update stylehelper 2019-04-24 23:43:09 +02:00
Jonas Kvinge
e0923a0494 Fix small sidebar mode width 2019-04-23 23:03:59 +02:00
Jonas Kvinge
0a1dfeb860 Fix some minor vlc issues 2019-04-23 19:20:46 +02:00
Jonas Kvinge
1c911575fa Remove nvidia workaround 2019-04-23 19:18:50 +02:00
Jonas Kvinge
d2ef0a996f Fix context background 2019-04-23 00:55:50 +02:00
Jonas Kvinge
1e886cb12c Improve equalizer and fix alignment of label right 2019-04-22 22:21:44 +02:00
Jonas Kvinge
984abc89a8 Fix chromaprinter unref buffer crash 2019-04-22 00:42:03 +02:00
Jonas Kvinge
3c6c9741ff Fix vlc crash 2019-04-21 22:24:24 +02:00
Jonas Kvinge
247a11146c Change 0 to nullptr 2019-04-21 21:39:11 +02:00
Jonas Kvinge
d1108c533f Test without nvidia workaround 2019-04-21 21:38:24 +02:00
Jonas Kvinge
881339848f Remove osd playing connect 2019-04-21 21:03:01 +02:00
Jonas Kvinge
c44638dcbe Also disable scroll over icon to change track option on systems without
X11
2019-04-21 20:33:54 +02:00
Jonas Kvinge
4887b85b8a Disable scroll over icon to change track option on kde 2019-04-21 20:23:49 +02:00
Jonas Kvinge
239f58e290 Only create audiopanorama when equalizer is enabled 2019-04-21 20:13:03 +02:00
Jonas Kvinge
560000f69d Only reload settings once 2019-04-21 03:19:30 +02:00
Jonas Kvinge
2d3509ae56 Apply settings immediately 2019-04-21 03:15:35 +02:00
Jonas Kvinge
4cc926a627 Disable notification art when tray notification is selected 2019-04-20 23:15:34 +02:00
Jonas Kvinge
a499a70633 Only enable equalizer and analyzer with gstreamer and xine 2019-04-20 22:24:11 +02:00
Jonas Kvinge
60a9154326 Fix equalizer 2019-04-20 22:23:22 +02:00
Jonas Kvinge
f761b8d4e1 Fix includes 2019-04-20 17:36:42 +02:00
Jonas Kvinge
7a0f6684e5 Improve song loader error handling 2019-04-20 15:28:16 +02:00
Jonas Kvinge
3ed6817ac9 Initialize gstreamer independent of witch engine is used 2019-04-20 15:25:31 +02:00
Jonas Kvinge
ba76385a2f Only invalidate local files 2019-04-20 15:22:56 +02:00
Jonas Kvinge
7bcd5ba14c Fix track seeking with mouse wheel 2019-04-20 14:26:30 +02:00
Jonas Kvinge
40db9f7020 Fix updating play and skip count 2019-04-19 14:02:28 +02:00
Jonas Kvinge
dffc46551e Fix mpris2 CanPlay 2019-04-19 12:38:01 +02:00
Jonas Kvinge
cf92852bb3 Dont install event filter unless its registered 2019-04-19 12:36:54 +02:00
Jonas Kvinge
844c4a28f4 Fix incorrect desktop file returned by mpris2 2019-04-19 10:35:15 +02:00
Jonas Kvinge
d2fc5a6228 Add libfftw3-dev to snap 2019-04-18 20:39:49 +02:00
Jonas Kvinge
006da837aa Fix debian/control 2019-04-18 19:55:38 +02:00
Jonas Kvinge
d920e27ab3 Add fftw to dependencies 2019-04-18 18:28:37 +02:00
Jonas Kvinge
27bafa8ab2 Fir formatting 2019-04-18 18:28:11 +02:00
Jonas Kvinge
907d18a83a Add moodbar 2019-04-18 15:03:01 +02:00
Jonas Kvinge
37b923bea3 Change query to find both albums by artist and album artist 2019-04-18 00:45:32 +02:00
Jonas Kvinge
91e597bbdd Decrease score for unmatched artist and album 2019-04-17 22:24:34 +02:00
Jonas Kvinge
a0d697bf6f Remove unused variable 2019-04-17 22:22:35 +02:00
Jonas Kvinge
63d5018ad6 Improve cover providers score system 2019-04-17 22:18:03 +02:00
Jonas Kvinge
ca928bdacb Add missing dependencies to nsi 2019-04-17 14:26:16 +02:00
Jonas Kvinge
f7e7791b8b Update libcrypto in nsi 2019-04-17 09:04:02 +02:00
Jonas Kvinge
80c2e5b141 Update .travis.yml (#115) 2019-04-17 00:23:47 +02:00
Jonas Kvinge
63c171e3b4 Re-enable macos builds (#114) 2019-04-16 23:17:36 +02:00
Jonas Kvinge
b0bfb0fdd4 Add libgnutls to nsi 2019-04-16 22:20:30 +02:00
Jonas Kvinge
31b24d9a09 Use GnuTLS instead 2019-04-16 17:48:11 +02:00
Jonas Kvinge
8b04a3b16a Add libssl to snap 2019-04-15 23:36:55 +02:00
Jonas Kvinge
b88d35d7cb Add openssl to dependencies 2019-04-15 22:44:43 +02:00
Jonas Kvinge
e00dcf1af0 Move declarations 2019-04-15 22:44:21 +02:00
Jonas Kvinge
7f23b9b424 Add https support to localredirectserver 2019-04-15 22:17:40 +02:00
Jonas Kvinge
e9bf04031b Move debian directory 2019-04-14 18:20:06 +02:00
Jonas Kvinge
c8f2334003 Remove unneeded includes 2019-04-14 18:06:38 +02:00
Jonas Kvinge
380b84195f Add ChartLyrics provider 2019-04-14 18:02:51 +02:00
Jonas Kvinge
fd26137ad2 Remove unused code 2019-04-14 16:42:05 +02:00
Jonas Kvinge
1ad163aac3 Add tidal cover provider 2019-04-14 16:40:05 +02:00
Jonas Kvinge
36dccc8157 Change search query 2019-04-14 03:01:21 +02:00
Jonas Kvinge
6dcdf5bf92 Add deezer cover provider 2019-04-14 02:54:40 +02:00
Jonas Kvinge
0b460017b8 Add dependencies to snap 2019-04-13 13:13:53 +02:00
Jonas Kvinge
061b06cd08 Update packages in snap 2019-04-13 01:39:07 +02:00
Jonas Kvinge
86272e1788 Change to https 2019-04-13 01:22:08 +02:00
Jonas Kvinge
86f3e011d8 Add desktop-qt5 to snap 2019-04-13 01:11:22 +02:00
Jonas Kvinge
0367c5bd1c Fix snap build 2019-04-13 00:44:21 +02:00
Jonas Kvinge
eed008de4b Fix snap network access 2019-04-13 00:21:19 +02:00
Jonas Kvinge
74f713ee35 Fix alsa through snap 2019-04-12 23:27:01 +02:00
Jonas Kvinge
6dbb8751b2 Fix snap issues 2019-04-12 19:55:33 +02:00
Jonas Kvinge
368bb54870 Formatting 2019-04-12 19:55:19 +02:00
Jonas Kvinge
77903a5ecd Improve handling of song source 2019-04-08 23:00:07 +02:00
Jonas Kvinge
9be161d165 Fix code style and errors 2019-04-08 18:46:11 +02:00
Jonas Kvinge
0ce5b50950 Update gstreamer plugins in nsi 2019-04-07 23:32:41 +02:00
Jonas Kvinge
9dded5203e Improve RPM spec file 2019-04-06 19:56:14 +02:00
Jonas Kvinge
d1c2188e5c Change compiler flags 2019-04-05 23:09:00 +02:00
Jonas Kvinge
c4285a14b2 Use common rpm spec file 2019-04-05 23:07:16 +02:00
Jonas Kvinge
cf0a47e836 Ops 2019-04-04 20:17:28 +02:00
Jonas Kvinge
c38639afcb Dont send playing now in offline mode 2019-04-04 20:16:26 +02:00
Jonas Kvinge
5863593c65 Change description for offline mode scrobbling 2019-04-04 20:09:45 +02:00
Jonas Kvinge
c2fa7f9a57 Turn back git revision 2019-04-04 20:09:27 +02:00
Jonas Kvinge
41f5cf6bee Update snap/snapcraft.yaml 2019-04-02 18:46:34 +02:00
Jonas Kvinge
ea508e9c35 Update dist/scripts/maketarball.sh.in 2019-04-02 18:46:04 +02:00
Jonas Kvinge
5ebf7cd273 Release 0.5.3 2019-04-02 00:52:28 +02:00
Jonas Kvinge
9986088dc4 Update protobuf in nsi 2019-04-02 00:01:06 +02:00
Jonas Kvinge
bfe0b2c634 Add missing error check on login error 2019-04-01 23:03:36 +02:00
Jonas Kvinge
cd2af6974c Remove ignore for content not found 2019-04-01 22:54:10 +02:00
Jonas Kvinge
c452486573 Update libprotobuf in nsi 2019-03-31 03:43:37 +02:00
Jonas Kvinge
79406b20f2 Fix Tidal login handling 2019-03-31 03:41:25 +02:00
Jonas Kvinge
1226bc214d Update Changelog 2019-03-31 01:16:11 +01:00
Jonas Kvinge
7da79dabdf Add group by format 2019-03-30 22:03:33 +01:00
Jonas Kvinge
b51026a2ee Remove dot from filenames 2019-03-28 21:19:50 +01:00
Jonas Kvinge
67d01f48a3 Remove api seeds lyrics (requires payment) 2019-03-28 02:24:05 +01:00
Jonas Kvinge
9fd5c5fc1c Add Spanish 2019-03-28 01:45:04 +01:00
Jonas Kvinge
70bc5b83fa Replace swedish characters 2019-03-28 01:40:59 +01:00
Jonas Kvinge
b380db51fa Add lines to settings 2019-03-27 01:23:15 +01:00
Jonas Kvinge
fab598ebff Add some lines to scrobbler settings 2019-03-27 00:48:38 +01:00
Jonas Kvinge
6f6d087fa2 Remove mono playback setting and fix the layout abit 2019-03-27 00:44:03 +01:00
Jonas Kvinge
6e463d1de3 Remove broken mono playback setting 2019-03-27 00:31:47 +01:00
Jonas Kvinge
21970f3065 Fix gst leaks 2019-03-27 00:27:49 +01:00
Jonas Kvinge
9d7e44be2d Update Changelog 2019-03-25 23:35:33 +01:00
Jonas Kvinge
9085fb8285 Disable aspect ratio checkbox when stretch is not checked 2019-03-25 23:34:36 +01:00
Jonas Kvinge
dd79d089f6 Tweak the size a bit 2019-03-25 23:33:58 +01:00
Jonas Kvinge
7aaad124d0 Add more background image options 2019-03-25 22:00:40 +01:00
Jonas Kvinge
0025cb9f53 Add missing include 2019-03-25 19:52:46 +01:00
Jonas Kvinge
15c8f2a3ee Notify collection backend about renamed files when organising files 2019-03-25 00:53:12 +01:00
Jonas Kvinge
fc1a2dac90 Update 3rdparty/README.md 2019-03-24 19:28:55 +01:00
Jonas Kvinge
f698b860f7 Tidal: Handle login better and allow duplicate albums 2019-03-23 21:14:46 +01:00
Jonas Kvinge
86b057a301 Add Song::ExtensionForFiletype 2019-03-23 02:24:09 +01:00
Jonas Kvinge
b066158a4b Remove redundant includes 2019-03-22 23:23:50 +01:00
Jonas Kvinge
046c822604 Fix loading playlists correctly 2019-03-22 23:23:22 +01:00
Jonas Kvinge
d427733bfc Save and restore geometry in transcoder dialog 2019-03-22 23:22:23 +01:00
Jonas Kvinge
04d34a06c7 Improve Tidal error handling 2019-03-22 23:20:43 +01:00
Jonas Kvinge
69d86513ae Save/restore geometry in settings dialog 2019-03-22 23:19:24 +01:00
Jonas Kvinge
019b49a219 Add option to allow extended ascii characters, save/restore geometry 2019-03-22 23:18:14 +01:00
Jonas Kvinge
d9e787784a Fix Song::InitFromProtobuf not setting source, add function Song::SourceFromURL 2019-03-22 23:16:18 +01:00
Jonas Kvinge
71969b88e3 Fix GetSongByUrl incorrectly using bytearray instead of string 2019-03-22 23:14:25 +01:00
Jonas Kvinge
7ae0f5e246 Add better support for APE tags 2019-03-22 23:13:49 +01:00
Jonas Kvinge
1ea7da4bb5 Update taglib 2019-03-22 23:12:59 +01:00
Jonas Kvinge
8b96bb5f27 Fix formatting 2019-03-22 23:12:41 +01:00
Jonas Kvinge
aefce3ccd0 Remove unused mpris1 files 2019-03-22 23:12:24 +01:00
Jonas Kvinge
4e599e2aba Move icon loading to device model 2019-03-22 23:10:42 +01:00
Jonas Kvinge
4148c289af Fix copyright 2019-03-13 00:51:51 +01:00
Jonas Kvinge
d575ab0b2b Add basic support for system icons and custom icons 2019-03-13 00:43:46 +01:00
Jonas Kvinge
d09af19d3f Update mimetypes 2019-03-12 23:26:40 +01:00
Jonas Kvinge
a2dff17db9 Add CanPlay and CanPause 2019-03-12 23:10:31 +01:00
Jonas Kvinge
c0fecb935f Change mpris path 2019-03-12 01:00:30 +01:00
Jonas Kvinge
28249b7e99 Remove unused variable 2019-03-12 00:59:35 +01:00
Jonas Kvinge
eb63e2257f Fix load settings in albumcoverchoicecontroller 2019-03-12 00:01:52 +01:00
Jonas Kvinge
2211716d04 Add option to save album cover in album directory 2019-03-11 23:07:11 +01:00
Jonas Kvinge
242137a50c Only do QUrl toEncoded() if url is valid 2019-03-10 21:09:05 +01:00
Jonas Kvinge
c41311bf76 Disable macos build 2019-03-09 18:19:15 +01:00
Jonas Kvinge
e0d959e3c5 Add norwegian translations 2019-03-09 18:02:47 +01:00
Jonas Kvinge
f0a5c4b2c2 Enable translations 2019-03-09 18:02:17 +01:00
Jonas Kvinge
e10a50fdc1 Remove unused roles 2019-03-09 17:49:12 +01:00
Jonas Kvinge
380f2509ac Remove deezer 2019-03-09 17:43:20 +01:00
Jonas Kvinge
c0fb35f6b9 Add option to disable playing widget 2019-03-09 17:20:07 +01:00
Jonas Kvinge
3e658845d2 Add option to disable volume control 2019-03-09 16:48:45 +01:00
Jonas Kvinge
384209ba70 Fix UNC path in gst engine 2019-02-25 16:35:29 +01:00
Jonas Kvinge
835b589894 Fix untranslated text 2019-02-23 18:54:00 +01:00
Jonas Kvinge
76e684ee75 Add translations to macos builds (#84) 2019-02-23 04:20:28 +01:00
Jonas Kvinge
d0d2c83768 Ops 2019-02-23 04:18:45 +01:00
Jonas Kvinge
b476bc3168 Add translations to debian 2019-02-23 04:14:49 +01:00
Jonas Kvinge
5a2ad145e8 Add gettext and Qt5LinguistTools 2019-02-23 01:14:36 +01:00
Jonas Kvinge
27233d2549 Dont allow X11 shortcuts on wayland 2019-02-23 01:10:45 +01:00
Jonas Kvinge
1a0bc75629 Change pacman to use current git revision 2019-02-22 22:57:53 +01:00
Jonas Kvinge
dc04961699 Add update-desktop-files 2019-02-22 21:17:10 +01:00
Jonas Kvinge
e594cf299e Rename desktop and appdata files 2019-02-22 20:41:06 +01:00
Jonas Kvinge
096c995a91 Add src/core/potranslator.h 2019-02-22 20:38:23 +01:00
Jonas Kvinge
f64b175cd8 Fix .gitignore 2019-02-22 20:38:08 +01:00
Jonas Kvinge
954e0e8a59 Add translations support (#82)
* Add translations support
* Update .gitignore
2019-02-22 20:24:38 +01:00
Jonas Kvinge
034b032cfa Update .gitignore 2019-02-22 20:08:43 +01:00
Jonas Kvinge
e33590bff9 Show strawberry icon in OSD 2019-02-21 18:12:40 +01:00
Jonas Kvinge
55f610f3b2 Fix formatting 2019-02-20 21:29:14 +01:00
Jonas Kvinge
87fd93a1cf Show error when editing tags fails, update DB immediately when successful 2019-02-20 21:27:53 +01:00
Jonas Kvinge
2db77a248a Fix formatting 2019-02-20 21:27:04 +01:00
Jonas Kvinge
f600274592 Replace NULL with nullptr 2019-02-20 21:26:14 +01:00
Jonas Kvinge
bc37d00a81 Stop watcher when unmounting 2019-02-20 21:24:10 +01:00
Jonas Kvinge
1956ea95ee Use leap instead 2019-02-20 21:22:59 +01:00
Jonas Kvinge
a56e3b91e1 Change fade default and allow setting device back if custom device is
selected
2019-02-20 21:21:33 +01:00
Jonas Kvinge
6bcc9d61e1 Dont set keep running 2019-02-20 21:21:09 +01:00
Jonas Kvinge
3ef34191a3 Fix icon 2019-02-20 21:20:38 +01:00
Jonas Kvinge
60de36aff9 Remove whitespace 2019-02-20 21:15:58 +01:00
Jonas Kvinge
b019dd1c51 Update Dockerfile 2019-02-19 00:37:37 +01:00
Jonas Kvinge
3a083d5527 Update Dockerfile 2019-02-19 00:26:43 +01:00
Jonas Kvinge
8006241a81 Change Dockerfile 2019-02-19 00:14:20 +01:00
Jonas Kvinge
b05e3d24ee Change id 2019-02-18 22:58:10 +01:00
Jonas Kvinge
b78c0a4979 Remove unused includes 2019-02-13 20:12:20 +01:00
Jonas Kvinge
d3b3c309fa Create systray tooltip workaround for KDE 2019-02-13 20:04:05 +01:00
Jonas Kvinge
65615495d9 Remove debugging 2019-02-12 22:08:26 +01:00
Jonas Kvinge
35f448c34f Add artist search in internet view, and use album artist 2019-02-12 21:58:03 +01:00
Jonas Kvinge
e1abd28a88 Remove upload script 2019-02-10 23:14:49 +01:00
Jonas Kvinge
a109d8be64 Revert change to tooltip 2019-02-10 21:28:09 +01:00
Jonas Kvinge
333a0bc05a Capitalize strawberry in osd and tooltip, change cdcase and remove some
unused code
2019-02-10 21:25:36 +01:00
Jonas Kvinge
a831519b54 Remove unused file 2019-02-10 18:37:06 +01:00
Jonas Kvinge
a25052ed96 Replace no cover image 2019-02-09 14:51:12 +01:00
Jonas Kvinge
676f8dc8be Make it possible to use enter in shortcuts 2019-02-09 12:47:40 +01:00
Jonas Kvinge
9c3cb82fca Add compiler to macos img file (#73) 2019-02-04 23:42:07 +01:00
Jonas Kvinge
9b827f58ad Add files to exculde in maketarball 2019-02-04 23:30:08 +01:00
Jonas Kvinge
22e327d391 Remove TextSelectableByKeyboard 2019-02-04 22:34:22 +01:00
Jonas Kvinge
451de4d72d Add spaces to debian copyright 2019-02-04 22:32:53 +01:00
Jonas Kvinge
0679b78c1d Add boom and rainbow analyzers 2019-02-04 21:34:12 +01:00
Jonas Kvinge
ad7084b897 Make lyrics selectable 2019-02-04 19:07:05 +01:00
Jonas Kvinge
3c068eaba9 Remove support for older taglib in tagreader 2019-02-02 12:39:11 +01:00
Jonas Kvinge
819ae08c6a Change to default to albumartist in organise dialog 2019-02-02 00:31:26 +01:00
Jonas Kvinge
38414ad8de Add unity7 to snap 2019-01-31 20:43:26 +01:00
Jonas Kvinge
f0422f7634 Fix snap 2019-01-31 00:08:52 +01:00
Jonas Kvinge
2a004dadf3 Remove system-files from snap 2019-01-30 00:00:35 +01:00
Jonas Kvinge
b7ea586e44 Add snap 2019-01-29 22:44:07 +01:00
Jonas Kvinge
2a5f286d07 Update README.md 2019-01-28 23:46:33 +01:00
Jonas Kvinge
0bc14671ec Turn back git revision 2019-01-26 23:53:35 +01:00
Jonas Kvinge
1a8fe18b8e Release 0.5.2 2019-01-26 18:13:04 +01:00
Jonas Kvinge
4599b4a9cc Fix thanks to 2019-01-26 18:10:04 +01:00
Jonas Kvinge
6ab6ab56dd Fix define 2019-01-26 17:56:18 +01:00
Jonas Kvinge
59f5dc21ac Update Changelog 2019-01-26 17:45:52 +01:00
Jonas Kvinge
8f316db49c Add raise() to make sure window is on top 2019-01-26 17:44:05 +01:00
Jonas Kvinge
4c2f28311c Remove commented code 2019-01-26 17:33:47 +01:00
Jonas Kvinge
6ae022fbec Update Changelog 2019-01-26 17:31:05 +01:00
Jonas Kvinge
cfbb0f8fc0 Update copyright 2019-01-26 17:30:54 +01:00
Jonas Kvinge
3ad2c2ad6a Update copyright 2019-01-26 17:30:44 +01:00
Jonas Kvinge
1ce553fb65 Copy album covers to file system devices 2019-01-26 17:18:26 +01:00
Jonas Kvinge
ec5ec83edc Change transcoder output file and add missing suffix 2019-01-26 14:57:25 +01:00
Jonas Kvinge
18087fd797 Update Changlog 2019-01-25 23:46:13 +01:00
Jonas Kvinge
f90de75e3a Add warning when enabling X11 shortcuts on gnome, cinnamon and KDE 2019-01-25 21:36:28 +01:00
Jonas Kvinge
3241815a11 Remove core/tagreaderclient.h include 2019-01-24 20:29:22 +01:00
Jonas Kvinge
db3f8d3b83 Fix uninitialised variables 2019-01-24 20:22:05 +01:00
Jonas Kvinge
9983dc3138 Rename globalshortcuts GSD D-Bus backend to avoid confusion 2019-01-24 20:17:50 +01:00
Jonas Kvinge
ad141c165b Update imobiledevice 2019-01-24 19:43:52 +01:00
Jonas Kvinge
93b252b9e7 Update README.md 2019-01-24 19:42:04 +01:00
Jonas Kvinge
42e245e334 Update README.md 2019-01-24 19:41:21 +01:00
Jonas Kvinge
cb844084e8 Add log to organise error dialog 2019-01-24 19:20:10 +01:00
Jonas Kvinge
3483736490 Fix remove misc from album title 2019-01-24 19:18:23 +01:00
Jonas Kvinge
119a75588e Fix aac mp4 transcoder 2019-01-24 19:16:39 +01:00
Jonas Kvinge
2f42242305 Use vbr by default 2019-01-24 19:14:51 +01:00
Jonas Kvinge
4990f44b10 Save album cover to gpod devices 2019-01-24 19:13:57 +01:00
Jonas Kvinge
85eba24167 Add iLister and AFC device 2019-01-24 19:10:42 +01:00
Jonas Kvinge
ce4be75803 Fix itdb track type 2019-01-24 19:10:10 +01:00
Jonas Kvinge
706529248a Fix find_path check for X11 headers 2019-01-24 18:25:54 +01:00
Jonas Kvinge
79f50f5343 Remove compile warning when missing X11/XF86keysym.h 2019-01-24 18:25:24 +01:00
Jonas Kvinge
7437c208ff Remove remastered from album title 2019-01-22 22:49:48 +01:00
Jonas Kvinge
b838893e88 Remove libQt5Gui-private-headers-devel 2019-01-22 18:16:46 +01:00
Jonas Kvinge
41e2a75675 Add error handling for mtp and gpod device 2019-01-21 18:58:54 +01:00
Jonas Kvinge
ad5e366aad Use ItemToIndex and fix memory leaks in devices 2019-01-21 17:44:37 +01:00
Jonas Kvinge
b35c641df6 Add libgstlibav.so to macdeploy 2019-01-19 22:02:56 +01:00
Jonas Kvinge
22c476d507 Add libgstlame.so to macdeploy (#63) 2019-01-19 18:00:47 +01:00
Jonas Kvinge
8f9b1d708b Update .travis.yml (#62) 2019-01-19 00:55:03 +01:00
Jonas Kvinge
9ce8b60cd2 unset dirs 2019-01-18 01:00:07 +01:00
Jonas Kvinge
9401ad2ba3 Check for libsingleapplication too 2019-01-18 00:40:54 +01:00
Jonas Kvinge
128b6c7ce9 Update Changelog 2019-01-13 14:48:01 +01:00
Jonas Kvinge
04d509f6eb Also do secondary check as a core app 2019-01-13 14:46:22 +01:00
Jonas Kvinge
c91cef3507 Add error handling/message for url handler 2019-01-13 00:06:08 +01:00
Jonas Kvinge
a9304a840f Remove libQt5Gui-private-headers-devel 2019-01-12 17:55:02 +01:00
Jonas Kvinge
3ba500b589 Turn back git revision 2019-01-12 17:45:13 +01:00
Jonas Kvinge
cc6a1ad63b Release 0.5.1 2019-01-12 16:12:29 +01:00
Jonas Kvinge
a4120d3d3e Fix use system SingleApplication 2019-01-12 02:07:39 +01:00
Jonas Kvinge
494ab68dd2 Fix SingleCoreApplication 2019-01-12 02:06:26 +01:00
Jonas Kvinge
708dd12243 Update Changelog 2019-01-11 21:58:24 +01:00
Jonas Kvinge
49601423cf Fix scroll over icon to change track feature 2019-01-11 20:21:45 +01:00
Jonas Kvinge
928aebd439 Move check for secondary instance 2019-01-11 20:07:59 +01:00
Jonas Kvinge
97717929dd Update README.md 2019-01-11 01:11:45 +01:00
Jonas Kvinge
c94f9073f8 Add SingleCoreApplication 2019-01-11 01:04:13 +01:00
Jonas Kvinge
5746ee74cf Fix infinite loop in StyleSheetLoader 2019-01-10 20:07:17 +01:00
Jonas Kvinge
970dcaf0fd Adjust about dialog and make text selectable 2019-01-09 22:06:15 +01:00
Jonas Kvinge
87c2007352 Update Changelog 2019-01-09 21:32:32 +01:00
Jonas Kvinge
d53de00e2a Change default tab to FLAC 2019-01-09 20:11:30 +01:00
Jonas Kvinge
513aafca16 Disable fading when alsa device is selected 2019-01-09 20:02:40 +01:00
Jonas Kvinge
1d35923f0c Also disable shortcut options when x11 is disabled 2019-01-09 19:22:38 +01:00
Jonas Kvinge
4de61e79fb Fix background image 2019-01-09 18:24:45 +01:00
Jonas Kvinge
b2fe64ed34 Add warning if missing headers 2019-01-08 23:49:35 +01:00
Jonas Kvinge
411cb27ead Fix gnome d-dus shortcuts backend 2019-01-08 23:25:50 +01:00
Jonas Kvinge
696dc0051e Fix loading shortcuts settings 2019-01-08 23:25:01 +01:00
Jonas Kvinge
c0e1a9a359 Use VERSION_GREATER instead 2019-01-07 19:25:11 +01:00
Jonas Kvinge
b73f90c44d Try to fix build with older cmake 2019-01-07 19:10:41 +01:00
Jonas Kvinge
aeb7e3914e Allow compile with Qt 5.5 again 2019-01-07 19:04:53 +01:00
Jonas Kvinge
89e0524f90 Attempt to fix cmake error 2019-01-07 18:02:50 +01:00
Jonas Kvinge
bbc26a78f8 Add 3rdparty/taglib/README.md 2019-01-07 02:14:51 +01:00
Jonas Kvinge
74fb44abd3 Change to VERSION_GREATER_EQUAL 2019-01-07 02:12:32 +01:00
Jonas Kvinge
d692e4e5c6 Update README.md 2019-01-07 01:49:53 +01:00
Jonas Kvinge
5cf088c0de Add 3rdparty/README.md 2019-01-07 01:47:07 +01:00
Jonas Kvinge
f222048efe Replace QtSingleApplication with SingleApplication (#40) 2019-01-07 01:00:58 +01:00
Jonas Kvinge
21b2a694f0 Update Changelog 2019-01-06 21:39:23 +01:00
Jonas Kvinge
8e210d8e01 Fix this properly 2019-01-06 17:41:56 +01:00
Jonas Kvinge
7e9668584b Change default for collection to group by album artist 2019-01-06 17:26:05 +01:00
Jonas Kvinge
ffd16e5401 Enable organise without gstreamer 2019-01-06 16:48:23 +01:00
Jonas Kvinge
14cfd1a34e Re-enable transcoder and organiser, add transcoder for wavpack 2019-01-06 14:34:50 +01:00
Jonas Kvinge
a11f43520e Add support for Monkey's Audio 2019-01-06 00:32:58 +01:00
Jonas Kvinge
e4159dd7c2 Update Changelog 2019-01-06 00:32:32 +01:00
Jonas Kvinge
8738fa4137 Add create-dmg.sh to gitignore 2019-01-05 23:18:14 +01:00
Jonas Kvinge
9b7da3e071 Attempt to fix crashes in devices 2019-01-05 23:17:20 +01:00
Jonas Kvinge
a06de35aa5 Fix crashes in devices 2019-01-05 23:11:16 +01:00
Jonas Kvinge
d5fffc3641 Change outfile 2019-01-05 13:07:41 +01:00
Jonas Kvinge
a734ed8dfe Only upload file for master branch 2019-01-05 01:50:17 +01:00
Jonas Kvinge
9e12f8e3eb Fix permissions on ~/.ssh/id_rsa 2019-01-05 01:03:31 +01:00
Jonas Kvinge
600f297472 Fix git commands 2019-01-05 01:03:31 +01:00
Jonas Kvinge
92ee972e58 Fix rsync command 2019-01-05 01:03:31 +01:00
Jonas Kvinge
95a5c8a76a Fix macOS versioning 2019-01-05 01:03:31 +01:00
Jonas Kvinge
212d8e9278 Update .travis.yml 2019-01-05 01:03:31 +01:00
Jonas Kvinge
7f844cae63 Update .travis.yml 2019-01-04 01:23:25 +01:00
Jonas Kvinge
5034c92be9 Update .travis.yml 2019-01-04 01:23:06 +01:00
Jonas Kvinge
9378bac10e Add make dmg 2019-01-04 01:22:32 +01:00
Jonas Kvinge
b6db96b653 Fix macOS install 2019-01-04 01:13:03 +01:00
Jonas Kvinge
c271e05abc Use Q_OS_MACOS instead of Q_OS_DARWIN 2019-01-04 00:39:22 +01:00
Jonas Kvinge
de7154eda8 Deploy gst-plugin-scanner 2019-01-04 00:35:10 +01:00
Jonas Kvinge
030106986b Fix Utilities::SetEnv 2019-01-03 23:18:39 +01:00
Jonas Kvinge
32d33f03d7 Fix script 2019-01-03 23:18:39 +01:00
Jonas Kvinge
750a5e1147 Update .travis.yml 2019-01-03 23:18:39 +01:00
Jonas Kvinge
8dfcb353cb Update .travis.yml 2019-01-03 23:18:39 +01:00
Jonas Kvinge
9a2740dede Update .travis.yml 2019-01-03 23:18:39 +01:00
Jonas Kvinge
6d6874db37 +x 2019-01-03 23:18:39 +01:00
Jonas Kvinge
01c6b266e5 Update .travis.yml 2019-01-03 23:18:39 +01:00
Jonas Kvinge
d1445cb47e Update .travis.yml 2019-01-03 23:18:39 +01:00
Jonas Kvinge
5c44742a9b Add upload script 2019-01-03 23:18:39 +01:00
Jonas Kvinge
486eedc03e Update .travis.yml 2019-01-03 23:18:39 +01:00
Jonas Kvinge
7d8ba57e5f Fix bundle dir for macOS 2019-01-03 23:18:39 +01:00
Jonas Kvinge
ab827a91dc Remove prompt 2019-01-03 23:18:39 +01:00
Jonas Kvinge
e0bbcdb236 Update .travis.yml 2019-01-03 23:18:39 +01:00
Jonas Kvinge
3d4b6783ed Fix gst plugins 2019-01-03 23:18:39 +01:00
Jonas Kvinge
bb398b3275 Update .travis.yml 2019-01-03 23:18:39 +01:00
Jonas Kvinge
4d05bf034b Update .travis.yml 2019-01-03 23:18:39 +01:00
Jonas Kvinge
6594d90778 Change deployed plugins 2019-01-03 23:18:39 +01:00
Jonas Kvinge
ee3981b748 Fix dmg script 2019-01-03 23:18:39 +01:00
Jonas Kvinge
f57416d22b Update PKGBUILD 2019-01-03 02:49:08 +01:00
Jonas Kvinge
bcc103e572 Fix PKGBUILD 2019-01-03 02:44:52 +01:00
Jonas Kvinge
d398018633 Fix macos build 2019-01-02 00:32:36 +01:00
Jonas Kvinge
45c4be3ae9 Fix macos build 2019-01-01 22:35:23 +01:00
Jonas Kvinge
d93d72d538 Update Changelog 2019-01-01 22:22:31 +01:00
Jonas Kvinge
d3bcb38669 Fix macos build 2019-01-01 22:06:48 +01:00
Jonas Kvinge
7f19c43f4d Remove remaining qxt 2019-01-01 21:56:24 +01:00
Jonas Kvinge
98791015e5 Minor fixes to qtsingleapplication 2019-01-01 21:48:50 +01:00
Jonas Kvinge
213f08e171 Fix macos build 2019-01-01 21:40:36 +01:00
Jonas Kvinge
4641115314 Rename macos device finder 2019-01-01 20:22:19 +01:00
Jonas Kvinge
faee781042 Remove empty files 2019-01-01 20:15:01 +01:00
Jonas Kvinge
de4885d223 Fix globalshortcut status print 2019-01-01 20:11:46 +01:00
Jonas Kvinge
cef334c210 Add new global shortcut system backend for X11 and Windows
- Remove qxt
- Also create an option for enabled/disabling shortcuts through X11.
2019-01-01 20:07:29 +01:00
Jonas Kvinge
2a54cb17e7 Move organise files, add option to strip all non-fat characters 2018-12-29 15:37:16 +01:00
Jonas Kvinge
2e1b601508 Fix copyright header 2018-12-29 03:25:21 +01:00
Jonas Kvinge
719be46f9e Update Changelog 2018-12-29 03:21:40 +01:00
Jonas Kvinge
649c061ee1 Fix typo 2018-12-29 03:21:29 +01:00
Jonas Kvinge
1023a3da6f Fix some copyrights 2018-12-29 03:21:15 +01:00
Jonas Kvinge
404283be19 Convert devicemanager to QAbstractItemModel 2018-12-29 02:57:22 +01:00
Jonas Kvinge
fc9f93791d Remove Qt5::Xml dependency 2018-12-28 17:15:27 +01:00
Jonas Kvinge
55b0d1f24f Fix headers 2018-12-26 15:32:20 +01:00
Jonas Kvinge
d487351d5c Fix includes 2018-12-26 15:05:32 +01:00
Jonas Kvinge
e66fe78cbe Remove Disc from album name when scrobbling 2018-12-26 13:33:56 +01:00
Jonas Kvinge
ba38ccdbc6 Finish UpdateNowPlayingRequestFinished 2018-12-26 02:31:32 +01:00
Jonas Kvinge
a603e112e7 Fix error handling 2018-12-26 02:23:48 +01:00
Jonas Kvinge
99f154be70 Don't resubmit on single requests 2018-12-26 02:01:19 +01:00
Jonas Kvinge
1ea259f8e3 Do submit after successful login 2018-12-26 01:45:28 +01:00
Jonas Kvinge
8445f5587f Remove error output when no results are found 2018-12-26 01:28:25 +01:00
Jonas Kvinge
301ca055bd Fix submit and error handling 2018-12-26 01:17:17 +01:00
Jonas Kvinge
d9dc89f25c Fix scrobble status output for Last.fm 2018-12-25 23:58:55 +01:00
Jonas Kvinge
07cfdbbc25 Make Listenbrainz send playing now 2018-12-25 23:28:58 +01:00
Jonas Kvinge
b0c951cdd2 Fix initial submit value 2018-12-25 23:12:46 +01:00
Jonas Kvinge
bab01291b1 Make scrobble submit delay configurable 2018-12-25 22:58:34 +01:00
Jonas Kvinge
7c3f3da07d Fix min scrobble point 2018-12-25 22:58:11 +01:00
Jonas Kvinge
81d112928b Update descriptions 2018-12-24 01:11:47 +01:00
Jonas Kvinge
9c09f0ce82 Update message 2018-12-24 01:11:37 +01:00
Jonas Kvinge
a20a2dbb71 Ask before opening url, fix some typos 2018-12-24 00:15:53 +01:00
Jonas Kvinge
cbf262be71 Update Changelog 2018-12-23 19:29:54 +01:00
Jonas Kvinge
c58cfd407c Update Changelog 2018-12-23 19:28:52 +01:00
Jonas Kvinge
c5db43854b Update Changelog 2018-12-23 19:23:03 +01:00
Jonas Kvinge
52de8d0082 Fix key up causing playback to reset 2018-12-23 19:17:21 +01:00
Jonas Kvinge
dea810996f Change macOS spelling 2018-12-23 19:07:20 +01:00
Jonas Kvinge
f7af63c222 Add scrobbler icons 2018-12-23 19:04:54 +01:00
Jonas Kvinge
0d7e12e781 Add scrobbler with support for Last.fm, Libre.fm and ListenBrainz 2018-12-23 18:54:27 +01:00
Jonas Kvinge
517285085a Fix compile without gstreamer 2018-12-20 18:11:22 +01:00
Jonas Kvinge
ceb0f5ead4 Add new musicbrainz album cover provider 2018-12-15 15:12:18 +01:00
Jonas Kvinge
df5573f29a Merge branch 'master' of github.com:jonaski/strawberry 2018-12-15 02:18:28 +01:00
Jonas Kvinge
ce4e1b1ae4 Fix uninitialized variable 2018-12-15 02:16:47 +01:00
Jonas Kvinge
2114cc98bb Update Dockerfile 2018-12-15 02:13:39 +01:00
Jonas Kvinge
e38973ed4f Update Dockerfile 2018-12-15 01:09:14 +01:00
Jonas Kvinge
4f8aaa98f7 Update README.md 2018-12-15 00:56:25 +01:00
Jonas Kvinge
4148a310a2 Update debian copyright 2018-12-15 00:53:11 +01:00
Jonas Kvinge
35397f6a3e Fix includes 2018-12-15 00:52:58 +01:00
Jonas Kvinge
19168ec6e8 Remove remaining amazon cover provider files 2018-12-15 00:50:53 +01:00
Jonas Kvinge
2d087dfe15 Add new last.fm album cover provider 2018-12-15 00:43:50 +01:00
Jonas Kvinge
3226633f51 Add missing empty check 2018-12-15 00:43:00 +01:00
Jonas Kvinge
33d2e0f836 Replace 0 with nullptr 2018-12-15 00:41:22 +01:00
Jonas Kvinge
6ccf661678 Change windows setup filename 2018-12-13 23:43:15 +01:00
Jonas Kvinge
b5ba78def2 Add PKGBUILD to exclude 2018-12-13 23:31:13 +01:00
Jonas Kvinge
1706ba5765 Improve discogs cover provider 2018-12-02 23:29:22 +01:00
Jonas Kvinge
a8f13a4157 Remove sha2 from debian copyright 2018-12-02 19:18:26 +01:00
Jonas Kvinge
2d8f30c40a Replace sha2 with QCryptographicHash 2018-12-02 19:12:27 +01:00
Jonas Kvinge
d97d0fe359 Update debian copyright 2018-12-02 16:26:19 +01:00
Jonas Kvinge
1bae736284 Add debian copyright 2018-12-02 16:13:58 +01:00
Jonas Kvinge
017352b91e Add contributors to about 2018-12-02 16:12:10 +01:00
Jonas Kvinge
355afacaa1 Update URLs to https 2018-12-02 16:11:51 +01:00
Jonas Kvinge
fae79800c8 Fix spelling 2018-12-02 14:00:53 +01:00
Jonas Kvinge
db298ba5e2 Add new faded strawberry background image 2018-12-01 21:12:58 +01:00
Jonas Kvinge
06a20d43ce Add new faded strawberry background image 2018-12-01 20:52:16 +01:00
Thomas PIERSON
63f29235e4 Update and improve the manual pages. (#33) 2018-12-01 15:38:03 +01:00
Jonas Kvinge
9bb00d99f6 Turn back git revision 2018-11-29 19:51:11 +01:00
Jonas Kvinge
bcd29b9fd2 Release 0.4.2 2018-11-28 21:53:38 +01:00
Jonas Kvinge
046c221bc6 Change internet to streaming in settings and change order of settings 2018-11-28 17:53:37 +01:00
Jonas Kvinge
29a39b4e7f Attempt to fix devices issue 2018-11-28 17:45:50 +01:00
Jonas Kvinge
9fb3d06aac Change if statement in qtsingleapplication/CMakeLists.txt 2018-11-28 17:44:45 +01:00
Jonas Kvinge
142d5e2347 Update .travis.yml 2018-11-27 19:36:22 +01:00
Jonas Kvinge
58ea0bcbb0 Turn Deezer OFF by default if dependencies arent found 2018-11-27 19:33:30 +01:00
Jonas Kvinge
1c0bbe5d33 Fix endif in qxt CMakeLists.txt 2018-11-27 19:27:09 +01:00
Jonas Kvinge
8a7bba8ef3 Remove background image
Unsure about copyright issues using it, the image is from the Strawbs boxset, removing
it for now.
2018-11-27 19:20:33 +01:00
Jonas Kvinge
3b93963688 Code cleanup in qxtglobalshortcut 2018-11-27 19:14:35 +01:00
Jonas Kvinge
77e5d0288f Fix typo 2018-11-19 01:38:55 +01:00
Jonas Kvinge
460e78a1b8 Merge branch 'master' of github.com:jonaski/strawberry 2018-11-19 01:32:26 +01:00
Jonas Kvinge
fcbade267d Update changelog and about 2018-11-19 01:31:52 +01:00
Jonas Kvinge
41b99d9aa0 Update README.md 2018-11-19 01:12:32 +01:00
Jonas Kvinge
96c761dbb5 Update README.md 2018-11-19 01:09:51 +01:00
Jonas Kvinge
d297564236 Update README.md 2018-11-19 01:09:12 +01:00
Jonas Kvinge
bca1a98938 Add option to reset playlist columns 2018-11-19 00:18:48 +01:00
Jonas Kvinge
23205bef65 Playlist fixes
- Fix bug resetting playlist view columns to show all when using more than one
playlist.
- Add queue to play next
2018-11-18 23:21:12 +01:00
Jonas Kvinge
7613b2f526 Add alsa to optional_component 2018-11-17 16:28:05 +01:00
Jonas Kvinge
c5a521af1f Fix logging 2018-11-17 03:27:46 +01:00
Jonas Kvinge
f15c85e807 Remove SetThreadIOPriority, fixes poor performance on macos 2018-11-17 03:25:42 +01:00
Jonas Kvinge
6129ad1f4d Track slider fixes 2018-11-17 03:25:21 +01:00
Jonas Kvinge
9972dc192b Add include for QtGlobal 2018-11-17 03:24:20 +01:00
Jonas Kvinge
32b96a25e8 Remove dead code 2018-11-17 03:23:49 +01:00
Jonas Kvinge
9d09e7f6fe Remove dead code 2018-11-17 03:23:22 +01:00
Jonas Kvinge
5927483402 Remove qstyleoption_cast 2018-11-16 17:45:57 +01:00
Jonas Kvinge
f228f79a8a Fix macos code 2018-11-16 17:25:39 +01:00
Jonas Kvinge
072a3065cd Don't set paths for gst scanner and plugins on macos 2018-11-15 20:20:30 +01:00
Jonas Kvinge
718bd4c081 Replace NULL and 0 with nullptr 2018-11-14 00:43:19 +01:00
Jonas Kvinge
542cc0ec2f Remove unused code 2018-11-14 00:31:04 +01:00
Jonas Kvinge
b357634f51 Add pacman package files 2018-11-11 03:37:14 +01:00
Jonas Kvinge
6968c4d0fb Remove OpenGL from Dockerfile 2018-11-09 22:24:55 +01:00
Jonas Kvinge
e35d618133 Make Deezer engine use quality setting 2018-11-09 19:27:36 +01:00
Jonas Kvinge
4a23fde6bf Merge branch 'master' of github.com:jonaski/strawberry 2018-11-05 02:12:24 +01:00
Jonas Kvinge
1ae577641d Remove Qt5OpenGL from spec files and control file 2018-11-05 02:11:26 +01:00
Jonas Kvinge
686a3bb42b Update README.md 2018-11-05 01:21:37 +01:00
Jonas Kvinge
1771d41871 Fixes to makefiles
- Add a warning when using the systems taglib less or equal to version 1.11.1
- Remove OpenGL and Qt5::OpenGL dependency, it is not used by the analyzer
- Rename some variables
2018-11-05 01:14:56 +01:00
Jonas Kvinge
ee8f4ca7ab Add libqt5sql5-sqlite to debian control 2018-11-04 23:24:49 +01:00
Jonas Kvinge
4197a508a3 Remove obsolete xine warning and engine reinitialization 2018-11-04 21:23:34 +01:00
Jonas Kvinge
f38ffb505d Add Requires libQt5Sql5-sqlite to spec 2018-11-04 00:48:39 +01:00
Jonas Kvinge
679caf73d1 Fix strawberry.appdata.xml 2018-11-03 16:30:53 +01:00
Jonas Kvinge
56d25c346c Update appdata file to new AppStream specification 2018-11-03 15:57:45 +01:00
Jonas Kvinge
6ba26ba289 Change fedora rpm suffix 2018-11-02 21:30:07 +01:00
Jonas Kvinge
27582b7a4e Add strawberry.appdata.xml to spec files 2018-11-02 20:30:12 +01:00
Jonas Kvinge
2f4417d683 Fix files to delete on uninstall in nsi 2018-11-01 22:22:39 +01:00
Jonas Kvinge
de97d29a82 Turn back git revision 2018-11-01 22:22:30 +01:00
Jonas Kvinge
b782a2c8a2 Release 0.4.1 2018-11-01 21:18:57 +01:00
Jonas Kvinge
298783e2c5 Attempt to login if streamurl fails 2018-11-01 21:18:09 +01:00
Jonas Kvinge
bc9ec8025c Move some settings 2018-10-31 19:44:24 +01:00
Jonas Kvinge
26459763e5 Only set QtDebugMsg when build type is debug 2018-10-31 19:41:52 +01:00
Jonas Kvinge
1213306657 Update libcdio 2018-10-31 01:30:15 +01:00
Jonas Kvinge
50add12e4b Update changelog 2018-10-30 23:47:51 +01:00
Jonas Kvinge
67c889f982 Improve Xine engine code 2018-10-30 23:40:41 +01:00
Jonas Kvinge
08cba25071 Improve VLC error handling 2018-10-30 23:40:05 +01:00
Jonas Kvinge
ff35b01bac Improve gst engine error handling 2018-10-30 23:39:08 +01:00
Jonas Kvinge
faee1977fe Add better error handling between engine and player 2018-10-30 23:21:51 +01:00
Jonas Kvinge
6105b99a7f Add option to continue to next song in playlist on error
Also rename some settings. Add option to grey out songs both on playback and
on startup.
2018-10-30 23:20:02 +01:00
Jonas Kvinge
4993201b70 Fix deezer url handler 2018-10-30 23:18:25 +01:00
Jonas Kvinge
f456ca674d Update taglib 2018-10-27 12:15:52 +02:00
Jonas Kvinge
2ba350f76f Attempt to fix crash in setStyleSheet() 2018-10-26 20:05:37 +02:00
Jonas Kvinge
3fe92a62ac Add DSF and DSDIFF to IsFileLossless 2018-10-24 00:58:03 +02:00
Jonas Kvinge
f4dcf6821f Rename class InternetModel to InternetServices 2018-10-23 23:25:02 +02:00
Jonas Kvinge
0c10013858 Ops 2018-10-23 21:14:58 +02:00
Jonas Kvinge
3e9530fa8d Set metadata from deezer engine 2018-10-23 20:21:33 +02:00
Jonas Kvinge
0f4ffe4fce Add PCM as filetype 2018-10-23 20:21:01 +02:00
Jonas Kvinge
e1c01e5d25 Fix device selection 2018-10-23 20:18:07 +02:00
Jonas Kvinge
51021131d7 Allow compile on Qt 5.5.1 or above 2018-10-23 20:17:29 +02:00
Jonas Kvinge
89a08d1d5e Fix RPM build 2018-10-22 23:23:25 +02:00
Jonas Kvinge
ba8717f95a Fix Deezer engine error state 2018-10-22 23:04:34 +02:00
Jonas Kvinge
c8dfb9b0db Fix loading custom device 2018-10-22 22:10:27 +02:00
Jonas Kvinge
3a02ece169 Add EnsureInitialised() 2018-10-22 20:40:02 +02:00
Jonas Kvinge
262df6b461 Merge pull request #24 from eclipseo/use_qt5_deps
Use qt5 libraries of system-wide libraries
2018-10-22 19:00:07 +02:00
Jonas Kvinge
b9516fdfd4 Merge pull request #23 from eclipseo/add_appdata_file
Add AppStream data file
2018-10-22 18:49:28 +02:00
Robert-André Mauchin
9de41bc027 Use qt5 version of system-wide libraries 2018-10-22 17:45:47 +02:00
Robert-André Mauchin
53b5cf3855 Add AppStream data file 2018-10-22 16:44:35 +02:00
Jonas Kvinge
0567358783 Update README.md 2018-10-21 20:49:35 +02:00
Jonas Kvinge
c97bc55c6f Move queuemanager to fancytabbar 2018-10-21 15:13:48 +02:00
Jonas Kvinge
3ef0bf60d0 Correct text for right click configure 2018-10-20 22:33:23 +02:00
Jonas Kvinge
b7b8084a38 Remove setExpanding 2018-10-20 22:18:56 +02:00
Jonas Kvinge
5221f13498 Minor code cleanup and fixes 2018-10-20 22:16:22 +02:00
Jonas Kvinge
0c0a8d70f3 Change darwin to macos 2018-10-20 22:15:32 +02:00
Jonas Kvinge
2ff971878d Enable debug logging on Fedora 2018-10-20 22:13:51 +02:00
Jonas Kvinge
1a0dc1e614 Update README 2018-10-20 22:13:21 +02:00
Jonas Kvinge
4a0bd99654 Enable deezer engine by default 2018-10-20 22:13:02 +02:00
Jonas Kvinge
5cb98e44cb Update README 2018-10-19 20:42:58 +02:00
Jonas Kvinge
13ed99b9c3 Update README and Changelog 2018-10-19 20:37:42 +02:00
Jonas Kvinge
0cda4e27aa Replace qSort/qStableSort/qSwap 2018-10-19 20:18:46 +02:00
Jonas Kvinge
0969e7f504 Remove cachedlist.h 2018-10-19 19:38:30 +02:00
Jonas Kvinge
cad73e18e2 Remove unused code 2018-10-19 19:20:29 +02:00
Jonas Kvinge
9eadeddfd9 Fixup and finish deezer engine 2018-10-19 19:15:33 +02:00
Jonas Kvinge
de11cb173b Use previews as default setting if deezer engine and dzmedia is missing 2018-10-19 19:14:49 +02:00
Jonas Kvinge
5853bc68d1 Replace depreciated macro 2018-10-19 19:13:40 +02:00
Jonas Kvinge
7d1fd9d46f Add missing names 2018-10-19 19:13:24 +02:00
Jonas Kvinge
c977c822d5 Add info about Deezer 2018-10-19 19:13:01 +02:00
Jonas Kvinge
c05fb33ea2 Replace FancyTabWidget with improved version 2018-10-19 19:10:22 +02:00
Jonas Kvinge
b9d0b3e152 Add option to diable Tidal and Deezer 2018-10-17 23:49:02 +02:00
Jonas Kvinge
a9e905b301 Fix bug not loading engine 2018-10-17 22:55:36 +02:00
Jonas Kvinge
a8a714c820 Use common classes for Tidal and Deezer 2018-10-17 21:18:39 +02:00
Jonas Kvinge
9349ad9383 Fix missing icon 2018-10-17 00:46:08 +02:00
Jonas Kvinge
f686f00951 Fix missing icon 2018-10-17 00:43:05 +02:00
Jonas Kvinge
3d13c12cb7 Update taglib 2018-10-16 23:58:26 +02:00
Jonas Kvinge
2384a42d33 Update .gitignore 2018-10-16 21:37:27 +02:00
Jonas Kvinge
f507fec905 Update Changelog 2018-10-16 21:32:03 +02:00
Jonas Kvinge
83a9724d17 Improve Tidal code 2018-10-16 21:31:28 +02:00
Jonas Kvinge
4156e26f76 Fix some minor code bugs in deezer 2018-10-16 21:30:27 +02:00
Jonas Kvinge
6d269e1786 Add libdeezer dll to windows nsi 2018-10-16 21:29:40 +02:00
Jonas Kvinge
ea447cab37 Remove quotes 2018-10-16 21:29:21 +02:00
Jonas Kvinge
4f3e7de441 Exclude debian changelog 2018-10-16 21:29:00 +02:00
Jonas Kvinge
0a81fa99fc Add Deezer support 2018-10-14 00:08:33 +02:00
Jonas Kvinge
4aad44cb62 Create timer for login attempts for Tidal 2018-10-13 00:30:52 +02:00
Jonas Kvinge
69dda39d02 Create timer for login attempts for Tidal 2018-10-13 00:18:38 +02:00
Jonas Kvinge
ca3ba6f136 Increase kTrackSliderUpdateTimeMs 2018-10-02 01:01:31 +02:00
Jonas Kvinge
044cf4624a Add hide() 2018-10-02 00:58:46 +02:00
Jonas Kvinge
1fbfabdf66 Remove whitespaces 2018-10-02 00:46:54 +02:00
Jonas Kvinge
db035351be Remove whitespaces 2018-10-02 00:38:52 +02:00
Jonas Kvinge
2883ef840e Fix track stop on error 2018-10-02 00:21:50 +02:00
Jonas Kvinge
8254ee911d Fix default setting for system tray 2018-10-01 00:31:02 +02:00
Jonas Kvinge
560bc0a150 Fix default setting for system tray 2018-10-01 00:29:06 +02:00
Jonas Kvinge
827898cd38 Fix taglib includes 2018-09-30 22:32:56 +02:00
Jonas Kvinge
184dec146c Move resume playback outside of startup group 2018-09-30 15:55:02 +02:00
Jonas Kvinge
298dbe96c8 Check if system has system tray using QSystemTrayIcon::isSystemTrayAvailable() 2018-09-30 15:33:27 +02:00
Jonas Kvinge
6d888eb51a Analyzer code cleanup and try to fix crash on Fedora 2018-09-30 15:32:21 +02:00
Jonas Kvinge
3694765611 Add error handling for enabling FTS3 2018-09-30 14:54:14 +02:00
Jonas Kvinge
b07ae3d34e Remove reset 2018-09-30 00:08:09 +02:00
Jonas Kvinge
64bcdf4734 Fix spelling 2018-09-30 00:07:59 +02:00
Jonas Kvinge
1c23756fc4 Turn on git revision 2018-09-30 00:07:05 +02:00
Jonas Kvinge
50e3eeaafd Release 0.3.3 2018-09-24 19:13:45 +02:00
Jonas Kvinge
843f528ebc Revert change to Tidal login using clientUniqueKey 2018-09-24 19:10:49 +02:00
Jonas Kvinge
faa0076988 Turn back git revision 2018-09-24 19:10:15 +02:00
Jonas Kvinge
59622c52ad Release 0.3.2 2018-09-24 18:42:21 +02:00
Jonas Kvinge
a8e9aba58b Save password as QString 2018-09-24 18:40:05 +02:00
Jonas Kvinge
36563cd1e1 Fix compile 2018-09-22 23:32:11 +02:00
Jonas Kvinge
072e712f0d Add missing QUrl include 2018-09-22 23:30:19 +02:00
Jonas Kvinge
121a186160 Improve contextview and engine code 2018-09-22 23:13:56 +02:00
Jonas Kvinge
15a2ccc21e Change size of comboxes in device settings 2018-09-22 15:54:38 +02:00
Jonas Kvinge
dbd8ea69eb Turn off debug about in Tidal 2018-09-22 15:39:24 +02:00
Jonas Kvinge
8a57356f64 More Tidal fixes 2018-09-22 15:37:42 +02:00
Jonas Kvinge
c77cb002f3 Add support for both ALSA hw and plughw 2018-09-21 23:29:00 +02:00
Jonas Kvinge
aa83a2b40b Add option to change url stream scheme for Tidal 2018-09-21 18:53:27 +02:00
Jonas Kvinge
65b04cac6e Update changelog 2018-09-21 01:20:16 +02:00
Jonas Kvinge
5e577190a8 Fix some copyrights 2018-09-21 01:12:21 +02:00
Jonas Kvinge
0143617056 Fix bug setting wrong temp metadata and bug in pipeline 2018-09-21 00:34:02 +02:00
Jonas Kvinge
a77dde7d3b Fix some includes 2018-09-20 22:48:52 +02:00
Jonas Kvinge
7dcdb7c673 Might be a good idea to actually add the URL Handler :) 2018-09-20 22:37:38 +02:00
Jonas Kvinge
6de8eb56cd Remove dead code in Tidal 2018-09-20 22:29:35 +02:00
Jonas Kvinge
04e272d9bc Fix mistake 2018-09-20 22:22:48 +02:00
Jonas Kvinge
17fe201473 Use URL Handler for Tidal 2018-09-20 22:13:30 +02:00
Jonas Kvinge
25249be37f Change orange to red 2018-09-20 17:44:31 +02:00
Jonas Kvinge
97ec12b5b3 Don't compile devices on windows 2018-09-20 17:36:23 +02:00
Jonas Kvinge
246f82bfad Replace obsolete QStyleOptionViewItemV2-4 2018-09-18 22:17:28 +02:00
Jonas Kvinge
db5679bbe9 Fix lsb-release command 2018-09-18 19:01:59 +02:00
Jonas Kvinge
feb0e1c45b Fix Fedora RPM suffix 2018-09-18 18:43:04 +02:00
Jonas Kvinge
edba837295 Fix RPM Suffix 2018-09-18 17:28:49 +02:00
Jonas Kvinge
55882360ef Fix RPM suffix 2018-09-18 00:45:33 +02:00
Jonas Kvinge
6039370ad6 Fix exclude 2018-09-18 00:45:07 +02:00
Jonas Kvinge
2d238c08d3 Change output filename 2018-09-18 00:31:21 +02:00
Jonas Kvinge
9b337b6a34 Add missing nsi 2018-09-17 19:30:23 +02:00
Jonas Kvinge
370db791aa Add nsi files for x86_64-w64-mingw32 2018-09-17 01:02:48 +02:00
Jonas Kvinge
9e3c547580 Turn back on git revision 2018-09-16 23:13:30 +02:00
Jonas Kvinge
ab5d9b62b8 Fix search error not shown in Tidal search 2018-09-15 22:34:44 +02:00
Jonas Kvinge
8e35e0c476 Release 0.3.1 2018-09-15 19:22:55 +02:00
Jonas Kvinge
9d9492b528 Update README.md 2018-09-15 13:46:29 +02:00
Jonas Kvinge
9732cc2ce2 Update README.md 2018-09-15 13:45:26 +02:00
Jonas Kvinge
a4beea3f34 Update README.md 2018-09-15 13:43:33 +02:00
Jonas Kvinge
c9256c52bf Check for QT version 2018-09-15 13:35:03 +02:00
Jonas Kvinge
6563bec7e4 Remove builtin qtwin and use WinExtras, replace some macros 2018-09-15 13:07:51 +02:00
Jonas Kvinge
072facdf7b Update features 2018-09-15 00:22:10 +02:00
Jonas Kvinge
a0f07a7a67 Update about 2018-09-14 23:58:58 +02:00
Jonas Kvinge
1a7465ba94 Formatting and remove unused icons 2018-09-14 23:05:58 +02:00
Jonas Kvinge
be3862ec40 Add missing signal 2018-09-12 22:55:53 +02:00
Jonas Kvinge
a5276a3b7e Merge branch 'master' of github.com:jonaski/strawberry 2018-09-12 22:52:09 +02:00
Jonas Kvinge
fc8a27f55b Fix some compiler warnings 2018-09-12 22:51:10 +02:00
Jonas Kvinge
87718bee24 Update .travis.yml 2018-09-12 22:15:19 +02:00
Jonas Kvinge
56f2e00990 Update .travis.yml 2018-09-12 22:14:37 +02:00
Jonas Kvinge
27e3448dda Merge branch 'master' of github.com:jonaski/strawberry 2018-09-12 21:52:52 +02:00
Jonas Kvinge
9404e40cad Fix song.h 2018-09-12 21:52:30 +02:00
Jonas Kvinge
982f399aff Update .travis.yml 2018-09-12 21:17:45 +02:00
Jonas Kvinge
6d373737db Update .travis.yml 2018-09-12 21:09:00 +02:00
Jonas Kvinge
7f9e196234 Update .travis.yml 2018-09-12 20:56:51 +02:00
Jonas Kvinge
95d03de160 Update .travis.yml 2018-09-12 20:12:34 +02:00
Jonas Kvinge
d43190a41f Update .travis.yml 2018-09-12 19:45:46 +02:00
Jonas Kvinge
b5c0529969 Update .travis.yml 2018-09-12 19:42:04 +02:00
Jonas Kvinge
621a5b1de8 Update Dockerfile 2018-09-12 19:32:13 +02:00
Jonas Kvinge
e30f269412 Update .travis.yml 2018-09-11 23:32:19 +02:00
Jonas Kvinge
494ac20cca Create Dockerfile 2018-09-11 23:13:58 +02:00
Jonas Kvinge
bf997a6d2e Don't show error when there was no match from API Seeds 2018-09-11 00:38:06 +02:00
Jonas Kvinge
bc0c0b7950 Extract error from Json data in API Seeds 2018-09-11 00:20:24 +02:00
Jonas Kvinge
f202cf6988 Don't use lyrics from AudD if title and artist don't match 2018-09-11 00:01:17 +02:00
Jonas Kvinge
e62fb964ff Improve lyrics providers 2018-09-10 23:46:01 +02:00
Jonas Kvinge
9014781336 Fix Tidal authentication 2018-09-10 22:22:00 +02:00
Jonas Kvinge
e479e7e113 Fix show album cover from Tidal 2018-09-10 21:58:57 +02:00
Jonas Kvinge
f9379961e9 Fix Tidal authentication 2018-09-10 21:23:50 +02:00
Jonas Kvinge
e5e6cbf6e4 Hide samplerate, bitdepth and bitrate when not set 2018-09-08 13:25:40 +02:00
Jonas Kvinge
6d686ee66a Add source to songs and playlist_items 2018-09-08 12:38:02 +02:00
Jonas Kvinge
19b645d731 Show filetype for Tidal 2018-09-06 22:34:18 +02:00
Jonas Kvinge
28c685dcd8 Ops I did it again... 2018-09-06 20:51:14 +02:00
Jonas Kvinge
0abeefd470 Fixed saving (APE) tags for WavPack files 2018-09-06 20:49:05 +02:00
Jonas Kvinge
1562585561 Added support for reading lyrics from tags
Also fixed tagreader crash when saving tags to MP3 files
2018-09-06 20:04:29 +02:00
Jonas Kvinge
0a64a2a394 Finish Tidal
- Add configurable settings
- Add progressbar
- Simplify code
2018-09-06 17:39:26 +02:00
Jonas Kvinge
440a223bfb Fix saving search_for_cover_auto 2018-09-06 17:37:50 +02:00
Jonas Kvinge
36b0a22c79 Fix saving above_status_bar 2018-09-06 17:37:03 +02:00
Jonas Kvinge
032022c246 Add "Show above status bar" as an option 2018-09-05 19:03:21 +02:00
Jonas Kvinge
9e4f3f9867 Fix qocoa mac build 2018-09-05 18:15:28 +02:00
Jonas Kvinge
1119c87b2f Fix clear search box 2018-09-04 22:55:38 +02:00
Jonas Kvinge
36ab26c49a Fix automatic album cover fetching
- Moved Album Choice Controller to mainwindow to use common for both
PlayingWidget and ContextView.
- Fixed a bug I created that caused fetching album covers in a loop
2018-09-04 21:43:44 +02:00
Jonas Kvinge
460cddb3dc Add ResetWarning() to make sure label is hidden 2018-09-04 20:52:47 +02:00
Jonas Kvinge
a5c2dfacf0 Don't use discogs for automatic album cover search 2018-09-04 20:51:47 +02:00
Jonas Kvinge
b9788ef4b5 Update .travis.yml 2018-09-02 23:49:28 +02:00
Jonas Kvinge
4a124e596e Update .travis.yml 2018-09-02 17:04:58 +02:00
Jonas Kvinge
994a400ac9 Update nsi files 2018-09-02 16:20:48 +02:00
Jonas Kvinge
d08e6a1dca Remove libmpcdec-5.dll 2018-09-02 16:00:48 +02:00
Jonas Kvinge
154136185b Remove libxine from nsi file 2018-09-02 12:56:31 +02:00
Jonas Kvinge
f86b10c71f Add bold to albums by label 2018-09-02 12:50:28 +02:00
Jonas Kvinge
0b3d84a65e Update changelog 2018-09-02 12:50:12 +02:00
Jonas Kvinge
ee78b6f2bb Add DSF and DSDIFF/DFF support 2018-09-02 01:40:14 +02:00
Jonas Kvinge
521d5cf4fa Add DSF and DSDIFF support to taglib 2018-09-02 01:39:02 +02:00
Jonas Kvinge
52cf4412c8 Update changelog 2018-09-01 22:22:12 +02:00
Jonas Kvinge
dcae67ac7b Change search limit 2018-09-01 22:21:45 +02:00
Jonas Kvinge
cd0ee282c6 Add dist/windows/strawberry-debug.nsi.in to cmake 2018-09-01 22:14:59 +02:00
Jonas Kvinge
9d7e5864de Merge branch 'master' of github.com:jonaski/strawberry 2018-09-01 22:00:44 +02:00
Jonas Kvinge
d426eb2e07 Add seperate nsi file for debug 2018-09-01 22:00:06 +02:00
Jonas Kvinge
06bed7feb7 Update README.md 2018-08-29 23:26:14 +02:00
Jonas Kvinge
adc38c4b12 Disable Amazon cover provider (API key revoked) 2018-08-29 22:27:26 +02:00
Jonas Kvinge
5af58c19ae Remove some unused variables 2018-08-29 22:17:23 +02:00
Jonas Kvinge
ac6cac8da1 New context with albums and lyrics +++ much more
* Added new lyrics provider with lyrics from AudD and API Seeds
* New improved context widget with albums and lyrics
* Fixed playing and context widget getting stuck in play mode when there was an error
* Changed icons for artists in collection, tidal and cover manager
* Removed "search" icon from "Search automatically" checkbox (right click) that looked ugly
* Removed some unused widgets from the src/widgets directory
* Fixed initial size of window and side panel
* Fixed saving window size correctly
2018-08-29 21:42:24 +02:00
Jonas Kvinge
3b30e66e87 Fix DB schema 2018-08-15 01:28:37 +02:00
Jonas Kvinge
41b0b1efd4 Remove broken xine fader until it's properly fixed 2018-08-12 15:05:34 +02:00
Jonas Kvinge
099d098dc7 Remove install log 2018-08-10 22:01:59 +02:00
Jonas Kvinge
1a55b7f1b2 Add DLL's required for Tidal to windows installer 2018-08-09 23:31:24 +02:00
Jonas Kvinge
f5ba8da3c7 Remove info frame from DeviceViewContainer
Was broken and caused yellow background on windows
2018-08-09 22:30:18 +02:00
Jonas Kvinge
08fcedd925 Rename some UI stuff 2018-08-09 21:49:18 +02:00
Jonas Kvinge
57f6f40e7d Fix missing icons and rework some UI stuff 2018-08-09 21:04:30 +02:00
Jonas Kvinge
4ca99dde43 Remove bak file 2018-08-09 18:41:43 +02:00
Jonas Kvinge
c518e42e18 Remove whitespace 2018-08-09 18:39:44 +02:00
Jonas Kvinge
0c329e6d83 Update README.md 2018-08-09 18:21:57 +02:00
Jonas Kvinge
820124f9e1 Add tidal support 2018-08-09 18:10:03 +02:00
Jonas Kvinge
26062bd07b Remove unneeded include 2018-07-28 00:16:56 +02:00
Jonas Kvinge
73029ab7a2 Remove dead analyzer code from VLC engine 2018-07-28 00:09:39 +02:00
Jonas Kvinge
c3e916d945 Add some missing e-mails in about 2018-07-20 02:28:42 +02:00
Jonas Kvinge
6ee9f9d1ad Add some missing names to about 2018-07-20 02:07:47 +02:00
Jonas Kvinge
b2c26eb4ed Make chromaprint optional 2018-07-16 07:23:37 +02:00
Jonas Kvinge
e181b47e3f Add 'make deb' 2018-07-16 02:57:57 +02:00
Jonas Kvinge
dc91f19f30 Just use PkgConfig to find dbus
- dbus was not found on debian based distros, because they had the library in a different location
- Not sure why I added the find package cmake file in the first place, will fix it and readd it if this causes problems
2018-07-16 01:20:29 +02:00
Jonas Kvinge
e260fc5057 Add check for qpa/qplatformnativeinterface.h in qxt 2018-07-16 01:18:58 +02:00
Jonas Kvinge
2368fff243 Fix mistake 2018-07-12 17:17:20 +02:00
Jonas Kvinge
70db0a33d1 Add debian package 2018-07-12 17:10:38 +02:00
Jonas Kvinge
56f47909f4 Fix Fedora build 2018-07-12 01:51:31 +02:00
Jonas Kvinge
e22b47a9d1 Revert git version off for Windows 2018-07-12 00:18:55 +02:00
Jonas Kvinge
e32ed02a24 Fix RPM build 2018-07-12 00:07:29 +02:00
Jonas Kvinge
eb5d72a940 Fix build with cmake with < 3.1 2018-07-11 17:23:44 +02:00
Jonas Kvinge
cbd809621a Update README.md 2018-07-08 19:50:16 +02:00
Jonas Kvinge
ad5d5d0ecd Correct Qt 5 dependencies 2018-07-06 21:56:13 +02:00
Jonas Kvinge
6bc948453c Update README.md 2018-07-05 19:47:18 +02:00
Jonas Kvinge
803590daa8 Fix Travis-CI build 2018-07-05 19:11:47 +02:00
Jonas Kvinge
c63399ee98 Update .travis.yml 2018-07-05 18:56:14 +02:00
Jonas Kvinge
f5ff95dca4 Update .travis.yml 2018-07-05 18:44:46 +02:00
Jonas Kvinge
998357c0bb Update .travis.yml 2018-07-05 18:33:50 +02:00
Jonas Kvinge
b43331bc3c Update .travis.yml 2018-07-05 18:17:36 +02:00
Jonas Kvinge
ecfeb17869 Update .travis.yml 2018-07-05 18:08:18 +02:00
Jonas Kvinge
9d2c9c732e Update .travis.yml 2018-07-05 18:02:24 +02:00
Jonas Kvinge
6478fadedc Update .travis.yml 2018-07-05 17:58:53 +02:00
Jonas Kvinge
a62eaa919d Update README.md 2018-07-05 17:56:25 +02:00
Jonas Kvinge
328a86288c Update .travis.yml 2018-07-05 17:52:32 +02:00
Jonas Kvinge
f1902a5b63 Update .travis.yml 2018-07-05 17:42:16 +02:00
Jonas Kvinge
693bade5a6 Update .travis.yml 2018-07-05 17:34:58 +02:00
Jonas Kvinge
ca2acb177a Create .travis.yml 2018-07-05 17:18:49 +02:00
Jonas Kvinge
670cd4e081 Remove unused variable 2018-07-05 03:28:32 +02:00
Jonas Kvinge
3a228c42bb Release 0.2.1 2018-07-05 02:55:51 +02:00
Jonas Kvinge
73fd87f8aa Update README.md 2018-07-04 14:25:36 +02:00
Jonas Kvinge
3adc1b55fa Update dist/windows/strawberry.nsi 2018-07-04 14:20:02 +02:00
Jonas Kvinge
0fd31f3632 Turn off git revision for windows build 2018-07-04 03:10:27 +02:00
Jonas Kvinge
55e0255fc2 Update windows/strawberry.nsi 2018-07-04 02:53:27 +02:00
Jonas Kvinge
8d23f6c422 Update dist/windows/strawberry.nsi 2018-07-04 01:57:22 +02:00
Jonas Kvinge
8aebfdc88c Fix dbus compile in osd widget 2018-07-04 00:55:09 +02:00
Jonas Kvinge
a554032823 Fix compile without dbus 2018-07-03 21:21:33 +02:00
Jonas Kvinge
c818ce19e9 Show engine switch warning only if more than 1 2018-07-03 20:36:38 +02:00
Jonas Kvinge
602f9759bb Fix dbus compile without X11 2018-07-03 20:32:28 +02:00
Jonas Kvinge
a00b8b2dca Use HAVE_DBUS instead of QT_DBUS_LIB 2018-07-03 19:48:08 +02:00
Jonas Kvinge
6dccc8857b Cleanup linking of QT components 2018-07-03 19:33:09 +02:00
Jonas Kvinge
b0f86a38ca Replace fromAscii() with fromLatin1() 2018-07-03 19:31:49 +02:00
Jonas Kvinge
1e4088b3e5 Make macdevicelister compile 2018-07-03 19:30:54 +02:00
Jonas Kvinge
3c5da3c8bd Update spec file 2018-07-03 18:55:25 +02:00
Jonas Kvinge
8e9bf2653a Update README.md 2018-07-03 18:24:34 +02:00
Jonas Kvinge
0d6f377664 Update README.md 2018-07-03 18:23:05 +02:00
Jonas Kvinge
d30a63f79b Fix variable 2018-07-03 17:56:13 +02:00
Jonas Kvinge
ab3569a285 More macos fixes 2018-07-03 17:51:52 +02:00
Jonas Kvinge
efdaf57f99 Bummer 2018-07-01 22:35:09 +02:00
Jonas Kvinge
ada7325a04 Fix macos build 2018-07-01 22:26:46 +02:00
Jonas Kvinge
c4e75dea65 Fix macos build 2018-07-01 22:24:23 +02:00
Jonas Kvinge
41ce19ab97 Correct spelling 2018-07-01 15:35:34 +02:00
Jonas Kvinge
3894419b14 More engine fixes 2018-07-01 15:30:53 +02:00
Jonas Kvinge
af03c05559 Make cmake fail if git revision cant be set. 2018-07-01 15:29:35 +02:00
Jonas Kvinge
04f1d296ea More engine fixes 2018-07-01 01:29:52 +02:00
Jonas Kvinge
67df8f2243 Hide warning groupbox in backend settings 2018-06-29 00:57:26 +02:00
Jonas Kvinge
980d8a65a1 Hide warning label in backend settings when not shown. 2018-06-29 00:33:30 +02:00
Jonas Kvinge
fc66e2e2c7 Fixes to xine engine 2018-06-28 23:12:39 +02:00
Jonas Kvinge
505c1feb42 Merge branch 'master' of github.com:jonaski/strawberry 2018-06-28 01:17:24 +02:00
Jonas Kvinge
985b91e5f4 Fix setting output/device for Xine and VLC backend
- Fixed setting output and device on Xine and VLC backend
- Fixed track slider for Xine, VLC and Phonon
- Improved backend settings to better support multiple backends
- Added group by samplerate and bitdepth in collection
- Fixed crash on exit when existing instance of the application is already runnung caused by NVIDIA driver
- Changed Q_OS_MAC to Q_OS_MACOS
2018-06-28 01:15:32 +02:00
Jonas Kvinge
ef7b95220c Update README.md 2018-06-21 01:50:14 +02:00
Jonas Kvinge
6978983dd3 Update README.md 2018-06-20 15:31:37 +02:00
Jonas Kvinge
008c39cd00 Add gstsink to devicefinder 2018-06-17 15:07:11 +02:00
Jonas Kvinge
416beb6b8e Use BOOST_SCOPE_EXIT 2018-06-12 00:26:08 +02:00
Jonas Kvinge
c4e64b591d Fix crash 2018-06-11 22:35:46 +02:00
Jonas Kvinge
bc78c3f3cb Release 0.1.6 2018-06-07 23:23:59 +02:00
Jonas Kvinge
60b55b6d7d Improvements to device selection 2018-06-07 19:38:40 +02:00
Jonas Kvinge
d45f8672cd Fix pulseaudio device selection 2018-06-07 02:06:12 +02:00
Jonas Kvinge
8df599ffe5 Exiting immediately to work around nvidia crash 2018-06-07 02:04:26 +02:00
Jonas Kvinge
f9c2801db1 Cleanup alsadevicefinder
Signed-off-by: Jonas Kvinge <jonas@jkvinge.net>
2018-05-22 22:36:32 +02:00
Jonas Kvinge
e5774ffcdc Turn back git revision 2018-05-16 23:31:45 +02:00
1913 changed files with 382760 additions and 119374 deletions

219
.clang-format Normal file
View File

@@ -0,0 +1,219 @@
---
Language: Cpp
# BasedOnStyle: LLVM
AccessModifierOffset: -1
AlignAfterOpenBracket: Align
AlignArrayOfStructures: None
AlignConsecutiveAssignments:
Enabled: false
AcrossEmptyLines: false
AcrossComments: false
AlignCompound: false
PadOperators: true
AlignConsecutiveBitFields:
Enabled: false
AcrossEmptyLines: false
AcrossComments: false
AlignCompound: false
PadOperators: false
AlignConsecutiveDeclarations:
Enabled: false
AcrossEmptyLines: false
AcrossComments: false
AlignCompound: false
PadOperators: false
AlignConsecutiveMacros:
Enabled: true
AcrossEmptyLines: false
AcrossComments: false
AlignCompound: false
PadOperators: false
AlignEscapedNewlines: Left
AlignOperands: DontAlign
AlignTrailingComments: true
AllowAllArgumentsOnNextLine: false
AllowAllParametersOfDeclarationOnNextLine: false
AllowShortEnumsOnASingleLine: true
AllowShortBlocksOnASingleLine: Never
AllowShortCaseLabelsOnASingleLine: true
AllowShortFunctionsOnASingleLine: All
AllowShortLambdasOnASingleLine: All
AllowShortIfStatementsOnASingleLine: AllIfsAndElse
AllowShortLoopsOnASingleLine: true
AlwaysBreakAfterDefinitionReturnType: None
AlwaysBreakAfterReturnType: None
AlwaysBreakBeforeMultilineStrings: false
AlwaysBreakTemplateDeclarations: No
AttributeMacros:
- __capability
BinPackArguments: true
BinPackParameters: true
BraceWrapping:
AfterCaseLabel: false
AfterClass: false
AfterControlStatement: Never
AfterEnum: false
AfterFunction: false
AfterNamespace: false
AfterObjCDeclaration: false
AfterStruct: false
AfterUnion: false
AfterExternBlock: false
BeforeCatch: false
BeforeElse: true
BeforeLambdaBody: false
BeforeWhile: false
IndentBraces: false
SplitEmptyFunction: false
SplitEmptyRecord: false
SplitEmptyNamespace: false
BreakBeforeBinaryOperators: None
BreakBeforeConceptDeclarations: Always
BreakBeforeBraces: Custom
BreakBeforeInheritanceComma: false
BreakInheritanceList: BeforeColon
BreakBeforeTernaryOperators: false
BreakConstructorInitializersBeforeComma: false
BreakConstructorInitializers: BeforeColon
BreakAfterJavaFieldAnnotations: false
BreakStringLiterals: false
ColumnLimit: 0
CommentPragmas: '^ IWYU pragma:'
QualifierAlignment: Leave
CompactNamespaces: false
ConstructorInitializerIndentWidth: 4
ContinuationIndentWidth: 2
Cpp11BracedListStyle: false
DeriveLineEnding: true
DerivePointerAlignment: false
DisableFormat: true
EmptyLineAfterAccessModifier: Never
EmptyLineBeforeAccessModifier: LogicalBlock
ExperimentalAutoDetectBinPacking: false
PackConstructorInitializers: BinPack
BasedOnStyle: ''
ConstructorInitializerAllOnOneLineOrOnePerLine: false
AllowAllConstructorInitializersOnNextLine: true
FixNamespaceComments: true
ForEachMacros:
- foreach
- Q_FOREACH
- BOOST_FOREACH
IfMacros:
- KJ_IF_MAYBE
IncludeBlocks: Preserve
IncludeCategories:
- Regex: '^"(llvm|llvm-c|clang|clang-c)/'
Priority: 2
SortPriority: 0
CaseSensitive: false
- Regex: '^(<|"(gtest|gmock|isl|json)/)'
Priority: 3
SortPriority: 0
CaseSensitive: false
- Regex: '.*'
Priority: 1
SortPriority: 0
CaseSensitive: false
IncludeIsMainRegex: '(Test)?$'
IncludeIsMainSourceRegex: ''
IndentAccessModifiers: false
IndentCaseLabels: true
IndentCaseBlocks: false
IndentGotoLabels: true
IndentPPDirectives: AfterHash
IndentExternBlock: AfterExternBlock
IndentRequiresClause: true
IndentWidth: 2
IndentWrappedFunctionNames: false
InsertBraces: false
InsertTrailingCommas: None
JavaScriptQuotes: Leave
JavaScriptWrapImports: true
KeepEmptyLines:
AtEndOfFile: true
AtStartOfBlock: true
AtStartOfFile: true
LambdaBodyIndentation: Signature
MacroBlockBegin: ''
MacroBlockEnd: ''
MaxEmptyLinesToKeep: 100
NamespaceIndentation: None
ObjCBinPackProtocolList: Auto
ObjCBlockIndentWidth: 2
ObjCBreakBeforeNestedBlockParam: true
ObjCSpaceAfterProperty: false
ObjCSpaceBeforeProtocolList: true
PenaltyBreakAssignment: 0
PenaltyBreakBeforeFirstCallParameter: 0
PenaltyBreakComment: 0
PenaltyBreakFirstLessLess: 0
PenaltyBreakOpenParenthesis: 0
PenaltyBreakString: 0
PenaltyBreakTemplateDeclaration: 0
PenaltyExcessCharacter: 0
PenaltyReturnTypeOnItsOwnLine: 0
PenaltyIndentedWhitespace: 0
PointerAlignment: Right
PPIndentWidth: -1
ReferenceAlignment: Pointer
ReflowComments: false
RemoveBracesLLVM: false
RequiresClausePosition: OwnLine
SeparateDefinitionBlocks: Leave
ShortNamespaceLines: 1
SortIncludes: false
SortJavaStaticImport: Before
SortUsingDeclarations: false
SpaceAfterCStyleCast: false
SpaceAfterLogicalNot: false
SpaceAfterTemplateKeyword: false
SpaceBeforeAssignmentOperators: true
SpaceBeforeCaseColon: false
SpaceBeforeCpp11BracedList: true
SpaceBeforeCtorInitializerColon: true
SpaceBeforeInheritanceColon: true
SpaceBeforeParens: ControlStatements
SpaceBeforeParensOptions:
AfterControlStatements: true
AfterForeachMacros: true
AfterFunctionDefinitionName: false
AfterFunctionDeclarationName: false
AfterIfMacros: true
AfterOverloadedOperator: false
AfterRequiresInClause: false
AfterRequiresInExpression: false
BeforeNonEmptyParentheses: false
SpaceAroundPointerQualifiers: Default
SpaceBeforeRangeBasedForLoopColon: true
SpaceInEmptyBlock: false
SpaceInEmptyParentheses: false
SpacesBeforeTrailingComments: 2
SpacesInAngles: Never
SpacesInConditionalStatement: false
SpacesInContainerLiterals: true
SpacesInCStyleCastParentheses: false
SpacesInLineCommentPrefix:
Minimum: 1
Maximum: -1
SpacesInParentheses: false
SpacesInSquareBrackets: false
SpaceBeforeSquareBrackets: false
BitFieldColonSpacing: Both
Standard: Latest
StatementAttributeLikeMacros:
- Q_EMIT
StatementMacros:
- Q_UNUSED
- QT_REQUIRE_VERSION
TabWidth: 8
UseCRLF: false
UseTab: Never
WhitespaceSensitiveMacros:
- STRINGIZE
- PP_STRINGIZE
- BOOST_PP_STRINGIZE
- NS_SWIFT_NAME
- CF_SWIFT_NAME
...

4
.github/FUNDING.yml vendored Normal file
View File

@@ -0,0 +1,4 @@
github: jonaski
patreon: jonaskvinge
ko_fi: jonaskvinge
custom: https://paypal.me/jonaskvinge

View File

@@ -0,0 +1,31 @@
---
name: Bug report
about: Create a report to help us improve
title: ''
labels: ''
assignees: ''
---
- [ ] I have checked the [FAQ](https://wiki.strawberrymusicplayer.org/wiki/FAQ) for answers.
- [ ] I have checked the [Changelog](https://github.com/strawberrymusicplayer/strawberry/blob/master/Changelog) that the issue is not already fixed.
- [ ] I believe this issue is a bug, and not a general technical issue, question or feature requests that can be discussed on the [forum](https://forum.strawberrymusicplayer.org/).
**Describe the bug**
A clear and concise description of what the bug is.
**To Reproduce**
Steps to reproduce the behavior.
**Expected behavior**
A clear and concise description of what you expected to happen.
**Screenshots:**
If applicable, add screenshots to help explain your problem.
**System Information:**
- Operating system:
- Strawberry Version:
**Additional context**
Add any other context about the problem here.

1
.github/ISSUE_TEMPLATE/config.yml vendored Normal file
View File

@@ -0,0 +1 @@
blank_issues_enabled: false

6
.github/dependabot.yml vendored Normal file
View File

@@ -0,0 +1,6 @@
version: 2
updates:
- package-ecosystem: "github-actions"
directory: "/"
schedule:
interval: daily

1741
.github/workflows/build.yml vendored Normal file

File diff suppressed because it is too large Load Diff

89
.gitignore vendored
View File

@@ -1,73 +1,16 @@
# This file is used to ignore files which are generated
# ----------------------------------------------------------------------------
*~
*.autosave
*.a
*.core
*.moc
*.o
*.obj
*.orig
*.rej
*.so
*.so.*
*_pch.h.cpp
*_resource.rc
*.qm
.#*
*.*#
core
!core/
tags
.DS_Store
.directory
*.debug
Makefile*
*.prl
*.app
moc_*.cpp
ui_*.h
qrc_*.cpp
Thumbs.db
*.res
*.rc
/.qmake.cache
/.qmake.stash
# qtcreator generated files
*.pro.user*
# xemacs temporary files
*.flc
# Vim temporary files
.*.swp
# Visual Studio generated files
*.ib_pdb_index
*.idb
*.ilk
*.pdb
*.sln
*.suo
*.vcproj
*vcproj.*.*.user
*.ncb
*.sdf
*.opensdf
*.vcxproj
*vcxproj.*
# MinGW generated files
*.Debug
*.Release
# Python byte code
*.pyc
# Binaries
# --------
*.dll
*.exe
/build
/bin
/CMakeLists.txt.user
/.qtcreator
/.kdev4
/strawberry.kdev4
/.vscode
/.code-workspace
/.sublime-workspace
/.idea
/.vs
/out
/CMakeSettings.json
/dist/scripts/maketarball.sh
/debian/changelog
_codeql_detected_source_root

0
.gitmodules vendored Normal file
View File

41
3rdparty/discord-rpc/CMakeLists.txt vendored Normal file
View File

@@ -0,0 +1,41 @@
set(DISCORD_RPC_SOURCES
discord_rpc.h
discord_register.h
discord_rpc.cpp
discord_rpc_connection.h
discord_rpc_connection.cpp
discord_serialization.h
discord_serialization.cpp
discord_connection.h
discord_backoff.h
discord_msg_queue.h
)
if(UNIX)
list(APPEND DISCORD_RPC_SOURCES discord_connection_unix.cpp)
if(APPLE)
list(APPEND DISCORD_RPC_SOURCES discord_register_osx.m)
add_definitions(-DDISCORD_OSX)
else()
list(APPEND DISCORD_RPC_SOURCES discord_register_linux.cpp)
add_definitions(-DDISCORD_LINUX)
endif()
endif()
if(WIN32)
list(APPEND DISCORD_RPC_SOURCES discord_connection_win.cpp discord_register_win.cpp)
add_definitions(-DDISCORD_WINDOWS)
endif()
add_library(discord-rpc STATIC ${DISCORD_RPC_SOURCES})
if(APPLE)
target_link_libraries(discord-rpc PRIVATE "-framework AppKit")
endif()
if(WIN32)
target_link_libraries(discord-rpc PRIVATE psapi advapi32)
endif()
target_include_directories(discord-rpc SYSTEM PRIVATE ${RapidJSON_INCLUDE_DIRS})
target_include_directories(discord-rpc PRIVATE ${CMAKE_CURRENT_SOURCE_DIR})

19
3rdparty/discord-rpc/LICENSE vendored Normal file
View File

@@ -0,0 +1,19 @@
Copyright 2017 Discord, Inc.
Permission is hereby granted, free of charge, to any person obtaining a copy of
this software and associated documentation files (the "Software"), to deal in
the Software without restriction, including without limitation the rights to
use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies
of the Software, and to permit persons to whom the Software is furnished to do
so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.

162
3rdparty/discord-rpc/README.md vendored Normal file
View File

@@ -0,0 +1,162 @@
# Discord RPC
## Fork Notice
This library was slightly modified for Strawberry Music Player with some extra features from the new API and shared library support/more unnecessary components removed. The original repository is [here](https://github.com/discord/discord-rpc)
## Deprecation Notice
This library has been deprecated in favor of Discord's GameSDK. [Learn more here](https://discordapp.com/developers/docs/game-sdk/sdk-starter-guide)
---
This is a library for interfacing your game with a locally running Discord desktop client. It's known to work on Windows, macOS, and Linux. You can use the lib directly if you like, or use it as a guide to writing your own if it doesn't suit your game as is. PRs/feedback welcome if you have an improvement everyone might want, or can describe how this doesn't meet your needs.
Included here are some quick demos that implement the very minimal subset to show current status, and
have callbacks for where a more complete game would do more things (joining, spectating, etc).
## Documentation
The most up to date documentation for Rich Presence can always be found on our [developer site](https://discordapp.com/developers/docs/rich-presence/how-to)! If you're interested in rolling your own native implementation of Rich Presence via IPC sockets instead of using our SDK—hey, you've got free time, right?—check out the ["Hard Mode" documentation](https://github.com/discordapp/discord-rpc/blob/master/documentation/hard-mode.md).
## Basic Usage
Zeroith, you should be set up to build things because you are a game developer, right?
First, head on over to the [Discord developers site](https://discordapp.com/developers/applications/me) and make yourself an app. Keep track of `Client ID` -- you'll need it here to pass to the init function.
### Unreal Engine 4 Setup
To use the Rich Presense plugin with Unreal Engine Projects:
1. Download the latest [release](https://github.com/discordapp/discord-rpc/releases) for each operating system you are targeting and the zipped source code
2. In the source code zip, copy the UE plugin—`examples/unrealstatus/Plugins/discordrpc`—to your project's plugin directory
3. At `[YOUR_UE_PROJECT]/Plugins/discordrpc/source/ThirdParty/DiscordRpcLibrary/`, create an `Include` folder and copy `discord_rpc.h` and `discord_register.h` to it from the zip
4. Follow the steps below for each OS
5. Build your UE4 project
6. Launch the editor, and enable the Discord plugin.
#### Windows
- At `[YOUR_UE_PROJECT]/Plugins/discordrpc/source/ThirdParty/DiscordRpcLibrary/`, create a `Win64` folder
- Copy `lib/discord-rpc.lib` and `bin/discord-rpc.dll` from `[RELEASE_ZIP]/win64-dynamic` to the `Win64` folder
#### Mac
- At `[YOUR_UE_PROJECT]/Plugins/discordrpc/source/ThirdParty/DiscordRpcLibrary/`, create a `Mac` folder
- Copy `libdiscord-rpc.dylib` from `[RELEASE_ZIP]/osx-dynamic/lib` to the `Mac` folder
#### Linux
- At `[YOUR_UE_PROJECT]/Plugins/discordrpc/source/ThirdParty/DiscordRpcLibrary/`, create a `Linux` folder
- Inside, create another folder `x86_64-unknown-linux-gnu`
- Copy `libdiscord-rpc.so` from `[RELEASE_ZIP]/linux-dynamic/lib` to `Linux/x86_64-unknown-linux-gnu`
### Unity Setup
If you're a Unity developer looking to integrate Rich Presence into your game, follow this simple guide to get started towards success:
1. Download the DLLs for any platform that you need from [our releases](https://github.com/discordapp/discord-rpc/releases)
2. In your Unity project, create a `Plugins` folder inside your `Assets` folder if you don't already have one
3. Copy the file `DiscordRpc.cs` from [here](https://github.com/discordapp/discord-rpc/blob/master/examples/button-clicker/Assets/DiscordRpc.cs) into your `Assets` folder. This is basically your header file for the SDK
We've got our `Plugins` folder ready, so let's get platform-specific!
#### Windows
4. Create `x86` and `x86_64` folders inside `Assets/Plugins/`
5. Copy `discord-rpc-win/win64-dynamic/bin/discord-rpc.dll` to `Assets/Plugins/x86_64/`
6. Copy `discord-rpc-win/win32-dynamic/bin/discord-rpc.dll` to `Assets/Plugins/x86/`
7. Click on both DLLs and make sure they are targetting the correct architectures in the Unity editor properties pane
8. Done!
#### MacOS
4. Copy `discord-rpc-osx/osx-dynamic/lib/libdiscord-rpc.dylib` to `Assets/Plugins/`
5. Rename `libdiscord-rpc.dylib` to `discord-rpc.bundle`
6. Done!
#### Linux
4. Copy `discord-rpc-linux/linux-dynamic-lib/libdiscord-rpc.so` to `Assets/Plugins/`
5. Done!
You're ready to roll! For code examples on how to interact with the SDK using the `DiscordRpc.cs` header file, check out [our example](https://github.com/discordapp/discord-rpc/blob/master/examples/button-clicker/Assets/DiscordController.cs)
### From package
Download a release package for your platform(s) -- they have subdirs with various prebuilt options, select the one you need add `/include` to your compile includes, `/lib` to your linker paths, and link with `discord-rpc`. For the dynamically linked builds, you'll need to ship the associated file along with your game.
### From repo
First-eth, you'll want `CMake`. There's a few different ways to install it on your system, and you should refer to [their website](https://cmake.org/install/). Many package managers provide ways of installing CMake as well.
To make sure it's installed correctly, type `cmake --version` into your flavor of terminal/cmd. If you get a response with a version number, you're good to go!
There's a [CMake](https://cmake.org/download/) file that should be able to generate the lib for you; Sometimes I use it like this:
```sh
cd <path to discord-rpc>
mkdir build
cd build
cmake .. -DCMAKE_INSTALL_PREFIX=<path to install discord-rpc to>
cmake --build . --config Release --target install
```
There is a wrapper build script `build.py` that runs `cmake` with a few different options.
Usually, I run `build.py` to get things started, then use the generated project files as I work on things. It does depend on `click` library, so do a quick `pip install click` to make sure you have it if you want to run `build.py`.
There are some CMake options you might care about:
| flag | default | does |
| ---------------------------------------------------------------------------------------- | ------- | ----------------------------------------------------------------------------------------------------------------------------------------------------- |
| `ENABLE_IO_THREAD` | `ON` | When enabled, we start up a thread to do io processing, if disabled you should call `Discord_UpdateConnection` yourself. |
| `USE_STATIC_CRT` | `OFF` | (Windows) Enable to statically link the CRT, avoiding requiring users install the redistributable package. (The prebuilt binaries enable this option) |
| [`BUILD_SHARED_LIBS`](https://cmake.org/cmake/help/v3.7/variable/BUILD_SHARED_LIBS.html) | `OFF` | Build library as a DLL |
| `WARNINGS_AS_ERRORS` | `OFF` | When enabled, compiles with `-Werror` (on \*nix platforms). |
## Continuous Builds
Why do we have three of these? Three times the fun!
| CI | badge |
| -------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------ |
| TravisCI | [![Build status](https://travis-ci.org/discordapp/discord-rpc.svg?branch=master)](https://travis-ci.org/discordapp/discord-rpc) |
| AppVeyor | [![Build status](https://ci.appveyor.com/api/projects/status/qvkoc0w1c4f4b8tj?svg=true)](https://ci.appveyor.com/project/crmarsh/discord-rpc) |
| Buildkite (internal) | [![Build status](https://badge.buildkite.com/e103d79d247f6776605a15246352a04b8fd83d69211b836111.svg)](https://buildkite.com/discord/discord-rpc) |
## Sample: send-presence
This is a text adventure "game" that inits/deinits the connection to Discord, and sends a presence update on each command.
## Sample: button-clicker
This is a sample [Unity](https://unity3d.com/) project that wraps a DLL version of the library, and sends presence updates when you click on a button. Run `python build.py unity` in the root directory to build the correct library files and place them in their respective folders.
## Sample: unrealstatus
This is a sample [Unreal](https://www.unrealengine.com) project that wraps the DLL version of the library with an Unreal plugin, exposes a blueprint class for interacting with it, and uses that to make a very simple UI. Run `python build.py unreal` in the root directory to build the correct library files and place them in their respective folders.
## Wrappers and Implementations
Below is a table of unofficial, community-developed wrappers for and implementations of Rich Presence in various languages. If you would like to have yours added, please make a pull request adding your repository to the table. The repository should include:
- The code
- A brief ReadMe of how to use it
- A working example
###### Rich Presence Wrappers and Implementations
| Name | Language |
| ------------------------------------------------------------------------- | --------------------------------- |
| [Discord RPC C#](https://github.com/Lachee/discord-rpc-csharp) | C# |
| [Discord RPC D](https://github.com/voidblaster/discord-rpc-d) | [D](https://dlang.org/) |
| [discord-rpc.jar](https://github.com/Vatuu/discord-rpc 'Discord-RPC.jar') | Java |
| [java-discord-rpc](https://github.com/MinnDevelopment/java-discord-rpc) | Java |
| [Discord-IPC](https://github.com/jagrosh/DiscordIPC) | Java |
| [Discord Rich Presence](https://npmjs.org/discord-rich-presence) | JavaScript |
| [drpc4k](https://github.com/Bluexin/drpc4k) | [Kotlin](https://kotlinlang.org/) |
| [lua-discordRPC](https://github.com/pfirsich/lua-discordRPC) | LuaJIT (FFI) |
| [pypresence](https://github.com/qwertyquerty/pypresence) | [Python](https://python.org/) |
| [SwordRPC](https://github.com/Azoy/SwordRPC) | [Swift](https://swift.org) |

63
3rdparty/discord-rpc/discord_backoff.h vendored Normal file
View File

@@ -0,0 +1,63 @@
/*
* Copyright 2017 Discord, Inc.
*
* Permission is hereby granted, free of charge, to any person obtaining a copy of
* this software and associated documentation files (the "Software"), to deal in
* the Software without restriction, including without limitation the rights to
* use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies
* of the Software, and to permit persons to whom the Software is furnished to do
* so, subject to the following conditions:
*
* The above copyright notice and this permission notice shall be included in all
* copies or substantial portions of the Software.
*
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
* SOFTWARE.
*
*/
#ifndef DISCORD_BACKOFF_H
#define DISCORD_BACKOFF_H
#include <algorithm>
#include <random>
#include <cstdint>
#include <ctime>
namespace discord_rpc {
struct Backoff {
int64_t minAmount;
int64_t maxAmount;
int64_t current;
int fails;
std::mt19937_64 randGenerator;
std::uniform_real_distribution<> randDistribution;
double rand01() { return randDistribution(randGenerator); }
Backoff(int64_t min, int64_t max)
: minAmount(min), maxAmount(max), current(min), fails(0), randGenerator(static_cast<uint64_t>(time(0))) {
}
void reset() {
fails = 0;
current = minAmount;
}
int64_t nextDelay() {
++fails;
int64_t delay = static_cast<int64_t>(static_cast<double>(current) * 2.0 * rand01());
current = std::min(current + delay, maxAmount);
return current;
}
};
} // namespace discord_rpc
#endif // DISCORD_BACKOFF_H

View File

@@ -0,0 +1,48 @@
/*
* Copyright 2017 Discord, Inc.
*
* Permission is hereby granted, free of charge, to any person obtaining a copy of
* this software and associated documentation files (the "Software"), to deal in
* the Software without restriction, including without limitation the rights to
* use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies
* of the Software, and to permit persons to whom the Software is furnished to do
* so, subject to the following conditions:
*
* The above copyright notice and this permission notice shall be included in all
* copies or substantial portions of the Software.
*
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
* SOFTWARE.
*
*/
#ifndef DISCORD_CONNECTION_H
#define DISCORD_CONNECTION_H
// This is to wrap the platform specific kinds of connect/read/write.
#include <cstdlib>
namespace discord_rpc {
// not really connectiony, but need per-platform
int GetProcessId();
struct BaseConnection {
static BaseConnection *Create();
static void Destroy(BaseConnection*&);
bool isOpen = false;
bool Open();
bool Close();
bool Write(const void *data, size_t length);
bool Read(void *data, size_t length);
};
} // namespace discord_rpc
#endif // DISCORD_CONNECTION_H

View File

@@ -0,0 +1,160 @@
/*
* Copyright 2017 Discord, Inc.
*
* Permission is hereby granted, free of charge, to any person obtaining a copy of
* this software and associated documentation files (the "Software"), to deal in
* the Software without restriction, including without limitation the rights to
* use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies
* of the Software, and to permit persons to whom the Software is furnished to do
* so, subject to the following conditions:
*
* The above copyright notice and this permission notice shall be included in all
* copies or substantial portions of the Software.
*
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
* SOFTWARE.
*
*/
#include "discord_connection.h"
#include <cerrno>
#include <fcntl.h>
#include <cstdio>
#include <cstring>
#include <sys/socket.h>
#include <sys/types.h>
#include <sys/un.h>
#include <unistd.h>
namespace discord_rpc {
int GetProcessId() {
return ::getpid();
}
struct BaseConnectionUnix : public BaseConnection {
int sock{ -1 };
};
static BaseConnectionUnix Connection;
static sockaddr_un PipeAddr{};
#ifdef MSG_NOSIGNAL
static int MsgFlags = MSG_NOSIGNAL;
#else
static int MsgFlags = 0;
#endif
static const char *GetTempPath() {
const char *temp = getenv("XDG_RUNTIME_DIR");
temp = temp ? temp : getenv("TMPDIR");
temp = temp ? temp : getenv("TMP");
temp = temp ? temp : getenv("TEMP");
temp = temp ? temp : "/tmp";
return temp;
}
BaseConnection *BaseConnection::Create() {
PipeAddr.sun_family = AF_UNIX;
return &Connection;
}
void BaseConnection::Destroy(BaseConnection *&c) {
auto self = reinterpret_cast<BaseConnectionUnix*>(c);
self->Close();
c = nullptr;
}
bool BaseConnection::Open() {
const char *tempPath = GetTempPath();
auto self = reinterpret_cast<BaseConnectionUnix*>(this);
self->sock = socket(AF_UNIX, SOCK_STREAM, 0);
if (self->sock == -1) {
return false;
}
fcntl(self->sock, F_SETFL, O_NONBLOCK);
#ifdef SO_NOSIGPIPE
int optval = 1;
setsockopt(self->sock, SOL_SOCKET, SO_NOSIGPIPE, &optval, sizeof(optval));
#endif
for (int pipeNum = 0; pipeNum < 10; ++pipeNum) {
snprintf(PipeAddr.sun_path, sizeof(PipeAddr.sun_path), "%s/discord-ipc-%d", tempPath, pipeNum);
int err = connect(self->sock, reinterpret_cast<const sockaddr*>(&PipeAddr), sizeof(PipeAddr));
if (err == 0) {
self->isOpen = true;
return true;
}
}
self->Close();
return false;
}
bool BaseConnection::Close() {
auto self = reinterpret_cast<BaseConnectionUnix*>(this);
if (self->sock == -1) {
return false;
}
close(self->sock);
self->sock = -1;
self->isOpen = false;
return true;
}
bool BaseConnection::Write(const void *data, size_t length) {
auto self = reinterpret_cast<BaseConnectionUnix*>(this);
if (self->sock == -1) {
return false;
}
ssize_t sentBytes = send(self->sock, data, length, MsgFlags);
if (sentBytes < 0) {
Close();
}
return sentBytes == static_cast<ssize_t>(length);
}
bool BaseConnection::Read(void *data, size_t length) {
auto self = reinterpret_cast<BaseConnectionUnix*>(this);
if (self->sock == -1) {
return false;
}
long res = recv(self->sock, data, length, MsgFlags);
if (res < 0) {
if (errno == EAGAIN) {
return false;
}
Close();
}
else if (res == 0) {
Close();
}
return static_cast<size_t>(res) == length;
}
} // namespace discord_rpc

View File

@@ -0,0 +1,160 @@
/*
* Copyright 2017 Discord, Inc.
*
* Permission is hereby granted, free of charge, to any person obtaining a copy of
* this software and associated documentation files (the "Software"), to deal in
* the Software without restriction, including without limitation the rights to
* use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies
* of the Software, and to permit persons to whom the Software is furnished to do
* so, subject to the following conditions:
*
* The above copyright notice and this permission notice shall be included in all
* copies or substantial portions of the Software.
*
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
* SOFTWARE.
*
*/
#include "discord_connection.h"
#define WIN32_LEAN_AND_MEAN
#define NOMCX
#define NOSERVICE
#define NOIME
#include <cassert>
#include <windows.h>
namespace discord_rpc {
int GetProcessId() {
return static_cast<int>(::GetCurrentProcessId());
}
struct BaseConnectionWin : public BaseConnection {
HANDLE pipe{ INVALID_HANDLE_VALUE };
};
static BaseConnectionWin Connection;
BaseConnection *BaseConnection::Create() {
return &Connection;
}
void BaseConnection::Destroy(BaseConnection *&c) {
auto self = reinterpret_cast<BaseConnectionWin*>(c);
self->Close();
c = nullptr;
}
bool BaseConnection::Open() {
wchar_t pipeName[]{ L"\\\\?\\pipe\\discord-ipc-0" };
const size_t pipeDigit = sizeof(pipeName) / sizeof(wchar_t) - 2;
pipeName[pipeDigit] = L'0';
auto self = reinterpret_cast<BaseConnectionWin*>(this);
for (;;) {
self->pipe = ::CreateFileW(pipeName, GENERIC_READ | GENERIC_WRITE, 0, nullptr, OPEN_EXISTING, 0, nullptr);
if (self->pipe != INVALID_HANDLE_VALUE) {
self->isOpen = true;
return true;
}
auto lastError = GetLastError();
if (lastError == ERROR_FILE_NOT_FOUND) {
if (pipeName[pipeDigit] < L'9') {
pipeName[pipeDigit]++;
continue;
}
}
else if (lastError == ERROR_PIPE_BUSY) {
if (!WaitNamedPipeW(pipeName, 10000)) {
return false;
}
continue;
}
return false;
}
}
bool BaseConnection::Close() {
auto self = reinterpret_cast<BaseConnectionWin*>(this);
::CloseHandle(self->pipe);
self->pipe = INVALID_HANDLE_VALUE;
self->isOpen = false;
return true;
}
bool BaseConnection::Write(const void *data, size_t length) {
if (length == 0) {
return true;
}
auto self = reinterpret_cast<BaseConnectionWin*>(this);
assert(self);
if (!self) {
return false;
}
if (self->pipe == INVALID_HANDLE_VALUE) {
return false;
}
assert(data);
if (!data) {
return false;
}
const DWORD bytesLength = static_cast<DWORD>(length);
DWORD bytesWritten = 0;
return ::WriteFile(self->pipe, data, bytesLength, &bytesWritten, nullptr) == TRUE && bytesWritten == bytesLength;
}
bool BaseConnection::Read(void *data, size_t length) {
assert(data);
if (!data) {
return false;
}
auto self = reinterpret_cast<BaseConnectionWin*>(this);
assert(self);
if (!self) {
return false;
}
if (self->pipe == INVALID_HANDLE_VALUE) {
return false;
}
DWORD bytesAvailable = 0;
if (::PeekNamedPipe(self->pipe, nullptr, 0, nullptr, &bytesAvailable, nullptr)) {
if (bytesAvailable >= length) {
DWORD bytesToRead = static_cast<DWORD>(length);
DWORD bytesRead = 0;
if (::ReadFile(self->pipe, data, bytesToRead, &bytesRead, nullptr) == TRUE) {
assert(bytesToRead == bytesRead);
return true;
}
else {
Close();
}
}
}
else {
Close();
}
return false;
}
} // namespace discord_rpc

View File

@@ -0,0 +1,64 @@
/*
* Copyright 2017 Discord, Inc.
*
* Permission is hereby granted, free of charge, to any person obtaining a copy of
* this software and associated documentation files (the "Software"), to deal in
* the Software without restriction, including without limitation the rights to
* use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies
* of the Software, and to permit persons to whom the Software is furnished to do
* so, subject to the following conditions:
*
* The above copyright notice and this permission notice shall be included in all
* copies or substantial portions of the Software.
*
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
* SOFTWARE.
*
*/
#ifndef DISCORD_MSG_QUEUE_H
#define DISCORD_MSG_QUEUE_H
#include <atomic>
// A simple queue. No locks, but only works with a single thread as producer and a single thread as
// a consumer. Mutex up as needed.
namespace discord_rpc {
template<typename ElementType, std::size_t QueueSize>
class MsgQueue {
ElementType queue_[QueueSize];
std::atomic_uint nextAdd_{ 0 };
std::atomic_uint nextSend_{ 0 };
std::atomic_uint pendingSends_{ 0 };
public:
MsgQueue() {}
ElementType *GetNextAddMessage() {
// if we are falling behind, bail
if (pendingSends_.load() >= QueueSize) {
return nullptr;
}
auto index = (nextAdd_++) % QueueSize;
return &queue_[index];
}
void CommitAdd() { ++pendingSends_; }
bool HavePendingSends() const { return pendingSends_.load() != 0; }
ElementType *GetNextSendMessage() {
auto index = (nextSend_++) % QueueSize;
return &queue_[index];
}
void CommitSend() { --pendingSends_; }
};
} // namespace discord_rpc
#endif // DISCORD_MSG_QUEUE_H

37
3rdparty/discord-rpc/discord_register.h vendored Normal file
View File

@@ -0,0 +1,37 @@
/*
* Copyright 2017 Discord, Inc.
*
* Permission is hereby granted, free of charge, to any person obtaining a copy of
* this software and associated documentation files (the "Software"), to deal in
* the Software without restriction, including without limitation the rights to
* use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies
* of the Software, and to permit persons to whom the Software is furnished to do
* so, subject to the following conditions:
*
* The above copyright notice and this permission notice shall be included in all
* copies or substantial portions of the Software.
*
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
* SOFTWARE.
*
*/
#ifndef DISCORD_REGISTER_H
#define DISCORD_REGISTER_H
#ifdef __cplusplus
extern "C" {
#endif
void Discord_Register(const char *applicationId, const char *command);
#ifdef __cplusplus
}
#endif
#endif // DISCORD_REGISTER_H

View File

@@ -0,0 +1,120 @@
/*
* Copyright 2017 Discord, Inc.
*
* Permission is hereby granted, free of charge, to any person obtaining a copy of
* this software and associated documentation files (the "Software"), to deal in
* the Software without restriction, including without limitation the rights to
* use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies
* of the Software, and to permit persons to whom the Software is furnished to do
* so, subject to the following conditions:
*
* The above copyright notice and this permission notice shall be included in all
* copies or substantial portions of the Software.
*
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
* SOFTWARE.
*
*/
#include "discord_rpc.h"
#include "discord_register.h"
#include <cstdio>
#include <errno.h>
#include <cstdlib>
#include <cstring>
#include <sys/stat.h>
#include <sys/types.h>
#include <unistd.h>
namespace {
static bool Mkdir(const char *path) {
int result = mkdir(path, 0755);
if (result == 0) {
return true;
}
if (errno == EEXIST) {
return true;
}
return false;
}
} // namespace
// We want to register games so we can run them from Discord client as discord-<appid>://
extern "C" void Discord_Register(const char *applicationId, const char *command) {
// Add a desktop file and update some mime handlers so that xdg-open does the right thing.
const char *home = getenv("HOME");
if (!home) {
return;
}
char exePath[1024]{};
if (!command || !command[0]) {
const ssize_t size = readlink("/proc/self/exe", exePath, sizeof(exePath));
if (size <= 0 || size >= static_cast<ssize_t>(sizeof(exePath))) {
return;
}
exePath[size] = '\0';
command = exePath;
}
constexpr char desktopFileFormat[] = "[Desktop Entry]\n"
"Name=Game %s\n"
"Exec=%s %%u\n" // note: it really wants that %u in there
"Type=Application\n"
"NoDisplay=true\n"
"Categories=Discord;Games;\n"
"MimeType=x-scheme-handler/discord-%s;\n";
char desktopFile[2048]{};
int fileLen = snprintf(desktopFile, sizeof(desktopFile), desktopFileFormat, applicationId, command, applicationId);
if (fileLen <= 0) {
return;
}
char desktopFilename[256]{};
(void)snprintf(desktopFilename, sizeof(desktopFilename), "/discord-%s.desktop", applicationId);
char desktopFilePath[1024]{};
(void)snprintf(desktopFilePath, sizeof(desktopFilePath), "%s/.local", home);
if (!Mkdir(desktopFilePath)) {
return;
}
strcat(desktopFilePath, "/share");
if (!Mkdir(desktopFilePath)) {
return;
}
strcat(desktopFilePath, "/applications");
if (!Mkdir(desktopFilePath)) {
return;
}
strcat(desktopFilePath, desktopFilename);
FILE *fp = fopen(desktopFilePath, "w");
if (fp) {
fwrite(desktopFile, 1, fileLen, fp);
fclose(fp);
}
else {
return;
}
char xdgMimeCommand[1024]{};
snprintf(xdgMimeCommand,
sizeof(xdgMimeCommand),
"xdg-mime default discord-%s.desktop x-scheme-handler/discord-%s",
applicationId,
applicationId);
if (system(xdgMimeCommand) < 0) {
fprintf(stderr, "Failed to register mime handler\n");
}
}

View File

@@ -0,0 +1,99 @@
/*
* Copyright 2017 Discord, Inc.
*
* Permission is hereby granted, free of charge, to any person obtaining a copy of
* this software and associated documentation files (the "Software"), to deal in
* the Software without restriction, including without limitation the rights to
* use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies
* of the Software, and to permit persons to whom the Software is furnished to do
* so, subject to the following conditions:
*
* The above copyright notice and this permission notice shall be included in all
* copies or substantial portions of the Software.
*
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
* SOFTWARE.
*
*/
#include <stdio.h>
#include <sys/stat.h>
#import <AppKit/AppKit.h>
#include "discord_register.h"
static void RegisterCommand(const char *applicationId, const char *command) {
// There does not appear to be a way to register arbitrary commands on OSX, so instead we'll save the command
// to a file in the Discord config path, and when it is needed, Discord can try to load the file there, open
// the command therein (will pass to js's window.open, so requires a url-like thing)
// Note: will not work for sandboxed apps
NSString *home = NSHomeDirectory();
if (!home) {
return;
}
NSString *path = [[[[[[home stringByAppendingPathComponent:@"Library"]
stringByAppendingPathComponent:@"Application Support"]
stringByAppendingPathComponent:@"discord"]
stringByAppendingPathComponent:@"games"]
stringByAppendingPathComponent:[NSString stringWithUTF8String:applicationId]]
stringByAppendingPathExtension:@"json"];
[[NSFileManager defaultManager] createDirectoryAtPath:[path stringByDeletingLastPathComponent] withIntermediateDirectories:YES attributes:nil error:nil];
NSString *jsonBuffer = [NSString stringWithFormat:@"{\"command\": \"%s\"}", command];
[jsonBuffer writeToFile:path atomically:NO encoding:NSUTF8StringEncoding error:nil];
}
static void RegisterURL(const char *applicationId) {
char url[256];
snprintf(url, sizeof(url), "discord-%s", applicationId);
CFStringRef cfURL = CFStringCreateWithCString(NULL, url, kCFStringEncodingUTF8);
NSString* myBundleId = [[NSBundle mainBundle] bundleIdentifier];
if (!myBundleId) {
fprintf(stderr, "No bundle id found\n");
return;
}
NSURL* myURL = [[NSBundle mainBundle] bundleURL];
if (!myURL) {
fprintf(stderr, "No bundle url found\n");
return;
}
OSStatus status = LSSetDefaultHandlerForURLScheme(cfURL, (__bridge CFStringRef)myBundleId);
if (status != noErr) {
fprintf(stderr, "Error in LSSetDefaultHandlerForURLScheme: %d\n", (int)status);
return;
}
status = LSRegisterURL((__bridge CFURLRef)myURL, true);
if (status != noErr) {
fprintf(stderr, "Error in LSRegisterURL: %d\n", (int)status);
}
}
void Discord_Register(const char *applicationId, const char *command) {
if (command) {
RegisterCommand(applicationId, command);
}
else {
// raii lite
@autoreleasepool {
RegisterURL(applicationId);
}
}
}

View File

@@ -0,0 +1,165 @@
/*
* Copyright 2017 Discord, Inc.
*
* Permission is hereby granted, free of charge, to any person obtaining a copy of
* this software and associated documentation files (the "Software"), to deal in
* the Software without restriction, including without limitation the rights to
* use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies
* of the Software, and to permit persons to whom the Software is furnished to do
* so, subject to the following conditions:
*
* The above copyright notice and this permission notice shall be included in all
* copies or substantial portions of the Software.
*
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
* SOFTWARE.
*
*/
#include "discord_rpc.h"
#include "discord_register.h"
#define WIN32_LEAN_AND_MEAN
#define NOMCX
#define NOSERVICE
#define NOIME
#include <windows.h>
#include <psapi.h>
#include <cstdio>
/**
* Updated fixes for MinGW and WinXP
* This block is written the way it does not involve changing the rest of the code
* Checked to be compiling
* 1) strsafe.h belongs to Windows SDK and cannot be added to MinGW
* #include guarded, functions redirected to <string.h> substitutes
* 2) RegSetKeyValueW and LSTATUS are not declared in <winreg.h>
* The entire function is rewritten
*/
#ifdef __MINGW32__
# include <wchar.h>
/// strsafe.h fixes
static HRESULT StringCbPrintfW(LPWSTR pszDest, size_t cbDest, LPCWSTR pszFormat, ...) {
HRESULT ret;
va_list va;
va_start(va, pszFormat);
cbDest /= 2; // Size is divided by 2 to convert from bytes to wide characters - causes segfault
// othervise
ret = vsnwprintf(pszDest, cbDest, pszFormat, va);
pszDest[cbDest - 1] = 0; // Terminate the string in case a buffer overflow; -1 will be returned
va_end(va);
return ret;
}
#else
# include <cwchar>
# include <strsafe.h>
#endif // __MINGW32__
/// winreg.h fixes
#ifndef LSTATUS
# define LSTATUS LONG
#endif
#ifdef RegSetKeyValueW
# undefine RegSetKeyValueW
#endif
#define RegSetKeyValueW regset
static LSTATUS regset(HKEY hkey, LPCWSTR subkey, LPCWSTR name, DWORD type, const void *data, DWORD len) {
HKEY htkey = hkey, hsubkey = nullptr;
LSTATUS ret;
if (subkey && subkey[0]) {
if ((ret = RegCreateKeyExW(hkey, subkey, 0, 0, 0, KEY_ALL_ACCESS, 0, &hsubkey, 0)) !=
ERROR_SUCCESS)
return ret;
htkey = hsubkey;
}
ret = RegSetValueExW(htkey, name, 0, type, static_cast<const BYTE*>(data), len);
if (hsubkey && hsubkey != hkey)
RegCloseKey(hsubkey);
return ret;
}
static void Discord_RegisterW(const wchar_t *applicationId, const wchar_t *command) {
// https://msdn.microsoft.com/en-us/library/aa767914(v=vs.85).aspx
// we want to register games so we can run them as discord-<appid>://
// Update the HKEY_CURRENT_USER, because it doesn't seem to require special permissions.
wchar_t exeFilePath[MAX_PATH]{};
DWORD exeLen = GetModuleFileNameW(nullptr, exeFilePath, MAX_PATH);
wchar_t openCommand[1024]{};
if (command && command[0]) {
StringCbPrintfW(openCommand, sizeof(openCommand), L"%s", command);
}
else {
// StringCbCopyW(openCommand, sizeof(openCommand), exeFilePath);
StringCbPrintfW(openCommand, sizeof(openCommand), L"%s", exeFilePath);
}
wchar_t protocolName[64]{};
StringCbPrintfW(protocolName, sizeof(protocolName), L"discord-%s", applicationId);
wchar_t protocolDescription[128]{};
StringCbPrintfW(protocolDescription, sizeof(protocolDescription), L"URL:Run game %s protocol", applicationId);
wchar_t urlProtocol = 0;
wchar_t keyName[256]{};
StringCbPrintfW(keyName, sizeof(keyName), L"Software\\Classes\\%s", protocolName);
HKEY key;
auto status = RegCreateKeyExW(HKEY_CURRENT_USER, keyName, 0, nullptr, 0, KEY_WRITE, nullptr, &key, nullptr);
if (status != ERROR_SUCCESS) {
fprintf(stderr, "Error creating key\n");
return;
}
DWORD len;
LSTATUS result;
len = static_cast<DWORD>(lstrlenW(protocolDescription) + 1);
result = RegSetKeyValueW(key, nullptr, nullptr, REG_SZ, protocolDescription, len * sizeof(wchar_t));
if (FAILED(result)) {
fprintf(stderr, "Error writing description\n");
}
len = static_cast<DWORD>(lstrlenW(protocolDescription) + 1);
result = RegSetKeyValueW(key, nullptr, L"URL Protocol", REG_SZ, &urlProtocol, sizeof(wchar_t));
if (FAILED(result)) {
fprintf(stderr, "Error writing description\n");
}
result = RegSetKeyValueW(key, L"DefaultIcon", nullptr, REG_SZ, exeFilePath, (exeLen + 1) * sizeof(wchar_t));
if (FAILED(result)) {
fprintf(stderr, "Error writing icon\n");
}
len = static_cast<DWORD>(lstrlenW(openCommand) + 1);
result = RegSetKeyValueW(key, L"shell\\open\\command", nullptr, REG_SZ, openCommand, len * sizeof(wchar_t));
if (FAILED(result)) {
fprintf(stderr, "Error writing command\n");
}
RegCloseKey(key);
}
extern "C" void Discord_Register(const char *applicationId, const char *command) {
wchar_t appId[32]{};
MultiByteToWideChar(CP_UTF8, 0, applicationId, -1, appId, 32);
wchar_t openCommand[1024]{};
const wchar_t *wcommand = nullptr;
if (command && command[0]) {
const auto commandBufferLen = sizeof(openCommand) / sizeof(*openCommand);
MultiByteToWideChar(CP_UTF8, 0, command, -1, openCommand, commandBufferLen);
wcommand = openCommand;
}
Discord_RegisterW(appId, wcommand);
}

510
3rdparty/discord-rpc/discord_rpc.cpp vendored Normal file
View File

@@ -0,0 +1,510 @@
/*
* Copyright 2017 Discord, Inc.
*
* Permission is hereby granted, free of charge, to any person obtaining a copy of
* this software and associated documentation files (the "Software"), to deal in
* the Software without restriction, including without limitation the rights to
* use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies
* of the Software, and to permit persons to whom the Software is furnished to do
* so, subject to the following conditions:
*
* The above copyright notice and this permission notice shall be included in all
* copies or substantial portions of the Software.
*
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
* SOFTWARE.
*
*/
#include <atomic>
#include <chrono>
#include <mutex>
#include <condition_variable>
#include <thread>
#include "discord_rpc.h"
#include "discord_backoff.h"
#include "discord_register.h"
#include "discord_msg_queue.h"
#include "discord_rpc_connection.h"
#include "discord_serialization.h"
using namespace discord_rpc;
static void Discord_UpdateConnection();
namespace {
constexpr size_t MaxMessageSize{ 16 * 1024 };
constexpr size_t MessageQueueSize{ 8 };
constexpr size_t JoinQueueSize{ 8 };
struct QueuedMessage {
size_t length;
char buffer[MaxMessageSize];
void Copy(const QueuedMessage &other) {
length = other.length;
if (length) {
memcpy(buffer, other.buffer, length);
}
}
};
struct User {
// snowflake (64bit int), turned into a ascii decimal string, at most 20 chars +1 null
// terminator = 21
char userId[32];
// 32 unicode glyphs is max name size => 4 bytes per glyph in the worst case, +1 for null
// terminator = 129
char username[344];
// 4 decimal digits + 1 null terminator = 5
char discriminator[8];
// optional 'a_' + md5 hex digest (32 bytes) + null terminator = 35
char avatar[128];
// Rounded way up because I'm paranoid about games breaking from future changes in these sizes
};
static RpcConnection *Connection{ nullptr };
static DiscordEventHandlers QueuedHandlers{};
static DiscordEventHandlers Handlers{};
static std::atomic_bool WasJustConnected{ false };
static std::atomic_bool WasJustDisconnected{ false };
static std::atomic_bool GotErrorMessage{ false };
static std::atomic_bool WasJoinGame{ false };
static std::atomic_bool WasSpectateGame{ false };
static std::atomic_bool UpdatePresence{ false };
static char JoinGameSecret[256];
static char SpectateGameSecret[256];
static int LastErrorCode{ 0 };
static char LastErrorMessage[256];
static int LastDisconnectErrorCode{ 0 };
static char LastDisconnectErrorMessage[256];
static std::mutex PresenceMutex;
static std::mutex HandlerMutex;
static QueuedMessage QueuedPresence{};
static MsgQueue<QueuedMessage, MessageQueueSize> SendQueue;
static MsgQueue<User, JoinQueueSize> JoinAskQueue;
static User connectedUser;
// We want to auto connect, and retry on failure, but not as fast as possible. This does expoential backoff from 0.5 seconds to 1 minute
static Backoff ReconnectTimeMs(500, 60 * 1000);
static auto NextConnect = std::chrono::system_clock::now();
static int Pid{ 0 };
static int Nonce{ 1 };
class IoThreadHolder {
private:
std::atomic_bool keepRunning{ true };
std::mutex waitForIOMutex;
std::condition_variable waitForIOActivity;
std::thread ioThread;
public:
void Start() {
keepRunning.store(true);
ioThread = std::thread([&]() {
const std::chrono::duration<int64_t, std::milli> maxWait { 500LL };
Discord_UpdateConnection();
while (keepRunning.load()) {
std::unique_lock<std::mutex> lock(waitForIOMutex);
waitForIOActivity.wait_for(lock, maxWait);
Discord_UpdateConnection();
}
});
}
void Notify() { waitForIOActivity.notify_all(); }
void Stop() {
keepRunning.exchange(false);
Notify();
if (ioThread.joinable()) {
ioThread.join();
}
}
~IoThreadHolder() { Stop(); }
};
static IoThreadHolder *IoThread{ nullptr };
static void UpdateReconnectTime() {
NextConnect = std::chrono::system_clock::now() + std::chrono::duration<int64_t, std::milli> { ReconnectTimeMs.nextDelay() };
}
static void SignalIOActivity() {
if (IoThread != nullptr) {
IoThread->Notify();
}
}
static bool RegisterForEvent(const char *evtName) {
auto qmessage = SendQueue.GetNextAddMessage();
if (qmessage) {
qmessage->length = JsonWriteSubscribeCommand(qmessage->buffer, sizeof(qmessage->buffer), Nonce++, evtName);
SendQueue.CommitAdd();
SignalIOActivity();
return true;
}
return false;
}
static bool DeregisterForEvent(const char *evtName) {
auto qmessage = SendQueue.GetNextAddMessage();
if (qmessage) {
qmessage->length = JsonWriteUnsubscribeCommand(qmessage->buffer, sizeof(qmessage->buffer), Nonce++, evtName);
SendQueue.CommitAdd();
SignalIOActivity();
return true;
}
return false;
}
} // namespace
static void Discord_UpdateConnection() {
if (!Connection) {
return;
}
if (!Connection->IsOpen()) {
if (std::chrono::system_clock::now() >= NextConnect) {
UpdateReconnectTime();
Connection->Open();
}
}
else {
// reads
for (;;) {
JsonDocument message;
if (!Connection->Read(message)) {
break;
}
const char *evtName = GetStrMember(&message, "evt");
const char *nonce = GetStrMember(&message, "nonce");
if (nonce) {
// in responses only -- should use to match up response when needed.
if (evtName && strcmp(evtName, "ERROR") == 0) {
auto data = GetObjMember(&message, "data");
LastErrorCode = GetIntMember(data, "code");
StringCopy(LastErrorMessage, GetStrMember(data, "message", ""));
GotErrorMessage.store(true);
}
}
else {
// should have evt == name of event, optional data
if (evtName == nullptr) {
continue;
}
auto data = GetObjMember(&message, "data");
if (strcmp(evtName, "ACTIVITY_JOIN") == 0) {
auto secret = GetStrMember(data, "secret");
if (secret) {
StringCopy(JoinGameSecret, secret);
WasJoinGame.store(true);
}
}
else if (strcmp(evtName, "ACTIVITY_SPECTATE") == 0) {
auto secret = GetStrMember(data, "secret");
if (secret) {
StringCopy(SpectateGameSecret, secret);
WasSpectateGame.store(true);
}
}
else if (strcmp(evtName, "ACTIVITY_JOIN_REQUEST") == 0) {
auto user = GetObjMember(data, "user");
auto userId = GetStrMember(user, "id");
auto username = GetStrMember(user, "username");
auto avatar = GetStrMember(user, "avatar");
auto joinReq = JoinAskQueue.GetNextAddMessage();
if (userId && username && joinReq) {
StringCopy(joinReq->userId, userId);
StringCopy(joinReq->username, username);
auto discriminator = GetStrMember(user, "discriminator");
if (discriminator) {
StringCopy(joinReq->discriminator, discriminator);
}
if (avatar) {
StringCopy(joinReq->avatar, avatar);
}
else {
joinReq->avatar[0] = 0;
}
JoinAskQueue.CommitAdd();
}
}
}
}
// writes
if (UpdatePresence.exchange(false) && QueuedPresence.length) {
QueuedMessage local;
{
std::lock_guard<std::mutex> guard(PresenceMutex);
local.Copy(QueuedPresence);
}
if (!Connection->Write(local.buffer, local.length)) {
// if we fail to send, requeue
std::lock_guard<std::mutex> guard(PresenceMutex);
QueuedPresence.Copy(local);
UpdatePresence.exchange(true);
}
}
while (SendQueue.HavePendingSends()) {
auto qmessage = SendQueue.GetNextSendMessage();
Connection->Write(qmessage->buffer, qmessage->length);
SendQueue.CommitSend();
}
}
}
extern "C" void Discord_Initialize(const char *applicationId, DiscordEventHandlers *handlers, const int autoRegister) {
IoThread = new (std::nothrow) IoThreadHolder();
if (IoThread == nullptr) {
return;
}
if (autoRegister) {
Discord_Register(applicationId, nullptr);
}
Pid = GetProcessId();
{
std::lock_guard<std::mutex> guard(HandlerMutex);
if (handlers) {
QueuedHandlers = *handlers;
}
else {
QueuedHandlers = {};
}
Handlers = {};
}
if (Connection) {
return;
}
Connection = RpcConnection::Create(applicationId);
Connection->onConnect = [](JsonDocument &readyMessage) {
Discord_UpdateHandlers(&QueuedHandlers);
if (QueuedPresence.length > 0) {
UpdatePresence.exchange(true);
SignalIOActivity();
}
auto data = GetObjMember(&readyMessage, "data");
auto user = GetObjMember(data, "user");
auto userId = GetStrMember(user, "id");
auto username = GetStrMember(user, "username");
auto avatar = GetStrMember(user, "avatar");
if (userId && username) {
StringCopy(connectedUser.userId, userId);
StringCopy(connectedUser.username, username);
auto discriminator = GetStrMember(user, "discriminator");
if (discriminator) {
StringCopy(connectedUser.discriminator, discriminator);
}
if (avatar) {
StringCopy(connectedUser.avatar, avatar);
}
else {
connectedUser.avatar[0] = 0;
}
}
WasJustConnected.exchange(true);
ReconnectTimeMs.reset();
};
Connection->onDisconnect = [](int err, const char *message) {
LastDisconnectErrorCode = err;
StringCopy(LastDisconnectErrorMessage, message);
WasJustDisconnected.exchange(true);
UpdateReconnectTime();
};
IoThread->Start();
}
extern "C" void Discord_Shutdown() {
if (!Connection) {
return;
}
Connection->onConnect = nullptr;
Connection->onDisconnect = nullptr;
Handlers = {};
QueuedPresence.length = 0;
UpdatePresence.exchange(false);
if (IoThread != nullptr) {
IoThread->Stop();
delete IoThread;
IoThread = nullptr;
}
RpcConnection::Destroy(Connection);
}
extern "C" void Discord_UpdatePresence(const DiscordRichPresence *presence) {
{
std::lock_guard<std::mutex> guard(PresenceMutex);
QueuedPresence.length = JsonWriteRichPresenceObj(QueuedPresence.buffer, sizeof(QueuedPresence.buffer), Nonce++, Pid, presence);
UpdatePresence.exchange(true);
}
SignalIOActivity();
}
extern "C" void Discord_ClearPresence(void) {
Discord_UpdatePresence(nullptr);
}
extern "C" void Discord_Respond(const char *userId, /* DISCORD_REPLY_ */ int reply) {
// if we are not connected, let's not batch up stale messages for later
if (!Connection || !Connection->IsOpen()) {
return;
}
auto qmessage = SendQueue.GetNextAddMessage();
if (qmessage) {
qmessage->length = JsonWriteJoinReply(qmessage->buffer, sizeof(qmessage->buffer), userId, reply, Nonce++);
SendQueue.CommitAdd();
SignalIOActivity();
}
}
extern "C" void Discord_RunCallbacks() {
// Note on some weirdness: internally we might connect, get other signals, disconnect any number
// of times inbetween calls here. Externally, we want the sequence to seem sane, so any other
// signals are book-ended by calls to ready and disconnect.
if (!Connection) {
return;
}
const bool wasDisconnected = WasJustDisconnected.exchange(false);
const bool isConnected = Connection->IsOpen();
if (isConnected) {
// if we are connected, disconnect cb first
std::lock_guard<std::mutex> guard(HandlerMutex);
if (wasDisconnected && Handlers.disconnected) {
Handlers.disconnected(LastDisconnectErrorCode, LastDisconnectErrorMessage);
}
}
if (WasJustConnected.exchange(false)) {
std::lock_guard<std::mutex> guard(HandlerMutex);
if (Handlers.ready) {
DiscordUser du{ connectedUser.userId, connectedUser.username, connectedUser.discriminator, connectedUser.avatar };
Handlers.ready(&du);
}
}
if (GotErrorMessage.exchange(false)) {
std::lock_guard<std::mutex> guard(HandlerMutex);
if (Handlers.errored) {
Handlers.errored(LastErrorCode, LastErrorMessage);
}
}
if (WasJoinGame.exchange(false)) {
std::lock_guard<std::mutex> guard(HandlerMutex);
if (Handlers.joinGame) {
Handlers.joinGame(JoinGameSecret);
}
}
if (WasSpectateGame.exchange(false)) {
std::lock_guard<std::mutex> guard(HandlerMutex);
if (Handlers.spectateGame) {
Handlers.spectateGame(SpectateGameSecret);
}
}
// Right now this batches up any requests and sends them all in a burst; I could imagine a world
// where the implementer would rather sequentially accept/reject each one before the next invite
// is sent. I left it this way because I could also imagine wanting to process these all and
// maybe show them in one common dialog and/or start fetching the avatars in parallel, and if
// not it should be trivial for the implementer to make a queue themselves.
while (JoinAskQueue.HavePendingSends()) {
const auto req = JoinAskQueue.GetNextSendMessage();
{
std::lock_guard<std::mutex> guard(HandlerMutex);
if (Handlers.joinRequest) {
DiscordUser du{ req->userId, req->username, req->discriminator, req->avatar };
Handlers.joinRequest(&du);
}
}
JoinAskQueue.CommitSend();
}
if (!isConnected) {
// if we are not connected, disconnect message last
std::lock_guard<std::mutex> guard(HandlerMutex);
if (wasDisconnected && Handlers.disconnected) {
Handlers.disconnected(LastDisconnectErrorCode, LastDisconnectErrorMessage);
}
}
}
extern "C" void Discord_UpdateHandlers(DiscordEventHandlers *newHandlers) {
if (newHandlers) {
#define HANDLE_EVENT_REGISTRATION(handler_name, event) \
if (!Handlers.handler_name && newHandlers->handler_name) { \
RegisterForEvent(event); \
} \
else if (Handlers.handler_name && !newHandlers->handler_name) { \
DeregisterForEvent(event); \
}
std::lock_guard<std::mutex> guard(HandlerMutex);
HANDLE_EVENT_REGISTRATION(joinGame, "ACTIVITY_JOIN")
HANDLE_EVENT_REGISTRATION(spectateGame, "ACTIVITY_SPECTATE")
HANDLE_EVENT_REGISTRATION(joinRequest, "ACTIVITY_JOIN_REQUEST")
#undef HANDLE_EVENT_REGISTRATION
Handlers = *newHandlers;
}
else {
std::lock_guard<std::mutex> guard(HandlerMutex);
Handlers = {};
}
}

94
3rdparty/discord-rpc/discord_rpc.h vendored Normal file
View File

@@ -0,0 +1,94 @@
/*
* Copyright 2017 Discord, Inc.
*
* Permission is hereby granted, free of charge, to any person obtaining a copy of
* this software and associated documentation files (the "Software"), to deal in
* the Software without restriction, including without limitation the rights to
* use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies
* of the Software, and to permit persons to whom the Software is furnished to do
* so, subject to the following conditions:
*
* The above copyright notice and this permission notice shall be included in all
* copies or substantial portions of the Software.
*
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
* SOFTWARE.
*
*/
#ifndef DISCORD_RPC_H
#define DISCORD_RPC_H
#include <cstdint>
#ifdef __cplusplus
extern "C" {
#endif
typedef struct DiscordRichPresence {
int type;
int status_display_type;
const char *name; /* max 128 bytes */
const char *state; /* max 128 bytes */
const char *details; /* max 128 bytes */
int64_t startTimestamp;
int64_t endTimestamp;
const char *largeImageKey; /* max 32 bytes */
const char *largeImageText; /* max 128 bytes */
const char *smallImageKey; /* max 32 bytes */
const char *smallImageText; /* max 128 bytes */
const char *partyId; /* max 128 bytes */
int partySize;
int partyMax;
int partyPrivacy;
const char *matchSecret; /* max 128 bytes */
const char *joinSecret; /* max 128 bytes */
const char *spectateSecret; /* max 128 bytes */
int8_t instance;
} DiscordRichPresence;
typedef struct DiscordUser {
const char *userId;
const char *username;
const char *discriminator;
const char *avatar;
} DiscordUser;
typedef struct DiscordEventHandlers {
void (*ready)(const DiscordUser *request);
void (*disconnected)(int errorCode, const char *message);
void (*errored)(int errorCode, const char *message);
void (*joinGame)(const char *joinSecret);
void (*spectateGame)(const char *spectateSecret);
void (*joinRequest)(const DiscordUser *request);
} DiscordEventHandlers;
#define DISCORD_REPLY_NO 0
#define DISCORD_REPLY_YES 1
#define DISCORD_REPLY_IGNORE 2
#define DISCORD_PARTY_PRIVATE 0
#define DISCORD_PARTY_PUBLIC 1
void Discord_Initialize(const char *applicationId, DiscordEventHandlers *handlers, const int autoRegister);
void Discord_Shutdown(void);
// checks for incoming messages, dispatches callbacks
void Discord_RunCallbacks(void);
void Discord_UpdatePresence(const DiscordRichPresence *presence);
void Discord_ClearPresence(void);
void Discord_Respond(const char *userid, /* DISCORD_REPLY_ */ int reply);
void Discord_UpdateHandlers(DiscordEventHandlers *handlers);
#ifdef __cplusplus
} /* extern "C" */
#endif
#endif // DISCORD_RPC_H

View File

@@ -0,0 +1,168 @@
/*
* Copyright 2017 Discord, Inc.
*
* Permission is hereby granted, free of charge, to any person obtaining a copy of
* this software and associated documentation files (the "Software"), to deal in
* the Software without restriction, including without limitation the rights to
* use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies
* of the Software, and to permit persons to whom the Software is furnished to do
* so, subject to the following conditions:
*
* The above copyright notice and this permission notice shall be included in all
* copies or substantial portions of the Software.
*
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
* SOFTWARE.
*
*/
#include "discord_rpc_connection.h"
#include "discord_serialization.h"
namespace discord_rpc {
static const int RpcVersion = 1;
static RpcConnection Instance;
RpcConnection *RpcConnection::Create(const char *applicationId) {
Instance.connection = BaseConnection::Create();
StringCopy(Instance.appId, applicationId);
return &Instance;
}
void RpcConnection::Destroy(RpcConnection *&c) {
c->Close();
BaseConnection::Destroy(c->connection);
c = nullptr;
}
void RpcConnection::Open() {
if (state == State::Connected) {
return;
}
if (state == State::Disconnected && !connection->Open()) {
return;
}
if (state == State::SentHandshake) {
JsonDocument message;
if (Read(message)) {
auto cmd = GetStrMember(&message, "cmd");
auto evt = GetStrMember(&message, "evt");
if (cmd && evt && !strcmp(cmd, "DISPATCH") && !strcmp(evt, "READY")) {
state = State::Connected;
if (onConnect) {
onConnect(message);
}
}
}
}
else {
sendFrame.opcode = Opcode::Handshake;
sendFrame.length = static_cast<uint32_t>(JsonWriteHandshakeObj(sendFrame.message, sizeof(sendFrame.message), RpcVersion, appId));
if (connection->Write(&sendFrame, sizeof(MessageFrameHeader) + sendFrame.length)) {
state = State::SentHandshake;
}
else {
Close();
}
}
}
void RpcConnection::Close() {
if (onDisconnect && (state == State::Connected || state == State::SentHandshake)) {
onDisconnect(lastErrorCode, lastErrorMessage);
}
connection->Close();
state = State::Disconnected;
}
bool RpcConnection::Write(const void *data, size_t length) {
sendFrame.opcode = Opcode::Frame;
memcpy(sendFrame.message, data, length);
sendFrame.length = static_cast<uint32_t>(length);
if (!connection->Write(&sendFrame, sizeof(MessageFrameHeader) + length)) {
Close();
return false;
}
return true;
}
bool RpcConnection::Read(JsonDocument &message) {
if (state != State::Connected && state != State::SentHandshake) {
return false;
}
MessageFrame readFrame{};
for (;;) {
bool didRead = connection->Read(&readFrame, sizeof(MessageFrameHeader));
if (!didRead) {
if (!connection->isOpen) {
lastErrorCode = static_cast<int>(ErrorCode::PipeClosed);
StringCopy(lastErrorMessage, "Pipe closed");
Close();
}
return false;
}
if (readFrame.length > 0) {
didRead = connection->Read(readFrame.message, readFrame.length);
if (!didRead) {
lastErrorCode = static_cast<int>(ErrorCode::ReadCorrupt);
StringCopy(lastErrorMessage, "Partial data in frame");
Close();
return false;
}
readFrame.message[readFrame.length] = 0;
}
switch (readFrame.opcode) {
case Opcode::Close: {
message.ParseInsitu(readFrame.message);
lastErrorCode = GetIntMember(&message, "code");
StringCopy(lastErrorMessage, GetStrMember(&message, "message", ""));
Close();
return false;
}
case Opcode::Frame:
message.ParseInsitu(readFrame.message);
return true;
case Opcode::Ping:
readFrame.opcode = Opcode::Pong;
if (!connection->Write(&readFrame, sizeof(MessageFrameHeader) + readFrame.length)) {
Close();
}
break;
case Opcode::Pong:
break;
case Opcode::Handshake:
default:
// something bad happened
lastErrorCode = static_cast<int>(ErrorCode::ReadCorrupt);
StringCopy(lastErrorMessage, "Bad ipc frame");
Close();
return false;
}
}
}
} // namespace discord_rpc

View File

@@ -0,0 +1,88 @@
/*
* Copyright 2017 Discord, Inc.
*
* Permission is hereby granted, free of charge, to any person obtaining a copy of
* this software and associated documentation files (the "Software"), to deal in
* the Software without restriction, including without limitation the rights to
* use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies
* of the Software, and to permit persons to whom the Software is furnished to do
* so, subject to the following conditions:
*
* The above copyright notice and this permission notice shall be included in all
* copies or substantial portions of the Software.
*
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
* SOFTWARE.
*
*/
#ifndef DISCORD_RPC_CONNECTION_H
#define DISCORD_RPC_CONNECTION_H
#include "discord_connection.h"
#include "discord_serialization.h"
namespace discord_rpc {
// I took this from the buffer size libuv uses for named pipes; I suspect ours would usually be much smaller.
constexpr size_t MaxRpcFrameSize = 64 * 1024;
struct RpcConnection {
enum class ErrorCode : int {
Success = 0,
PipeClosed = 1,
ReadCorrupt = 2,
};
enum class Opcode : uint32_t {
Handshake = 0,
Frame = 1,
Close = 2,
Ping = 3,
Pong = 4,
};
struct MessageFrameHeader {
Opcode opcode;
uint32_t length;
};
struct MessageFrame : public MessageFrameHeader {
char message[MaxRpcFrameSize - sizeof(MessageFrameHeader)];
};
enum class State : uint32_t {
Disconnected,
SentHandshake,
AwaitingResponse,
Connected,
};
BaseConnection *connection{ nullptr };
State state{ State::Disconnected };
void (*onConnect)(JsonDocument &message) { nullptr };
void (*onDisconnect)(int errorCode, const char *message) { nullptr };
char appId[64]{};
int lastErrorCode{ 0 };
char lastErrorMessage[256]{};
RpcConnection::MessageFrame sendFrame;
static RpcConnection *Create(const char *applicationId);
static void Destroy(RpcConnection*&);
inline bool IsOpen() const { return state == State::Connected; }
void Open();
void Close();
bool Write(const void *data, size_t length);
bool Read(JsonDocument &message);
};
} // namespace discord_rpc
#endif // DISCORD_RPC_CONNECTION_H

View File

@@ -0,0 +1,285 @@
/*
* Copyright 2017 Discord, Inc.
*
* Permission is hereby granted, free of charge, to any person obtaining a copy of
* this software and associated documentation files (the "Software"), to deal in
* the Software without restriction, including without limitation the rights to
* use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies
* of the Software, and to permit persons to whom the Software is furnished to do
* so, subject to the following conditions:
*
* The above copyright notice and this permission notice shall be included in all
* copies or substantial portions of the Software.
*
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
* SOFTWARE.
*
*/
#include "discord_serialization.h"
#include "discord_connection.h"
#include "discord_rpc.h"
namespace discord_rpc {
template<typename T>
void NumberToString(char *dest, T number) {
if (!number) {
*dest++ = '0';
*dest++ = 0;
return;
}
if (number < 0) {
*dest++ = '-';
number = -number;
}
char temp[32];
int place = 0;
while (number) {
auto digit = number % 10;
number = number / 10;
temp[place++] = '0' + static_cast<char>(digit);
}
for (--place; place >= 0; --place) {
*dest++ = temp[place];
}
*dest = 0;
}
// it's ever so slightly faster to not have to strlen the key
template<typename T>
void WriteKey(JsonWriter &w, T &k) {
w.Key(k, sizeof(T) - 1);
}
struct WriteObject {
JsonWriter &writer;
WriteObject(JsonWriter &w)
: writer(w) {
writer.StartObject();
}
template<typename T>
WriteObject(JsonWriter &w, T &name)
: writer(w) {
WriteKey(writer, name);
writer.StartObject();
}
~WriteObject() { writer.EndObject(); }
};
struct WriteArray {
JsonWriter &writer;
template<typename T>
WriteArray(JsonWriter &w, T &name)
: writer(w) {
WriteKey(writer, name);
writer.StartArray();
}
~WriteArray() { writer.EndArray(); }
};
template<typename T>
void WriteOptionalString(JsonWriter &w, T &k, const char *value) {
if (value && value[0]) {
w.Key(k, sizeof(T) - 1);
w.String(value);
}
}
static void JsonWriteNonce(JsonWriter &writer, const int nonce) {
WriteKey(writer, "nonce");
char nonceBuffer[32];
NumberToString(nonceBuffer, nonce);
writer.String(nonceBuffer);
}
size_t JsonWriteRichPresenceObj(char *dest, const size_t maxLen, const int nonce, const int pid, const DiscordRichPresence *presence) {
JsonWriter writer(dest, maxLen);
{
WriteObject top(writer);
JsonWriteNonce(writer, nonce);
WriteKey(writer, "cmd");
writer.String("SET_ACTIVITY");
{
WriteObject args(writer, "args");
WriteKey(writer, "pid");
writer.Int(pid);
if (presence != nullptr) {
WriteObject activity(writer, "activity");
if (presence->type >= 0 && presence->type <= 5) {
WriteKey(writer, "type");
writer.Int(presence->type);
WriteKey(writer, "status_display_type");
writer.Int(presence->status_display_type);
}
WriteOptionalString(writer, "name", presence->name);
WriteOptionalString(writer, "state", presence->state);
WriteOptionalString(writer, "details", presence->details);
if (presence->startTimestamp || presence->endTimestamp) {
WriteObject timestamps(writer, "timestamps");
if (presence->startTimestamp) {
WriteKey(writer, "start");
writer.Int64(presence->startTimestamp);
}
if (presence->endTimestamp) {
WriteKey(writer, "end");
writer.Int64(presence->endTimestamp);
}
}
if ((presence->largeImageKey && presence->largeImageKey[0]) ||
(presence->largeImageText && presence->largeImageText[0]) ||
(presence->smallImageKey && presence->smallImageKey[0]) ||
(presence->smallImageText && presence->smallImageText[0])) {
WriteObject assets(writer, "assets");
WriteOptionalString(writer, "large_image", presence->largeImageKey);
WriteOptionalString(writer, "large_text", presence->largeImageText);
WriteOptionalString(writer, "small_image", presence->smallImageKey);
WriteOptionalString(writer, "small_text", presence->smallImageText);
}
if ((presence->partyId && presence->partyId[0]) || presence->partySize ||
presence->partyMax || presence->partyPrivacy) {
WriteObject party(writer, "party");
WriteOptionalString(writer, "id", presence->partyId);
if (presence->partySize && presence->partyMax) {
WriteArray size(writer, "size");
writer.Int(presence->partySize);
writer.Int(presence->partyMax);
}
if (presence->partyPrivacy) {
WriteKey(writer, "privacy");
writer.Int(presence->partyPrivacy);
}
}
if ((presence->matchSecret && presence->matchSecret[0]) ||
(presence->joinSecret && presence->joinSecret[0]) ||
(presence->spectateSecret && presence->spectateSecret[0])) {
WriteObject secrets(writer, "secrets");
WriteOptionalString(writer, "match", presence->matchSecret);
WriteOptionalString(writer, "join", presence->joinSecret);
WriteOptionalString(writer, "spectate", presence->spectateSecret);
}
writer.Key("instance");
writer.Bool(presence->instance != 0);
}
}
}
return writer.Size();
}
size_t JsonWriteHandshakeObj(char *dest, size_t maxLen, int version, const char *applicationId) {
JsonWriter writer(dest, maxLen);
{
WriteObject obj(writer);
WriteKey(writer, "v");
writer.Int(version);
WriteKey(writer, "client_id");
writer.String(applicationId);
}
return writer.Size();
}
size_t JsonWriteSubscribeCommand(char *dest, size_t maxLen, int nonce, const char *evtName) {
JsonWriter writer(dest, maxLen);
{
WriteObject obj(writer);
JsonWriteNonce(writer, nonce);
WriteKey(writer, "cmd");
writer.String("SUBSCRIBE");
WriteKey(writer, "evt");
writer.String(evtName);
}
return writer.Size();
}
size_t JsonWriteUnsubscribeCommand(char *dest, size_t maxLen, int nonce, const char *evtName) {
JsonWriter writer(dest, maxLen);
{
WriteObject obj(writer);
JsonWriteNonce(writer, nonce);
WriteKey(writer, "cmd");
writer.String("UNSUBSCRIBE");
WriteKey(writer, "evt");
writer.String(evtName);
}
return writer.Size();
}
size_t JsonWriteJoinReply(char *dest, size_t maxLen, const char *userId, const int reply, const int nonce) {
JsonWriter writer(dest, maxLen);
{
WriteObject obj(writer);
WriteKey(writer, "cmd");
if (reply == DISCORD_REPLY_YES) {
writer.String("SEND_ACTIVITY_JOIN_INVITE");
}
else {
writer.String("CLOSE_ACTIVITY_JOIN_REQUEST");
}
WriteKey(writer, "args");
{
WriteObject args(writer);
WriteKey(writer, "user_id");
writer.String(userId);
}
JsonWriteNonce(writer, nonce);
}
return writer.Size();
}
} // namespace discord_rpc

View File

@@ -0,0 +1,213 @@
/*
* Copyright 2017 Discord, Inc.
*
* Permission is hereby granted, free of charge, to any person obtaining a copy of
* this software and associated documentation files (the "Software"), to deal in
* the Software without restriction, including without limitation the rights to
* use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies
* of the Software, and to permit persons to whom the Software is furnished to do
* so, subject to the following conditions:
*
* The above copyright notice and this permission notice shall be included in all
* copies or substantial portions of the Software.
*
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
* SOFTWARE.
*
*/
#ifndef DISCORD_SERIALIZATION_H
#define DISCORD_SERIALIZATION_H
#include <rapidjson/document.h>
#include <rapidjson/stringbuffer.h>
#include <rapidjson/writer.h>
struct DiscordRichPresence;
namespace discord_rpc {
// if only there was a standard library function for this
template<size_t Len>
inline size_t StringCopy(char (&dest)[Len], const char *src) {
if (!src || !Len) {
return 0;
}
size_t copied;
char *out = dest;
for (copied = 1; *src && copied < Len; ++copied) {
*out++ = *src++;
}
*out = 0;
return copied - 1;
}
size_t JsonWriteHandshakeObj(char *dest, size_t maxLen, int version, const char *applicationId);
// Commands
size_t JsonWriteRichPresenceObj(char *dest, const size_t maxLen, const int nonce, const int pid, const DiscordRichPresence *presence);
size_t JsonWriteSubscribeCommand(char *dest, size_t maxLen, int nonce, const char *evtName);
size_t JsonWriteUnsubscribeCommand(char *dest, size_t maxLen, int nonce, const char *evtName);
size_t JsonWriteJoinReply(char *dest, size_t maxLen, const char *userId, int reply, int nonce);
// I want to use as few allocations as I can get away with, and to do that with RapidJson, you need
// to supply some of your own allocators for stuff rather than use the defaults
class LinearAllocator {
public:
char *buffer_;
char *end_;
LinearAllocator() {
assert(0); // needed for some default case in rapidjson, should not use
}
LinearAllocator(char *buffer, size_t size)
: buffer_(buffer), end_(buffer + size) {
}
static const bool kNeedFree = false;
void *Malloc(size_t size) {
char *res = buffer_;
buffer_ += size;
if (buffer_ > end_) {
buffer_ = res;
return nullptr;
}
return res;
}
void *Realloc(void *originalPtr, size_t originalSize, size_t newSize) {
if (newSize == 0) {
return nullptr;
}
// allocate how much you need in the first place
assert(!originalPtr && !originalSize);
// unused parameter warning
(void)(originalPtr);
(void)(originalSize);
return Malloc(newSize);
}
static void Free(void *ptr) {
/* shrug */
(void)ptr;
}
};
template<size_t Size>
class FixedLinearAllocator : public LinearAllocator {
public:
char fixedBuffer_[Size];
FixedLinearAllocator()
: LinearAllocator(fixedBuffer_, Size) {
}
static const bool kNeedFree = false;
};
// wonder why this isn't a thing already, maybe I missed it
class DirectStringBuffer {
public:
using Ch = char;
char *buffer_;
char *end_;
char *current_;
DirectStringBuffer(char *buffer, size_t maxLen)
: buffer_(buffer), end_(buffer + maxLen), current_(buffer) {
}
void Put(char c) {
if (current_ < end_) {
*current_++ = c;
}
}
void Flush() {}
size_t GetSize() const { return static_cast<size_t>(current_ - buffer_); }
};
using MallocAllocator = rapidjson::CrtAllocator;
using PoolAllocator = rapidjson::MemoryPoolAllocator<MallocAllocator>;
using UTF8 = rapidjson::UTF8<char>;
// Writer appears to need about 16 bytes per nested object level (with 64bit size_t)
using StackAllocator = FixedLinearAllocator<2048>;
constexpr size_t WriterNestingLevels = 2048 / (2 * sizeof(size_t));
using JsonWriterBase =
rapidjson::Writer<DirectStringBuffer, UTF8, UTF8, StackAllocator, rapidjson::kWriteNoFlags>;
class JsonWriter : public JsonWriterBase {
public:
DirectStringBuffer stringBuffer_;
StackAllocator stackAlloc_;
JsonWriter(char *dest, size_t maxLen)
: JsonWriterBase(stringBuffer_, &stackAlloc_, WriterNestingLevels), stringBuffer_(dest, maxLen), stackAlloc_() {
}
size_t Size() const { return stringBuffer_.GetSize(); }
};
using JsonDocumentBase = rapidjson::GenericDocument<UTF8, PoolAllocator, StackAllocator>;
class JsonDocument : public JsonDocumentBase {
public:
static const int kDefaultChunkCapacity = 32 * 1024;
// json parser will use this buffer first, then allocate more if needed; I seriously doubt we
// send any messages that would use all of this, though.
char parseBuffer_[32 * 1024];
MallocAllocator mallocAllocator_;
PoolAllocator poolAllocator_;
StackAllocator stackAllocator_;
JsonDocument()
: JsonDocumentBase(rapidjson::kObjectType,
&poolAllocator_,
sizeof(stackAllocator_.fixedBuffer_),
&stackAllocator_),
poolAllocator_(parseBuffer_, sizeof(parseBuffer_), kDefaultChunkCapacity, &mallocAllocator_), stackAllocator_() {
}
};
using JsonValue = rapidjson::GenericValue<UTF8, PoolAllocator>;
inline JsonValue *GetObjMember(JsonValue *obj, const char *name) {
if (obj) {
auto member = obj->FindMember(name);
if (member != obj->MemberEnd() && member->value.IsObject()) {
return &member->value;
}
}
return nullptr;
}
inline int GetIntMember(JsonValue *obj, const char *name, int notFoundDefault = 0) {
if (obj) {
auto member = obj->FindMember(name);
if (member != obj->MemberEnd() && member->value.IsInt()) {
return member->value.GetInt();
}
}
return notFoundDefault;
}
inline const char *GetStrMember(JsonValue *obj, const char *name, const char *notFoundDefault = nullptr) {
if (obj) {
auto member = obj->FindMember(name);
if (member != obj->MemberEnd() && member->value.IsString()) {
return member->value.GetString();
}
}
return notFoundDefault;
}
} // namespace discord_rpc
#endif // DISCORD_SERIALIZATION_H

View File

@@ -1,33 +0,0 @@
cmake_minimum_required(VERSION 2.8.11)
set(CMAKE_CXX_STANDARD 11)
set(SOURCES)
set(HEADERS
qsearchfield.h
qbutton.h
qprogressindicatorspinning.h
)
qt5_wrap_cpp(MOC_SOURCES ${HEADERS})
if(APPLE)
list(APPEND SOURCES
qsearchfield_mac.mm
qbutton_mac.mm
qprogressindicatorspinning_mac.mm
)
else()
list(APPEND SOURCES
qsearchfield_nonmac.cpp
qbutton_nonmac.cpp
qprogressindicatorspinning_nonmac.cpp
)
set(RESOURCES
qprogressindicatorspinning_nonmac.qrc
)
qt5_add_resources(RESOURCES_SOURCES ${RESOURCES})
endif()
add_library(Qocoa STATIC ${SOURCES} ${MOC_SOURCES} ${RESOURCES_SOURCES})
target_link_libraries(Qocoa ${QT_LIBRARIES})

View File

@@ -1,17 +0,0 @@
SOURCES += main.cpp\
gallery.cpp \
HEADERS += gallery.h \
qocoa_mac.h \
qsearchfield.h \
qbutton.h \
qprogressindicatorspinning.h \
mac {
OBJECTIVE_SOURCES += qsearchfield_mac.mm qbutton_mac.mm qprogressindicatorspinning_mac.mm
LIBS += -framework Foundation -framework Appkit
QMAKE_CFLAGS += -mmacosx-version-min=10.6
} else {
SOURCES += qsearchfield_nonmac.cpp qbutton_nonmac.cpp qprogressindicatorspinning_nonmac.cpp
RESOURCES += qsearchfield_nonmac.qrc qprogressindicatorspinning_nonmac.qrc
}

View File

@@ -1,34 +0,0 @@
# Qocoa
Qocoa is a collection of Qt wrappers for OSX's Cocoa widgets.
## Features
- basic fallback to sensible Qt types on non-OSX platforms
- shared class headers which expose no implementation details
- typical Qt signal/slot-based API
- trivial to import into projects (class header/implementation, [single shared global header](https://github.com/mikemcquaid/Qocoa/blob/master/qocoa_mac.h))
## Building
```
git clone git://github.com/mikemcquaid/Qocoa.git
cd Qocoa
qmake # or cmake .
make
```
## Status
Qocoa classes are currently provided for NSButton, a spinning NSProgressIndicator and NSSearchField. There is a [TODO list](https://github.com/mikemcquaid/Qocoa/blob/master/TODO.md) for classes I hope to implement.
## Usage
For each class you want to use copy the [`qocoa_mac.h`](https://github.com/mikemcquaid/Qocoa/blob/master/qocoa_mac.h), `$CLASS.h`, `$CLASS_mac.*` and `$CLASS_nonmac.*` files into your source tree and add them to your buildsystem. Examples are provided for [CMake](https://github.com/mikemcquaid/Qocoa/blob/master/CMakeLists.txt) and [QMake](https://github.com/mikemcquaid/Qocoa/blob/master/Qocoa.pro).
## Contact
[Mike McQuaid](mailto:mike@mikemcquaid.com)
## License
Qocoa is licensed under the [MIT License](http://en.wikipedia.org/wiki/MIT_License).
The full license text is available in [LICENSE.txt](https://github.com/mikemcquaid/Qocoa/blob/master/LICENSE.txt).
The icons are taken from the [Oxygen Project](http://www.oxygen-icons.org/) and are licensed under the [Creative Commons Attribution-ShareAlike 3.0 License](http://creativecommons.org/licenses/by-sa/3.0/).
## Gallery
![Qocoa Gallery](https://github.com/mikemcquaid/Qocoa/raw/master/gallery.png)

View File

@@ -1,13 +0,0 @@
Widgets I hope to implement (or at least investigate):
- NSTokenField
- NSSegmentedControl
- NSLevelIndicator
- NSPathControl
- NSSlider (Circular)
- NSSplitView
- NSTextFinder
- NSOutlineView in an NSScrollView (Source List)
- NSDrawer
- PDFView
- WebView

View File

@@ -1,70 +0,0 @@
#include "gallery.h"
#include <QVBoxLayout>
#include "qsearchfield.h"
#include "qbutton.h"
#include "qprogressindicatorspinning.h"
Gallery::Gallery(QWidget *parent) : QWidget(parent)
{
setWindowTitle("Qocoa Gallery");
QVBoxLayout *layout = new QVBoxLayout(this);
QSearchField *searchField = new QSearchField(this);
layout->addWidget(searchField);
QButton *roundedButton = new QButton(this, QButton::Rounded);
roundedButton->setText("Button");
layout->addWidget(roundedButton);
QButton *regularSquareButton = new QButton(this, QButton::RegularSquare);
regularSquareButton->setText("Button");
layout->addWidget(regularSquareButton);
QButton *disclosureButton = new QButton(this, QButton::Disclosure);
layout->addWidget(disclosureButton);
QButton *shadowlessSquareButton = new QButton(this, QButton::ShadowlessSquare);
shadowlessSquareButton->setText("Button");
layout->addWidget(shadowlessSquareButton);
QButton *circularButton = new QButton(this, QButton::Circular);
layout->addWidget(circularButton);
QButton *textureSquareButton = new QButton(this, QButton::TexturedSquare);
textureSquareButton->setText("Textured Button");
layout->addWidget(textureSquareButton);
QButton *helpButton = new QButton(this, QButton::HelpButton);
layout->addWidget(helpButton);
QButton *smallSquareButton = new QButton(this, QButton::SmallSquare);
smallSquareButton->setText("Gradient Button");
layout->addWidget(smallSquareButton);
QButton *texturedRoundedButton = new QButton(this, QButton::TexturedRounded);
texturedRoundedButton->setText("Round Textured");
layout->addWidget(texturedRoundedButton);
QButton *roundedRectangleButton = new QButton(this, QButton::RoundRect);
roundedRectangleButton->setText("Rounded Rect Button");
layout->addWidget(roundedRectangleButton);
QButton *recessedButton = new QButton(this, QButton::Recessed);
recessedButton->setText("Recessed Button");
layout->addWidget(recessedButton);
QButton *roundedDisclosureButton = new QButton(this, QButton::RoundedDisclosure);
layout->addWidget(roundedDisclosureButton);
#ifdef MAC_OS_X_VERSION_10_7
QButton *inlineButton = new QButton(this, QButton::Inline);
inlineButton->setText("Inline Button");
layout->addWidget(inlineButton);
#endif
QProgressIndicatorSpinning *progressIndicatorSpinning = new QProgressIndicatorSpinning(this);
progressIndicatorSpinning->animate();
layout->addWidget(progressIndicatorSpinning);
}

View File

@@ -1,14 +0,0 @@
#ifndef GALLERY_H
#define GALLERY_H
#include <QWidget>
class Gallery : public QWidget
{
Q_OBJECT
public:
explicit Gallery(QWidget *parent = 0);
};
#endif // WIDGET_H

Binary file not shown.

Before

Width:  |  Height:  |  Size: 41 KiB

View File

@@ -1,12 +0,0 @@
#include <QApplication>
#include "gallery.h"
int main(int argc, char *argv[])
{
QApplication application(argc, argv);
Gallery gallery;
gallery.show();
return application.exec();
}

View File

@@ -1,50 +0,0 @@
#ifndef QBUTTON_H
#define QBUTTON_H
#include <QWidget>
#include <QPointer>
#include <QString>
class QButtonPrivate;
class QButton : public QWidget
{
Q_OBJECT
public:
// Matches NSBezelStyle
enum BezelStyle {
Rounded = 1,
RegularSquare = 2,
Disclosure = 5,
ShadowlessSquare = 6,
Circular = 7,
TexturedSquare = 8,
HelpButton = 9,
SmallSquare = 10,
TexturedRounded = 11,
RoundRect = 12,
Recessed = 13,
RoundedDisclosure = 14,
#ifdef MAC_OS_X_VERSION_10_7
Inline = 15
#endif
};
explicit QButton(QWidget *parent, BezelStyle bezelStyle = Rounded);
public slots:
void setText(const QString &text);
void setImage(const QPixmap &image);
void setChecked(bool checked);
public:
void setCheckable(bool checkable);
bool isChecked();
signals:
void clicked(bool checked = false);
private:
friend class QButtonPrivate;
QPointer<QButtonPrivate> pimpl;
};
#endif // QBUTTON_H

View File

@@ -1,227 +0,0 @@
/*
Copyright (C) 2011 by Mike McQuaid
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in
all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
THE SOFTWARE.
*/
#include "qbutton.h"
#include "qocoa_mac.h"
#import "Foundation/NSAutoreleasePool.h"
#import "AppKit/NSButton.h"
#import "AppKit/NSFont.h"
class QButtonPrivate : public QObject
{
public:
QButtonPrivate(QButton *qButton, NSButton *nsButton, QButton::BezelStyle bezelStyle)
: QObject(qButton), qButton(qButton), nsButton(nsButton)
{
switch(bezelStyle) {
case QButton::Disclosure:
case QButton::Circular:
case QButton::Inline:
case QButton::RoundedDisclosure:
case QButton::HelpButton:
[nsButton setTitle:@""];
default:
break;
}
NSFont* font = 0;
switch(bezelStyle) {
case QButton::RoundRect:
font = [NSFont fontWithName:@"Lucida Grande" size:12];
break;
case QButton::Recessed:
font = [NSFont fontWithName:@"Lucida Grande Bold" size:12];
break;
#ifdef MAC_OS_X_VERSION_10_7
case QButton::Inline:
font = [NSFont boldSystemFontOfSize:[NSFont systemFontSizeForControlSize:NSSmallControlSize]];
break;
#endif
default:
font = [NSFont systemFontOfSize:[NSFont systemFontSizeForControlSize:NSRegularControlSize]];
break;
}
[nsButton setFont:font];
switch(bezelStyle) {
case QButton::Rounded:
qButton->setMinimumWidth(40);
qButton->setFixedHeight(24);
qButton->setSizePolicy(QSizePolicy::Minimum, QSizePolicy::Fixed);
break;
case QButton::RegularSquare:
case QButton::TexturedSquare:
qButton->setMinimumSize(14, 23);
qButton->setSizePolicy(QSizePolicy::Minimum, QSizePolicy::Minimum);
break;
case QButton::ShadowlessSquare:
qButton->setMinimumSize(5, 25);
qButton->setSizePolicy(QSizePolicy::Minimum, QSizePolicy::Minimum);
break;
case QButton::SmallSquare:
qButton->setMinimumSize(4, 21);
qButton->setSizePolicy(QSizePolicy::Minimum, QSizePolicy::Minimum);
break;
case QButton::TexturedRounded:
qButton->setMinimumSize(10, 22);
qButton->setSizePolicy(QSizePolicy::Minimum, QSizePolicy::Minimum);
break;
case QButton::RoundRect:
case QButton::Recessed:
qButton->setMinimumWidth(16);
qButton->setFixedHeight(18);
qButton->setSizePolicy(QSizePolicy::Minimum, QSizePolicy::Fixed);
break;
case QButton::Disclosure:
qButton->setMinimumWidth(13);
qButton->setFixedHeight(13);
qButton->setSizePolicy(QSizePolicy::Minimum, QSizePolicy::Fixed);
break;
case QButton::Circular:
qButton->setMinimumSize(16, 16);
qButton->setMaximumHeight(40);
qButton->setSizePolicy(QSizePolicy::Minimum, QSizePolicy::Minimum);
break;
case QButton::HelpButton:
case QButton::RoundedDisclosure:
qButton->setMinimumWidth(22);
qButton->setFixedHeight(22);
qButton->setSizePolicy(QSizePolicy::Minimum, QSizePolicy::Fixed);
break;
#ifdef MAC_OS_X_VERSION_10_7
case QButton::Inline:
qButton->setMinimumWidth(10);
qButton->setFixedHeight(16);
qButton->setSizePolicy(QSizePolicy::Minimum, QSizePolicy::Fixed);
break;
#endif
}
switch(bezelStyle) {
case QButton::Recessed:
[nsButton setButtonType:NSPushOnPushOffButton];
case QButton::Disclosure:
[nsButton setButtonType:NSOnOffButton];
default:
[nsButton setButtonType:NSMomentaryPushInButton];
}
[nsButton setBezelStyle:bezelStyle];
}
void clicked()
{
emit qButton->clicked(qButton->isChecked());
}
~QButtonPrivate() {
[[nsButton target] release];
[nsButton setTarget:nil];
}
QButton *qButton;
NSButton *nsButton;
};
@interface QButtonTarget : NSObject
{
@public
QPointer<QButtonPrivate> pimpl;
}
-(void)clicked;
@end
@implementation QButtonTarget
-(void)clicked {
Q_ASSERT(pimpl);
if (pimpl)
pimpl->clicked();
}
@end
QButton::QButton(QWidget *parent, BezelStyle bezelStyle) : QWidget(parent)
{
NSAutoreleasePool *pool = [[NSAutoreleasePool alloc] init];
NSButton *button = [[NSButton alloc] init];
pimpl = new QButtonPrivate(this, button, bezelStyle);
QButtonTarget *target = [[QButtonTarget alloc] init];
target->pimpl = pimpl;
[button setTarget:target];
[button setAction:@selector(clicked)];
setupLayout(button, this);
[button release];
[pool drain];
}
void QButton::setText(const QString &text)
{
Q_ASSERT(pimpl);
if (!pimpl)
return;
NSAutoreleasePool *pool = [[NSAutoreleasePool alloc] init];
[pimpl->nsButton setTitle:fromQString(text)];
[pool drain];
}
void QButton::setImage(const QPixmap &image)
{
Q_ASSERT(pimpl);
if (pimpl)
[pimpl->nsButton setImage:fromQPixmap(image)];
}
void QButton::setChecked(bool checked)
{
Q_ASSERT(pimpl);
if (pimpl)
[pimpl->nsButton setState:checked];
}
void QButton::setCheckable(bool checkable)
{
const NSInteger cellMask = checkable ? NSChangeBackgroundCellMask : NSNoCellMask;
Q_ASSERT(pimpl);
if (pimpl)
[[pimpl->nsButton cell] setShowsStateBy:cellMask];
}
bool QButton::isChecked()
{
Q_ASSERT(pimpl);
if (!pimpl)
return false;
return [pimpl->nsButton state];
}

View File

@@ -1,96 +0,0 @@
/*
Copyright (C) 2011 by Mike McQuaid
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in
all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
THE SOFTWARE.
*/
#include <QtGlobal>
#include <QObject>
#include <QWidget>
#include <QPointer>
#include <QString>
#include <QPixmap>
#include <QAbstractButton>
#include <QBoxLayout>
#include <QPushButton>
#include <QToolBar>
#include <QToolButton>
#include "qbutton.h"
class QButtonPrivate : public QObject
{
public:
QButtonPrivate(QButton *button, QAbstractButton *abstractButton)
: QObject(button), abstractButton(abstractButton) {}
QPointer<QAbstractButton> abstractButton;
};
QButton::QButton(QWidget *parent, BezelStyle) : QWidget(parent)
{
QAbstractButton *button = 0;
if (qobject_cast<QToolBar*>(parent))
button = new QToolButton(this);
else
button = new QPushButton(this);
connect(button, SIGNAL(clicked()),
this, SIGNAL(clicked()));
pimpl = new QButtonPrivate(this, button);
QVBoxLayout *layout = new QVBoxLayout(this);
layout->setMargin(0);
layout->addWidget(button);
}
void QButton::setText(const QString &text)
{
Q_ASSERT(pimpl);
if (pimpl)
pimpl->abstractButton->setText(text);
}
void QButton::setImage(const QPixmap &image)
{
Q_ASSERT(pimpl);
if (pimpl)
pimpl->abstractButton->setIcon(image);
}
void QButton::setChecked(bool checked)
{
Q_ASSERT(pimpl);
if (pimpl)
pimpl->abstractButton->setChecked(checked);
}
void QButton::setCheckable(bool checkable)
{
Q_ASSERT(pimpl);
if (pimpl)
pimpl->abstractButton->setCheckable(checkable);
}
bool QButton::isChecked()
{
Q_ASSERT(pimpl);
if (!pimpl)
return false;
return pimpl->abstractButton->isChecked();
}

View File

@@ -1,28 +0,0 @@
#ifndef QPROGRESSINDICATORSPINNING_H
#define QPROGRESSINDICATORSPINNING_H
#include <QWidget>
#include <QPointer>
class QProgressIndicatorSpinningPrivate;
class QProgressIndicatorSpinning : public QWidget
{
Q_OBJECT
public:
// Matches NSProgressIndicatorThickness
enum Thickness {
Default = 14,
Small = 10,
Large = 18,
Aqua = 12
};
explicit QProgressIndicatorSpinning(QWidget *parent, Thickness thickness = Default);
public slots:
void animate(bool animate = true);
private:
friend class QProgressIndicatorSpinningPrivate;
QPointer<QProgressIndicatorSpinningPrivate> pimpl;
};
#endif // QPROGRESSINDICATORSPINNING_H

View File

@@ -1,70 +0,0 @@
/*
Copyright (C) 2011 by Mike McQuaid
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in
all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
THE SOFTWARE.
*/
#include "qprogressindicatorspinning.h"
#include "qocoa_mac.h"
#import "Foundation/NSAutoreleasePool.h"
#import "AppKit/NSProgressIndicator.h"
class QProgressIndicatorSpinningPrivate : public QObject
{
public:
QProgressIndicatorSpinningPrivate(QProgressIndicatorSpinning *qProgressIndicatorSpinning,
NSProgressIndicator *nsProgressIndicator)
: QObject(qProgressIndicatorSpinning), nsProgressIndicator(nsProgressIndicator) {}
NSProgressIndicator *nsProgressIndicator;
};
QProgressIndicatorSpinning::QProgressIndicatorSpinning(QWidget *parent,
Thickness thickness)
: QWidget(parent)
{
NSAutoreleasePool *pool = [[NSAutoreleasePool alloc] init];
NSProgressIndicator *progress = [[NSProgressIndicator alloc] init];
[progress setStyle:NSProgressIndicatorSpinningStyle];
pimpl = new QProgressIndicatorSpinningPrivate(this, progress);
setupLayout(progress, this);
setFixedSize(thickness, thickness);
[progress release];
[pool drain];
}
void QProgressIndicatorSpinning::animate(bool animate)
{
Q_ASSERT(pimpl);
if (!pimpl)
return;
if (animate)
[pimpl->nsProgressIndicator startAnimation:nil];
else
[pimpl->nsProgressIndicator stopAnimation:nil];
}

View File

@@ -1,77 +0,0 @@
/*
Copyright (C) 2011 by Mike McQuaid
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in
all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
THE SOFTWARE.
*/
#include <QtGlobal>
#include <QObject>
#include <QWidget>
#include <QBoxLayout>
#include <QLabel>
#include <QMovie>
#include <QPointer>
#include <QSize>
#include "qprogressindicatorspinning.h"
class QProgressIndicatorSpinningPrivate : public QObject
{
public:
QProgressIndicatorSpinningPrivate(QProgressIndicatorSpinning *qProgressIndicatorSpinning,
QMovie *movie)
: QObject(qProgressIndicatorSpinning), movie(movie) {}
QPointer<QMovie> movie;
};
QProgressIndicatorSpinning::QProgressIndicatorSpinning(QWidget *parent,
Thickness thickness)
: QWidget(parent)
{
QVBoxLayout *layout = new QVBoxLayout(this);
layout->setMargin(0);
QSize size(thickness, thickness);
QMovie *movie = new QMovie(this);
movie->setFileName(":/Qocoa/qprogressindicatorspinning_nonmac.gif");
movie->setScaledSize(size);
// Roughly match OSX speed.
movie->setSpeed(200);
pimpl = new QProgressIndicatorSpinningPrivate(this, movie);
QLabel *label = new QLabel(this);
label->setMovie(movie);
layout->addWidget(label);
setFixedSize(size);
}
void QProgressIndicatorSpinning::animate(bool animate)
{
Q_ASSERT(pimpl && pimpl->movie);
if (!(pimpl && pimpl->movie))
return;
if (animate)
pimpl->movie->start();
else
pimpl->movie->stop();
}

Binary file not shown.

Before

Width:  |  Height:  |  Size: 3.1 KiB

View File

@@ -1,5 +0,0 @@
<RCC>
<qresource prefix="/Qocoa">
<file>qprogressindicatorspinning_nonmac.gif</file>
</qresource>
</RCC>

View File

@@ -1,45 +0,0 @@
#ifndef QSEARCHFIELD_H
#define QSEARCHFIELD_H
#include <QWidget>
#include <QObject>
#include <QPointer>
#include <QString>
#include <QEvent>
#include <QResizeEvent>
class QSearchFieldPrivate;
class QSearchField : public QWidget
{
Q_OBJECT
public:
explicit QSearchField(QWidget *parent);
QString text() const;
QString placeholderText() const;
void setFocus(Qt::FocusReason reason);
public slots:
void setText(const QString &text);
void setPlaceholderText(const QString &text);
void clear();
void selectAll();
void setFocus();
signals:
void textChanged(const QString &text);
void editingFinished();
void returnPressed();
protected:
void resizeEvent(QResizeEvent*);
bool eventFilter(QObject*, QEvent*);
private:
friend class QSearchFieldPrivate;
QPointer <QSearchFieldPrivate> pimpl;
Q_PROPERTY(QString placeholderText READ placeholderText WRITE setPlaceholderText);
};
#endif // QSEARCHFIELD_H

View File

@@ -1,285 +0,0 @@
/*
Copyright (C) 2011 by Mike McQuaid
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in
all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
THE SOFTWARE.
*/
#include "qsearchfield.h"
#include "qocoa_mac.h"
#import "Foundation/NSAutoreleasePool.h"
#import "Foundation/NSNotification.h"
#import "AppKit/NSSearchField.h"
#include <QApplication>
#include <QClipboard>
#include <QKeyEvent>
class QSearchFieldPrivate : public QObject
{
public:
QSearchFieldPrivate(QSearchField *qSearchField, NSSearchField *nsSearchField)
: QObject(qSearchField), qSearchField(qSearchField), nsSearchField(nsSearchField) {}
void textDidChange(const QString &text)
{
if (qSearchField)
emit qSearchField->textChanged(text);
}
void textDidEndEditing()
{
if (qSearchField)
emit qSearchField->editingFinished();
}
void returnPressed()
{
if (qSearchField) {
emit qSearchField->returnPressed();
QKeyEvent* event = new QKeyEvent(QEvent::KeyPress, Qt::Key_Return, Qt::NoModifier);
QApplication::postEvent(qSearchField, event);
}
}
void keyDownPressed()
{
if (qSearchField) {
QKeyEvent* event = new QKeyEvent(QEvent::KeyPress, Qt::Key_Down, Qt::NoModifier);
QApplication::postEvent(qSearchField, event);
}
}
void keyUpPressed()
{
if (qSearchField) {
QKeyEvent* event = new QKeyEvent(QEvent::KeyPress, Qt::Key_Up, Qt::NoModifier);
QApplication::postEvent(qSearchField, event);
}
}
QPointer<QSearchField> qSearchField;
NSSearchField *nsSearchField;
};
@interface QSearchFieldDelegate : NSObject<NSTextFieldDelegate>
{
@public
QPointer<QSearchFieldPrivate> pimpl;
}
-(void)controlTextDidChange:(NSNotification*)notification;
-(void)controlTextDidEndEditing:(NSNotification*)notification;
@end
@implementation QSearchFieldDelegate
-(void)controlTextDidChange:(NSNotification*)notification {
Q_ASSERT(pimpl);
if (pimpl)
pimpl->textDidChange(toQString([[notification object] stringValue]));
}
-(BOOL)control: (NSControl *)control textView:
(NSTextView *)textView doCommandBySelector:
(SEL)commandSelector {
Q_ASSERT(pimpl);
if (!pimpl) return NO;
if (commandSelector == @selector(moveDown:)) {
pimpl->keyDownPressed();
return YES;
} else if (commandSelector == @selector(moveUp:)) {
pimpl->keyUpPressed();
return YES;
}
return NO;
}
-(void)controlTextDidEndEditing:(NSNotification*)notification {
// No Q_ASSERT here as it is called on destruction.
if (!pimpl) return;
pimpl->textDidEndEditing();
if ([[[notification userInfo] objectForKey:@"NSTextMovement"] intValue] == NSReturnTextMovement)
pimpl->returnPressed();
}
@end
@interface QocoaSearchField : NSSearchField
-(BOOL)performKeyEquivalent:(NSEvent*)event;
@end
@implementation QocoaSearchField
-(BOOL)performKeyEquivalent:(NSEvent*)event {
// First, check if we have the focus.
// If no, it probably means this event isn't for us.
NSResponder* firstResponder = [[NSApp keyWindow] firstResponder];
if ([firstResponder isKindOfClass:[NSText class]] &&
[(NSText*)firstResponder delegate] == self) {
if ([event type] == NSKeyDown && [event modifierFlags] & NSCommandKeyMask)
{
QString keyString = toQString([event characters]);
if (keyString == "a") // Cmd+a
{
[self performSelector:@selector(selectText:)];
return YES;
}
else if (keyString == "c") // Cmd+c
{
[[self currentEditor] copy: nil];
return YES;
}
else if (keyString == "v") // Cmd+v
{
[[self currentEditor] paste: nil];
return YES;
}
else if (keyString == "x") // Cmd+x
{
[[self currentEditor] cut: nil];
return YES;
}
}
}
return NO;
}
@end
QSearchField::QSearchField(QWidget *parent) : QWidget(parent)
{
NSAutoreleasePool *pool = [[NSAutoreleasePool alloc] init];
NSSearchField *search = [[QocoaSearchField alloc] init];
QSearchFieldDelegate *delegate = [[QSearchFieldDelegate alloc] init];
pimpl = delegate->pimpl = new QSearchFieldPrivate(this, search);
[search setDelegate:delegate];
setupLayout(search, this);
setFixedHeight(24);
setSizePolicy(QSizePolicy::Expanding, QSizePolicy::Fixed);
[search release];
[pool drain];
}
void QSearchField::setText(const QString &text)
{
Q_ASSERT(pimpl);
if (!pimpl)
return;
NSAutoreleasePool *pool = [[NSAutoreleasePool alloc] init];
[pimpl->nsSearchField setStringValue:fromQString(text)];
if (!text.isEmpty()) {
[pimpl->nsSearchField selectText:pimpl->nsSearchField];
[[pimpl->nsSearchField currentEditor] setSelectedRange:NSMakeRange([[pimpl->nsSearchField stringValue] length], 0)];
}
[pool drain];
}
void QSearchField::setPlaceholderText(const QString &text)
{
Q_ASSERT(pimpl);
if (!pimpl)
return;
NSAutoreleasePool *pool = [[NSAutoreleasePool alloc] init];
[[pimpl->nsSearchField cell] setPlaceholderString:fromQString(text)];
[pool drain];
}
QString QSearchField::placeholderText() const {
Q_ASSERT(pimpl);
NSString* placeholder = [[pimpl->nsSearchField cell] placeholderString];
return toQString(placeholder);
}
void QSearchField::setFocus(Qt::FocusReason reason)
{
/* Do nothing: we were previously using makeFirstResponder on search field, but
* that resulted in having the text being selected (and I didn't find any way to
* deselect it) which would result in the user erasing the first letter he just
* typed, after using setText (e.g. if the user typed a letter while having
* focus on the playlist, which means we call setText and give focus to the
* search bar).
* Instead now the focus will take place when calling selectText in setText.
* This obviously breaks the purpose of this function, but we never call only
* setFocus on a search box in Clementine (i.e. without a call to setText
* shortly after).
*/
// Q_ASSERT(pimpl);
// if (!pimpl)
// return;
// if ([pimpl->nsSearchField acceptsFirstResponder]) {
// [[pimpl->nsSearchField window] makeFirstResponder: pimpl->nsSearchField];
// }
}
void QSearchField::setFocus()
{
setFocus(Qt::OtherFocusReason);
}
void QSearchField::clear()
{
Q_ASSERT(pimpl);
if (!pimpl)
return;
[pimpl->nsSearchField setStringValue:@""];
emit textChanged(QString());
}
void QSearchField::selectAll()
{
Q_ASSERT(pimpl);
if (!pimpl)
return;
[pimpl->nsSearchField performSelector:@selector(selectText:)];
}
QString QSearchField::text() const
{
Q_ASSERT(pimpl);
if (!pimpl)
return QString();
return toQString([pimpl->nsSearchField stringValue]);
}
void QSearchField::resizeEvent(QResizeEvent *resizeEvent)
{
QWidget::resizeEvent(resizeEvent);
}
bool QSearchField::eventFilter(QObject *o, QEvent *e)
{
return QWidget::eventFilter(o, e);
}

View File

@@ -1,188 +0,0 @@
/*
Copyright (C) 2011 by Mike McQuaid
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in
all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
THE SOFTWARE.
*/
#include <QtGlobal>
#include <QObject>
#include <QWidget>
#include <QApplication>
#include <QPointer>
#include <QString>
#include <QIcon>
#include <QSize>
#include <QStyle>
#include <QLineEdit>
#include <QBoxLayout>
#include <QToolButton>
#include <QtEvents>
#include "../../src/core/iconloader.h"
#include "qsearchfield.h"
class QSearchFieldPrivate : public QObject
{
public:
QSearchFieldPrivate(QSearchField *searchField, QLineEdit *lineEdit, QToolButton *clearButton)
: QObject(searchField), lineEdit(lineEdit), clearButton(clearButton) {}
int lineEditFrameWidth() const {
return lineEdit->style()->pixelMetric(QStyle::PM_DefaultFrameWidth);
}
int clearButtonPaddedWidth() const {
return clearButton->width() + lineEditFrameWidth() * 2;
}
int clearButtonPaddedHeight() const {
return clearButton->height() + lineEditFrameWidth() * 2;
}
QPointer<QLineEdit> lineEdit;
QPointer<QToolButton> clearButton;
};
QSearchField::QSearchField(QWidget *parent) : QWidget(parent)
{
QLineEdit *lineEdit = new QLineEdit(this);
connect(lineEdit, SIGNAL(textChanged(QString)),
this, SIGNAL(textChanged(QString)));
connect(lineEdit, SIGNAL(editingFinished()),
this, SIGNAL(editingFinished()));
connect(lineEdit, SIGNAL(returnPressed()),
this, SIGNAL(returnPressed()));
connect(lineEdit, SIGNAL(textChanged(QString)),
this, SLOT(setText(QString)));
QIcon clearIcon(IconLoader::Load("edit-clear-locationbar-ltr"));
QToolButton *clearButton = new QToolButton(this);
clearButton->setIcon(clearIcon);
clearButton->setIconSize(QSize(16, 16));
clearButton->setStyleSheet("border: none; padding: 0px;");
clearButton->resize(clearButton->sizeHint());
connect(clearButton, SIGNAL(clicked()), this, SLOT(clear()));
pimpl = new QSearchFieldPrivate(this, lineEdit, clearButton);
const int frame_width = lineEdit->style()->pixelMetric(QStyle::PM_DefaultFrameWidth);
lineEdit->setStyleSheet(QString("QLineEdit { padding-left: %1px; } ").arg(clearButton->width()));
const int width = frame_width + qMax(lineEdit->minimumSizeHint().width(), pimpl->clearButtonPaddedWidth());
const int height = frame_width + qMax(lineEdit->minimumSizeHint().height(), pimpl->clearButtonPaddedHeight());
lineEdit->setMinimumSize(width, height);
QVBoxLayout *layout = new QVBoxLayout(this);
layout->setMargin(0);
layout->addWidget(lineEdit);
lineEdit->installEventFilter(this);
}
void QSearchField::setText(const QString &text)
{
Q_ASSERT(pimpl && pimpl->clearButton && pimpl->lineEdit);
if (!(pimpl && pimpl->clearButton && pimpl->lineEdit))
return;
if (text != this->text())
pimpl->lineEdit->setText(text);
}
void QSearchField::setPlaceholderText(const QString &text)
{
Q_ASSERT(pimpl && pimpl->lineEdit);
if (!(pimpl && pimpl->lineEdit))
return;
#if QT_VERSION >= 0x040700
pimpl->lineEdit->setPlaceholderText(text);
#endif
}
QString QSearchField::placeholderText() const {
#if QT_VERSION >= 0x040700
return pimpl->lineEdit->placeholderText();
#else
return QString();
#endif
}
void QSearchField::setFocus(Qt::FocusReason reason)
{
Q_ASSERT(pimpl && pimpl->lineEdit);
if (pimpl && pimpl->lineEdit)
pimpl->lineEdit->setFocus(reason);
}
void QSearchField::setFocus()
{
setFocus(Qt::OtherFocusReason);
}
void QSearchField::clear()
{
Q_ASSERT(pimpl && pimpl->lineEdit);
if (!(pimpl && pimpl->lineEdit))
return;
pimpl->lineEdit->clear();
}
void QSearchField::selectAll()
{
Q_ASSERT(pimpl && pimpl->lineEdit);
if (!(pimpl && pimpl->lineEdit))
return;
pimpl->lineEdit->selectAll();
}
QString QSearchField::text() const
{
Q_ASSERT(pimpl && pimpl->lineEdit);
if (!(pimpl && pimpl->lineEdit))
return QString();
return pimpl->lineEdit->text();
}
void QSearchField::resizeEvent(QResizeEvent *resizeEvent)
{
Q_ASSERT(pimpl && pimpl->clearButton && pimpl->lineEdit);
if (!(pimpl && pimpl->clearButton && pimpl->lineEdit))
return;
QWidget::resizeEvent(resizeEvent);
const int x = pimpl->lineEditFrameWidth();
const int y = (height() - pimpl->clearButton->height())/2;
pimpl->clearButton->move(x, y);
}
bool QSearchField::eventFilter(QObject *o, QEvent *e)
{
if (pimpl && pimpl->lineEdit && o == pimpl->lineEdit) {
// Forward some lineEdit events to QSearchField (only those we need for
// now, but some might be added later if needed)
switch (e->type()) {
case QEvent::FocusIn:
case QEvent::FocusOut:
QApplication::sendEvent(this, e);
break;
}
}
return QWidget::eventFilter(o, e);
}

View File

@@ -1,29 +0,0 @@
cmake_minimum_required(VERSION 2.8.11)
set(CMAKE_CXX_STANDARD 11)
set(SINGLEAPP-SOURCES
qtlocalpeer.cpp
qtsingleapplication.cpp
qtsinglecoreapplication.cpp
)
set(SINGLEAPP-MOC-HEADERS
qtlocalpeer.h
qtsingleapplication.h
qtsinglecoreapplication.h
)
if(WIN32)
set(SINGLEAPP-SOURCES ${SINGLEAPP-SOURCES} qtlockedfile_win.cpp)
elseif(WIN32)
set(SINGLEAPP-SOURCES ${SINGLEAPP-SOURCES} qtlockedfile_unix.cpp)
endif(WIN32)
QT5_WRAP_CPP(SINGLEAPP-SOURCES-MOC ${SINGLEAPP-MOC-HEADERS})
ADD_LIBRARY(qtsingleapplication STATIC
${SINGLEAPP-SOURCES}
${SINGLEAPP-SOURCES-MOC}
)
target_link_libraries(qtsingleapplication Qt5::Core Qt5::Widgets Qt5::Network)

View File

@@ -1,504 +0,0 @@
GNU LESSER GENERAL PUBLIC LICENSE
Version 2.1, February 1999
Copyright (C) 1991, 1999 Free Software Foundation, Inc.
51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
Everyone is permitted to copy and distribute verbatim copies
of this license document, but changing it is not allowed.
[This is the first released version of the Lesser GPL. It also counts
as the successor of the GNU Library Public License, version 2, hence
the version number 2.1.]
Preamble
The licenses for most software are designed to take away your
freedom to share and change it. By contrast, the GNU General Public
Licenses are intended to guarantee your freedom to share and change
free software--to make sure the software is free for all its users.
This license, the Lesser General Public License, applies to some
specially designated software packages--typically libraries--of the
Free Software Foundation and other authors who decide to use it. You
can use it too, but we suggest you first think carefully about whether
this license or the ordinary General Public License is the better
strategy to use in any particular case, based on the explanations below.
When we speak of free software, we are referring to freedom of use,
not price. Our General Public Licenses are designed to make sure that
you have the freedom to distribute copies of free software (and charge
for this service if you wish); that you receive source code or can get
it if you want it; that you can change the software and use pieces of
it in new free programs; and that you are informed that you can do
these things.
To protect your rights, we need to make restrictions that forbid
distributors to deny you these rights or to ask you to surrender these
rights. These restrictions translate to certain responsibilities for
you if you distribute copies of the library or if you modify it.
For example, if you distribute copies of the library, whether gratis
or for a fee, you must give the recipients all the rights that we gave
you. You must make sure that they, too, receive or can get the source
code. If you link other code with the library, you must provide
complete object files to the recipients, so that they can relink them
with the library after making changes to the library and recompiling
it. And you must show them these terms so they know their rights.
We protect your rights with a two-step method: (1) we copyright the
library, and (2) we offer you this license, which gives you legal
permission to copy, distribute and/or modify the library.
To protect each distributor, we want to make it very clear that
there is no warranty for the free library. Also, if the library is
modified by someone else and passed on, the recipients should know
that what they have is not the original version, so that the original
author's reputation will not be affected by problems that might be
introduced by others.
Finally, software patents pose a constant threat to the existence of
any free program. We wish to make sure that a company cannot
effectively restrict the users of a free program by obtaining a
restrictive license from a patent holder. Therefore, we insist that
any patent license obtained for a version of the library must be
consistent with the full freedom of use specified in this license.
Most GNU software, including some libraries, is covered by the
ordinary GNU General Public License. This license, the GNU Lesser
General Public License, applies to certain designated libraries, and
is quite different from the ordinary General Public License. We use
this license for certain libraries in order to permit linking those
libraries into non-free programs.
When a program is linked with a library, whether statically or using
a shared library, the combination of the two is legally speaking a
combined work, a derivative of the original library. The ordinary
General Public License therefore permits such linking only if the
entire combination fits its criteria of freedom. The Lesser General
Public License permits more lax criteria for linking other code with
the library.
We call this license the "Lesser" General Public License because it
does Less to protect the user's freedom than the ordinary General
Public License. It also provides other free software developers Less
of an advantage over competing non-free programs. These disadvantages
are the reason we use the ordinary General Public License for many
libraries. However, the Lesser license provides advantages in certain
special circumstances.
For example, on rare occasions, there may be a special need to
encourage the widest possible use of a certain library, so that it becomes
a de-facto standard. To achieve this, non-free programs must be
allowed to use the library. A more frequent case is that a free
library does the same job as widely used non-free libraries. In this
case, there is little to gain by limiting the free library to free
software only, so we use the Lesser General Public License.
In other cases, permission to use a particular library in non-free
programs enables a greater number of people to use a large body of
free software. For example, permission to use the GNU C Library in
non-free programs enables many more people to use the whole GNU
operating system, as well as its variant, the GNU/Linux operating
system.
Although the Lesser General Public License is Less protective of the
users' freedom, it does ensure that the user of a program that is
linked with the Library has the freedom and the wherewithal to run
that program using a modified version of the Library.
The precise terms and conditions for copying, distribution and
modification follow. Pay close attention to the difference between a
"work based on the library" and a "work that uses the library". The
former contains code derived from the library, whereas the latter must
be combined with the library in order to run.
GNU LESSER GENERAL PUBLIC LICENSE
TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION
0. This License Agreement applies to any software library or other
program which contains a notice placed by the copyright holder or
other authorized party saying it may be distributed under the terms of
this Lesser General Public License (also called "this License").
Each licensee is addressed as "you".
A "library" means a collection of software functions and/or data
prepared so as to be conveniently linked with application programs
(which use some of those functions and data) to form executables.
The "Library", below, refers to any such software library or work
which has been distributed under these terms. A "work based on the
Library" means either the Library or any derivative work under
copyright law: that is to say, a work containing the Library or a
portion of it, either verbatim or with modifications and/or translated
straightforwardly into another language. (Hereinafter, translation is
included without limitation in the term "modification".)
"Source code" for a work means the preferred form of the work for
making modifications to it. For a library, complete source code means
all the source code for all modules it contains, plus any associated
interface definition files, plus the scripts used to control compilation
and installation of the library.
Activities other than copying, distribution and modification are not
covered by this License; they are outside its scope. The act of
running a program using the Library is not restricted, and output from
such a program is covered only if its contents constitute a work based
on the Library (independent of the use of the Library in a tool for
writing it). Whether that is true depends on what the Library does
and what the program that uses the Library does.
1. You may copy and distribute verbatim copies of the Library's
complete source code as you receive it, in any medium, provided that
you conspicuously and appropriately publish on each copy an
appropriate copyright notice and disclaimer of warranty; keep intact
all the notices that refer to this License and to the absence of any
warranty; and distribute a copy of this License along with the
Library.
You may charge a fee for the physical act of transferring a copy,
and you may at your option offer warranty protection in exchange for a
fee.
2. You may modify your copy or copies of the Library or any portion
of it, thus forming a work based on the Library, and copy and
distribute such modifications or work under the terms of Section 1
above, provided that you also meet all of these conditions:
a) The modified work must itself be a software library.
b) You must cause the files modified to carry prominent notices
stating that you changed the files and the date of any change.
c) You must cause the whole of the work to be licensed at no
charge to all third parties under the terms of this License.
d) If a facility in the modified Library refers to a function or a
table of data to be supplied by an application program that uses
the facility, other than as an argument passed when the facility
is invoked, then you must make a good faith effort to ensure that,
in the event an application does not supply such function or
table, the facility still operates, and performs whatever part of
its purpose remains meaningful.
(For example, a function in a library to compute square roots has
a purpose that is entirely well-defined independent of the
application. Therefore, Subsection 2d requires that any
application-supplied function or table used by this function must
be optional: if the application does not supply it, the square
root function must still compute square roots.)
These requirements apply to the modified work as a whole. If
identifiable sections of that work are not derived from the Library,
and can be reasonably considered independent and separate works in
themselves, then this License, and its terms, do not apply to those
sections when you distribute them as separate works. But when you
distribute the same sections as part of a whole which is a work based
on the Library, the distribution of the whole must be on the terms of
this License, whose permissions for other licensees extend to the
entire whole, and thus to each and every part regardless of who wrote
it.
Thus, it is not the intent of this section to claim rights or contest
your rights to work written entirely by you; rather, the intent is to
exercise the right to control the distribution of derivative or
collective works based on the Library.
In addition, mere aggregation of another work not based on the Library
with the Library (or with a work based on the Library) on a volume of
a storage or distribution medium does not bring the other work under
the scope of this License.
3. You may opt to apply the terms of the ordinary GNU General Public
License instead of this License to a given copy of the Library. To do
this, you must alter all the notices that refer to this License, so
that they refer to the ordinary GNU General Public License, version 2,
instead of to this License. (If a newer version than version 2 of the
ordinary GNU General Public License has appeared, then you can specify
that version instead if you wish.) Do not make any other change in
these notices.
Once this change is made in a given copy, it is irreversible for
that copy, so the ordinary GNU General Public License applies to all
subsequent copies and derivative works made from that copy.
This option is useful when you wish to copy part of the code of
the Library into a program that is not a library.
4. You may copy and distribute the Library (or a portion or
derivative of it, under Section 2) in object code or executable form
under the terms of Sections 1 and 2 above provided that you accompany
it with the complete corresponding machine-readable source code, which
must be distributed under the terms of Sections 1 and 2 above on a
medium customarily used for software interchange.
If distribution of object code is made by offering access to copy
from a designated place, then offering equivalent access to copy the
source code from the same place satisfies the requirement to
distribute the source code, even though third parties are not
compelled to copy the source along with the object code.
5. A program that contains no derivative of any portion of the
Library, but is designed to work with the Library by being compiled or
linked with it, is called a "work that uses the Library". Such a
work, in isolation, is not a derivative work of the Library, and
therefore falls outside the scope of this License.
However, linking a "work that uses the Library" with the Library
creates an executable that is a derivative of the Library (because it
contains portions of the Library), rather than a "work that uses the
library". The executable is therefore covered by this License.
Section 6 states terms for distribution of such executables.
When a "work that uses the Library" uses material from a header file
that is part of the Library, the object code for the work may be a
derivative work of the Library even though the source code is not.
Whether this is true is especially significant if the work can be
linked without the Library, or if the work is itself a library. The
threshold for this to be true is not precisely defined by law.
If such an object file uses only numerical parameters, data
structure layouts and accessors, and small macros and small inline
functions (ten lines or less in length), then the use of the object
file is unrestricted, regardless of whether it is legally a derivative
work. (Executables containing this object code plus portions of the
Library will still fall under Section 6.)
Otherwise, if the work is a derivative of the Library, you may
distribute the object code for the work under the terms of Section 6.
Any executables containing that work also fall under Section 6,
whether or not they are linked directly with the Library itself.
6. As an exception to the Sections above, you may also combine or
link a "work that uses the Library" with the Library to produce a
work containing portions of the Library, and distribute that work
under terms of your choice, provided that the terms permit
modification of the work for the customer's own use and reverse
engineering for debugging such modifications.
You must give prominent notice with each copy of the work that the
Library is used in it and that the Library and its use are covered by
this License. You must supply a copy of this License. If the work
during execution displays copyright notices, you must include the
copyright notice for the Library among them, as well as a reference
directing the user to the copy of this License. Also, you must do one
of these things:
a) Accompany the work with the complete corresponding
machine-readable source code for the Library including whatever
changes were used in the work (which must be distributed under
Sections 1 and 2 above); and, if the work is an executable linked
with the Library, with the complete machine-readable "work that
uses the Library", as object code and/or source code, so that the
user can modify the Library and then relink to produce a modified
executable containing the modified Library. (It is understood
that the user who changes the contents of definitions files in the
Library will not necessarily be able to recompile the application
to use the modified definitions.)
b) Use a suitable shared library mechanism for linking with the
Library. A suitable mechanism is one that (1) uses at run time a
copy of the library already present on the user's computer system,
rather than copying library functions into the executable, and (2)
will operate properly with a modified version of the library, if
the user installs one, as long as the modified version is
interface-compatible with the version that the work was made with.
c) Accompany the work with a written offer, valid for at
least three years, to give the same user the materials
specified in Subsection 6a, above, for a charge no more
than the cost of performing this distribution.
d) If distribution of the work is made by offering access to copy
from a designated place, offer equivalent access to copy the above
specified materials from the same place.
e) Verify that the user has already received a copy of these
materials or that you have already sent this user a copy.
For an executable, the required form of the "work that uses the
Library" must include any data and utility programs needed for
reproducing the executable from it. However, as a special exception,
the materials to be distributed need not include anything that is
normally distributed (in either source or binary form) with the major
components (compiler, kernel, and so on) of the operating system on
which the executable runs, unless that component itself accompanies
the executable.
It may happen that this requirement contradicts the license
restrictions of other proprietary libraries that do not normally
accompany the operating system. Such a contradiction means you cannot
use both them and the Library together in an executable that you
distribute.
7. You may place library facilities that are a work based on the
Library side-by-side in a single library together with other library
facilities not covered by this License, and distribute such a combined
library, provided that the separate distribution of the work based on
the Library and of the other library facilities is otherwise
permitted, and provided that you do these two things:
a) Accompany the combined library with a copy of the same work
based on the Library, uncombined with any other library
facilities. This must be distributed under the terms of the
Sections above.
b) Give prominent notice with the combined library of the fact
that part of it is a work based on the Library, and explaining
where to find the accompanying uncombined form of the same work.
8. You may not copy, modify, sublicense, link with, or distribute
the Library except as expressly provided under this License. Any
attempt otherwise to copy, modify, sublicense, link with, or
distribute the Library is void, and will automatically terminate your
rights under this License. However, parties who have received copies,
or rights, from you under this License will not have their licenses
terminated so long as such parties remain in full compliance.
9. You are not required to accept this License, since you have not
signed it. However, nothing else grants you permission to modify or
distribute the Library or its derivative works. These actions are
prohibited by law if you do not accept this License. Therefore, by
modifying or distributing the Library (or any work based on the
Library), you indicate your acceptance of this License to do so, and
all its terms and conditions for copying, distributing or modifying
the Library or works based on it.
10. Each time you redistribute the Library (or any work based on the
Library), the recipient automatically receives a license from the
original licensor to copy, distribute, link with or modify the Library
subject to these terms and conditions. You may not impose any further
restrictions on the recipients' exercise of the rights granted herein.
You are not responsible for enforcing compliance by third parties with
this License.
11. If, as a consequence of a court judgment or allegation of patent
infringement or for any other reason (not limited to patent issues),
conditions are imposed on you (whether by court order, agreement or
otherwise) that contradict the conditions of this License, they do not
excuse you from the conditions of this License. If you cannot
distribute so as to satisfy simultaneously your obligations under this
License and any other pertinent obligations, then as a consequence you
may not distribute the Library at all. For example, if a patent
license would not permit royalty-free redistribution of the Library by
all those who receive copies directly or indirectly through you, then
the only way you could satisfy both it and this License would be to
refrain entirely from distribution of the Library.
If any portion of this section is held invalid or unenforceable under any
particular circumstance, the balance of the section is intended to apply,
and the section as a whole is intended to apply in other circumstances.
It is not the purpose of this section to induce you to infringe any
patents or other property right claims or to contest validity of any
such claims; this section has the sole purpose of protecting the
integrity of the free software distribution system which is
implemented by public license practices. Many people have made
generous contributions to the wide range of software distributed
through that system in reliance on consistent application of that
system; it is up to the author/donor to decide if he or she is willing
to distribute software through any other system and a licensee cannot
impose that choice.
This section is intended to make thoroughly clear what is believed to
be a consequence of the rest of this License.
12. If the distribution and/or use of the Library is restricted in
certain countries either by patents or by copyrighted interfaces, the
original copyright holder who places the Library under this License may add
an explicit geographical distribution limitation excluding those countries,
so that distribution is permitted only in or among countries not thus
excluded. In such case, this License incorporates the limitation as if
written in the body of this License.
13. The Free Software Foundation may publish revised and/or new
versions of the Lesser General Public License from time to time.
Such new versions will be similar in spirit to the present version,
but may differ in detail to address new problems or concerns.
Each version is given a distinguishing version number. If the Library
specifies a version number of this License which applies to it and
"any later version", you have the option of following the terms and
conditions either of that version or of any later version published by
the Free Software Foundation. If the Library does not specify a
license version number, you may choose any version ever published by
the Free Software Foundation.
14. If you wish to incorporate parts of the Library into other free
programs whose distribution conditions are incompatible with these,
write to the author to ask for permission. For software which is
copyrighted by the Free Software Foundation, write to the Free
Software Foundation; we sometimes make exceptions for this. Our
decision will be guided by the two goals of preserving the free status
of all derivatives of our free software and of promoting the sharing
and reuse of software generally.
NO WARRANTY
15. BECAUSE THE LIBRARY IS LICENSED FREE OF CHARGE, THERE IS NO
WARRANTY FOR THE LIBRARY, TO THE EXTENT PERMITTED BY APPLICABLE LAW.
EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR
OTHER PARTIES PROVIDE THE LIBRARY "AS IS" WITHOUT WARRANTY OF ANY
KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE
IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE
LIBRARY IS WITH YOU. SHOULD THE LIBRARY PROVE DEFECTIVE, YOU ASSUME
THE COST OF ALL NECESSARY SERVICING, REPAIR OR CORRECTION.
16. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN
WRITING WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY
AND/OR REDISTRIBUTE THE LIBRARY AS PERMITTED ABOVE, BE LIABLE TO YOU
FOR DAMAGES, INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR
CONSEQUENTIAL DAMAGES ARISING OUT OF THE USE OR INABILITY TO USE THE
LIBRARY (INCLUDING BUT NOT LIMITED TO LOSS OF DATA OR DATA BEING
RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD PARTIES OR A
FAILURE OF THE LIBRARY TO OPERATE WITH ANY OTHER SOFTWARE), EVEN IF
SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH
DAMAGES.
END OF TERMS AND CONDITIONS
How to Apply These Terms to Your New Libraries
If you develop a new library, and you want it to be of the greatest
possible use to the public, we recommend making it free software that
everyone can redistribute and change. You can do so by permitting
redistribution under these terms (or, alternatively, under the terms of the
ordinary General Public License).
To apply these terms, attach the following notices to the library. It is
safest to attach them to the start of each source file to most effectively
convey the exclusion of warranty; and each file should have at least the
"copyright" line and a pointer to where the full notice is found.
<one line to give the library's name and a brief idea of what it does.>
Copyright (C) <year> <name of author>
This library is free software; you can redistribute it and/or
modify it under the terms of the GNU Lesser General Public
License as published by the Free Software Foundation; either
version 2.1 of the License, or (at your option) any later version.
This library 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
Lesser General Public License for more details.
You should have received a copy of the GNU Lesser General Public
License along with this library; if not, write to the Free Software
Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
Also add information on how to contact you by electronic and paper mail.
You should also get your employer (if you work as a programmer) or your
school, if any, to sign a "copyright disclaimer" for the library, if
necessary. Here is a sample; alter the names:
Yoyodyne, Inc., hereby disclaims all copyright interest in the
library `Frob' (a library for tweaking knobs) written by James Random Hacker.
<signature of Ty Coon>, 1 April 1990
Ty Coon, President of Vice
That's all there is to it!

View File

@@ -1,210 +0,0 @@
/****************************************************************************
**
** Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies).
** All rights reserved.
**
** Contact: Nokia Corporation (qt-info@nokia.com)
**
** This file is part of a Qt Solutions component.
**
** You may use this file under the terms of the BSD license as follows:
**
** "Redistribution and use in source and binary forms, with or without
** modification, are permitted provided that the following conditions are
** met:
** * Redistributions of source code must retain the above copyright
** notice, this list of conditions and the following disclaimer.
** * Redistributions in binary form must reproduce the above copyright
** notice, this list of conditions and the following disclaimer in
** the documentation and/or other materials provided with the
** distribution.
** * Neither the name of Nokia Corporation and its Subsidiary(-ies) nor
** the names of its contributors may be used to endorse or promote
** products derived from this software without specific prior written
** permission.
**
** THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
** "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
** LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
** A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
** OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
** SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
** LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
** DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
** THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
** (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
** OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE."
**
****************************************************************************/
#include "qtlocalpeer.h"
#include <unistd.h>
#include <QtGlobal>
#include <QCoreApplication>
#include <QObject>
#include <QAbstractSocket>
#include <QByteArray>
#include <QChar>
#include <QDataStream>
#include <QDir>
#include <QFile>
#include <QIODevice>
#include <QLocalServer>
#include <QLocalSocket>
#include <QRegExp>
#if defined(Q_OS_WIN)
#include <qt_windows.h>
#include <QLibrary>
typedef BOOL(WINAPI*PProcessIdToSessionId)(DWORD,DWORD*);
static PProcessIdToSessionId pProcessIdToSessionId = 0;
#endif
#if defined(Q_OS_UNIX)
#include <time.h>
#endif
#include "qtlockedfile.cpp"
#if defined(Q_OS_WIN)
#include "qtlockedfile_win.cpp"
#else
#include "qtlockedfile_unix.cpp"
#endif
const char* QtLocalPeer::ack = "ack";
QtLocalPeer::QtLocalPeer(QObject* parent, const QString &appId)
: QObject(parent), id(appId)
{
QString prefix = id;
if (id.isEmpty()) {
id = QCoreApplication::applicationFilePath();
#if defined(Q_OS_WIN)
id = id.toLower();
#endif
prefix = id.section(QLatin1Char('/'), -1);
}
prefix.remove(QRegExp("[^a-zA-Z]"));
prefix.truncate(6);
QByteArray idc = id.toUtf8();
quint16 idNum = qChecksum(idc.constData(), idc.size());
socketName = QLatin1String("qtsingleapp-") + prefix + QLatin1Char('-') + QString::number(idNum, 16);
#if defined(Q_OS_WIN)
if (!pProcessIdToSessionId) {
QLibrary lib("kernel32");
pProcessIdToSessionId = (PProcessIdToSessionId)lib.resolve("ProcessIdToSessionId");
}
if (pProcessIdToSessionId) {
DWORD sessionId = 0;
pProcessIdToSessionId(GetCurrentProcessId(), &sessionId);
socketName += QLatin1Char('-') + QString::number(sessionId, 16);
}
#else
socketName += QLatin1Char('-') + QString::number(::getuid(), 16);
#endif
server = new QLocalServer(this);
QString lockName = QDir(QDir::tempPath()).absolutePath() + QLatin1Char('/') + socketName + QLatin1String("-lockfile");
lockFile.setFileName(lockName);
lockFile.open(QIODevice::ReadWrite);
}
bool QtLocalPeer::isClient()
{
if (lockFile.isLocked())
return false;
if (!lockFile.lock(QtLockedFile::WriteLock, false))
return true;
bool res = server->listen(socketName);
#if defined(Q_OS_UNIX) && (QT_VERSION >= QT_VERSION_CHECK(4,5,0))
// ### Workaround
if (!res && server->serverError() == QAbstractSocket::AddressInUseError) {
QFile::remove(QDir::cleanPath(QDir::tempPath())+QLatin1Char('/')+socketName);
res = server->listen(socketName);
}
#endif
if (!res)
qWarning("QtSingleCoreApplication: listen on local socket failed, %s", qPrintable(server->errorString()));
QObject::connect(server, SIGNAL(newConnection()), SLOT(receiveConnection()));
return false;
}
bool QtLocalPeer::sendMessage(const QString &message, int timeout)
{
if (!isClient())
return false;
QLocalSocket socket;
bool connOk = false;
for(int i = 0; i < 2; i++) {
// Try twice, in case the other instance is just starting up
socket.connectToServer(socketName);
connOk = socket.waitForConnected(timeout/2);
if (connOk || i)
break;
int ms = 250;
#if defined(Q_OS_WIN)
Sleep(DWORD(ms));
#else
struct timespec ts = { ms / 1000, (ms % 1000) * 1000 * 1000 };
nanosleep(&ts, NULL);
#endif
}
if (!connOk)
return false;
QByteArray uMsg(message.toUtf8());
QDataStream ds(&socket);
ds.writeBytes(uMsg.constData(), uMsg.size());
bool res = socket.waitForBytesWritten(timeout);
if (res) {
res &= socket.waitForReadyRead(timeout); // wait for ack
if (res)
res &= (socket.read(qstrlen(ack)) == ack);
}
return res;
}
void QtLocalPeer::receiveConnection()
{
QLocalSocket* socket = server->nextPendingConnection();
if (!socket)
return;
while (socket->bytesAvailable() < (int)sizeof(quint32))
socket->waitForReadyRead();
QDataStream ds(socket);
QByteArray uMsg;
quint32 remaining;
ds >> remaining;
uMsg.resize(remaining);
int got = 0;
char* uMsgBuf = uMsg.data();
do {
got = ds.readRawData(uMsgBuf, remaining);
remaining -= got;
uMsgBuf += got;
}
while (remaining && got >= 0 && socket->waitForReadyRead(2000));
if (got < 0) {
qWarning("QtLocalPeer: Message reception failed %s", socket->errorString().toLatin1().constData());
delete socket;
return;
}
QString message(QString::fromUtf8(uMsg));
socket->write(ack, qstrlen(ack));
socket->waitForBytesWritten(1000);
delete socket;
emit messageReceived(message); //### (might take a long time to return)
}

View File

@@ -1,76 +0,0 @@
/****************************************************************************
**
** Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies).
** All rights reserved.
**
** Contact: Nokia Corporation (qt-info@nokia.com)
**
** This file is part of a Qt Solutions component.
**
** You may use this file under the terms of the BSD license as follows:
**
** "Redistribution and use in source and binary forms, with or without
** modification, are permitted provided that the following conditions are
** met:
** * Redistributions of source code must retain the above copyright
** notice, this list of conditions and the following disclaimer.
** * Redistributions in binary form must reproduce the above copyright
** notice, this list of conditions and the following disclaimer in
** the documentation and/or other materials provided with the
** distribution.
** * Neither the name of Nokia Corporation and its Subsidiary(-ies) nor
** the names of its contributors may be used to endorse or promote
** products derived from this software without specific prior written
** permission.
**
** THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
** "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
** LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
** A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
** OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
** SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
** LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
** DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
** THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
** (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
** OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE."
**
****************************************************************************/
#ifndef QTLOCALPEER_H
#define QTLOCALPEER_H
#include <QObject>
#include <QString>
#include <QLocalServer>
#include "qtlockedfile.h"
class QtLocalPeer : public QObject
{
Q_OBJECT
public:
QtLocalPeer(QObject *parent = 0, const QString &appId = QString());
bool isClient();
bool sendMessage(const QString &message, int timeout);
QString applicationId() const
{ return id; }
Q_SIGNALS:
void messageReceived(const QString &message);
protected Q_SLOTS:
void receiveConnection();
protected:
QString id;
QString socketName;
QLocalServer *server;
QtLockedFile lockFile;
private:
static const char* ack;
};
#endif // QTLOCALPEER_H

View File

@@ -1,195 +0,0 @@
/****************************************************************************
**
** Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies).
** All rights reserved.
**
** Contact: Nokia Corporation (qt-info@nokia.com)
**
** This file is part of a Qt Solutions component.
**
** You may use this file under the terms of the BSD license as follows:
**
** "Redistribution and use in source and binary forms, with or without
** modification, are permitted provided that the following conditions are
** met:
** * Redistributions of source code must retain the above copyright
** notice, this list of conditions and the following disclaimer.
** * Redistributions in binary form must reproduce the above copyright
** notice, this list of conditions and the following disclaimer in
** the documentation and/or other materials provided with the
** distribution.
** * Neither the name of Nokia Corporation and its Subsidiary(-ies) nor
** the names of its contributors may be used to endorse or promote
** products derived from this software without specific prior written
** permission.
**
** THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
** "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
** LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
** A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
** OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
** SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
** LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
** DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
** THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
** (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
** OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE."
**
****************************************************************************/
#include <QFile>
#include <QString>
#include "qtlockedfile.h"
/*!
\class QtLockedFile
\brief The QtLockedFile class extends QFile with advisory locking
functions.
A file may be locked in read or write mode. Multiple instances of
\e QtLockedFile, created in multiple processes running on the same
machine, may have a file locked in read mode. Exactly one instance
may have it locked in write mode. A read and a write lock cannot
exist simultaneously on the same file.
The file locks are advisory. This means that nothing prevents
another process from manipulating a locked file using QFile or
file system functions offered by the OS. Serialization is only
guaranteed if all processes that access the file use
QLockedFile. Also, while holding a lock on a file, a process
must not open the same file again (through any API), or locks
can be unexpectedly lost.
The lock provided by an instance of \e QtLockedFile is released
whenever the program terminates. This is true even when the
program crashes and no destructors are called.
*/
/*! \enum QtLockedFile::LockMode
This enum describes the available lock modes.
\value ReadLock A read lock.
\value WriteLock A write lock.
\value NoLock Neither a read lock nor a write lock.
*/
/*!
Constructs an unlocked \e QtLockedFile object. This constructor
behaves in the same way as \e QFile::QFile().
\sa QFile::QFile()
*/
QtLockedFile::QtLockedFile()
: QFile()
{
#ifdef Q_OS_WIN
wmutex = 0;
rmutex = 0;
#endif
m_lock_mode = NoLock;
}
/*!
Constructs an unlocked QtLockedFile object with file \a name. This
constructor behaves in the same way as \e QFile::QFile(const
QString&).
\sa QFile::QFile()
*/
QtLockedFile::QtLockedFile(const QString &name)
: QFile(name)
{
#ifdef Q_OS_WIN
wmutex = 0;
rmutex = 0;
#endif
m_lock_mode = NoLock;
}
/*!
Opens the file in OpenMode \a mode.
This is identical to QFile::open(), with the one exception that the
Truncate mode flag is disallowed. Truncation would conflict with the
advisory file locking, since the file would be modified before the
write lock is obtained. If truncation is required, use resize(0)
after obtaining the write lock.
Returns true if successful; otherwise false.
\sa QFile::open(), QFile::resize()
*/
bool QtLockedFile::open(OpenMode mode)
{
if (mode & QIODevice::Truncate) {
qWarning("QtLockedFile::open(): Truncate mode not allowed.");
return false;
}
return QFile::open(mode);
}
/*!
Returns \e true if this object has a in read or write lock;
otherwise returns \e false.
\sa lockMode()
*/
bool QtLockedFile::isLocked() const
{
return m_lock_mode != NoLock;
}
/*!
Returns the type of lock currently held by this object, or \e
QtLockedFile::NoLock.
\sa isLocked()
*/
QtLockedFile::LockMode QtLockedFile::lockMode() const
{
return m_lock_mode;
}
/*!
\fn bool QtLockedFile::lock(LockMode mode, bool block = true)
Obtains a lock of type \a mode. The file must be opened before it
can be locked.
If \a block is true, this function will block until the lock is
aquired. If \a block is false, this function returns \e false
immediately if the lock cannot be aquired.
If this object already has a lock of type \a mode, this function
returns \e true immediately. If this object has a lock of a
different type than \a mode, the lock is first released and then a
new lock is obtained.
This function returns \e true if, after it executes, the file is
locked by this object, and \e false otherwise.
\sa unlock(), isLocked(), lockMode()
*/
/*!
\fn bool QtLockedFile::unlock()
Releases a lock.
If the object has no lock, this function returns immediately.
This function returns \e true if, after it executes, the file is
not locked by this object, and \e false otherwise.
\sa lock(), isLocked(), lockMode()
*/
/*!
\fn QtLockedFile::~QtLockedFile()
Destroys the \e QtLockedFile object. If any locks were held, they
are released.
*/

View File

@@ -1,94 +0,0 @@
/****************************************************************************
**
** Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies).
** All rights reserved.
**
** Contact: Nokia Corporation (qt-info@nokia.com)
**
** This file is part of a Qt Solutions component.
**
** You may use this file under the terms of the BSD license as follows:
**
** "Redistribution and use in source and binary forms, with or without
** modification, are permitted provided that the following conditions are
** met:
** * Redistributions of source code must retain the above copyright
** notice, this list of conditions and the following disclaimer.
** * Redistributions in binary form must reproduce the above copyright
** notice, this list of conditions and the following disclaimer in
** the documentation and/or other materials provided with the
** distribution.
** * Neither the name of Nokia Corporation and its Subsidiary(-ies) nor
** the names of its contributors may be used to endorse or promote
** products derived from this software without specific prior written
** permission.
**
** THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
** "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
** LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
** A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
** OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
** SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
** LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
** DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
** THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
** (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
** OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE."
**
****************************************************************************/
#ifndef QTLOCKEDFILE_H
#define QTLOCKEDFILE_H
#include <QFile>
#ifdef Q_OS_WIN
#include <QVector>
#endif
#if defined(Q_WS_WIN) || defined(Q_OS_WIN)
# if !defined(QT_QTLOCKEDFILE_EXPORT) && !defined(QT_QTLOCKEDFILE_IMPORT)
# define QT_QTLOCKEDFILE_EXPORT
# elif defined(QT_QTLOCKEDFILE_IMPORT)
# if defined(QT_QTLOCKEDFILE_EXPORT)
# undef QT_QTLOCKEDFILE_EXPORT
# endif
# define QT_QTLOCKEDFILE_EXPORT __declspec(dllimport)
# elif defined(QT_QTLOCKEDFILE_EXPORT)
# undef QT_QTLOCKEDFILE_EXPORT
# define QT_QTLOCKEDFILE_EXPORT __declspec(dllexport)
# endif
#else
# define QT_QTLOCKEDFILE_EXPORT
#endif
class QT_QTLOCKEDFILE_EXPORT QtLockedFile : public QFile
{
public:
enum LockMode { NoLock = 0, ReadLock, WriteLock };
QtLockedFile();
QtLockedFile(const QString &name);
~QtLockedFile();
bool open(OpenMode mode);
bool lock(LockMode mode, bool block = true);
bool unlock();
bool isLocked() const;
LockMode lockMode() const;
private:
#ifdef Q_OS_WIN
Qt::HANDLE wmutex;
Qt::HANDLE rmutex;
QVector<Qt::HANDLE> rmutexes;
QString mutexname;
Qt::HANDLE getMutexHandle(int idx, bool doCreate);
bool waitMutex(Qt::HANDLE mutex, bool doBlock);
#endif
LockMode m_lock_mode;
};
#endif

View File

@@ -1,114 +0,0 @@
/****************************************************************************
**
** Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies).
** All rights reserved.
**
** Contact: Nokia Corporation (qt-info@nokia.com)
**
** This file is part of a Qt Solutions component.
**
** You may use this file under the terms of the BSD license as follows:
**
** "Redistribution and use in source and binary forms, with or without
** modification, are permitted provided that the following conditions are
** met:
** * Redistributions of source code must retain the above copyright
** notice, this list of conditions and the following disclaimer.
** * Redistributions in binary form must reproduce the above copyright
** notice, this list of conditions and the following disclaimer in
** the documentation and/or other materials provided with the
** distribution.
** * Neither the name of Nokia Corporation and its Subsidiary(-ies) nor
** the names of its contributors may be used to endorse or promote
** products derived from this software without specific prior written
** permission.
**
** THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
** "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
** LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
** A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
** OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
** SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
** LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
** DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
** THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
** (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
** OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE."
**
****************************************************************************/
#include <string.h>
#include <errno.h>
#include <unistd.h>
#include <fcntl.h>
#include "qtlockedfile.h"
bool QtLockedFile::lock(LockMode mode, bool block)
{
if (!isOpen()) {
qWarning("QtLockedFile::lock(): file is not opened");
return false;
}
if (mode == NoLock)
return unlock();
if (mode == m_lock_mode)
return true;
if (m_lock_mode != NoLock)
unlock();
struct flock fl;
fl.l_whence = SEEK_SET;
fl.l_start = 0;
fl.l_len = 0;
fl.l_type = (mode == ReadLock) ? F_RDLCK : F_WRLCK;
int cmd = block ? F_SETLKW : F_SETLK;
int ret = fcntl(handle(), cmd, &fl);
if (ret == -1) {
if (errno != EINTR && errno != EAGAIN)
qWarning("QtLockedFile::lock(): fcntl: %s", strerror(errno));
return false;
}
m_lock_mode = mode;
return true;
}
bool QtLockedFile::unlock()
{
if (!isOpen()) {
qWarning("QtLockedFile::unlock(): file is not opened");
return false;
}
if (!isLocked())
return true;
struct flock fl;
fl.l_whence = SEEK_SET;
fl.l_start = 0;
fl.l_len = 0;
fl.l_type = F_UNLCK;
int ret = fcntl(handle(), F_SETLKW, &fl);
if (ret == -1) {
qWarning("QtLockedFile::lock(): fcntl: %s", strerror(errno));
return false;
}
m_lock_mode = NoLock;
return true;
}
QtLockedFile::~QtLockedFile()
{
if (isOpen())
unlock();
}

View File

@@ -1,203 +0,0 @@
/****************************************************************************
**
** Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies).
** All rights reserved.
**
** Contact: Nokia Corporation (qt-info@nokia.com)
**
** This file is part of a Qt Solutions component.
**
** You may use this file under the terms of the BSD license as follows:
**
** "Redistribution and use in source and binary forms, with or without
** modification, are permitted provided that the following conditions are
** met:
** * Redistributions of source code must retain the above copyright
** notice, this list of conditions and the following disclaimer.
** * Redistributions in binary form must reproduce the above copyright
** notice, this list of conditions and the following disclaimer in
** the documentation and/or other materials provided with the
** distribution.
** * Neither the name of Nokia Corporation and its Subsidiary(-ies) nor
** the names of its contributors may be used to endorse or promote
** products derived from this software without specific prior written
** permission.
**
** THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
** "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
** LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
** A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
** OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
** SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
** LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
** DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
** THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
** (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
** OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE."
**
****************************************************************************/
#include <QFileInfo>
#include "qtlockedfile.h"
#include <qt_windows.h>
#define MUTEX_PREFIX "QtLockedFile mutex "
// Maximum number of concurrent read locks. Must not be greater than MAXIMUM_WAIT_OBJECTS
#define MAX_READERS MAXIMUM_WAIT_OBJECTS
Qt::HANDLE QtLockedFile::getMutexHandle(int idx, bool doCreate)
{
if (mutexname.isEmpty()) {
QFileInfo fi(*this);
mutexname = QString::fromLatin1(MUTEX_PREFIX) + fi.absoluteFilePath().toLower();
}
QString mname(mutexname);
if (idx >= 0)
mname += QString::number(idx);
Qt::HANDLE mutex;
if (doCreate) {
mutex = CreateMutexW(NULL, FALSE, (WCHAR*)mname.utf16());
if (!mutex) {
qErrnoWarning("QtLockedFile::lock(): CreateMutex failed");
return 0;
}
}
else {
mutex = OpenMutexW(SYNCHRONIZE | MUTEX_MODIFY_STATE, FALSE, (WCHAR*)mname.utf16());
if (!mutex) {
if (GetLastError() != ERROR_FILE_NOT_FOUND)
qErrnoWarning("QtLockedFile::lock(): OpenMutex failed");
return 0;
}
}
return mutex;
}
bool QtLockedFile::waitMutex(Qt::HANDLE mutex, bool doBlock)
{
Q_ASSERT(mutex);
DWORD res = WaitForSingleObject(mutex, doBlock ? INFINITE : 0);
switch (res) {
case WAIT_OBJECT_0:
case WAIT_ABANDONED:
return true;
break;
case WAIT_TIMEOUT:
break;
default:
qErrnoWarning("QtLockedFile::lock(): WaitForSingleObject failed");
}
return false;
}
bool QtLockedFile::lock(LockMode mode, bool block)
{
if (!isOpen()) {
qWarning("QtLockedFile::lock(): file is not opened");
return false;
}
if (mode == NoLock)
return unlock();
if (mode == m_lock_mode)
return true;
if (m_lock_mode != NoLock)
unlock();
if (!wmutex && !(wmutex = getMutexHandle(-1, true)))
return false;
if (!waitMutex(wmutex, block))
return false;
if (mode == ReadLock) {
int idx = 0;
for (; idx < MAX_READERS; idx++) {
rmutex = getMutexHandle(idx, false);
if (!rmutex || waitMutex(rmutex, false))
break;
CloseHandle(rmutex);
}
bool ok = true;
if (idx >= MAX_READERS) {
qWarning("QtLockedFile::lock(): too many readers");
rmutex = 0;
ok = false;
}
else if (!rmutex) {
rmutex = getMutexHandle(idx, true);
if (!rmutex || !waitMutex(rmutex, false))
ok = false;
}
if (!ok && rmutex) {
CloseHandle(rmutex);
rmutex = 0;
}
ReleaseMutex(wmutex);
if (!ok)
return false;
}
else {
Q_ASSERT(rmutexes.isEmpty());
for (int i = 0; i < MAX_READERS; i++) {
Qt::HANDLE mutex = getMutexHandle(i, false);
if (mutex)
rmutexes.append(mutex);
}
if (rmutexes.size()) {
DWORD res = WaitForMultipleObjects(rmutexes.size(), rmutexes.constData(), TRUE, block ? INFINITE : 0);
if (res != WAIT_OBJECT_0 && res != WAIT_ABANDONED) {
if (res != WAIT_TIMEOUT)
qErrnoWarning("QtLockedFile::lock(): WaitForMultipleObjects failed");
m_lock_mode = WriteLock; // trick unlock() to clean up - semiyucky
unlock();
return false;
}
}
}
m_lock_mode = mode;
return true;
}
bool QtLockedFile::unlock()
{
if (!isOpen()) {
qWarning("QtLockedFile::unlock(): file is not opened");
return false;
}
if (!isLocked())
return true;
if (m_lock_mode == ReadLock) {
ReleaseMutex(rmutex);
CloseHandle(rmutex);
rmutex = 0;
}
else {
foreach(Qt::HANDLE mutex, rmutexes) {
ReleaseMutex(mutex);
CloseHandle(mutex);
}
rmutexes.clear();
ReleaseMutex(wmutex);
}
m_lock_mode = QtLockedFile::NoLock;
return true;
}
QtLockedFile::~QtLockedFile()
{
if (isOpen())
unlock();
if (wmutex)
CloseHandle(wmutex);
}

View File

@@ -1,335 +0,0 @@
/****************************************************************************
**
** Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies).
** All rights reserved.
**
** Contact: Nokia Corporation (qt-info@nokia.com)
**
** This file is part of a Qt Solutions component.
**
** You may use this file under the terms of the BSD license as follows:
**
** "Redistribution and use in source and binary forms, with or without
** modification, are permitted provided that the following conditions are
** met:
** * Redistributions of source code must retain the above copyright
** notice, this list of conditions and the following disclaimer.
** * Redistributions in binary form must reproduce the above copyright
** notice, this list of conditions and the following disclaimer in
** the documentation and/or other materials provided with the
** distribution.
** * Neither the name of Nokia Corporation and its Subsidiary(-ies) nor
** the names of its contributors may be used to endorse or promote
** products derived from this software without specific prior written
** permission.
**
** THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
** "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
** LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
** A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
** OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
** SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
** LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
** DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
** THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
** (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
** OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE."
**
****************************************************************************/
#include "qtsingleapplication.h"
#include <QApplication>
#include <QWidget>
#include <QString>
#include "qtlocalpeer.h"
/*!
\class QtSingleApplication qtsingleapplication.h
\brief The QtSingleApplication class provides an API to detect and
communicate with running instances of an application.
This class allows you to create applications where only one
instance should be running at a time. I.e., if the user tries to
launch another instance, the already running instance will be
activated instead. Another usecase is a client-server system,
where the first started instance will assume the role of server,
and the later instances will act as clients of that server.
By default, the full path of the executable file is used to
determine whether two processes are instances of the same
application. You can also provide an explicit identifier string
that will be compared instead.
The application should create the QtSingleApplication object early
in the startup phase, and call isRunning() to find out if another
instance of this application is already running. If isRunning()
returns false, it means that no other instance is running, and
this instance has assumed the role as the running instance. In
this case, the application should continue with the initialization
of the application user interface before entering the event loop
with exec(), as normal.
The messageReceived() signal will be emitted when the running
application receives messages from another instance of the same
application. When a message is received it might be helpful to the
user to raise the application so that it becomes visible. To
facilitate this, QtSingleApplication provides the
setActivationWindow() function and the activateWindow() slot.
If isRunning() returns true, another instance is already
running. It may be alerted to the fact that another instance has
started by using the sendMessage() function. Also data such as
startup parameters (e.g. the name of the file the user wanted this
new instance to open) can be passed to the running instance with
this function. Then, the application should terminate (or enter
client mode).
If isRunning() returns true, but sendMessage() fails, that is an
indication that the running instance is frozen.
Here's an example that shows how to convert an existing
application to use QtSingleApplication. It is very simple and does
not make use of all QtSingleApplication's functionality (see the
examples for that).
\code
// Original
int main(int argc, char **argv)
{
QApplication app(argc, argv);
MyMainWidget mmw;
mmw.show();
return app.exec();
}
// Single instance
int main(int argc, char **argv)
{
QtSingleApplication app(argc, argv);
if (app.isRunning())
return !app.sendMessage(someDataString);
MyMainWidget mmw;
app.setActivationWindow(&mmw);
mmw.show();
return app.exec();
}
\endcode
Once this QtSingleApplication instance is destroyed (normally when
the process exits or crashes), when the user next attempts to run the
application this instance will not, of course, be encountered. The
next instance to call isRunning() or sendMessage() will assume the
role as the new running instance.
For console (non-GUI) applications, QtSingleCoreApplication may be
used instead of this class, to avoid the dependency on the QtGui
library.
\sa QtSingleCoreApplication
*/
void QtSingleApplication::sysInit(const QString &appId)
{
actWin = 0;
peer = new QtLocalPeer(this, appId);
connect(peer, SIGNAL(messageReceived(const QString&)), SIGNAL(messageReceived(const QString&)));
}
/*!
Creates a QtSingleApplication object. The application identifier
will be QCoreApplication::applicationFilePath(). \a argc, \a
argv, and \a GUIenabled are passed on to the QAppliation constructor.
If you are creating a console application (i.e. setting \a
GUIenabled to false), you may consider using
QtSingleCoreApplication instead.
*/
QtSingleApplication::QtSingleApplication(int &argc, char **argv, bool GUIenabled)
: QApplication(argc, argv, GUIenabled)
{
sysInit();
}
/*!
Creates a QtSingleApplication object with the application
identifier \a appId. \a argc and \a argv are passed on to the
QAppliation constructor.
*/
QtSingleApplication::QtSingleApplication(const QString &appId, int &argc, char **argv)
: QApplication(argc, argv)
{
sysInit(appId);
}
#if defined(Q_WS_X11)
/*!
Special constructor for X11, ref. the documentation of
QApplication's corresponding constructor. The application identifier
will be QCoreApplication::applicationFilePath(). \a dpy, \a visual,
and \a cmap are passed on to the QApplication constructor.
*/
QtSingleApplication::QtSingleApplication(Display* dpy, Qt::HANDLE visual, Qt::HANDLE cmap)
: QApplication(dpy, visual, cmap)
{
sysInit();
}
/*!
Special constructor for X11, ref. the documentation of
QApplication's corresponding constructor. The application identifier
will be QCoreApplication::applicationFilePath(). \a dpy, \a argc, \a
argv, \a visual, and \a cmap are passed on to the QApplication
constructor.
*/
QtSingleApplication::QtSingleApplication(Display *dpy, int &argc, char **argv, Qt::HANDLE visual, Qt::HANDLE cmap)
: QApplication(dpy, argc, argv, visual, cmap)
{
sysInit();
}
/*!
Special constructor for X11, ref. the documentation of
QApplication's corresponding constructor. The application identifier
will be \a appId. \a dpy, \a argc, \a
argv, \a visual, and \a cmap are passed on to the QApplication
constructor.
*/
QtSingleApplication::QtSingleApplication(Display* dpy, const QString &appId, int argc, char **argv, Qt::HANDLE visual, Qt::HANDLE cmap)
: QApplication(dpy, argc, argv, visual, cmap)
{
sysInit(appId);
}
#endif
/*!
Returns true if another instance of this application is running;
otherwise false.
This function does not find instances of this application that are
being run by a different user (on Windows: that are running in
another session).
\sa sendMessage()
*/
bool QtSingleApplication::isRunning()
{
return peer->isClient();
}
/*!
Tries to send the text \a message to the currently running
instance. The QtSingleApplication object in the running instance
will emit the messageReceived() signal when it receives the
message.
This function returns true if the message has been sent to, and
processed by, the current instance. If there is no instance
currently running, or if the running instance fails to process the
message within \a timeout milliseconds, this function return false.
\sa isRunning(), messageReceived()
*/
bool QtSingleApplication::sendMessage(const QString &message, int timeout)
{
return peer->sendMessage(message, timeout);
}
/*!
Returns the application identifier. Two processes with the same
identifier will be regarded as instances of the same application.
*/
QString QtSingleApplication::id() const
{
return peer->applicationId();
}
/*!
Sets the activation window of this application to \a aw. The
activation window is the widget that will be activated by
activateWindow(). This is typically the application's main window.
If \a activateOnMessage is true (the default), the window will be
activated automatically every time a message is received, just prior
to the messageReceived() signal being emitted.
\sa activateWindow(), messageReceived()
*/
void QtSingleApplication::setActivationWindow(QWidget* aw, bool activateOnMessage)
{
actWin = aw;
if (activateOnMessage)
connect(peer, SIGNAL(messageReceived(const QString&)), this, SLOT(activateWindow()));
else
disconnect(peer, SIGNAL(messageReceived(const QString&)), this, SLOT(activateWindow()));
}
/*!
Returns the applications activation window if one has been set by
calling setActivationWindow(), otherwise returns 0.
\sa setActivationWindow()
*/
QWidget* QtSingleApplication::activationWindow() const
{
return actWin;
}
/*!
De-minimizes, raises, and activates this application's activation window.
This function does nothing if no activation window has been set.
This is a convenience function to show the user that this
application instance has been activated when he has tried to start
another instance.
This function should typically be called in response to the
messageReceived() signal. By default, that will happen
automatically, if an activation window has been set.
\sa setActivationWindow(), messageReceived(), initialize()
*/
void QtSingleApplication::activateWindow()
{
if (actWin) {
actWin->setWindowState(actWin->windowState() & ~Qt::WindowMinimized);
actWin->raise();
actWin->activateWindow();
}
}
/*!
\fn void QtSingleApplication::messageReceived(const QString& message)
This signal is emitted when the current instance receives a \a
message from another instance of this application.
\sa sendMessage(), setActivationWindow(), activateWindow()
*/
/*!
\fn void QtSingleApplication::initialize(bool dummy = true)
\obsolete
*/

View File

@@ -1,104 +0,0 @@
/****************************************************************************
**
** Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies).
** All rights reserved.
**
** Contact: Nokia Corporation (qt-info@nokia.com)
**
** This file is part of a Qt Solutions component.
**
** You may use this file under the terms of the BSD license as follows:
**
** "Redistribution and use in source and binary forms, with or without
** modification, are permitted provided that the following conditions are
** met:
** * Redistributions of source code must retain the above copyright
** notice, this list of conditions and the following disclaimer.
** * Redistributions in binary form must reproduce the above copyright
** notice, this list of conditions and the following disclaimer in
** the documentation and/or other materials provided with the
** distribution.
** * Neither the name of Nokia Corporation and its Subsidiary(-ies) nor
** the names of its contributors may be used to endorse or promote
** products derived from this software without specific prior written
** permission.
**
** THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
** "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
** LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
** A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
** OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
** SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
** LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
** DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
** THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
** (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
** OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE."
**
****************************************************************************/
#ifndef QTSINGLEAPPLICATION_H
#define QTSINGLEAPPLICATION_H
#include <QtGlobal>
#include <QObject>
#include <QWidget>
#include <QApplication>
#include <QString>
class QtLocalPeer;
#if defined(Q_WS_WIN) || defined(Q_OS_WIN32)
# if !defined(QT_QTSINGLEAPPLICATION_EXPORT) && !defined(QT_QTSINGLEAPPLICATION_IMPORT)
# define QT_QTSINGLEAPPLICATION_EXPORT
# elif defined(QT_QTSINGLEAPPLICATION_IMPORT)
# if defined(QT_QTSINGLEAPPLICATION_EXPORT)
# undef QT_QTSINGLEAPPLICATION_EXPORT
# endif
# define QT_QTSINGLEAPPLICATION_EXPORT __declspec(dllimport)
# elif defined(QT_QTSINGLEAPPLICATION_EXPORT)
# undef QT_QTSINGLEAPPLICATION_EXPORT
# define QT_QTSINGLEAPPLICATION_EXPORT __declspec(dllexport)
# endif
#else
# define QT_QTSINGLEAPPLICATION_EXPORT
#endif
class QT_QTSINGLEAPPLICATION_EXPORT QtSingleApplication : public QApplication
{
Q_OBJECT
public:
QtSingleApplication(int &argc, char **argv, bool GUIenabled = true);
QtSingleApplication(const QString &id, int &argc, char **argv);
#if defined(Q_WS_X11)
QtSingleApplication(Display* dpy, Qt::HANDLE visual = 0, Qt::HANDLE colormap = 0);
QtSingleApplication(Display *dpy, int &argc, char **argv, Qt::HANDLE visual = 0, Qt::HANDLE cmap= 0);
QtSingleApplication(Display* dpy, const QString &appId, int argc, char **argv, Qt::HANDLE visual = 0, Qt::HANDLE colormap = 0);
#endif
bool isRunning();
QString id() const;
void setActivationWindow(QWidget* aw, bool activateOnMessage = true);
QWidget* activationWindow() const;
// Obsolete:
void initialize(bool dummy = true)
{ isRunning(); Q_UNUSED(dummy) }
public Q_SLOTS:
bool sendMessage(const QString &message, int timeout = 5000);
void activateWindow();
Q_SIGNALS:
void messageReceived(const QString &message);
private:
void sysInit(const QString &appId = QString());
QtLocalPeer *peer;
QWidget *actWin;
};
#endif // QTSINGLEAPPLICATION_H

View File

@@ -1,146 +0,0 @@
/****************************************************************************
**
** Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies).
** All rights reserved.
**
** Contact: Nokia Corporation (qt-info@nokia.com)
**
** This file is part of a Qt Solutions component.
**
** You may use this file under the terms of the BSD license as follows:
**
** "Redistribution and use in source and binary forms, with or without
** modification, are permitted provided that the following conditions are
** met:
** * Redistributions of source code must retain the above copyright
** notice, this list of conditions and the following disclaimer.
** * Redistributions in binary form must reproduce the above copyright
** notice, this list of conditions and the following disclaimer in
** the documentation and/or other materials provided with the
** distribution.
** * Neither the name of Nokia Corporation and its Subsidiary(-ies) nor
** the names of its contributors may be used to endorse or promote
** products derived from this software without specific prior written
** permission.
**
** THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
** "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
** LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
** A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
** OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
** SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
** LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
** DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
** THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
** (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
** OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE."
**
****************************************************************************/
#include <QCoreApplication>
#include <QString>
#include <QFlags>
#include "qtsinglecoreapplication.h"
#include "qtlocalpeer.h"
/*!
\class QtSingleCoreApplication qtsinglecoreapplication.h
\brief A variant of the QtSingleApplication class for non-GUI applications.
This class is a variant of QtSingleApplication suited for use in
console (non-GUI) applications. It is an extension of
QCoreApplication (instead of QApplication). It does not require
the QtGui library.
The API and usage is identical to QtSingleApplication, except that
functions relating to the "activation window" are not present, for
obvious reasons. Please refer to the QtSingleApplication
documentation for explanation of the usage.
A QtSingleCoreApplication instance can communicate to a
QtSingleApplication instance if they share the same application
id. Hence, this class can be used to create a light-weight
command-line tool that sends commands to a GUI application.
\sa QtSingleApplication
*/
/*!
Creates a QtSingleCoreApplication object. The application identifier
will be QCoreApplication::applicationFilePath(). \a argc and \a
argv are passed on to the QCoreAppliation constructor.
*/
QtSingleCoreApplication::QtSingleCoreApplication(int &argc, char **argv)
: QCoreApplication(argc, argv) {
peer = new QtLocalPeer(this);
connect(peer, SIGNAL(messageReceived(const QString&)), SIGNAL(messageReceived(const QString&)));
}
/*!
Creates a QtSingleCoreApplication object with the application
identifier \a appId. \a argc and \a argv are passed on to the
QCoreAppliation constructor.
*/
QtSingleCoreApplication::QtSingleCoreApplication(const QString &appId, int &argc, char **argv)
: QCoreApplication(argc, argv) {
peer = new QtLocalPeer(this, appId);
connect(peer, SIGNAL(messageReceived(const QString&)), SIGNAL(messageReceived(const QString&)));
}
/*!
Returns true if another instance of this application is running;
otherwise false.
This function does not find instances of this application that are
being run by a different user (on Windows: that are running in
another session).
\sa sendMessage()
*/
bool QtSingleCoreApplication::isRunning() {
return peer->isClient();
}
/*!
Tries to send the text \a message to the currently running
instance. The QtSingleCoreApplication object in the running instance
will emit the messageReceived() signal when it receives the
message.
This function returns true if the message has been sent to, and
processed by, the current instance. If there is no instance
currently running, or if the running instance fails to process the
message within \a timeout milliseconds, this function return false.
\sa isRunning(), messageReceived()
*/
bool QtSingleCoreApplication::sendMessage(const QString &message, int timeout) {
return peer->sendMessage(message, timeout);
}
/*!
Returns the application identifier. Two processes with the same
identifier will be regarded as instances of the same application.
*/
QString QtSingleCoreApplication::id() const {
return peer->applicationId();
}
/*!
\fn void QtSingleCoreApplication::messageReceived(const QString& message)
This signal is emitted when the current instance receives a \a
message from another instance of this application.
\sa sendMessage()
*/

View File

@@ -1,72 +0,0 @@
/****************************************************************************
**
** Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies).
** All rights reserved.
**
** Contact: Nokia Corporation (qt-info@nokia.com)
**
** This file is part of a Qt Solutions component.
**
** You may use this file under the terms of the BSD license as follows:
**
** "Redistribution and use in source and binary forms, with or without
** modification, are permitted provided that the following conditions are
** met:
** * Redistributions of source code must retain the above copyright
** notice, this list of conditions and the following disclaimer.
** * Redistributions in binary form must reproduce the above copyright
** notice, this list of conditions and the following disclaimer in
** the documentation and/or other materials provided with the
** distribution.
** * Neither the name of Nokia Corporation and its Subsidiary(-ies) nor
** the names of its contributors may be used to endorse or promote
** products derived from this software without specific prior written
** permission.
**
** THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
** "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
** LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
** A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
** OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
** SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
** LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
** DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
** THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
** (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
** OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE."
**
****************************************************************************/
#ifndef QTSINGLECOREAPPLICATION_H
#define QTSINGLECOREAPPLICATION_H
#include <QCoreApplication>
#include <QObject>
#include <QString>
class QtLocalPeer;
class QtSingleCoreApplication : public QCoreApplication
{
Q_OBJECT
public:
QtSingleCoreApplication(int &argc, char **argv);
QtSingleCoreApplication(const QString &id, int &argc, char **argv);
bool isRunning();
QString id() const;
public Q_SLOTS:
bool sendMessage(const QString &message, int timeout = 5000);
Q_SIGNALS:
void messageReceived(const QString &message);
private:
QtLocalPeer* peer;
};
#endif // QTSINGLECOREAPPLICATION_H

View File

@@ -1,14 +0,0 @@
cmake_minimum_required(VERSION 2.8.11)
set(CMAKE_CXX_STANDARD 11)
set(QTWIN-SOURCES
qtwin.cpp
)
ADD_LIBRARY(qtwin STATIC
${QTWIN-SOURCES}
)
target_link_libraries(qtwin
Qt5::Widgets
)

View File

@@ -1,229 +0,0 @@
/****************************************************************************
**
** Copyright (C) 2009 Nokia Corporation and/or its subsidiary(-ies).
**
** Use, modification and distribution is allowed without limitation,
** warranty, liability or support of any kind.
**
****************************************************************************/
#include "qtwin.h"
#include <QLibrary>
#include <QApplication>
#include <QWidget>
#include <QList>
#include <QPointer>
#ifdef Q_WS_WIN
#include <qt_windows.h>
// Blur behind data structures
#define DWM_BB_ENABLE 0x00000001 // fEnable has been specified
#define DWM_BB_BLURREGION 0x00000002 // hRgnBlur has been specified
#define DWM_BB_TRANSITIONONMAXIMIZED 0x00000004 // fTransitionOnMaximized has been specified
#define WM_DWMCOMPOSITIONCHANGED 0x031E // Composition changed window message
typedef struct _DWM_BLURBEHIND
{
DWORD dwFlags;
BOOL fEnable;
HRGN hRgnBlur;
BOOL fTransitionOnMaximized;
} DWM_BLURBEHIND, *PDWM_BLURBEHIND;
typedef struct _MARGINS
{
int cxLeftWidth;
int cxRightWidth;
int cyTopHeight;
int cyBottomHeight;
} MARGINS, *PMARGINS;
typedef HRESULT (WINAPI *PtrDwmIsCompositionEnabled)(BOOL* pfEnabled);
typedef HRESULT (WINAPI *PtrDwmExtendFrameIntoClientArea)(HWND hWnd, const MARGINS* pMarInset);
typedef HRESULT (WINAPI *PtrDwmEnableBlurBehindWindow)(HWND hWnd, const DWM_BLURBEHIND* pBlurBehind);
typedef HRESULT (WINAPI *PtrDwmGetColorizationColor)(DWORD *pcrColorization, BOOL *pfOpaqueBlend);
static PtrDwmIsCompositionEnabled pDwmIsCompositionEnabled= 0;
static PtrDwmEnableBlurBehindWindow pDwmEnableBlurBehindWindow = 0;
static PtrDwmExtendFrameIntoClientArea pDwmExtendFrameIntoClientArea = 0;
static PtrDwmGetColorizationColor pDwmGetColorizationColor = 0;
/*
* Internal helper class that notifies windows if the
* DWM compositing state changes and updates the widget
* flags correspondingly.
*/
class WindowNotifier : public QWidget
{
public:
WindowNotifier() { winId(); }
void addWidget(QWidget *widget) { widgets.append(widget); }
void removeWidget(QWidget *widget) { widgets.removeAll(widget); }
bool winEvent(MSG *message, long *result);
private:
QWidgetList widgets;
};
static bool resolveLibs()
{
if (!pDwmIsCompositionEnabled) {
QLibrary dwmLib(QString::fromAscii("dwmapi"));
pDwmIsCompositionEnabled =(PtrDwmIsCompositionEnabled)dwmLib.resolve("DwmIsCompositionEnabled");
pDwmExtendFrameIntoClientArea = (PtrDwmExtendFrameIntoClientArea)dwmLib.resolve("DwmExtendFrameIntoClientArea");
pDwmEnableBlurBehindWindow = (PtrDwmEnableBlurBehindWindow)dwmLib.resolve("DwmEnableBlurBehindWindow");
pDwmGetColorizationColor = (PtrDwmGetColorizationColor)dwmLib.resolve("DwmGetColorizationColor");
}
return pDwmIsCompositionEnabled != 0;
}
#endif
/*!
* Chekcs and returns true if Windows DWM composition
* is currently enabled on the system.
*
* To get live notification on the availability of
* this feature, you will currently have to
* reimplement winEvent() on your widget and listen
* for the WM_DWMCOMPOSITIONCHANGED event to occur.
*
*/
bool QtWin::isCompositionEnabled()
{
#ifdef Q_WS_WIN
if (resolveLibs()) {
HRESULT hr = S_OK;
BOOL isEnabled = false;
hr = pDwmIsCompositionEnabled(&isEnabled);
if (SUCCEEDED(hr))
return isEnabled;
}
#endif
return false;
}
/*!
* Enables Blur behind on a Widget.
*
* \a enable tells if the blur should be enabled or not
*/
bool QtWin::enableBlurBehindWindow(QWidget *widget, bool enable,
const QRegion &region)
{
Q_ASSERT(widget);
bool result = false;
#ifdef Q_WS_WIN
if (resolveLibs()) {
DWM_BLURBEHIND bb = {0};
HRESULT hr = S_OK;
bb.fEnable = enable;
bb.dwFlags = DWM_BB_ENABLE;
bb.hRgnBlur = NULL;
if (!region.isEmpty()) {
bb.dwFlags |= DWM_BB_BLURREGION;
bb.hRgnBlur = region.handle();
}
widget->setAttribute(Qt::WA_TranslucentBackground, enable);
widget->setAttribute(Qt::WA_NoSystemBackground, enable);
hr = pDwmEnableBlurBehindWindow(widget->winId(), &bb);
if (SUCCEEDED(hr)) {
result = true;
windowNotifier()->addWidget(widget);
}
}
#endif
return result;
}
/*!
* ExtendFrameIntoClientArea.
*
* This controls the rendering of the frame inside the window.
* Note that passing margins of -1 (the default value) will completely
* remove the frame from the window.
*
* \note you should not call enableBlurBehindWindow before calling
* this functions
*
* \a enable tells if the blur should be enabled or not
*/
bool QtWin::extendFrameIntoClientArea(QWidget *widget, int left, int top, int right, int bottom)
{
Q_ASSERT(widget);
Q_UNUSED(left);
Q_UNUSED(top);
Q_UNUSED(right);
Q_UNUSED(bottom);
bool result = false;
#ifdef Q_WS_WIN
if (resolveLibs()) {
QLibrary dwmLib(QString::fromAscii("dwmapi"));
HRESULT hr = S_OK;
MARGINS m = {left, top, right, bottom};
hr = pDwmExtendFrameIntoClientArea(widget->winId(), &m);
if (SUCCEEDED(hr)) {
result = true;
windowNotifier()->addWidget(widget);
}
widget->setAttribute(Qt::WA_TranslucentBackground, result);
}
#endif
return result;
}
/*!
* Returns the current colorizationColor for the window.
*
* \a enable tells if the blur should be enabled or not
*/
QColor QtWin::colorizatinColor()
{
QColor resultColor = QApplication::palette().window().color();
#ifdef Q_WS_WIN
if (resolveLibs()) {
DWORD color = 0;
BOOL opaque = FALSE;
QLibrary dwmLib(QString::fromAscii("dwmapi"));
HRESULT hr = S_OK;
hr = pDwmGetColorizationColor(&color, &opaque);
if (SUCCEEDED(hr))
resultColor = QColor(color);
}
#endif
return resultColor;
}
#ifdef Q_WS_WIN
WindowNotifier *QtWin::windowNotifier()
{
static WindowNotifier *windowNotifierInstance = 0;
if (!windowNotifierInstance)
windowNotifierInstance = new WindowNotifier;
return windowNotifierInstance;
}
/* Notify all enabled windows that the DWM state changed */
bool WindowNotifier::winEvent(MSG *message, long *result)
{
if (message && message->message == WM_DWMCOMPOSITIONCHANGED) {
bool compositionEnabled = QtWin::isCompositionEnabled();
foreach(QWidget * widget, widgets) {
if (widget) {
widget->setAttribute(Qt::WA_NoSystemBackground, compositionEnabled);
}
widget->update();
}
}
return QWidget::winEvent(message, result);
}
#endif

View File

@@ -1,38 +0,0 @@
/****************************************************************************
**
** Copyright (C) 2009 Nokia Corporation and/or its subsidiary(-ies).
**
** Use, modification and distribution is allowed without limitation,
** warranty, liability or support of any kind.
**
****************************************************************************/
#ifndef QTWIN_H
#define QTWIN_H
#include <QColor>
#include <QWidget>
/**
* This is a helper class for using the Desktop Window Manager
* functionality on Windows 7 and Windows Vista. On other platforms
* these functions will simply not do anything.
*/
class WindowNotifier;
class QtWin
{
public:
static bool enableBlurBehindWindow(QWidget *widget, bool enable = true,
const QRegion& region = QRegion());
static bool extendFrameIntoClientArea(QWidget *widget,
int left = -1, int top = -1,
int right = -1, int bottom = -1);
static bool isCompositionEnabled();
static QColor colorizatinColor();
private:
static WindowNotifier *windowNotifier();
};
#endif // QTWIN_H

View File

@@ -1,36 +0,0 @@
cmake_minimum_required(VERSION 2.8.11)
set(CMAKE_CXX_STANDARD 11)
set(QXT-SOURCES
qxtglobal.cpp
qxtglobalshortcut.cpp
)
set(QXT-MOC-HEADERS
qxtglobalshortcut.h
)
find_package(X11)
include_directories(${X11_INCLUDE_DIR})
include_directories(${Qt5Gui_PRIVATE_INCLUDE_DIRS})
if(WIN32)
set(QXT-SOURCES ${QXT-SOURCES} qxtglobalshortcut_win.cpp)
elseif(APPLE)
set(QXT-SOURCES ${QXT-SOURCES} qxtglobalshortcut_mac.cpp)
else(WIN32)
set(QXT-SOURCES ${QXT-SOURCES} qxtglobalshortcut_x11.cpp)
endif(WIN32)
QT5_WRAP_CPP(QXT-SOURCES-MOC ${QXT-MOC-HEADERS})
ADD_LIBRARY(qxt STATIC
${QXT-SOURCES}
${QXT-SOURCES-MOC}
)
if(WIN32)
target_link_libraries(qxt Qt5::Core Qt5::Widgets)
else(WIN32)
target_link_libraries(qxt Qt5::Core Qt5::Widgets Qt5::X11Extras)
endif(WIN32)

89
3rdparty/qxt/LICENSE vendored
View File

@@ -1,89 +0,0 @@
Qt Extension Library
Copyright (C) 2007 Qxt Foundation
------------------- Disclaimer ------------------------------------------------
Until the Qxt Foundation is legally established, copyright for the
source code falls back to the original contributor. For information about the
status of the Qxt Foundation, or about the copyright status of any part of Qxt,
contact the Qxt project maintainers at <foundation@libqxt.org>
Once the Qxt Foundation has been legally established, all contributors must
transfer all copyright interest to the Qxt Foundation before their submissions
will be added to the project.
------------------- License ---------------------------------------------------
This library is free software; you can redistribute it and/or modify it
under the terms of the Common Public License, version 1.0, as published by IBM
or under the terms of the GNU Lesser General Public License, version 2.1,
as published by the Free Software Foundation
This file is provided "AS IS", without WARRANTIES OR CONDITIONS OF ANY
KIND, EITHER EXPRESS OR IMPLIED INCLUDING, WITHOUT LIMITATION, ANY
WARRANTIES OR CONDITIONS OF TITLE, NON-INFRINGEMENT, MERCHANTABILITY OR
FITNESS FOR A PARTICULAR PURPOSE.
You should have received a copy of the CPL along with this file.
See the LICENSE file and the cpl1.0.txt file included with the source
distribution for more information. If you did not receive a copy of the
license, contact the Qxt Foundation.
You should have received a copy of the LGPL along with this file.
See the LICENSE file and the lgpl-2.1.txt file included with the source
distribution for more information. If you did not receive a copy of the
license, contact the Qxt Foundation.
Parts of Qxt depend on Qt 4 and/or other libraries that have their own
licenses. Qxt is independent of these licenses; however, use of these other
libraries is subject to their respective license agreements.
------------------- Intent ----------------------------------------------------
The following section describes the opinions and intent of the Qxt Foundation
with regards to the licensing and use of the Qxt source code and library. In
the event that the CPL is found to be illegal or invalid, or if any application
or clause of the license is subjected to question or abuse, this section is a
general statement of the desired interpretation.
This section has no legal standing and the statements made here are strictly
subject to the text of the CPL; that is, if this section and the CPL are in
disagreement, the text of the CPL takes precedence. In no way does this
intent grant you any additional rights or impose any additional restrictions.
If you have questions about licensing, contact the maintainers.
Qxt is built and supported by open-source enthusiasts.
- Please respect the open-source background of the contributors. The code is
provided for everyone's use; you may not restrict the rights of anyone to
use it.
- No individual may claim ownership of any part of the code. It belongs
to the community.
- You may modify the source code to suit your needs, but these changes
must be made free. If you distribute a modified form of Qxt, you must
also distribute the entire source code of the modified form.
- Digital Rights Management (DRM) puts unfair, unfree restrictions on
users and developers. It is the opposite of Free Software. We can't
stop you from using it, but please don't use the Qxt name for software
restricted by DRM.
- Please respect the time and effort put into the project by the developers.
- If you find Qxt useful, it would be appreciated if you would include
text in your application (for instance, in the About dialog) giving
acknowledgement to Qxt.
- If you make modifications to the source code, you must not call the
modified version "Qxt." It's okay to include "Qxt" in the name, but
anyone who receives the modified version needs to know that it's not
the same as the version distributed by the Qxt Foundation.
- We want everyone to be able to use Qxt without restrictions.
- If you distribute Qxt in compiled binary form, please ensure that
everyone who receives it can get the source code used to create it.
- You are free to use Qxt in closed-source applications as long as you
distribute Qxt in an open-source fashion. This does not require you
to make your entire application open-source.
- The Qxt Foundation is a non-profit, non-political organization.
- Please don't use the Qxt name in any political or semi-political
propaganda or publication. We don't like it.
- Qxt is distributed "as-is," with no warranty.
- If it makes your program crash, your computer blow up, or tiny demons
fly out of your nose, please don't sue us.

View File

@@ -1,372 +0,0 @@
#ifndef KEYMAPPER_X11_H
#define KEYMAPPER_X11_H
// (davidsansome) Nicked from qkeymapper_x11.cpp
#include <Qt>
#define XK_MISCELLANY
#define XK_LATIN1
#define XK_KOREAN
#define XK_XKB_KEYS
#include <X11/keysymdef.h>
//
// Keyboard event translation
//
#ifndef XK_ISO_Left_Tab
#define XK_ISO_Left_Tab 0xFE20
#endif
#ifndef XK_dead_hook
#define XK_dead_hook 0xFE61
#endif
#ifndef XK_dead_horn
#define XK_dead_horn 0xFE62
#endif
#ifndef XK_Codeinput
#define XK_Codeinput 0xFF37
#endif
#ifndef XK_Kanji_Bangou
#define XK_Kanji_Bangou 0xFF37 /* same as codeinput */
#endif
// Fix old X libraries
#ifndef XK_KP_Home
#define XK_KP_Home 0xFF95
#endif
#ifndef XK_KP_Left
#define XK_KP_Left 0xFF96
#endif
#ifndef XK_KP_Up
#define XK_KP_Up 0xFF97
#endif
#ifndef XK_KP_Right
#define XK_KP_Right 0xFF98
#endif
#ifndef XK_KP_Down
#define XK_KP_Down 0xFF99
#endif
#ifndef XK_KP_Prior
#define XK_KP_Prior 0xFF9A
#endif
#ifndef XK_KP_Next
#define XK_KP_Next 0xFF9B
#endif
#ifndef XK_KP_End
#define XK_KP_End 0xFF9C
#endif
#ifndef XK_KP_Insert
#define XK_KP_Insert 0xFF9E
#endif
#ifndef XK_KP_Delete
#define XK_KP_Delete 0xFF9F
#endif
// the next lines are taken from XFree > 4.0 (X11/XF86keysyms.h), defining some special
// multimedia keys. They are included here as not every system has them.
#define XF86XK_Standby 0x1008FF10
#define XF86XK_AudioLowerVolume 0x1008FF11
#define XF86XK_AudioMute 0x1008FF12
#define XF86XK_AudioRaiseVolume 0x1008FF13
#define XF86XK_AudioPlay 0x1008FF14
#define XF86XK_AudioStop 0x1008FF15
#define XF86XK_AudioPrev 0x1008FF16
#define XF86XK_AudioNext 0x1008FF17
#define XF86XK_HomePage 0x1008FF18
#define XF86XK_Calculator 0x1008FF1D
#define XF86XK_Mail 0x1008FF19
#define XF86XK_Start 0x1008FF1A
#define XF86XK_Search 0x1008FF1B
#define XF86XK_AudioRecord 0x1008FF1C
#define XF86XK_Back 0x1008FF26
#define XF86XK_Forward 0x1008FF27
#define XF86XK_Stop 0x1008FF28
#define XF86XK_Refresh 0x1008FF29
#define XF86XK_Favorites 0x1008FF30
#define XF86XK_AudioPause 0x1008FF31
#define XF86XK_AudioMedia 0x1008FF32
#define XF86XK_MyComputer 0x1008FF33
#define XF86XK_OpenURL 0x1008FF38
#define XF86XK_Launch0 0x1008FF40
#define XF86XK_Launch1 0x1008FF41
#define XF86XK_Launch2 0x1008FF42
#define XF86XK_Launch3 0x1008FF43
#define XF86XK_Launch4 0x1008FF44
#define XF86XK_Launch5 0x1008FF45
#define XF86XK_Launch6 0x1008FF46
#define XF86XK_Launch7 0x1008FF47
#define XF86XK_Launch8 0x1008FF48
#define XF86XK_Launch9 0x1008FF49
#define XF86XK_LaunchA 0x1008FF4A
#define XF86XK_LaunchB 0x1008FF4B
#define XF86XK_LaunchC 0x1008FF4C
#define XF86XK_LaunchD 0x1008FF4D
#define XF86XK_LaunchE 0x1008FF4E
#define XF86XK_LaunchF 0x1008FF4F
// end of XF86keysyms.h
// Special keys used by Qtopia, mapped into the X11 private keypad range.
#define QTOPIAXK_Select 0x11000601
#define QTOPIAXK_Yes 0x11000602
#define QTOPIAXK_No 0x11000603
#define QTOPIAXK_Cancel 0x11000604
#define QTOPIAXK_Printer 0x11000605
#define QTOPIAXK_Execute 0x11000606
#define QTOPIAXK_Sleep 0x11000607
#define QTOPIAXK_Play 0x11000608
#define QTOPIAXK_Zoom 0x11000609
#define QTOPIAXK_Context1 0x1100060A
#define QTOPIAXK_Context2 0x1100060B
#define QTOPIAXK_Context3 0x1100060C
#define QTOPIAXK_Context4 0x1100060D
#define QTOPIAXK_Call 0x1100060E
#define QTOPIAXK_Hangup 0x1100060F
#define QTOPIAXK_Flip 0x11000610
// keyboard mapping table
static const unsigned int KeyTbl[] = {
// misc keys
XK_Escape, Qt::Key_Escape,
XK_Tab, Qt::Key_Tab,
XK_ISO_Left_Tab, Qt::Key_Backtab,
XK_BackSpace, Qt::Key_Backspace,
XK_Return, Qt::Key_Return,
XK_Insert, Qt::Key_Insert,
XK_Delete, Qt::Key_Delete,
XK_Clear, Qt::Key_Delete,
XK_Pause, Qt::Key_Pause,
XK_Print, Qt::Key_Print,
0x1005FF60, Qt::Key_SysReq, // hardcoded Sun SysReq
0x1007ff00, Qt::Key_SysReq, // hardcoded X386 SysReq
// cursor movement
XK_Home, Qt::Key_Home,
XK_End, Qt::Key_End,
XK_Left, Qt::Key_Left,
XK_Up, Qt::Key_Up,
XK_Right, Qt::Key_Right,
XK_Down, Qt::Key_Down,
XK_Prior, Qt::Key_PageUp,
XK_Next, Qt::Key_PageDown,
// modifiers
XK_Shift_L, Qt::Key_Shift,
XK_Shift_R, Qt::Key_Shift,
XK_Shift_Lock, Qt::Key_Shift,
XK_Control_L, Qt::Key_Control,
XK_Control_R, Qt::Key_Control,
XK_Meta_L, Qt::Key_Meta,
XK_Meta_R, Qt::Key_Meta,
XK_Alt_L, Qt::Key_Alt,
XK_Alt_R, Qt::Key_Alt,
XK_Caps_Lock, Qt::Key_CapsLock,
XK_Num_Lock, Qt::Key_NumLock,
XK_Scroll_Lock, Qt::Key_ScrollLock,
XK_Super_L, Qt::Key_Super_L,
XK_Super_R, Qt::Key_Super_R,
XK_Menu, Qt::Key_Menu,
XK_Hyper_L, Qt::Key_Hyper_L,
XK_Hyper_R, Qt::Key_Hyper_R,
XK_Help, Qt::Key_Help,
0x1000FF74, Qt::Key_Backtab, // hardcoded HP backtab
0x1005FF10, Qt::Key_F11, // hardcoded Sun F36 (labeled F11)
0x1005FF11, Qt::Key_F12, // hardcoded Sun F37 (labeled F12)
// numeric and function keypad keys
XK_KP_Enter, Qt::Key_Enter,
// special and additional keys
XK_Clear, Qt::Key_Clear,
XK_Delete, Qt::Key_Delete,
XK_space, Qt::Key_Space,
XK_exclam, Qt::Key_Exclam,
XK_quotedbl, Qt::Key_QuoteDbl,
XK_numbersign, Qt::Key_NumberSign,
XK_dollar, Qt::Key_Dollar,
XK_percent, Qt::Key_Percent,
XK_ampersand, Qt::Key_Ampersand,
XK_apostrophe, Qt::Key_Apostrophe,
XK_parenleft, Qt::Key_ParenLeft,
XK_parenright, Qt::Key_ParenRight,
XK_asterisk, Qt::Key_Asterisk,
XK_plus, Qt::Key_Plus,
XK_comma, Qt::Key_Comma,
XK_minus, Qt::Key_Minus,
XK_period, Qt::Key_Period,
XK_slash, Qt::Key_Slash,
XK_colon, Qt::Key_Colon,
XK_semicolon, Qt::Key_Semicolon,
XK_less, Qt::Key_Less,
XK_equal, Qt::Key_Equal,
XK_greater, Qt::Key_Greater,
XK_question, Qt::Key_Question,
XK_bracketleft, Qt::Key_BracketLeft,
XK_backslash, Qt::Key_Backslash,
XK_bracketright, Qt::Key_BracketRight,
XK_asciicircum, Qt::Key_AsciiCircum,
XK_underscore, Qt::Key_Underscore,
// International input method support keys
// International & multi-key character composition
XK_ISO_Level3_Shift, Qt::Key_AltGr,
XK_Multi_key, Qt::Key_Multi_key,
XK_Codeinput, Qt::Key_Codeinput,
XK_SingleCandidate, Qt::Key_SingleCandidate,
XK_MultipleCandidate, Qt::Key_MultipleCandidate,
XK_PreviousCandidate, Qt::Key_PreviousCandidate,
// Misc Functions
XK_Mode_switch, Qt::Key_Mode_switch,
XK_script_switch, Qt::Key_Mode_switch,
// Japanese keyboard support
XK_Kanji, Qt::Key_Kanji,
XK_Muhenkan, Qt::Key_Muhenkan,
//XK_Henkan_Mode, Qt::Key_Henkan_Mode,
XK_Henkan_Mode, Qt::Key_Henkan,
XK_Henkan, Qt::Key_Henkan,
XK_Romaji, Qt::Key_Romaji,
XK_Hiragana, Qt::Key_Hiragana,
XK_Katakana, Qt::Key_Katakana,
XK_Hiragana_Katakana, Qt::Key_Hiragana_Katakana,
XK_Zenkaku, Qt::Key_Zenkaku,
XK_Hankaku, Qt::Key_Hankaku,
XK_Zenkaku_Hankaku, Qt::Key_Zenkaku_Hankaku,
XK_Touroku, Qt::Key_Touroku,
XK_Massyo, Qt::Key_Massyo,
XK_Kana_Lock, Qt::Key_Kana_Lock,
XK_Kana_Shift, Qt::Key_Kana_Shift,
XK_Eisu_Shift, Qt::Key_Eisu_Shift,
XK_Eisu_toggle, Qt::Key_Eisu_toggle,
//XK_Kanji_Bangou, Qt::Key_Kanji_Bangou,
//XK_Zen_Koho, Qt::Key_Zen_Koho,
//XK_Mae_Koho, Qt::Key_Mae_Koho,
XK_Kanji_Bangou, Qt::Key_Codeinput,
XK_Zen_Koho, Qt::Key_MultipleCandidate,
XK_Mae_Koho, Qt::Key_PreviousCandidate,
#ifdef XK_KOREAN
// Korean keyboard support
XK_Hangul, Qt::Key_Hangul,
XK_Hangul_Start, Qt::Key_Hangul_Start,
XK_Hangul_End, Qt::Key_Hangul_End,
XK_Hangul_Hanja, Qt::Key_Hangul_Hanja,
XK_Hangul_Jamo, Qt::Key_Hangul_Jamo,
XK_Hangul_Romaja, Qt::Key_Hangul_Romaja,
//XK_Hangul_Codeinput, Qt::Key_Hangul_Codeinput,
XK_Hangul_Codeinput, Qt::Key_Codeinput,
XK_Hangul_Jeonja, Qt::Key_Hangul_Jeonja,
XK_Hangul_Banja, Qt::Key_Hangul_Banja,
XK_Hangul_PreHanja, Qt::Key_Hangul_PreHanja,
XK_Hangul_PostHanja, Qt::Key_Hangul_PostHanja,
//XK_Hangul_SingleCandidate,Qt::Key_Hangul_SingleCandidate,
//XK_Hangul_MultipleCandidate,Qt::Key_Hangul_MultipleCandidate,
//XK_Hangul_PreviousCandidate,Qt::Key_Hangul_PreviousCandidate,
XK_Hangul_SingleCandidate, Qt::Key_SingleCandidate,
XK_Hangul_MultipleCandidate,Qt::Key_MultipleCandidate,
XK_Hangul_PreviousCandidate,Qt::Key_PreviousCandidate,
XK_Hangul_Special, Qt::Key_Hangul_Special,
//XK_Hangul_switch, Qt::Key_Hangul_switch,
XK_Hangul_switch, Qt::Key_Mode_switch,
#endif // XK_KOREAN
// dead keys
XK_dead_grave, Qt::Key_Dead_Grave,
XK_dead_acute, Qt::Key_Dead_Acute,
XK_dead_circumflex, Qt::Key_Dead_Circumflex,
XK_dead_tilde, Qt::Key_Dead_Tilde,
XK_dead_macron, Qt::Key_Dead_Macron,
XK_dead_breve, Qt::Key_Dead_Breve,
XK_dead_abovedot, Qt::Key_Dead_Abovedot,
XK_dead_diaeresis, Qt::Key_Dead_Diaeresis,
XK_dead_abovering, Qt::Key_Dead_Abovering,
XK_dead_doubleacute, Qt::Key_Dead_Doubleacute,
XK_dead_caron, Qt::Key_Dead_Caron,
XK_dead_cedilla, Qt::Key_Dead_Cedilla,
XK_dead_ogonek, Qt::Key_Dead_Ogonek,
XK_dead_iota, Qt::Key_Dead_Iota,
XK_dead_voiced_sound, Qt::Key_Dead_Voiced_Sound,
XK_dead_semivoiced_sound, Qt::Key_Dead_Semivoiced_Sound,
XK_dead_belowdot, Qt::Key_Dead_Belowdot,
XK_dead_hook, Qt::Key_Dead_Hook,
XK_dead_horn, Qt::Key_Dead_Horn,
// Special multimedia keys
// currently only tested with MS internet keyboard
// browsing keys
XF86XK_Back, Qt::Key_Back,
XF86XK_Forward, Qt::Key_Forward,
XF86XK_Stop, Qt::Key_Stop,
XF86XK_Refresh, Qt::Key_Refresh,
XF86XK_Favorites, Qt::Key_Favorites,
XF86XK_AudioMedia, Qt::Key_LaunchMedia,
XF86XK_OpenURL, Qt::Key_OpenUrl,
XF86XK_HomePage, Qt::Key_HomePage,
XF86XK_Search, Qt::Key_Search,
// media keys
XF86XK_AudioLowerVolume, Qt::Key_VolumeDown,
XF86XK_AudioMute, Qt::Key_VolumeMute,
XF86XK_AudioRaiseVolume, Qt::Key_VolumeUp,
XF86XK_AudioPlay, Qt::Key_MediaPlay,
XF86XK_AudioStop, Qt::Key_MediaStop,
XF86XK_AudioPrev, Qt::Key_MediaPrevious,
XF86XK_AudioNext, Qt::Key_MediaNext,
XF86XK_AudioRecord, Qt::Key_MediaRecord,
// launch keys
XF86XK_Mail, Qt::Key_LaunchMail,
XF86XK_MyComputer, Qt::Key_Launch0,
XF86XK_Calculator, Qt::Key_Launch1,
XF86XK_Standby, Qt::Key_Standby,
XF86XK_Launch0, Qt::Key_Launch2,
XF86XK_Launch1, Qt::Key_Launch3,
XF86XK_Launch2, Qt::Key_Launch4,
XF86XK_Launch3, Qt::Key_Launch5,
XF86XK_Launch4, Qt::Key_Launch6,
XF86XK_Launch5, Qt::Key_Launch7,
XF86XK_Launch6, Qt::Key_Launch8,
XF86XK_Launch7, Qt::Key_Launch9,
XF86XK_Launch8, Qt::Key_LaunchA,
XF86XK_Launch9, Qt::Key_LaunchB,
XF86XK_LaunchA, Qt::Key_LaunchC,
XF86XK_LaunchB, Qt::Key_LaunchD,
XF86XK_LaunchC, Qt::Key_LaunchE,
XF86XK_LaunchD, Qt::Key_LaunchF,
// Qtopia keys
QTOPIAXK_Select, Qt::Key_Select,
QTOPIAXK_Yes, Qt::Key_Yes,
QTOPIAXK_No, Qt::Key_No,
QTOPIAXK_Cancel, Qt::Key_Cancel,
QTOPIAXK_Printer, Qt::Key_Printer,
QTOPIAXK_Execute, Qt::Key_Execute,
QTOPIAXK_Sleep, Qt::Key_Sleep,
QTOPIAXK_Play, Qt::Key_Play,
QTOPIAXK_Zoom, Qt::Key_Zoom,
QTOPIAXK_Context1, Qt::Key_Context1,
QTOPIAXK_Context2, Qt::Key_Context2,
QTOPIAXK_Context3, Qt::Key_Context3,
QTOPIAXK_Context4, Qt::Key_Context4,
QTOPIAXK_Call, Qt::Key_Call,
QTOPIAXK_Hangup, Qt::Key_Hangup,
QTOPIAXK_Flip, Qt::Key_Flip,
0, 0
};
#endif // KEYMAPPER_X11_H

View File

@@ -1,251 +0,0 @@
/****************************************************************************
** Copyright (c) 2006 - 2011, the LibQxt project.
** See the Qxt AUTHORS file for a list of authors and copyright holders.
** All rights reserved.
**
** Redistribution and use in source and binary forms, with or without
** modification, are permitted provided that the following conditions are met:
** * Redistributions of source code must retain the above copyright
** notice, this list of conditions and the following disclaimer.
** * Redistributions in binary form must reproduce the above copyright
** notice, this list of conditions and the following disclaimer in the
** documentation and/or other materials provided with the distribution.
** * Neither the name of the LibQxt project nor the
** names of its contributors may be used to endorse or promote products
** derived from this software without specific prior written permission.
**
** THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
** ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
** WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
** DISCLAIMED. IN NO EVENT SHALL <COPYRIGHT HOLDER> BE LIABLE FOR ANY
** DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
** (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
** LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
** ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
** (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
** SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
**
** <http://libqxt.org> <foundation@libqxt.org>
*****************************************************************************/
#include "qxtglobal.h"
/*!
\headerfile <QxtGlobal>
\title Global Qxt Declarations
\inmodule QxtCore
\brief The <QxtGlobal> header provides basic declarations and
is included by all other Qxt headers.
*/
/*!
\macro QXT_VERSION
\relates <QxtGlobal>
This macro expands a numeric value of the form 0xMMNNPP (MM =
major, NN = minor, PP = patch) that specifies Qxt's version
number. For example, if you compile your application against Qxt
0.4.0, the QXT_VERSION macro will expand to 0x000400.
You can use QXT_VERSION to use the latest Qt features where
available. For example:
\code
#if QXT_VERSION >= 0x000400
qxtTabWidget->setTabMovementMode(QxtTabWidget::InPlaceMovement);
#endif
\endcode
\sa QXT_VERSION_STR, qxtVersion()
*/
/*!
\macro QXT_VERSION_STR
\relates <QxtGlobal>
This macro expands to a string that specifies Qxt's version number
(for example, "0.4.0"). This is the version against which the
application is compiled.
\sa qxtVersion(), QXT_VERSION
*/
/*!
\relates <QxtGlobal>
Returns the version number of Qxt at run-time as a string (for
example, "0.4.0"). This may be a different version than the
version the application was compiled against.
\sa QXT_VERSION_STR
*/
const char * qxtVersion()
{
return QXT_VERSION_STR;
}
/*!
\headerfile <QxtPimpl>
\title The Qxt private implementation
\inmodule QxtCore
\brief The <QxtPimpl> header provides tools for hiding
details of a class.
Application code generally doesn't have to be concerned about hiding its
implementation details, but when writing library code it is important to
maintain a constant interface, both source and binary. Maintaining a constant
source interface is easy enough, but keeping the binary interface constant
means moving implementation details into a private class. The PIMPL, or
d-pointer, idiom is a common method of implementing this separation. QxtPimpl
offers a convenient way to connect the public and private sides of your class.
\section1 Getting Started
Before you declare the public class, you need to make a forward declaration
of the private class. The private class must have the same name as the public
class, followed by the word Private. For example, a class named MyTest would
declare the private class with:
\code
class MyTestPrivate;
\endcode
\section1 The Public Class
Generally, you shouldn't keep any data members in the public class without a
good reason. Functions that are part of the public interface should be declared
in the public class, and functions that need to be available to subclasses (for
calling or overriding) should be in the protected section of the public class.
To connect the private class to the public class, include the
QXT_DECLARE_PRIVATE macro in the private section of the public class. In the
example above, the private class is connected as follows:
\code
private:
QXT_DECLARE_PRIVATE(MyTest)
\endcode
Additionally, you must include the QXT_INIT_PRIVATE macro in the public class's
constructor. Continuing with the MyTest example, your constructor might look
like this:
\code
MyTest::MyTest() {
// initialization
QXT_INIT_PRIVATE(MyTest);
}
\endcode
\section1 The Private Class
As mentioned above, data members should usually be kept in the private class.
This allows the memory layout of the private class to change without breaking
binary compatibility for the public class. Functions that exist only as
implementation details, or functions that need access to private data members,
should be implemented here.
To define the private class, inherit from the template QxtPrivate class, and
include the QXT_DECLARE_PUBLIC macro in its public section. The template
parameter should be the name of the public class. For example:
\code
class MyTestPrivate : public QxtPrivate<MyTest> {
public:
MyTestPrivate();
QXT_DECLARE_PUBLIC(MyTest)
};
\endcode
\section1 Accessing Private Members
Use the qxt_d() function (actually a function-like object) from functions in
the public class to access the private class. Similarly, functions in the
private class can invoke functions in the public class by using the qxt_p()
function (this one's actually a function).
For example, assume that MyTest has methods named getFoobar and doBaz(),
and MyTestPrivate has a member named foobar and a method named doQuux().
The code might resemble this example:
\code
int MyTest::getFoobar() {
return qxt_d().foobar;
}
void MyTestPrivate::doQuux() {
qxt_p().doBaz(foobar);
}
\endcode
*/
/*!
* \macro QXT_DECLARE_PRIVATE(PUB)
* \relates <QxtPimpl>
* Declares that a public class has a related private class.
*
* This shuold be put in the private section of the public class. The
* parameter \a PUB must be the name of the public class.
*/
/*!
* \macro QXT_DECLARE_PUBLIC(PUB)
* \relates <QxtPimpl>
* Declares that a private class has a related public class named \a PUB.
*
* This may be put anywhere in the declaration of the private class. The parameter is the name of the public class.
*/
/*!
* \macro QXT_INIT_PRIVATE(PUB)
* \relates <QxtPimpl>
* Initializes resources owned by the private class.
*
* This should be called from the public class's constructor,
* before qxt_d() is used for the first time. The parameter \a PUB must be
* the name of the public class.
*/
/*!
* \macro QXT_D(PUB)
* \relates <QxtPimpl>
* Returns a reference in the current scope named "d" to the private class
* associated with the public class \a PUB.
*
* This function is only available in a class using QXT_DECLARE_PRIVATE().
*/
/*!
* \macro QXT_P(PUB)
* \relates <QxtPimpl>
* Creates a reference in the current scope named "q" to the public class
* named \a PUB.
*
* This macro only works in a class using QXT_DECLARE_PUBLIC().
*/
/*!
* \fn QxtPrivate<PUB>& PUB::qxt_d()
* \relates <QxtPimpl>
* Returns a reference to the private class.
*
* This function is only available in a class using \a QXT_DECLARE_PRIVATE.
*/
/*!
* \fn const QxtPrivate<PUB>& PUB::qxt_d() const
* \relates <QxtPimpl>
* Returns a const reference to the private class.
*
* This function is only available in a class using \a QXT_DECLARE_PRIVATE.
* This overload will be automatically used in const functions.
*/
/*!
* \fn PUB& QxtPrivate::qxt_p()
* \relates <QxtPimpl>
* Returns a reference to the public class.
*
* This function is only available in a class using QXT_DECLARE_PUBLIC().
*/
/*!
* \fn const PUB& QxtPrivate::qxt_p() const
* \relates <QxtPimpl>
* Returns a const reference to the public class.
*
* This function is only available in a class using QXT_DECLARE_PUBLIC().
* This overload will be automatically used in const functions.
*/

View File

@@ -1,233 +0,0 @@
/****************************************************************************
** Copyright (c) 2006 - 2011, the LibQxt project.
** See the Qxt AUTHORS file for a list of authors and copyright holders.
** All rights reserved.
**
** Redistribution and use in source and binary forms, with or without
** modification, are permitted provided that the following conditions are met:
** * Redistributions of source code must retain the above copyright
** notice, this list of conditions and the following disclaimer.
** * Redistributions in binary form must reproduce the above copyright
** notice, this list of conditions and the following disclaimer in the
** documentation and/or other materials provided with the distribution.
** * Neither the name of the LibQxt project nor the
** names of its contributors may be used to endorse or promote products
** derived from this software without specific prior written permission.
**
** THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
** ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
** WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
** DISCLAIMED. IN NO EVENT SHALL <COPYRIGHT HOLDER> BE LIABLE FOR ANY
** DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
** (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
** LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
** ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
** (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
** SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
**
** <http://libqxt.org> <foundation@libqxt.org>
*****************************************************************************/
#ifndef QXTGLOBAL_H
#define QXTGLOBAL_H
#include <QtGlobal>
#define QXT_VERSION 0x000700
#define QXT_VERSION_STR "0.7.0"
//--------------------------global macros------------------------------
#ifndef QXT_NO_MACROS
#ifndef _countof
#define _countof(x) (sizeof(x)/sizeof(*x))
#endif
#endif // QXT_NO_MACROS
//--------------------------export macros------------------------------
#define QXT_DLLEXPORT DO_NOT_USE_THIS_ANYMORE
#if !defined(QXT_STATIC) && !defined(QXT_DOXYGEN_RUN)
# if defined(BUILD_QXT_CORE)
# define QXT_CORE_EXPORT Q_DECL_EXPORT
# else
# define QXT_CORE_EXPORT Q_DECL_IMPORT
# endif
#else
# define QXT_CORE_EXPORT
#endif // BUILD_QXT_CORE
#if !defined(QXT_STATIC) && !defined(QXT_DOXYGEN_RUN)
# if defined(BUILD_QXT_GUI)
# define QXT_GUI_EXPORT Q_DECL_EXPORT
# else
# define QXT_GUI_EXPORT Q_DECL_IMPORT
# endif
#else
# define QXT_GUI_EXPORT
#endif // BUILD_QXT_GUI
#if !defined(QXT_STATIC) && !defined(QXT_DOXYGEN_RUN)
# if defined(BUILD_QXT_NETWORK)
# define QXT_NETWORK_EXPORT Q_DECL_EXPORT
# else
# define QXT_NETWORK_EXPORT Q_DECL_IMPORT
# endif
#else
# define QXT_NETWORK_EXPORT
#endif // BUILD_QXT_NETWORK
#if !defined(QXT_STATIC) && !defined(QXT_DOXYGEN_RUN)
# if defined(BUILD_QXT_SQL)
# define QXT_SQL_EXPORT Q_DECL_EXPORT
# else
# define QXT_SQL_EXPORT Q_DECL_IMPORT
# endif
#else
# define QXT_SQL_EXPORT
#endif // BUILD_QXT_SQL
#if !defined(QXT_STATIC) && !defined(QXT_DOXYGEN_RUN)
# if defined(BUILD_QXT_WEB)
# define QXT_WEB_EXPORT Q_DECL_EXPORT
# else
# define QXT_WEB_EXPORT Q_DECL_IMPORT
# endif
#else
# define QXT_WEB_EXPORT
#endif // BUILD_QXT_WEB
#if !defined(QXT_STATIC) && !defined(QXT_DOXYGEN_RUN)
# if defined(BUILD_QXT_BERKELEY)
# define QXT_BERKELEY_EXPORT Q_DECL_EXPORT
# else
# define QXT_BERKELEY_EXPORT Q_DECL_IMPORT
# endif
#else
# define QXT_BERKELEY_EXPORT
#endif // BUILD_QXT_BERKELEY
#if !defined(QXT_STATIC) && !defined(QXT_DOXYGEN_RUN)
# if defined(BUILD_QXT_ZEROCONF)
# define QXT_ZEROCONF_EXPORT Q_DECL_EXPORT
# else
# define QXT_ZEROCONF_EXPORT Q_DECL_IMPORT
# endif
#else
# define QXT_ZEROCONF_EXPORT
#endif // QXT_ZEROCONF_EXPORT
#if defined(BUILD_QXT_CORE) || defined(BUILD_QXT_GUI) || defined(BUILD_QXT_SQL) || defined(BUILD_QXT_NETWORK) || defined(BUILD_QXT_WEB) || defined(BUILD_QXT_BERKELEY) || defined(BUILD_QXT_ZEROCONF)
# define BUILD_QXT
#endif
QXT_CORE_EXPORT const char* qxtVersion();
#ifndef QT_BEGIN_NAMESPACE
#define QT_BEGIN_NAMESPACE
#endif
#ifndef QT_END_NAMESPACE
#define QT_END_NAMESPACE
#endif
#ifndef QT_FORWARD_DECLARE_CLASS
#define QT_FORWARD_DECLARE_CLASS(Class) class Class;
#endif
/****************************************************************************
** This file is derived from code bearing the following notice:
** The sole author of this file, Adam Higerd, has explicitly disclaimed all
** copyright interest and protection for the content within. This file has
** been placed in the public domain according to United States copyright
** statute and case law. In jurisdictions where this public domain dedication
** is not legally recognized, anyone who receives a copy of this file is
** permitted to use, modify, duplicate, and redistribute this file, in whole
** or in part, with no restrictions or conditions. In these jurisdictions,
** this file shall be copyright (C) 2006-2008 by Adam Higerd.
****************************************************************************/
#define QXT_DECLARE_PRIVATE(PUB) friend class PUB##Private; QxtPrivateInterface<PUB, PUB##Private> qxt_d;
#define QXT_DECLARE_PUBLIC(PUB) friend class PUB;
#define QXT_INIT_PRIVATE(PUB) qxt_d.setPublic(this);
#define QXT_D(PUB) PUB##Private& d = qxt_d()
#define QXT_P(PUB) PUB& p = qxt_p()
template <typename PUB>
class QxtPrivate
{
public:
virtual ~QxtPrivate()
{}
inline void QXT_setPublic(PUB* pub)
{
qxt_p_ptr = pub;
}
protected:
inline PUB& qxt_p()
{
return *qxt_p_ptr;
}
inline const PUB& qxt_p() const
{
return *qxt_p_ptr;
}
inline PUB* qxt_ptr()
{
return qxt_p_ptr;
}
inline const PUB* qxt_ptr() const
{
return qxt_p_ptr;
}
private:
PUB* qxt_p_ptr;
};
template <typename PUB, typename PVT>
class QxtPrivateInterface
{
friend class QxtPrivate<PUB>;
public:
QxtPrivateInterface()
{
pvt = new PVT;
}
~QxtPrivateInterface()
{
delete pvt;
}
inline void setPublic(PUB* pub)
{
pvt->QXT_setPublic(pub);
}
inline PVT& operator()()
{
return *static_cast<PVT*>(pvt);
}
inline const PVT& operator()() const
{
return *static_cast<PVT*>(pvt);
}
inline PVT * operator->()
{
return static_cast<PVT*>(pvt);
}
inline const PVT * operator->() const
{
return static_cast<PVT*>(pvt);
}
private:
QxtPrivateInterface(const QxtPrivateInterface&) { }
QxtPrivateInterface& operator=(const QxtPrivateInterface&) { }
QxtPrivate<PUB>* pvt;
};
#endif // QXT_GLOBAL

View File

@@ -1,222 +0,0 @@
#include "qxtglobalshortcut.h"
/****************************************************************************
** Copyright (c) 2006 - 2011, the LibQxt project.
** See the Qxt AUTHORS file for a list of authors and copyright holders.
** All rights reserved.
**
** Redistribution and use in source and binary forms, with or without
** modification, are permitted provided that the following conditions are met:
** * Redistributions of source code must retain the above copyright
** notice, this list of conditions and the following disclaimer.
** * Redistributions in binary form must reproduce the above copyright
** notice, this list of conditions and the following disclaimer in the
** documentation and/or other materials provided with the distribution.
** * Neither the name of the LibQxt project nor the
** names of its contributors may be used to endorse or promote products
** derived from this software without specific prior written permission.
**
** THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
** ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
** WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
** DISCLAIMED. IN NO EVENT SHALL <COPYRIGHT HOLDER> BE LIABLE FOR ANY
** DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
** (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
** LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
** ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
** (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
** SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
**
** <http://libqxt.org> <foundation@libqxt.org>
*****************************************************************************/
#include <QtGlobal>
#include <QAbstractEventDispatcher>
#include <QHash>
#include <QPair>
#include <QtDebug>
#include "qxtglobalshortcut_p.h"
bool QxtGlobalShortcutPrivate::error = false;
#ifndef Q_WS_MAC
int QxtGlobalShortcutPrivate::ref = 0;
#if QT_VERSION < QT_VERSION_CHECK(5,0,0)
QAbstractEventDispatcher::EventFilter QxtGlobalShortcutPrivate::prevEventFilter = 0;
#endif
#endif // Q_WS_MAC
QHash<QPair<quint32, quint32>, QxtGlobalShortcut*> QxtGlobalShortcutPrivate::shortcuts;
QxtGlobalShortcutPrivate::QxtGlobalShortcutPrivate() : enabled(true), key(Qt::Key(0)), mods(Qt::NoModifier)
{
#ifndef Q_WS_MAC
if (!ref++)
#if QT_VERSION < QT_VERSION_CHECK(5,0,0)
prevEventFilter = QAbstractEventDispatcher::instance()->setEventFilter(eventFilter);
#else
QAbstractEventDispatcher::instance()->installNativeEventFilter(this);
#endif
#endif // Q_WS_MAC
}
QxtGlobalShortcutPrivate::~QxtGlobalShortcutPrivate()
{
#ifndef Q_WS_MAC
if (!--ref)
#if QT_VERSION < QT_VERSION_CHECK(5,0,0)
QAbstractEventDispatcher::instance()->setEventFilter(prevEventFilter);
#else
QAbstractEventDispatcher::instance()->removeNativeEventFilter(this);
#endif
#endif // Q_WS_MAC
}
bool QxtGlobalShortcutPrivate::setShortcut(const QKeySequence& shortcut)
{
Qt::KeyboardModifiers allMods = Qt::ShiftModifier | Qt::ControlModifier | Qt::AltModifier | Qt::MetaModifier;
key = shortcut.isEmpty() ? Qt::Key(0) : Qt::Key((shortcut[0] ^ allMods) & shortcut[0]);
mods = shortcut.isEmpty() ? Qt::KeyboardModifiers(0) : Qt::KeyboardModifiers(shortcut[0] & allMods);
const quint32 nativeKey = nativeKeycode(key);
const quint32 nativeMods = nativeModifiers(mods);
const bool res = registerShortcut(nativeKey, nativeMods);
if (res)
shortcuts.insert(qMakePair(nativeKey, nativeMods), &qxt_p());
else
qWarning() << "QxtGlobalShortcut failed to register:" << QKeySequence(key + mods).toString();
return res;
}
bool QxtGlobalShortcutPrivate::unsetShortcut()
{
bool res = false;
const quint32 nativeKey = nativeKeycode(key);
const quint32 nativeMods = nativeModifiers(mods);
if (shortcuts.value(qMakePair(nativeKey, nativeMods)) == &qxt_p())
res = unregisterShortcut(nativeKey, nativeMods);
if (res)
shortcuts.remove(qMakePair(nativeKey, nativeMods));
else
qWarning() << "QxtGlobalShortcut failed to unregister:" << QKeySequence(key + mods).toString();
key = Qt::Key(0);
mods = Qt::KeyboardModifiers(0);
return res;
}
void QxtGlobalShortcutPrivate::activateShortcut(quint32 nativeKey, quint32 nativeMods)
{
QxtGlobalShortcut* shortcut = shortcuts.value(qMakePair(nativeKey, nativeMods));
if (shortcut && shortcut->isEnabled())
emit shortcut->activated();
}
/*!
\class QxtGlobalShortcut
\inmodule QxtWidgets
\brief The QxtGlobalShortcut class provides a global shortcut aka "hotkey".
A global shortcut triggers even if the application is not active. This
makes it easy to implement applications that react to certain shortcuts
still if some other application is active or if the application is for
example minimized to the system tray.
Example usage:
\code
QxtGlobalShortcut* shortcut = new QxtGlobalShortcut(window);
connect(shortcut, SIGNAL(activated()), window, SLOT(toggleVisibility()));
shortcut->setShortcut(QKeySequence("Ctrl+Shift+F12"));
\endcode
\bold {Note:} Since Qxt 0.6 QxtGlobalShortcut no more requires QxtApplication.
*/
/*!
\fn QxtGlobalShortcut::activated()
This signal is emitted when the user types the shortcut's key sequence.
\sa shortcut
*/
/*!
Constructs a new QxtGlobalShortcut with \a parent.
*/
QxtGlobalShortcut::QxtGlobalShortcut(QObject* parent)
: QObject(parent)
{
QXT_INIT_PRIVATE(QxtGlobalShortcut);
}
/*!
Constructs a new QxtGlobalShortcut with \a shortcut and \a parent.
*/
QxtGlobalShortcut::QxtGlobalShortcut(const QKeySequence& shortcut, QObject* parent)
: QObject(parent)
{
QXT_INIT_PRIVATE(QxtGlobalShortcut);
setShortcut(shortcut);
}
/*!
Destructs the QxtGlobalShortcut.
*/
QxtGlobalShortcut::~QxtGlobalShortcut()
{
if (qxt_d().key != 0)
qxt_d().unsetShortcut();
}
/*!
\property QxtGlobalShortcut::shortcut
\brief the shortcut key sequence
\bold {Note:} Notice that corresponding key press and release events are not
delivered for registered global shortcuts even if they are disabled.
Also, comma separated key sequences are not supported.
Only the first part is used:
\code
qxtShortcut->setShortcut(QKeySequence("Ctrl+Alt+A,Ctrl+Alt+B"));
Q_ASSERT(qxtShortcut->shortcut() == QKeySequence("Ctrl+Alt+A"));
\endcode
*/
QKeySequence QxtGlobalShortcut::shortcut() const
{
return QKeySequence(qxt_d().key | qxt_d().mods);
}
bool QxtGlobalShortcut::setShortcut(const QKeySequence& shortcut)
{
if (qxt_d().key != 0)
qxt_d().unsetShortcut();
return qxt_d().setShortcut(shortcut);
}
/*!
\property QxtGlobalShortcut::enabled
\brief whether the shortcut is enabled
A disabled shortcut does not get activated.
The default value is \c true.
\sa setDisabled()
*/
bool QxtGlobalShortcut::isEnabled() const
{
return qxt_d().enabled;
}
void QxtGlobalShortcut::setEnabled(bool enabled)
{
qxt_d().enabled = enabled;
}
/*!
Sets the shortcut \a disabled.
\sa enabled
*/
void QxtGlobalShortcut::setDisabled(bool disabled)
{
qxt_d().enabled = !disabled;
}

View File

@@ -1,68 +0,0 @@
#ifndef QXTGLOBALSHORTCUT_H
/****************************************************************************
** Copyright (c) 2006 - 2011, the LibQxt project.
** See the Qxt AUTHORS file for a list of authors and copyright holders.
** All rights reserved.
**
** Redistribution and use in source and binary forms, with or without
** modification, are permitted provided that the following conditions are met:
** * Redistributions of source code must retain the above copyright
** notice, this list of conditions and the following disclaimer.
** * Redistributions in binary form must reproduce the above copyright
** notice, this list of conditions and the following disclaimer in the
** documentation and/or other materials provided with the distribution.
** * Neither the name of the LibQxt project nor the
** names of its contributors may be used to endorse or promote products
** derived from this software without specific prior written permission.
**
** THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
** ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
** WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
** DISCLAIMED. IN NO EVENT SHALL <COPYRIGHT HOLDER> BE LIABLE FOR ANY
** DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
** (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
** LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
** ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
** (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
** SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
**
** <http://libqxt.org> <foundation@libqxt.org>
*****************************************************************************/
#define QXTGLOBALSHORTCUT_H
#include <QObject>
#include <QKeySequence>
#include <QString>
#include "qxtglobal.h"
class QxtGlobalShortcutPrivate;
class QXT_GUI_EXPORT QxtGlobalShortcut : public QObject
{
Q_OBJECT
QXT_DECLARE_PRIVATE(QxtGlobalShortcut)
Q_PROPERTY(bool enabled READ isEnabled WRITE setEnabled)
Q_PROPERTY(QKeySequence shortcut READ shortcut WRITE setShortcut)
public:
explicit QxtGlobalShortcut(QObject* parent = 0);
explicit QxtGlobalShortcut(const QKeySequence& shortcut, QObject* parent = 0);
virtual ~QxtGlobalShortcut();
QKeySequence shortcut() const;
bool setShortcut(const QKeySequence& shortcut);
bool isEnabled() const;
public Q_SLOTS:
void setEnabled(bool enabled = true);
void setDisabled(bool disabled = true);
Q_SIGNALS:
void activated();
};
#endif // QXTGLOBALSHORTCUT_H

View File

@@ -1,258 +0,0 @@
#include <Carbon/Carbon.h>
/****************************************************************************
** Copyright (c) 2006 - 2011, the LibQxt project.
** See the Qxt AUTHORS file for a list of authors and copyright holders.
** All rights reserved.
**
** Redistribution and use in source and binary forms, with or without
** modification, are permitted provided that the following conditions are met:
** * Redistributions of source code must retain the above copyright
** notice, this list of conditions and the following disclaimer.
** * Redistributions in binary form must reproduce the above copyright
** notice, this list of conditions and the following disclaimer in the
** documentation and/or other materials provided with the distribution.
** * Neither the name of the LibQxt project nor the
** names of its contributors may be used to endorse or promote products
** derived from this software without specific prior written permission.
**
** THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
** ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
** WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
** DISCLAIMED. IN NO EVENT SHALL <COPYRIGHT HOLDER> BE LIABLE FOR ANY
** DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
** (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
** LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
** ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
** (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
** SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
**
** <http://libqxt.org> <foundation@libqxt.org>
*****************************************************************************/
#include "qxtglobalshortcut_p.h"
#include <QMap>
#include <QHash>
#include <QtDebug>
#include <QApplication>
typedef QPair<uint, uint> Identifier;
static QMap<quint32, EventHotKeyRef> keyRefs;
static QHash<Identifier, quint32> keyIDs;
static quint32 hotKeySerial = 0;
static bool qxt_mac_handler_installed = false;
OSStatus qxt_mac_handle_hot_key(EventHandlerCallRef nextHandler, EventRef event, void* data)
{
Q_UNUSED(nextHandler);
Q_UNUSED(data);
if (GetEventClass(event) == kEventClassKeyboard && GetEventKind(event) == kEventHotKeyPressed)
{
EventHotKeyID keyID;
GetEventParameter(event, kEventParamDirectObject, typeEventHotKeyID, NULL, sizeof(keyID), NULL, &keyID);
Identifier id = keyIDs.key(keyID.id);
QxtGlobalShortcutPrivate::activateShortcut(id.second, id.first);
}
return noErr;
}
quint32 QxtGlobalShortcutPrivate::nativeModifiers(Qt::KeyboardModifiers modifiers)
{
quint32 native = 0;
if (modifiers & Qt::ShiftModifier)
native |= shiftKey;
if (modifiers & Qt::ControlModifier)
native |= cmdKey;
if (modifiers & Qt::AltModifier)
native |= optionKey;
if (modifiers & Qt::MetaModifier)
native |= controlKey;
if (modifiers & Qt::KeypadModifier)
native |= kEventKeyModifierNumLockMask;
return native;
}
quint32 QxtGlobalShortcutPrivate::nativeKeycode(Qt::Key key)
{
UTF16Char ch;
// Constants found in NSEvent.h from AppKit.framework
switch (key)
{
case Qt::Key_Return:
return kVK_Return;
case Qt::Key_Enter:
return kVK_ANSI_KeypadEnter;
case Qt::Key_Tab:
return kVK_Tab;
case Qt::Key_Space:
return kVK_Space;
case Qt::Key_Backspace:
return kVK_Delete;
case Qt::Key_Control:
return kVK_Command;
case Qt::Key_Shift:
return kVK_Shift;
case Qt::Key_CapsLock:
return kVK_CapsLock;
case Qt::Key_Option:
return kVK_Option;
case Qt::Key_Meta:
return kVK_Control;
case Qt::Key_F17:
return kVK_F17;
case Qt::Key_VolumeUp:
return kVK_VolumeUp;
case Qt::Key_VolumeDown:
return kVK_VolumeDown;
case Qt::Key_F18:
return kVK_F18;
case Qt::Key_F19:
return kVK_F19;
case Qt::Key_F20:
return kVK_F20;
case Qt::Key_F5:
return kVK_F5;
case Qt::Key_F6:
return kVK_F6;
case Qt::Key_F7:
return kVK_F7;
case Qt::Key_F3:
return kVK_F3;
case Qt::Key_F8:
return kVK_F8;
case Qt::Key_F9:
return kVK_F9;
case Qt::Key_F11:
return kVK_F11;
case Qt::Key_F13:
return kVK_F13;
case Qt::Key_F16:
return kVK_F16;
case Qt::Key_F14:
return kVK_F14;
case Qt::Key_F10:
return kVK_F10;
case Qt::Key_F12:
return kVK_F12;
case Qt::Key_F15:
return kVK_F15;
case Qt::Key_Help:
return kVK_Help;
case Qt::Key_Home:
return kVK_Home;
case Qt::Key_PageUp:
return kVK_PageUp;
case Qt::Key_Delete:
return kVK_ForwardDelete;
case Qt::Key_F4:
return kVK_F4;
case Qt::Key_End:
return kVK_End;
case Qt::Key_F2:
return kVK_F2;
case Qt::Key_PageDown:
return kVK_PageDown;
case Qt::Key_F1:
return kVK_F1;
case Qt::Key_Left:
return kVK_LeftArrow;
case Qt::Key_Right:
return kVK_RightArrow;
case Qt::Key_Down:
return kVK_DownArrow;
case Qt::Key_Up:
return kVK_UpArrow;
default:
;
}
if (key == Qt::Key_Escape) ch = 27;
else if (key == Qt::Key_Return) ch = 13;
else if (key == Qt::Key_Enter) ch = 3;
else if (key == Qt::Key_Tab) ch = 9;
else ch = key;
CFDataRef currentLayoutData;
TISInputSourceRef currentKeyboard = TISCopyCurrentKeyboardInputSource();
if (currentKeyboard == NULL)
return 0;
currentLayoutData = (CFDataRef)TISGetInputSourceProperty(currentKeyboard, kTISPropertyUnicodeKeyLayoutData);
CFRelease(currentKeyboard);
if (currentLayoutData == NULL)
return 0;
UCKeyboardLayout* header = (UCKeyboardLayout*)CFDataGetBytePtr(currentLayoutData);
UCKeyboardTypeHeader* table = header->keyboardTypeList;
uint8_t *data = (uint8_t*)header;
// God, would a little documentation for this shit kill you...
for (quint32 i=0; i < header->keyboardTypeCount; i++)
{
UCKeyStateRecordsIndex* stateRec = 0;
if (table[i].keyStateRecordsIndexOffset != 0)
{
stateRec = reinterpret_cast<UCKeyStateRecordsIndex*>(data + table[i].keyStateRecordsIndexOffset);
if (stateRec->keyStateRecordsIndexFormat != kUCKeyStateRecordsIndexFormat) stateRec = 0;
}
UCKeyToCharTableIndex* charTable = reinterpret_cast<UCKeyToCharTableIndex*>(data + table[i].keyToCharTableIndexOffset);
if (charTable->keyToCharTableIndexFormat != kUCKeyToCharTableIndexFormat) continue;
for (quint32 j=0; j < charTable->keyToCharTableCount; j++)
{
UCKeyOutput* keyToChar = reinterpret_cast<UCKeyOutput*>(data + charTable->keyToCharTableOffsets[j]);
for (quint32 k=0; k < charTable->keyToCharTableSize; k++)
{
if (keyToChar[k] & kUCKeyOutputTestForIndexMask)
{
long idx = keyToChar[k] & kUCKeyOutputGetIndexMask;
if (stateRec && idx < stateRec->keyStateRecordCount)
{
UCKeyStateRecord* rec = reinterpret_cast<UCKeyStateRecord*>(data + stateRec->keyStateRecordOffsets[idx]);
if (rec->stateZeroCharData == ch) return k;
}
}
else if (!(keyToChar[k] & kUCKeyOutputSequenceIndexMask) && keyToChar[k] < 0xFFFE)
{
if (keyToChar[k] == ch) return k;
}
} // for k
} // for j
} // for i
return 0;
}
bool QxtGlobalShortcutPrivate::registerShortcut(quint32 nativeKey, quint32 nativeMods)
{
if (!qxt_mac_handler_installed)
{
EventTypeSpec t;
t.eventClass = kEventClassKeyboard;
t.eventKind = kEventHotKeyPressed;
InstallApplicationEventHandler(&qxt_mac_handle_hot_key, 1, &t, NULL, NULL);
}
EventHotKeyID keyID;
keyID.signature = 'cute';
keyID.id = ++hotKeySerial;
EventHotKeyRef ref = 0;
bool rv = !RegisterEventHotKey(nativeKey, nativeMods, keyID, GetApplicationEventTarget(), 0, &ref);
if (rv)
{
keyIDs.insert(Identifier(nativeMods, nativeKey), keyID.id);
keyRefs.insert(keyID.id, ref);
}
return rv;
}
bool QxtGlobalShortcutPrivate::unregisterShortcut(quint32 nativeKey, quint32 nativeMods)
{
Identifier id(nativeMods, nativeKey);
if (!keyIDs.contains(id)) return false;
EventHotKeyRef ref = keyRefs.take(keyIDs[id]);
keyIDs.remove(id);
return !UnregisterEventHotKey(ref);
}

View File

@@ -1,84 +0,0 @@
#ifndef QXTGLOBALSHORTCUT_P_H
/****************************************************************************
** Copyright (c) 2006 - 2011, the LibQxt project.
** See the Qxt AUTHORS file for a list of authors and copyright holders.
** All rights reserved.
**
** Redistribution and use in source and binary forms, with or without
** modification, are permitted provided that the following conditions are met:
** * Redistributions of source code must retain the above copyright
** notice, this list of conditions and the following disclaimer.
** * Redistributions in binary form must reproduce the above copyright
** notice, this list of conditions and the following disclaimer in the
** documentation and/or other materials provided with the distribution.
** * Neither the name of the LibQxt project nor the
** names of its contributors may be used to endorse or promote products
** derived from this software without specific prior written permission.
**
** THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
** ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
** WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
** DISCLAIMED. IN NO EVENT SHALL <COPYRIGHT HOLDER> BE LIABLE FOR ANY
** DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
** (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
** LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
** ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
** (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
** SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
**
** <http://libqxt.org> <foundation@libqxt.org>
*****************************************************************************/
#define QXTGLOBALSHORTCUT_P_H
#include "qxtglobalshortcut.h"
#include <QAbstractEventDispatcher>
#include <QKeySequence>
#include <QHash>
#if QT_VERSION >= QT_VERSION_CHECK(5,0,0)
#include <QAbstractNativeEventFilter>
#endif
class QxtGlobalShortcutPrivate : public QxtPrivate<QxtGlobalShortcut>
#if QT_VERSION >= QT_VERSION_CHECK(5,0,0)
,public QAbstractNativeEventFilter
#endif
{
public:
QXT_DECLARE_PUBLIC(QxtGlobalShortcut)
QxtGlobalShortcutPrivate();
~QxtGlobalShortcutPrivate();
bool enabled;
Qt::Key key;
Qt::KeyboardModifiers mods;
bool setShortcut(const QKeySequence& shortcut);
bool unsetShortcut();
static bool error;
#ifndef Q_WS_MAC
static int ref;
#if QT_VERSION < QT_VERSION_CHECK(5,0,0)
static QAbstractEventDispatcher::EventFilter prevEventFilter;
static bool eventFilter(void* message);
#else
virtual bool nativeEventFilter(const QByteArray & eventType, void * message, long * result);
#endif // QT_VERSION < QT_VERSION_CHECK(5,0,0)
#endif // Q_WS_MAC
static void activateShortcut(quint32 nativeKey, quint32 nativeMods);
private:
static quint32 nativeKeycode(Qt::Key keycode);
static quint32 nativeModifiers(Qt::KeyboardModifiers modifiers);
static bool registerShortcut(quint32 nativeKey, quint32 nativeMods);
static bool unregisterShortcut(quint32 nativeKey, quint32 nativeMods);
static QHash<QPair<quint32, quint32>, QxtGlobalShortcut*> shortcuts;
};
#endif // QXTGLOBALSHORTCUT_P_H

View File

@@ -1,247 +0,0 @@
#include "qxtglobalshortcut_p.h"
/****************************************************************************
** Copyright (c) 2006 - 2011, the LibQxt project.
** See the Qxt AUTHORS file for a list of authors and copyright holders.
** All rights reserved.
**
** Redistribution and use in source and binary forms, with or without
** modification, are permitted provided that the following conditions are met:
** * Redistributions of source code must retain the above copyright
** notice, this list of conditions and the following disclaimer.
** * Redistributions in binary form must reproduce the above copyright
** notice, this list of conditions and the following disclaimer in the
** documentation and/or other materials provided with the distribution.
** * Neither the name of the LibQxt project nor the
** names of its contributors may be used to endorse or promote products
** derived from this software without specific prior written permission.
**
** THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
** ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
** WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
** DISCLAIMED. IN NO EVENT SHALL <COPYRIGHT HOLDER> BE LIABLE FOR ANY
** DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
** (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
** LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
** ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
** (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
** SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
**
** <http://libqxt.org> <foundation@libqxt.org>
*****************************************************************************/
#include <qt_windows.h>
#if QT_VERSION < QT_VERSION_CHECK(5,0,0)
bool QxtGlobalShortcutPrivate::eventFilter(void* message)
{
#else
bool QxtGlobalShortcutPrivate::nativeEventFilter(const QByteArray & eventType,
void * message, long * result)
{
Q_UNUSED(eventType);
Q_UNUSED(result);
#endif
MSG* msg = static_cast<MSG*>(message);
if (msg->message == WM_HOTKEY)
{
const quint32 keycode = HIWORD(msg->lParam);
const quint32 modifiers = LOWORD(msg->lParam);
activateShortcut(keycode, modifiers);
}
return false;
}
quint32 QxtGlobalShortcutPrivate::nativeModifiers(Qt::KeyboardModifiers modifiers)
{
// MOD_ALT, MOD_CONTROL, (MOD_KEYUP), MOD_SHIFT, MOD_WIN
quint32 native = 0;
if (modifiers & Qt::ShiftModifier)
native |= MOD_SHIFT;
if (modifiers & Qt::ControlModifier)
native |= MOD_CONTROL;
if (modifiers & Qt::AltModifier)
native |= MOD_ALT;
if (modifiers & Qt::MetaModifier)
native |= MOD_WIN;
// TODO: resolve these?
//if (modifiers & Qt::KeypadModifier)
//if (modifiers & Qt::GroupSwitchModifier)
return native;
}
quint32 QxtGlobalShortcutPrivate::nativeKeycode(Qt::Key key)
{
switch (key)
{
case Qt::Key_Escape:
return VK_ESCAPE;
case Qt::Key_Tab:
case Qt::Key_Backtab:
return VK_TAB;
case Qt::Key_Backspace:
return VK_BACK;
case Qt::Key_Return:
case Qt::Key_Enter:
return VK_RETURN;
case Qt::Key_Insert:
return VK_INSERT;
case Qt::Key_Delete:
return VK_DELETE;
case Qt::Key_Pause:
return VK_PAUSE;
case Qt::Key_Print:
return VK_PRINT;
case Qt::Key_Clear:
return VK_CLEAR;
case Qt::Key_Home:
return VK_HOME;
case Qt::Key_End:
return VK_END;
case Qt::Key_Left:
return VK_LEFT;
case Qt::Key_Up:
return VK_UP;
case Qt::Key_Right:
return VK_RIGHT;
case Qt::Key_Down:
return VK_DOWN;
case Qt::Key_PageUp:
return VK_PRIOR;
case Qt::Key_PageDown:
return VK_NEXT;
case Qt::Key_F1:
return VK_F1;
case Qt::Key_F2:
return VK_F2;
case Qt::Key_F3:
return VK_F3;
case Qt::Key_F4:
return VK_F4;
case Qt::Key_F5:
return VK_F5;
case Qt::Key_F6:
return VK_F6;
case Qt::Key_F7:
return VK_F7;
case Qt::Key_F8:
return VK_F8;
case Qt::Key_F9:
return VK_F9;
case Qt::Key_F10:
return VK_F10;
case Qt::Key_F11:
return VK_F11;
case Qt::Key_F12:
return VK_F12;
case Qt::Key_F13:
return VK_F13;
case Qt::Key_F14:
return VK_F14;
case Qt::Key_F15:
return VK_F15;
case Qt::Key_F16:
return VK_F16;
case Qt::Key_F17:
return VK_F17;
case Qt::Key_F18:
return VK_F18;
case Qt::Key_F19:
return VK_F19;
case Qt::Key_F20:
return VK_F20;
case Qt::Key_F21:
return VK_F21;
case Qt::Key_F22:
return VK_F22;
case Qt::Key_F23:
return VK_F23;
case Qt::Key_F24:
return VK_F24;
case Qt::Key_Space:
return VK_SPACE;
case Qt::Key_Asterisk:
return VK_MULTIPLY;
case Qt::Key_Plus:
return VK_ADD;
case Qt::Key_Comma:
return VK_SEPARATOR;
case Qt::Key_Minus:
return VK_SUBTRACT;
case Qt::Key_Slash:
return VK_DIVIDE;
case Qt::Key_MediaNext:
return VK_MEDIA_NEXT_TRACK;
case Qt::Key_MediaPrevious:
return VK_MEDIA_PREV_TRACK;
case Qt::Key_MediaPlay:
return VK_MEDIA_PLAY_PAUSE;
case Qt::Key_MediaStop:
return VK_MEDIA_STOP;
// couldn't find those in VK_*
//case Qt::Key_MediaLast:
//case Qt::Key_MediaRecord:
case Qt::Key_VolumeDown:
return VK_VOLUME_DOWN;
case Qt::Key_VolumeUp:
return VK_VOLUME_UP;
case Qt::Key_VolumeMute:
return VK_VOLUME_MUTE;
// numbers
case Qt::Key_0:
case Qt::Key_1:
case Qt::Key_2:
case Qt::Key_3:
case Qt::Key_4:
case Qt::Key_5:
case Qt::Key_6:
case Qt::Key_7:
case Qt::Key_8:
case Qt::Key_9:
return key;
// letters
case Qt::Key_A:
case Qt::Key_B:
case Qt::Key_C:
case Qt::Key_D:
case Qt::Key_E:
case Qt::Key_F:
case Qt::Key_G:
case Qt::Key_H:
case Qt::Key_I:
case Qt::Key_J:
case Qt::Key_K:
case Qt::Key_L:
case Qt::Key_M:
case Qt::Key_N:
case Qt::Key_O:
case Qt::Key_P:
case Qt::Key_Q:
case Qt::Key_R:
case Qt::Key_S:
case Qt::Key_T:
case Qt::Key_U:
case Qt::Key_V:
case Qt::Key_W:
case Qt::Key_X:
case Qt::Key_Y:
case Qt::Key_Z:
return key;
default:
return 0;
}
}
bool QxtGlobalShortcutPrivate::registerShortcut(quint32 nativeKey, quint32 nativeMods)
{
return RegisterHotKey(0, nativeMods ^ nativeKey, nativeMods, nativeKey);
}
bool QxtGlobalShortcutPrivate::unregisterShortcut(quint32 nativeKey, quint32 nativeMods)
{
return UnregisterHotKey(0, nativeMods ^ nativeKey);
}

View File

@@ -1,263 +0,0 @@
#include "qxtglobalshortcut_p.h"
/****************************************************************************
** Copyright (c) 2006 - 2011, the LibQxt project.
** See the Qxt AUTHORS file for a list of authors and copyright holders.
** All rights reserved.
**
** Redistribution and use in source and binary forms, with or without
** modification, are permitted provided that the following conditions are met:
** * Redistributions of source code must retain the above copyright
** notice, this list of conditions and the following disclaimer.
** * Redistributions in binary form must reproduce the above copyright
** notice, this list of conditions and the following disclaimer in the
** documentation and/or other materials provided with the distribution.
** * Neither the name of the LibQxt project nor the
** names of its contributors may be used to endorse or promote products
** derived from this software without specific prior written permission.
**
** THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
** ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
** WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
** DISCLAIMED. IN NO EVENT SHALL <COPYRIGHT HOLDER> BE LIABLE FOR ANY
** DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
** (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
** LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
** ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
** (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
** SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
**
** <http://libqxt.org> <foundation@libqxt.org>
*****************************************************************************/
#if QT_VERSION < QT_VERSION_CHECK(5,0,0)
# include <QX11Info>
#else
# include <qpa/qplatformnativeinterface.h>
# include <xcb/xcb.h>
# include <QApplication>
#endif
#include <X11/X.h>
#include <X11/Xlib.h>
#include <xcb/xproto.h>
#include <QtGlobal>
#include <QByteArray>
#include <QGuiApplication>
#include <QKeySequence>
#include <QString>
#include <QVector>
#include "keymapper_x11.h"
namespace {
const QVector<quint32> maskModifiers = QVector<quint32>()
<< 0 << Mod2Mask << LockMask << (Mod2Mask | LockMask);
typedef int (*X11ErrorHandler)(Display *display, XErrorEvent *event);
class QxtX11ErrorHandler {
public:
static bool error;
static int qxtX11ErrorHandler(Display *display, XErrorEvent *event)
{
Q_UNUSED(display);
switch (event->error_code)
{
case BadAccess:
case BadValue:
case BadWindow:
if (event->request_code == 33 /* X_GrabKey */ ||
event->request_code == 34 /* X_UngrabKey */)
{
error = true;
//TODO:
//char errstr[256];
//XGetErrorText(dpy, err->error_code, errstr, 256);
}
}
return 0;
}
QxtX11ErrorHandler()
{
error = false;
m_previousErrorHandler = XSetErrorHandler(qxtX11ErrorHandler);
}
~QxtX11ErrorHandler()
{
XSetErrorHandler(m_previousErrorHandler);
}
private:
X11ErrorHandler m_previousErrorHandler;
};
bool QxtX11ErrorHandler::error = false;
class QxtX11Data {
public:
QxtX11Data()
{
#if QT_VERSION < QT_VERSION_CHECK(5,0,0)
m_display = QX11Info::display();
#else
QPlatformNativeInterface *native = qApp->platformNativeInterface();
void *display = native->nativeResourceForScreen(QByteArray("display"),
QGuiApplication::primaryScreen());
m_display = reinterpret_cast<Display *>(display);
#endif
}
bool isValid()
{
return m_display != 0;
}
Display *display()
{
Q_ASSERT(isValid());
return m_display;
}
Window rootWindow()
{
return DefaultRootWindow(display());
}
bool grabKey(quint32 keycode, quint32 modifiers, Window window)
{
QxtX11ErrorHandler errorHandler;
for (int i = 0; !errorHandler.error && i < maskModifiers.size(); ++i) {
XGrabKey(display(), keycode, modifiers | maskModifiers[i], window, True,
GrabModeAsync, GrabModeAsync);
}
if (errorHandler.error) {
ungrabKey(keycode, modifiers, window);
return false;
}
return true;
}
bool ungrabKey(quint32 keycode, quint32 modifiers, Window window)
{
QxtX11ErrorHandler errorHandler;
foreach (quint32 maskMods, maskModifiers) {
XUngrabKey(display(), keycode, modifiers | maskMods, window);
}
return !errorHandler.error;
}
private:
Display *m_display;
};
} // namespace
#if QT_VERSION < QT_VERSION_CHECK(5,0,0)
bool QxtGlobalShortcutPrivate::eventFilter(void *message)
{
XEvent *event = static_cast<XEvent *>(message);
if (event->type == KeyPress)
{
XKeyEvent *key = reinterpret_cast<XKeyEvent *>(event);
unsigned int keycode = key->keycode;
unsigned int keystate = key->state;
#else
bool QxtGlobalShortcutPrivate::nativeEventFilter(const QByteArray & eventType,
void *message, long *result)
{
Q_UNUSED(result);
xcb_key_press_event_t *kev = 0;
if (eventType == "xcb_generic_event_t") {
xcb_generic_event_t *ev = static_cast<xcb_generic_event_t *>(message);
if ((ev->response_type & 127) == XCB_KEY_PRESS)
kev = static_cast<xcb_key_press_event_t *>(message);
}
if (kev != 0) {
unsigned int keycode = kev->detail;
unsigned int keystate = 0;
if(kev->state & XCB_MOD_MASK_1)
keystate |= Mod1Mask;
if(kev->state & XCB_MOD_MASK_CONTROL)
keystate |= ControlMask;
if(kev->state & XCB_MOD_MASK_4)
keystate |= Mod4Mask;
if(kev->state & XCB_MOD_MASK_SHIFT)
keystate |= ShiftMask;
#endif
activateShortcut(keycode,
// Mod1Mask == Alt, Mod4Mask == Meta
keystate & (ShiftMask | ControlMask | Mod1Mask | Mod4Mask));
}
return false;
}
quint32 QxtGlobalShortcutPrivate::nativeModifiers(Qt::KeyboardModifiers modifiers)
{
// ShiftMask, LockMask, ControlMask, Mod1Mask, Mod2Mask, Mod3Mask, Mod4Mask, and Mod5Mask
quint32 native = 0;
if (modifiers & Qt::ShiftModifier)
native |= ShiftMask;
if (modifiers & Qt::ControlModifier)
native |= ControlMask;
if (modifiers & Qt::AltModifier)
native |= Mod1Mask;
if (modifiers & Qt::MetaModifier)
native |= Mod4Mask;
// TODO: resolve these?
//if (modifiers & Qt::MetaModifier)
//if (modifiers & Qt::KeypadModifier)
//if (modifiers & Qt::GroupSwitchModifier)
return native;
}
quint32 QxtGlobalShortcutPrivate::nativeKeycode(Qt::Key key)
{
// (davidsansome) Try the table from QKeyMapper first - this seems to be
// the only way to get Keysyms for the media keys.
unsigned int keysym = 0;
int i = 0;
while (KeyTbl[i]) {
if (KeyTbl[i+1] == static_cast<uint>(key)) {
keysym = KeyTbl[i];
break;
}
i += 2;
}
// If that didn't work then fall back on XStringToKeysym
if (!keysym) {
keysym = XStringToKeysym(QKeySequence(key).toString().toLatin1().data());
if (keysym == NoSymbol)
keysym = static_cast<ushort>(key);
}
QxtX11Data x11;
if (!x11.isValid())
return 0;
return XKeysymToKeycode(x11.display(), keysym);
}
bool QxtGlobalShortcutPrivate::registerShortcut(quint32 nativeKey, quint32 nativeMods)
{
QxtX11Data x11;
return x11.isValid() && x11.grabKey(nativeKey, nativeMods, x11.rootWindow());
}
bool QxtGlobalShortcutPrivate::unregisterShortcut(quint32 nativeKey, quint32 nativeMods)
{
QxtX11Data x11;
return x11.isValid() && x11.ungrabKey(nativeKey, nativeMods, x11.rootWindow());
}

View File

@@ -1,4 +0,0 @@
cmake_minimum_required(VERSION 2.8.11)
set(CMAKE_CXX_STANDARD 11)
add_library(sha2 STATIC sha2.cpp)

589
3rdparty/sha2/sha2.cpp vendored
View File

@@ -1,589 +0,0 @@
/*
* FILE: sha2.c
* AUTHOR: Aaron D. Gifford - http://www.aarongifford.com/
*
* Copyright (c) 2000-2001, Aaron D. Gifford
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions
* are met:
* 1. Redistributions of source code must retain the above copyright
* notice, this list of conditions and the following disclaimer.
* 2. Redistributions in binary form must reproduce the above copyright
* notice, this list of conditions and the following disclaimer in the
* documentation and/or other materials provided with the distribution.
* 3. Neither the name of the copyright holder nor the names of contributors
* may be used to endorse or promote products derived from this software
* without specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTOR(S) ``AS IS'' AND
* ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
* IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
* ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTOR(S) BE LIABLE
* FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
* DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
* OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
* HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
* LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
* OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
* SUCH DAMAGE.
*
*/
#include <string.h>
#include <assert.h>
#include "sha2.h"
/*
* ASSERT NOTE:
* Some sanity checking code is included using assert(). On my FreeBSD
* system, this additional code can be removed by compiling with NDEBUG
* defined. Check your own systems manpage on assert() to see how to
* compile WITHOUT the sanity checking code on your system.
*
* UNROLLED TRANSFORM LOOP NOTE:
* You can define SHA2_UNROLL_TRANSFORM to use the unrolled transform
* loop version for the hash transform rounds (defined using macros
* later in this file). Either define on the command line, for example:
*
* cc -DSHA2_UNROLL_TRANSFORM -o sha2 sha2.c sha2prog.c
*
* or define below:
*
* #define SHA2_UNROLL_TRANSFORM
*
*/
/*** SHA-256/384/512 Machine Architecture Definitions *****************/
/*
* BYTE_ORDER NOTE:
*
* Please make sure that your system defines BYTE_ORDER. If your
* architecture is little-endian, make sure it also defines
* LITTLE_ENDIAN and that the two (BYTE_ORDER and LITTLE_ENDIAN) are
* equivilent.
*
* If your system does not define the above, then you can do so by
* hand like this:
*
* #define LITTLE_ENDIAN 1234
* #define BIG_ENDIAN 4321
*
* And for little-endian machines, add:
*
* #define BYTE_ORDER LITTLE_ENDIAN
*
* Or for big-endian machines:
*
* #define BYTE_ORDER BIG_ENDIAN
*
* The FreeBSD machine this was written on defines BYTE_ORDER
* appropriately by including <sys/types.h> (which in turn includes
* <machine/endian.h> where the appropriate definitions are actually
* made).
*/
#ifdef __MINGW32__
#include <sys/param.h>
#endif
#if !defined(BYTE_ORDER) || (BYTE_ORDER != LITTLE_ENDIAN && BYTE_ORDER != BIG_ENDIAN)
#error Define BYTE_ORDER to be equal to either LITTLE_ENDIAN or BIG_ENDIAN
#endif
namespace strawberry_sha2 {
/*
* Define the followingsha2_* types to types of the correct length on
* the native archtecture. Most BSD systems and Linux define u_intXX_t
* types. Machines with very recent ANSI C headers, can use the
* uintXX_t definintions from inttypes.h by defining SHA2_USE_INTTYPES_H
* during compile or in the sha.h header file.
*
* Machines that support neither u_intXX_t nor inttypes.h's uintXX_t
* will need to define these three typedefs below (and the appropriate
* ones in sha.h too) by hand according to their system architecture.
*
* Thank you, Jun-ichiro itojun Hagino, for suggesting using u_intXX_t
* types and pointing out recent ANSI C support for uintXX_t in inttypes.h.
*/
#ifdef SHA2_USE_INTTYPES_H
typedef uint8_t sha2_byte; /* Exactly 1 byte */
typedef uint32_t sha2_word32; /* Exactly 4 bytes */
typedef uint64_t sha2_word64; /* Exactly 8 bytes */
#else /* SHA2_USE_INTTYPES_H */
typedef u_int8_t sha2_byte; /* Exactly 1 byte */
typedef u_int32_t sha2_word32; /* Exactly 4 bytes */
typedef u_int64_t sha2_word64; /* Exactly 8 bytes */
#endif /* SHA2_USE_INTTYPES_H */
/*** SHA-256/384/512 Various Length Definitions ***********************/
/* NOTE: Most of these are in sha2.h */
#define SHA256_SHORT_BLOCK_LENGTH (SHA256_BLOCK_LENGTH - 8)
/*** ENDIAN REVERSAL MACROS *******************************************/
#if BYTE_ORDER == LITTLE_ENDIAN
#define REVERSE32(w,x) { \
sha2_word32 tmp = (w); \
tmp = (tmp >> 16) | (tmp << 16); \
(x) = ((tmp & 0xff00ff00UL) >> 8) | ((tmp & 0x00ff00ffUL) << 8); \
}
#define REVERSE64(w,x) { \
sha2_word64 tmp = (w); \
tmp = (tmp >> 32) | (tmp << 32); \
tmp = ((tmp & 0xff00ff00ff00ff00ULL) >> 8) | \
((tmp & 0x00ff00ff00ff00ffULL) << 8); \
(x) = ((tmp & 0xffff0000ffff0000ULL) >> 16) | \
((tmp & 0x0000ffff0000ffffULL) << 16); \
}
#endif /* BYTE_ORDER == LITTLE_ENDIAN */
/*
* Macro for incrementally adding the unsigned 64-bit integer n to the
* unsigned 128-bit integer (represented using a two-element array of
* 64-bit words):
*/
#define ADDINC128(w,n) { \
(w)[0] += (sha2_word64)(n); \
if ((w)[0] < (n)) { \
(w)[1]++; \
} \
}
/*
* Macros for copying blocks of memory and for zeroing out ranges
* of memory. Using these macros makes it easy to switch from
* using memset()/memcpy() and using bzero()/bcopy().
*
* Please define either SHA2_USE_MEMSET_MEMCPY or define
* SHA2_USE_BZERO_BCOPY depending on which function set you
* choose to use:
*/
#if !defined(SHA2_USE_MEMSET_MEMCPY) && !defined(SHA2_USE_BZERO_BCOPY)
/* Default to memset()/memcpy() if no option is specified */
#define SHA2_USE_MEMSET_MEMCPY 1
#endif
#if defined(SHA2_USE_MEMSET_MEMCPY) && defined(SHA2_USE_BZERO_BCOPY)
/* Abort with an error if BOTH options are defined */
#error Define either SHA2_USE_MEMSET_MEMCPY or SHA2_USE_BZERO_BCOPY, not both!
#endif
#ifdef SHA2_USE_MEMSET_MEMCPY
#define MEMSET_BZERO(p,l) memset((p), 0, (l))
#define MEMCPY_BCOPY(d,s,l) memcpy((d), (s), (l))
#endif
#ifdef SHA2_USE_BZERO_BCOPY
#define MEMSET_BZERO(p,l) bzero((p), (l))
#define MEMCPY_BCOPY(d,s,l) bcopy((s), (d), (l))
#endif
/*** THE SIX LOGICAL FUNCTIONS ****************************************/
/*
* Bit shifting and rotation (used by the six SHA-XYZ logical functions:
*
* NOTE: The naming of R and S appears backwards here (R is a SHIFT and
* S is a ROTATION) because the SHA-256/384/512 description document
* (see http://csrc.nist.gov/cryptval/shs/sha256-384-512.pdf) uses this
* same "backwards" definition.
*/
/* Shift-right (used in SHA-256, SHA-384, and SHA-512): */
#define R(b,x) ((x) >> (b))
/* 32-bit Rotate-right (used in SHA-256): */
#define S32(b,x) (((x) >> (b)) | ((x) << (32 - (b))))
/* Two of six logical functions used in SHA-256, SHA-384, and SHA-512: */
#define Ch(x,y,z) (((x) & (y)) ^ ((~(x)) & (z)))
#define Maj(x,y,z) (((x) & (y)) ^ ((x) & (z)) ^ ((y) & (z)))
/* Four of six logical functions used in SHA-256: */
#define Sigma0_256(x) (S32(2, (x)) ^ S32(13, (x)) ^ S32(22, (x)))
#define Sigma1_256(x) (S32(6, (x)) ^ S32(11, (x)) ^ S32(25, (x)))
#define sigma0_256(x) (S32(7, (x)) ^ S32(18, (x)) ^ R(3 , (x)))
#define sigma1_256(x) (S32(17, (x)) ^ S32(19, (x)) ^ R(10, (x)))
/*** INTERNAL FUNCTION PROTOTYPES *************************************/
/* NOTE: These should not be accessed directly from outside this
* library -- they are intended for private internal visibility/use
* only.
*/
void SHA256_Transform(SHA256_CTX*, const sha2_word32*);
/*** SHA-XYZ INITIAL HASH VALUES AND CONSTANTS ************************/
/* Hash constant words K for SHA-256: */
const static sha2_word32 K256[64] = {
0x428a2f98UL, 0x71374491UL, 0xb5c0fbcfUL, 0xe9b5dba5UL,
0x3956c25bUL, 0x59f111f1UL, 0x923f82a4UL, 0xab1c5ed5UL,
0xd807aa98UL, 0x12835b01UL, 0x243185beUL, 0x550c7dc3UL,
0x72be5d74UL, 0x80deb1feUL, 0x9bdc06a7UL, 0xc19bf174UL,
0xe49b69c1UL, 0xefbe4786UL, 0x0fc19dc6UL, 0x240ca1ccUL,
0x2de92c6fUL, 0x4a7484aaUL, 0x5cb0a9dcUL, 0x76f988daUL,
0x983e5152UL, 0xa831c66dUL, 0xb00327c8UL, 0xbf597fc7UL,
0xc6e00bf3UL, 0xd5a79147UL, 0x06ca6351UL, 0x14292967UL,
0x27b70a85UL, 0x2e1b2138UL, 0x4d2c6dfcUL, 0x53380d13UL,
0x650a7354UL, 0x766a0abbUL, 0x81c2c92eUL, 0x92722c85UL,
0xa2bfe8a1UL, 0xa81a664bUL, 0xc24b8b70UL, 0xc76c51a3UL,
0xd192e819UL, 0xd6990624UL, 0xf40e3585UL, 0x106aa070UL,
0x19a4c116UL, 0x1e376c08UL, 0x2748774cUL, 0x34b0bcb5UL,
0x391c0cb3UL, 0x4ed8aa4aUL, 0x5b9cca4fUL, 0x682e6ff3UL,
0x748f82eeUL, 0x78a5636fUL, 0x84c87814UL, 0x8cc70208UL,
0x90befffaUL, 0xa4506cebUL, 0xbef9a3f7UL, 0xc67178f2UL
};
/* Initial hash value H for SHA-256: */
const static sha2_word32 sha256_initial_hash_value[8] = {
0x6a09e667UL,
0xbb67ae85UL,
0x3c6ef372UL,
0xa54ff53aUL,
0x510e527fUL,
0x9b05688cUL,
0x1f83d9abUL,
0x5be0cd19UL
};
/*
* Constant used by SHA256/384/512_End() functions for converting the
* digest to a readable hexadecimal character string:
*/
static const char *sha2_hex_digits = "0123456789abcdef";
/*** SHA-256: *********************************************************/
void SHA256_Init(SHA256_CTX* context) {
if (context == (SHA256_CTX*)0) {
return;
}
MEMCPY_BCOPY(context->state, sha256_initial_hash_value, SHA256_DIGEST_LENGTH);
MEMSET_BZERO(context->buffer, SHA256_BLOCK_LENGTH);
context->bitcount = 0;
}
#ifdef SHA2_UNROLL_TRANSFORM
/* Unrolled SHA-256 round macros: */
#if BYTE_ORDER == LITTLE_ENDIAN
#define ROUND256_0_TO_15(a,b,c,d,e,f,g,h) \
REVERSE32(*data++, W256[j]); \
T1 = (h) + Sigma1_256(e) + Ch((e), (f), (g)) + \
K256[j] + W256[j]; \
(d) += T1; \
(h) = T1 + Sigma0_256(a) + Maj((a), (b), (c)); \
j++
#else /* BYTE_ORDER == LITTLE_ENDIAN */
#define ROUND256_0_TO_15(a,b,c,d,e,f,g,h) \
T1 = (h) + Sigma1_256(e) + Ch((e), (f), (g)) + \
K256[j] + (W256[j] = *data++); \
(d) += T1; \
(h) = T1 + Sigma0_256(a) + Maj((a), (b), (c)); \
j++
#endif /* BYTE_ORDER == LITTLE_ENDIAN */
#define ROUND256(a,b,c,d,e,f,g,h) \
s0 = W256[(j+1)&0x0f]; \
s0 = sigma0_256(s0); \
s1 = W256[(j+14)&0x0f]; \
s1 = sigma1_256(s1); \
T1 = (h) + Sigma1_256(e) + Ch((e), (f), (g)) + K256[j] + \
(W256[j&0x0f] += s1 + W256[(j+9)&0x0f] + s0); \
(d) += T1; \
(h) = T1 + Sigma0_256(a) + Maj((a), (b), (c)); \
j++
void SHA256_Transform(SHA256_CTX* context, const sha2_word32* data) {
sha2_word32 a, b, c, d, e, f, g, h, s0, s1;
sha2_word32 T1, *W256;
int j;
W256 = (sha2_word32*)context->buffer;
/* Initialize registers with the prev. intermediate value */
a = context->state[0];
b = context->state[1];
c = context->state[2];
d = context->state[3];
e = context->state[4];
f = context->state[5];
g = context->state[6];
h = context->state[7];
j = 0;
do {
/* Rounds 0 to 15 (unrolled): */
ROUND256_0_TO_15(a,b,c,d,e,f,g,h);
ROUND256_0_TO_15(h,a,b,c,d,e,f,g);
ROUND256_0_TO_15(g,h,a,b,c,d,e,f);
ROUND256_0_TO_15(f,g,h,a,b,c,d,e);
ROUND256_0_TO_15(e,f,g,h,a,b,c,d);
ROUND256_0_TO_15(d,e,f,g,h,a,b,c);
ROUND256_0_TO_15(c,d,e,f,g,h,a,b);
ROUND256_0_TO_15(b,c,d,e,f,g,h,a);
} while (j < 16);
/* Now for the remaining rounds to 64: */
do {
ROUND256(a,b,c,d,e,f,g,h);
ROUND256(h,a,b,c,d,e,f,g);
ROUND256(g,h,a,b,c,d,e,f);
ROUND256(f,g,h,a,b,c,d,e);
ROUND256(e,f,g,h,a,b,c,d);
ROUND256(d,e,f,g,h,a,b,c);
ROUND256(c,d,e,f,g,h,a,b);
ROUND256(b,c,d,e,f,g,h,a);
} while (j < 64);
/* Compute the current intermediate hash value */
context->state[0] += a;
context->state[1] += b;
context->state[2] += c;
context->state[3] += d;
context->state[4] += e;
context->state[5] += f;
context->state[6] += g;
context->state[7] += h;
/* Clean up */
a = b = c = d = e = f = g = h = T1 = 0;
}
#else /* SHA2_UNROLL_TRANSFORM */
void SHA256_Transform(SHA256_CTX* context, const sha2_word32* data) {
sha2_word32 a, b, c, d, e, f, g, h, s0, s1;
sha2_word32 T1, T2, *W256;
int j;
W256 = (sha2_word32*)context->buffer;
/* Initialize registers with the prev. intermediate value */
a = context->state[0];
b = context->state[1];
c = context->state[2];
d = context->state[3];
e = context->state[4];
f = context->state[5];
g = context->state[6];
h = context->state[7];
j = 0;
do {
#if BYTE_ORDER == LITTLE_ENDIAN
/* Copy data while converting to host byte order */
REVERSE32(*data++,W256[j]);
/* Apply the SHA-256 compression function to update a..h */
T1 = h + Sigma1_256(e) + Ch(e, f, g) + K256[j] + W256[j];
#else /* BYTE_ORDER == LITTLE_ENDIAN */
/* Apply the SHA-256 compression function to update a..h with copy */
T1 = h + Sigma1_256(e) + Ch(e, f, g) + K256[j] + (W256[j] = *data++);
#endif /* BYTE_ORDER == LITTLE_ENDIAN */
T2 = Sigma0_256(a) + Maj(a, b, c);
h = g;
g = f;
f = e;
e = d + T1;
d = c;
c = b;
b = a;
a = T1 + T2;
j++;
} while (j < 16);
do {
/* Part of the message block expansion: */
s0 = W256[(j+1)&0x0f];
s0 = sigma0_256(s0);
s1 = W256[(j+14)&0x0f];
s1 = sigma1_256(s1);
/* Apply the SHA-256 compression function to update a..h */
T1 = h + Sigma1_256(e) + Ch(e, f, g) + K256[j] +
(W256[j&0x0f] += s1 + W256[(j+9)&0x0f] + s0);
T2 = Sigma0_256(a) + Maj(a, b, c);
h = g;
g = f;
f = e;
e = d + T1;
d = c;
c = b;
b = a;
a = T1 + T2;
j++;
} while (j < 64);
/* Compute the current intermediate hash value */
context->state[0] += a;
context->state[1] += b;
context->state[2] += c;
context->state[3] += d;
context->state[4] += e;
context->state[5] += f;
context->state[6] += g;
context->state[7] += h;
/* Clean up */
a = b = c = d = e = f = g = h = T1 = T2 = 0;
}
#endif /* SHA2_UNROLL_TRANSFORM */
void SHA256_Update(SHA256_CTX* context, const sha2_byte *data, size_t len) {
unsigned int freespace, usedspace;
if (len == 0) {
/* Calling with no data is valid - we do nothing */
return;
}
/* Sanity check: */
assert(context != (SHA256_CTX*)0 && data != (sha2_byte*)0);
usedspace = (context->bitcount >> 3) % SHA256_BLOCK_LENGTH;
if (usedspace > 0) {
/* Calculate how much free space is available in the buffer */
freespace = SHA256_BLOCK_LENGTH - usedspace;
if (len >= freespace) {
/* Fill the buffer completely and process it */
MEMCPY_BCOPY(&context->buffer[usedspace], data, freespace);
context->bitcount += freespace << 3;
len -= freespace;
data += freespace;
SHA256_Transform(context, (sha2_word32*)context->buffer);
} else {
/* The buffer is not yet full */
MEMCPY_BCOPY(&context->buffer[usedspace], data, len);
context->bitcount += len << 3;
/* Clean up: */
usedspace = freespace = 0;
return;
}
}
while (len >= SHA256_BLOCK_LENGTH) {
/* Process as many complete blocks as we can */
SHA256_Transform(context, (sha2_word32*)data);
context->bitcount += SHA256_BLOCK_LENGTH << 3;
len -= SHA256_BLOCK_LENGTH;
data += SHA256_BLOCK_LENGTH;
}
if (len > 0) {
/* There's left-overs, so save 'em */
MEMCPY_BCOPY(context->buffer, data, len);
context->bitcount += len << 3;
}
/* Clean up: */
usedspace = freespace = 0;
}
void SHA256_Final(sha2_byte digest[], SHA256_CTX* context) {
sha2_word32 *d = (sha2_word32*)digest;
unsigned int usedspace;
/* Sanity check: */
assert(context != (SHA256_CTX*)0);
/* If no digest buffer is passed, we don't bother doing this: */
if (digest != (sha2_byte*)0) {
usedspace = (context->bitcount >> 3) % SHA256_BLOCK_LENGTH;
#if BYTE_ORDER == LITTLE_ENDIAN
/* Convert FROM host byte order */
REVERSE64(context->bitcount,context->bitcount);
#endif
if (usedspace > 0) {
/* Begin padding with a 1 bit: */
context->buffer[usedspace++] = 0x80;
if (usedspace <= SHA256_SHORT_BLOCK_LENGTH) {
/* Set-up for the last transform: */
MEMSET_BZERO(&context->buffer[usedspace], SHA256_SHORT_BLOCK_LENGTH - usedspace);
} else {
if (usedspace < SHA256_BLOCK_LENGTH) {
MEMSET_BZERO(&context->buffer[usedspace], SHA256_BLOCK_LENGTH - usedspace);
}
/* Do second-to-last transform: */
SHA256_Transform(context, (sha2_word32*)context->buffer);
/* And set-up for the last transform: */
MEMSET_BZERO(context->buffer, SHA256_SHORT_BLOCK_LENGTH);
}
} else {
/* Set-up for the last transform: */
MEMSET_BZERO(context->buffer, SHA256_SHORT_BLOCK_LENGTH);
/* Begin padding with a 1 bit: */
*context->buffer = 0x80;
}
/* Set the bit count: */
*(sha2_word64*)&context->buffer[SHA256_SHORT_BLOCK_LENGTH] = context->bitcount;
/* Final transform: */
SHA256_Transform(context, (sha2_word32*)context->buffer);
#if BYTE_ORDER == LITTLE_ENDIAN
{
/* Convert TO host byte order */
int j;
for (j = 0; j < 8; j++) {
REVERSE32(context->state[j],context->state[j]);
*d++ = context->state[j];
}
}
#else
MEMCPY_BCOPY(d, context->state, SHA256_DIGEST_LENGTH);
#endif
}
/* Clean up state data: */
MEMSET_BZERO(context, sizeof(SHA256_CTX));
usedspace = 0;
}
char *SHA256_End(SHA256_CTX* context, char buffer[]) {
sha2_byte digest[SHA256_DIGEST_LENGTH], *d = digest;
int i;
/* Sanity check: */
assert(context != (SHA256_CTX*)0);
if (buffer != (char*)0) {
SHA256_Final(digest, context);
for (i = 0; i < SHA256_DIGEST_LENGTH; i++) {
*buffer++ = sha2_hex_digits[(*d & 0xf0) >> 4];
*buffer++ = sha2_hex_digits[*d & 0x0f];
d++;
}
*buffer = (char)0;
} else {
MEMSET_BZERO(context, sizeof(SHA256_CTX));
}
MEMSET_BZERO(digest, SHA256_DIGEST_LENGTH);
return buffer;
}
char* SHA256_Data(const sha2_byte* data, size_t len, char digest[SHA256_DIGEST_STRING_LENGTH]) {
SHA256_CTX context;
SHA256_Init(&context);
SHA256_Update(&context, data, len);
return SHA256_End(&context, digest);
}
} // namespace strawberry_sha2

81
3rdparty/sha2/sha2.h vendored
View File

@@ -1,81 +0,0 @@
/*
* FILE: sha2.h
* AUTHOR: Aaron D. Gifford - http://www.aarongifford.com/
*
* Copyright (c) 2000-2001, Aaron D. Gifford
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions
* are met:
* 1. Redistributions of source code must retain the above copyright
* notice, this list of conditions and the following disclaimer.
* 2. Redistributions in binary form must reproduce the above copyright
* notice, this list of conditions and the following disclaimer in the
* documentation and/or other materials provided with the distribution.
* 3. Neither the name of the copyright holder nor the names of contributors
* may be used to endorse or promote products derived from this software
* without specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTOR(S) ``AS IS'' AND
* ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
* IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
* ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTOR(S) BE LIABLE
* FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
* DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
* OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
* HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
* LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
* OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
* SUCH DAMAGE.
*
* $Id: sha2.h,v 1.1 2001/11/08 00:02:01 adg Exp adg $
*/
#ifndef __STRAWBERRY_SHA2_H__
#define __STRAWBERRY_SHA2_H__
#include <stddef.h>
/*
* Import u_intXX_t size_t type definitions from system headers. You
* may need to change this, or define these things yourself in this
* file.
*/
#include <sys/types.h>
namespace strawberry_sha2 {
/*** SHA-256/384/512 Various Length Definitions ***********************/
static const int SHA256_BLOCK_LENGTH = 64;
static const int SHA256_DIGEST_LENGTH = 32;
static const int SHA256_DIGEST_STRING_LENGTH = (SHA256_DIGEST_LENGTH * 2 + 1);
/*** SHA-256/384/512 Context Structures *******************************/
/* NOTE: If your architecture does not define either u_intXX_t types or
* uintXX_t (from inttypes.h), you may need to define things by hand
* for your system:
*/
#ifdef __MINGW32__
typedef unsigned char u_int8_t; /* 1-byte (8-bits) */
typedef unsigned int u_int32_t; /* 4-bytes (32-bits) */
typedef unsigned long long u_int64_t; /* 8-bytes (64-bits) */
#endif
typedef struct _SHA256_CTX {
u_int32_t state[8];
u_int64_t bitcount;
u_int8_t buffer[SHA256_BLOCK_LENGTH];
} SHA256_CTX;
void SHA256_Init(SHA256_CTX *);
void SHA256_Update(SHA256_CTX*, const u_int8_t*, size_t);
void SHA256_Final(u_int8_t[SHA256_DIGEST_LENGTH], SHA256_CTX*);
char* SHA256_End(SHA256_CTX*, char[SHA256_DIGEST_STRING_LENGTH]);
char* SHA256_Data(const u_int8_t*, size_t, char[SHA256_DIGEST_STRING_LENGTH]);
} // namespace strawberry_sha2
#endif /* __STRAWBERRY_SHA2_H__ */

View File

@@ -1,380 +0,0 @@
cmake_minimum_required(VERSION 2.8.11)
set(CMAKE_CXX_STANDARD 11)
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wno-delete-non-virtual-dtor")
set(TAGLIB_SOVERSION_CURRENT 17)
set(TAGLIB_SOVERSION_REVISION 0)
set(TAGLIB_SOVERSION_AGE 16)
math(EXPR TAGLIB_SOVERSION_MAJOR "${TAGLIB_SOVERSION_CURRENT} - ${TAGLIB_SOVERSION_AGE}")
math(EXPR TAGLIB_SOVERSION_MINOR "${TAGLIB_SOVERSION_AGE}")
math(EXPR TAGLIB_SOVERSION_PATCH "${TAGLIB_SOVERSION_REVISION}")
include(TestBigEndian)
test_big_endian(IS_BIG_ENDIAN)
if(NOT IS_BIG_ENDIAN)
add_definitions(-DSYSTEM_BYTEORDER=1)
else()
add_definitions(-DSYSTEM_BYTEORDER=2)
endif()
configure_file(taglib_config.h.cmake ${CMAKE_CURRENT_BINARY_DIR}/taglib_config.h)
set(CMAKE_INCLUDE_CURRENT_DIR ON)
include_directories(
${CMAKE_CURRENT_SOURCE_DIR}/toolkit
${CMAKE_CURRENT_SOURCE_DIR}/asf
${CMAKE_CURRENT_SOURCE_DIR}/mpeg
${CMAKE_CURRENT_SOURCE_DIR}/ogg
${CMAKE_CURRENT_SOURCE_DIR}/ogg/flac
${CMAKE_CURRENT_SOURCE_DIR}/flac
${CMAKE_CURRENT_SOURCE_DIR}/mpc
${CMAKE_CURRENT_SOURCE_DIR}/mp4
${CMAKE_CURRENT_SOURCE_DIR}/ogg/vorbis
${CMAKE_CURRENT_SOURCE_DIR}/ogg/speex
${CMAKE_CURRENT_SOURCE_DIR}/ogg/opus
${CMAKE_CURRENT_SOURCE_DIR}/mpeg/id3v2
${CMAKE_CURRENT_SOURCE_DIR}/mpeg/id3v2/frames
${CMAKE_CURRENT_SOURCE_DIR}/mpeg/id3v1
${CMAKE_CURRENT_SOURCE_DIR}/ape
${CMAKE_CURRENT_SOURCE_DIR}/wavpack
${CMAKE_CURRENT_SOURCE_DIR}/trueaudio
${CMAKE_CURRENT_SOURCE_DIR}/riff
${CMAKE_CURRENT_SOURCE_DIR}/riff/aiff
${CMAKE_CURRENT_SOURCE_DIR}/riff/wav
${CMAKE_CURRENT_SOURCE_DIR}/mod
${CMAKE_CURRENT_SOURCE_DIR}/s3m
${CMAKE_CURRENT_SOURCE_DIR}/it
${CMAKE_CURRENT_SOURCE_DIR}/xm
${CMAKE_SOURCE_DIR}/3rdparty
)
if(ZLIB_FOUND)
include_directories(${ZLIB_INCLUDE_DIR})
elseif(HAVE_ZLIB_SOURCE)
include_directories(${ZLIB_SOURCE})
endif()
set(tag_HDRS
tag.h
fileref.h
audioproperties.h
taglib_export.h
${CMAKE_CURRENT_BINARY_DIR}/taglib_config.h
toolkit/taglib.h
toolkit/tstring.h
toolkit/tlist.h
toolkit/tlist.tcc
toolkit/tstringlist.h
toolkit/tbytevector.h
toolkit/tbytevectorlist.h
toolkit/tbytevectorstream.h
toolkit/tiostream.h
toolkit/tfile.h
toolkit/tfilestream.h
toolkit/tmap.h
toolkit/tmap.tcc
toolkit/tpropertymap.h
toolkit/trefcounter.h
toolkit/tdebuglistener.h
mpeg/mpegfile.h
mpeg/mpegproperties.h
mpeg/mpegheader.h
mpeg/xingheader.h
mpeg/id3v1/id3v1tag.h
mpeg/id3v1/id3v1genres.h
mpeg/id3v2/id3v2extendedheader.h
mpeg/id3v2/id3v2frame.h
mpeg/id3v2/id3v2header.h
mpeg/id3v2/id3v2synchdata.h
mpeg/id3v2/id3v2footer.h
mpeg/id3v2/id3v2framefactory.h
mpeg/id3v2/id3v2tag.h
mpeg/id3v2/frames/attachedpictureframe.h
mpeg/id3v2/frames/commentsframe.h
mpeg/id3v2/frames/eventtimingcodesframe.h
mpeg/id3v2/frames/generalencapsulatedobjectframe.h
mpeg/id3v2/frames/ownershipframe.h
mpeg/id3v2/frames/popularimeterframe.h
mpeg/id3v2/frames/privateframe.h
mpeg/id3v2/frames/relativevolumeframe.h
mpeg/id3v2/frames/synchronizedlyricsframe.h
mpeg/id3v2/frames/textidentificationframe.h
mpeg/id3v2/frames/uniquefileidentifierframe.h
mpeg/id3v2/frames/unknownframe.h
mpeg/id3v2/frames/unsynchronizedlyricsframe.h
mpeg/id3v2/frames/urllinkframe.h
mpeg/id3v2/frames/chapterframe.h
mpeg/id3v2/frames/tableofcontentsframe.h
mpeg/id3v2/frames/podcastframe.h
ogg/oggfile.h
ogg/oggpage.h
ogg/oggpageheader.h
ogg/xiphcomment.h
ogg/vorbis/vorbisfile.h
ogg/vorbis/vorbisproperties.h
ogg/flac/oggflacfile.h
ogg/speex/speexfile.h
ogg/speex/speexproperties.h
ogg/opus/opusfile.h
ogg/opus/opusproperties.h
flac/flacfile.h
flac/flacpicture.h
flac/flacproperties.h
flac/flacmetadatablock.h
ape/apefile.h
ape/apeproperties.h
ape/apetag.h
ape/apefooter.h
ape/apeitem.h
mpc/mpcfile.h
mpc/mpcproperties.h
wavpack/wavpackfile.h
wavpack/wavpackproperties.h
trueaudio/trueaudiofile.h
trueaudio/trueaudioproperties.h
riff/rifffile.h
riff/aiff/aifffile.h
riff/aiff/aiffproperties.h
riff/wav/wavfile.h
riff/wav/wavproperties.h
riff/wav/infotag.h
asf/asffile.h
asf/asfproperties.h
asf/asftag.h
asf/asfattribute.h
asf/asfpicture.h
mp4/mp4file.h
mp4/mp4atom.h
mp4/mp4tag.h
mp4/mp4item.h
mp4/mp4properties.h
mp4/mp4coverart.h
mod/modfilebase.h
mod/modfile.h
mod/modtag.h
mod/modproperties.h
it/itfile.h
it/itproperties.h
s3m/s3mfile.h
s3m/s3mproperties.h
xm/xmfile.h
xm/xmproperties.h
)
set(mpeg_SRCS
mpeg/mpegfile.cpp
mpeg/mpegproperties.cpp
mpeg/mpegheader.cpp
mpeg/xingheader.cpp
)
set(id3v1_SRCS
mpeg/id3v1/id3v1tag.cpp
mpeg/id3v1/id3v1genres.cpp
)
set(id3v2_SRCS
mpeg/id3v2/id3v2framefactory.cpp
mpeg/id3v2/id3v2synchdata.cpp
mpeg/id3v2/id3v2tag.cpp
mpeg/id3v2/id3v2header.cpp
mpeg/id3v2/id3v2frame.cpp
mpeg/id3v2/id3v2footer.cpp
mpeg/id3v2/id3v2extendedheader.cpp
)
set(frames_SRCS
mpeg/id3v2/frames/attachedpictureframe.cpp
mpeg/id3v2/frames/commentsframe.cpp
mpeg/id3v2/frames/eventtimingcodesframe.cpp
mpeg/id3v2/frames/generalencapsulatedobjectframe.cpp
mpeg/id3v2/frames/ownershipframe.cpp
mpeg/id3v2/frames/popularimeterframe.cpp
mpeg/id3v2/frames/privateframe.cpp
mpeg/id3v2/frames/relativevolumeframe.cpp
mpeg/id3v2/frames/synchronizedlyricsframe.cpp
mpeg/id3v2/frames/textidentificationframe.cpp
mpeg/id3v2/frames/uniquefileidentifierframe.cpp
mpeg/id3v2/frames/unknownframe.cpp
mpeg/id3v2/frames/unsynchronizedlyricsframe.cpp
mpeg/id3v2/frames/urllinkframe.cpp
mpeg/id3v2/frames/chapterframe.cpp
mpeg/id3v2/frames/tableofcontentsframe.cpp
mpeg/id3v2/frames/podcastframe.cpp
)
set(ogg_SRCS
ogg/oggfile.cpp
ogg/oggpage.cpp
ogg/oggpageheader.cpp
ogg/xiphcomment.cpp
)
set(vorbis_SRCS
ogg/vorbis/vorbisfile.cpp
ogg/vorbis/vorbisproperties.cpp
)
set(flacs_SRCS
flac/flacfile.cpp
flac/flacpicture.cpp
flac/flacproperties.cpp
flac/flacmetadatablock.cpp
flac/flacunknownmetadatablock.cpp
)
set(oggflacs_SRCS
ogg/flac/oggflacfile.cpp
)
set(mpc_SRCS
mpc/mpcfile.cpp
mpc/mpcproperties.cpp
)
set(mp4_SRCS
mp4/mp4file.cpp
mp4/mp4atom.cpp
mp4/mp4tag.cpp
mp4/mp4item.cpp
mp4/mp4properties.cpp
mp4/mp4coverart.cpp
)
set(ape_SRCS
ape/apetag.cpp
ape/apefooter.cpp
ape/apeitem.cpp
ape/apefile.cpp
ape/apeproperties.cpp
)
set(wavpack_SRCS
wavpack/wavpackfile.cpp
wavpack/wavpackproperties.cpp
)
set(speex_SRCS
ogg/speex/speexfile.cpp
ogg/speex/speexproperties.cpp
)
set(opus_SRCS
ogg/opus/opusfile.cpp
ogg/opus/opusproperties.cpp
)
set(trueaudio_SRCS
trueaudio/trueaudiofile.cpp
trueaudio/trueaudioproperties.cpp
)
set(asf_SRCS
asf/asftag.cpp
asf/asffile.cpp
asf/asfproperties.cpp
asf/asfattribute.cpp
asf/asfpicture.cpp
)
set(riff_SRCS
riff/rifffile.cpp
)
set(aiff_SRCS
riff/aiff/aifffile.cpp
riff/aiff/aiffproperties.cpp
)
set(wav_SRCS
riff/wav/wavfile.cpp
riff/wav/wavproperties.cpp
riff/wav/infotag.cpp
)
set(mod_SRCS
mod/modfilebase.cpp
mod/modfile.cpp
mod/modtag.cpp
mod/modproperties.cpp
)
set(s3m_SRCS
s3m/s3mfile.cpp
s3m/s3mproperties.cpp
)
set(it_SRCS
it/itfile.cpp
it/itproperties.cpp
)
set(xm_SRCS
xm/xmfile.cpp
xm/xmproperties.cpp
)
set(toolkit_SRCS
toolkit/tstring.cpp
toolkit/tstringlist.cpp
toolkit/tbytevector.cpp
toolkit/tbytevectorlist.cpp
toolkit/tbytevectorstream.cpp
toolkit/tiostream.cpp
toolkit/tfile.cpp
toolkit/tfilestream.cpp
toolkit/tdebug.cpp
toolkit/tpropertymap.cpp
toolkit/trefcounter.cpp
toolkit/tdebuglistener.cpp
toolkit/tzlib.cpp
)
if(HAVE_ZLIB_SOURCE)
set(zlib_SRCS
${ZLIB_SOURCE}/adler32.c
${ZLIB_SOURCE}/crc32.c
${ZLIB_SOURCE}/inffast.c
${ZLIB_SOURCE}/inflate.c
${ZLIB_SOURCE}/inftrees.c
${ZLIB_SOURCE}/zutil.c
)
endif()
set(tag_LIB_SRCS
${mpeg_SRCS} ${id3v1_SRCS} ${id3v2_SRCS} ${frames_SRCS} ${ogg_SRCS}
${vorbis_SRCS} ${oggflacs_SRCS} ${mpc_SRCS} ${ape_SRCS} ${toolkit_SRCS} ${flacs_SRCS}
${wavpack_SRCS} ${speex_SRCS} ${trueaudio_SRCS} ${riff_SRCS} ${aiff_SRCS} ${wav_SRCS}
${asf_SRCS} ${mp4_SRCS} ${mod_SRCS} ${s3m_SRCS} ${it_SRCS} ${xm_SRCS} ${opus_SRCS}
${zlib_SRCS}
tag.cpp
tagunion.cpp
fileref.cpp
audioproperties.cpp
tagutils.cpp
)
add_library(tag STATIC ${tag_LIB_SRCS} ${tag_HDRS})
if(HAVE_ZLIB AND NOT HAVE_ZLIB_SOURCE)
target_link_libraries(tag ${ZLIB_LIBRARIES})
endif()
set_target_properties(tag PROPERTIES
VERSION ${TAGLIB_SOVERSION_MAJOR}.${TAGLIB_SOVERSION_MINOR}.${TAGLIB_SOVERSION_PATCH}
SOVERSION ${TAGLIB_SOVERSION_MAJOR}
DEFINE_SYMBOL MAKE_TAGLIB_LIB
LINK_INTERFACE_LIBRARIES ""
)
foreach(header ${tag_HDRS})
get_filename_component(header_name ${header} NAME)
configure_file(
"${header}"
"${CMAKE_CURRENT_BINARY_DIR}/headers/taglib/${header_name}"
COPYONLY
)
endforeach()

View File

@@ -1,502 +0,0 @@
GNU LESSER GENERAL PUBLIC LICENSE
Version 2.1, February 1999
Copyright (C) 1991, 1999 Free Software Foundation, Inc.
51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
Everyone is permitted to copy and distribute verbatim copies
of this license document, but changing it is not allowed.
[This is the first released version of the Lesser GPL. It also counts
as the successor of the GNU Library Public License, version 2, hence
the version number 2.1.]
Preamble
The licenses for most software are designed to take away your
freedom to share and change it. By contrast, the GNU General Public
Licenses are intended to guarantee your freedom to share and change
free software--to make sure the software is free for all its users.
This license, the Lesser General Public License, applies to some
specially designated software packages--typically libraries--of the
Free Software Foundation and other authors who decide to use it. You
can use it too, but we suggest you first think carefully about whether
this license or the ordinary General Public License is the better
strategy to use in any particular case, based on the explanations below.
When we speak of free software, we are referring to freedom of use,
not price. Our General Public Licenses are designed to make sure that
you have the freedom to distribute copies of free software (and charge
for this service if you wish); that you receive source code or can get
it if you want it; that you can change the software and use pieces of
it in new free programs; and that you are informed that you can do
these things.
To protect your rights, we need to make restrictions that forbid
distributors to deny you these rights or to ask you to surrender these
rights. These restrictions translate to certain responsibilities for
you if you distribute copies of the library or if you modify it.
For example, if you distribute copies of the library, whether gratis
or for a fee, you must give the recipients all the rights that we gave
you. You must make sure that they, too, receive or can get the source
code. If you link other code with the library, you must provide
complete object files to the recipients, so that they can relink them
with the library after making changes to the library and recompiling
it. And you must show them these terms so they know their rights.
We protect your rights with a two-step method: (1) we copyright the
library, and (2) we offer you this license, which gives you legal
permission to copy, distribute and/or modify the library.
To protect each distributor, we want to make it very clear that
there is no warranty for the free library. Also, if the library is
modified by someone else and passed on, the recipients should know
that what they have is not the original version, so that the original
author's reputation will not be affected by problems that might be
introduced by others.
Finally, software patents pose a constant threat to the existence of
any free program. We wish to make sure that a company cannot
effectively restrict the users of a free program by obtaining a
restrictive license from a patent holder. Therefore, we insist that
any patent license obtained for a version of the library must be
consistent with the full freedom of use specified in this license.
Most GNU software, including some libraries, is covered by the
ordinary GNU General Public License. This license, the GNU Lesser
General Public License, applies to certain designated libraries, and
is quite different from the ordinary General Public License. We use
this license for certain libraries in order to permit linking those
libraries into non-free programs.
When a program is linked with a library, whether statically or using
a shared library, the combination of the two is legally speaking a
combined work, a derivative of the original library. The ordinary
General Public License therefore permits such linking only if the
entire combination fits its criteria of freedom. The Lesser General
Public License permits more lax criteria for linking other code with
the library.
We call this license the "Lesser" General Public License because it
does Less to protect the user's freedom than the ordinary General
Public License. It also provides other free software developers Less
of an advantage over competing non-free programs. These disadvantages
are the reason we use the ordinary General Public License for many
libraries. However, the Lesser license provides advantages in certain
special circumstances.
For example, on rare occasions, there may be a special need to
encourage the widest possible use of a certain library, so that it becomes
a de-facto standard. To achieve this, non-free programs must be
allowed to use the library. A more frequent case is that a free
library does the same job as widely used non-free libraries. In this
case, there is little to gain by limiting the free library to free
software only, so we use the Lesser General Public License.
In other cases, permission to use a particular library in non-free
programs enables a greater number of people to use a large body of
free software. For example, permission to use the GNU C Library in
non-free programs enables many more people to use the whole GNU
operating system, as well as its variant, the GNU/Linux operating
system.
Although the Lesser General Public License is Less protective of the
users' freedom, it does ensure that the user of a program that is
linked with the Library has the freedom and the wherewithal to run
that program using a modified version of the Library.
The precise terms and conditions for copying, distribution and
modification follow. Pay close attention to the difference between a
"work based on the library" and a "work that uses the library". The
former contains code derived from the library, whereas the latter must
be combined with the library in order to run.
GNU LESSER GENERAL PUBLIC LICENSE
TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION
0. This License Agreement applies to any software library or other
program which contains a notice placed by the copyright holder or
other authorized party saying it may be distributed under the terms of
this Lesser General Public License (also called "this License").
Each licensee is addressed as "you".
A "library" means a collection of software functions and/or data
prepared so as to be conveniently linked with application programs
(which use some of those functions and data) to form executables.
The "Library", below, refers to any such software library or work
which has been distributed under these terms. A "work based on the
Library" means either the Library or any derivative work under
copyright law: that is to say, a work containing the Library or a
portion of it, either verbatim or with modifications and/or translated
straightforwardly into another language. (Hereinafter, translation is
included without limitation in the term "modification".)
"Source code" for a work means the preferred form of the work for
making modifications to it. For a library, complete source code means
all the source code for all modules it contains, plus any associated
interface definition files, plus the scripts used to control compilation
and installation of the library.
Activities other than copying, distribution and modification are not
covered by this License; they are outside its scope. The act of
running a program using the Library is not restricted, and output from
such a program is covered only if its contents constitute a work based
on the Library (independent of the use of the Library in a tool for
writing it). Whether that is true depends on what the Library does
and what the program that uses the Library does.
1. You may copy and distribute verbatim copies of the Library's
complete source code as you receive it, in any medium, provided that
you conspicuously and appropriately publish on each copy an
appropriate copyright notice and disclaimer of warranty; keep intact
all the notices that refer to this License and to the absence of any
warranty; and distribute a copy of this License along with the
Library.
You may charge a fee for the physical act of transferring a copy,
and you may at your option offer warranty protection in exchange for a
fee.
2. You may modify your copy or copies of the Library or any portion
of it, thus forming a work based on the Library, and copy and
distribute such modifications or work under the terms of Section 1
above, provided that you also meet all of these conditions:
a) The modified work must itself be a software library.
b) You must cause the files modified to carry prominent notices
stating that you changed the files and the date of any change.
c) You must cause the whole of the work to be licensed at no
charge to all third parties under the terms of this License.
d) If a facility in the modified Library refers to a function or a
table of data to be supplied by an application program that uses
the facility, other than as an argument passed when the facility
is invoked, then you must make a good faith effort to ensure that,
in the event an application does not supply such function or
table, the facility still operates, and performs whatever part of
its purpose remains meaningful.
(For example, a function in a library to compute square roots has
a purpose that is entirely well-defined independent of the
application. Therefore, Subsection 2d requires that any
application-supplied function or table used by this function must
be optional: if the application does not supply it, the square
root function must still compute square roots.)
These requirements apply to the modified work as a whole. If
identifiable sections of that work are not derived from the Library,
and can be reasonably considered independent and separate works in
themselves, then this License, and its terms, do not apply to those
sections when you distribute them as separate works. But when you
distribute the same sections as part of a whole which is a work based
on the Library, the distribution of the whole must be on the terms of
this License, whose permissions for other licensees extend to the
entire whole, and thus to each and every part regardless of who wrote
it.
Thus, it is not the intent of this section to claim rights or contest
your rights to work written entirely by you; rather, the intent is to
exercise the right to control the distribution of derivative or
collective works based on the Library.
In addition, mere aggregation of another work not based on the Library
with the Library (or with a work based on the Library) on a volume of
a storage or distribution medium does not bring the other work under
the scope of this License.
3. You may opt to apply the terms of the ordinary GNU General Public
License instead of this License to a given copy of the Library. To do
this, you must alter all the notices that refer to this License, so
that they refer to the ordinary GNU General Public License, version 2,
instead of to this License. (If a newer version than version 2 of the
ordinary GNU General Public License has appeared, then you can specify
that version instead if you wish.) Do not make any other change in
these notices.
Once this change is made in a given copy, it is irreversible for
that copy, so the ordinary GNU General Public License applies to all
subsequent copies and derivative works made from that copy.
This option is useful when you wish to copy part of the code of
the Library into a program that is not a library.
4. You may copy and distribute the Library (or a portion or
derivative of it, under Section 2) in object code or executable form
under the terms of Sections 1 and 2 above provided that you accompany
it with the complete corresponding machine-readable source code, which
must be distributed under the terms of Sections 1 and 2 above on a
medium customarily used for software interchange.
If distribution of object code is made by offering access to copy
from a designated place, then offering equivalent access to copy the
source code from the same place satisfies the requirement to
distribute the source code, even though third parties are not
compelled to copy the source along with the object code.
5. A program that contains no derivative of any portion of the
Library, but is designed to work with the Library by being compiled or
linked with it, is called a "work that uses the Library". Such a
work, in isolation, is not a derivative work of the Library, and
therefore falls outside the scope of this License.
However, linking a "work that uses the Library" with the Library
creates an executable that is a derivative of the Library (because it
contains portions of the Library), rather than a "work that uses the
library". The executable is therefore covered by this License.
Section 6 states terms for distribution of such executables.
When a "work that uses the Library" uses material from a header file
that is part of the Library, the object code for the work may be a
derivative work of the Library even though the source code is not.
Whether this is true is especially significant if the work can be
linked without the Library, or if the work is itself a library. The
threshold for this to be true is not precisely defined by law.
If such an object file uses only numerical parameters, data
structure layouts and accessors, and small macros and small inline
functions (ten lines or less in length), then the use of the object
file is unrestricted, regardless of whether it is legally a derivative
work. (Executables containing this object code plus portions of the
Library will still fall under Section 6.)
Otherwise, if the work is a derivative of the Library, you may
distribute the object code for the work under the terms of Section 6.
Any executables containing that work also fall under Section 6,
whether or not they are linked directly with the Library itself.
6. As an exception to the Sections above, you may also combine or
link a "work that uses the Library" with the Library to produce a
work containing portions of the Library, and distribute that work
under terms of your choice, provided that the terms permit
modification of the work for the customer's own use and reverse
engineering for debugging such modifications.
You must give prominent notice with each copy of the work that the
Library is used in it and that the Library and its use are covered by
this License. You must supply a copy of this License. If the work
during execution displays copyright notices, you must include the
copyright notice for the Library among them, as well as a reference
directing the user to the copy of this License. Also, you must do one
of these things:
a) Accompany the work with the complete corresponding
machine-readable source code for the Library including whatever
changes were used in the work (which must be distributed under
Sections 1 and 2 above); and, if the work is an executable linked
with the Library, with the complete machine-readable "work that
uses the Library", as object code and/or source code, so that the
user can modify the Library and then relink to produce a modified
executable containing the modified Library. (It is understood
that the user who changes the contents of definitions files in the
Library will not necessarily be able to recompile the application
to use the modified definitions.)
b) Use a suitable shared library mechanism for linking with the
Library. A suitable mechanism is one that (1) uses at run time a
copy of the library already present on the user's computer system,
rather than copying library functions into the executable, and (2)
will operate properly with a modified version of the library, if
the user installs one, as long as the modified version is
interface-compatible with the version that the work was made with.
c) Accompany the work with a written offer, valid for at
least three years, to give the same user the materials
specified in Subsection 6a, above, for a charge no more
than the cost of performing this distribution.
d) If distribution of the work is made by offering access to copy
from a designated place, offer equivalent access to copy the above
specified materials from the same place.
e) Verify that the user has already received a copy of these
materials or that you have already sent this user a copy.
For an executable, the required form of the "work that uses the
Library" must include any data and utility programs needed for
reproducing the executable from it. However, as a special exception,
the materials to be distributed need not include anything that is
normally distributed (in either source or binary form) with the major
components (compiler, kernel, and so on) of the operating system on
which the executable runs, unless that component itself accompanies
the executable.
It may happen that this requirement contradicts the license
restrictions of other proprietary libraries that do not normally
accompany the operating system. Such a contradiction means you cannot
use both them and the Library together in an executable that you
distribute.
7. You may place library facilities that are a work based on the
Library side-by-side in a single library together with other library
facilities not covered by this License, and distribute such a combined
library, provided that the separate distribution of the work based on
the Library and of the other library facilities is otherwise
permitted, and provided that you do these two things:
a) Accompany the combined library with a copy of the same work
based on the Library, uncombined with any other library
facilities. This must be distributed under the terms of the
Sections above.
b) Give prominent notice with the combined library of the fact
that part of it is a work based on the Library, and explaining
where to find the accompanying uncombined form of the same work.
8. You may not copy, modify, sublicense, link with, or distribute
the Library except as expressly provided under this License. Any
attempt otherwise to copy, modify, sublicense, link with, or
distribute the Library is void, and will automatically terminate your
rights under this License. However, parties who have received copies,
or rights, from you under this License will not have their licenses
terminated so long as such parties remain in full compliance.
9. You are not required to accept this License, since you have not
signed it. However, nothing else grants you permission to modify or
distribute the Library or its derivative works. These actions are
prohibited by law if you do not accept this License. Therefore, by
modifying or distributing the Library (or any work based on the
Library), you indicate your acceptance of this License to do so, and
all its terms and conditions for copying, distributing or modifying
the Library or works based on it.
10. Each time you redistribute the Library (or any work based on the
Library), the recipient automatically receives a license from the
original licensor to copy, distribute, link with or modify the Library
subject to these terms and conditions. You may not impose any further
restrictions on the recipients' exercise of the rights granted herein.
You are not responsible for enforcing compliance by third parties with
this License.
11. If, as a consequence of a court judgment or allegation of patent
infringement or for any other reason (not limited to patent issues),
conditions are imposed on you (whether by court order, agreement or
otherwise) that contradict the conditions of this License, they do not
excuse you from the conditions of this License. If you cannot
distribute so as to satisfy simultaneously your obligations under this
License and any other pertinent obligations, then as a consequence you
may not distribute the Library at all. For example, if a patent
license would not permit royalty-free redistribution of the Library by
all those who receive copies directly or indirectly through you, then
the only way you could satisfy both it and this License would be to
refrain entirely from distribution of the Library.
If any portion of this section is held invalid or unenforceable under any
particular circumstance, the balance of the section is intended to apply,
and the section as a whole is intended to apply in other circumstances.
It is not the purpose of this section to induce you to infringe any
patents or other property right claims or to contest validity of any
such claims; this section has the sole purpose of protecting the
integrity of the free software distribution system which is
implemented by public license practices. Many people have made
generous contributions to the wide range of software distributed
through that system in reliance on consistent application of that
system; it is up to the author/donor to decide if he or she is willing
to distribute software through any other system and a licensee cannot
impose that choice.
This section is intended to make thoroughly clear what is believed to
be a consequence of the rest of this License.
12. If the distribution and/or use of the Library is restricted in
certain countries either by patents or by copyrighted interfaces, the
original copyright holder who places the Library under this License may add
an explicit geographical distribution limitation excluding those countries,
so that distribution is permitted only in or among countries not thus
excluded. In such case, this License incorporates the limitation as if
written in the body of this License.
13. The Free Software Foundation may publish revised and/or new
versions of the Lesser General Public License from time to time.
Such new versions will be similar in spirit to the present version,
but may differ in detail to address new problems or concerns.
Each version is given a distinguishing version number. If the Library
specifies a version number of this License which applies to it and
"any later version", you have the option of following the terms and
conditions either of that version or of any later version published by
the Free Software Foundation. If the Library does not specify a
license version number, you may choose any version ever published by
the Free Software Foundation.
14. If you wish to incorporate parts of the Library into other free
programs whose distribution conditions are incompatible with these,
write to the author to ask for permission. For software which is
copyrighted by the Free Software Foundation, write to the Free
Software Foundation; we sometimes make exceptions for this. Our
decision will be guided by the two goals of preserving the free status
of all derivatives of our free software and of promoting the sharing
and reuse of software generally.
NO WARRANTY
15. BECAUSE THE LIBRARY IS LICENSED FREE OF CHARGE, THERE IS NO
WARRANTY FOR THE LIBRARY, TO THE EXTENT PERMITTED BY APPLICABLE LAW.
EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR
OTHER PARTIES PROVIDE THE LIBRARY "AS IS" WITHOUT WARRANTY OF ANY
KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE
IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE
LIBRARY IS WITH YOU. SHOULD THE LIBRARY PROVE DEFECTIVE, YOU ASSUME
THE COST OF ALL NECESSARY SERVICING, REPAIR OR CORRECTION.
16. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN
WRITING WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY
AND/OR REDISTRIBUTE THE LIBRARY AS PERMITTED ABOVE, BE LIABLE TO YOU
FOR DAMAGES, INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR
CONSEQUENTIAL DAMAGES ARISING OUT OF THE USE OR INABILITY TO USE THE
LIBRARY (INCLUDING BUT NOT LIMITED TO LOSS OF DATA OR DATA BEING
RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD PARTIES OR A
FAILURE OF THE LIBRARY TO OPERATE WITH ANY OTHER SOFTWARE), EVEN IF
SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH
DAMAGES.
END OF TERMS AND CONDITIONS
How to Apply These Terms to Your New Libraries
If you develop a new library, and you want it to be of the greatest
possible use to the public, we recommend making it free software that
everyone can redistribute and change. You can do so by permitting
redistribution under these terms (or, alternatively, under the terms of the
ordinary General Public License).
To apply these terms, attach the following notices to the library. It is
safest to attach them to the start of each source file to most effectively
convey the exclusion of warranty; and each file should have at least the
"copyright" line and a pointer to where the full notice is found.
<one line to give the library's name and a brief idea of what it does.>
Copyright (C) <year> <name of author>
This library is free software; you can redistribute it and/or
modify it under the terms of the GNU Lesser General Public
License as published by the Free Software Foundation; either
version 2.1 of the License, or (at your option) any later version.
This library 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
Lesser General Public License for more details.
You should have received a copy of the GNU Lesser General Public
License along with this library; if not, write to the Free Software
Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
Also add information on how to contact you by electronic and paper mail.
You should also get your employer (if you work as a programmer) or your
school, if any, to sign a "copyright disclaimer" for the library, if
necessary. Here is a sample; alter the names:
Yoyodyne, Inc., hereby disclaims all copyright interest in the
library `Frob' (a library for tweaking knobs) written by James Random Hacker.
<signature of Ty Coon>, 1 April 1990
Ty Coon, President of Vice
That's all there is to it!

View File

@@ -1,170 +0,0 @@
================================================================================
= APE Tag Specification, Version 2.000
================================================================================
Original Content (C) 2004, Frank Klemm <frank.klemm@elster.offl.uni-jena.de>
Formatting / Editing (C) 2004, Scott Wheeler <wheeler@kde.org>
================================================================================
= Contents
================================================================================
1 - APE Tag General Structure
2 - APE Tag Header / Footer Format
3 - APE Tag Flags
4 - APE Tag Item Format
5 - APE Tag Item Supported Keys
6 - APE Tag Item Content
7 - Data Types
7.1 - Data Types / UTF-8
7.2 - Data Types / Dates
7.3 - Data Types / Timestamps
================================================================================
= 1 - APE Tag General Structure
================================================================================
Member of Basic Components of SV8 Stream Note:
It is strongly recommended that the data size be stored in the tags. The size
should normally be in the roughly one kilobyte, never more than 8 kilobytes.
Larger data should be stored externally using link entries. Linked data is much
easier to process by normal programs, so for instance JPEG data should not be
included inside the audio file.
APE Tag Version 2.000 (with header, recommended):
/================================\
| APE Tag Header | 32 bytes |
|-------------------|------------|
| APE Tag Item 1 | > 10 bytes |
| APE Tag Item 2 | > 10 bytes |
| APE Tag Item n-1 | > 10 bytes |
| APE Tag Item n | > 10 bytes |
|-------------------|------------|
| APE Tag Footer | 32 bytes |
\================================/
APE tag items should be sorted ascending by size. When streaming, parts of the
APE tag may be dropped to reduce the danger of drop outs between tracks. This
is not required, but is strongly recommended. It would be desirable for the i
tems to be sorted by importance / size, but this is not feasible. This
convention should only be broken when adding less important small items and it
is not desirable to rewrite the entire tag. An APE tag at the end of a file
(the recommended location) must have at least a footer; an APE tag at the
beginning of a file (strongly discouraged) must have at least a header.
APE Tag Version 1.000 (without header, deprecated)
/================================\
| APE Tag Item 1 | > 10 bytes |
| APE Tag Item 2 | > 10 bytes |
| APE Tag Item n-1 | > 10 bytes |
| APE Tag Item n | > 10 bytes |
|-------------------|------------|
| APE Tag Footer | 32 bytes |
\================================/
================================================================================
= 2 - APE Tag Header / Footer Format
================================================================================
Contains number, length and attributes of all tag items
Header and Footer are different in 1 bit in the Tags Flags to distinguish
between them.
Member of APE Tag 2.0
/===========================================================================\
| Preamble | 8 bytes | { 'A', 'P', 'E', 'T', 'A', 'G', 'E', 'X' } |
|----------------|---------|------------------------------------------------|
| Version Number | 4 bytes | 1000 = Version 1.000, 2000 = Version 2.000 |
|----------------|---------|------------------------------------------------|
| Tag Size | 4 bytes | Tag size in bytes including footer and all tag |
| | | items excluding the header (for 1.000 |
| | | compatibility) |
|----------------|---------|------------------------------------------------|
| Item Count | 4 bytes | Number of items in the tag |
|----------------|---------|------------------------------------------------|
| Tag Flags | 4 bytes | Global flags |
|----------------|---------|------------------------------------------------|
| Reserved | 8 bytes | Must be zeroed |
\===========================================================================/
================================================================================
= 3 - APE Tag Flags
================================================================================
The general flag structure for either items or headers / footers is the same.
Bits 31, 30 and 29 are specific to headers / footers, whereas 2 through 0 are
item specific.
Note: APE Tags from Version 1.0 do not use any of the following. All flags in
that version are zeroed and ignored when reading.
/=================================================================\
| Contains Header | Bit 31 | 1 - has header | 0 - no header |
|-----------------|-------------|---------------------------------|
| Contains Footer | Bit 30 | 1 - has footer | 0 - no footer |
|-----------------|-------------|---------------------------------|
| Is Header | Bit 29 | 1 - is header | 0 - is footer |
|-----------------|-------------|---------------------------------|
| Undefined | Bits 28 - 3 | Undefined, must be zeroed |
|-----------------|-------------|---------------------------------|
| Encoding | Bits 2 - 1 | 00 - UTF-8 |
| | | 01 - Binary Data * |
| | | 10 - External Reference ** |
| | | 11 - Reserved |
|-----------------|-------------|---------------------------------|
| Read Only | Bit 0 | 1 - read only | 0 - read/write |
\=================================================================/
(*) Should be ignored by tools for editing text values
(**) Allowed external reference formats:
- http://host/directory/filename.ext
- ftp://host/directory/filename.ext
- filename.ext
- /directory/filename.ext
- DRIVE:/directory/filename.ext
Note: External references are also UTF-8 encoded.
================================================================================
= 4 - APE Tag Item Format
================================================================================
APE Tag Items are stored as key-value pairs. APE Tags Item Key are case
sensitive, however it is illegal to use keys which only differ in case and
it is recommended that tag reading not be case sensitive.
Every key can only occur (at most) once. It is not possible to repeat a key
to signify updated contents.
Tags can be partially or completely repeated in the streaming format. This
makes it possible to display an artist and / or title if it was missed at the
beginning of the stream. It is recommended that the important information like
artist, album and title should occur approximately every 2 minutes in the
stream and again 5 to 10 seconds before the end. However, care should be tak
en not to replicate this information too often or during passages with high
bitrate demands to avoid unnecessary drop-outs.
/==============================================================================\
| Content Size | 4 bytes | Length of the value in bytes |
|----------------|---------------|---------------------------------------------|
| Flags | 4 bytes | Item flags |
|----------------|---------------|---------------------------------------------|
| Key | 2 - 255 bytes | Item key |
|----------------|---------------|---------------------------------------------|
| Key Terminator | 1 byte | Null byte that indicates the end of the key |
|----------------|---------------|---------------------------------------------|
| Value | variable | Content (formatted according to the flags) |
\==============================================================================/
================================================================================
Sections 5 - 7 haven't yet been converted from:
http://www.personal.uni-jena.de/~pfk/mpp/sv8/apetag.html

View File

@@ -1,314 +0,0 @@
/***************************************************************************
copyright : (C) 2010 by Alex Novichkov
email : novichko@atnet.ru
copyright : (C) 2006 by Lukáš Lalinský
email : lalinsky@gmail.com
(original WavPack implementation)
copyright : (C) 2004 by Allan Sandfeld Jensen
email : kde@carewolf.org
(original MPC implementation)
***************************************************************************/
/***************************************************************************
* This library is free software; you can redistribute it and/or modify *
* it under the terms of the GNU Lesser General Public License version *
* 2.1 as published by the Free Software Foundation. *
* *
* This library 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 *
* Lesser General Public License for more details. *
* *
* You should have received a copy of the GNU Lesser General Public *
* License along with this library; if not, write to the Free Software *
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA *
* 02110-1301 USA *
* *
* Alternatively, this file is available under the Mozilla Public *
* License Version 1.1. You may obtain a copy of the License at *
* http://www.mozilla.org/MPL/ *
***************************************************************************/
#include <tbytevector.h>
#include <tstring.h>
#include <tdebug.h>
#include <tagunion.h>
#include <id3v1tag.h>
#include <id3v2header.h>
#include <tpropertymap.h>
#include <tagutils.h>
#include "apefile.h"
#include "apetag.h"
#include "apefooter.h"
using namespace TagLib;
namespace
{
enum { ApeAPEIndex = 0, ApeID3v1Index = 1 };
}
class APE::File::FilePrivate
{
public:
FilePrivate() :
APELocation(-1),
APESize(0),
ID3v1Location(-1),
ID3v2Header(0),
ID3v2Location(-1),
ID3v2Size(0),
properties(0) {}
~FilePrivate()
{
delete ID3v2Header;
delete properties;
}
long APELocation;
long APESize;
long ID3v1Location;
ID3v2::Header *ID3v2Header;
long ID3v2Location;
long ID3v2Size;
TagUnion tag;
Properties *properties;
};
////////////////////////////////////////////////////////////////////////////////
// static members
////////////////////////////////////////////////////////////////////////////////
bool APE::File::isSupported(IOStream *stream)
{
// An APE file has an ID "MAC " somewhere. An ID3v2 tag may precede.
const ByteVector buffer = Utils::readHeader(stream, bufferSize(), true);
return (buffer.find("MAC ") >= 0);
}
////////////////////////////////////////////////////////////////////////////////
// public members
////////////////////////////////////////////////////////////////////////////////
APE::File::File(FileName file, bool readProperties, Properties::ReadStyle) :
TagLib::File(file),
d(new FilePrivate())
{
if(isOpen())
read(readProperties);
}
APE::File::File(IOStream *stream, bool readProperties, Properties::ReadStyle) :
TagLib::File(stream),
d(new FilePrivate())
{
if(isOpen())
read(readProperties);
}
APE::File::~File()
{
delete d;
}
TagLib::Tag *APE::File::tag() const
{
return &d->tag;
}
PropertyMap APE::File::properties() const
{
return d->tag.properties();
}
void APE::File::removeUnsupportedProperties(const StringList &properties)
{
d->tag.removeUnsupportedProperties(properties);
}
PropertyMap APE::File::setProperties(const PropertyMap &properties)
{
if(ID3v1Tag())
ID3v1Tag()->setProperties(properties);
return APETag(true)->setProperties(properties);
}
APE::Properties *APE::File::audioProperties() const
{
return d->properties;
}
bool APE::File::save()
{
if(readOnly()) {
debug("APE::File::save() -- File is read only.");
return false;
}
// Update ID3v1 tag
if(ID3v1Tag() && !ID3v1Tag()->isEmpty()) {
// ID3v1 tag is not empty. Update the old one or create a new one.
if(d->ID3v1Location >= 0) {
seek(d->ID3v1Location);
}
else {
seek(0, End);
d->ID3v1Location = tell();
}
writeBlock(ID3v1Tag()->render());
}
else {
// ID3v1 tag is empty. Remove the old one.
if(d->ID3v1Location >= 0) {
truncate(d->ID3v1Location);
d->ID3v1Location = -1;
}
}
// Update APE tag
if(APETag() && !APETag()->isEmpty()) {
// APE tag is not empty. Update the old one or create a new one.
if(d->APELocation < 0) {
if(d->ID3v1Location >= 0)
d->APELocation = d->ID3v1Location;
else
d->APELocation = length();
}
const ByteVector data = APETag()->render();
insert(data, d->APELocation, d->APESize);
if(d->ID3v1Location >= 0)
d->ID3v1Location += (static_cast<long>(data.size()) - d->APESize);
d->APESize = data.size();
}
else {
// APE tag is empty. Remove the old one.
if(d->APELocation >= 0) {
removeBlock(d->APELocation, d->APESize);
if(d->ID3v1Location >= 0)
d->ID3v1Location -= d->APESize;
d->APELocation = -1;
d->APESize = 0;
}
}
return true;
}
ID3v1::Tag *APE::File::ID3v1Tag(bool create)
{
return d->tag.access<ID3v1::Tag>(ApeID3v1Index, create);
}
APE::Tag *APE::File::APETag(bool create)
{
return d->tag.access<APE::Tag>(ApeAPEIndex, create);
}
void APE::File::strip(int tags)
{
if(tags & ID3v1)
d->tag.set(ApeID3v1Index, 0);
if(tags & APE)
d->tag.set(ApeAPEIndex, 0);
if(!ID3v1Tag())
APETag(true);
}
bool APE::File::hasAPETag() const
{
return (d->APELocation >= 0);
}
bool APE::File::hasID3v1Tag() const
{
return (d->ID3v1Location >= 0);
}
////////////////////////////////////////////////////////////////////////////////
// private members
////////////////////////////////////////////////////////////////////////////////
void APE::File::read(bool readProperties)
{
// Look for an ID3v2 tag
d->ID3v2Location = Utils::findID3v2(this);
if(d->ID3v2Location >= 0) {
seek(d->ID3v2Location);
d->ID3v2Header = new ID3v2::Header(readBlock(ID3v2::Header::size()));
d->ID3v2Size = d->ID3v2Header->completeTagSize();
}
// Look for an ID3v1 tag
d->ID3v1Location = Utils::findID3v1(this);
if(d->ID3v1Location >= 0)
d->tag.set(ApeID3v1Index, new ID3v1::Tag(this, d->ID3v1Location));
// Look for an APE tag
d->APELocation = Utils::findAPE(this, d->ID3v1Location);
if(d->APELocation >= 0) {
d->tag.set(ApeAPEIndex, new APE::Tag(this, d->APELocation));
d->APESize = APETag()->footer()->completeTagSize();
d->APELocation = d->APELocation + APE::Footer::size() - d->APESize;
}
if(d->ID3v1Location < 0)
APETag(true);
// Look for APE audio properties
if(readProperties) {
long streamLength;
if(d->APELocation >= 0)
streamLength = d->APELocation;
else if(d->ID3v1Location >= 0)
streamLength = d->ID3v1Location;
else
streamLength = length();
if(d->ID3v2Location >= 0) {
seek(d->ID3v2Location + d->ID3v2Size);
streamLength -= (d->ID3v2Location + d->ID3v2Size);
}
else {
seek(0);
}
d->properties = new Properties(this, streamLength);
}
}

View File

@@ -1,235 +0,0 @@
/***************************************************************************
copyright : (C) 2010 by Alex Novichkov
email : novichko@atnet.ru
copyright : (C) 2006 by Lukáš Lalinský
email : lalinsky@gmail.com
(original WavPack implementation)
copyright : (C) 2004 by Allan Sandfeld Jensen
email : kde@carewolf.org
(original MPC implementation)
***************************************************************************/
/***************************************************************************
* This library is free software; you can redistribute it and/or modify *
* it under the terms of the GNU Lesser General Public License version *
* 2.1 as published by the Free Software Foundation. *
* *
* This library 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 *
* Lesser General Public License for more details. *
* *
* You should have received a copy of the GNU Lesser General Public *
* License along with this library; if not, write to the Free Software *
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA *
* 02110-1301 USA *
* *
* Alternatively, this file is available under the Mozilla Public *
* License Version 1.1. You may obtain a copy of the License at *
* http://www.mozilla.org/MPL/ *
***************************************************************************/
#ifndef TAGLIB_APEFILE_H
#define TAGLIB_APEFILE_H
#include "tfile.h"
#include "taglib_export.h"
#include "apeproperties.h"
namespace TagLib {
class Tag;
namespace ID3v1 { class Tag; }
namespace APE { class Tag; }
//! An implementation of APE metadata
/*!
* This is implementation of APE metadata.
*
* This supports ID3v1 and APE (v1 and v2) style comments as well as reading stream
* properties from the file.
*/
namespace APE {
//! An implementation of TagLib::File with APE specific methods
/*!
* This implements and provides an interface for APE files to the
* TagLib::Tag and TagLib::AudioProperties interfaces by way of implementing
* the abstract TagLib::File API as well as providing some additional
* information specific to APE files.
*/
class TAGLIB_EXPORT File : public TagLib::File
{
public:
/*!
* This set of flags is used for various operations and is suitable for
* being OR-ed together.
*/
enum TagTypes {
//! Empty set. Matches no tag types.
NoTags = 0x0000,
//! Matches ID3v1 tags.
ID3v1 = 0x0001,
//! Matches APE tags.
APE = 0x0002,
//! Matches all tag types.
AllTags = 0xffff
};
/*!
* Constructs an APE file from \a file. If \a readProperties is true the
* file's audio properties will also be read.
*
* \note In the current implementation, \a propertiesStyle is ignored.
*/
File(FileName file, bool readProperties = true,
Properties::ReadStyle propertiesStyle = Properties::Average);
/*!
* Constructs an APE file from \a stream. If \a readProperties is true the
* file's audio properties will also be read.
*
* \note TagLib will *not* take ownership of the stream, the caller is
* responsible for deleting it after the File object.
*
* \note In the current implementation, \a propertiesStyle is ignored.
*/
File(IOStream *stream, bool readProperties = true,
Properties::ReadStyle propertiesStyle = Properties::Average);
/*!
* Destroys this instance of the File.
*/
virtual ~File();
/*!
* Returns the Tag for this file. This will be an APE tag, an ID3v1 tag
* or a combination of the two.
*/
virtual TagLib::Tag *tag() const;
/*!
* Implements the unified property interface -- export function.
* If the file contains both an APE and an ID3v1 tag, only APE
* will be converted to the PropertyMap.
*/
PropertyMap properties() const;
/*!
* Removes unsupported properties. Forwards to the actual Tag's
* removeUnsupportedProperties() function.
*/
void removeUnsupportedProperties(const StringList &properties);
/*!
* Implements the unified property interface -- import function.
* Creates an APEv2 tag if necessary. A potentially existing ID3v1
* tag will be updated as well.
*/
PropertyMap setProperties(const PropertyMap &);
/*!
* Returns the APE::Properties for this file. If no audio properties
* were read then this will return a null pointer.
*/
virtual Properties *audioProperties() const;
/*!
* Saves the file.
*
* \note According to the official Monkey's Audio SDK, an APE file
* can only have either ID3V1 or APE tags, so a parameter is used here.
*/
virtual bool save();
/*!
* Returns a pointer to the ID3v1 tag of the file.
*
* If \a create is false (the default) this may return a null pointer
* if there is no valid ID3v1 tag. If \a create is true it will create
* an ID3v1 tag if one does not exist and returns a valid pointer.
*
* \note This may return a valid pointer regardless of whether or not the
* file on disk has an ID3v1 tag. Use hasID3v1Tag() to check if the file
* on disk actually has an ID3v1 tag.
*
* \note The Tag <b>is still</b> owned by the MPEG::File and should not be
* deleted by the user. It will be deleted when the file (object) is
* destroyed.
*
* \see hasID3v1Tag()
*/
ID3v1::Tag *ID3v1Tag(bool create = false);
/*!
* Returns a pointer to the APE tag of the file.
*
* If \a create is false (the default) this may return a null pointer
* if there is no valid APE tag. If \a create is true it will create
* an APE tag if one does not exist and returns a valid pointer.
*
* \note This may return a valid pointer regardless of whether or not the
* file on disk has an APE tag. Use hasAPETag() to check if the file
* on disk actually has an APE tag.
*
* \note The Tag <b>is still</b> owned by the MPEG::File and should not be
* deleted by the user. It will be deleted when the file (object) is
* destroyed.
*
* \see hasAPETag()
*/
APE::Tag *APETag(bool create = false);
/*!
* This will remove the tags that match the OR-ed together TagTypes from the
* file. By default it removes all tags.
*
* \note This will also invalidate pointers to the tags
* as their memory will be freed.
* \note In order to make the removal permanent save() still needs to be called
*/
void strip(int tags = AllTags);
/*!
* Returns whether or not the file on disk actually has an APE tag.
*
* \see APETag()
*/
bool hasAPETag() const;
/*!
* Returns whether or not the file on disk actually has an ID3v1 tag.
*
* \see ID3v1Tag()
*/
bool hasID3v1Tag() const;
/*!
* Returns whether or not the given \a stream can be opened as an APE
* file.
*
* \note This method is designed to do a quick check. The result may
* not necessarily be correct.
*/
static bool isSupported(IOStream *stream);
private:
File(const File &);
File &operator=(const File &);
void read(bool readProperties);
class FilePrivate;
FilePrivate *d;
};
}
}
#endif

View File

@@ -1,234 +0,0 @@
/***************************************************************************
copyright : (C) 2004 by Allan Sandfeld Jensen
(C) 2002 - 2008 by Scott Wheeler (id3v2header.cpp)
email : kde@carewolf.org
***************************************************************************/
/***************************************************************************
* This library is free software; you can redistribute it and/or modify *
* it under the terms of the GNU Lesser General Public License version *
* 2.1 as published by the Free Software Foundation. *
* *
* This library 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 *
* Lesser General Public License for more details. *
* *
* You should have received a copy of the GNU Lesser General Public *
* License along with this library; if not, write to the Free Software *
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA *
* 02110-1301 USA *
* *
* Alternatively, this file is available under the Mozilla Public *
* License Version 1.1. You may obtain a copy of the License at *
* http://www.mozilla.org/MPL/ *
***************************************************************************/
#include <iostream>
#include <bitset>
#include <tstring.h>
#include <tdebug.h>
#include "apefooter.h"
using namespace TagLib;
using namespace APE;
class APE::Footer::FooterPrivate
{
public:
FooterPrivate() :
version(0),
footerPresent(true),
headerPresent(false),
isHeader(false),
itemCount(0),
tagSize(0) {}
unsigned int version;
bool footerPresent;
bool headerPresent;
bool isHeader;
unsigned int itemCount;
unsigned int tagSize;
};
////////////////////////////////////////////////////////////////////////////////
// static members
////////////////////////////////////////////////////////////////////////////////
unsigned int APE::Footer::size()
{
return 32;
}
ByteVector APE::Footer::fileIdentifier()
{
return ByteVector("APETAGEX");
}
////////////////////////////////////////////////////////////////////////////////
// public members
////////////////////////////////////////////////////////////////////////////////
APE::Footer::Footer() :
d(new FooterPrivate())
{
}
APE::Footer::Footer(const ByteVector &data) :
d(new FooterPrivate())
{
parse(data);
}
APE::Footer::~Footer()
{
delete d;
}
unsigned int APE::Footer::version() const
{
return d->version;
}
bool APE::Footer::headerPresent() const
{
return d->headerPresent;
}
bool APE::Footer::footerPresent() const
{
return d->footerPresent;
}
bool APE::Footer::isHeader() const
{
return d->isHeader;
}
void APE::Footer::setHeaderPresent(bool b) const
{
d->headerPresent = b;
}
unsigned int APE::Footer::itemCount() const
{
return d->itemCount;
}
void APE::Footer::setItemCount(unsigned int s)
{
d->itemCount = s;
}
unsigned int APE::Footer::tagSize() const
{
return d->tagSize;
}
unsigned int APE::Footer::completeTagSize() const
{
if(d->headerPresent)
return d->tagSize + size();
else
return d->tagSize;
}
void APE::Footer::setTagSize(unsigned int s)
{
d->tagSize = s;
}
void APE::Footer::setData(const ByteVector &data)
{
parse(data);
}
ByteVector APE::Footer::renderFooter() const
{
return render(false);
}
ByteVector APE::Footer::renderHeader() const
{
if(!d->headerPresent)
return ByteVector();
else
return render(true);
}
////////////////////////////////////////////////////////////////////////////////
// protected members
////////////////////////////////////////////////////////////////////////////////
void APE::Footer::parse(const ByteVector &data)
{
if(data.size() < size())
return;
// The first eight bytes, data[0..7], are the File Identifier, "APETAGEX".
// Read the version number
d->version = data.toUInt(8, false);
// Read the tag size
d->tagSize = data.toUInt(12, false);
// Read the item count
d->itemCount = data.toUInt(16, false);
// Read the flags
std::bitset<32> flags(TAGLIB_CONSTRUCT_BITSET(data.toUInt(20, false)));
d->headerPresent = flags[31];
d->footerPresent = !flags[30];
d->isHeader = flags[29];
}
ByteVector APE::Footer::render(bool isHeader) const
{
ByteVector v;
// add the file identifier -- "APETAGEX"
v.append(fileIdentifier());
// add the version number -- we always render a 2.000 tag regardless of what
// the tag originally was.
v.append(ByteVector::fromUInt(2000, false));
// add the tag size
v.append(ByteVector::fromUInt(d->tagSize, false));
// add the item count
v.append(ByteVector::fromUInt(d->itemCount, false));
// render and add the flags
std::bitset<32> flags;
flags[31] = d->headerPresent;
flags[30] = false; // footer is always present
flags[29] = isHeader;
v.append(ByteVector::fromUInt(flags.to_ulong(), false));
// add the reserved 64bit
v.append(ByteVector::fromLongLong(0));
return v;
}

View File

@@ -1,173 +0,0 @@
/***************************************************************************
copyright : (C) 2004 by Allan Sandfeld Jensen
email : kde@carewolf.org
***************************************************************************/
/***************************************************************************
* This library is free software; you can redistribute it and/or modify *
* it under the terms of the GNU Lesser General Public License version *
* 2.1 as published by the Free Software Foundation. *
* *
* This library 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 *
* Lesser General Public License for more details. *
* *
* You should have received a copy of the GNU Lesser General Public *
* License along with this library; if not, write to the Free Software *
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA *
* 02110-1301 USA *
* *
* Alternatively, this file is available under the Mozilla Public *
* License Version 1.1. You may obtain a copy of the License at *
* http://www.mozilla.org/MPL/ *
***************************************************************************/
#ifndef TAGLIB_APEFOOTER_H
#define TAGLIB_APEFOOTER_H
#include "tbytevector.h"
#include "taglib_export.h"
namespace TagLib {
namespace APE {
//! An implementation of APE footers
/*!
* This class implements APE footers (and headers). It attempts to follow, both
* semantically and programmatically, the structure specified in
* the APE v2.0 standard. The API is based on the properties of APE footer and
* headers specified there.
*/
class TAGLIB_EXPORT Footer
{
public:
/*!
* Constructs an empty APE footer.
*/
Footer();
/*!
* Constructs an APE footer based on \a data. parse() is called
* immediately.
*/
Footer(const ByteVector &data);
/*!
* Destroys the footer.
*/
virtual ~Footer();
/*!
* Returns the version number. (Note: This is the 1000 or 2000.)
*/
unsigned int version() const;
/*!
* Returns true if a header is present in the tag.
*/
bool headerPresent() const;
/*!
* Returns true if a footer is present in the tag.
*/
bool footerPresent() const;
/*!
* Returns true this is actually the header.
*/
bool isHeader() const;
/*!
* Sets whether the header should be rendered or not
*/
void setHeaderPresent(bool b) const;
/*!
* Returns the number of items in the tag.
*/
unsigned int itemCount() const;
/*!
* Set the item count to \a s.
* \see itemCount()
*/
void setItemCount(unsigned int s);
/*!
* Returns the tag size in bytes. This is the size of the frame content and footer.
* The size of the \e entire tag will be this plus the header size, if present.
*
* \see completeTagSize()
*/
unsigned int tagSize() const;
/*!
* Returns the tag size, including if present, the header
* size.
*
* \see tagSize()
*/
unsigned int completeTagSize() const;
/*!
* Set the tag size to \a s.
* \see tagSize()
*/
void setTagSize(unsigned int s);
/*!
* Returns the size of the footer. Presently this is always 32 bytes.
*/
static unsigned int size();
/*!
* Returns the string used to identify an APE tag inside of a file.
* Presently this is always "APETAGEX".
*/
static ByteVector fileIdentifier();
/*!
* Sets the data that will be used as the footer. 32 bytes,
* starting from \a data will be used.
*/
void setData(const ByteVector &data);
/*!
* Renders the footer back to binary format.
*/
ByteVector renderFooter() const;
/*!
* Renders the header corresponding to the footer. If headerPresent is
* set to false, it returns an empty ByteVector.
*/
ByteVector renderHeader() const;
protected:
/*!
* Called by setData() to parse the footer data. It makes this information
* available through the public API.
*/
void parse(const ByteVector &data);
/*!
* Called by renderFooter and renderHeader
*/
ByteVector render(bool isHeader) const;
private:
Footer(const Footer &);
Footer &operator=(const Footer &);
class FooterPrivate;
FooterPrivate *d;
};
}
}
#endif

View File

@@ -1,301 +0,0 @@
/***************************************************************************
copyright : (C) 2004 by Allan Sandfeld Jensen
email : kde@carewolf.com
***************************************************************************/
/***************************************************************************
* This library is free software; you can redistribute it and/or modify *
* it under the terms of the GNU Lesser General Public License version *
* 2.1 as published by the Free Software Foundation. *
* *
* This library 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 *
* Lesser General Public License for more details. *
* *
* You should have received a copy of the GNU Lesser General Public *
* License along with this library; if not, write to the Free Software *
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA *
* 02110-1301 USA *
* *
* Alternatively, this file is available under the Mozilla Public *
* License Version 1.1. You may obtain a copy of the License at *
* http://www.mozilla.org/MPL/ *
***************************************************************************/
#include <tbytevectorlist.h>
#include <tdebug.h>
#include "apeitem.h"
using namespace TagLib;
using namespace APE;
class APE::Item::ItemPrivate
{
public:
ItemPrivate() :
type(Text),
readOnly(false) {}
Item::ItemTypes type;
String key;
ByteVector value;
StringList text;
bool readOnly;
};
////////////////////////////////////////////////////////////////////////////////
// public members
////////////////////////////////////////////////////////////////////////////////
APE::Item::Item() :
d(new ItemPrivate())
{
}
APE::Item::Item(const String &key, const String &value) :
d(new ItemPrivate())
{
d->key = key;
d->text.append(value);
}
APE::Item::Item(const String &key, const StringList &values) :
d(new ItemPrivate())
{
d->key = key;
d->text = values;
}
APE::Item::Item(const String &key, const ByteVector &value, bool binary) :
d(new ItemPrivate())
{
d->key = key;
if(binary) {
d->type = Binary;
d->value = value;
}
else {
d->text.append(value);
}
}
APE::Item::Item(const Item &item) :
d(new ItemPrivate(*item.d))
{
}
APE::Item::~Item()
{
delete d;
}
Item &APE::Item::operator=(const Item &item)
{
Item(item).swap(*this);
return *this;
}
void APE::Item::swap(Item &item)
{
using std::swap;
swap(d, item.d);
}
void APE::Item::setReadOnly(bool readOnly)
{
d->readOnly = readOnly;
}
bool APE::Item::isReadOnly() const
{
return d->readOnly;
}
void APE::Item::setType(APE::Item::ItemTypes val)
{
d->type = val;
}
APE::Item::ItemTypes APE::Item::type() const
{
return d->type;
}
String APE::Item::key() const
{
return d->key;
}
ByteVector APE::Item::binaryData() const
{
return d->value;
}
void APE::Item::setBinaryData(const ByteVector &value)
{
d->type = Binary;
d->value = value;
d->text.clear();
}
ByteVector APE::Item::value() const
{
// This seems incorrect as it won't be actually rendering the value to keep it
// up to date.
return d->value;
}
void APE::Item::setKey(const String &key)
{
d->key = key;
}
void APE::Item::setValue(const String &value)
{
d->type = Text;
d->text = value;
d->value.clear();
}
void APE::Item::setValues(const StringList &value)
{
d->type = Text;
d->text = value;
d->value.clear();
}
void APE::Item::appendValue(const String &value)
{
d->type = Text;
d->text.append(value);
d->value.clear();
}
void APE::Item::appendValues(const StringList &values)
{
d->type = Text;
d->text.append(values);
d->value.clear();
}
int APE::Item::size() const
{
int result = 8 + d->key.size() + 1;
switch(d->type) {
case Text:
if(!d->text.isEmpty()) {
StringList::ConstIterator it = d->text.begin();
result += it->data(String::UTF8).size();
it++;
for(; it != d->text.end(); ++it)
result += 1 + it->data(String::UTF8).size();
}
break;
case Binary:
case Locator:
result += d->value.size();
break;
}
return result;
}
StringList APE::Item::toStringList() const
{
return d->text;
}
StringList APE::Item::values() const
{
return d->text;
}
String APE::Item::toString() const
{
if(d->type == Text && !isEmpty())
return d->text.front();
else
return String();
}
bool APE::Item::isEmpty() const
{
switch(d->type) {
case Text:
if(d->text.isEmpty())
return true;
if(d->text.size() == 1 && d->text.front().isEmpty())
return true;
return false;
case Binary:
case Locator:
return d->value.isEmpty();
default:
return false;
}
}
void APE::Item::parse(const ByteVector &data)
{
// 11 bytes is the minimum size for an APE item
if(data.size() < 11) {
debug("APE::Item::parse() -- no data in item");
return;
}
const unsigned int valueLength = data.toUInt(0, false);
const unsigned int flags = data.toUInt(4, false);
// An item key can contain ASCII characters from 0x20 up to 0x7E, not UTF-8.
// We assume that the validity of the given key has been checked.
d->key = String(&data[8], String::Latin1);
const ByteVector value = data.mid(8 + d->key.size() + 1, valueLength);
setReadOnly(flags & 1);
setType(ItemTypes((flags >> 1) & 3));
if(Text == d->type)
d->text = StringList(ByteVectorList::split(value, '\0'), String::UTF8);
else
d->value = value;
}
ByteVector APE::Item::render() const
{
ByteVector data;
unsigned int flags = ((d->readOnly) ? 1 : 0) | (d->type << 1);
ByteVector value;
if(isEmpty())
return data;
if(d->type == Text) {
StringList::ConstIterator it = d->text.begin();
value.append(it->data(String::UTF8));
it++;
for(; it != d->text.end(); ++it) {
value.append('\0');
value.append(it->data(String::UTF8));
}
d->value = value;
}
else
value.append(d->value);
data.append(ByteVector::fromUInt(value.size(), false));
data.append(ByteVector::fromUInt(flags, false));
data.append(d->key.data(String::Latin1));
data.append(ByteVector('\0'));
data.append(value);
return data;
}

View File

@@ -1,224 +0,0 @@
/***************************************************************************
copyright : (C) 2004 by Allan Sandfeld Jensen
email : kde@carewolf.org
***************************************************************************/
/***************************************************************************
* This library is free software; you can redistribute it and/or modify *
* it under the terms of the GNU Lesser General Public License version *
* 2.1 as published by the Free Software Foundation. *
* *
* This library 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 *
* Lesser General Public License for more details. *
* *
* You should have received a copy of the GNU Lesser General Public *
* License along with this library; if not, write to the Free Software *
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA *
* 02110-1301 USA *
* *
* Alternatively, this file is available under the Mozilla Public *
* License Version 1.1. You may obtain a copy of the License at *
* http://www.mozilla.org/MPL/ *
***************************************************************************/
#ifndef TAGLIB_APEITEM_H
#define TAGLIB_APEITEM_H
#include "tbytevector.h"
#include "tstring.h"
#include "tstringlist.h"
namespace TagLib {
namespace APE {
//! An implementation of APE-items
/*!
* This class provides the features of items in the APEv2 standard.
*/
class TAGLIB_EXPORT Item
{
public:
/*!
* Enum of types an Item can have. The value of 3 is reserved.
*/
enum ItemTypes {
//! Item contains text information coded in UTF-8
Text = 0,
//! Item contains binary information
Binary = 1,
//! Item is a locator of external stored information
Locator = 2
};
/*!
* Constructs an empty item.
*/
Item();
/*!
* Constructs a text item with \a key and \a value.
*/
// BIC: Remove this, StringList has a constructor from a single string
Item(const String &key, const String &value);
/*!
* Constructs a text item with \a key and \a values.
*/
Item(const String &key, const StringList &values);
/*!
* Constructs an item with \a key and \a value.
* If \a binary is true a Binary item will be created, otherwise \a value will be interpreted as text
*/
Item(const String &key, const ByteVector &value, bool binary);
/*!
* Construct an item as a copy of \a item.
*/
Item(const Item &item);
/*!
* Destroys the item.
*/
virtual ~Item();
/*!
* Copies the contents of \a item into this item.
*/
Item &operator=(const Item &item);
/*!
* Exchanges the content of this item by the content of \a item.
*/
void swap(Item &item);
/*!
* Returns the key.
*/
String key() const;
/*!
* Returns the binary value.
* If the item type is not \a Binary, always returns an empty ByteVector.
*/
ByteVector binaryData() const;
/*!
* Set the binary value to \a value
* The item's type will also be set to \a Binary
*/
void setBinaryData(const ByteVector &value);
#ifndef DO_NOT_DOCUMENT
/* Remove in next binary incompatible release */
ByteVector value() const;
#endif
/*!
* Sets the key for the item to \a key.
*/
void setKey(const String &key);
/*!
* Sets the text value of the item to \a value and clears any previous contents.
*
* \see toString()
*/
void setValue(const String &value);
/*!
* Sets the text value of the item to the list of values in \a value and clears
* any previous contents.
*
* \see toStringList()
*/
void setValues(const StringList &values);
/*!
* Appends \a value to create (or extend) the current list of text values.
*
* \see toString()
*/
void appendValue(const String &value);
/*!
* Appends \a values to extend the current list of text values.
*
* \see toStringList()
*/
void appendValues(const StringList &values);
/*!
* Returns the size of the full item.
*/
int size() const;
/*!
* Returns the value as a single string. In case of multiple strings,
* the first is returned. If the data type is not \a Text, always returns
* an empty String.
*/
String toString() const;
#ifndef DO_NOT_DOCUMENT
/* Remove in next binary incompatible release */
StringList toStringList() const;
#endif
/*!
* Returns the list of text values. If the data type is not \a Text, always
* returns an empty StringList.
*/
StringList values() const;
/*!
* Render the item to a ByteVector.
*/
ByteVector render() const;
/*!
* Parse the item from the ByteVector \a data.
*/
void parse(const ByteVector& data);
/*!
* Set the item to read-only.
*/
void setReadOnly(bool readOnly);
/*!
* Return true if the item is read-only.
*/
bool isReadOnly() const;
/*!
* Sets the type of the item to \a type.
*
* \see ItemTypes
*/
void setType(ItemTypes type);
/*!
* Returns the type of the item.
*/
ItemTypes type() const;
/*!
* Returns if the item has any real content.
*/
bool isEmpty() const;
private:
class ItemPrivate;
ItemPrivate *d;
};
}
}
#endif

View File

@@ -1,252 +0,0 @@
/***************************************************************************
copyright : (C) 2010 by Alex Novichkov
email : novichko@atnet.ru
copyright : (C) 2006 by Lukáš Lalinský
email : lalinsky@gmail.com
(original WavPack implementation)
***************************************************************************/
/***************************************************************************
* This library is free software; you can redistribute it and/or modify *
* it under the terms of the GNU Lesser General Public License version *
* 2.1 as published by the Free Software Foundation. *
* *
* This library 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 *
* Lesser General Public License for more details. *
* *
* You should have received a copy of the GNU Lesser General Public *
* License along with this library; if not, write to the Free Software *
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA *
* 02110-1301 USA *
* *
* Alternatively, this file is available under the Mozilla Public *
* License Version 1.1. You may obtain a copy of the License at *
* http://www.mozilla.org/MPL/ *
***************************************************************************/
#include <tstring.h>
#include <tdebug.h>
#include <bitset>
#include "id3v2tag.h"
#include "apeproperties.h"
#include "apefile.h"
#include "apetag.h"
#include "apefooter.h"
using namespace TagLib;
class APE::Properties::PropertiesPrivate
{
public:
PropertiesPrivate() :
length(0),
bitrate(0),
sampleRate(0),
channels(0),
version(0),
bitsPerSample(0),
sampleFrames(0) {}
int length;
int bitrate;
int sampleRate;
int channels;
int version;
int bitsPerSample;
unsigned int sampleFrames;
};
////////////////////////////////////////////////////////////////////////////////
// public members
////////////////////////////////////////////////////////////////////////////////
APE::Properties::Properties(File *, ReadStyle style) :
AudioProperties(style),
d(new PropertiesPrivate())
{
debug("APE::Properties::Properties() -- This constructor is no longer used.");
}
APE::Properties::Properties(File *file, long streamLength, ReadStyle style) :
AudioProperties(style),
d(new PropertiesPrivate())
{
read(file, streamLength);
}
APE::Properties::~Properties()
{
delete d;
}
int APE::Properties::length() const
{
return lengthInSeconds();
}
int APE::Properties::lengthInSeconds() const
{
return d->length / 1000;
}
int APE::Properties::lengthInMilliseconds() const
{
return d->length;
}
int APE::Properties::bitrate() const
{
return d->bitrate;
}
int APE::Properties::sampleRate() const
{
return d->sampleRate;
}
int APE::Properties::channels() const
{
return d->channels;
}
int APE::Properties::version() const
{
return d->version;
}
int APE::Properties::bitsPerSample() const
{
return d->bitsPerSample;
}
unsigned int APE::Properties::sampleFrames() const
{
return d->sampleFrames;
}
////////////////////////////////////////////////////////////////////////////////
// private members
////////////////////////////////////////////////////////////////////////////////
namespace
{
int headerVersion(const ByteVector &header)
{
if(header.size() < 6 || !header.startsWith("MAC "))
return -1;
return header.toUShort(4, false);
}
}
void APE::Properties::read(File *file, long streamLength)
{
// First, we assume that the file pointer is set at the first descriptor.
long offset = file->tell();
int version = headerVersion(file->readBlock(6));
// Next, we look for the descriptor.
if(version < 0) {
offset = file->find("MAC ", offset);
file->seek(offset);
version = headerVersion(file->readBlock(6));
}
if(version < 0) {
debug("APE::Properties::read() -- APE descriptor not found");
return;
}
d->version = version;
if(d->version >= 3980)
analyzeCurrent(file);
else
analyzeOld(file);
if(d->sampleFrames > 0 && d->sampleRate > 0) {
const double length = d->sampleFrames * 1000.0 / d->sampleRate;
d->length = static_cast<int>(length + 0.5);
d->bitrate = static_cast<int>(streamLength * 8.0 / length + 0.5);
}
}
void APE::Properties::analyzeCurrent(File *file)
{
// Read the descriptor
file->seek(2, File::Current);
const ByteVector descriptor = file->readBlock(44);
if(descriptor.size() < 44) {
debug("APE::Properties::analyzeCurrent() -- descriptor is too short.");
return;
}
const unsigned int descriptorBytes = descriptor.toUInt(0, false);
if((descriptorBytes - 52) > 0)
file->seek(descriptorBytes - 52, File::Current);
// Read the header
const ByteVector header = file->readBlock(24);
if(header.size() < 24) {
debug("APE::Properties::analyzeCurrent() -- MAC header is too short.");
return;
}
// Get the APE info
d->channels = header.toShort(18, false);
d->sampleRate = header.toUInt(20, false);
d->bitsPerSample = header.toShort(16, false);
const unsigned int totalFrames = header.toUInt(12, false);
if(totalFrames == 0)
return;
const unsigned int blocksPerFrame = header.toUInt(4, false);
const unsigned int finalFrameBlocks = header.toUInt(8, false);
d->sampleFrames = (totalFrames - 1) * blocksPerFrame + finalFrameBlocks;
}
void APE::Properties::analyzeOld(File *file)
{
const ByteVector header = file->readBlock(26);
if(header.size() < 26) {
debug("APE::Properties::analyzeOld() -- MAC header is too short.");
return;
}
const unsigned int totalFrames = header.toUInt(18, false);
// Fail on 0 length APE files (catches non-finalized APE files)
if(totalFrames == 0)
return;
const short compressionLevel = header.toShort(0, false);
unsigned int blocksPerFrame;
if(d->version >= 3950)
blocksPerFrame = 73728 * 4;
else if(d->version >= 3900 || (d->version >= 3800 && compressionLevel == 4000))
blocksPerFrame = 73728;
else
blocksPerFrame = 9216;
// Get the APE info
d->channels = header.toShort(4, false);
d->sampleRate = header.toUInt(6, false);
const unsigned int finalFrameBlocks = header.toUInt(22, false);
d->sampleFrames = (totalFrames - 1) * blocksPerFrame + finalFrameBlocks;
// Get the bit depth from the RIFF-fmt chunk.
file->seek(16, File::Current);
const ByteVector fmt = file->readBlock(28);
if(fmt.size() < 28 || !fmt.startsWith("WAVEfmt ")) {
debug("APE::Properties::analyzeOld() -- fmt header is too short.");
return;
}
d->bitsPerSample = fmt.toShort(26, false);
}

View File

@@ -1,143 +0,0 @@
/***************************************************************************
copyright : (C) 2010 by Alex Novichkov
email : novichko@atnet.ru
copyright : (C) 2006 by Lukáš Lalinský
email : lalinsky@gmail.com
(original WavPack implementation)
***************************************************************************/
/***************************************************************************
* This library is free software; you can redistribute it and/or modify *
* it under the terms of the GNU Lesser General Public License version *
* 2.1 as published by the Free Software Foundation. *
* *
* This library 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 *
* Lesser General Public License for more details. *
* *
* You should have received a copy of the GNU Lesser General Public *
* License along with this library; if not, write to the Free Software *
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA *
* 02110-1301 USA *
* *
* Alternatively, this file is available under the Mozilla Public *
* License Version 1.1. You may obtain a copy of the License at *
* http://www.mozilla.org/MPL/ *
***************************************************************************/
#ifndef TAGLIB_APEPROPERTIES_H
#define TAGLIB_APEPROPERTIES_H
#include "taglib_export.h"
#include "audioproperties.h"
namespace TagLib {
namespace APE {
class File;
//! An implementation of audio property reading for APE
/*!
* This reads the data from an APE stream found in the AudioProperties
* API.
*/
class TAGLIB_EXPORT Properties : public AudioProperties
{
public:
/*!
* Create an instance of APE::Properties with the data read from the
* APE::File \a file.
*
* \deprecated
*/
Properties(File *file, ReadStyle style = Average);
/*!
* Create an instance of APE::Properties with the data read from the
* APE::File \a file.
*/
Properties(File *file, long streamLength, ReadStyle style = Average);
/*!
* Destroys this APE::Properties instance.
*/
virtual ~Properties();
/*!
* Returns the length of the file in seconds. The length is rounded down to
* the nearest whole second.
*
* \note This method is just an alias of lengthInSeconds().
*
* \deprecated
*/
virtual int length() const;
/*!
* Returns the length of the file in seconds. The length is rounded down to
* the nearest whole second.
*
* \see lengthInMilliseconds()
*/
// BIC: make virtual
int lengthInSeconds() const;
/*!
* Returns the length of the file in milliseconds.
*
* \see lengthInSeconds()
*/
// BIC: make virtual
int lengthInMilliseconds() const;
/*!
* Returns the average bit rate of the file in kb/s.
*/
virtual int bitrate() const;
/*!
* Returns the sample rate in Hz.
*/
virtual int sampleRate() const;
/*!
* Returns the number of audio channels.
*/
virtual int channels() const;
/*!
* Returns the number of bits per audio sample.
*/
int bitsPerSample() const;
/*!
* Returns the total number of audio samples in file.
*/
unsigned int sampleFrames() const;
/*!
* Returns APE version.
*/
int version() const;
private:
Properties(const Properties &);
Properties &operator=(const Properties &);
void read(File *file, long streamLength);
void analyzeCurrent(File *file);
void analyzeOld(File *file);
class PropertiesPrivate;
PropertiesPrivate *d;
};
}
}
#endif

View File

@@ -1,437 +0,0 @@
/***************************************************************************
copyright : (C) 2004 by Allan Sandfeld Jensen
email : kde@carewolf.com
***************************************************************************/
/***************************************************************************
* This library is free software; you can redistribute it and/or modify *
* it under the terms of the GNU Lesser General Public License version *
* 2.1 as published by the Free Software Foundation. *
* *
* This library 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 *
* Lesser General Public License for more details. *
* *
* You should have received a copy of the GNU Lesser General Public *
* License along with this library; if not, write to the Free Software *
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA *
* 02110-1301 USA *
* *
* Alternatively, this file is available under the Mozilla Public *
* License Version 1.1. You may obtain a copy of the License at *
* http://www.mozilla.org/MPL/ *
***************************************************************************/
#if defined(__SUNPRO_CC) && (__SUNPRO_CC < 0x5130)
// Sun Studio finds multiple specializations of Map because
// it considers specializations with and without class types
// to be different; this define forces Map to use only the
// specialization with the class keyword.
#define WANT_CLASS_INSTANTIATION_OF_MAP (1)
#endif
#include <tfile.h>
#include <tstring.h>
#include <tmap.h>
#include <tpropertymap.h>
#include <tdebug.h>
#include <tutils.h>
#include "apetag.h"
#include "apefooter.h"
#include "apeitem.h"
using namespace TagLib;
using namespace APE;
namespace
{
const unsigned int MinKeyLength = 2;
const unsigned int MaxKeyLength = 255;
bool isKeyValid(const ByteVector &key)
{
const char *invalidKeys[] = { "ID3", "TAG", "OGGS", "MP+", 0 };
// only allow printable ASCII including space (32..126)
for(ByteVector::ConstIterator it = key.begin(); it != key.end(); ++it) {
const int c = static_cast<unsigned char>(*it);
if(c < 32 || c > 126)
return false;
}
const String upperKey = String(key).upper();
for(size_t i = 0; invalidKeys[i] != 0; ++i) {
if(upperKey == invalidKeys[i])
return false;
}
return true;
}
}
class APE::Tag::TagPrivate
{
public:
TagPrivate() :
file(0),
footerLocation(0) {}
File *file;
long footerLocation;
Footer footer;
ItemListMap itemListMap;
};
////////////////////////////////////////////////////////////////////////////////
// public methods
////////////////////////////////////////////////////////////////////////////////
APE::Tag::Tag() :
TagLib::Tag(),
d(new TagPrivate())
{
}
APE::Tag::Tag(TagLib::File *file, long footerLocation) :
TagLib::Tag(),
d(new TagPrivate())
{
d->file = file;
d->footerLocation = footerLocation;
read();
}
APE::Tag::~Tag()
{
delete d;
}
ByteVector APE::Tag::fileIdentifier()
{
return ByteVector::fromCString("APETAGEX");
}
String APE::Tag::title() const
{
if(d->itemListMap["TITLE"].isEmpty())
return String();
return d->itemListMap["TITLE"].values().toString();
}
String APE::Tag::artist() const
{
if(d->itemListMap["ARTIST"].isEmpty())
return String();
return d->itemListMap["ARTIST"].values().toString();
}
String APE::Tag::album() const
{
if(d->itemListMap["ALBUM"].isEmpty())
return String();
return d->itemListMap["ALBUM"].values().toString();
}
String APE::Tag::comment() const
{
if(d->itemListMap["COMMENT"].isEmpty())
return String();
return d->itemListMap["COMMENT"].values().toString();
}
String APE::Tag::genre() const
{
if(d->itemListMap["GENRE"].isEmpty())
return String();
return d->itemListMap["GENRE"].values().toString();
}
unsigned int APE::Tag::year() const
{
if(d->itemListMap["YEAR"].isEmpty())
return 0;
return d->itemListMap["YEAR"].toString().toInt();
}
unsigned int APE::Tag::track() const
{
if(d->itemListMap["TRACK"].isEmpty())
return 0;
return d->itemListMap["TRACK"].toString().toInt();
}
void APE::Tag::setTitle(const String &s)
{
addValue("TITLE", s, true);
}
void APE::Tag::setArtist(const String &s)
{
addValue("ARTIST", s, true);
}
void APE::Tag::setAlbum(const String &s)
{
addValue("ALBUM", s, true);
}
void APE::Tag::setComment(const String &s)
{
addValue("COMMENT", s, true);
}
void APE::Tag::setGenre(const String &s)
{
addValue("GENRE", s, true);
}
void APE::Tag::setYear(unsigned int i)
{
if(i == 0)
removeItem("YEAR");
else
addValue("YEAR", String::number(i), true);
}
void APE::Tag::setTrack(unsigned int i)
{
if(i == 0)
removeItem("TRACK");
else
addValue("TRACK", String::number(i), true);
}
namespace
{
// conversions of tag keys between what we use in PropertyMap and what's usual
// for APE tags
// usual, APE
const char *keyConversions[][2] = {{"TRACKNUMBER", "TRACK" },
{"DATE", "YEAR" },
{"ALBUMARTIST", "ALBUM ARTIST"},
{"DISCNUMBER", "DISC" },
{"REMIXER", "MIXARTIST" }};
const size_t keyConversionsSize = sizeof(keyConversions) / sizeof(keyConversions[0]);
}
PropertyMap APE::Tag::properties() const
{
PropertyMap properties;
ItemListMap::ConstIterator it = itemListMap().begin();
for(; it != itemListMap().end(); ++it) {
String tagName = it->first.upper();
// if the item is Binary or Locator, or if the key is an invalid string,
// add to unsupportedData
if(it->second.type() != Item::Text || tagName.isEmpty()) {
properties.unsupportedData().append(it->first);
}
else {
// Some tags need to be handled specially
for(size_t i = 0; i < keyConversionsSize; ++i) {
if(tagName == keyConversions[i][1])
tagName = keyConversions[i][0];
}
properties[tagName].append(it->second.toStringList());
}
}
return properties;
}
void APE::Tag::removeUnsupportedProperties(const StringList &properties)
{
StringList::ConstIterator it = properties.begin();
for(; it != properties.end(); ++it)
removeItem(*it);
}
PropertyMap APE::Tag::setProperties(const PropertyMap &origProps)
{
PropertyMap properties(origProps); // make a local copy that can be modified
// see comment in properties()
for(size_t i = 0; i < keyConversionsSize; ++i)
if(properties.contains(keyConversions[i][0])) {
properties.insert(keyConversions[i][1], properties[keyConversions[i][0]]);
properties.erase(keyConversions[i][0]);
}
// first check if tags need to be removed completely
StringList toRemove;
ItemListMap::ConstIterator remIt = itemListMap().begin();
for(; remIt != itemListMap().end(); ++remIt) {
String key = remIt->first.upper();
// only remove if a) key is valid, b) type is text, c) key not contained in new properties
if(!key.isEmpty() && remIt->second.type() == APE::Item::Text && !properties.contains(key))
toRemove.append(remIt->first);
}
for(StringList::ConstIterator removeIt = toRemove.begin(); removeIt != toRemove.end(); removeIt++)
removeItem(*removeIt);
// now sync in the "forward direction"
PropertyMap::ConstIterator it = properties.begin();
PropertyMap invalid;
for(; it != properties.end(); ++it) {
const String &tagName = it->first;
if(!checkKey(tagName))
invalid.insert(it->first, it->second);
else if(!(itemListMap().contains(tagName)) || !(itemListMap()[tagName].values() == it->second)) {
if(it->second.isEmpty())
removeItem(tagName);
else {
StringList::ConstIterator valueIt = it->second.begin();
addValue(tagName, *valueIt, true);
++valueIt;
for(; valueIt != it->second.end(); ++valueIt)
addValue(tagName, *valueIt, false);
}
}
}
return invalid;
}
bool APE::Tag::checkKey(const String &key)
{
if(key.size() < MinKeyLength || key.size() > MaxKeyLength)
return false;
return isKeyValid(key.data(String::UTF8));
}
APE::Footer *APE::Tag::footer() const
{
return &d->footer;
}
const APE::ItemListMap& APE::Tag::itemListMap() const
{
return d->itemListMap;
}
void APE::Tag::removeItem(const String &key)
{
d->itemListMap.erase(key.upper());
}
void APE::Tag::addValue(const String &key, const String &value, bool replace)
{
if(replace)
removeItem(key);
if(value.isEmpty())
return;
// Text items may contain more than one value.
// Binary or locator items may have only one value, hence always replaced.
ItemListMap::Iterator it = d->itemListMap.find(key.upper());
if(it != d->itemListMap.end() && it->second.type() == Item::Text)
it->second.appendValue(value);
else
setItem(key, Item(key, value));
}
void APE::Tag::setData(const String &key, const ByteVector &value)
{
removeItem(key);
if(value.isEmpty())
return;
setItem(key, Item(key, value, true));
}
void APE::Tag::setItem(const String &key, const Item &item)
{
if(!checkKey(key)) {
debug("APE::Tag::setItem() - Couldn't set an item due to an invalid key.");
return;
}
d->itemListMap[key.upper()] = item;
}
bool APE::Tag::isEmpty() const
{
return d->itemListMap.isEmpty();
}
////////////////////////////////////////////////////////////////////////////////
// protected methods
////////////////////////////////////////////////////////////////////////////////
void APE::Tag::read()
{
if(d->file && d->file->isValid()) {
d->file->seek(d->footerLocation);
d->footer.setData(d->file->readBlock(Footer::size()));
if(d->footer.tagSize() <= Footer::size() ||
d->footer.tagSize() > static_cast<unsigned long>(d->file->length()))
return;
d->file->seek(d->footerLocation + Footer::size() - d->footer.tagSize());
parse(d->file->readBlock(d->footer.tagSize() - Footer::size()));
}
}
ByteVector APE::Tag::render() const
{
ByteVector data;
unsigned int itemCount = 0;
for(ItemListMap::ConstIterator it = d->itemListMap.begin(); it != d->itemListMap.end(); ++it) {
data.append(it->second.render());
itemCount++;
}
d->footer.setItemCount(itemCount);
d->footer.setTagSize(data.size() + Footer::size());
d->footer.setHeaderPresent(true);
return d->footer.renderHeader() + data + d->footer.renderFooter();
}
void APE::Tag::parse(const ByteVector &data)
{
// 11 bytes is the minimum size for an APE item
if(data.size() < 11)
return;
unsigned int pos = 0;
for(unsigned int i = 0; i < d->footer.itemCount() && pos <= data.size() - 11; i++) {
const int nullPos = data.find('\0', pos + 8);
if(nullPos < 0) {
debug("APE::Tag::parse() - Couldn't find a key/value separator. Stopped parsing.");
return;
}
const unsigned int keyLength = nullPos - pos - 8;
const unsigned int valLegnth = data.toUInt(pos, false);
if(keyLength >= MinKeyLength
&& keyLength <= MaxKeyLength
&& isKeyValid(data.mid(pos + 8, keyLength)))
{
APE::Item item;
item.parse(data.mid(pos));
d->itemListMap.insert(item.key().upper(), item);
}
else {
debug("APE::Tag::parse() - Skipped an item due to an invalid key.");
}
pos += keyLength + valLegnth + 9;
}
}

View File

@@ -1,208 +0,0 @@
/***************************************************************************
copyright : (C) 2004 by Allan Sandfeld Jensen
email : kde@carewolf.org
***************************************************************************/
/***************************************************************************
* This library is free software; you can redistribute it and/or modify *
* it under the terms of the GNU Lesser General Public License version *
* 2.1 as published by the Free Software Foundation. *
* *
* This library 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 *
* Lesser General Public License for more details. *
* *
* You should have received a copy of the GNU Lesser General Public *
* License along with this library; if not, write to the Free Software *
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA *
* 02110-1301 USA *
* *
* Alternatively, this file is available under the Mozilla Public *
* License Version 1.1. You may obtain a copy of the License at *
* http://www.mozilla.org/MPL/ *
***************************************************************************/
#ifndef TAGLIB_APETAG_H
#define TAGLIB_APETAG_H
#include "tag.h"
#include "tbytevector.h"
#include "tmap.h"
#include "tstring.h"
#include "taglib_export.h"
#include "apeitem.h"
namespace TagLib {
class File;
//! An implementation of the APE tagging format
namespace APE {
class Footer;
/*!
* A mapping between a list of item names, or keys, and the associated item.
*
* \see APE::Tag::itemListMap()
*/
typedef Map<const String, Item> ItemListMap;
//! An APE tag implementation
class TAGLIB_EXPORT Tag : public TagLib::Tag
{
public:
/*!
* Create an APE tag with default values.
*/
Tag();
/*!
* Create an APE tag and parse the data in \a file with APE footer at
* \a tagOffset.
*/
Tag(TagLib::File *file, long footerLocation);
/*!
* Destroys this Tag instance.
*/
virtual ~Tag();
/*!
* Renders the in memory values to a ByteVector suitable for writing to
* the file.
*/
ByteVector render() const;
/*!
* Returns the string "APETAGEX" suitable for usage in locating the tag in a
* file.
*/
static ByteVector fileIdentifier();
// Reimplementations.
virtual String title() const;
virtual String artist() const;
virtual String album() const;
virtual String comment() const;
virtual String genre() const;
virtual unsigned int year() const;
virtual unsigned int track() const;
virtual void setTitle(const String &s);
virtual void setArtist(const String &s);
virtual void setAlbum(const String &s);
virtual void setComment(const String &s);
virtual void setGenre(const String &s);
virtual void setYear(unsigned int i);
virtual void setTrack(unsigned int i);
/*!
* Implements the unified tag dictionary interface -- export function.
* APE tags are perfectly compatible with the dictionary interface because they
* support both arbitrary tag names and multiple values. Currently only
* APE items of type *Text* are handled by the dictionary interface; all *Binary*
* and *Locator* items will be put into the unsupportedData list and can be
* deleted on request using removeUnsupportedProperties(). The same happens
* to Text items if their key is invalid for PropertyMap (which should actually
* never happen).
*
* The only conversion done by this export function is to rename the APE tags
* TRACK to TRACKNUMBER, YEAR to DATE, and ALBUM ARTIST to ALBUMARTIST, respectively,
* in order to be compliant with the names used in other formats.
*/
PropertyMap properties() const;
void removeUnsupportedProperties(const StringList &properties);
/*!
* Implements the unified tag dictionary interface -- import function. The same
* comments as for the export function apply; additionally note that the APE tag
* specification requires keys to have between 2 and 16 printable ASCII characters
* with the exception of the fixed strings "ID3", "TAG", "OGGS", and "MP+".
*/
PropertyMap setProperties(const PropertyMap &);
/*!
* Check if the given String is a valid APE tag key.
*/
static bool checkKey(const String&);
/*!
* Returns a pointer to the tag's footer.
*/
Footer *footer() const;
/*!
* Returns a reference to the item list map. This is an ItemListMap of
* all of the items in the tag.
*
* This is the most powerful structure for accessing the items of the tag.
*
* APE tags are case-insensitive, all keys in this map have been converted
* to upper case.
*
* \warning You should not modify this data structure directly, instead
* use setItem() and removeItem().
*/
const ItemListMap &itemListMap() const;
/*!
* Removes the \a key item from the tag
*/
void removeItem(const String &key);
/*!
* Adds to the text item specified by \a key the data \a value. If \a replace
* is true, then all of the other values on the same key will be removed
* first. If a binary item exists for \a key it will be removed first.
*/
void addValue(const String &key, const String &value, bool replace = true);
/*!
* Set the binary data for the key specified by \a item to \a value
* This will convert the item to type \a Binary if it isn't already and
* all of the other values on the same key will be removed.
*/
void setData(const String &key, const ByteVector &value);
/*!
* Sets the \a key item to the value of \a item. If an item with the \a key is already
* present, it will be replaced.
*/
void setItem(const String &key, const Item &item);
/*!
* Returns true if the tag does not contain any data.
*/
bool isEmpty() const;
protected:
/*!
* Reads from the file specified in the constructor.
*/
void read();
/*!
* Parses the body of the tag in \a data.
*/
void parse(const ByteVector &data);
private:
Tag(const Tag &);
Tag &operator=(const Tag &);
class TagPrivate;
TagPrivate *d;
};
}
}
#endif

View File

@@ -1,351 +0,0 @@
/**************************************************************************
copyright : (C) 2005-2007 by Lukáš Lalinský
email : lalinsky@gmail.com
**************************************************************************/
/***************************************************************************
* This library is free software; you can redistribute it and/or modify *
* it under the terms of the GNU Lesser General Public License version *
* 2.1 as published by the Free Software Foundation. *
* *
* This library 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 *
* Lesser General Public License for more details. *
* *
* You should have received a copy of the GNU Lesser General Public *
* License along with this library; if not, write to the Free Software *
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA *
* 02110-1301 USA *
* *
* Alternatively, this file is available under the Mozilla Public *
* License Version 1.1. You may obtain a copy of the License at *
* http://www.mozilla.org/MPL/ *
***************************************************************************/
#include <taglib.h>
#include <tdebug.h>
#include <trefcounter.h>
#include "asfattribute.h"
#include "asffile.h"
#include "asfutils.h"
using namespace TagLib;
class ASF::Attribute::AttributePrivate : public RefCounter
{
public:
AttributePrivate() :
pictureValue(ASF::Picture::fromInvalid()),
numericValue(0),
stream(0),
language(0) {}
AttributeTypes type;
String stringValue;
ByteVector byteVectorValue;
ASF::Picture pictureValue;
unsigned long long numericValue;
int stream;
int language;
};
////////////////////////////////////////////////////////////////////////////////
// public members
////////////////////////////////////////////////////////////////////////////////
ASF::Attribute::Attribute() :
d(new AttributePrivate())
{
d->type = UnicodeType;
}
ASF::Attribute::Attribute(const ASF::Attribute &other) :
d(other.d)
{
d->ref();
}
ASF::Attribute::Attribute(const String &value) :
d(new AttributePrivate())
{
d->type = UnicodeType;
d->stringValue = value;
}
ASF::Attribute::Attribute(const ByteVector &value) :
d(new AttributePrivate())
{
d->type = BytesType;
d->byteVectorValue = value;
}
ASF::Attribute::Attribute(const ASF::Picture &value) :
d(new AttributePrivate())
{
d->type = BytesType;
d->pictureValue = value;
}
ASF::Attribute::Attribute(unsigned int value) :
d(new AttributePrivate())
{
d->type = DWordType;
d->numericValue = value;
}
ASF::Attribute::Attribute(unsigned long long value) :
d(new AttributePrivate())
{
d->type = QWordType;
d->numericValue = value;
}
ASF::Attribute::Attribute(unsigned short value) :
d(new AttributePrivate())
{
d->type = WordType;
d->numericValue = value;
}
ASF::Attribute::Attribute(bool value) :
d(new AttributePrivate())
{
d->type = BoolType;
d->numericValue = value;
}
ASF::Attribute &ASF::Attribute::operator=(const ASF::Attribute &other)
{
Attribute(other).swap(*this);
return *this;
}
void ASF::Attribute::swap(Attribute &other)
{
using std::swap;
swap(d, other.d);
}
ASF::Attribute::~Attribute()
{
if(d->deref())
delete d;
}
ASF::Attribute::AttributeTypes ASF::Attribute::type() const
{
return d->type;
}
String ASF::Attribute::toString() const
{
return d->stringValue;
}
ByteVector ASF::Attribute::toByteVector() const
{
if(d->pictureValue.isValid())
return d->pictureValue.render();
return d->byteVectorValue;
}
unsigned short ASF::Attribute::toBool() const
{
return d->numericValue ? 1 : 0;
}
unsigned short ASF::Attribute::toUShort() const
{
return static_cast<unsigned short>(d->numericValue);
}
unsigned int ASF::Attribute::toUInt() const
{
return static_cast<unsigned int>(d->numericValue);
}
unsigned long long ASF::Attribute::toULongLong() const
{
return static_cast<unsigned long long>(d->numericValue);
}
ASF::Picture ASF::Attribute::toPicture() const
{
return d->pictureValue;
}
String ASF::Attribute::parse(ASF::File &f, int kind)
{
unsigned int size, nameLength;
String name;
d->pictureValue = Picture::fromInvalid();
// extended content descriptor
if(kind == 0) {
nameLength = readWORD(&f);
name = readString(&f, nameLength);
d->type = ASF::Attribute::AttributeTypes(readWORD(&f));
size = readWORD(&f);
}
// metadata & metadata library
else {
int temp = readWORD(&f);
// metadata library
if(kind == 2) {
d->language = temp;
}
d->stream = readWORD(&f);
nameLength = readWORD(&f);
d->type = ASF::Attribute::AttributeTypes(readWORD(&f));
size = readDWORD(&f);
name = readString(&f, nameLength);
}
if(kind != 2 && size > 65535) {
debug("ASF::Attribute::parse() -- Value larger than 64kB");
}
switch(d->type) {
case WordType:
d->numericValue = readWORD(&f);
break;
case BoolType:
if(kind == 0) {
d->numericValue = (readDWORD(&f) != 0);
}
else {
d->numericValue = (readWORD(&f) != 0);
}
break;
case DWordType:
d->numericValue = readDWORD(&f);
break;
case QWordType:
d->numericValue = readQWORD(&f);
break;
case UnicodeType:
d->stringValue = readString(&f, size);
break;
case BytesType:
case GuidType:
d->byteVectorValue = f.readBlock(size);
break;
}
if(d->type == BytesType && name == "WM/Picture") {
d->pictureValue.parse(d->byteVectorValue);
if(d->pictureValue.isValid()) {
d->byteVectorValue.clear();
}
}
return name;
}
int ASF::Attribute::dataSize() const
{
switch (d->type) {
case WordType:
return 2;
case BoolType:
return 4;
case DWordType:
return 4;
case QWordType:
return 5;
case UnicodeType:
return d->stringValue.size() * 2 + 2;
case BytesType:
if(d->pictureValue.isValid())
return d->pictureValue.dataSize();
case GuidType:
return d->byteVectorValue.size();
}
return 0;
}
ByteVector ASF::Attribute::render(const String &name, int kind) const
{
ByteVector data;
switch (d->type) {
case WordType:
data.append(ByteVector::fromShort(toUShort(), false));
break;
case BoolType:
if(kind == 0) {
data.append(ByteVector::fromUInt(toBool(), false));
}
else {
data.append(ByteVector::fromShort(toBool(), false));
}
break;
case DWordType:
data.append(ByteVector::fromUInt(toUInt(), false));
break;
case QWordType:
data.append(ByteVector::fromLongLong(toULongLong(), false));
break;
case UnicodeType:
data.append(renderString(d->stringValue));
break;
case BytesType:
if(d->pictureValue.isValid()) {
data.append(d->pictureValue.render());
break;
}
case GuidType:
data.append(d->byteVectorValue);
break;
}
if(kind == 0) {
data = renderString(name, true) +
ByteVector::fromShort((int)d->type, false) +
ByteVector::fromShort(data.size(), false) +
data;
}
else {
ByteVector nameData = renderString(name);
data = ByteVector::fromShort(kind == 2 ? d->language : 0, false) +
ByteVector::fromShort(d->stream, false) +
ByteVector::fromShort(nameData.size(), false) +
ByteVector::fromShort((int)d->type, false) +
ByteVector::fromUInt(data.size(), false) +
nameData +
data;
}
return data;
}
int ASF::Attribute::language() const
{
return d->language;
}
void ASF::Attribute::setLanguage(int value)
{
d->language = value;
}
int ASF::Attribute::stream() const
{
return d->stream;
}
void ASF::Attribute::setStream(int value)
{
d->stream = value;
}

View File

@@ -1,208 +0,0 @@
/**************************************************************************
copyright : (C) 2005-2007 by Lukáš Lalinský
email : lalinsky@gmail.com
**************************************************************************/
/***************************************************************************
* This library is free software; you can redistribute it and/or modify *
* it under the terms of the GNU Lesser General Public License version *
* 2.1 as published by the Free Software Foundation. *
* *
* This library 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 *
* Lesser General Public License for more details. *
* *
* You should have received a copy of the GNU Lesser General Public *
* License along with this library; if not, write to the Free Software *
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA *
* 02110-1301 USA *
* *
* Alternatively, this file is available under the Mozilla Public *
* License Version 1.1. You may obtain a copy of the License at *
* http://www.mozilla.org/MPL/ *
***************************************************************************/
#ifndef TAGLIB_ASFATTRIBUTE_H
#define TAGLIB_ASFATTRIBUTE_H
#include "tstring.h"
#include "tbytevector.h"
#include "taglib_export.h"
#include "asfpicture.h"
namespace TagLib
{
namespace ASF
{
class File;
class Picture;
class TAGLIB_EXPORT Attribute
{
public:
/*!
* Enum of types an Attribute can have.
*/
enum AttributeTypes {
UnicodeType = 0,
BytesType = 1,
BoolType = 2,
DWordType = 3,
QWordType = 4,
WordType = 5,
GuidType = 6
};
/*!
* Constructs an empty attribute.
*/
Attribute();
/*!
* Constructs an attribute with \a key and a UnicodeType \a value.
*/
Attribute(const String &value);
/*!
* Constructs an attribute with \a key and a BytesType \a value.
*/
Attribute(const ByteVector &value);
/*!
* Constructs an attribute with \a key and a Picture \a value.
*
* This attribute is compatible with the ID3 frame, APIC. The ID3 specification for the APIC frame stipulates that,
* while there may be any number of APIC frames associated with a file,
* only one may be of type 1 and only one may be of type 2.
*
* The specification also states that the description of the picture can be no longer than 64 characters, but can be empty.
* WM/Picture attributes added with TagLib::ASF are not automatically validated to conform to ID3 specifications.
* You must add code in your application to perform validations if you want to maintain complete compatibility with ID3.
*/
Attribute(const Picture &value);
/*!
* Constructs an attribute with \a key and a DWordType \a value.
*/
Attribute(unsigned int value);
/*!
* Constructs an attribute with \a key and a QWordType \a value.
*/
Attribute(unsigned long long value);
/*!
* Constructs an attribute with \a key and a WordType \a value.
*/
Attribute(unsigned short value);
/*!
* Constructs an attribute with \a key and a BoolType \a value.
*/
Attribute(bool value);
/*!
* Construct an attribute as a copy of \a other.
*/
Attribute(const Attribute &item);
/*!
* Copies the contents of \a other into this item.
*/
Attribute &operator=(const Attribute &other);
/*!
* Exchanges the content of the Attribute by the content of \a other.
*/
void swap(Attribute &other);
/*!
* Destroys the attribute.
*/
virtual ~Attribute();
/*!
* Returns type of the value.
*/
AttributeTypes type() const;
/*!
* Returns the BoolType \a value.
*/
unsigned short toBool() const;
/*!
* Returns the WordType \a value.
*/
unsigned short toUShort() const;
/*!
* Returns the DWordType \a value.
*/
unsigned int toUInt() const;
/*!
* Returns the QWordType \a value.
*/
unsigned long long toULongLong() const;
/*!
* Returns the UnicodeType \a value.
*/
String toString() const;
/*!
* Returns the BytesType \a value.
*/
ByteVector toByteVector() const;
/*!
* Returns the Picture \a value.
*/
Picture toPicture() const;
/*!
* Returns the language number, or 0 is no stream number was set.
*/
int language() const;
/*!
* Sets the language number.
*/
void setLanguage(int value);
/*!
* Returns the stream number, or 0 is no stream number was set.
*/
int stream() const;
/*!
* Sets the stream number.
*/
void setStream(int value);
#ifndef DO_NOT_DOCUMENT
/* THIS IS PRIVATE, DON'T TOUCH IT! */
String parse(ASF::File &file, int kind = 0);
#endif
//! Returns the size of the stored data
int dataSize() const;
private:
friend class File;
ByteVector render(const String &name, int kind = 0) const;
class AttributePrivate;
AttributePrivate *d;
};
}
}
#endif

View File

@@ -1,705 +0,0 @@
/**************************************************************************
copyright : (C) 2005-2007 by Lukáš Lalinský
email : lalinsky@gmail.com
**************************************************************************/
/***************************************************************************
* This library is free software; you can redistribute it and/or modify *
* it under the terms of the GNU Lesser General Public License version *
* 2.1 as published by the Free Software Foundation. *
* *
* This library 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 *
* Lesser General Public License for more details. *
* *
* You should have received a copy of the GNU Lesser General Public *
* License along with this library; if not, write to the Free Software *
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA *
* 02110-1301 USA *
* *
* Alternatively, this file is available under the Mozilla Public *
* License Version 1.1. You may obtain a copy of the License at *
* http://www.mozilla.org/MPL/ *
***************************************************************************/
#include <tdebug.h>
#include <tbytevectorlist.h>
#include <tpropertymap.h>
#include <tstring.h>
#include <tagutils.h>
#include "asffile.h"
#include "asftag.h"
#include "asfproperties.h"
#include "asfutils.h"
using namespace TagLib;
class ASF::File::FilePrivate
{
public:
class BaseObject;
class UnknownObject;
class FilePropertiesObject;
class StreamPropertiesObject;
class ContentDescriptionObject;
class ExtendedContentDescriptionObject;
class HeaderExtensionObject;
class CodecListObject;
class MetadataObject;
class MetadataLibraryObject;
FilePrivate():
headerSize(0),
tag(0),
properties(0),
contentDescriptionObject(0),
extendedContentDescriptionObject(0),
headerExtensionObject(0),
metadataObject(0),
metadataLibraryObject(0)
{
objects.setAutoDelete(true);
}
~FilePrivate()
{
delete tag;
delete properties;
}
unsigned long long headerSize;
ASF::Tag *tag;
ASF::Properties *properties;
List<BaseObject *> objects;
ContentDescriptionObject *contentDescriptionObject;
ExtendedContentDescriptionObject *extendedContentDescriptionObject;
HeaderExtensionObject *headerExtensionObject;
MetadataObject *metadataObject;
MetadataLibraryObject *metadataLibraryObject;
};
namespace
{
const ByteVector headerGuid("\x30\x26\xB2\x75\x8E\x66\xCF\x11\xA6\xD9\x00\xAA\x00\x62\xCE\x6C", 16);
const ByteVector filePropertiesGuid("\xA1\xDC\xAB\x8C\x47\xA9\xCF\x11\x8E\xE4\x00\xC0\x0C\x20\x53\x65", 16);
const ByteVector streamPropertiesGuid("\x91\x07\xDC\xB7\xB7\xA9\xCF\x11\x8E\xE6\x00\xC0\x0C\x20\x53\x65", 16);
const ByteVector contentDescriptionGuid("\x33\x26\xB2\x75\x8E\x66\xCF\x11\xA6\xD9\x00\xAA\x00\x62\xCE\x6C", 16);
const ByteVector extendedContentDescriptionGuid("\x40\xA4\xD0\xD2\x07\xE3\xD2\x11\x97\xF0\x00\xA0\xC9\x5E\xA8\x50", 16);
const ByteVector headerExtensionGuid("\xb5\x03\xbf_.\xa9\xcf\x11\x8e\xe3\x00\xc0\x0c Se", 16);
const ByteVector metadataGuid("\xEA\xCB\xF8\xC5\xAF[wH\204g\xAA\214D\xFAL\xCA", 16);
const ByteVector metadataLibraryGuid("\224\034#D\230\224\321I\241A\x1d\x13NEpT", 16);
const ByteVector codecListGuid("\x40\x52\xd1\x86\x1d\x31\xd0\x11\xa3\xa4\x00\xa0\xc9\x03\x48\xf6", 16);
const ByteVector contentEncryptionGuid("\xFB\xB3\x11\x22\x23\xBD\xD2\x11\xB4\xB7\x00\xA0\xC9\x55\xFC\x6E", 16);
const ByteVector extendedContentEncryptionGuid("\x14\xE6\x8A\x29\x22\x26 \x17\x4C\xB9\x35\xDA\xE0\x7E\xE9\x28\x9C", 16);
const ByteVector advancedContentEncryptionGuid("\xB6\x9B\x07\x7A\xA4\xDA\x12\x4E\xA5\xCA\x91\xD3\x8D\xC1\x1A\x8D", 16);
}
class ASF::File::FilePrivate::BaseObject
{
public:
ByteVector data;
virtual ~BaseObject() {}
virtual ByteVector guid() const = 0;
virtual void parse(ASF::File *file, unsigned int size);
virtual ByteVector render(ASF::File *file);
};
class ASF::File::FilePrivate::UnknownObject : public ASF::File::FilePrivate::BaseObject
{
ByteVector myGuid;
public:
UnknownObject(const ByteVector &guid);
ByteVector guid() const;
};
class ASF::File::FilePrivate::FilePropertiesObject : public ASF::File::FilePrivate::BaseObject
{
public:
ByteVector guid() const;
void parse(ASF::File *file, unsigned int size);
};
class ASF::File::FilePrivate::StreamPropertiesObject : public ASF::File::FilePrivate::BaseObject
{
public:
ByteVector guid() const;
void parse(ASF::File *file, unsigned int size);
};
class ASF::File::FilePrivate::ContentDescriptionObject : public ASF::File::FilePrivate::BaseObject
{
public:
ByteVector guid() const;
void parse(ASF::File *file, unsigned int size);
ByteVector render(ASF::File *file);
};
class ASF::File::FilePrivate::ExtendedContentDescriptionObject : public ASF::File::FilePrivate::BaseObject
{
public:
ByteVectorList attributeData;
ByteVector guid() const;
void parse(ASF::File *file, unsigned int size);
ByteVector render(ASF::File *file);
};
class ASF::File::FilePrivate::MetadataObject : public ASF::File::FilePrivate::BaseObject
{
public:
ByteVectorList attributeData;
ByteVector guid() const;
void parse(ASF::File *file, unsigned int size);
ByteVector render(ASF::File *file);
};
class ASF::File::FilePrivate::MetadataLibraryObject : public ASF::File::FilePrivate::BaseObject
{
public:
ByteVectorList attributeData;
ByteVector guid() const;
void parse(ASF::File *file, unsigned int size);
ByteVector render(ASF::File *file);
};
class ASF::File::FilePrivate::HeaderExtensionObject : public ASF::File::FilePrivate::BaseObject
{
public:
List<ASF::File::FilePrivate::BaseObject *> objects;
HeaderExtensionObject();
ByteVector guid() const;
void parse(ASF::File *file, unsigned int size);
ByteVector render(ASF::File *file);
};
class ASF::File::FilePrivate::CodecListObject : public ASF::File::FilePrivate::BaseObject
{
public:
ByteVector guid() const;
void parse(ASF::File *file, unsigned int size);
private:
enum CodecType
{
Video = 0x0001,
Audio = 0x0002,
Unknown = 0xFFFF
};
};
void ASF::File::FilePrivate::BaseObject::parse(ASF::File *file, unsigned int size)
{
data.clear();
if(size > 24 && size <= (unsigned int)(file->length()))
data = file->readBlock(size - 24);
else
data = ByteVector();
}
ByteVector ASF::File::FilePrivate::BaseObject::render(ASF::File * /*file*/)
{
return guid() + ByteVector::fromLongLong(data.size() + 24, false) + data;
}
ASF::File::FilePrivate::UnknownObject::UnknownObject(const ByteVector &guid) : myGuid(guid)
{
}
ByteVector ASF::File::FilePrivate::UnknownObject::guid() const
{
return myGuid;
}
ByteVector ASF::File::FilePrivate::FilePropertiesObject::guid() const
{
return filePropertiesGuid;
}
void ASF::File::FilePrivate::FilePropertiesObject::parse(ASF::File *file, unsigned int size)
{
BaseObject::parse(file, size);
if(data.size() < 64) {
debug("ASF::File::FilePrivate::FilePropertiesObject::parse() -- data is too short.");
return;
}
const long long duration = data.toLongLong(40, false);
const long long preroll = data.toLongLong(56, false);
file->d->properties->setLengthInMilliseconds(static_cast<int>(duration / 10000.0 - preroll + 0.5));
}
ByteVector ASF::File::FilePrivate::StreamPropertiesObject::guid() const
{
return streamPropertiesGuid;
}
void ASF::File::FilePrivate::StreamPropertiesObject::parse(ASF::File *file, unsigned int size)
{
BaseObject::parse(file, size);
if(data.size() < 70) {
debug("ASF::File::FilePrivate::StreamPropertiesObject::parse() -- data is too short.");
return;
}
file->d->properties->setCodec(data.toUShort(54, false));
file->d->properties->setChannels(data.toUShort(56, false));
file->d->properties->setSampleRate(data.toUInt(58, false));
file->d->properties->setBitrate(static_cast<int>(data.toUInt(62, false) * 8.0 / 1000.0 + 0.5));
file->d->properties->setBitsPerSample(data.toUShort(68, false));
}
ByteVector ASF::File::FilePrivate::ContentDescriptionObject::guid() const
{
return contentDescriptionGuid;
}
void ASF::File::FilePrivate::ContentDescriptionObject::parse(ASF::File *file, unsigned int /*size*/)
{
const int titleLength = readWORD(file);
const int artistLength = readWORD(file);
const int copyrightLength = readWORD(file);
const int commentLength = readWORD(file);
const int ratingLength = readWORD(file);
file->d->tag->setTitle(readString(file,titleLength));
file->d->tag->setArtist(readString(file,artistLength));
file->d->tag->setCopyright(readString(file,copyrightLength));
file->d->tag->setComment(readString(file,commentLength));
file->d->tag->setRating(readString(file,ratingLength));
}
ByteVector ASF::File::FilePrivate::ContentDescriptionObject::render(ASF::File *file)
{
const ByteVector v1 = renderString(file->d->tag->title());
const ByteVector v2 = renderString(file->d->tag->artist());
const ByteVector v3 = renderString(file->d->tag->copyright());
const ByteVector v4 = renderString(file->d->tag->comment());
const ByteVector v5 = renderString(file->d->tag->rating());
data.clear();
data.append(ByteVector::fromShort(v1.size(), false));
data.append(ByteVector::fromShort(v2.size(), false));
data.append(ByteVector::fromShort(v3.size(), false));
data.append(ByteVector::fromShort(v4.size(), false));
data.append(ByteVector::fromShort(v5.size(), false));
data.append(v1);
data.append(v2);
data.append(v3);
data.append(v4);
data.append(v5);
return BaseObject::render(file);
}
ByteVector ASF::File::FilePrivate::ExtendedContentDescriptionObject::guid() const
{
return extendedContentDescriptionGuid;
}
void ASF::File::FilePrivate::ExtendedContentDescriptionObject::parse(ASF::File *file, unsigned int /*size*/)
{
int count = readWORD(file);
while(count--) {
ASF::Attribute attribute;
String name = attribute.parse(*file);
file->d->tag->addAttribute(name, attribute);
}
}
ByteVector ASF::File::FilePrivate::ExtendedContentDescriptionObject::render(ASF::File *file)
{
data.clear();
data.append(ByteVector::fromShort(attributeData.size(), false));
data.append(attributeData.toByteVector(""));
return BaseObject::render(file);
}
ByteVector ASF::File::FilePrivate::MetadataObject::guid() const
{
return metadataGuid;
}
void ASF::File::FilePrivate::MetadataObject::parse(ASF::File *file, unsigned int /*size*/)
{
int count = readWORD(file);
while(count--) {
ASF::Attribute attribute;
String name = attribute.parse(*file, 1);
file->d->tag->addAttribute(name, attribute);
}
}
ByteVector ASF::File::FilePrivate::MetadataObject::render(ASF::File *file)
{
data.clear();
data.append(ByteVector::fromShort(attributeData.size(), false));
data.append(attributeData.toByteVector(""));
return BaseObject::render(file);
}
ByteVector ASF::File::FilePrivate::MetadataLibraryObject::guid() const
{
return metadataLibraryGuid;
}
void ASF::File::FilePrivate::MetadataLibraryObject::parse(ASF::File *file, unsigned int /*size*/)
{
int count = readWORD(file);
while(count--) {
ASF::Attribute attribute;
String name = attribute.parse(*file, 2);
file->d->tag->addAttribute(name, attribute);
}
}
ByteVector ASF::File::FilePrivate::MetadataLibraryObject::render(ASF::File *file)
{
data.clear();
data.append(ByteVector::fromShort(attributeData.size(), false));
data.append(attributeData.toByteVector(""));
return BaseObject::render(file);
}
ASF::File::FilePrivate::HeaderExtensionObject::HeaderExtensionObject()
{
objects.setAutoDelete(true);
}
ByteVector ASF::File::FilePrivate::HeaderExtensionObject::guid() const
{
return headerExtensionGuid;
}
void ASF::File::FilePrivate::HeaderExtensionObject::parse(ASF::File *file, unsigned int /*size*/)
{
file->seek(18, File::Current);
long long dataSize = readDWORD(file);
long long dataPos = 0;
while(dataPos < dataSize) {
ByteVector guid = file->readBlock(16);
if(guid.size() != 16) {
file->setValid(false);
break;
}
bool ok;
long long size = readQWORD(file, &ok);
if(!ok) {
file->setValid(false);
break;
}
BaseObject *obj;
if(guid == metadataGuid) {
file->d->metadataObject = new MetadataObject();
obj = file->d->metadataObject;
}
else if(guid == metadataLibraryGuid) {
file->d->metadataLibraryObject = new MetadataLibraryObject();
obj = file->d->metadataLibraryObject;
}
else {
obj = new UnknownObject(guid);
}
obj->parse(file, (unsigned int)size);
objects.append(obj);
dataPos += size;
}
}
ByteVector ASF::File::FilePrivate::HeaderExtensionObject::render(ASF::File *file)
{
data.clear();
for(List<BaseObject *>::ConstIterator it = objects.begin(); it != objects.end(); ++it) {
data.append((*it)->render(file));
}
data = ByteVector("\x11\xD2\xD3\xAB\xBA\xA9\xcf\x11\x8E\xE6\x00\xC0\x0C\x20\x53\x65\x06\x00", 18) + ByteVector::fromUInt(data.size(), false) + data;
return BaseObject::render(file);
}
ByteVector ASF::File::FilePrivate::CodecListObject::guid() const
{
return codecListGuid;
}
void ASF::File::FilePrivate::CodecListObject::parse(ASF::File *file, unsigned int size)
{
BaseObject::parse(file, size);
if(data.size() <= 20) {
debug("ASF::File::FilePrivate::CodecListObject::parse() -- data is too short.");
return;
}
unsigned int pos = 16;
const int count = data.toUInt(pos, false);
pos += 4;
for(int i = 0; i < count; ++i) {
if(pos >= data.size())
break;
const CodecType type = static_cast<CodecType>(data.toUShort(pos, false));
pos += 2;
int nameLength = data.toUShort(pos, false);
pos += 2;
const unsigned int namePos = pos;
pos += nameLength * 2;
const int descLength = data.toUShort(pos, false);
pos += 2;
const unsigned int descPos = pos;
pos += descLength * 2;
const int infoLength = data.toUShort(pos, false);
pos += 2 + infoLength * 2;
if(type == CodecListObject::Audio) {
// First audio codec found.
const String name(data.mid(namePos, nameLength * 2), String::UTF16LE);
file->d->properties->setCodecName(name.stripWhiteSpace());
const String desc(data.mid(descPos, descLength * 2), String::UTF16LE);
file->d->properties->setCodecDescription(desc.stripWhiteSpace());
break;
}
}
}
////////////////////////////////////////////////////////////////////////////////
// static members
////////////////////////////////////////////////////////////////////////////////
bool ASF::File::isSupported(IOStream *stream)
{
// An ASF file has to start with the designated GUID.
const ByteVector id = Utils::readHeader(stream, 16, false);
return (id == headerGuid);
}
////////////////////////////////////////////////////////////////////////////////
// public members
////////////////////////////////////////////////////////////////////////////////
ASF::File::File(FileName file, bool, Properties::ReadStyle) :
TagLib::File(file),
d(new FilePrivate())
{
if(isOpen())
read();
}
ASF::File::File(IOStream *stream, bool, Properties::ReadStyle) :
TagLib::File(stream),
d(new FilePrivate())
{
if(isOpen())
read();
}
ASF::File::~File()
{
delete d;
}
ASF::Tag *ASF::File::tag() const
{
return d->tag;
}
PropertyMap ASF::File::properties() const
{
return d->tag->properties();
}
void ASF::File::removeUnsupportedProperties(const StringList &properties)
{
d->tag->removeUnsupportedProperties(properties);
}
PropertyMap ASF::File::setProperties(const PropertyMap &properties)
{
return d->tag->setProperties(properties);
}
ASF::Properties *ASF::File::audioProperties() const
{
return d->properties;
}
bool ASF::File::save()
{
if(readOnly()) {
debug("ASF::File::save() -- File is read only.");
return false;
}
if(!isValid()) {
debug("ASF::File::save() -- Trying to save invalid file.");
return false;
}
if(!d->contentDescriptionObject) {
d->contentDescriptionObject = new FilePrivate::ContentDescriptionObject();
d->objects.append(d->contentDescriptionObject);
}
if(!d->extendedContentDescriptionObject) {
d->extendedContentDescriptionObject = new FilePrivate::ExtendedContentDescriptionObject();
d->objects.append(d->extendedContentDescriptionObject);
}
if(!d->headerExtensionObject) {
d->headerExtensionObject = new FilePrivate::HeaderExtensionObject();
d->objects.append(d->headerExtensionObject);
}
if(!d->metadataObject) {
d->metadataObject = new FilePrivate::MetadataObject();
d->headerExtensionObject->objects.append(d->metadataObject);
}
if(!d->metadataLibraryObject) {
d->metadataLibraryObject = new FilePrivate::MetadataLibraryObject();
d->headerExtensionObject->objects.append(d->metadataLibraryObject);
}
d->extendedContentDescriptionObject->attributeData.clear();
d->metadataObject->attributeData.clear();
d->metadataLibraryObject->attributeData.clear();
const AttributeListMap allAttributes = d->tag->attributeListMap();
for(AttributeListMap::ConstIterator it = allAttributes.begin(); it != allAttributes.end(); ++it) {
const String &name = it->first;
const AttributeList &attributes = it->second;
bool inExtendedContentDescriptionObject = false;
bool inMetadataObject = false;
for(AttributeList::ConstIterator jt = attributes.begin(); jt != attributes.end(); ++jt) {
const Attribute &attribute = *jt;
const bool largeValue = (attribute.dataSize() > 65535);
const bool guid = (attribute.type() == Attribute::GuidType);
if(!inExtendedContentDescriptionObject && !guid && !largeValue && attribute.language() == 0 && attribute.stream() == 0) {
d->extendedContentDescriptionObject->attributeData.append(attribute.render(name));
inExtendedContentDescriptionObject = true;
}
else if(!inMetadataObject && !guid && !largeValue && attribute.language() == 0 && attribute.stream() != 0) {
d->metadataObject->attributeData.append(attribute.render(name, 1));
inMetadataObject = true;
}
else {
d->metadataLibraryObject->attributeData.append(attribute.render(name, 2));
}
}
}
ByteVector data;
for(List<FilePrivate::BaseObject *>::ConstIterator it = d->objects.begin(); it != d->objects.end(); ++it) {
data.append((*it)->render(this));
}
seek(16);
writeBlock(ByteVector::fromLongLong(data.size() + 30, false));
writeBlock(ByteVector::fromUInt(d->objects.size(), false));
writeBlock(ByteVector("\x01\x02", 2));
insert(data, 30, static_cast<unsigned long>(d->headerSize - 30));
d->headerSize = data.size() + 30;
return true;
}
////////////////////////////////////////////////////////////////////////////////
// private members
////////////////////////////////////////////////////////////////////////////////
void ASF::File::read()
{
if(!isValid())
return;
if(readBlock(16) != headerGuid) {
debug("ASF::File::read(): Not an ASF file.");
setValid(false);
return;
}
d->tag = new ASF::Tag();
d->properties = new ASF::Properties();
bool ok;
d->headerSize = readQWORD(this, &ok);
if(!ok) {
setValid(false);
return;
}
int numObjects = readDWORD(this, &ok);
if(!ok) {
setValid(false);
return;
}
seek(2, Current);
FilePrivate::FilePropertiesObject *filePropertiesObject = 0;
FilePrivate::StreamPropertiesObject *streamPropertiesObject = 0;
for(int i = 0; i < numObjects; i++) {
const ByteVector guid = readBlock(16);
if(guid.size() != 16) {
setValid(false);
break;
}
long size = (long)readQWORD(this, &ok);
if(!ok) {
setValid(false);
break;
}
FilePrivate::BaseObject *obj;
if(guid == filePropertiesGuid) {
filePropertiesObject = new FilePrivate::FilePropertiesObject();
obj = filePropertiesObject;
}
else if(guid == streamPropertiesGuid) {
streamPropertiesObject = new FilePrivate::StreamPropertiesObject();
obj = streamPropertiesObject;
}
else if(guid == contentDescriptionGuid) {
d->contentDescriptionObject = new FilePrivate::ContentDescriptionObject();
obj = d->contentDescriptionObject;
}
else if(guid == extendedContentDescriptionGuid) {
d->extendedContentDescriptionObject = new FilePrivate::ExtendedContentDescriptionObject();
obj = d->extendedContentDescriptionObject;
}
else if(guid == headerExtensionGuid) {
d->headerExtensionObject = new FilePrivate::HeaderExtensionObject();
obj = d->headerExtensionObject;
}
else if(guid == codecListGuid) {
obj = new FilePrivate::CodecListObject();
}
else {
if(guid == contentEncryptionGuid ||
guid == extendedContentEncryptionGuid ||
guid == advancedContentEncryptionGuid) {
d->properties->setEncrypted(true);
}
obj = new FilePrivate::UnknownObject(guid);
}
obj->parse(this, size);
d->objects.append(obj);
}
if(!filePropertiesObject || !streamPropertiesObject) {
debug("ASF::File::read(): Missing mandatory header objects.");
setValid(false);
return;
}
}

View File

@@ -1,138 +0,0 @@
/**************************************************************************
copyright : (C) 2005-2007 by Lukáš Lalinský
email : lalinsky@gmail.com
**************************************************************************/
/***************************************************************************
* This library is free software; you can redistribute it and/or modify *
* it under the terms of the GNU Lesser General Public License version *
* 2.1 as published by the Free Software Foundation. *
* *
* This library 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 *
* Lesser General Public License for more details. *
* *
* You should have received a copy of the GNU Lesser General Public *
* License along with this library; if not, write to the Free Software *
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA *
* 02110-1301 USA *
* *
* Alternatively, this file is available under the Mozilla Public *
* License Version 1.1. You may obtain a copy of the License at *
* http://www.mozilla.org/MPL/ *
***************************************************************************/
#ifndef TAGLIB_ASFFILE_H
#define TAGLIB_ASFFILE_H
#include "tag.h"
#include "tfile.h"
#include "taglib_export.h"
#include "asfproperties.h"
#include "asftag.h"
namespace TagLib {
//! An implementation of ASF (WMA) metadata
namespace ASF {
/*!
* This implements and provides an interface for ASF files to the
* TagLib::Tag and TagLib::AudioProperties interfaces by way of implementing
* the abstract TagLib::File API as well as providing some additional
* information specific to ASF files.
*/
class TAGLIB_EXPORT File : public TagLib::File
{
public:
/*!
* Constructs an ASF file from \a file.
*
* \note In the current implementation, both \a readProperties and
* \a propertiesStyle are ignored. The audio properties are always
* read.
*/
File(FileName file, bool readProperties = true,
Properties::ReadStyle propertiesStyle = Properties::Average);
/*!
* Constructs an ASF file from \a stream.
*
* \note In the current implementation, both \a readProperties and
* \a propertiesStyle are ignored. The audio properties are always
* read.
*
* \note TagLib will *not* take ownership of the stream, the caller is
* responsible for deleting it after the File object.
*/
File(IOStream *stream, bool readProperties = true,
Properties::ReadStyle propertiesStyle = Properties::Average);
/*!
* Destroys this instance of the File.
*/
virtual ~File();
/*!
* Returns a pointer to the ASF tag of the file.
*
* ASF::Tag implements the tag interface, so this serves as the
* reimplementation of TagLib::File::tag().
*
* \note The Tag <b>is still</b> owned by the ASF::File and should not be
* deleted by the user. It will be deleted when the file (object) is
* destroyed.
*/
virtual Tag *tag() const;
/*!
* Implements the unified property interface -- export function.
*/
PropertyMap properties() const;
/*!
* Removes unsupported properties. Forwards to the actual Tag's
* removeUnsupportedProperties() function.
*/
void removeUnsupportedProperties(const StringList &properties);
/*!
* Implements the unified property interface -- import function.
*/
PropertyMap setProperties(const PropertyMap &);
/*!
* Returns the ASF audio properties for this file.
*/
virtual Properties *audioProperties() const;
/*!
* Save the file.
*
* This returns true if the save was successful.
*/
virtual bool save();
/*!
* Returns whether or not the given \a stream can be opened as an ASF
* file.
*
* \note This method is designed to do a quick check. The result may
* not necessarily be correct.
*/
static bool isSupported(IOStream *stream);
private:
void read();
class FilePrivate;
FilePrivate *d;
};
}
}
#endif

View File

@@ -1,183 +0,0 @@
/**************************************************************************
copyright : (C) 2010 by Anton Sergunov
email : setosha@gmail.com
**************************************************************************/
/***************************************************************************
* This library is free software; you can redistribute it and/or modify *
* it under the terms of the GNU Lesser General Public License version *
* 2.1 as published by the Free Software Foundation. *
* *
* This library 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 *
* Lesser General Public License for more details. *
* *
* You should have received a copy of the GNU Lesser General Public *
* License along with this library; if not, write to the Free Software *
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA *
* 02110-1301 USA *
* *
* Alternatively, this file is available under the Mozilla Public *
* License Version 1.1. You may obtain a copy of the License at *
* http://www.mozilla.org/MPL/ *
***************************************************************************/
#include <taglib.h>
#include <tdebug.h>
#include <trefcounter.h>
#include "asfattribute.h"
#include "asffile.h"
#include "asfpicture.h"
#include "asfutils.h"
using namespace TagLib;
class ASF::Picture::PicturePrivate : public RefCounter
{
public:
bool valid;
Type type;
String mimeType;
String description;
ByteVector picture;
};
////////////////////////////////////////////////////////////////////////////////
// Picture class members
////////////////////////////////////////////////////////////////////////////////
ASF::Picture::Picture() :
d(new PicturePrivate())
{
d->valid = true;
}
ASF::Picture::Picture(const Picture& other) :
d(other.d)
{
d->ref();
}
ASF::Picture::~Picture()
{
if(d->deref())
delete d;
}
bool ASF::Picture::isValid() const
{
return d->valid;
}
String ASF::Picture::mimeType() const
{
return d->mimeType;
}
void ASF::Picture::setMimeType(const String &value)
{
d->mimeType = value;
}
ASF::Picture::Type ASF::Picture::type() const
{
return d->type;
}
void ASF::Picture::setType(const ASF::Picture::Type& t)
{
d->type = t;
}
String ASF::Picture::description() const
{
return d->description;
}
void ASF::Picture::setDescription(const String &desc)
{
d->description = desc;
}
ByteVector ASF::Picture::picture() const
{
return d->picture;
}
void ASF::Picture::setPicture(const ByteVector &p)
{
d->picture = p;
}
int ASF::Picture::dataSize() const
{
return
9 + (d->mimeType.length() + d->description.length()) * 2 +
d->picture.size();
}
ASF::Picture& ASF::Picture::operator=(const ASF::Picture& other)
{
Picture(other).swap(*this);
return *this;
}
void ASF::Picture::swap(Picture &other)
{
using std::swap;
swap(d, other.d);
}
ByteVector ASF::Picture::render() const
{
if(!isValid())
return ByteVector();
return
ByteVector((char)d->type) +
ByteVector::fromUInt(d->picture.size(), false) +
renderString(d->mimeType) +
renderString(d->description) +
d->picture;
}
void ASF::Picture::parse(const ByteVector& bytes)
{
d->valid = false;
if(bytes.size() < 9)
return;
int pos = 0;
d->type = (Type)bytes[0]; ++pos;
const unsigned int dataLen = bytes.toUInt(pos, false); pos+=4;
const ByteVector nullStringTerminator(2, 0);
int endPos = bytes.find(nullStringTerminator, pos, 2);
if(endPos < 0)
return;
d->mimeType = String(bytes.mid(pos, endPos - pos), String::UTF16LE);
pos = endPos+2;
endPos = bytes.find(nullStringTerminator, pos, 2);
if(endPos < 0)
return;
d->description = String(bytes.mid(pos, endPos - pos), String::UTF16LE);
pos = endPos+2;
if(dataLen + pos != bytes.size())
return;
d->picture = bytes.mid(pos, dataLen);
d->valid = true;
return;
}
ASF::Picture ASF::Picture::fromInvalid()
{
Picture ret;
ret.d->valid = false;
return ret;
}

View File

@@ -1,222 +0,0 @@
/**************************************************************************
copyright : (C) 2010 by Anton Sergunov
email : setosha@gmail.com
**************************************************************************/
/***************************************************************************
* This library is free software; you can redistribute it and/or modify *
* it under the terms of the GNU Lesser General Public License version *
* 2.1 as published by the Free Software Foundation. *
* *
* This library 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 *
* Lesser General Public License for more details. *
* *
* You should have received a copy of the GNU Lesser General Public *
* License along with this library; if not, write to the Free Software *
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA *
* 02110-1301 USA *
* *
* Alternatively, this file is available under the Mozilla Public *
* License Version 1.1. You may obtain a copy of the License at *
* http://www.mozilla.org/MPL/ *
***************************************************************************/
#ifndef ASFPICTURE_H
#define ASFPICTURE_H
#include "tstring.h"
#include "tbytevector.h"
#include "taglib_export.h"
#include "attachedpictureframe.h"
namespace TagLib
{
namespace ASF
{
//! An ASF attached picture interface implementation
/*!
* This is an implementation of ASF attached pictures interface. Pictures may be
* included in attributes, one per WM/Picture attribute (but there may be multiple WM/Picture
* attribute in a single tag). These pictures are usually in either JPEG or
* PNG format.
* \see Attribute::toPicture()
* \see Attribute::Attribute(const Picture& picture)
*/
class TAGLIB_EXPORT Picture {
public:
/*!
* This describes the function or content of the picture.
*/
enum Type {
//! A type not enumerated below
Other = 0x00,
//! 32x32 PNG image that should be used as the file icon
FileIcon = 0x01,
//! File icon of a different size or format
OtherFileIcon = 0x02,
//! Front cover image of the album
FrontCover = 0x03,
//! Back cover image of the album
BackCover = 0x04,
//! Inside leaflet page of the album
LeafletPage = 0x05,
//! Image from the album itself
Media = 0x06,
//! Picture of the lead artist or soloist
LeadArtist = 0x07,
//! Picture of the artist or performer
Artist = 0x08,
//! Picture of the conductor
Conductor = 0x09,
//! Picture of the band or orchestra
Band = 0x0A,
//! Picture of the composer
Composer = 0x0B,
//! Picture of the lyricist or text writer
Lyricist = 0x0C,
//! Picture of the recording location or studio
RecordingLocation = 0x0D,
//! Picture of the artists during recording
DuringRecording = 0x0E,
//! Picture of the artists during performance
DuringPerformance = 0x0F,
//! Picture from a movie or video related to the track
MovieScreenCapture = 0x10,
//! Picture of a large, coloured fish
ColouredFish = 0x11,
//! Illustration related to the track
Illustration = 0x12,
//! Logo of the band or performer
BandLogo = 0x13,
//! Logo of the publisher (record company)
PublisherLogo = 0x14
};
/*!
* Constructs an empty picture.
*/
Picture();
/*!
* Construct an picture as a copy of \a other.
*/
Picture(const Picture& other);
/*!
* Destroys the picture.
*/
virtual ~Picture();
/*!
* Copies the contents of \a other into this picture.
*/
Picture& operator=(const Picture& other);
/*!
* Exchanges the content of the Picture by the content of \a other.
*/
void swap(Picture &other);
/*!
* Returns true if Picture stores valid picture
*/
bool isValid() const;
/*!
* Returns the mime type of the image. This should in most cases be
* "image/png" or "image/jpeg".
* \see setMimeType(const String &)
* \see picture()
* \see setPicture(const ByteArray&)
*/
String mimeType() const;
/*!
* Sets the mime type of the image. This should in most cases be
* "image/png" or "image/jpeg".
* \see setMimeType(const String &)
* \see picture()
* \see setPicture(const ByteArray&)
*/
void setMimeType(const String &value);
/*!
* Returns the type of the image.
*
* \see Type
* \see setType()
*/
Type type() const;
/*!
* Sets the type for the image.
*
* \see Type
* \see type()
*/
void setType(const ASF::Picture::Type& t);
/*!
* Returns a text description of the image.
*
* \see setDescription()
*/
String description() const;
/*!
* Sets a textual description of the image to \a desc.
*
* \see description()
*/
void setDescription(const String &desc);
/*!
* Returns the image data as a ByteVector.
*
* \note ByteVector has a data() method that returns a const char * which
* should make it easy to export this data to external programs.
*
* \see setPicture()
* \see mimeType()
*/
ByteVector picture() const;
/*!
* Sets the image data to \a p. \a p should be of the type specified in
* this frame's mime-type specification.
*
* \see picture()
* \see mimeType()
* \see setMimeType()
*/
void setPicture(const ByteVector &p);
/*!
* Returns picture as binary raw data \a value
*/
ByteVector render() const;
/*!
* Returns picture as binary raw data \a value
*/
int dataSize() const;
#ifndef DO_NOT_DOCUMENT
/* THIS IS PRIVATE, DON'T TOUCH IT! */
void parse(const ByteVector& );
static Picture fromInvalid();
#endif
private:
class PicturePrivate;
PicturePrivate *d;
};
}
}
#endif // ASFPICTURE_H

View File

@@ -1,194 +0,0 @@
/**************************************************************************
copyright : (C) 2005-2007 by Lukáš Lalinský
email : lalinsky@gmail.com
**************************************************************************/
/***************************************************************************
* This library is free software; you can redistribute it and/or modify *
* it under the terms of the GNU Lesser General Public License version *
* 2.1 as published by the Free Software Foundation. *
* *
* This library 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 *
* Lesser General Public License for more details. *
* *
* You should have received a copy of the GNU Lesser General Public *
* License along with this library; if not, write to the Free Software *
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA *
* 02110-1301 USA *
* *
* Alternatively, this file is available under the Mozilla Public *
* License Version 1.1. You may obtain a copy of the License at *
* http://www.mozilla.org/MPL/ *
***************************************************************************/
#include <tdebug.h>
#include <tstring.h>
#include "asfproperties.h"
using namespace TagLib;
class ASF::Properties::PropertiesPrivate
{
public:
PropertiesPrivate() :
length(0),
bitrate(0),
sampleRate(0),
channels(0),
bitsPerSample(0),
codec(ASF::Properties::Unknown),
encrypted(false) {}
int length;
int bitrate;
int sampleRate;
int channels;
int bitsPerSample;
ASF::Properties::Codec codec;
String codecName;
String codecDescription;
bool encrypted;
};
////////////////////////////////////////////////////////////////////////////////
// public members
////////////////////////////////////////////////////////////////////////////////
ASF::Properties::Properties() :
AudioProperties(AudioProperties::Average),
d(new PropertiesPrivate())
{
}
ASF::Properties::~Properties()
{
delete d;
}
int ASF::Properties::length() const
{
return lengthInSeconds();
}
int ASF::Properties::lengthInSeconds() const
{
return d->length / 1000;
}
int ASF::Properties::lengthInMilliseconds() const
{
return d->length;
}
int ASF::Properties::bitrate() const
{
return d->bitrate;
}
int ASF::Properties::sampleRate() const
{
return d->sampleRate;
}
int ASF::Properties::channels() const
{
return d->channels;
}
int ASF::Properties::bitsPerSample() const
{
return d->bitsPerSample;
}
ASF::Properties::Codec ASF::Properties::codec() const
{
return d->codec;
}
String ASF::Properties::codecName() const
{
return d->codecName;
}
String ASF::Properties::codecDescription() const
{
return d->codecDescription;
}
bool ASF::Properties::isEncrypted() const
{
return d->encrypted;
}
////////////////////////////////////////////////////////////////////////////////
// private members
////////////////////////////////////////////////////////////////////////////////
void ASF::Properties::setLength(int /*length*/)
{
debug("ASF::Properties::setLength() -- This method is deprecated. Do not use.");
}
void ASF::Properties::setLengthInMilliseconds(int value)
{
d->length = value;
}
void ASF::Properties::setBitrate(int value)
{
d->bitrate = value;
}
void ASF::Properties::setSampleRate(int value)
{
d->sampleRate = value;
}
void ASF::Properties::setChannels(int value)
{
d->channels = value;
}
void ASF::Properties::setBitsPerSample(int value)
{
d->bitsPerSample = value;
}
void ASF::Properties::setCodec(int value)
{
switch(value)
{
case 0x0160:
d->codec = WMA1;
break;
case 0x0161:
d->codec = WMA2;
break;
case 0x0162:
d->codec = WMA9Pro;
break;
case 0x0163:
d->codec = WMA9Lossless;
break;
default:
d->codec = Unknown;
break;
}
}
void ASF::Properties::setCodecName(const String &value)
{
d->codecName = value;
}
void ASF::Properties::setCodecDescription(const String &value)
{
d->codecDescription = value;
}
void ASF::Properties::setEncrypted(bool value)
{
d->encrypted = value;
}

View File

@@ -1,186 +0,0 @@
/**************************************************************************
copyright : (C) 2005-2007 by Lukáš Lalinský
email : lalinsky@gmail.com
**************************************************************************/
/***************************************************************************
* This library is free software; you can redistribute it and/or modify *
* it under the terms of the GNU Lesser General Public License version *
* 2.1 as published by the Free Software Foundation. *
* *
* This library 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 *
* Lesser General Public License for more details. *
* *
* You should have received a copy of the GNU Lesser General Public *
* License along with this library; if not, write to the Free Software *
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA *
* 02110-1301 USA *
* *
* Alternatively, this file is available under the Mozilla Public *
* License Version 1.1. You may obtain a copy of the License at *
* http://www.mozilla.org/MPL/ *
***************************************************************************/
#ifndef TAGLIB_ASFPROPERTIES_H
#define TAGLIB_ASFPROPERTIES_H
#include "audioproperties.h"
#include "tstring.h"
#include "taglib_export.h"
namespace TagLib {
namespace ASF {
//! An implementation of ASF audio properties
class TAGLIB_EXPORT Properties : public AudioProperties
{
public:
/*!
* Audio codec types can be used in ASF file.
*/
enum Codec
{
/*!
* Couldn't detect the codec.
*/
Unknown = 0,
/*!
* Windows Media Audio 1
*/
WMA1,
/*!
* Windows Media Audio 2 or above
*/
WMA2,
/*!
* Windows Media Audio 9 Professional
*/
WMA9Pro,
/*!
* Windows Media Audio 9 Lossless
*/
WMA9Lossless,
};
/*!
* Creates an instance of ASF::Properties.
*/
Properties();
/*!
* Destroys this ASF::Properties instance.
*/
virtual ~Properties();
/*!
* Returns the length of the file in seconds. The length is rounded down to
* the nearest whole second.
*
* \note This method is just an alias of lengthInSeconds().
*
* \deprecated
*/
virtual int length() const;
/*!
* Returns the length of the file in seconds. The length is rounded down to
* the nearest whole second.
*
* \see lengthInMilliseconds()
*/
// BIC: make virtual
int lengthInSeconds() const;
/*!
* Returns the length of the file in milliseconds.
*
* \see lengthInSeconds()
*/
// BIC: make virtual
int lengthInMilliseconds() const;
/*!
* Returns the average bit rate of the file in kb/s.
*/
virtual int bitrate() const;
/*!
* Returns the sample rate in Hz.
*/
virtual int sampleRate() const;
/*!
* Returns the number of audio channels.
*/
virtual int channels() const;
/*!
* Returns the number of bits per audio sample.
*/
int bitsPerSample() const;
/*!
* Returns the codec used in the file.
*
* \see codecName()
* \see codecDescription()
*/
Codec codec() const;
/*!
* Returns the concrete codec name, for example "Windows Media Audio 9.1"
* used in the file if available, otherwise an empty string.
*
* \see codec()
* \see codecDescription()
*/
String codecName() const;
/*!
* Returns the codec description, typically contains the encoder settings,
* for example "VBR Quality 50, 44kHz, stereo 1-pass VBR" if available,
* otherwise an empty string.
*
* \see codec()
* \see codecName()
*/
String codecDescription() const;
/*!
* Returns whether or not the file is encrypted.
*/
bool isEncrypted() const;
#ifndef DO_NOT_DOCUMENT
// deprecated
void setLength(int value);
void setLengthInMilliseconds(int value);
void setBitrate(int value);
void setSampleRate(int value);
void setChannels(int value);
void setBitsPerSample(int value);
void setCodec(int value);
void setCodecName(const String &value);
void setCodecDescription(const String &value);
void setEncrypted(bool value);
#endif
private:
class PropertiesPrivate;
PropertiesPrivate *d;
};
}
}
#endif

View File

@@ -1,378 +0,0 @@
/**************************************************************************
copyright : (C) 2005-2007 by Lukáš Lalinský
email : lalinsky@gmail.com
**************************************************************************/
/***************************************************************************
* This library is free software; you can redistribute it and/or modify *
* it under the terms of the GNU Lesser General Public License version *
* 2.1 as published by the Free Software Foundation. *
* *
* This library 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 *
* Lesser General Public License for more details. *
* *
* You should have received a copy of the GNU Lesser General Public *
* License along with this library; if not, write to the Free Software *
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA *
* 02110-1301 USA *
* *
* Alternatively, this file is available under the Mozilla Public *
* License Version 1.1. You may obtain a copy of the License at *
* http://www.mozilla.org/MPL/ *
***************************************************************************/
#include <tpropertymap.h>
#include "asftag.h"
using namespace TagLib;
class ASF::Tag::TagPrivate
{
public:
String title;
String artist;
String copyright;
String comment;
String rating;
AttributeListMap attributeListMap;
};
ASF::Tag::Tag() :
TagLib::Tag(),
d(new TagPrivate())
{
}
ASF::Tag::~Tag()
{
delete d;
}
String ASF::Tag::title() const
{
return d->title;
}
String ASF::Tag::artist() const
{
return d->artist;
}
String ASF::Tag::album() const
{
if(d->attributeListMap.contains("WM/AlbumTitle"))
return d->attributeListMap["WM/AlbumTitle"][0].toString();
return String();
}
String ASF::Tag::copyright() const
{
return d->copyright;
}
String ASF::Tag::comment() const
{
return d->comment;
}
String ASF::Tag::rating() const
{
return d->rating;
}
unsigned int ASF::Tag::year() const
{
if(d->attributeListMap.contains("WM/Year"))
return d->attributeListMap["WM/Year"][0].toString().toInt();
return 0;
}
unsigned int ASF::Tag::track() const
{
if(d->attributeListMap.contains("WM/TrackNumber")) {
const ASF::Attribute attr = d->attributeListMap["WM/TrackNumber"][0];
if(attr.type() == ASF::Attribute::DWordType)
return attr.toUInt();
else
return attr.toString().toInt();
}
if(d->attributeListMap.contains("WM/Track"))
return d->attributeListMap["WM/Track"][0].toUInt();
return 0;
}
String ASF::Tag::genre() const
{
if(d->attributeListMap.contains("WM/Genre"))
return d->attributeListMap["WM/Genre"][0].toString();
return String();
}
void ASF::Tag::setTitle(const String &value)
{
d->title = value;
}
void ASF::Tag::setArtist(const String &value)
{
d->artist = value;
}
void ASF::Tag::setCopyright(const String &value)
{
d->copyright = value;
}
void ASF::Tag::setComment(const String &value)
{
d->comment = value;
}
void ASF::Tag::setRating(const String &value)
{
d->rating = value;
}
void ASF::Tag::setAlbum(const String &value)
{
setAttribute("WM/AlbumTitle", value);
}
void ASF::Tag::setGenre(const String &value)
{
setAttribute("WM/Genre", value);
}
void ASF::Tag::setYear(unsigned int value)
{
setAttribute("WM/Year", String::number(value));
}
void ASF::Tag::setTrack(unsigned int value)
{
setAttribute("WM/TrackNumber", String::number(value));
}
ASF::AttributeListMap& ASF::Tag::attributeListMap()
{
return d->attributeListMap;
}
const ASF::AttributeListMap &ASF::Tag::attributeListMap() const
{
return d->attributeListMap;
}
bool ASF::Tag::contains(const String &key) const
{
return d->attributeListMap.contains(key);
}
void ASF::Tag::removeItem(const String &key)
{
d->attributeListMap.erase(key);
}
ASF::AttributeList ASF::Tag::attribute(const String &name) const
{
return d->attributeListMap[name];
}
void ASF::Tag::setAttribute(const String &name, const Attribute &attribute)
{
AttributeList value;
value.append(attribute);
d->attributeListMap.insert(name, value);
}
void ASF::Tag::setAttribute(const String &name, const AttributeList &values)
{
d->attributeListMap.insert(name, values);
}
void ASF::Tag::addAttribute(const String &name, const Attribute &attribute)
{
if(d->attributeListMap.contains(name)) {
d->attributeListMap[name].append(attribute);
}
else {
setAttribute(name, attribute);
}
}
bool ASF::Tag::isEmpty() const
{
return TagLib::Tag::isEmpty() &&
copyright().isEmpty() &&
rating().isEmpty() &&
d->attributeListMap.isEmpty();
}
namespace
{
const char *keyTranslation[][2] = {
{ "WM/AlbumTitle", "ALBUM" },
{ "WM/AlbumArtist", "ALBUMARTIST" },
{ "WM/Composer", "COMPOSER" },
{ "WM/Writer", "WRITER" },
{ "WM/Conductor", "CONDUCTOR" },
{ "WM/ModifiedBy", "REMIXER" },
{ "WM/Year", "DATE" },
{ "WM/OriginalReleaseYear", "ORIGINALDATE" },
{ "WM/Producer", "PRODUCER" },
{ "WM/ContentGroupDescription", "GROUPING" },
{ "WM/SubTitle", "SUBTITLE" },
{ "WM/SetSubTitle", "DISCSUBTITLE" },
{ "WM/TrackNumber", "TRACKNUMBER" },
{ "WM/PartOfSet", "DISCNUMBER" },
{ "WM/Genre", "GENRE" },
{ "WM/BeatsPerMinute", "BPM" },
{ "WM/Mood", "MOOD" },
{ "WM/ISRC", "ISRC" },
{ "WM/Lyrics", "LYRICS" },
{ "WM/Media", "MEDIA" },
{ "WM/Publisher", "LABEL" },
{ "WM/CatalogNo", "CATALOGNUMBER" },
{ "WM/Barcode", "BARCODE" },
{ "WM/EncodedBy", "ENCODEDBY" },
{ "WM/AlbumSortOrder", "ALBUMSORT" },
{ "WM/AlbumArtistSortOrder", "ALBUMARTISTSORT" },
{ "WM/ArtistSortOrder", "ARTISTSORT" },
{ "WM/TitleSortOrder", "TITLESORT" },
{ "WM/Script", "SCRIPT" },
{ "WM/Language", "LANGUAGE" },
{ "MusicBrainz/Track Id", "MUSICBRAINZ_TRACKID" },
{ "MusicBrainz/Artist Id", "MUSICBRAINZ_ARTISTID" },
{ "MusicBrainz/Album Id", "MUSICBRAINZ_ALBUMID" },
{ "MusicBrainz/Album Artist Id", "MUSICBRAINZ_ALBUMARTISTID" },
{ "MusicBrainz/Release Group Id", "MUSICBRAINZ_RELEASEGROUPID" },
{ "MusicBrainz/Work Id", "MUSICBRAINZ_WORKID" },
{ "MusicIP/PUID", "MUSICIP_PUID" },
{ "Acoustid/Id", "ACOUSTID_ID" },
{ "Acoustid/Fingerprint", "ACOUSTID_FINGERPRINT" },
};
const size_t keyTranslationSize = sizeof(keyTranslation) / sizeof(keyTranslation[0]);
String translateKey(const String &key)
{
for(size_t i = 0; i < keyTranslationSize; ++i) {
if(key == keyTranslation[i][0])
return keyTranslation[i][1];
}
return String();
}
}
PropertyMap ASF::Tag::properties() const
{
PropertyMap props;
if(!d->title.isEmpty()) {
props["TITLE"] = d->title;
}
if(!d->artist.isEmpty()) {
props["ARTIST"] = d->artist;
}
if(!d->copyright.isEmpty()) {
props["COPYRIGHT"] = d->copyright;
}
if(!d->comment.isEmpty()) {
props["COMMENT"] = d->comment;
}
ASF::AttributeListMap::ConstIterator it = d->attributeListMap.begin();
for(; it != d->attributeListMap.end(); ++it) {
const String key = translateKey(it->first);
if(!key.isEmpty()) {
AttributeList::ConstIterator it2 = it->second.begin();
for(; it2 != it->second.end(); ++it2) {
if(key == "TRACKNUMBER") {
if(it2->type() == ASF::Attribute::DWordType)
props.insert(key, String::number(it2->toUInt()));
else
props.insert(key, it2->toString());
}
else {
props.insert(key, it2->toString());
}
}
}
else {
props.unsupportedData().append(it->first);
}
}
return props;
}
void ASF::Tag::removeUnsupportedProperties(const StringList &props)
{
StringList::ConstIterator it = props.begin();
for(; it != props.end(); ++it)
d->attributeListMap.erase(*it);
}
PropertyMap ASF::Tag::setProperties(const PropertyMap &props)
{
static Map<String, String> reverseKeyMap;
if(reverseKeyMap.isEmpty()) {
int numKeys = sizeof(keyTranslation) / sizeof(keyTranslation[0]);
for(int i = 0; i < numKeys; i++) {
reverseKeyMap[keyTranslation[i][1]] = keyTranslation[i][0];
}
}
PropertyMap origProps = properties();
PropertyMap::ConstIterator it = origProps.begin();
for(; it != origProps.end(); ++it) {
if(!props.contains(it->first) || props[it->first].isEmpty()) {
if(it->first == "TITLE") {
d->title.clear();
}
else if(it->first == "ARTIST") {
d->artist.clear();
}
else if(it->first == "COMMENT") {
d->comment.clear();
}
else if(it->first == "COPYRIGHT") {
d->copyright.clear();
}
else {
d->attributeListMap.erase(reverseKeyMap[it->first]);
}
}
}
PropertyMap ignoredProps;
it = props.begin();
for(; it != props.end(); ++it) {
if(reverseKeyMap.contains(it->first)) {
String name = reverseKeyMap[it->first];
removeItem(name);
StringList::ConstIterator it2 = it->second.begin();
for(; it2 != it->second.end(); ++it2) {
addAttribute(name, *it2);
}
}
else if(it->first == "TITLE") {
d->title = it->second.toString();
}
else if(it->first == "ARTIST") {
d->artist = it->second.toString();
}
else if(it->first == "COMMENT") {
d->comment = it->second.toString();
}
else if(it->first == "COPYRIGHT") {
d->copyright = it->second.toString();
}
else {
ignoredProps.insert(it->first, it->second);
}
}
return ignoredProps;
}

View File

@@ -1,209 +0,0 @@
/**************************************************************************
copyright : (C) 2005-2007 by Lukáš Lalinský
email : lalinsky@gmail.com
**************************************************************************/
/***************************************************************************
* This library is free software; you can redistribute it and/or modify *
* it under the terms of the GNU Lesser General Public License version *
* 2.1 as published by the Free Software Foundation. *
* *
* This library 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 *
* Lesser General Public License for more details. *
* *
* You should have received a copy of the GNU Lesser General Public *
* License along with this library; if not, write to the Free Software *
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA *
* 02110-1301 USA *
* *
* Alternatively, this file is available under the Mozilla Public *
* License Version 1.1. You may obtain a copy of the License at *
* http://www.mozilla.org/MPL/ *
***************************************************************************/
#ifndef TAGLIB_ASFTAG_H
#define TAGLIB_ASFTAG_H
#include "tag.h"
#include "tlist.h"
#include "tmap.h"
#include "taglib_export.h"
#include "asfattribute.h"
namespace TagLib {
namespace ASF {
typedef List<Attribute> AttributeList;
typedef Map<String, AttributeList> AttributeListMap;
class TAGLIB_EXPORT Tag : public TagLib::Tag {
friend class File;
public:
Tag();
virtual ~Tag();
/*!
* Returns the track name.
*/
virtual String title() const;
/*!
* Returns the artist name.
*/
virtual String artist() const;
/*!
* Returns the album name; if no album name is present in the tag
* String::null will be returned.
*/
virtual String album() const;
/*!
* Returns the track comment.
*/
virtual String comment() const;
/*!
* Returns the genre name; if no genre is present in the tag String::null
* will be returned.
*/
virtual String genre() const;
/*!
* Returns the rating.
*/
virtual String rating() const;
/*!
* Returns the genre name; if no genre is present in the tag String::null
* will be returned.
*/
virtual String copyright() const;
/*!
* Returns the year; if there is no year set, this will return 0.
*/
virtual unsigned int year() const;
/*!
* Returns the track number; if there is no track number set, this will
* return 0.
*/
virtual unsigned int track() const;
/*!
* Sets the title to \a s.
*/
virtual void setTitle(const String &s);
/*!
* Sets the artist to \a s.
*/
virtual void setArtist(const String &s);
/*!
* Sets the album to \a s. If \a s is String::null then this value will be
* cleared.
*/
virtual void setAlbum(const String &s);
/*!
* Sets the comment to \a s.
*/
virtual void setComment(const String &s);
/*!
* Sets the rating to \a s.
*/
virtual void setRating(const String &s);
/*!
* Sets the copyright to \a s.
*/
virtual void setCopyright(const String &s);
/*!
* Sets the genre to \a s.
*/
virtual void setGenre(const String &s);
/*!
* Sets the year to \a i. If \a s is 0 then this value will be cleared.
*/
virtual void setYear(unsigned int i);
/*!
* Sets the track to \a i. If \a s is 0 then this value will be cleared.
*/
virtual void setTrack(unsigned int i);
/*!
* Returns true if the tag does not contain any data. This should be
* reimplemented in subclasses that provide more than the basic tagging
* abilities in this class.
*/
virtual bool isEmpty() const;
/*!
* \deprecated
*/
AttributeListMap &attributeListMap();
/*!
* Returns a reference to the item list map. This is an AttributeListMap of
* all of the items in the tag.
*/
const AttributeListMap &attributeListMap() const;
/*!
* \return True if a value for \a attribute is currently set.
*/
bool contains(const String &name) const;
/*!
* Removes the \a key attribute from the tag
*/
void removeItem(const String &name);
/*!
* \return The list of values for the key \a name, or an empty list if no
* values have been set.
*/
AttributeList attribute(const String &name) const;
/*!
* Sets the \a key attribute to the value of \a attribute. If an attribute
* with the \a key is already present, it will be replaced.
*/
void setAttribute(const String &name, const Attribute &attribute);
/*!
* Sets multiple \a values to the key \a name.
*/
void setAttribute(const String &name, const AttributeList &values);
/*!
* Sets the \a key attribute to the value of \a attribute. If an attribute
* with the \a key is already present, it will be added to the list.
*/
void addAttribute(const String &name, const Attribute &attribute);
PropertyMap properties() const;
void removeUnsupportedProperties(const StringList& properties);
PropertyMap setProperties(const PropertyMap &properties);
private:
class TagPrivate;
TagPrivate *d;
};
}
}
#endif

View File

@@ -1,104 +0,0 @@
/***************************************************************************
copyright : (C) 2015 by Tsuda Kageyu
email : tsuda.kageyu@gmail.com
***************************************************************************/
/***************************************************************************
* This library is free software; you can redistribute it and/or modify *
* it under the terms of the GNU Lesser General Public License version *
* 2.1 as published by the Free Software Foundation. *
* *
* This library 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 *
* Lesser General Public License for more details. *
* *
* You should have received a copy of the GNU Lesser General Public *
* License along with this library; if not, write to the Free Software *
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA *
* 02110-1301 USA *
* *
* Alternatively, this file is available under the Mozilla Public *
* License Version 1.1. You may obtain a copy of the License at *
* http://www.mozilla.org/MPL/ *
***************************************************************************/
#ifndef TAGLIB_ASFUTILS_H
#define TAGLIB_ASFUTILS_H
// THIS FILE IS NOT A PART OF THE TAGLIB API
#ifndef DO_NOT_DOCUMENT // tell Doxygen not to document this header
namespace TagLib
{
namespace ASF
{
namespace
{
inline unsigned short readWORD(File *file, bool *ok = 0)
{
const ByteVector v = file->readBlock(2);
if(v.size() != 2) {
if(ok) *ok = false;
return 0;
}
if(ok) *ok = true;
return v.toUShort(false);
}
inline unsigned int readDWORD(File *file, bool *ok = 0)
{
const ByteVector v = file->readBlock(4);
if(v.size() != 4) {
if(ok) *ok = false;
return 0;
}
if(ok) *ok = true;
return v.toUInt(false);
}
inline long long readQWORD(File *file, bool *ok = 0)
{
const ByteVector v = file->readBlock(8);
if(v.size() != 8) {
if(ok) *ok = false;
return 0;
}
if(ok) *ok = true;
return v.toLongLong(false);
}
inline String readString(File *file, int length)
{
ByteVector data = file->readBlock(length);
unsigned int size = data.size();
while (size >= 2) {
if(data[size - 1] != '\0' || data[size - 2] != '\0') {
break;
}
size -= 2;
}
if(size != data.size()) {
data.resize(size);
}
return String(data, String::UTF16LE);
}
inline ByteVector renderString(const String &str, bool includeLength = false)
{
ByteVector data = str.data(String::UTF16LE) + ByteVector::fromShort(0, false);
if(includeLength) {
data = ByteVector::fromShort(data.size(), false) + data;
}
return data;
}
}
}
}
#endif
#endif

View File

@@ -1,111 +0,0 @@
/***************************************************************************
copyright : (C) 2002 - 2008 by Scott Wheeler
email : wheeler@kde.org
***************************************************************************/
/***************************************************************************
* This library is free software; you can redistribute it and/or modify *
* it under the terms of the GNU Lesser General Public License version *
* 2.1 as published by the Free Software Foundation. *
* *
* This library 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 *
* Lesser General Public License for more details. *
* *
* You should have received a copy of the GNU Lesser General Public *
* License along with this library; if not, write to the Free Software *
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA *
* 02110-1301 USA *
* *
* Alternatively, this file is available under the Mozilla Public *
* License Version 1.1. You may obtain a copy of the License at *
* http://www.mozilla.org/MPL/ *
***************************************************************************/
#include <tbytevector.h>
#include "aiffproperties.h"
#include "apeproperties.h"
#include "asfproperties.h"
#include "flacproperties.h"
#include "mp4properties.h"
#include "mpcproperties.h"
#include "mpegproperties.h"
#include "opusproperties.h"
#include "speexproperties.h"
#include "trueaudioproperties.h"
#include "vorbisproperties.h"
#include "wavproperties.h"
#include "wavpackproperties.h"
#include "audioproperties.h"
using namespace TagLib;
// This macro is a workaround for the fact that we can't add virtual functions.
// Should be true virtual functions in taglib2.
#define VIRTUAL_FUNCTION_WORKAROUND(function_name, default_value) \
if(dynamic_cast<const APE::Properties*>(this)) \
return dynamic_cast<const APE::Properties*>(this)->function_name(); \
else if(dynamic_cast<const ASF::Properties*>(this)) \
return dynamic_cast<const ASF::Properties*>(this)->function_name(); \
else if(dynamic_cast<const FLAC::Properties*>(this)) \
return dynamic_cast<const FLAC::Properties*>(this)->function_name(); \
else if(dynamic_cast<const MP4::Properties*>(this)) \
return dynamic_cast<const MP4::Properties*>(this)->function_name(); \
else if(dynamic_cast<const MPC::Properties*>(this)) \
return dynamic_cast<const MPC::Properties*>(this)->function_name(); \
else if(dynamic_cast<const MPEG::Properties*>(this)) \
return dynamic_cast<const MPEG::Properties*>(this)->function_name(); \
else if(dynamic_cast<const Ogg::Opus::Properties*>(this)) \
return dynamic_cast<const Ogg::Opus::Properties*>(this)->function_name(); \
else if(dynamic_cast<const Ogg::Speex::Properties*>(this)) \
return dynamic_cast<const Ogg::Speex::Properties*>(this)->function_name(); \
else if(dynamic_cast<const TrueAudio::Properties*>(this)) \
return dynamic_cast<const TrueAudio::Properties*>(this)->function_name(); \
else if(dynamic_cast<const RIFF::AIFF::Properties*>(this)) \
return dynamic_cast<const RIFF::AIFF::Properties*>(this)->function_name(); \
else if(dynamic_cast<const RIFF::WAV::Properties*>(this)) \
return dynamic_cast<const RIFF::WAV::Properties*>(this)->function_name(); \
else if(dynamic_cast<const Vorbis::Properties*>(this)) \
return dynamic_cast<const Vorbis::Properties*>(this)->function_name(); \
else if(dynamic_cast<const WavPack::Properties*>(this)) \
return dynamic_cast<const WavPack::Properties*>(this)->function_name(); \
else \
return (default_value);
class AudioProperties::AudioPropertiesPrivate
{
};
////////////////////////////////////////////////////////////////////////////////
// public methods
////////////////////////////////////////////////////////////////////////////////
AudioProperties::~AudioProperties()
{
}
int AudioProperties::lengthInSeconds() const
{
VIRTUAL_FUNCTION_WORKAROUND(lengthInSeconds, 0)
}
int AudioProperties::lengthInMilliseconds() const
{
VIRTUAL_FUNCTION_WORKAROUND(lengthInMilliseconds, 0)
}
////////////////////////////////////////////////////////////////////////////////
// protected methods
////////////////////////////////////////////////////////////////////////////////
AudioProperties::AudioProperties(ReadStyle) :
d(0)
{
}

View File

@@ -1,127 +0,0 @@
/***************************************************************************
copyright : (C) 2002 - 2008 by Scott Wheeler
email : wheeler@kde.org
***************************************************************************/
/***************************************************************************
* This library is free software; you can redistribute it and/or modify *
* it under the terms of the GNU Lesser General Public License version *
* 2.1 as published by the Free Software Foundation. *
* *
* This library 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 *
* Lesser General Public License for more details. *
* *
* You should have received a copy of the GNU Lesser General Public *
* License along with this library; if not, write to the Free Software *
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA *
* 02110-1301 USA *
* *
* Alternatively, this file is available under the Mozilla Public *
* License Version 1.1. You may obtain a copy of the License at *
* http://www.mozilla.org/MPL/ *
***************************************************************************/
#ifndef TAGLIB_AUDIOPROPERTIES_H
#define TAGLIB_AUDIOPROPERTIES_H
#include "taglib_export.h"
namespace TagLib {
//! A simple, abstract interface to common audio properties
/*!
* The values here are common to most audio formats. For more specific, codec
* dependent values, please see see the subclasses APIs. This is meant to
* compliment the TagLib::File and TagLib::Tag APIs in providing a simple
* interface that is sufficient for most applications.
*/
class TAGLIB_EXPORT AudioProperties
{
public:
/*!
* Reading audio properties from a file can sometimes be very time consuming
* and for the most accurate results can often involve reading the entire
* file. Because in many situations speed is critical or the accuracy of the
* values is not particularly important this allows the level of desired
* accuracy to be set.
*/
enum ReadStyle {
//! Read as little of the file as possible
Fast,
//! Read more of the file and make better values guesses
Average,
//! Read as much of the file as needed to report accurate values
Accurate
};
/*!
* Destroys this AudioProperties instance.
*/
virtual ~AudioProperties();
/*!
* Returns the length of the file in seconds.
*/
virtual int length() const = 0;
/*!
* Returns the length of the file in seconds. The length is rounded down to
* the nearest whole second.
*
* \see lengthInMilliseconds()
*/
// BIC: make virtual
int lengthInSeconds() const;
/*!
* Returns the length of the file in milliseconds.
*
* \see lengthInSeconds()
*/
// BIC: make virtual
int lengthInMilliseconds() const;
/*!
* Returns the most appropriate bit rate for the file in kb/s. For constant
* bitrate formats this is simply the bitrate of the file. For variable
* bitrate formats this is either the average or nominal bitrate.
*/
virtual int bitrate() const = 0;
/*!
* Returns the sample rate in Hz.
*/
virtual int sampleRate() const = 0;
/*!
* Returns the number of audio channels.
*/
virtual int channels() const = 0;
protected:
/*!
* Construct an audio properties instance. This is protected as this class
* should not be instantiated directly, but should be instantiated via its
* subclasses and can be fetched from the FileRef or File APIs.
*
* \see ReadStyle
*/
AudioProperties(ReadStyle style);
private:
AudioProperties(const AudioProperties &);
AudioProperties &operator=(const AudioProperties &);
class AudioPropertiesPrivate;
AudioPropertiesPrivate *d;
};
}
#endif

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