1
0
mirror of https://github.com/tomahawk-player/tomahawk.git synced 2025-09-08 21:20:45 +02:00

Compare commits

...

425 Commits
gfw ... 0.2.2

Author SHA1 Message Date
Jason Herskowitz
13ab10adea Edited ChangeLog via GitHub 2011-08-22 12:29:31 -04:00
Christian Muehlhaeuser
20d2a5ff59 * Bumped version to 0.2.2. 2011-08-22 17:46:55 +02:00
Leo Franchi
6b9eec00fd Changelog 2011-08-22 07:34:47 -04:00
Leo Franchi
d7416ddd57 TWK-415: Don't crash if the trackproxymodel has an invalid current track
(cherry picked from commit 498d7052de)
2011-08-22 07:32:48 -04:00
Leo Franchi
2e9aa7f3b3 Changelog. 2011-08-21 21:41:31 -04:00
Leo Franchi
208393deb0 TWK-401: Only update source stats after addfiles dbcmd is finished, instead of playing a race condition game. Also, refresh recent albums on stats change
(cherry picked from commit 6521198127)
2011-08-21 21:34:26 -04:00
Leo Franchi
b923d4f994 TWK-420: Show resolver wrench immediately after enabling a resolver.
(cherry picked from commit f0a6d4e8bb)
2011-08-21 21:34:20 -04:00
Christian Muehlhaeuser
edbee5a922 * Fixed filtering out unwanted dupes when viewing a local collection. 2011-08-21 22:52:53 +02:00
Michael Zanetti
e0bdc4b8bc TWK-411: Dragging an album/artist to "New Station" creates a station based on that artist instead of all the tracks 2011-08-21 16:00:21 +02:00
Christian Muehlhaeuser
4b53d20663 * Updated ChangeLog. 2011-08-21 04:51:52 +02:00
Christian Muehlhaeuser
74c4f4ddc2 * Fixed TWK-442: Provide stable sort ordering in Track- / TreeProxyModel. 2011-08-21 03:53:42 +02:00
Christian Muehlhaeuser
ec03ece35c * Fixed TWK-435: Don't block pipeline if a resolver times out. 2011-08-21 03:33:32 +02:00
Dominik Schmidt
d217e7fae0 TWK-410: possible fix 2011-08-21 03:33:25 +02:00
Christian Muehlhaeuser
bc3bcc708f * Don't filter out some wanted tracks, e.g. when multiple tracks of an album have the same name, but different tracks numbers. 2011-08-21 02:59:09 +02:00
Christian Muehlhaeuser
7a90ba11bb * Fixed TWK-387: Stop showing a loading spinner, if there are no items to load. 2011-08-21 02:58:59 +02:00
Michael Zanetti
ed219a56cd don't add duplicates when dropping albums or artists and fix losing items when combining synchronous and asynchrounous drop operations 2011-08-20 14:38:43 +02:00
Christian Muehlhaeuser
1537d5b08a * Updated ChangeLog. 2011-08-18 00:05:45 +02:00
Christian Muehlhaeuser
263340a270 * No need for clucene in Tomahawk binary. 2011-08-17 22:13:24 +02:00
Jason Herskowitz
bf54ebf7fe De-decapitate avatar placeholder
(cherry picked from commit 77d60fa02d)
2011-08-17 14:40:04 -04:00
Leo Franchi
bfbac296b0 Fix resolvers on qt 4.8, baseUrl is required for html5 security policy stuff for localStorage
(cherry picked from commit 4abb53ccdf)
2011-08-17 14:36:02 -04:00
Christian Muehlhaeuser
7971e7aadc * More verbose debug output in DBSyncConnection. 2011-08-17 04:15:28 +02:00
Christian Muehlhaeuser
4cc1690dea * Fixed sorting of identical items in Tree- & TrackProxyModel. 2011-08-17 03:34:21 +02:00
Christian Muehlhaeuser
2090d76955 * Fixed sidebar sorting for items with identical names. 2011-08-17 03:20:23 +02:00
Christian Muehlhaeuser
d09397a8ab * Moved the AudioControl QSlider stylesheets into SeekSlider. 2011-08-17 03:20:12 +02:00
Christian Muehlhaeuser
a734cad4e1 * No need for mouse tracking. 2011-08-17 02:27:39 +02:00
Christian Muehlhaeuser
9b433379ee * Fixed TWK-212: Sliders should jump to the position they are clicked on. 2011-08-17 02:27:25 +02:00
Christian Muehlhaeuser
2e11376d01 * Fix sorting for real. 2011-08-17 01:10:56 +02:00
Christian Muehlhaeuser
9ba11290ae * Fixed sidebar sorting. 2011-08-17 01:10:45 +02:00
Leo Franchi
97e0bbaf38 Allow to show the setting dialog always, and disable +/- buttons till loaded
(cherry picked from commit 713243cc5d)
2011-08-16 19:08:03 -04:00
Leo Franchi
eb4242622d Show spinner on initial load while loading sip plugins in preferences. Disable Settings action till servent is loaded
(cherry picked from commit ee8da33e06)
2011-08-16 19:07:57 -04:00
Michael Zanetti
469bea43ba added drag capabilities to albumview ins sourceinfowidget and welcomewidget 2011-08-16 23:49:24 +02:00
Michael Zanetti
f9f3a45a31 fix copyright headers in SettingsListDelegate 2011-08-16 19:53:50 +02:00
Michael Zanetti
0579d63013 fixed copyright headers 2011-08-16 19:53:41 +02:00
Michael Zanetti
1bb115ec6f Created DropJob which will start a query for the dropped items and wait for the results 2011-08-16 19:53:30 +02:00
Michael Zanetti
5f320028b8 more work to be able to drag and drop mixed mimetypes (e.g. an artist and some tracks) 2011-08-16 19:53:15 +02:00
Michael Zanetti
b0d445c262 added drag and drop to playlists for albums and artists 2011-08-16 19:53:06 +02:00
Christian Muehlhaeuser
479a0c469f * Un-regress listen-along. 2011-08-16 03:25:24 +02:00
Christian Muehlhaeuser
b8bf7420d0 * Updated ChangeLog. 2011-08-16 03:14:09 +02:00
Christian Muehlhaeuser
16f32253c3 * Don't try to play unavailable results. 2011-08-16 03:13:11 +02:00
Christian Muehlhaeuser
b6fcae3a4a * Updated ChangeLog. 2011-08-16 02:44:46 +02:00
Christian Muehlhaeuser
2e2ff63a7a * Don't crash when encountering an unknown artist in a search. 2011-08-16 01:45:05 +02:00
Christian Muehlhaeuser
7b24444010 * Update to version 0.2.1. 2011-08-16 01:28:39 +02:00
Christian Muehlhaeuser
7c6304beea * Fixed Javascript resolvers not working / breaking Tomahawk. 2011-08-16 01:27:07 +02:00
Dominik Schmidt
2cd4d7a682 He iiis iiis ... release breaker.. iiis iis release breaker! 2011-08-15 23:54:29 +02:00
Christian Muehlhaeuser
1ff6cfa31f * This makes it official then: 0.2.0 is released. 2011-08-15 21:50:07 +02:00
Leo Franchi
cd8e187bfe paint album selection rect on windows 2011-08-15 14:00:55 -04:00
Christian Muehlhaeuser
33a3ec4c4c * Added logging to Servent. 2011-08-15 19:07:09 +02:00
Leo Franchi
f9c623d654 use correct servicetype in portforward delete as well as create 2011-08-15 11:02:21 -04:00
Leo Franchi
283a3bd216 oops, didn't mean to commit that 2011-08-15 01:47:29 -04:00
Leo Franchi
a8513d41ea Fix sparkle. Again. No, undefined macros are not fun when #ifed. 2011-08-15 01:45:42 -04:00
Leo Franchi
b8394003e8 draw selection rect in settings dialog on windows too. hope it looks okay... 2011-08-15 00:20:40 -04:00
Christian Muehlhaeuser
ae1095217c * Fixed header resizing issues, which were caused by varying column counts. 2011-08-15 04:59:55 +02:00
Leo Franchi
e159698bfd Use update.php instead of sparkle.xml to save stats 2011-08-14 22:40:30 -04:00
Leo Franchi
cd07bd4f71 Add system profiling 2011-08-14 22:26:25 -04:00
Leo Franchi
825903f294 Fix copying automatic playlists and stations 2011-08-14 22:23:14 -04:00
Christian Muehlhaeuser
a5596e0288 * ChangeLog cleanup. 2011-08-15 02:54:12 +02:00
Jason Herskowitz
53c9d0fcde Changelogging 2011-08-14 20:27:23 -04:00
Christian Muehlhaeuser
277c8c4275 Merge remote-tracking branch 'origin/async' 2011-08-15 02:01:34 +02:00
Christian Muehlhaeuser
3d28293250 * Set fixed widths for add / remove buttons in the settings dialog. 2011-08-15 01:55:41 +02:00
Leo Franchi
3df2c2a104 TWK-123: Re-resolve queries when their resolved-to result goes offline. 2011-08-14 18:39:04 -04:00
Christian Muehlhaeuser
65b2f42463 * Fixed TWK-386. Renamed Music to Collection in settings dialog. 2011-08-15 00:10:17 +02:00
Leo Franchi
0e7fae2b5a Tighten up margins in diagnostics dialog 2011-08-14 17:54:16 -04:00
Leo Franchi
afbe74bc13 Add Michael Zanetti to Thanks To... 2011-08-14 17:49:38 -04:00
Leo Franchi
ae32b0b368 TWK-216: reset the proper view mode toggle when changing to a different view mode automatically 2011-08-14 17:44:43 -04:00
Leo Franchi
7d2c284a3e Merge branch 'master' of github.com:tomahawk-player/tomahawk 2011-08-14 17:16:02 -04:00
Leo Franchi
198ad22f09 Fix strange padding due to QPushButton incorrect layouting rect on OS X 2011-08-14 17:15:46 -04:00
Leo Franchi
f9af1e0520 Merge branch 'master' of github.com:tomahawk-player/tomahawk 2011-08-14 16:39:27 -04:00
Michael Zanetti
f2e76803cc fixed offset issue with icons in settings list 2011-08-14 22:37:55 +02:00
Leo Franchi
a11ec10748 Merge branch 'master' of github.com:tomahawk-player/tomahawk 2011-08-14 15:32:37 -04:00
Leo Franchi
a887232fff Fix some margins and fonts on settings dialog 2011-08-14 15:29:07 -04:00
Jason Herskowitz
7e249b91d8 Make dashboard.png not be huge 2011-08-14 15:01:34 -04:00
Leo Franchi
83b3758a25 Change New Additions page to fit other pages more, with title and description and icon. 2011-08-14 14:38:44 -04:00
Leo Franchi
9313de5b17 Show treeview in artistinfowidget with only one column 2011-08-14 14:27:44 -04:00
Leo Franchi
99a298edb5 Manually encode "'" as %27 for QUrls which is legal and makes more apps happy 2011-08-14 14:17:06 -04:00
Leo Franchi
65405682aa Elide description label for long playlist names force window resizes 2011-08-14 14:04:23 -04:00
Leo Franchi
d32e177583 local results should only load social actions by the local source 2011-08-14 13:50:27 -04:00
Dominik Schmidt
4db7228d0c Add async api for returning results in a qtscriptresolver 2011-08-14 16:42:21 +02:00
Jason Herskowitz
56ddbfe93d Make dashboard icon more white like other icons 2011-08-14 10:37:11 -04:00
Dominik Schmidt
4f24e9c5f8 Add some aliases to tomahawk.js 2011-08-14 14:37:16 +02:00
Dominik Schmidt
9b7db84a9e Move result parsing in qtscriptresolver to a method 2011-08-14 14:32:59 +02:00
Dominik Schmidt
e7aa846a0f Remove all references to installer revision 2011-08-14 14:29:55 +02:00
Alejandro Wainzinger
0aa07d62fd Wait for script QProcess to properly exit. 2011-08-14 13:30:22 +02:00
Christian Muehlhaeuser
5449154ee9 * Fixed and cleaned up Logger class. 2011-08-14 08:19:48 +02:00
Christian Muehlhaeuser
2dc94021e2 * You can't expand anything in the track view of the album page. 2011-08-14 06:41:47 +02:00
Christian Muehlhaeuser
33a237086c * Fixed queue button flickering. Much smoother animation. QSplitter, I'll meet you in hell. 2011-08-14 06:29:07 +02:00
Christian Muehlhaeuser
aff34a9dc5 * Removed debugging utility. 2011-08-14 06:19:25 +02:00
Christian Muehlhaeuser
15f5212fa0 * Fixed TWK-375: TreeItemDelegate's painting for tracks was broken. 2011-08-14 04:54:45 +02:00
Christian Muehlhaeuser
add8515111 * Fixed wording on album page. 2011-08-14 04:28:03 +02:00
Christian Muehlhaeuser
37367bc5da * Further cleanups and fixed QPixmap warning: We need to store Source's QPixmaps as pointers, since a Source is being constructed in a thread. 2011-08-14 04:13:38 +02:00
Christian Muehlhaeuser
9ec9901e14 * Remove WebCollection altogether. We've established it's not quite gonna work out that way. 2011-08-14 03:28:35 +02:00
Christian Muehlhaeuser
1fb0af1d97 * Don't initialise a WebCollection. 2011-08-14 03:23:12 +02:00
Christian Muehlhaeuser
989243914c * Fixed queue not allowing to remove items from it. 2011-08-14 03:14:39 +02:00
Dominik Schmidt
7d8e29a932 Removed revision.txt. No warranty, I'm drnuk 2011-08-14 02:47:45 +02:00
Christian Muehlhaeuser
001c42f19f * Removed obsolete tomahawk.nsi. 2011-08-14 02:29:53 +02:00
Dominik Schmidt
d871762897 Remove another obsoleted file 2011-08-14 02:20:20 +02:00
Christian Muehlhaeuser
c5bfb4827d * Removed obsolete files. 2011-08-14 01:46:47 +02:00
Christian Muehlhaeuser
6dd1952ad3 * Fixed TWK-373: Auto-load covers, without waiting for the scrollbar to be triggered. 2011-08-14 01:33:12 +02:00
Christian Muehlhaeuser
28e18b66a6 * Fixed TWK-366: Don't accept drops unless we are using a backing playlist. 2011-08-14 01:25:54 +02:00
Christian Muehlhaeuser
99c61d1731 * Removed debug. 2011-08-14 00:54:56 +02:00
Christian Muehlhaeuser
65835fc2b2 * Fixed cut-off text in WelcomeWidget on non-OSX. 2011-08-14 00:54:56 +02:00
Leo Franchi
4732db07d1 draw a border on osx around album covers as there's no selection background 2011-08-13 18:39:03 -04:00
Leo Franchi
67763df201 use a grey instead of blue for osx selection rect 2011-08-13 17:20:05 -04:00
Leo Franchi
1ef2be9f3c Merge branch 'master' of github.com:tomahawk-player/tomahawk 2011-08-13 17:13:30 -04:00
Leo Franchi
3b148c66ad Paint a selection rect around items in the config dialog on osx 2011-08-13 17:13:05 -04:00
Dominik Schmidt
968bee2a62 Gooooood mooooorniiiing, viiieeetnaaam! 2011-08-13 23:00:00 +02:00
Christian Muehlhaeuser
a7a4b97df8 * Fixed TWK-362: Only display other albums on album page. 2011-08-13 22:56:51 +02:00
Dominik Schmidt
999b9bae22 Restructure version string generation 2011-08-13 22:42:08 +02:00
Dominik Schmidt
e6bb2877ee Fix building installers for windows 2011-08-13 22:18:44 +02:00
Leo Franchi
e367e49039 Remove assertion---happens easily on shutdown if you quit too early while tomahawk is loading, and i've never seen it otherwise. 2011-08-13 16:08:27 -04:00
Dominik Schmidt
47a92664df Recover from apachalogger's "fixes" :P 2011-08-13 21:51:31 +02:00
Leo Franchi
29b0b4e431 Draw whole row background on osx 2011-08-13 15:15:50 -04:00
Leo Franchi
9ca97d2e1a Paint proper text color in tree item delegate 2011-08-13 14:57:03 -04:00
Leo Franchi
50267afe06 Fix cutting off playlistview column in short with avatar mode 2011-08-13 10:14:20 -04:00
Christian Muehlhaeuser
3766edcc43 * Cleaned up tomahawkapp.cpp. 2011-08-13 07:28:15 +02:00
Christian Muehlhaeuser
51b39b5302 * Source & warning cleanup. 2011-08-13 07:25:58 +02:00
Christian Muehlhaeuser
35fdb26b77 * Confusing. It was just working a second ago. 2011-08-13 06:04:43 +02:00
Christian Muehlhaeuser
74d52e3208 * Fixed cross compiling with MinGW. 2011-08-13 05:58:05 +02:00
Christian Muehlhaeuser
db4437cf62 * Fixed adding tracks to the top-level in TreeModel. 2011-08-13 05:37:30 +02:00
Christian Muehlhaeuser
b766f6808f * Fix cross compiling with MinGW and try to unbreak the MainWindow a bit more. 2011-08-13 04:49:09 +02:00
Christian Muehlhaeuser
dce31156db * Another attempt. 2011-08-13 04:46:56 +02:00
Christian Muehlhaeuser
637ec28ab1 * Try to fix ViewManager, too. 2011-08-13 04:38:08 +02:00
Christian Muehlhaeuser
f15dd8153f * Try to fix OS X painting glitch. 2011-08-13 04:23:37 +02:00
Christian Muehlhaeuser
aa68229ac6 * Fixed TWK-107: paint dividers between toolbar, central widget and status bar. 2011-08-13 04:16:04 +02:00
Michael Zanetti
5e6751dc64 merge lfranchi's commit 2011-08-13 04:07:29 +02:00
Michael Zanetti
aff075f2ad added --help command line option 2011-08-13 03:23:00 +02:00
Michael Zanetti
7baf43e3d7 shrink font in newplaylistwidget und allow wordwrap for the text 2011-08-12 22:38:03 +02:00
Leo Franchi
b43fe66409 Hide header for track list in welcome widget 2011-08-12 15:34:21 -04:00
Leo Franchi
809d1139d4 Never sh ow horiz scrollbar in welcomewidget trackview 2011-08-12 15:13:03 -04:00
Jason Herskowitz
009be45dc3 Cha-cha-cha-changelog 2011-08-12 14:51:59 -04:00
Leo Franchi
7d90bc7426 support rd.io shortened links too 2011-08-12 13:04:12 -04:00
Leo Franchi
bb0e7e7631 changelog 2011-08-12 12:52:13 -04:00
Leo Franchi
01c5012028 use artist-description radio instead of song-radio when no artist/song elements are present. fixes TWK-355 2011-08-12 12:50:49 -04:00
Leo Franchi
b9f7bf2656 misc avatar and welcome widget work 2011-08-12 12:30:33 -04:00
Jason Herskowitz
70b0203acd More changelogging. 2011-08-12 09:27:40 -04:00
Dominik Schmidt
1245ae7ac2 Fix linking against QtUiTools on windows 2011-08-12 15:22:06 +02:00
Christian Muehlhaeuser
eda6f8ff8f * We're officially 0.2.0 (rc1) now. 2011-08-12 15:11:34 +02:00
Leo Franchi
4bef594b53 actually fix things :) 2011-08-12 09:11:05 -04:00
Leo Franchi
a72ef2bf6e qt.conf, not info.plist 2011-08-12 09:06:53 -04:00
Harald Sitter
1d6697f11d use cmake_module_path for includes of cmakemodules 2011-08-12 14:25:42 +02:00
Dominik Schmidt
6be91dd558 Fix cross-compilation in cmake 2.8.5 2011-08-12 14:05:47 +02:00
Dominik Schmidt
dc34262445 Hopefully fix AddAppIconMacro inclusion problems for everyone 2011-08-12 13:59:43 +02:00
Leo Franchi
bb1a06a636 mac-specific tweaks 2011-08-12 00:18:38 -04:00
Leo Franchi
1fa1ed42e9 Paint a nicer playlist delegate, and number count backdrop 2011-08-12 00:10:31 -04:00
Christian Muehlhaeuser
fe15fcd1f5 * Remove obsolete method. 2011-08-12 04:18:51 +02:00
Dominik Schmidt
7169aa352e cmake: check for QtWebkit 2011-08-12 04:01:39 +02:00
Dominik Schmidt
4da0b72ded cmake: check for boost 2011-08-12 03:56:30 +02:00
Leo Franchi
7a4a2f5b70 didn't mean to commit that change, doing a partial update of the playlist delegate isn't great 2011-08-11 21:26:05 -04:00
Christian Muehlhaeuser
744f31bb45 Added almost-finished AlbumInfoWidget. 2011-08-12 03:23:46 +02:00
Christian Muehlhaeuser
53f812ed42 * Used tLog() instead of qDebug() for jabber errors. 2011-08-12 03:23:46 +02:00
Leo Franchi
91525bf5d9 reload top loved tracks playlist with love by local source as well 2011-08-11 21:19:57 -04:00
Leo Franchi
595d0cf987 Update playlists when revision info comes in 2011-08-11 21:11:59 -04:00
Leo Franchi
78d867b16f add rdio link parsing 2011-08-11 20:37:17 -04:00
Leo Franchi
2a061b5bf1 change Recently Played for super collection to Dashboard 2011-08-11 18:37:31 -04:00
Leo Franchi
11f7f4a25e re-enable avatars in recently played tracks list, as per TWK-346 2011-08-11 18:24:39 -04:00
Leo Franchi
a9c0d5f820 only show infinity icon for stations, not auto playlists 2011-08-11 18:10:55 -04:00
Leo Franchi
c99fff2b16 Polish up the playlist widget a whole bunch. TWK-348 2011-08-11 18:06:48 -04:00
Michael Zanetti
eda5893012 removed unused function 2011-08-11 23:59:11 +02:00
Michael Zanetti
0e6c79b921 auto-expand the local collections on startup 2011-08-11 23:51:56 +02:00
Christian Muehlhaeuser
c8ba2ee171 Revert "Use 512x512 icon on osx as lion has bigger icon previews"
This reverts commit b7649a3281.
2011-08-11 22:27:31 +02:00
Leo Franchi
206c212767 Don't install Info.plist at cmake time, as it is only valid for releases 2011-08-11 16:07:12 -04:00
Leo Franchi
b0d01ec0fb Add a new macdeploy.py script that intelligently handles osx bundling
Add sip plugins and spotify

Remove old scripts and update build-release-osx.sh to use new macdeploy

Remove old files
2011-08-11 14:40:12 -04:00
Christian Muehlhaeuser
d7100c0e8e * Generally prioritize resolving newer queries to make the GUI feel more responsive. 2011-08-11 18:10:06 +02:00
Christian Muehlhaeuser
6d82ae0c4d * Don't try to resolve search queries when appending them to the SearchWidget's TrackModel. 2011-08-11 15:48:27 +02:00
Jason Herskowitz
649d30e11b Add album art drop shadow. Take 1. 2011-08-11 09:15:07 -04:00
Jason Herskowitz
f36cf0e5fa Make light gray on track placeholder icon match the gray used on album placeholder image. 2011-08-11 08:19:49 -04:00
Christian Muehlhaeuser
e0b406e7ef * Fixed TWK-325: Show a spinner animation while searching for tracks. 2011-08-11 13:58:22 +02:00
Leo Franchi
ca65bb2ccc Don't disable play/pause ever now that we have a stacked layout 2011-08-10 23:17:32 -04:00
Leo Franchi
3a890ee929 Use QStackedLayout instead of show/hide for play/pause widget. Fixes flicker. Extra 2px of spacing i can't get rid of... will work harder. TWK-128 2011-08-10 22:52:50 -04:00
Leo Franchi
c7333a2f1f Merge branch 'leo-test' 2011-08-10 22:51:52 -04:00
Christian Muehlhaeuser
0dd29ffa3d * Use track-placeholder.png in the PlaylistItemDelegate. 2011-08-11 02:48:28 +02:00
Christian Muehlhaeuser
503de73c7f * Use smaller fonts for PipelineStatus- & TransferView. 2011-08-11 02:40:08 +02:00
Christian Muehlhaeuser
5377ff718d Merge pull request #33 from Horrendus/patch-1
Corrected the Path for Jreen
2011-08-10 16:55:04 -07:00
Stefan Derkits
caef0ccdbd Corrected the Path for Jreen 2011-08-11 02:54:32 +03:00
Christian Muehlhaeuser
9e901dba2d * Disable horizontal scrollbars in TransferView. 2011-08-11 01:51:25 +02:00
Christian Muehlhaeuser
291035db9c * Fixed TWK-343, wording in SourceInfoWidget. 2011-08-11 01:30:09 +02:00
Christian Muehlhaeuser
a065480f75 * Let headless users trigger a rescan with --filescan. 2011-08-11 00:57:33 +02:00
Michael Zanetti
3fa64c76ee make use of the avatar frame in recently played 2011-08-11 00:14:20 +02:00
Jason Herskowitz
554a688077 Add track placeholder image for artist pages (Top Hits) and New Additions pages (Latest Additions). 2011-08-10 16:56:02 -04:00
Jason Herskowitz
c1f043d2d1 Mo' better avatar frame 2011-08-10 16:20:50 -04:00
Michael Zanetti
bc3662a997 added the avatar frame also to the Collection and SuperCollection icons
BUG: TWK-337
2011-08-10 17:23:02 +02:00
Michael Zanetti
d3ab32d06a changed color of score bars to match the rest of the color palette
BUG-252
2011-08-10 17:23:02 +02:00
Leo Franchi
c36373569a Check for KDE4 dev headers, in order for sip icons to show up in delegate. No, I don't have any clue why this fixes it. Stop asking. Go Away. 2011-08-09 22:46:50 -04:00
Michael Zanetti
3dbc426954 fixed the off-by-one issue with avatar frames 2011-08-10 04:10:16 +02:00
Jason Herskowitz
4415aa59f8 Make 32px image actually be 32px 2011-08-09 21:55:31 -04:00
Christian Muehlhaeuser
6fdec28f50 * Silly whitespace fixes. 2011-08-10 03:47:46 +02:00
Christian Muehlhaeuser
ef2514e95c * Added convenient new Album::get method. 2011-08-10 03:47:46 +02:00
Michael Zanetti
27480f8cdb added SettingsListDelegate to center the items in SettingsDialogList
BUG: 314
2011-08-10 03:41:02 +02:00
Jason Herskowitz
fbcfb552ad Make inner square of frame a square instead of a rectangle so the image doesn't look off-center. 2011-08-09 21:16:50 -04:00
Michael Zanetti
25012ecc26 changed slider button stylesheets to allow moving them to the end
BUG: TWK-289
2011-08-10 00:14:03 +02:00
Michael Zanetti
c29ce585a5 Added a frame to the avatars as requested in bug TWK-106.
The frame image must be in displayed size and the avatar takes 80% of the available space centered.
2011-08-10 00:14:03 +02:00
Leo Franchi
3af34a8581 Only show loved tracks (not loved or unloved) in playlist. Update existing social action instead of duplicating it.. 2011-08-09 10:48:26 -04:00
Leo Franchi
9ec284bfa5 Merge branch 'master' into leo-test
Conflicts:
	src/libtomahawk/playlist/dynamic/DynamicPlaylist.h
	src/libtomahawk/widgets/welcomeplaylistmodel.cpp
2011-08-09 07:26:26 -04:00
Leo Franchi
585bfcdc49 debug-- 2011-08-09 07:12:55 -04:00
Leo Franchi
339710c86a Find playlist/dynplaylist item to activate if opened from non-sidebar. TWK-300. Ugh. 2011-08-08 23:24:24 -04:00
Christian Muehlhaeuser
fc43a6a851 * Hide the last.fm test button on OS X - for the 0.2 release. 2011-08-09 03:41:06 +02:00
Christian Muehlhaeuser
4b2c6e8d89 * 50 fps is enough for our AnimatedSplitter animation. 2011-08-09 03:36:16 +02:00
Christian Muehlhaeuser
6cba708640 * BUG: TWK-312 - Fixed AnimatedSplitter cutting off child widgets. 2011-08-09 03:21:55 +02:00
Dominik Schmidt
a46aadd843 Use filter.png for the filter in the topbar 2011-08-09 03:20:54 +02:00
Leo Franchi
d7dd3292ff be safer and don't crash. TWK-333 2011-08-08 21:07:49 -04:00
Dominik Schmidt
6b62265708 Show what you've actually searched for in the sidebar 2011-08-09 02:52:01 +02:00
Christian Muehlhaeuser
304981c28b * We should still remove the query from the pending list in Pipeline. 2011-08-09 02:00:03 +02:00
Dominik Schmidt
ba0c21e111 Show tomahawk version in the diagnostics dialog 2011-08-09 01:48:20 +02:00
Christian Muehlhaeuser
023be21950 * Fixed the preemptive onResolvingFinished() call triggered by the Pipeline. Fixes stations, I bet. 2011-08-09 00:54:56 +02:00
Michael Zanetti
fb95568196 Start playing on ENTER in artistview
BUG: TWK-204
2011-08-09 00:45:37 +02:00
Christian Muehlhaeuser
d9a4b718ed * Use setPixelSize instead of setPointSize. Should fix HeaderLabel weirdness on some systems. 2011-08-08 21:55:39 +02:00
Christian Muehlhaeuser
72add01e66 * Prevent multiple resolvingFinished() signals being emitted from Query. 2011-08-08 21:32:54 +02:00
Dominik Schmidt
f05c58150e Fix FindPhonon.cmake to respect find_version 2011-08-08 14:54:54 +02:00
Dominik Schmidt
7dc1e94ae6 Fix FindCLucene.cmake to respect find_version 2011-08-08 14:53:35 +02:00
Dominik Schmidt
8e07eb5c55 Use macro_optional_find_package everywhere. FindPhonon needs to be fixed
to respect the version number.
2011-08-08 14:08:17 +02:00
Leo Franchi
44aa85b51e support spotifyURL and spotifyURI in track/open, track/queue, and track/play links 2011-08-07 17:43:48 -04:00
Jason Herskowitz
dcf1ebb70f Don't forget one of the drag indicator icon sizes (22x22) 2011-08-07 17:37:27 -04:00
Leo Franchi
0865741733 Don't draw white text on light background 2011-08-07 17:09:18 -04:00
Leo Franchi
58c18acd01 Load automatic playlists and stations in Newest Stations and Playlists list... 2011-08-07 17:09:18 -04:00
Leo Franchi
4630b238bf Merge branch 'master' into leo-test
Conflicts:
	src/audiocontrols.cpp
2011-08-07 17:00:16 -04:00
Jason Herskowitz
f3dc1a0800 Trying some new matching icons for the drag indictors for songs 2011-08-07 16:44:57 -04:00
Leo Franchi
7df6e8c153 use avatar icon in recently played tracks for not-found avatars 2011-08-07 12:41:29 -04:00
Leo Franchi
566880365a Better copy for loved tracks playlist, and show all without limit. 2011-08-07 12:41:29 -04:00
Dominik Schmidt
dd54736e76 Unbreak clang compilation. 2011-08-07 15:56:06 +02:00
Leo Franchi
2c8fac1f8c Actually draw speaker icon in playlist delegate. I'm assuming this was a typo... 2011-08-06 23:59:41 -04:00
Leo Franchi
ce4328c0c3 Hide headers for related artists treeview in artistinfowidget. Don't ask my why it has to happen when it's already displayed.
Fixes TWK-310
2011-08-06 23:34:14 -04:00
Leo Franchi
c6a65a5ba4 Use a lighter color on os x as highlight color for score bar is way too bright. 2011-08-06 20:41:21 -04:00
Leo Franchi
8230e8bfac Asynchronously update on social action loading so loved tracks show up loaded 2011-08-06 18:30:17 -04:00
Leo Franchi
23ea7537e6 Report social action changes and refresh loved playlists 2011-08-06 18:06:21 -04:00
Leo Franchi
b9733249ee Sort by time and show source's own loved tracks 2011-08-06 17:24:05 -04:00
Leo Franchi
ffd5a2f81e Ooops, use true not 1 2011-08-06 16:58:07 -04:00
Leo Franchi
eefc6fd5da OSX Compile 2011-08-06 16:21:01 -04:00
Leo Franchi
d69b10c148 Merge branch 'databasegenerator' 2011-08-06 14:41:59 -04:00
Leo Franchi
9fbbcb6b53 Hide generator combobox until we have more than one generator 2011-08-06 14:41:47 -04:00
Leo Franchi
c6eee1324b Paint dynamic controls the same hue as overlay widget. TWK-309 2011-08-06 14:41:47 -04:00
Leo Franchi
b960be9d97 Get top 60 loved tracks, not 30 2011-08-06 14:41:35 -04:00
Leo Franchi
cdfd6a3464 dd proper loved tracks queries 2011-08-06 14:35:51 -04:00
Leo Franchi
4cfd039c40 social action stuff 2011-08-06 12:40:29 -04:00
Frank Osterfeld
8e4ea5e88f Link on OS X 2011-08-06 18:28:55 +02:00
Jason Herskowitz
76fbe88e95 More changelogging 2011-08-05 17:47:27 -04:00
Leo Franchi
1759d1ea19 Add a loved tracks playlist, and aggregate loved tracks playlist, minus the actual valid tracks 2011-08-05 17:17:28 -04:00
Leo Franchi
703823f553 fix up some copyrights from muesli's script 2011-08-05 16:05:53 -04:00
Leo Franchi
aeb949aa23 Fix merge 2011-08-05 15:39:04 -04:00
Leo Franchi
b15d3162de Merge branch 'master' into databasegenerator
Conflicts:
	src/libtomahawk/CMakeLists.txt
	src/libtomahawk/globalactionmanager.cpp
2011-08-05 15:38:26 -04:00
Leo Franchi
b2deebe0c2 Hide generator combobox until we have more than one generator 2011-08-05 15:36:04 -04:00
Leo Franchi
5d5b5fa3af Paint dynamic controls the same hue as overlay widget. TWK-309 2011-08-05 14:55:39 -04:00
Leo Franchi
f151b59431 Show search and artist pages as temporary pages in sidebar
Remove margins and spacing from searchwidget
Remove "Cancel" button as no other view pages have cancel buttons, and we can't delete a page if we show it as a temporary page anymore
2011-08-05 14:36:52 -04:00
Leo Franchi
c7c12eef93 Show drop indicator after last track if it's dropped below 2011-08-05 14:22:34 -04:00
Leo Franchi
b67623e649 Don't redefine signals 2011-08-05 14:14:59 -04:00
Leo Franchi
8834bf81fa save styles/moods to file, instead of loading on demand sillyness. Fixes TWK-308 2011-08-05 14:06:39 -04:00
Leo Franchi
0877b17a58 Handle multiply-shortened urls. 2011-08-05 12:46:37 -04:00
Leo Franchi
7df1f7a8b8 Expand bit.ly, t.co, and j.mp links to spotify tracks 2011-08-05 12:38:16 -04:00
Leo Franchi
453bf6206c Only accept spotify tracks by default 2011-08-05 12:00:57 -04:00
Leo Franchi
4d31eac5f6 Emit trackCountChanged when dropping tracks in a playlist. Handle Qt/Mac bug where drops from outside the app are Qt::MoveAction not Qt::CopyAction 2011-08-05 11:57:42 -04:00
Leo Franchi
7feb9d5249 Draw proper drop index, since on some platforms (OS X :( ) visualRect() and indexAt() aren't commutative... 2011-08-05 11:46:18 -04:00
Alejandro Wainzinger
0c4746430b Merge branch 'master' of github.com:tomahawk-player/tomahawk 2011-08-05 17:33:22 +02:00
Alejandro Wainzinger
ec02854490 Do not backwards the signals connect for next/previous.
* Fixed TWK-313 - fix signal/slot connection for next/previous actionmenu items.
2011-08-05 17:31:31 +02:00
Leo Franchi
ae48c151d0 Show indicator on osx too. NO CLUE why this fixes it.. 2011-08-05 11:21:26 -04:00
Leo Franchi
57dfd6b4b2 Set drop rect from left edge to right edge always, don't rely on QAIV for native drag-drops 2011-08-05 11:14:08 -04:00
Leo Franchi
0e2dd37559 allow dropping onto AudioControls to start playing 2011-08-05 10:39:08 -04:00
Leo Franchi
98030c9b05 Merge branch 'dragndrop' 2011-08-05 07:57:26 -04:00
Leo Franchi
89cec23815 On OS X drops from outside the apps are Qt::MoveActions.... 2011-08-05 07:53:30 -04:00
Dominik Schmidt
e476251c5e Remove ugly dash from rc version 2011-08-05 02:56:57 +02:00
Leo Franchi
4a3bca9bf4 Factor out dragndrop support across tomahawk into GlobalActionManager, add spotify support 2011-08-04 19:01:41 -04:00
Jason Herskowitz
0ad60299ef Cleaned up formatting a bit. 2011-08-04 18:29:59 -03:00
Jason Herskowitz
1d13bc2e40 Stop repeating myself in changelog 2011-08-04 15:30:55 -04:00
Jason Herskowitz
04bff62705 Couple of edits to changelog. Added desktop notifications (linux) and removed libpng entry. 2011-08-04 15:26:44 -04:00
Jason Herskowitz
e4893be501 More changelogifying. Take a look and see if I missed anything or added too much. 2011-08-04 15:23:12 -04:00
Jason Herskowitz
fe762d4fc5 Changelogifying 2011-08-04 14:35:31 -03:00
Jason Herskowitz
dbb7c64807 de-biggified the info.png icon by adding padding to image 2011-08-04 10:12:15 -04:00
Jason Herskowitz
2fdab5c9a1 New 16x16 info.png. May play around with different icons, but scales well now. 2011-08-04 07:51:24 -04:00
Christian Muehlhaeuser
18628defa4 * Fixed info.png's size. 2011-08-04 06:34:36 +02:00
Christian Muehlhaeuser
4a34b97e8c * This should fix the Windows local file playback issues. 2011-08-04 06:11:14 +02:00
Leo Franchi
9d88c9a0f7 Add support for JSPF playlists, remote and local. TWK-303 2011-08-03 23:35:10 -04:00
Leo Franchi
a9111267e8 Merge branch 'master' into databasegenerator
Conflicts:
	src/libtomahawk/CMakeLists.txt
	src/libtomahawk/database/databasecommand_createplaylist.cpp
	src/libtomahawk/playlist/dynamic/DynamicPlaylist.h
2011-08-03 23:31:25 -04:00
Leo Franchi
d3eb8df91a Add support for JSPF playlists, remote and local 2011-08-03 23:26:24 -04:00
Christian Muehlhaeuser
f010736e0d * Call setVisible on the lineEdit... just to be sure. 2011-08-04 05:24:46 +02:00
Christian Muehlhaeuser
9a1ac2f505 * Ignore empty searches. 2011-08-04 05:21:33 +02:00
Christian Muehlhaeuser
8c3ea50301 * Added native MacLineEdit widget and used it in TomahawkWindow's toolbar. 2011-08-04 05:11:12 +02:00
Leo Franchi
5fd8e2181d support playing spotify track urls (http://open.spotify.com or spotify:track). No drag-n-drop yet. 2011-08-03 18:06:49 -04:00
Christian Muehlhaeuser
92efd0da7f * Hopefully fixes the file:// issues on Windows. 2011-08-03 23:47:02 +02:00
Leo Franchi
326b75aefe Don't crash if user rapidly regenerates automatic playlists 2011-08-03 16:58:24 -04:00
Christian Muehlhaeuser
5e4b5fa0d0 * Fixed race condition in AudioEngine. 2011-08-03 16:45:41 +02:00
Leo Franchi
8f4ea6d95d Crash less 2011-08-03 10:44:14 -04:00
Christian Muehlhaeuser
d803a36915 * Possible fix for windows filename issues. 2011-08-03 15:33:21 +02:00
Leo Franchi
12f6d1f780 Always trigger sync for local playlist creation 2011-08-02 23:28:51 -04:00
Leo Franchi
5c58bc1d58 Be safer when deleting playlist category items, this might fix some weirdness 2011-08-02 23:28:51 -04:00
Jason Herskowitz
ae66fb8c5c Add share icon to use for tweet/post action 2011-08-02 21:52:14 -04:00
Jason Herskowitz
4a93bb97fc Adding an icon for 'filter' so we don't have to use the same magnifying glass we use for search 2011-08-01 21:36:00 -04:00
Jeff Mitchell
35c3eedd93 Some Changelogifying. 2011-08-01 12:35:44 -04:00
Leo Franchi
ea69fe158a be careful 2011-08-01 11:39:03 -04:00
Christian Muehlhaeuser
de508c049b * A few more improvements to TrackView & PlaylistItemDelegate. 2011-08-01 09:51:24 +02:00
Christian Muehlhaeuser
cf56819b0c * Lower the FuncTimeouts again. I can't reproduce any issues here. 2011-08-01 09:38:49 +02:00
Christian Muehlhaeuser
2f7d13588f * Slightly improved flat-view's painting speed. 2011-08-01 09:32:08 +02:00
Christian Muehlhaeuser
7b2189cd6f * Disable mimetype checking for now. 2011-08-01 05:57:51 +02:00
Christian Muehlhaeuser
37e77f4fd7 * Removed InfoBar from welcome page. 2011-08-01 04:52:58 +02:00
Christian Muehlhaeuser
7ee6db41d6 * Ignore results with unsupported mimetypes. 2011-08-01 04:47:28 +02:00
Christian Muehlhaeuser
a8e72c3b26 * Never elide caption in InfoBar to avoid silly eliding problems. 2011-08-01 04:24:46 +02:00
Christian Muehlhaeuser
a41e84ae78 * Try to fix AnimatedSplitter. 2011-08-01 04:04:13 +02:00
Jason Herskowitz
bf37bad98a Another try on info.png 2011-07-31 21:47:18 -04:00
Christian Muehlhaeuser
374e6a0983 * Use info.png for contextual links. 2011-08-01 03:15:49 +02:00
Christian Muehlhaeuser
c06b5ea2f6 * Always wait for DatabaseResolvers to finish before shunting queries. 2011-08-01 02:37:55 +02:00
Christian Muehlhaeuser
243997b06e * Use new default artist placeholder image. 2011-08-01 02:27:12 +02:00
Christian Muehlhaeuser
d0858efd7d * Fixed warnings and removed weird margin on ArtistInfoWidget. 2011-08-01 02:20:46 +02:00
Leo Franchi
7ea0de753e remove empty Playlists or Stations entry if all are deleted from peers 2011-07-31 19:46:24 -04:00
Leo Franchi
432d6af37c Delete playlists from peers in the UI as well 2011-07-31 19:41:06 -04:00
Leo Franchi
e1943e6f64 Queue too-fast revision changes and replay them in order to avoid crashes while fast editing 2011-07-31 19:30:45 -04:00
Leo Franchi
e3dddea777 Fix external resolvers that depend on setup message 2011-07-31 13:16:10 -04:00
Leo Franchi
3e1d58463d Change Search to Filter in filter line edit for collections 2011-07-31 12:39:11 -04:00
Leo Franchi
8e51953427 Switch to using direct GenericSelect command 2011-07-31 11:44:23 -04:00
Leo Franchi
91bdfec734 Limit results to what was asked for 2011-07-30 17:16:56 -04:00
Leo Franchi
808901d192 Merge branch 'master' into databasegenerator 2011-07-30 17:06:06 -04:00
Leo Franchi
ce60c173b7 Add support for track, artist, and album generic queries 2011-07-30 17:05:01 -04:00
Leo Franchi
9c36b32e8e add migrate script 2011-07-30 16:13:29 -04:00
Leo Franchi
c76fabbc2b Create and load database-backed special dynamic playlists, and fix some debugs and stuff 2011-07-30 15:35:32 -04:00
Jeff Mitchell
75596c6744 Add initial configuration message support to external resolvers, send proxy info 2011-07-30 14:36:03 -04:00
Leo Franchi
ca467fb5bc Add support for non-autoloaded dynamic playlists that can be used for custom displays
Add a SocialPlaylistWidget that will display some cool social stats and lists, but none right now
2011-07-29 14:06:44 -04:00
Leo Franchi
9120f6436c Scroll per pixel on osx since that's how other apps do it, feels more natural with a trackpad 2011-07-28 16:18:19 -04:00
Leo Franchi
b7649a3281 Use 512x512 icon on osx as lion has bigger icon previews 2011-07-27 08:46:11 -04:00
Thierry Goeckel
10ec1f4f89 Correct minor mistakes according online lint. 2011-07-26 20:20:35 +02:00
Leo Franchi
9fdddbf04e Slow down pipeline a bit to fix spotify resolver; need to talk to chris about why the timeout change broke it. 2011-07-26 09:25:24 -04:00
Leo Franchi
0380379634 Fix obscene filename of class 2011-07-25 18:16:37 -04:00
Leo Franchi
72bfeba65a add to cmakelists 2011-07-25 18:15:46 -04:00
Leo Franchi
4a8b851ba5 Initial database generators 2011-07-25 18:15:39 -04:00
Jason Herskowitz
5fca433805 New album placeholder artwork. Better or worse? 2011-07-25 16:53:17 -04:00
Leo Franchi
cb75c10390 Attempt to stop eliding on osx and also keep things sane elsewhere 2011-07-25 11:58:26 -04:00
Leo Franchi
b7432c8b6c Try using non-escaped path for QFile::exists() 2011-07-25 11:01:25 -04:00
Leo Franchi
df6dc711fc qDebug()-- 2011-07-25 10:52:31 -04:00
Leo Franchi
6a8febcdce Make compile on lion 2011-07-25 10:32:42 -04:00
Christian Muehlhaeuser
ff4e52c398 * Fixed CPack.txt package details. 2011-07-25 14:48:31 +02:00
Christian Muehlhaeuser
2cf9cdab88 * Added QPixmap-caches to Album- & PlaylistItem delegates, too. 2011-07-25 04:01:23 +02:00
Christian Muehlhaeuser
1a3cae012e * Add a QPixmap-cache to the TreeView delegate. 2011-07-25 03:55:02 +02:00
Christian Muehlhaeuser
d4ccbdfa56 * Fixed QTimeLine warning and give the biography on the Artist-Page as much space as possible. 2011-07-25 03:44:05 +02:00
Christian Muehlhaeuser
87531a7ac9 * Get rid of dupe qsrand()s. We do that on startup. 2011-07-25 03:26:58 +02:00
Christian Muehlhaeuser
0c5673ca79 * Filter out duplicate tracks in the Tree Collection. 2011-07-25 03:07:36 +02:00
Christian Muehlhaeuser
ff7012a65d * Start tomahawk with --verbose to get full logging and console output, again. 2011-07-25 01:57:10 +02:00
Christian Muehlhaeuser
601b513da3 * Cleaned up more logging. 2011-07-25 01:41:49 +02:00
Christian Muehlhaeuser
cf6a3c9448 * Further cleanups & logging. 2011-07-25 00:48:40 +02:00
Christian Muehlhaeuser
8c78c0dc08 * Added logging levels. 2011-07-25 00:48:40 +02:00
Christian Muehlhaeuser
bb4b3b4faf * Added tDebug and a debug-level. Don't log qDebug to disk _ever_. 2011-07-25 00:48:40 +02:00
Christian Muehlhaeuser
4caf6d6a28 * Logging cleanups. 2011-07-25 00:48:39 +02:00
Dominik Schmidt
499f45402f Build installers with phonon-vlc and vlc from 0.1 time because currently mingw32-phonon-vlc is broken 2011-07-25 00:32:35 +02:00
Christian Muehlhaeuser
ddedc74501 * GPL headers for AvatarManager. 2011-07-24 20:08:58 +02:00
Christian Muehlhaeuser
0526d4071d * Fixed a few more GPL headers. 2011-07-24 20:07:04 +02:00
Christian Muehlhaeuser
7555c06c0f * Added GPL header to Logger. 2011-07-24 20:05:14 +02:00
Christian Muehlhaeuser
55bef176d3 * Make tLog() work properly. 2011-07-24 19:22:44 +02:00
Christian Muehlhaeuser
9c341bb3e6 * Disable qDebug() logging for release builds. Use tLog() for logging from NOW on. 2011-07-24 18:36:58 +02:00
Christian Muehlhaeuser
41f1a562fd * Fixed DatabaseWorker logic. 2011-07-24 18:36:58 +02:00
Dominik Schmidt
34c618ed94 Fix windows deployment to use local vlc plugins again 2011-07-24 00:36:34 +02:00
Jeff Mitchell
a9e3b716f2 Make things a little safer and also try setting an explicit nam configuration on liblastfm2 in settings dialog to see if that fixes the Mac problem 2011-07-23 13:15:20 -04:00
Jeff Mitchell
287990ca96 Don't reconnect twitter on settings change if it wasn't already connected 2011-07-23 11:46:15 -04:00
Jeff Mitchell
9e54917ff8 Remove now-unnecessary and buggy proxy code in jabber plugin 2011-07-23 11:37:32 -04:00
Jeff Mitchell
40d44c31d0 Add more debug 2011-07-23 11:30:02 -04:00
Jeff Mitchell
f4be7f09e6 Merge branch 'master' into proxytesting 2011-07-23 10:32:20 -04:00
Jeff Mitchell
794d6f870c Add weird debug output from jabber sip 2011-07-22 16:42:27 -04:00
Leo Franchi
8f6a567bee Work harder to hide the header 2011-07-22 14:35:38 -04:00
Leo Franchi
ea3171038b Make playlist album rows the same size as track album rows 2011-07-22 13:54:30 -04:00
Leo Franchi
ee3fb6b47e Don't paint selected text as white on osx, there's no selection rect. 2011-07-22 13:13:20 -04:00
Leo Franchi
b194d8c9cd Use new no-album-cover found image, nicer 2011-07-22 13:13:20 -04:00
Leo Franchi
a7308cddcc Scale pixmaps smoothly to avoid horrible jagged edges 2011-07-22 13:13:20 -04:00
Leo Franchi
7f890e571d Hide header as it's not needed 2011-07-22 13:13:20 -04:00
Christian Muehlhaeuser
4a5a8e5d15 * Don't artificially slow down the Pipeline. 2011-07-22 18:31:10 +02:00
Leo Franchi
66b1e21f31 Use QSplitter to get a 1px handle to avoid merging different alternate-color rows 2011-07-22 11:11:29 -04:00
Leo Franchi
36573c2342 Load album before adding to view to avoid flashing empty playlist message 2011-07-22 11:11:13 -04:00
Leo Franchi
0b9822d689 make compile on non-osx 2011-07-21 16:25:58 -04:00
Leo Franchi
f36b95fe6b OSX: Don't quit on window close, to conform to OSX expectations. Add Show/Hide action to tray icon. 2011-07-21 16:21:45 -04:00
Leo Franchi
1da74e4d81 Add a stretch factor to the title of the playlist header, things like "My Collection" don't get elided to My...tion 2011-07-21 14:55:57 -04:00
Leo Franchi
c0ee4751a0 make link manager adapt to pipeline reportresult changes 2011-07-21 13:34:44 -04:00
Christian Muehlhaeuser
aa5fb8bc53 * Fixed GStreamer pausing - even more. Sigh for Phonon's states. 2011-07-21 18:49:22 +02:00
Leo Franchi
57cdd0d960 Bring to front on mac when a tomahawkurl is opened in Tomahawk. Will add linux and win-specific code as well. 2011-07-21 11:22:26 -04:00
Alejandro Wainzinger
4ac6c32a45 Use clear() to clear text, not a QString(). 2011-07-21 05:16:09 -07:00
Alejandro Wainzinger
00c122b05c * Fixed TWK-249 - Add a bit more widget spacing to fix clipping of search box. 2011-07-21 05:14:31 -07:00
Alejandro Wainzinger
bcf7d9d689 * Fixed TWK-261 - Make "show offline sources" a checkable option, and save its value in settings. 2011-07-21 01:57:41 -07:00
Christian Muehlhaeuser
dbf31d704a * Cleaned up QtScriptResolver and added vital debug output. 2011-07-21 00:59:26 +02:00
Christian Muehlhaeuser
7f4d64d8dc * Always apply ProxyStyle. 2011-07-21 00:43:15 +02:00
Jeff Mitchell
2f95e0b191 Fix mistaken logic not using the map created especially for its
purpose...
2011-07-20 18:35:50 -04:00
Jeff Mitchell
86ac66a258 Use the enum value, to avoid out-of-order documentation mixup 2011-07-20 18:24:32 -04:00
Leo Franchi
f5e39c216e properly decode escaped characters coming from the HTTP api 2011-07-20 14:12:17 -04:00
Leo Franchi
5336700050 find LIBLASTFM_FOUND properly instead of always finding it as false 2011-07-20 07:43:01 -04:00
Christian Muehlhaeuser
bb8c60c939 * Removed obsolete includes from TomahawkWindow. 2011-07-20 08:26:16 +02:00
Christian Muehlhaeuser
48b2c77e6b * Cleaned up TomahawkWindow. 2011-07-20 08:22:38 +02:00
Christian Muehlhaeuser
900be23fa0 * A few updates to the german translation. 2011-07-20 07:37:49 +02:00
Christian Muehlhaeuser
fbb9e74537 * Fixed german translation setting a global quit shortcut on the key 'Q'. 2011-07-20 07:20:32 +02:00
Christian Muehlhaeuser
21abd78de5 * Remove not-working CMake cache solution. 2011-07-20 07:15:10 +02:00
Christian Muehlhaeuser
0a5f9ba290 * Use the same unique revision identifier as git itself. 2011-07-20 06:56:31 +02:00
Christian Muehlhaeuser
8d06d2ca38 * Try to force empty TOMAHAWK_VERSION in CMake cache. 2011-07-20 06:55:08 +02:00
Christian Muehlhaeuser
bbe81050f3 * Fixed sparkle updating and introduced TomahawkUtils::appFriendlyVersion(). 2011-07-20 06:01:58 +02:00
Christian Muehlhaeuser
751b76948e * Show which version is build during CMake debug output. 2011-07-20 05:51:40 +02:00
Christian Muehlhaeuser
485b40b22b * Added branch name to version string. 2011-07-20 05:47:13 +02:00
Christian Muehlhaeuser
4c8ba931d3 * Stop temporary query timer after it's been triggered. 2011-07-20 05:22:37 +02:00
Christian Muehlhaeuser
463eb2bfd8 * And even more Pipeline cleanups. 2011-07-20 04:53:43 +02:00
Christian Muehlhaeuser
7ab0a3093e * Few debug cleanups in Pipeline. 2011-07-20 04:41:59 +02:00
Leo Franchi
dabbd38cc7 Handle resolver file paths becoming invalid properly. Show user file is not found, etc. 2011-07-19 22:27:02 -04:00
Christian Muehlhaeuser
efd7911efc * Fixed another pipeline bug. 2011-07-20 04:25:44 +02:00
Christian Muehlhaeuser
9b8d69a21f * Fixed assert bug in pipeline. 2011-07-20 03:59:02 +02:00
Christian Muehlhaeuser
b39029743e * Fixed painting tracks with foreign charsets in sidebar. 2011-07-20 02:32:20 +02:00
Christian Muehlhaeuser
b771a23e23 * Fixed checking date executable variable. 2011-07-20 02:05:16 +02:00
Christian Muehlhaeuser
ffd4ba4edf * Fixed TWK-243: Show git revision in version number. 2011-07-20 02:02:37 +02:00
Christian Muehlhaeuser
6bfbbce05f * Fixed TWK-279 - Play first track of a playlist if play is clicked and nothing is playing yet. 2011-07-20 01:52:19 +02:00
Christian Muehlhaeuser
4a3f157718 * Fixed GStreamer skipping to the next track on pausing. 2011-07-20 00:17:15 +02:00
Christian Muehlhaeuser
920b239dc1 * Removed some more debug output from resolvers. 2011-07-19 23:40:21 +02:00
Christian Muehlhaeuser
1a81a292fc * Remove obsolete debug output. 2011-07-19 23:34:59 +02:00
Christian Muehlhaeuser
066aac7e26 * Fixed not properly ending drag and drop operation when leaving the sidebar. 2011-07-19 23:33:35 +02:00
Christian Muehlhaeuser
ac726faf1b * Also release non-temporary queries in Pipeline. 2011-07-19 23:13:16 +02:00
Christian Muehlhaeuser
dc5c0394f7 * Release unused queries in Pipeline. 2011-07-19 22:53:35 +02:00
Christian Muehlhaeuser
4098cc2709 * PlaylistInterface now provides getSharedPointer(). AudioEngine makes use of it and doesn't crash when encountering a deleted playlist. 2011-07-19 17:54:10 +02:00
Christian Muehlhaeuser
63aa26f607 * Fixed init procedure: don't setup Servent before database and sources are loaded. 2011-07-17 01:02:32 +02:00
Jason Herskowitz
4238327ebc Added icon for info icon/arrow that takes you to artist or album page. 2011-07-16 15:49:39 -04:00
Jason Herskowitz
120ee995f1 Placeholder images for missing album art, user avatar and artist image. Also sidebar icon for Loved Tracks. 2011-07-16 15:43:00 -04:00
Jeff Mitchell
7d7650f97c Fix twitter copy and also size issues. Fixes TWK-209. 2011-07-16 13:36:59 -04:00
Jeff Mitchell
b5d5db434a Change infosystem timeout values 2011-07-14 14:10:04 -04:00
Leo Franchi
a4a274531c Fix shortcuts on OS X 2011-07-14 10:42:27 +02:00
Jeff Mitchell
3a1083d2b3 Insert some code which is most likely totally do-nothing in the
offchance it solves jherskowitz's random crash...
2011-07-12 18:00:55 -04:00
Jeff Mitchell
e79604b598 Modify qHash/criteriamd5 algorithm to guarantee order of adding values
to the md5sum, since order matters in md5 and isn't guaranteed by
default in a QHash.

Requires a cache clear, which is done automatically.
2011-07-12 17:51:27 -04:00
Jeff Mitchell
43a1b38a49 Fix some objects in cache being "lost", such as similar artists/top
artist songs
2011-07-12 16:38:16 -04:00
Jeff Mitchell
e83be2b9cd Fix stupid C&P mistake that broke scrobbling. 2011-07-12 12:01:00 -04:00
Christian Muehlhaeuser
fcfc344627 * Fixed JavaScript resolvers not working. 2011-07-12 01:10:37 +02:00
Jeff Mitchell
28d34a84ad Add a cache versioning system, and invalidate the cache in the upgrade
to version 1
2011-07-11 16:01:53 -04:00
Christian Muehlhaeuser
3bd6bd540f * Updated .gitignore. 2011-07-11 16:59:43 +02:00
Christian Muehlhaeuser
c35d7c964a * Removed some InfoSystem debug output. 2011-07-11 16:59:15 +02:00
Christian Muehlhaeuser
15805aa32c * Improved AlbumView and cover fetching in Artist / Album-Model. 2011-07-11 16:52:09 +02:00
Christian Muehlhaeuser
6f14277821 * Updated .gitignore. 2011-07-11 03:36:11 +02:00
Christian Muehlhaeuser
2d66feb5b2 * Fixed default flat collection view sorting. 2011-07-11 03:24:33 +02:00
Christian Muehlhaeuser
a6944c49ae * Hide the origin column in the default flat collection view. 2011-07-11 03:05:14 +02:00
Christian Muehlhaeuser
3ad6826779 * Fixed bogus column widths when loading a flat collection view. 2011-07-11 02:59:13 +02:00
Christian Muehlhaeuser
0e04e8970b * Try to force updates when hovered item in a TrackView changes. 2011-07-11 02:49:46 +02:00
Christian Muehlhaeuser
76af86dc4b * Added direct links to Artist / Album - pages in TrackView. 2011-07-11 02:02:32 +02:00
Christian Muehlhaeuser
3d289c0f77 * Added musicbrainz InfoPlugin to CMakeLists.txt 2011-07-09 02:12:01 +02:00
Christopher Reichert
d7ea7e3eee Doxygen documentation for DatabaseCommand_LoadSocialAction. 2011-07-08 13:26:28 -05:00
Leo Franchi
09be5a1a60 pita wip 2011-06-12 12:13:27 -04:00
Leo Franchi
298d0a08a0 Try harder to fix audiocontrol flickering 2011-06-12 11:05:13 -04:00
397 changed files with 10884 additions and 4697 deletions

3
.gitignore vendored
View File

@@ -11,7 +11,8 @@ moc_*
/tomahawk
thirdparty/qtweetlib/WARNING-twitter-api-keys
.kdev4
tomahawk.kdev4
*.kdev4
*.kate-swp
clang/
win/
gcc/

View File

@@ -1,6 +1,6 @@
PROJECT( tomahawk )
CMAKE_MINIMUM_REQUIRED( VERSION 2.8 )
SET( CMAKE_MODULE_PATH "${CMAKE_MODULE_PATH}" "${CMAKE_SOURCE_DIR}/CMakeModules" )
SET( CMAKE_MODULE_PATH "${CMAKE_CURRENT_SOURCE_DIR}/CMakeModules" )
IF( ${CMAKE_VERSION} VERSION_GREATER 2.8.3 )
CMAKE_POLICY(SET CMP0017 NEW)
@@ -15,28 +15,36 @@ SET( TOMAHAWK_APPLICATION_NAME "Tomahawk" )
SET( TOMAHAWK_DESCRIPTION_SUMMARY "The social media player" )
SET( TOMAHAWK_VERSION_MAJOR 0 )
SET( TOMAHAWK_VERSION_MINOR 1 )
SET( TOMAHAWK_VERSION_PATCH 0 )
SET( TOMAHAWK_VERSION_MINOR 2 )
SET( TOMAHAWK_VERSION_PATCH 2 )
# SET( TOMAHAWK_VERSION_RC 0 )
#SET( TOMAHAWK_VERSION_RC 0 )
IF( NOT CMAKE_BUILD_TYPE STREQUAL "Release" )
# Use the date as the tweak level.
INCLUDE( ${CMAKE_MODULE_PATH}/kwsysDateStamp.cmake )
SET( TOMAHAWK_VERSION_TWEAK "${KWSYS_DATE_STAMP_YEAR}${KWSYS_DATE_STAMP_MONTH}${KWSYS_DATE_STAMP_DAY}" )
INCLUDE( ${CMAKE_MODULE_PATH}/CMakeVersionSource.cmake )
ENDIF()
# build options
option(BUILD_GUI "Build Tomahawk with GUI" ON)
option(BUILD_RELEASE "Generate TOMAHAWK_VERSION without GIT info" OFF)
# generate version string
# base string used in release and unstable builds
SET( TOMAHAWK_VERSION ${TOMAHAWK_VERSION_MAJOR}.${TOMAHAWK_VERSION_MINOR}.${TOMAHAWK_VERSION_PATCH} )
IF( ${TOMAHAWK_VERSION_TWEAK} GREATER 0)
SET( TOMAHAWK_VERSION ${TOMAHAWK_VERSION}.${TOMAHAWK_VERSION_TWEAK} )
ENDIF()
IF( TOMAHAWK_VERSION_RC )
SET( CMake_VERSION ${TOMAHAWK_VERSION}-rc${TOMAHAWK_VERSION_RC} )
SET( TOMAHAWK_VERSION ${TOMAHAWK_VERSION}rc${TOMAHAWK_VERSION_RC} )
ENDIF()
IF( CMAKE_VERSION_SOURCE )
SET( TOMAHAWK_VERSION ${TOMAHAWK_VERSION}-${CMAKE_VERSION_SOURCE} )
# additional info for non-release builds
IF( NOT BUILD_RELEASE )
INCLUDE( CMakeDateStamp )
SET( TOMAHAWK_VERSION_DATE "${CMAKE_DATESTAMP_YEAR}${CMAKE_DATESTAMP_MONTH}${CMAKE_DATESTAMP_DAY}" )
IF( ${TOMAHAWK_VERSION_DATE} GREATER 0)
SET( TOMAHAWK_VERSION ${TOMAHAWK_VERSION}.${TOMAHAWK_VERSION_DATE} )
ENDIF()
INCLUDE( CMakeVersionSource )
IF( CMAKE_VERSION_SOURCE )
SET( TOMAHAWK_VERSION ${TOMAHAWK_VERSION}-${CMAKE_VERSION_SOURCE} )
ENDIF()
ENDIF()
@@ -48,33 +56,29 @@ SET( CMAKE_LIBRARY_OUTPUT_DIRECTORY "${CMAKE_BINARY_DIR}" )
SET( CMAKE_ARCHIVE_OUTPUT_DIRECTORY "${CMAKE_BINARY_DIR}" )
# installer creation
INCLUDE( CPack.cmake )
# Check if we need qtgui:
IF( "${gui}" STREQUAL "no" )
ADD_DEFINITIONS( -DENABLE_HEADLESS )
MESSAGE( STATUS "Building in HEADLESS mode ***" )
FIND_PACKAGE( Qt4 4.7.0 COMPONENTS QtCore QtXml QtNetwork REQUIRED )
ELSE()
MESSAGE( STATUS "Building full GUI version ***" )
FIND_PACKAGE( Qt4 4.7.0 COMPONENTS QtGui QtCore QtXml QtNetwork REQUIRED )
ENDIF()
INCLUDE( TomahawkCPack.cmake )
#deps
INCLUDE( MacroOptionalFindPackage )
INCLUDE( MacroLogFeature )
# required
#While we distribute our own liblastfm2, don't need to look for it
#macro_optional_find_package(LibLastFm 0.3.3)
#macro_log_feature(LIBLASTFM_FOUND "LastFm" "Qt library for the Last.fm webservices" "https://github.com/mxcl/liblastfm" FALSE "" "liblastfm is needed for scrobbling tracks to Last.fm and fetching cover artwork")
set(LIBLASTFM_FOUND true)
# Check if we need qtgui:
SET(NEEDED_QT4_COMPONENTS QtCore QtXml QtNetwork )
IF( NOT BUILD_GUI )
ADD_DEFINITIONS( -DENABLE_HEADLESS )
MESSAGE( STATUS "Building Tomahawk ${TOMAHAWK_VERSION} in HEADLESS mode ***" )
ELSE()
MESSAGE( STATUS "Building Tomahawk ${TOMAHAWK_VERSION} full GUI version ***" )
LIST(APPEND NEEDED_QT4_COMPONENTS "QtGui" "QtWebkit" )
ENDIF()
find_package(Phonon REQUIRED)
if(PHONON_VERSION STRLESS "4.5.0")
message(FATAL_ERROR "Phonon version 4.5.0 or higher is required, you have version ${PHONON_VERSION}")
else()
message(STATUS "Phonon found; ensure that phonon-vlc is at least 0.4")
macro_optional_find_package(Qt4 4.7.0 COMPONENTS ${NEEDED_QT4_COMPONENTS} )
macro_log_feature(QT4_FOUND "Qt" "A cross-platform application and UI framework" "http://qt.nokia.com" TRUE "" "If you see this, although libqt4-devel is installed, check whether \n the qtwebkit-devel package is installed as well")
macro_optional_find_package(Phonon 4.5.0)
macro_log_feature(PHONON_FOUND "Phonon" "The Phonon multimedia library" "http://phonon.kde.org" TRUE "" "")
if(PHONON_FOUND)
message(STATUS "Phonon found; ensure that phonon-vlc is at least 0.4")
endif()
macro_optional_find_package(LibEchonest 1.1.7)
@@ -88,6 +92,20 @@ macro_log_feature(QJSON_FOUND "QJson" "Qt library that maps JSON data to QVarian
macro_optional_find_package(Taglib 1.6.0)
macro_log_feature(TAGLIB_FOUND "TagLib" "Audio Meta-Data Library" "http://developer.kde.org/~wheeler/taglib.html" TRUE "" "taglib is needed for reading meta data from audio files")
include( CheckTagLibFileName )
check_taglib_filename( COMPLEX_TAGLIB_FILENAME )
macro_optional_find_package(Boost)
macro_log_feature(Boost_FOUND "Boost" "Provides free peer-reviewed portable C++ source libraries" "http://www.boost.org" TRUE "" "") #FIXME: give useful explaination
# required
#While we distribute our own liblastfm2, don't need to look for it
#macro_optional_find_package(LibLastFm 0.3.3)
#macro_log_feature(LIBLASTFM_FOUND "LastFm" "Qt library for the Last.fm webservices" "https://github.com/mxcl/liblastfm" FALSE "" "liblastfm is needed for scrobbling tracks to Last.fm and fetching cover artwork")
set(LIBLASTFM_FOUND true)
# this installs headers and such and should really be handled in a separate package by packagers
IF( INTERNAL_JREEN )
@@ -100,7 +118,7 @@ IF( INTERNAL_JREEN )
ELSE( INTERNAL_JREEN )
macro_optional_find_package(Jreen)
ENDIF( INTERNAL_JREEN )
macro_log_feature(LIBJREEN_FOUND "Jreen" "Qt XMPP Library" "http://gitorious.org/jreen/jreen" FALSE "" "Jreen is needed for the Jabber SIP plugin. \n\n Use -DINTERNAL_JREEN=ON to build the git submodule inside Tomahawk \n Be aware this installs a full jreen with headers and everything!\n")
macro_log_feature(LIBJREEN_FOUND "Jreen" "Qt XMPP Library" "https://github.com/euroelessar/jreen" FALSE "" "Jreen is needed for the Jabber SIP plugin. \n\n Use -DINTERNAL_JREEN=ON to build the git submodule inside Tomahawk \n Be aware this installs a full jreen with headers and everything!\n")
# this installs headers and such and should really be handled in a separate package by packagers
IF( INTERNAL_QTWEETLIB )
@@ -124,10 +142,16 @@ SET( LIBPORTFWD_LIBRARIES ${LIBPORTFWD_LIBRARY} )
ADD_SUBDIRECTORY( ${THIRDPARTY_DIR}/libportfwd )
# we need pthreads too
find_package(Threads)
macro_optional_find_package(Threads)
macro_log_feature(THREADS_FOUND "Threads" "Threading Library" "" TRUE "" "Platform specific library for threading")
find_package(KDE4Installed)
find_package(KDE4)
macro_optional_find_package(KDE4)
macro_optional_find_package(KDE4Installed)
# this was used before we had FindKDE4Installed, just leaving it here to keep the flags
# for future kde integration
# macro_optional_find_package(KDE4)
IF(KDE4_FOUND)
#KDE4 adds and removes some compiler flags that we don't like
STRING( REPLACE "-std=iso9899:1990" "" CLEAN_C_FLAGS ${CMAKE_C_FLAGS} )
@@ -136,9 +160,6 @@ ELSE()
SET( CLEAN_C_FLAGS ${CMAKE_C_FLAGS} )
ENDIF()
include( CheckTagLibFileName )
check_taglib_filename( COMPLEX_TAGLIB_FILENAME )
IF( WIN32 )
find_library(QTSPARKLE_LIBRARIES qtsparkle)
ENDIF( WIN32 )

View File

@@ -1,3 +1,5 @@
SET(WINDRES_EXECUTABLE ${CMAKE_RC_COMPILER})
# This macro is taken from kdelibs/cmake/modules/KDE4Macros.cmake.
#
# Copyright (c) 2006-2009 Alexander Neundorf, <neundorf@kde.org>

View File

@@ -0,0 +1,23 @@
find_program(DATE_EXECUTABLE NAMES date)
mark_as_advanced(DATE_EXECUTABLE)
if(DATE_EXECUTABLE)
execute_process(
COMMAND ${DATE_EXECUTABLE} +%Y
OUTPUT_VARIABLE CMAKE_DATESTAMP_YEAR
OUTPUT_STRIP_TRAILING_WHITESPACE
WORKING_DIRECTORY ${CMAKE_SOURCE_DIR}
)
execute_process(
COMMAND ${DATE_EXECUTABLE} +%m
OUTPUT_VARIABLE CMAKE_DATESTAMP_MONTH
OUTPUT_STRIP_TRAILING_WHITESPACE
WORKING_DIRECTORY ${CMAKE_SOURCE_DIR}
)
execute_process(
COMMAND ${DATE_EXECUTABLE} +%d
OUTPUT_VARIABLE CMAKE_DATESTAMP_DAY
OUTPUT_STRIP_TRAILING_WHITESPACE
WORKING_DIRECTORY ${CMAKE_SOURCE_DIR}
)
endif()

View File

@@ -5,13 +5,21 @@ if(EXISTS ${CMAKE_SOURCE_DIR}/.git/HEAD)
mark_as_advanced(GIT_EXECUTABLE)
if(GIT_EXECUTABLE)
execute_process(
COMMAND ${GIT_EXECUTABLE} rev-parse --verify -q --short=4 HEAD
COMMAND ${GIT_EXECUTABLE} rev-parse --verify -q --short=7 HEAD
OUTPUT_VARIABLE head
OUTPUT_STRIP_TRAILING_WHITESPACE
WORKING_DIRECTORY ${CMAKE_SOURCE_DIR}
)
if(head)
set(CMAKE_VERSION_SOURCE "g${head}")
set(branch "")
execute_process(
COMMAND ${GIT_EXECUTABLE} name-rev HEAD
OUTPUT_VARIABLE branch
OUTPUT_STRIP_TRAILING_WHITESPACE
WORKING_DIRECTORY ${CMAKE_SOURCE_DIR}
)
string(REGEX REPLACE "HEAD " "" branch "${branch}")
set(CMAKE_VERSION_SOURCE "git-${branch}-${head}")
execute_process(
COMMAND ${GIT_EXECUTABLE} update-index -q --refresh
WORKING_DIRECTORY ${CMAKE_SOURCE_DIR}

View File

@@ -12,9 +12,12 @@
INCLUDE(CheckSymbolExists)
INCLUDE(FindLibraryWithDebug)
if(NOT CLUCENE_MIN_VERSION)
set(CLUCENE_MIN_VERSION "0.9.23")
endif(NOT CLUCENE_MIN_VERSION)
IF(CLucene_FIND_VERSION)
SET(CLUCENE_MIN_VERSION ${CLucene_FIND_VERSION})
ELSEIF()
SET(CLUCENE_MIN_VERSION "0.9.23")
ENDIF(CLucene_FIND_VERSION)
IF(EXISTS ${PROJECT_CMAKE}/CLuceneConfig.cmake)
INCLUDE(${PROJECT_CMAKE}/CLuceneConfig.cmake)

View File

@@ -38,14 +38,14 @@ else(PHONON_FOUND)
find_path(PHONON_INCLUDE_DIR NAMES phonon/phonon_export.h PATHS ${KDE4_INCLUDE_INSTALL_DIR} ${QT_INCLUDE_DIR} ${INCLUDE_INSTALL_DIR} ${QT_LIBRARY_DIR})
find_path(PHONON_INCLUDE_DIR NAMES phonon/phonon_export.h)
if(PHONON_INCLUDE_DIR AND PHONON_LIBRARY)
_phonon_find_version()
if(PHONON_INCLUDE_DIR AND PHONON_LIBRARY AND NOT PHONON_VERSION VERSION_LESS ${Phonon_FIND_VERSION})
set(PHONON_LIBS ${phonon_LIB_DEPENDS} ${PHONON_LIBRARY})
set(PHONON_INCLUDES ${PHONON_INCLUDE_DIR}/KDE ${PHONON_INCLUDE_DIR})
set(PHONON_FOUND TRUE)
_phonon_find_version()
else(PHONON_INCLUDE_DIR AND PHONON_LIBRARY)
else(PHONON_INCLUDE_DIR AND PHONON_LIBRARY AND NOT PHONON_VERSION VERSION_LESS ${Phonon_FIND_VERSION})
set(PHONON_FOUND FALSE)
endif(PHONON_INCLUDE_DIR AND PHONON_LIBRARY)
endif(PHONON_INCLUDE_DIR AND PHONON_LIBRARY AND NOT PHONON_VERSION VERSION_LESS ${Phonon_FIND_VERSION})
if(PHONON_FOUND)
if(NOT PHONON_FIND_QUIETLY)

View File

@@ -21,19 +21,22 @@
!define MING_BIN "${MING_PATH}/bin"
!define MING_LIB "${MING_PATH}/lib"
!define BUILD_PATH "@CMAKE_BINARY_DIR@"
!define SOURCE_PATH "@CMAKE_SOURCE_DIR@"
!define QT_DLL_PATH "${MING_BIN}"
!define SQLITE_DLL_PATH "${MING_LIB}/qt4/plugins/sqldrivers"
!define IMAGEFORMATS_DLL_PATH "${MING_LIB}/qt4/plugins/imageformats"
!define VLC_PLUGIN_PATH "${MING_LIB}\vlc\plugins"
!define NSI_PATH "@CMAKE_SOURCE_DIR@/admin/win/nsi"
; We use official release plugins
; mingw32-vlc from obs misses a lot and has even broken ones probably
!define VLC_PATH "${SOURCE_PATH}\admin\win\vlc\prefix" ; SIC! ^
!define VLC_BIN "${VLC_PATH}\bin"
!define VLC_PLUGIN_PATH "${VLC_BIN}\plugins"
!define NSI_PATH "${SOURCE_PATH}/admin/win/nsi"
;-----------------------------------------------------------------------------
; Increment installer revision number as part of this script.
; Installer version
;-----------------------------------------------------------------------------
!define /file REVISION_LAST ${NSI_PATH}/revision.txt
!define /math REVISION ${REVISION_LAST} + 1
!delfile revision.txt
!appendfile revision.txt ${REVISION}
!define VER_MAJOR "@CPACK_PACKAGE_VERSION_MAJOR@"
!define VER_MINOR "@CPACK_PACKAGE_VERSION_MINOR@"
@@ -43,7 +46,7 @@
;-----------------------------------------------------------------------------
; Installer build timestamp.
;-----------------------------------------------------------------------------
!define /date BUILD_TIME "built on %Y/%m/%d at %I:%M %p (rev. ${REVISION})"
!define /date BUILD_TIME "built on %Y/%m/%d at %I:%M %p"
;-----------------------------------------------------------------------------
; Initial installer setup and definitions.
@@ -90,7 +93,7 @@ ReserveFile "${NSISDIR}\Plugins\InstallOptions.dll"
!define MUI_ICON ${NSI_PATH}\installer.ico
!define MUI_UNICON ${NSI_PATH}\installer.ico
!define MUI_WELCOMEFINISHPAGE_BITMAP ${NSI_PATH}\welcome.bmp
!define MUI_WELCOMEPAGE_TITLE "@CPACK_PACKAGE_NAME@ ${VERSION} Setup$\r$\nInstaller Build Revision ${REVISION}"
!define MUI_WELCOMEPAGE_TITLE "@CPACK_PACKAGE_NAME@ ${VERSION} Setup$\r$\nInstaller"
!define MUI_WELCOMEPAGE_TEXT "This wizard will guide you through the installation.$\r$\n$\r$\n$_CLICK"
!define MUI_HEADERIMAGE
!define MUI_HEADERIMAGE_BITMAP ${NSI_PATH}\page_header.bmp
@@ -200,10 +203,7 @@ Function PageReinstall
IntCmp $R0 ${VER_MINOR} build_check new_version older_version
build_check:
ReadRegDWORD $R0 HKLM "Software\Tomahawk" "VersionBuild"
IntCmp $R0 ${VER_BUILD} revision_check new_version older_version
revision_check:
ReadRegDWORD $R0 HKLM "Software\Tomahawk" "VersionRevision"
IntCmp $R0 ${REVISION} same_version new_version older_version
IntCmp $R0 ${VER_BUILD} same_version new_version older_version
new_version:
!insertmacro INSTALLOPTIONS_WRITE "NSIS.InstallOptions.ini" "Field 1" "Text" "An older version of Tomahawk is installed on your system. It is recommended that you uninstall the current version before installing. Select the operation you want to perform and click Next to continue."
@@ -327,15 +327,15 @@ Section "Tomahawk Player" SEC_TOMAHAWK_PLAYER
File "${MING_BIN}\libdbus-1-3.dll"
File "${MING_BIN}\dbus-daemon.exe"
File "${MING_BIN}\libphonon.dll"
File "${VLC_BIN}\libphonon.dll"
SetOutPath "$INSTDIR\phonon_backend"
File "${MING_BIN}\phonon_backend\phonon_vlc.dll"
File "${VLC_BIN}\phonon_backend\phonon_vlc.dll"
SetOutPath "$INSTDIR"
;VLC
;SetOutPath "$INSTDIR\phonon_backend"
File "${MING_BIN}\libvlc.dll"
File "${MING_BIN}\libvlccore.dll"
File "${VLC_BIN}\libvlc.dll"
File "${VLC_BIN}\libvlccore.dll"
SetOutPath "$INSTDIR\plugins"
File /r "${VLC_PLUGIN_PATH}\*.dll"
SetOutPath "$INSTDIR"

View File

@@ -1,21 +0,0 @@
# Do not edit! Generated by kwsysDateStamp.py
#=============================================================================
# KWSys - Kitware System Library
# Copyright 2000-2009 Kitware, Inc., Insight Software Consortium
#
# Distributed under the OSI-approved BSD License (the "License");
# see accompanying file Copyright.txt for details.
#
# This software is distributed WITHOUT ANY WARRANTY; without even the
# implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
# See the License for more information.
#=============================================================================
# KWSys version date year component. Format is CCYY.
SET(KWSYS_DATE_STAMP_YEAR 2011)
# KWSys version date month component. Format is MM.
SET(KWSYS_DATE_STAMP_MONTH 07)
# KWSys version date day component. Format is DD.
SET(KWSYS_DATE_STAMP_DAY 06)

View File

@@ -3,6 +3,10 @@
# in this file.
if(CPACK_GENERATOR MATCHES "NSIS")
if( NOT EXISTS "@CMAKE_SOURCE_DIR@/admin/win/vlc/")
MESSAGE(FATAL_ERROR "\n You don't have vlc in your admin/win/ dir. \n Please change into that dir and execute 'sh update-vlc.sh'" )
endif()
#SET(CPACK_NSIS_INSTALL_ROOT "@CPACK_NSIS_INSTALL_ROOT@")
# set the install/unistall icon used for the installer itself

View File

@@ -1,22 +1,97 @@
Version 0.2.2:
* Fixed crash when pressing previous and next when playing a song from the Queue.
* Fixed issue where wrench for newly added resolvers would not show up immediately.
* Fixed sidebar statistics not updating after collection scan finished.
* Fixed omitting a few tracks in the Collection tree-view.
* Fixed sidebar & track sorting issues.
* Seek- & volume sliders now directly jump to the position you clicked on.
* Added ability to drag artists and albums within Tomahawk (to playlists, queue, etc.).
Version 0.2.1:
* Fixed crashing trying to play an unavailable track.
* Fixed a crash caused by using Javascript resolvers.
* Fixed searching with Javascript resolvers.
Version 0.2.0:
* Re-resolve queries when their resolved-to source goes offline.
* Cleanup formatting of Preference/Configure and Diagnostics windows.
* Add selection indicator on album art.
* Fix inability to create Echonest playlists based solely on style or mood.
* Created new Artist & Album page, showing various related information.
* Update playlists in dashboard to keep them in sync.
* Support Rdio track URLs and ability to drop them onto Tomahawk.
* Change "Recently Played" page to "Dashboard".
* Prioritize resolving newer queries to make GUI more responsive.
* Automatically expand local collection node in sidebar on launch.
* Display spinner animation while searching for tracks.
* Let Tomahawk-headless users trigger a rescan with --filescan.
* Include Stations and Automatic Playlists in "New Stations and Playlists".
* Always keep current page and sidebar selection in sync.
* New icon theme and many design tweaks.
* Fixed bug where drop indicator wouldn't show below the last track of a
playlist.
* Added support for "playing" Spotify track URLs (and t.co and bit.ly
shortened track URLs) and ability to drag/drop them into Tomahawk.
* Added support for JSPF playlists (XSPF via JSON).
* Scroll per pixel to making scrolling feel more natural.
* Filter out duplicate tracks in Collection tree view.
* Spotify resolver now honors SOCKS5 proxy settings.
* Made "show offline sources" menu option a toggle instead of two separate
entries.
* Properly decode escaped characters coming from HTTP API.
* Handle/display resolver file paths becoming invalid in Preferences.
* Fixed track skipping-on-pause bug when using Gstreamer backend.
* Fixed a few crashes that could occur when fetching data from Last.fm.
* Made Twitter dialog more readable/understandable.
* Fixed streaming from https:// links.
* Implement new Javascript resolver API and ability to present config
dialogs for resolvers.
* Show when a track was played in the Recently Played tracks history.
* Added context menus for Artists and Albums.
* Fixed playlist bugs that would cause track to stop playing when dropping
or moving items in the same playlist.
* Set volume to 75% on startup.
* Added "listen along" feature (and ability to "catch up").
* Added "love" feature - also "loves" track on Last.fm.
* Twitter checks for updates less often now, saving user API calls from
running out when using multiple clients.
* Added score column and score bars to indicate resolver match certainty.
* Added "New Additions" page for each source.
* Improved tomahawk:// link handling. Added support for http://toma.hk/.
* Fixed sorting by file size.
* Improved the way Adium status is updated with now-playing information.
* Re-resolve tracks when a resolver is added/removed/enabled/disabled.
* Added global search function that searches all available sources.
* Collection scanner can now run automatically, watching files and dirs for
changes.
* Added Pipeline status view.
* Allow seeking in songs - if supported by audio backend.
* Added ability to make a copy of a peer's playlist.
* Shuffle and Repeat settings are stored on a playlist by playlist basis.
* (Linux) Desktop notifications for now playing.
* (OS X) Removed "test login" button from Last.fm settings.
* (OS X) Added MediaKey support.
* (OS X) Don't quit on window close to conform to best practices.
Version 0.1.0:
* Fixed stations so they resolve against all available sources instead of
only local and friend's collections.
* Add a Song seed for stations and automatic playlists, and allow dragging of
any tracks to the New Stations entry to create a pre-seeded station.
* Add a Song seed for stations and automatic playlists, and allow dragging
of any tracks to the New Stations entry to create a pre-seeded station.
* Added auto-completion for artists while filling in a station or automatic
playlist.
* SOCKS5 proxy support. Noproxy hosts are also supported but no wildcard
support (yet).
* Support loading of - and exporting to - .xspf playlists
* Added Tomahawk:// protocol support and share links for many things including
tracks, playlists, and stations.
* Support loading of - and exporting to - .xspf playlists.
* Added Tomahawk:// protocol support and share links for many things
including tracks, playlists, and stations.
* Autoload automatically detected resolvers on startup.
* Fix issue where track resolving spinner never stopped if tracks were
removed from playlist while resolving.
* Twitter & Jabber profile pictures are shown.
* Fix issues with stations where multiple tracks could be added at once.
* Allow multiple accounts of the same type.
* Add new Google account type that is a thin wrapper around a Jabber plugin.
* Add new Google account type, a thin wrapper around a Jabber plugin.
* Overhaul the settings dialog interface.
* Resolvers can now be enabled and disabled, and some can be configured
directly in Tomahawk, for example the new Spotify resolver.
@@ -24,21 +99,21 @@ Version 0.1.0:
as a node under the Super Collection.
* Fix massive speed bottleneck on startup in the case of many recently
played playlists.
* Removed filter and song view from Super Collection, coming back in the next
release.
* Removed filter and song view from Super Collection, coming back in the
next release.
* Browse and play collections in our snappy tree-mode, which also shows
images for artists and albums.
* Fixed crash that could occur when playing a track from a browser.
* Fixed a crash caused by sources going on or offline.
* Huge optimizations in the resolving pipeline.
* Improved the handling of automatic status messages for Google Talk
* Improved the handling of automatic status messages for Google Talk.
* Switch to Phonon sound system, allowing us to support a wide variety
of audio formats.
* UI tweaks and cleanup.
* (OS X) Open configuration dialogs as sliding sheets.
* (OS X) Increase our available file watches to the maximum that the system
reports.
* (OS X) Added 'Window' menu with zoom/minimize actions
* (OS X) Added 'Window' menu with zoom/minimize actions.
Version 0.0.3:
* Show spinner while resolving playlists.
@@ -57,8 +132,9 @@ Version 0.0.3:
* Faster painting of playlists with lots of unresolved tracks.
* Prefer local results when results' score is equal.
* (Windows) The tomahawk:// protocol handler works on Windows now.
* (Windows) Fixed launching Tomahawk from Windows installer with admin privileges.
* (Windows) Prevent launching a second instance on Windows.
* (Windows) Fixed launching Tomahawk from Windows installer with admin
privileges.
Version 0.0.2:
* Don't reconnect to Jabber if the settings dialog is closed successfully

View File

@@ -1,5 +1,5 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple Computer//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>CFBundleDevelopmentRegion</key>
@@ -23,40 +23,42 @@
<key>CFBundleName</key>
<string>Tomahawk</string>
<key>LSMinimumSystemVersion</key>
<string>10.5.0</string>
<key>SUFeedURL</key>
<string>http://download.tomahawk-player.org/sparkle</string>
<key>SUPublicDSAKeyFile</key>
<string>sparkle_pub.pem</string>
<key>CFBundleURLTypes</key>
<array>
<dict>
<key>CFBundleURLName</key>
<string>Tomahawk URL</string>
<key>CFBundleURLSchemes</key>
<array>
<string>tomahawk</string>
</array>
</dict>
</array>
<key>CFBundleDocumentTypes</key>
<array>
<dict>
<key>CFBundleTypeExtensions</key>
<array>
<string>xspf</string>
</array>
<key>CFBundleTypeIconFile</key>
<string>Generic.icns</string>
<key>CFBundleTypeMIMETypes</key>
<array>
<string>application/xspf+xml</string>
</array>
<key>CFBundleTypeName</key>
<string>XSPF Playlist</string>
<key>CFBundleTypeRole</key>
<string>Viewer</string>
</dict>
</array>
<string>10.5.0</string>
<key>SUFeedURL</key>
<string>http://download.tomahawk-player.org/sparkle/update.php</string>
<key>SUPublicDSAKeyFile</key>
<string>sparkle_pub.pem</string>
<key>SUEnableSystemProfiling</key>
<true/>
<key>CFBundleURLTypes</key>
<array>
<dict>
<key>CFBundleURLName</key>
<string>Tomahawk URL</string>
<key>CFBundleURLSchemes</key>
<array>
<string>tomahawk</string>
</array>
</dict>
</array>
<key>CFBundleDocumentTypes</key>
<array>
<dict>
<key>CFBundleTypeExtensions</key>
<array>
<string>xspf</string>
</array>
<key>CFBundleTypeIconFile</key>
<string>Generic.icns</string>
<key>CFBundleTypeMIMETypes</key>
<array>
<string>application/xspf+xml</string>
</array>
<key>CFBundleTypeName</key>
<string>XSPF Playlist</string>
<key>CFBundleTypeRole</key>
<string>Viewer</string>
</dict>
</array>
</dict>
</plist>

View File

@@ -1,64 +0,0 @@
#!/bin/sh
# author: max@last.fm
# usage: Run from inside the bundle root directory, eg. Last.fm.app
# The first parameter should be the QtFrameworks to copy.
# Remaining parameters are plugins to copy, directories and files are
# valid.
# eg: add-Qt-to-bundle.sh 'QtCore QtGui QtXml' \
# imageformats \
# sqldrivers/libsqlite.dylib
################################################################################
QT_FRAMEWORKS_DIR="$QTDIR/lib"
QT_PLUGINS_DIR="$QTDIR/plugins"
if [[ ! -d "$QTDIR/lib/QtCore.framework" ]]
then
# this dir is the location of install for the official Trolltech dmg
if [[ -d /Library/Frameworks/QtCore.framework ]]
then
QT_FRAMEWORKS_DIR=/Library/Frameworks
QT_PLUGINS_DIR=/Developer/Applications/Qt/plugins
fi
fi
echo "Plugins go to: $QT_PLUGINS_DIR"
if [ -z $QTDIR ]
then
echo QTDIR must be set, or install the official Qt dmg
exit 1
fi
################################################################################
#first frameworks
mkdir -p Contents/Frameworks
for x in $1
do
echo "C $x"
cp -R $QT_FRAMEWORKS_DIR/$x.framework Contents/Frameworks/
chmod -R u+rw Contents/Frameworks/
done
#plugins
shift
mkdir -p Contents/MacOS
mkdir -p Contents/MacOS/sqldrivers
mkdir -p Contents/MacOS/imageformats
mkdir -p Contents/MacOS/phonon_backend
mkdir -p Contents/MacOS/crypto
cp -R $QT_PLUGINS_DIR/sqldrivers/libqsqlite.dylib Contents/MacOS/sqldrivers/
cp -R $QT_PLUGINS_DIR/imageformats/libqgif.dylib Contents/MacOS/imageformats/
cp -R $QT_PLUGINS_DIR/imageformats/libqjpeg.dylib Contents/MacOS/imageformats/
cp -R $QT_PLUGINS_DIR/imageformats/libqico.dylib Contents/MacOS/imageformats/
cp -R $QT_PLUGINS_DIR/imageformats/libqmng.dylib Contents/MacOS/imageformats/
#cp -R $QT_PLUGINS_DIR/imageformats/libqsvg.dylib Contents/MacOS/imageformats/
#cp -R $QT_PLUGINS_DIR/imageformats/libqtiff.dylib Contents/MacOS/imageformats/
cp -R $QT_PLUGINS_DIR/crypto/libqca-ossl.dylib Contents/MacOS/crypto/
cp -R $QT_PLUGINS_DIR/phonon_backend/phonon_vlc.so Contents/MacOS/phonon_backend/
#cleanup
find Contents/Frameworks -name Headers -o -name \*.prl -o -name \*_debug | xargs rm -rf
find Contents -name \*_debug -o -name \*_debug.dylib | xargs rm

View File

@@ -1,16 +0,0 @@
#!/bin/sh
# author: lfranchi@kde.org
# usage: Run from inside the bundle root directory, eg. Tomahawk.app
# The first parameter should be the spotify resolver binary to copy.
# eg: add-spotify.sh /path/to/spotify_tomahawkresolver
################################################################################
mkdir -p Contents/Frameworks
cp -R /Library/Frameworks/libspotify.framework Contents/Frameworks
install_name_tool -change /usr/local/Cellar/qt/4.7.3/lib/QtCore.framework/Versions/4/QtCore @executable_path/../Frameworks/QtCore.framework/Versions/4/QtCore $1
install_name_tool -change /usr/local/Cellar/qt/4.7.3/lib/QtNetwork.framework/Versions/4/QtNetwork @executable_path/../Frameworks/QtNetwork.framework/Versions/4/QtNetwork $1
install_name_tool -change libqjson.0.dylib @executable_path/libqjson.0.7.1.dylib $1
install_name_tool -change /usr/local/Cellar/qjson/0.7.1/lib/libqjson.0.7.1.dylib @executable_path/libqjson.0.7.1.dylib $1
mkdir -p Contents/MacOS
cp $1 Contents/MacOS/

View File

@@ -23,65 +23,28 @@ then
fi
ROOT=`pwd`
QTDIR=`which qmake`
LINKDIR=`readlink $QTDIR`
QTDIR=`dirname $QTDIR`
QTDIR=$QTDIR/`dirname $LINKDIR`
QTDIR=`dirname $QTDIR`
test -L "$QTDIR" && QTDIR=`readlink $QTDIR`
echo "Goes here: $QTDIR"
export QMAKESPEC='macx-g++'
export QTDIR
export VERSION
export QTVERSION='4.7.3'
################################################################################
CLEAN='1'
BUILD='1'
NOTQUICK='1'
CREATEDMG='1'
VERSION=$1
header "Adding Qt to app bundle"
cd tomahawk.app
$ROOT/../admin/mac/add-Qt-to-bundle.sh \
'QtCore QtGui QtXml QtNetwork QtSql QtXmlPatterns QtWebKit phonon'
# 'QtCore QtGui QtXml QtNetwork QtSql QtXmlPatterns QtWebKit QtDbus phonon'
################################################################################
header "Renaming files"
mv tomahawk.app Tomahawk.app
mv Tomahawk.app/Contents/MacOS/tomahawk Tomahawk.app/Contents/MacOS/Tomahawk
header "Fixing and copying libraries"
$ROOT/../admin/mac/macdeploy.py Tomahawk.app quiet
cd Tomahawk.app
header "Renaming icon"
mv Contents/Resources/tomahawkSources.icns Contents/Resources/Tomahawk.icns
mv Contents/MacOS/tomahawk Contents/MacOS/Tomahawk
# cp $ROOT/../admin/mac/Info.plist Contents/Info.plist
cp $ROOT/../admin/mac/qt.conf Contents/Resources/qt.conf
header "Copying VLC plugins into bundle"
mkdir -p Contents/plugins
cp -R /usr/local/Cellar/vlc-git/HEAD/lib/vlc/plugins/ Contents/plugins
rm -rf Contents/plugins/video_* Contents/plugins/gui Contents/plugins/*/libold* Contents/plugins/*/libvcd* Contents/plugins/*/libdvd* \
Contents/plugins/*/liblibass* Contents/plugins/*/libx264* Contents/plugins/*/libschroe* Contents/plugins/*/liblibmpeg2* \
Contents/plugins/*/libstream_out_* Contents/plugins/*/libmjpeg_plugin* Contents/plugins/*/libh264_plugin* Contents/plugins/*/libzvbi_plugin* Contents/plugins/*/lib*sub*
header "Running install_name_tool"
$ROOT/../admin/mac/deposx.sh
header "Copying Sparkle pubkey & framework, and qt.conf"
cp $ROOT/../admin/mac/sparkle_pub.pem Contents/Resources
header "Copying Sparkle framework"
cp -R /Library/Frameworks/Sparkle.framework Contents/Frameworks
cp $ROOT/../admin/mac/qt.conf Contents/Resources
header "Adding spotify resolver to bundle if spotify_tomahawkresolver found in $ROOT"
if [ -e $ROOT/spotify_tomahawkresolver ]
then
header "Found, so adding spotify resolver."ac
$ROOT/../admin/mac/add-spotify.sh $ROOT/spotify_tomahawkresolver
fi
header "Creating DMG"
cd ..
mv tomahawk.app Tomahawk.app
$ROOT/../admin/mac/create-dmg.sh Tomahawk.app
mv Tomahawk.dmg Tomahawk-$VERSION.dmg

View File

@@ -1,169 +0,0 @@
#!/bin/sh
# author: max@last.fm, chris@last.fm
################################################################################
if [ -z $QTDIR ]
then
echo QTDIR must be set
exit 1
fi
if [ -z $QTVERSION ]
then
echo QTVERSION must be set
exit 1
fi
cd ..
ORIGROOT=`pwd`
cd -
cd Contents
QTLIBS=`ls Frameworks | cut -d. -f1`
LIBS=`cd MacOS && ls -fR1 | grep dylib`
PLUGINFOLDERS=`ls plugins | cut -d. -f1`
################################################################################
function import_lib
{
echo "L \`$1'"
cp -R -L $1 MacOS/`basename $1`
chmod u+rw MacOS/`basename $1`
deplib_change MacOS/`basename $1`
deposx_change MacOS/`basename $1`
}
function deposx_change
{
echo "D \`$1'"
echo $QTDIR
for y in $QTLIBS
do
install_name_tool -change $QTDIR/lib/$y.framework/Versions/4/$y \
@executable_path/../Frameworks/$y.framework/Versions/4/$y \
"$1"
install_name_tool -change /usr/local/Cellar/qt/$QTVERSION/lib/$y.framework/Versions/4/$y \
@executable_path/../Frameworks/$y.framework/Versions/4/$y \
"$1"
install_name_tool -change /usr/X11/lib/libpng12.0.dylib \
@executable_path/libpng12.0.dylib \
"$1"
done
for y in $LIBS
do
install_name_tool -change $y \
@executable_path/$y \
"$1"
done
}
function deplib_change
{
install_name_tool -change /usr/local/Cellar/qjson/0.7.1/lib/libqjson.0.7.1.dylib @executable_path/libqjson.0.7.1.dylib $1
install_name_tool -change /usr/local/lib/libechonest.1.1.dylib @executable_path/libechonest.1.1.dylib $1
install_name_tool -change /usr/local/lib/libclucene-core.1.dylib @executable_path/libclucene-core.1.dylib $1
install_name_tool -change /usr/local/lib/libclucene-shared.1.dylib @executable_path/libclucene-shared.1.dylib $1
install_name_tool -change /usr/local/Cellar/taglib/1.7/lib/libtag.1.7.0.dylib @executable_path/libtag.1.7.0.dylib $1
# install_name_tool -change /usr/local/Cellar/gloox/1.0/lib/libgloox.8.dylib @executable_path/libgloox.8.dylib $1
# install_name_tool -change /usr/local/Cellar/libogg/1.2.0/lib/libogg.0.dylib @executable_path/libogg.0.dylib $1
# install_name_tool -change /usr/local/Cellar/libvorbis/1.3.1/lib/libvorbis.0.dylib @executable_path/libvorbis.0.dylib $1
# install_name_tool -change /usr/local/Cellar/libvorbis/1.3.1/lib/libvorbisfile.3.dylib @executable_path/libvorbisfile.3.dylib $1
# install_name_tool -change /usr/local/Cellar/mad/0.15.1b/lib/libmad.0.dylib @executable_path/libmad.0.dylib $1
# install_name_tool -change /usr/local/Cellar/flac/1.2.1/lib/libFLAC++.6.dylib @executable_path/libFLAC++.6.dylib $1
# install_name_tool -change /usr/local/Cellar/flac/1.2.1/lib/libFLAC.8.dylib @executable_path/libFLAC.8.dylib $1
install_name_tool -change /usr/local/Cellar/kde-phonon/4.5.0/lib/libphonon.4.dylib @executable_path/libphonon.4.dylib $1
install_name_tool -change /usr/local/Cellar/kde-phonon/4.5.0/lib/libphonon.4.5.0.dylib @executable_path/libphonon.4.dylib $1
install_name_tool -change $ORIGROOT/libtomahawklib.dylib @executable_path/libtomahawklib.dylib $1
install_name_tool -change $ORIGROOT/libtomahawk_sipjabber.dylib @executable_path/libtomahawk_sipjabber.dylib $1
install_name_tool -change $ORIGROOT/libtomahawk_sipgoogle.dylib @executable_path/libtomahawk_sipgoogle.dylib $1
install_name_tool -change $ORIGROOT/libtomahawk_siptwitter.dylib @executable_path/libtomahawk_siptwitter.dylib $1
install_name_tool -change $ORIGROOT/libtomahawk_sipzeroconf.dylib @executable_path/libtomahawk_sipzeroconf.dylib $1
install_name_tool -change $ORIGROOT/libtomahawk_qtweetlib.dylib @executable_path/libtomahawk_qtweetlib.dylib $1
install_name_tool -change $ORIGROOT/libtomahawk_portfwd.dylib @executable_path/libtomahawk_portfwd.dylib $1
install_name_tool -change $ORIGROOT/libjreen.dylib @executable_path/libjreen.dylib $1
install_name_tool -change /usr/local/Cellar/jreen/HEAD/lib/libjreen.dylib @executable_path/libjreen.dylib $1
install_name_tool -change /usr/local/Cellar/qca/2.0.2/lib/qca.framework/Versions/2/qca @executable_path/../Frameworks/qca.framework/Versions/2/qca $1
install_name_tool -change /usr/local/Cellar/gettext/0.18.1.1/lib/libintl.8.dylib @executable_path/libintl.8.dylib $1
install_name_tool -change /usr/local/Cellar/vlc-git/HEAD/lib/libvlc.5.dylib @executable_path/libvlc.5.dylib $1
install_name_tool -change /usr/local/Cellar/vlc-git/HEAD/lib/libvlccore.4.dylib @executable_path/libvlccore.4.dylib $1
install_name_tool -change libqjson.0.dylib @executable_path/libqjson.0.7.1.dylib $1
install_name_tool -change libechonest.1.1.dylib @executable_path/libechonest.1.1.dylib $1
install_name_tool -change libclucene-core.1.dylib @executable_path/libclucene-core.1.dylib $1
install_name_tool -change libclucene-shared.1.dylib @executable_path/libclucene-shared.1.dylib $1
}
################################################################################
# first all libraries and executables
find MacOS -type f -a -perm -100 | while read x
do
echo $x
y=$(file "$x" | grep 'Mach-O')
deposx_change "$x"
deplib_change "$x"
done
import_lib /usr/local/Cellar/qjson/0.7.1/lib/libqjson.0.7.1.dylib
import_lib /usr/local/Cellar/taglib/1.7/lib/libtag.1.7.0.dylib
#import_lib /usr/local/Cellar/gloox/1.0/lib/libgloox.8.dylib
#import_lib /usr/local/Cellar/libogg/1.2.0/lib/libogg.0.dylib
#import_lib /usr/local/Cellar/libvorbis/1.3.1/lib/libvorbis.0.dylib
#import_lib /usr/local/Cellar/libvorbis/1.3.1/lib/libvorbisfile.3.dylib
#import_lib /usr/local/Cellar/mad/0.15.1b/lib/libmad.0.dylib
#import_lib /usr/local/Cellar/flac/1.2.1/lib/libFLAC++.6.dylib
#import_lib /usr/local/Cellar/flac/1.2.1/lib/libFLAC.8.dylib
import_lib /usr/local/lib/libechonest.1.1.dylib
import_lib /usr/local/lib/libclucene-core.1.dylib
import_lib /usr/local/lib/libclucene-shared.1.dylib
import_lib /usr/local/Cellar/kde-phonon/4.5.0/lib/libphonon.4.dylib
import_lib /usr/local/Cellar/vlc-git/HEAD/lib/libvlc.5.dylib
import_lib /usr/local/Cellar/vlc-git/HEAD/lib/libvlccore.4.dylib
import_lib /usr/local/Cellar/gettext/0.18.1.1/lib/libintl.8.dylib
import_lib /usr/X11/lib/libpng12.0.dylib
import_lib $ORIGROOT/libjreen.dylib
import_lib $ORIGROOT/libtomahawklib.dylib
import_lib $ORIGROOT/libtomahawk_sipjabber.dylib
import_lib $ORIGROOT/libtomahawk_sipgoogle.dylib
import_lib $ORIGROOT/libtomahawk_siptwitter.dylib
import_lib $ORIGROOT/libtomahawk_sipzeroconf.dylib
import_lib $ORIGROOT/libtomahawk_qtweetlib.dylib
import_lib $ORIGROOT/libtomahawk_portfwd.dylib
cp -R /usr/local/Cellar/qca/2.0.2/lib/qca.framework Frameworks/
chmod 644 Frameworks/qca.framework/Versions/2/qca
deplib_change Frameworks/qca.framework/Versions/2/qca
deposx_change Frameworks/qca.framework/Versions/2/qca
# now Qt
for x in $QTLIBS
do
echo `pwd`
# ls -l Frameworks/$x.framework/Versions/4/$x
deposx_change Frameworks/$x.framework/Versions/4/$x
install_name_tool -id @executable_path/../Frameworks/$x.framework/Versions/4/$x \
Frameworks/$x.framework/Versions/4/$x
deplib_change "Frameworks/$x.framework/Versions/4/$x"
done
# now VLC plugins
for x in plugins/$PLUGINFOLDERS
do
for plugin in `ls plugins/$x | cut -f1`
do
echo "Fixing VLC plugin: $plugin"
chmod 644 plugins/$x/$plugin
deplib_change plugins/$x/$plugin
done
done

517
admin/mac/macdeploy.py Executable file
View File

@@ -0,0 +1,517 @@
#!/usr/bin/python
# This file is part of Clementine.
#
# Clementine is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# (at your option) any later version.
#
# Clementine is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with Clementine. If not, see <http://www.gnu.org/licenses/>.
import os
import re
import subprocess
import sys
FRAMEWORK_SEARCH_PATH=[
'/Library/Frameworks',
os.path.join(os.environ['HOME'], 'Library/Frameworks')
]
LIBRARY_SEARCH_PATH=['/usr/local/lib', '/usr/local/Cellar/gettext/0.18.1.1/lib', '.']
VLC_PLUGINS=[
'access/libaccess_attachment_plugin.dylib',
#'access/libaccess_avio_plugin.dylib',
'access/libaccess_fake_plugin.dylib',
'access/libaccess_ftp_plugin.dylib',
'access/libaccess_http_plugin.dylib',
'access/libaccess_imem_plugin.dylib',
'access/libaccess_mmap_plugin.dylib',
'access/libaccess_mms_plugin.dylib',
'access/libaccess_realrtsp_plugin.dylib',
'access/libaccess_tcp_plugin.dylib',
'access/libaccess_udp_plugin.dylib',
'access/libcdda_plugin.dylib',
'access/libfilesystem_plugin.dylib',
'access/libqtcapture_plugin.dylib',
'access/librtp_plugin.dylib',
'access/libzip_plugin.dylib',
'access_output/libaccess_output_dummy_plugin.dylib',
'access_output/libaccess_output_file_plugin.dylib',
'access_output/libaccess_output_http_plugin.dylib',
'access_output/libaccess_output_shout_plugin.dylib',
'access_output/libaccess_output_udp_plugin.dylib',
'audio_filter/liba52tofloat32_plugin.dylib',
'audio_filter/liba52tospdif_plugin.dylib',
'audio_filter/libaudio_format_plugin.dylib',
'audio_filter/libaudiobargraph_a_plugin.dylib',
'audio_filter/libchorus_flanger_plugin.dylib',
'audio_filter/libconverter_fixed_plugin.dylib',
'audio_filter/libdolby_surround_decoder_plugin.dylib',
'audio_filter/libdtstofloat32_plugin.dylib',
'audio_filter/libdtstospdif_plugin.dylib',
'audio_filter/libequalizer_plugin.dylib',
'audio_filter/libheadphone_channel_mixer_plugin.dylib',
'audio_filter/libmono_plugin.dylib',
'audio_filter/libmpgatofixed32_plugin.dylib',
'audio_filter/libnormvol_plugin.dylib',
'audio_filter/libparam_eq_plugin.dylib',
'audio_filter/libscaletempo_plugin.dylib',
'audio_filter/libsimple_channel_mixer_plugin.dylib',
'audio_filter/libspatializer_plugin.dylib',
'audio_filter/libtrivial_channel_mixer_plugin.dylib',
'audio_filter/libugly_resampler_plugin.dylib',
'audio_mixer/libfloat32_mixer_plugin.dylib',
'audio_mixer/libspdif_mixer_plugin.dylib',
'audio_mixer/libtrivial_mixer_plugin.dylib',
'audio_output/libaout_file_plugin.dylib',
'audio_output/libauhal_plugin.dylib',
'codec/liba52_plugin.dylib',
'codec/libadpcm_plugin.dylib',
'codec/libaes3_plugin.dylib',
'codec/libaraw_plugin.dylib',
'codec/libavcodec_plugin.dylib',
'codec/libcc_plugin.dylib',
'codec/libcdg_plugin.dylib',
'codec/libdts_plugin.dylib',
'codec/libfaad_plugin.dylib',
'codec/libfake_plugin.dylib',
'codec/libflac_plugin.dylib',
'codec/libfluidsynth_plugin.dylib',
'codec/libinvmem_plugin.dylib',
'codec/liblpcm_plugin.dylib',
'codec/libmpeg_audio_plugin.dylib',
'codec/libpng_plugin.dylib',
'codec/librawvideo_plugin.dylib',
'codec/libspeex_plugin.dylib',
'codec/libspudec_plugin.dylib',
'codec/libtheora_plugin.dylib',
'codec/libtwolame_plugin.dylib',
'codec/libvorbis_plugin.dylib',
'control/libgestures_plugin.dylib',
'control/libhotkeys_plugin.dylib',
'control/libmotion_plugin.dylib',
'control/libnetsync_plugin.dylib',
'control/libsignals_plugin.dylib',
'demux/libaiff_plugin.dylib',
'demux/libasf_plugin.dylib',
'demux/libau_plugin.dylib',
#'demux/libavformat_plugin.dylib',
'demux/libavi_plugin.dylib',
'demux/libdemux_cdg_plugin.dylib',
'demux/libdemuxdump_plugin.dylib',
'demux/libdirac_plugin.dylib',
'demux/libes_plugin.dylib',
'demux/libflacsys_plugin.dylib',
'demux/liblive555_plugin.dylib',
'demux/libmkv_plugin.dylib',
'demux/libmod_plugin.dylib',
'demux/libmp4_plugin.dylib',
'demux/libmpc_plugin.dylib',
'demux/libmpgv_plugin.dylib',
'demux/libnsc_plugin.dylib',
'demux/libnsv_plugin.dylib',
'demux/libnuv_plugin.dylib',
'demux/libogg_plugin.dylib',
'demux/libplaylist_plugin.dylib',
'demux/libps_plugin.dylib',
'demux/libpva_plugin.dylib',
'demux/librawaud_plugin.dylib',
'demux/librawdv_plugin.dylib',
'demux/librawvid_plugin.dylib',
'demux/libreal_plugin.dylib',
'demux/libsmf_plugin.dylib',
'demux/libts_plugin.dylib',
'demux/libtta_plugin.dylib',
'demux/libty_plugin.dylib',
'demux/libvc1_plugin.dylib',
'demux/libvoc_plugin.dylib',
'demux/libwav_plugin.dylib',
'demux/libxa_plugin.dylib',
'meta_engine/libfolder_plugin.dylib',
'meta_engine/libtaglib_plugin.dylib',
'misc/libaudioscrobbler_plugin.dylib',
'misc/libdummy_plugin.dylib',
'misc/libexport_plugin.dylib',
'misc/libfreetype_plugin.dylib',
'misc/libgnutls_plugin.dylib',
'misc/liblogger_plugin.dylib',
'misc/liblua_plugin.dylib',
'misc/libosd_parser_plugin.dylib',
'misc/libquartztext_plugin.dylib',
'misc/libstats_plugin.dylib',
'misc/libvod_rtsp_plugin.dylib',
'misc/libxml_plugin.dylib',
'misc/libxtag_plugin.dylib',
'mmx/libi420_rgb_mmx_plugin.dylib',
'mmx/libi420_yuy2_mmx_plugin.dylib',
'mmx/libi422_yuy2_mmx_plugin.dylib',
'mmx/libmemcpymmx_plugin.dylib',
'mmxext/libmemcpymmxext_plugin.dylib',
'mux/libmux_asf_plugin.dylib',
'mux/libmux_avi_plugin.dylib',
'mux/libmux_dummy_plugin.dylib',
'mux/libmux_mp4_plugin.dylib',
'mux/libmux_mpjpeg_plugin.dylib',
'mux/libmux_ogg_plugin.dylib',
'mux/libmux_ps_plugin.dylib',
'mux/libmux_ts_plugin.dylib',
'mux/libmux_wav_plugin.dylib',
'packetizer/libpacketizer_copy_plugin.dylib',
'packetizer/libpacketizer_dirac_plugin.dylib',
'packetizer/libpacketizer_flac_plugin.dylib',
'packetizer/libpacketizer_h264_plugin.dylib',
'packetizer/libpacketizer_mlp_plugin.dylib',
'packetizer/libpacketizer_mpeg4audio_plugin.dylib',
'packetizer/libpacketizer_mpeg4video_plugin.dylib',
'packetizer/libpacketizer_mpegvideo_plugin.dylib',
'packetizer/libpacketizer_vc1_plugin.dylib',
'sse2/libi420_rgb_sse2_plugin.dylib',
'sse2/libi420_yuy2_sse2_plugin.dylib',
'sse2/libi422_yuy2_sse2_plugin.dylib',
'stream_filter/libdecomp_plugin.dylib',
'stream_filter/libstream_filter_rar_plugin.dylib',
'stream_filter/libstream_filter_record_plugin.dylib',
'visualization/libvisual_plugin.dylib',
]
VLC_SEARCH_PATH=[
'/usr/local/lib/vlc/plugins/',
]
QT_PLUGINS = [
'crypto/libqca-ossl.dylib',
'phonon_backend/phonon_vlc.so',
'sqldrivers/libqsqlite.dylib',
'imageformats/libqgif.dylib',
'imageformats/libqico.dylib',
'imageformats/libqjpeg.dylib',
'imageformats/libqmng.dylib',
]
TOMAHAWK_PLUGINS = [
'libtomahawk_sipjabber.dylib',
'libtomahawk_sipgoogle.dylib',
'libtomahawk_siptwitter.dylib',
'libtomahawk_sipzeroconf.dylib',
'libtomahawk_qtweetlib.dylib',
]
QT_PLUGINS_SEARCH_PATH=[
'/usr/local/Cellar/qt/4.7.3/plugins',
]
class Error(Exception):
pass
class CouldNotFindQtPluginErrorFindFrameworkError(Error):
pass
class InstallNameToolError(Error):
pass
class CouldNotFindQtPluginError(Error):
pass
class CouldNotFindVLCPluginError(Error):
pass
class CouldNotFindScriptPluginError(Error):
pass
if len(sys.argv) < 2:
print 'Usage: %s <bundle.app>' % sys.argv[0]
bundle_dir = sys.argv[1]
bundle_name = os.path.basename(bundle_dir).split('.')[0]
commands = []
binary_dir = os.path.join(bundle_dir, 'Contents', 'MacOS')
frameworks_dir = os.path.join(bundle_dir, 'Contents', 'Frameworks')
commands.append(['mkdir', '-p', frameworks_dir])
resources_dir = os.path.join(bundle_dir, 'Contents', 'Resources')
commands.append(['mkdir', '-p', resources_dir])
plugins_dir = os.path.join(bundle_dir, 'Contents', 'PlugIns')
binary = os.path.join(bundle_dir, 'Contents', 'MacOS', bundle_name)
fixed_libraries = []
fixed_frameworks = []
def GetBrokenLibraries(binary):
#print "Checking libs for binary: %s" % binary
output = subprocess.Popen(['otool', '-L', binary], stdout=subprocess.PIPE).communicate()[0]
broken_libs = {
'frameworks': [],
'libs': []}
for line in [x.split(' ')[0].lstrip() for x in output.split('\n')[1:]]:
#print "Checking line: %s" % line
if not line: # skip empty lines
continue
if os.path.basename(binary) == os.path.basename(line):
#print "mnope %s-%s" % (os.path.basename(binary), os.path.basename(line))
continue
if re.match(r'^\s*/System/', line):
continue # System framework
elif re.match(r'^\s*/usr/lib/', line):
#print "unix style system lib"
continue # unix style system library
elif re.match(r'Breakpad', line):
continue # Manually added by cmake.
elif re.match(r'^\s*@executable_path', line) or re.match(r'^\s*@loader_path', line):
# Potentially already fixed library
if '.framework' in line:
relative_path = os.path.join(*line.split('/')[3:])
if not os.path.exists(os.path.join(frameworks_dir, relative_path)):
broken_libs['frameworks'].append(relative_path)
else:
relative_path = os.path.join(*line.split('/')[1:])
#print "RELPATH %s %s" % (relative_path, os.path.join(binary_dir, relative_path))
if not os.path.exists(os.path.join(binary_dir, relative_path)):
broken_libs['libs'].append(relative_path)
elif re.search(r'\w+\.framework', line):
broken_libs['frameworks'].append(line)
else:
broken_libs['libs'].append(line)
return broken_libs
def FindFramework(path):
for search_path in FRAMEWORK_SEARCH_PATH:
abs_path = os.path.join(search_path, path)
if os.path.exists(abs_path):
return abs_path
raise CouldNotFindFrameworkError(path)
def FindLibrary(path):
if os.path.exists(path):
return path
for search_path in LIBRARY_SEARCH_PATH:
abs_path = os.path.join(search_path, path)
if os.path.exists(abs_path):
return abs_path
else: # try harder---look for lib name in library folders
newpath = os.path.join(search_path,os.path.basename(path))
if os.path.exists(newpath):
return newpath
return ""
#raise CouldNotFindFrameworkError(path)
def FixAllLibraries(broken_libs):
for framework in broken_libs['frameworks']:
FixFramework(framework)
for lib in broken_libs['libs']:
FixLibrary(lib)
def FixFramework(path):
if path in fixed_libraries:
return
else:
fixed_libraries.append(path)
abs_path = FindFramework(path)
broken_libs = GetBrokenLibraries(abs_path)
FixAllLibraries(broken_libs)
new_path = CopyFramework(abs_path)
id = os.sep.join(new_path.split(os.sep)[3:])
FixFrameworkId(new_path, id)
for framework in broken_libs['frameworks']:
FixFrameworkInstallPath(framework, new_path)
for library in broken_libs['libs']:
FixLibraryInstallPath(library, new_path)
def FixLibrary(path):
if path in fixed_libraries or FindSystemLibrary(os.path.basename(path)) is not None:
return
else:
fixed_libraries.append(path)
abs_path = FindLibrary(path)
if abs_path == "":
print "Could not resolve %s, not fixing!" % path
return
broken_libs = GetBrokenLibraries(abs_path)
FixAllLibraries(broken_libs)
new_path = CopyLibrary(abs_path)
FixLibraryId(new_path)
for framework in broken_libs['frameworks']:
FixFrameworkInstallPath(framework, new_path)
for library in broken_libs['libs']:
FixLibraryInstallPath(library, new_path)
def FixVLCPlugin(abs_path, subdir):
broken_libs = GetBrokenLibraries(abs_path)
FixAllLibraries(broken_libs)
#print "Copying plugin....%s %s %s" % (plugins_dir, subdir, os.path.join(abs_path.split('/')[-2:]))
plugindir = abs_path.split('/')[-2]
new_path = os.path.join(plugins_dir, subdir, plugindir, os.path.basename(abs_path))
args = ['mkdir', '-p', os.path.dirname(new_path)]
commands.append(args)
args = ['ditto', '--arch=i386', '--arch=x86_64', abs_path, new_path]
commands.append(args)
args = ['chmod', 'u+w', new_path]
commands.append(args)
for framework in broken_libs['frameworks']:
FixFrameworkInstallPath(framework, new_path)
for library in broken_libs['libs']:
FixLibraryInstallPath(library, new_path)
def FixPlugin(abs_path, subdir):
broken_libs = GetBrokenLibraries(abs_path)
FixAllLibraries(broken_libs)
new_path = CopyPlugin(abs_path, subdir)
for framework in broken_libs['frameworks']:
FixFrameworkInstallPath(framework, new_path)
for library in broken_libs['libs']:
FixLibraryInstallPath(library, new_path)
def FixBinary(path):
broken_libs = GetBrokenLibraries(path)
FixAllLibraries(broken_libs)
for framework in broken_libs['frameworks']:
FixFrameworkInstallPath(framework, path)
for library in broken_libs['libs']:
FixLibraryInstallPath(library, path)
def CopyLibrary(path):
new_path = os.path.join(frameworks_dir, os.path.basename(path))
args = ['ditto', '--arch=i386', '--arch=x86_64', path, new_path]
commands.append(args)
args = ['chmod', 'u+w', new_path]
commands.append(args)
return new_path
def CopyPlugin(path, subdir):
new_path = os.path.join(plugins_dir, subdir, os.path.basename(path))
args = ['mkdir', '-p', os.path.dirname(new_path)]
commands.append(args)
args = ['ditto', '--arch=i386', '--arch=x86_64', path, new_path]
commands.append(args)
args = ['chmod', 'u+w', new_path]
commands.append(args)
return new_path
def CopyFramework(path):
parts = path.split(os.sep)
for i, part in enumerate(parts):
if re.match(r'\w+\.framework', part):
full_path = os.path.join(frameworks_dir, *parts[i:-1])
break
args = ['mkdir', '-p', full_path]
commands.append(args)
args = ['ditto', '--arch=i386', '--arch=x86_64', path, full_path]
commands.append(args)
args = ['chmod', 'u+w', os.path.join(full_path, parts[-1])]
commands.append(args)
menu_nib = os.path.join(os.path.split(path)[0], 'Resources', 'qt_menu.nib')
if os.path.exists(menu_nib):
args = ['cp', '-r', menu_nib, resources_dir]
commands.append(args)
return os.path.join(full_path, parts[-1])
def FixId(path, library_name):
id = '@executable_path/../Frameworks/%s' % library_name
args = ['install_name_tool', '-id', id, path]
commands.append(args)
def FixLibraryId(path):
library_name = os.path.basename(path)
FixId(path, library_name)
def FixFrameworkId(path, id):
FixId(path, id)
def FixInstallPath(library_path, library, new_path):
args = ['install_name_tool', '-change', library_path, new_path, library]
commands.append(args)
def FindSystemLibrary(library_name):
for path in ['/lib', '/usr/lib']:
full_path = os.path.join(path, library_name)
if os.path.exists(full_path):
return full_path
return None
def FixLibraryInstallPath(library_path, library):
system_library = FindSystemLibrary(os.path.basename(library_path))
if system_library is None:
new_path = '@executable_path/../Frameworks/%s' % os.path.basename(library_path)
FixInstallPath(library_path, library, new_path)
else:
FixInstallPath(library_path, library, system_library)
def FixFrameworkInstallPath(library_path, library):
parts = library_path.split(os.sep)
for i, part in enumerate(parts):
if re.match(r'\w+\.framework', part):
full_path = os.path.join(*parts[i:])
break
new_path = '@executable_path/../Frameworks/%s' % full_path
FixInstallPath(library_path, library, new_path)
def FindQtPlugin(name):
for path in QT_PLUGINS_SEARCH_PATH:
if os.path.exists(path):
if os.path.exists(os.path.join(path, name)):
return os.path.join(path, name)
raise CouldNotFindQtPluginError(name)
def FindVLCPlugin(name):
for path in VLC_SEARCH_PATH:
if os.path.exists(path):
if os.path.exists(os.path.join(path, name)):
return os.path.join(path, name)
raise CouldNotFindVLCPluginError(name)
FixBinary(binary)
for plugin in VLC_PLUGINS:
FixVLCPlugin(FindVLCPlugin(plugin), '.')
for plugin in TOMAHAWK_PLUGINS:
FixPlugin(plugin, '../MacOS')
try:
FixPlugin('spotify_tomahawkresolver', '../MacOS')
except:
print 'Failed to find spotify resolver'
for plugin in QT_PLUGINS:
FixPlugin(FindQtPlugin(plugin), os.path.dirname(plugin))
if len(sys.argv) <= 2:
print 'Would run %d commands:' % len(commands)
for command in commands:
print ' '.join(command)
print 'OK?'
raw_input()
for command in commands:
p = subprocess.Popen(command)
os.waitpid(p.pid, 0)

View File

@@ -1,2 +1,2 @@
[Paths]
Plugins = plugins
Plugins = PlugIns

View File

@@ -1,20 +1,27 @@
SET(MINGW_PREFIX "i686-w64-mingw32")
# this one is important
SET(CMAKE_SYSTEM_NAME Windows)
# specify the cross compiler
SET(CMAKE_C_COMPILER ccache i686-w64-mingw32-gcc)
SET(CMAKE_CXX_COMPILER ccache i686-w64-mingw32-g++)
SET(CMAKE_C_COMPILER ccache ${MINGW_PREFIX}-gcc)
SET(CMAKE_CXX_COMPILER ccache ${MINGW_PREFIX}-g++)
SET(CMAKE_RC_COMPILER /usr/bin/${MINGW_PREFIX}-windres)
# where is the target environment containing libraries
SET(CMAKE_FIND_ROOT_PATH /usr/i686-w64-mingw32/sys-root/mingw)
SET(CMAKE_FIND_ROOT_PATH /usr/${MINGW_PREFIX}/sys-root/mingw)
SET(CMAKE_FIND_ROOT_PATH_MODE_LIBRARY ONLY)
SET(CMAKE_FIND_ROOT_PATH_MODE_INCLUDE ONLY)
SET(CMAKE_FIND_ROOT_PATH_MODE_PROGRAM NEVER)
# windres executable for application icon support
SET(WINDRES_EXECUTABLE /usr/bin/i686-w64-mingw32-windres)
# libs with broken find modules
SET(TAGLIB_FOUND true)
SET(TAGLIB_LIBRARIES ${CMAKE_FIND_ROOT_PATH}/lib/libtag.dll.a)
SET(TAGLIB_INCLUDES ${CMAKE_FIND_ROOT_PATH}/include/taglib)
SET(QT_PLUGINS_DIR ${CMAKE_FIND_ROOT_PATH}/lib/qt4/plugins/)
SET(QT_QTUITOOLS_LIBRARY_RELEASE ${CMAKE_FIND_ROOT_PATH}/lib/libQtUiTools.a)
SET(QT_QTUITOOLS_LIBRARY_DEBUG ${CMAKE_FIND_ROOT_PATH}/lib/libQtUiToolsd.a)
SET(QT_QTUITOOLS_LIBRARY ${QT_QTUITOOLS_LIBRARY_RELEASE})

View File

@@ -1 +0,0 @@
122

View File

@@ -1,667 +0,0 @@
;Tomahawk installer script.
;-----------------------------------------------------------------------------
; Some installer script options (comment-out options not required)
;-----------------------------------------------------------------------------
;!define OPTION_LICENSE_AGREEMENT
!define OPTION_UAC_PLUGIN_ENHANCED
!define OPTION_SECTION_SC_START_MENU
!define OPTION_SECTION_SC_DESKTOP
!define OPTION_SECTION_SC_QUICK_LAUNCH
!define OPTION_FINISHPAGE
!define OPTION_FINISHPAGE_LAUNCHER
!define OPTION_FINISHPAGE_RELEASE_NOTES
;-----------------------------------------------------------------------------
; Some paths.
;-----------------------------------------------------------------------------
!ifndef MING_PATH
!define MING_PATH "/usr/i686-w64-mingw32/sys-root/mingw"
!endif
!define MING_BIN "${MING_PATH}/bin"
!define MING_LIB "${MING_PATH}/lib"
!define ROOT_PATH "..\..\.." ; assuming the script is in ROOT/admin/win/nsi
!define BUILD_PATH "${ROOT_PATH}\build"
!define QT_DLL_PATH "${MING_BIN}"
!define SQLITE_DLL_PATH "${MING_LIB}/qt4/plugins/sqldrivers"
!define IMAGEFORMATS_DLL_PATH "${MING_LIB}/qt4/plugins/imageformats"
!define VLC_PLUGIN_PATH "${MING_LIB}\vlc\plugins"
;-----------------------------------------------------------------------------
; Increment installer revision number as part of this script.
;-----------------------------------------------------------------------------
!define /file REVISION_LAST revision.txt
!define /math REVISION ${REVISION_LAST} + 1
!delfile revision.txt
!appendfile revision.txt ${REVISION}
!ifndef VER_MAJOR && VER_MINOR && VER_BUILD
!define VER_MAJOR "0"
!define VER_MINOR "2"
!define VER_BUILD "0prealpha"
!endif
!define VERSION "${VER_MAJOR}.${VER_MINOR}.${VER_BUILD}"
;-----------------------------------------------------------------------------
; Installer build timestamp.
;-----------------------------------------------------------------------------
!define /date BUILD_TIME "built on %Y/%m/%d at %I:%M %p (rev. ${REVISION})"
;-----------------------------------------------------------------------------
; Initial installer setup and definitions.
;-----------------------------------------------------------------------------
Name "Tomahawk"
Caption "Tomahawk Installer"
BrandingText "Tomahawk ${VERSION} -- ${BUILD_TIME}"
OutFile "${ROOT_PATH}\build\tomahawk-${VERSION}.exe"
InstallDir "$PROGRAMFILES\Tomahawk"
InstallDirRegKey HKCU "Software\Tomahawk" ""
InstType Standard
InstType Full
InstType Minimal
CRCCheck On
SetCompressor /SOLID lzma
RequestExecutionLevel user ;Now using the UAC plugin.
ReserveFile tomahawk.ini
ReserveFile "${NSISDIR}\Plugins\InstallOptions.dll"
;-----------------------------------------------------------------------------
; Include some required header files.
;-----------------------------------------------------------------------------
!include LogicLib.nsh ;Used by APPDATA uninstaller.
!include nsDialogs.nsh ;Used by APPDATA uninstaller.
!include MUI2.nsh ;Used by APPDATA uninstaller.
!include InstallOptions.nsh ;Required by MUI2 to support old MUI_INSTALLOPTIONS.
!include Memento.nsh ;Remember user selections.
!include WinVer.nsh ;Windows version detection.
!include WordFunc.nsh ;Used by VersionCompare macro function.
!include UAC.nsh ;Used by the UAC elevation to install as user or admin.
;-----------------------------------------------------------------------------
; Memento selections stored in registry.
;-----------------------------------------------------------------------------
!define MEMENTO_REGISTRY_ROOT HKLM
!define MEMENTO_REGISTRY_KEY Software\Microsoft\Windows\CurrentVersion\Uninstall\Tomahawk
;-----------------------------------------------------------------------------
; Modern User Interface (MUI) defintions and setup.
;-----------------------------------------------------------------------------
!define MUI_ABORTWARNING
!define MUI_ICON installer.ico
!define MUI_UNICON installer.ico
!define MUI_WELCOMEFINISHPAGE_BITMAP welcome.bmp
!define MUI_WELCOMEPAGE_TITLE "Tomahawk ${VERSION} Setup$\r$\nInstaller Build Revision ${REVISION}"
!define MUI_WELCOMEPAGE_TEXT "This wizard will guide you through the installation.$\r$\n$\r$\n$_CLICK"
!define MUI_HEADERIMAGE
!define MUI_HEADERIMAGE_BITMAP page_header.bmp
!define MUI_COMPONENTSPAGE_SMALLDESC
!define MUI_FINISHPAGE_TITLE "Tomahawk Install Completed"
!define MUI_FINISHPAGE_LINK "Click here to visit the Tomahawk website."
!define MUI_FINISHPAGE_LINK_LOCATION "http://tomahawk-player.org/"
!define MUI_FINISHPAGE_NOREBOOTSUPPORT
!ifdef OPTION_FINISHPAGE_RELEASE_NOTES
!define MUI_FINISHPAGE_SHOWREADME_NOTCHECKED
!define MUI_FINISHPAGE_SHOWREADME "$INSTDIR\NOTES.txt"
!define MUI_FINISHPAGE_SHOWREADME_TEXT "Show release notes"
!endif
!ifdef OPTION_FINISHPAGE_LAUNCHER
!define MUI_FINISHPAGE_NOAUTOCLOSE
!define MUI_FINISHPAGE_RUN
!define MUI_FINISHPAGE_RUN_FUNCTION "LaunchTomahawk"
!endif
;-----------------------------------------------------------------------------
; Page macros.
;-----------------------------------------------------------------------------
!insertmacro MUI_PAGE_WELCOME
!ifdef OPTION_LICENSE_AGREEMENT
!insertmacro MUI_PAGE_LICENSE "LICENSE.txt"
!endif
Page custom PageReinstall PageLeaveReinstall
!insertmacro MUI_PAGE_COMPONENTS
!insertmacro MUI_PAGE_DIRECTORY
!insertmacro MUI_PAGE_INSTFILES
!ifdef OPTION_FINISHPAGE
!insertmacro MUI_PAGE_FINISH
!endif
!insertmacro MUI_UNPAGE_CONFIRM
UninstPage custom un.UnPageUserAppData un.UnPageUserAppDataLeave
!insertmacro MUI_UNPAGE_INSTFILES
;-----------------------------------------------------------------------------
; Other MUI macros.
;-----------------------------------------------------------------------------
!insertmacro MUI_LANGUAGE "English"
##############################################################################
# #
# FINISH PAGE LAUNCHER FUNCTIONS #
# #
##############################################################################
Function LaunchTomahawk
${UAC.CallFunctionAsUser} LaunchTomahawkAsUser
FunctionEnd
Function LaunchTomahawkAsUser
Exec "$INSTDIR\tomahawk.exe"
FunctionEnd
##############################################################################
# #
# PROCESS HANDLING FUNCTIONS AND MACROS #
# #
##############################################################################
!macro CheckForProcess processName gotoWhenFound gotoWhenNotFound
Processes::FindProcess ${processName}
StrCmp $R0 "0" ${gotoWhenNotFound} ${gotoWhenFound}
!macroend
!macro ConfirmEndProcess processName
MessageBox MB_YESNO|MB_ICONEXCLAMATION \
"Found ${processName} process(s) which need to be stopped.$\nDo you want the installer to stop these for you?" \
IDYES process_${processName}_kill IDNO process_${processName}_ended
process_${processName}_kill:
DetailPrint "Killing ${processName} processes."
Processes::KillProcess ${processName}
Sleep 1500
StrCmp $R0 "1" process_${processName}_ended
DetailPrint "Process to kill not found!"
process_${processName}_ended:
!macroend
!macro CheckAndConfirmEndProcess processName
!insertmacro CheckForProcess ${processName} 0 no_process_${processName}_to_end
!insertmacro ConfirmEndProcess ${processName}
no_process_${processName}_to_end:
!macroend
Function EnsureTomahawkShutdown
!insertmacro CheckAndConfirmEndProcess "tomahawk.exe"
FunctionEnd
##############################################################################
# #
# RE-INSTALLER FUNCTIONS #
# #
##############################################################################
Function PageReinstall
ReadRegStr $R0 HKLM "Software\Tomahawk" ""
StrCmp $R0 "" 0 +2
Abort
;Detect version
ReadRegDWORD $R0 HKLM "Software\Tomahawk" "VersionMajor"
IntCmp $R0 ${VER_MAJOR} minor_check new_version older_version
minor_check:
ReadRegDWORD $R0 HKLM "Software\Tomahawk" "VersionMinor"
IntCmp $R0 ${VER_MINOR} build_check new_version older_version
build_check:
ReadRegDWORD $R0 HKLM "Software\Tomahawk" "VersionBuild"
IntCmp $R0 ${VER_BUILD} revision_check new_version older_version
revision_check:
ReadRegDWORD $R0 HKLM "Software\Tomahawk" "VersionRevision"
IntCmp $R0 ${REVISION} same_version new_version older_version
new_version:
!insertmacro INSTALLOPTIONS_WRITE "tomahawk.ini" "Field 1" "Text" "An older version of Tomahawk is installed on your system. It is recommended that you uninstall the current version before installing. Select the operation you want to perform and click Next to continue."
!insertmacro INSTALLOPTIONS_WRITE "tomahawk.ini" "Field 2" "Text" "Uninstall before installing"
!insertmacro INSTALLOPTIONS_WRITE "tomahawk.ini" "Field 3" "Text" "Do not uninstall"
!insertmacro MUI_HEADER_TEXT "Already Installed" "Choose how you want to install Tomahawk."
StrCpy $R0 "1"
Goto reinst_start
older_version:
!insertmacro INSTALLOPTIONS_WRITE "tomahawk.ini" "Field 1" "Text" "A newer version of Tomahawk is already installed! It is not recommended that you install an older version. If you really want to install this older version, it is better to uninstall the current version first. Select the operation you want to perform and click Next to continue."
!insertmacro INSTALLOPTIONS_WRITE "tomahawk.ini" "Field 2" "Text" "Uninstall before installing"
!insertmacro INSTALLOPTIONS_WRITE "tomahawk.ini" "Field 3" "Text" "Do not uninstall"
!insertmacro MUI_HEADER_TEXT "Already Installed" "Choose how you want to install Tomahawk."
StrCpy $R0 "1"
Goto reinst_start
same_version:
!insertmacro INSTALLOPTIONS_WRITE "tomahawk.ini" "Field 1" "Text" "Tomahawk ${VERSION} is already installed.\r\nSelect the operation you want to perform and click Next to continue."
!insertmacro INSTALLOPTIONS_WRITE "tomahawk.ini" "Field 2" "Text" "Add/Reinstall components"
!insertmacro INSTALLOPTIONS_WRITE "tomahawk.ini" "Field 3" "Text" "Uninstall Tomahawk"
!insertmacro MUI_HEADER_TEXT "Already Installed" "Choose the maintenance option to perform."
StrCpy $R0 "2"
reinst_start:
!insertmacro INSTALLOPTIONS_DISPLAY "tomahawk.ini"
FunctionEnd
Function PageLeaveReinstall
!insertmacro INSTALLOPTIONS_READ $R1 "tomahawk.ini" "Field 2" "State"
StrCmp $R0 "1" 0 +2
StrCmp $R1 "1" reinst_uninstall reinst_done
StrCmp $R0 "2" 0 +3
StrCmp $R1 "1" reinst_done reinst_uninstall
reinst_uninstall:
ReadRegStr $R1 HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\Tomahawk" "UninstallString"
HideWindow
ClearErrors
ExecWait '$R1 _?=$INSTDIR'
IfErrors no_remove_uninstaller
IfFileExists "$INSTDIR\tomahawk.exe" no_remove_uninstaller
Delete $R1
RMDir $INSTDIR
no_remove_uninstaller:
StrCmp $R0 "2" 0 +3
UAC::Unload
Quit
BringToFront
reinst_done:
FunctionEnd
##############################################################################
# #
# INSTALLER SECTIONS #
# #
##############################################################################
Section "Tomahawk Player" SEC_TOMAHAWK_PLAYER
SectionIn 1 2 3 RO
SetDetailsPrint listonly
SetDetailsPrint textonly
DetailPrint "Installing Tomahawk Player essentials."
SetDetailsPrint listonly
SetOutPath "$INSTDIR"
!ifdef INSTALL_PATH
;Main executable.
File "${INSTALL_PATH}\bin\tomahawk.exe"
File "${INSTALL_PATH}\bin\libqxtweb-standalone.dll"
File "${INSTALL_PATH}\bin\libtomahawk_portfwd.dll"
File "${INSTALL_PATH}\bin\libtomahawk_lastfm2.dll"
File "${INSTALL_PATH}\bin\libtomahawklib.dll"
File "${INSTALL_PATH}\lib\libtomahawk_sip*.dll"
!endif
!ifndef INSTALL_PATH
;Main executable.
File "${BUILD_PATH}\tomahawk.exe"
File "${BUILD_PATH}\libtomahawklib.dll"
File "${BUILD_PATH}\libqxtweb-standalone.dll"
File "${BUILD_PATH}\libtomahawk_portfwd.dll"
File "${BUILD_PATH}\libtomahawk_lastfm2.dll"
File "${BUILD_PATH}\libtomahawk_sip*.dll"
!endif
;License & release notes.
File "${ROOT_PATH}\LICENSE.txt"
File /oname=NOTES.txt RELEASE_NOTES.txt
;QT stuff:
File "${QT_DLL_PATH}\QtCore4.dll"
File "${QT_DLL_PATH}\QtGui4.dll"
File "${QT_DLL_PATH}\QtNetwork4.dll"
File "${QT_DLL_PATH}\QtSql4.dll"
File "${QT_DLL_PATH}\QtXml4.dll"
File "${QT_DLL_PATH}\QtWebKit4.dll"
;SQLite driver
SetOutPath "$INSTDIR\sqldrivers"
File "${SQLITE_DLL_PATH}\qsqlite4.dll"
SetOutPath "$INSTDIR"
;Image plugins
SetOutPath "$INSTDIR\imageformats"
File "${IMAGEFORMATS_DLL_PATH}\qgif4.dll"
File "${IMAGEFORMATS_DLL_PATH}\qjpeg4.dll"
SetOutPath "$INSTDIR"
;Cygwin/c++ stuff
;File "${MING_BIN}\cygmad-0.dll"
;File "${MING_BIN}\libgcc_s_dw2-1.dll"
;File "${MING_BIN}\mingwm10.dll"
File "${MING_BIN}\libgcc_s_sjlj-1.dll"
File "${MING_BIN}\libstdc++-6.dll"
;Phonon stuff
;Fix the phonon build to not use Dbus
File "${QT_DLL_PATH}\QtDbus4.dll"
File "${MING_BIN}\libdbus-1-3.dll"
File "${MING_BIN}\dbus-daemon.exe"
File "${MING_BIN}\libphonon.dll"
SetOutPath "$INSTDIR\phonon_backend"
File "${MING_BIN}\phonon_backend\phonon_vlc.dll"
SetOutPath "$INSTDIR"
;VLC
;SetOutPath "$INSTDIR\phonon_backend"
File "${MING_BIN}\libvlc.dll"
File "${MING_BIN}\libvlccore.dll"
SetOutPath "$INSTDIR\plugins"
File /r "${VLC_PLUGIN_PATH}\*.dll"
SetOutPath "$INSTDIR"
File "${MING_BIN}\libmad-0.dll" ; MP3
File "${MING_BIN}\libFLAC-8.dll" ; FLAC
File "${MING_BIN}\libogg-0.dll" ; OGG, FLAC
File "${MING_BIN}\libvorbis-0.dll" ; OGG
File "${MING_BIN}\libvorbisenc-2.dll" ; OGG
; Other
File "${MING_BIN}\libqjson.dll"
File "${MING_BIN}\libtag.dll"
File "${MING_BIN}\libpng15-15.dll"
File "${MING_BIN}\libjpeg-8.dll"
File "${MING_BIN}\zlib1.dll"
File "${MING_BIN}\libechonest.dll"
File "${MING_BIN}\libQTweetLib.dll"
; Jabber
File "${MING_BIN}\libjreen.dll"
File "${MING_BIN}\libqca.dll"
SetOutPath "$INSTDIR\crypto"
File "${MING_LIB}\qt4\plugins\crypto\libqca-ossl.dll"
SetOutPath "$INSTDIR"
File "${MING_BIN}\libssl-8.dll"
File "${MING_BIN}\libcrypto-8.dll"
File "${MING_LIB}\libclucene-core.dll"
File "${MING_LIB}\libclucene-shared.dll"
File "${MING_BIN}\libqtsparkle.dll"
SectionEnd
SectionGroup "Shortcuts"
!ifdef OPTION_SECTION_SC_START_MENU
${MementoSection} "Start Menu Program Group" SEC_START_MENU
SectionIn 1 2
SetDetailsPrint textonly
DetailPrint "Adding shortcuts for the Tomahawk program group to the Start Menu."
SetDetailsPrint listonly
SetShellVarContext all
RMDir /r "$SMPROGRAMS\Tomahawk"
CreateDirectory "$SMPROGRAMS\Tomahawk"
CreateShortCut "$SMPROGRAMS\Tomahawk\LICENSE.lnk" "$INSTDIR\LICENSE.txt"
CreateShortCut "$SMPROGRAMS\Tomahawk\Tomahawk.lnk" "$INSTDIR\tomahawk.exe"
CreateShortCut "$SMPROGRAMS\Tomahawk\Release notes.lnk" "$INSTDIR\NOTES.txt"
CreateShortCut "$SMPROGRAMS\Tomahawk\Uninstall.lnk" "$INSTDIR\uninstall.exe"
SetShellVarContext current
${MementoSectionEnd}
!endif
!ifdef OPTION_SECTION_SC_DESKTOP
${MementoSection} "Desktop Shortcut" SEC_DESKTOP
SectionIn 1 2
SetDetailsPrint textonly
DetailPrint "Creating Desktop Shortcuts"
SetDetailsPrint listonly
CreateShortCut "$DESKTOP\Tomahawk.lnk" "$INSTDIR\tomahawk.exe"
${MementoSectionEnd}
!endif
!ifdef OPTION_SECTION_SC_QUICK_LAUNCH
${MementoSection} "Quick Launch Shortcut" SEC_QUICK_LAUNCH
SectionIn 1 2
SetDetailsPrint textonly
DetailPrint "Creating Quick Launch Shortcut"
SetDetailsPrint listonly
CreateShortCut "$QUICKLAUNCH\Tomahawk.lnk" "$INSTDIR\tomahawk.exe"
${MementoSectionEnd}
!endif
SectionGroupEnd
${MementoSectionDone}
; Installer section descriptions
;--------------------------------
!insertmacro MUI_FUNCTION_DESCRIPTION_BEGIN
!insertmacro MUI_DESCRIPTION_TEXT ${SEC_TOMAHAWK_PLAYER} "Tomahawk player essentials."
!insertmacro MUI_DESCRIPTION_TEXT ${SEC_START_MENU} "Tomahawk program group."
!insertmacro MUI_DESCRIPTION_TEXT ${SEC_DESKTOP} "Desktop shortcut for Tomahawk."
!insertmacro MUI_DESCRIPTION_TEXT ${SEC_QUICK_LAUNCH} "Quick Launch shortcut for Tomahawk."
!insertmacro MUI_FUNCTION_DESCRIPTION_END
Section -post
;Uninstaller file.
SetDetailsPrint textonly
DetailPrint "Writing Uninstaller"
SetDetailsPrint listonly
WriteUninstaller $INSTDIR\uninstall.exe
;Registry keys required for installer version handling and uninstaller.
SetDetailsPrint textonly
DetailPrint "Writing Installer Registry Keys"
SetDetailsPrint listonly
;Version numbers used to detect existing installation version for comparisson.
WriteRegStr HKLM "Software\Tomahawk" "" $INSTDIR
WriteRegDWORD HKLM "Software\Tomahawk" "VersionMajor" "${VER_MAJOR}"
WriteRegDWORD HKLM "Software\Tomahawk" "VersionMinor" "${VER_MINOR}"
WriteRegDWORD HKLM "Software\Tomahawk" "VersionRevision" "${REVISION}"
WriteRegDWORD HKLM "Software\Tomahawk" "VersionBuild" "${VER_BUILD}"
;Add or Remove Programs entry.
WriteRegExpandStr HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\Tomahawk" "UninstallString" '"$INSTDIR\Uninstall.exe"'
WriteRegExpandStr HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\Tomahawk" "InstallLocation" "$INSTDIR"
WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\Tomahawk" "DisplayName" "Tomahawk"
WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\Tomahawk" "Publisher" "Tomahawk-player.org"
WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\Tomahawk" "DisplayIcon" "$INSTDIR\Uninstall.exe,0"
WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\Tomahawk" "DisplayVersion" "${VERSION}"
WriteRegDWORD HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\Tomahawk" "VersionMajor" "${VER_MAJOR}"
WriteRegDWORD HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\Tomahawk" "VersionMinor" "${VER_MINOR}.${REVISION}"
WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\Tomahawk" "URLInfoAbout" "http://tomahawk-player.org/"
WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\Tomahawk" "HelpLink" "http://tomahawk-player.org/"
WriteRegDWORD HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\Tomahawk" "NoModify" "1"
WriteRegDWORD HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\Tomahawk" "NoRepair" "1"
; Register tomahawk:// protocol handler
WriteRegStr HKCR "tomahawk" "" "URL: Tomahawk Protocol"
WriteRegStr HKCR "tomahawk\DefaultIcon" "" $INSTDIR\tomahawk.exe,1
WriteRegStr HKCR "tomahawk\shell" "" "open"
WriteRegStr HKCR "tomahawk\shell\open\command" "" '"$INSTDIR\tomahawk.exe" "%1"'
SetDetailsPrint textonly
DetailPrint "Finsihed."
SectionEnd
##############################################################################
# #
# UNINSTALLER SECTION #
# #
##############################################################################
Var UnPageUserAppDataDialog
Var UnPageUserAppDataCheckbox
Var UnPageUserAppDataCheckbox_State
Var UnPageUserAppDataEditBox
Function un.UnPageUserAppData
!insertmacro MUI_HEADER_TEXT "Uninstall Tomahawk" "Remove Tomahawk's data folder from your computer."
nsDialogs::Create /NOUNLOAD 1018
Pop $UnPageUserAppDataDialog
${If} $UnPageUserAppDataDialog == error
Abort
${EndIf}
${NSD_CreateLabel} 0 0 100% 12u "Do you want to delete Tomahawk's data folder?"
Pop $0
${NSD_CreateText} 0 13u 100% 12u "$LOCALAPPDATA\Tomahawk"
Pop $UnPageUserAppDataEditBox
SendMessage $UnPageUserAppDataEditBox ${EM_SETREADONLY} 1 0
${NSD_CreateLabel} 0 46u 100% 24u "Leave unchecked to keep the data folder for later use or check to delete the data folder."
Pop $0
${NSD_CreateCheckbox} 0 71u 100% 8u "Yes, delete this data folder."
Pop $UnPageUserAppDataCheckbox
nsDialogs::Show
FunctionEnd
Function un.UnPageUserAppDataLeave
${NSD_GetState} $UnPageUserAppDataCheckbox $UnPageUserAppDataCheckbox_State
FunctionEnd
Section Uninstall
IfFileExists "$INSTDIR\tomahawk.exe" tomahawk_installed
MessageBox MB_YESNO "It does not appear that Tomahawk is installed in the directory '$INSTDIR'.$\r$\nContinue anyway (not recommended)?" IDYES tomahawk_installed
Abort "Uninstall aborted by user"
tomahawk_installed:
;Delete registry keys.
DeleteRegKey HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\Tomahawk"
DeleteRegValue HKLM "Software\Tomahawk" "VersionBuild"
DeleteRegValue HKLM "Software\Tomahawk" "VersionMajor"
DeleteRegValue HKLM "Software\Tomahawk" "VersionMinor"
DeleteRegValue HKLM "Software\Tomahawk" "VersionRevision"
DeleteRegValue HKLM "Software\Tomahawk" ""
DeleteRegKey HKLM "Software\Tomahawk"
DeleteRegKey HKCR "tomahawk"
;Start menu shortcuts.
!ifdef OPTION_SECTION_SC_START_MENU
SetShellVarContext all
RMDir /r "$SMPROGRAMS\Tomahawk"
SetShellVarContext current
!endif
;Desktop shortcut.
!ifdef OPTION_SECTION_SC_DESKTOP
IfFileExists "$DESKTOP\Tomahawk.lnk" 0 +2
Delete "$DESKTOP\Tomahawk.lnk"
!endif
;Quick Launch shortcut.
!ifdef OPTION_SECTION_SC_QUICK_LAUNCH
IfFileExists "$QUICKLAUNCH\Tomahawk.lnk" 0 +2
Delete "$QUICKLAUNCH\Tomahawk.lnk"
!endif
;Remove all the Program Files.
RMDir /r $INSTDIR
;Uninstall User Data if option is checked, otherwise skip.
${If} $UnPageUserAppDataCheckbox_State == ${BST_CHECKED}
RMDir /r "$LOCALAPPDATA\Tomahawk"
${EndIf}
SetDetailsPrint textonly
DetailPrint "Finsihed."
SectionEnd
##############################################################################
# #
# NSIS Installer Event Handler Functions #
# #
##############################################################################
Function .onInit
!insertmacro INSTALLOPTIONS_EXTRACT "tomahawk.ini"
;Remove Quick Launch option from Windows 7, as no longer applicable - usually.
${IfNot} ${AtMostWinVista}
SectionSetText ${SEC_QUICK_LAUNCH} "Quick Launch Shortcut (N/A)"
SectionSetFlags ${SEC_QUICK_LAUNCH} ${SF_RO}
SectionSetInstTypes ${SEC_QUICK_LAUNCH} 0
${EndIf}
${MementoSectionRestore}
UAC_Elevate:
UAC::RunElevated
StrCmp 1223 $0 UAC_ElevationAborted ; UAC dialog aborted by user?
StrCmp 0 $0 0 UAC_Err ; Error?
StrCmp 1 $1 0 UAC_Success ;Are we the real deal or just the wrapper?
Quit
UAC_Err:
MessageBox MB_ICONSTOP "Unable to elevate, error $0"
Abort
UAC_ElevationAborted:
Abort
UAC_Success:
StrCmp 1 $3 +4 ;Admin?
StrCmp 3 $1 0 UAC_ElevationAborted ;Try again?
MessageBox MB_ICONSTOP "This installer requires admin access, try again"
goto UAC_Elevate
;Prevent multiple instances.
System::Call 'kernel32::CreateMutexA(i 0, i 0, t "tomahawkInstaller") i .r1 ?e'
Pop $R0
StrCmp $R0 0 +3
MessageBox MB_OK|MB_ICONEXCLAMATION "The installer is already running."
Abort
;Use available InstallLocation when possible. This is useful in the uninstaller
;via re-install, which would otherwise use a default location - a bug.
ReadRegStr $R0 HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\Tomahawk" "InstallLocation"
StrCmp $R0 "" SkipSetInstDir
StrCpy $INSTDIR $R0
SkipSetInstDir:
;Shutdown Tomahawk in case Add/Remove re-installer option used.
Call EnsureTomahawkShutdown
FunctionEnd
Function .onInstSuccess
${MementoSectionSave}
UAC::Unload ;Must call unload!
FunctionEnd
Function .onInstFailed
UAC::Unload ;Must call unload!
FunctionEnd
##############################################################################
# #
# NSIS Uninstaller Event Handler Functions #
# #
##############################################################################
Function un.onInit
UAC_Elevate:
UAC::RunElevated
StrCmp 1223 $0 UAC_ElevationAborted ; UAC dialog aborted by user?
StrCmp 0 $0 0 UAC_Err ; Error?
StrCmp 1 $1 0 UAC_Success ;Are we the real deal or just the wrapper?
Quit
UAC_Err:
MessageBox MB_ICONSTOP "Unable to elevate, error $0"
Abort
UAC_ElevationAborted:
Abort
UAC_Success:
StrCmp 1 $3 +4 ;Admin?
StrCmp 3 $1 0 UAC_ElevationAborted ;Try again?
MessageBox MB_ICONSTOP "This uninstaller requires admin access, try again"
goto UAC_Elevate
;Prevent multiple instances.
System::Call 'kernel32::CreateMutexA(i 0, i 0, t "tomahawkUninstaller") i .r1 ?e'
Pop $R0
StrCmp $R0 0 +3
MessageBox MB_OK|MB_ICONEXCLAMATION "This uninstaller is already running."
Abort
FunctionEnd
Function un.onUnInstSuccess
UAC::Unload ;Must call unload!
FunctionEnd
Function un.onUnInstFailed
UAC::Unload ;Must call unload!
FunctionEnd

View File

@@ -1,20 +1,49 @@
#!/bin/bash
echo "Remove old vlc dir..."
mkdir -p vlc/
cd vlc/
#rm -vf vlc-*.7z
rm -rf vlc/
#rm -rf vlc/
echo "Download specified binary..."
#wget -c "http://downloads.sourceforge.net/project/vlc/1.1.9/win32/vlc-1.1.9-win32.7z?r=http%3A%2F%2Fwww.videolan.org%2Fvlc%2Fdownload-windows.html&ts=1306272584&use_mirror=leaseweb"
wget -c "http://nightlies.videolan.org/build/win32/trunk-20110524-1321/vlc-1.2.0-git-20110524-1321-win32.7z"
#wget -c "http://download.tomahawk-player.org/tomahawk-vlc-0.1.zip"
wget -c http://people.videolan.org/~jb/phonon/phonon-vlc-last.7z
echo "Extract binary..."
7z x vlc-*.7z
mv -v vlc-*/ vlc/
7z x phonon-vlc-last.7z
#mv -v vlc-*/ vlc/
#unzip tomahawk-vlc-0.1.zip
echo "Strip unneeded plugins from vlc/plugins..."
cd vlc/plugins/
rm -rvf video_*/ gui/ */libold* */libvcd* */libdvd* */liblibass* */libx264* */libschroe* */liblibmpeg2* \
*/libstream_out_* */libmjpeg_plugin* */libh264_plugin* */libzvbi_plugin* */lib*sub*
cd prefix/bin/plugins
rm -rvf libold* libvcd* libdvd* liblibass* libx264* libschroe* liblibmpeg2* \
libstream_out_* libmjpeg_plugin* libh264_plugin* libzvbi_plugin* lib*sub* \
*qt4* *skins2* libaccess_bd_plugin.dll \
libaudiobargraph_* libball_plugin.dll \
libdirac_plugin.dll \
libgnutls_plugin.dll \
libcaca_plugin.dll \
libfreetype_plugin.dll \
libaccess_output_shout_plugin.dll \
libremoteosd_plugin.dll \
libsdl_image_plugin.dll \
libvout_sdl_plugin.dll \
libpng_plugin.dll \
libgoom_plugin.dll \
libatmo_plugin.dll \
libmux_ts_plugin.dll \
libkate_plugin.dll \
libtaglib_plugin.dll
# this is for vlc-1.2
# rm -rvf video_*/ gui/ */libold* */libvcd* */libdvd* */liblibass* */libx264* */libschroe* */liblibmpeg2* \
# */libstream_out_* */libmjpeg_plugin* */libh264_plugin* */libzvbi_plugin* */lib*sub* \
# services_discover/ visualization/ control/ misc/
echo "Downloaded and stripped VLC"

Binary file not shown.

Before

Width:  |  Height:  |  Size: 643 B

After

Width:  |  Height:  |  Size: 4.2 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 856 B

After

Width:  |  Height:  |  Size: 5.1 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.5 KiB

After

Width:  |  Height:  |  Size: 7.3 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 204 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 7.3 KiB

0
data/images/configure.png Executable file → Normal file
View File

Before

Width:  |  Height:  |  Size: 1.8 KiB

After

Width:  |  Height:  |  Size: 1.8 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 6.4 KiB

After

Width:  |  Height:  |  Size: 68 KiB

BIN
data/images/filter.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 4.2 KiB

0
data/images/home.png Executable file → Normal file
View File

Before

Width:  |  Height:  |  Size: 1.7 KiB

After

Width:  |  Height:  |  Size: 1.7 KiB

BIN
data/images/info.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 4.2 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.0 MiB

0
data/images/music-icon.png Executable file → Normal file
View File

Before

Width:  |  Height:  |  Size: 1.8 KiB

After

Width:  |  Height:  |  Size: 1.8 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.2 KiB

After

Width:  |  Height:  |  Size: 1.0 MiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 91 KiB

BIN
data/images/share.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 4.8 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.5 KiB

After

Width:  |  Height:  |  Size: 3.1 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.0 MiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.4 KiB

After

Width:  |  Height:  |  Size: 19 KiB

0
data/images/view-refresh.png Executable file → Normal file
View File

Before

Width:  |  Height:  |  Size: 2.0 KiB

After

Width:  |  Height:  |  Size: 2.0 KiB

View File

@@ -31,19 +31,19 @@ Tomahawk.resolver = {
Tomahawk.timestamp = function() {
return Math.round( new Date()/1000 );
}
};
Tomahawk.dumpResult = function( result ) {
var results = result.results;
Tomahawk.log("Dumping " + results.length + " results for query " + result.qid + "...");
for(var i=0; i<results.length;i++)
{
var result = results[i];
Tomahawk.log( result.artist + " - " + result.track + " | " + result.url );
var result1 = results[i];
Tomahawk.log( result1.artist + " - " + result1.track + " | " + result1.url );
}
Tomahawk.log("Done.");
}
};
// javascript part of Tomahawk-Object API
Tomahawk.extend = function(object, members) {
@@ -57,7 +57,7 @@ Tomahawk.extend = function(object, members) {
}
return newObject;
}
};
// Resolver BaseObject, inherit it to implement your own resolver
@@ -77,7 +77,9 @@ var TomahawkResolver = {
{
var configJson = window.localStorage[ this.scriptPath() ];
if( configJson === undefined )
{
configJson = "{}";
}
var config = JSON.parse( configJson );
@@ -153,11 +155,15 @@ var TomahawkResolver = {
Tomahawk.valueForSubNode = function(node, tag)
{
if(node === undefined)
{
throw new Error("Tomahawk.valueForSubnode: node is undefined!");
}
var element = node.getElementsByTagName(tag)[0];
if( element === undefined )
{
return undefined;
}
return element.textContent;
};
@@ -165,11 +171,13 @@ Tomahawk.valueForSubNode = function(node, tag)
Tomahawk.syncRequest = function(url)
{
var xmlHttpRequest = new XMLHttpRequest();
xmlHttpRequest.open('GET', url, false);
xmlHttpRequest.send(null);
return xmlHttpRequest.responseText;
}
var xmlHttpRequest = new XMLHttpRequest();
xmlHttpRequest.open('GET', url, false);
xmlHttpRequest.send(null);
if (xmlHttpRequest.status == 200){
return xmlHttpRequest.responseText;
}
};
/**
*
@@ -210,7 +218,7 @@ Tomahawk.sha256=function(s){
m[l >> 5] |= 0x80 << (24 - l % 32);
m[((l + 64 >> 9) << 4) + 15] = l;
for ( var i = 0; i<m.length; i+=16 ) {
for ( i = 0; i<m.length; i+=16 ) {
a = HASH[0];
b = HASH[1];
c = HASH[2];
@@ -220,9 +228,15 @@ Tomahawk.sha256=function(s){
g = HASH[6];
h = HASH[7];
for ( var j = 0; j<64; j++) {
if (j < 16) W[j] = m[j + i];
else W[j] = safe_add(safe_add(safe_add(Gamma1256(W[j - 2]), W[j - 7]), Gamma0256(W[j - 15])), W[j - 16]);
for ( j = 0; j<64; j++) {
if (j < 16)
{
W[j] = m[j + i];
}
else
{
W[j] = safe_add(safe_add(safe_add(Gamma1256(W[j - 2]), W[j - 7]), Gamma0256(W[j - 15])), W[j - 16]);
}
T1 = safe_add(safe_add(safe_add(safe_add(h, Sigma1256(e)), Ch(e, f, g)), K[j]), W[j]);
T2 = safe_add(Sigma0256(a), Maj(a, b, c));
@@ -297,4 +311,10 @@ Tomahawk.sha256=function(s){
s = Utf8Encode(s);
return binb2hex(core_sha256(str2binb(s), s.length * chrsz));
}
};
// some aliases
Tomahawk.setTimeout = window.setTimeout;
Tomahawk.setInterval = window.setInterval;

View File

@@ -1,7 +1,6 @@
-- Script to migate from db version 24 to 25.
-- Added the social_attributes table.
--
-- Separate each command with %%
ALTER TABLE dynamic_playlist RENAME TO tmp_dynamic_playlist;

View File

@@ -0,0 +1,8 @@
-- Script to migate from db version 25 to 26.
-- Added the "autoload" column to dynamic_playlist
--
ALTER TABLE dynamic_playlist ADD COLUMN autoload BOOLEAN DEFAULT 'true';
UPDATE settings SET v = '26' WHERE k == 'schema_version';

View File

@@ -119,22 +119,22 @@
<message>
<location filename="src/libtomahawk/playlist/collectionmodel.cpp" line="168"/>
<source>Name</source>
<translation type="unfinished">Name</translation>
<translation>Name</translation>
</message>
<message>
<location filename="src/libtomahawk/playlist/collectionmodel.cpp" line="168"/>
<source>Tracks</source>
<translation type="unfinished">Stücke</translation>
<translation>Stücke</translation>
</message>
<message>
<location filename="src/libtomahawk/playlist/collectionmodel.cpp" line="168"/>
<source>Duration</source>
<translation type="unfinished">Spieldauer</translation>
<translation>Spieldauer</translation>
</message>
<message>
<location filename="src/libtomahawk/playlist/collectionmodel.cpp" line="168"/>
<source>Origin</source>
<translation type="unfinished">Quelle</translation>
<translation>Quelle</translation>
</message>
</context>
<context>
@@ -142,17 +142,17 @@
<message>
<location filename="src/libtomahawk/playlist/collectionview.cpp" line="75"/>
<source>&amp;Play</source>
<translation type="unfinished">&amp;Abspielen</translation>
<translation>&amp;Abspielen</translation>
</message>
<message>
<location filename="src/libtomahawk/playlist/collectionview.cpp" line="76"/>
<source>Add to &amp;Queue</source>
<translation type="unfinished">Zur &amp;Warteschlange hinzufügen</translation>
<translation>In &amp;Warteschlange einreihen</translation>
</message>
<message>
<location filename="src/libtomahawk/playlist/collectionview.cpp" line="108"/>
<source>This collection is empty.</source>
<translation type="unfinished">Diese Sammlung ist leer.</translation>
<translation>Diese Sammlung ist leer.</translation>
</message>
</context>
<context>
@@ -175,19 +175,19 @@
<message>
<location filename="src/sip/jabber/jabber.cpp" line="124"/>
<source>Add Friend...</source>
<translation type="unfinished">Freund hinzufügen</translation>
<translation>Freund hinzufügen</translation>
</message>
<message>
<location filename="src/sip/jabber/jabber.cpp" line="169"/>
<location filename="src/sip/jreen/jabber.cpp" line="183"/>
<source>Add Friend</source>
<translation type="unfinished">Freund hinzufügen</translation>
<translation>Freund hinzufügen</translation>
</message>
<message>
<location filename="src/sip/jabber/jabber.cpp" line="170"/>
<location filename="src/sip/jreen/jabber.cpp" line="184"/>
<source>Enter Jabber ID:</source>
<translation type="unfinished">Jabber-ID eingeben:</translation>
<translation>Jabber-ID eingeben:</translation>
</message>
</context>
<context>
@@ -208,27 +208,27 @@
<message>
<location filename="src/libtomahawk/widgets/newplaylistwidget.ui" line="22"/>
<source>Enter a title for the new playlist:</source>
<translation type="unfinished">Gib einen Titel für die neue Playliste ein:</translation>
<translation>Gib einen Titel für die neue Playliste ein:</translation>
</message>
<message>
<location filename="src/libtomahawk/widgets/newplaylistwidget.ui" line="44"/>
<source>Tomahawk offers a variety of ways to help you create playlists and find music you enjoy!</source>
<translation type="unfinished">Tomahawk bietet verschiedene Wege, Playlisten zu erstellen und Musik zu finden, die du magst!</translation>
<translation>Tomahawk bietet verschiedene Wege, Playlisten zu erstellen und Musik zu finden, die du magst!</translation>
</message>
<message>
<location filename="src/libtomahawk/widgets/newplaylistwidget.ui" line="59"/>
<source>Just enter a genre or tag name and Tomahawk will suggest a few songs to get you started with your new playlist:</source>
<translation type="unfinished">Gib einfach ein Genre oder einen Tagnamen ein und Tomahawk wird dir einige Lieder vorschlagen, um dir zu helfen, eine neue Playliste zu erstellen:</translation>
<translation>Gib einfach ein Genre oder einen Tagnamen ein, und Tomahawk wird dir einige Lieder vorschlagen und dir helfen eine neue Playliste zu erstellen:</translation>
</message>
<message>
<location filename="src/libtomahawk/widgets/newplaylistwidget.cpp" line="45"/>
<source>&amp;Create Playlist</source>
<translation type="unfinished">Playliste &amp;erstellen</translation>
<translation>Playliste &amp;erstellen</translation>
</message>
<message>
<location filename="src/libtomahawk/widgets/newplaylistwidget.h" line="51"/>
<source>Create a new playlist</source>
<translation type="unfinished">Erstelle eine neue Playliste</translation>
<translation>Erstelle eine neue Playliste</translation>
</message>
</context>
<context>
@@ -270,27 +270,27 @@
<message>
<location filename="src/libtomahawk/playlist/playlistview.cpp" line="74"/>
<source>&amp;Play</source>
<translation type="unfinished">&amp;Abspielen</translation>
<translation>&amp;Abspielen</translation>
</message>
<message>
<location filename="src/libtomahawk/playlist/playlistview.cpp" line="75"/>
<source>Add to &amp;Queue</source>
<translation type="unfinished">In &amp;Warteschlange einreihen</translation>
<translation>In &amp;Warteschlange einreihen</translation>
</message>
<message>
<location filename="src/libtomahawk/playlist/playlistview.cpp" line="79"/>
<source>&amp;Delete Items</source>
<translation type="unfinished">Elemente &amp;entfernen</translation>
<translation>Elemente &amp;entfernen</translation>
</message>
<message>
<location filename="src/libtomahawk/playlist/playlistview.cpp" line="79"/>
<source>&amp;Delete Item</source>
<translation type="unfinished">Element &amp;entfernen</translation>
<translation>Element &amp;entfernen</translation>
</message>
<message>
<location filename="src/libtomahawk/playlist/playlistview.cpp" line="143"/>
<source>This playlist is currently empty. Add some tracks to it and enjoy the music!</source>
<translation type="unfinished">Die Playliste ist derzeit leer. Füge einige Stücke hinzu und genieße die Musik!</translation>
<translation>Die Playliste ist derzeit leer. Füge einige Stücke hinzu und genieße die Musik!</translation>
</message>
</context>
<context>
@@ -359,18 +359,18 @@
<message>
<location filename="src/settingsdialog.ui" line="30"/>
<source>Jabber</source>
<translation type="unfinished">Jabber</translation>
<translation>Jabber</translation>
</message>
<message>
<location filename="src/settingsdialog.ui" line="53"/>
<source>Jabber ID:</source>
<translation type="unfinished">Jabber-ID:</translation>
<translation>Jabber-ID:</translation>
</message>
<message>
<location filename="src/settingsdialog.ui" line="79"/>
<location filename="src/settingsdialog.ui" line="524"/>
<source>Password:</source>
<translation type="unfinished">Passwort:</translation>
<translation>Passwort:</translation>
</message>
<message>
<location filename="src/settingsdialog.ui" line="132"/>
@@ -380,138 +380,138 @@
<message>
<location filename="src/settingsdialog.ui" line="152"/>
<source>Server:</source>
<translation type="unfinished">Server:</translation>
<translation>Server:</translation>
</message>
<message>
<location filename="src/settingsdialog.ui" line="175"/>
<source>Port:</source>
<translation type="unfinished">Port:</translation>
<translation>Port:</translation>
</message>
<message>
<location filename="src/settingsdialog.ui" line="238"/>
<source>Network</source>
<translation type="unfinished">Netzwerk</translation>
<translation>Netzwerk</translation>
</message>
<message>
<location filename="src/settingsdialog.ui" line="250"/>
<source>Advanced Network Settings</source>
<translation type="unfinished">Erweiterte Netzwerkeinstellungen</translation>
<translation>Erweiterte Netzwerkeinstellungen</translation>
</message>
<message>
<location filename="src/settingsdialog.ui" line="267"/>
<source>If you&apos;re having difficulty connecting to peers, try setting this to your external IP address/host name and a port number (default 50210). Make sure to forward that port to this machine!</source>
<translation type="unfinished">Wenn du Schwierigkeiten hast, zu anderen Leuten zu verbinden, versuche diene externe IP-Addresse/Rechnernamen und eine Portnummer (Standard 50210) hier einzutragen. Stelle sicher, den Port entsprechend an diesen Rechner weiterzuleiten!</translation>
<translation>Wenn du Schwierigkeiten hast, dich mit anderen Leuten zu verbinden, versuche deine externe IP-Adresse/Rechnernamen und eine Portnummer (Standard 50210) hier einzutragen. Stelle sicher, den Port entsprechend an diesen Rechner weiterzuleiten!</translation>
</message>
<message>
<location filename="src/settingsdialog.ui" line="285"/>
<source>Static Host Name:</source>
<translation type="unfinished">Statischer Rechnername:</translation>
<translation>Statischer Rechnername:</translation>
</message>
<message>
<location filename="src/settingsdialog.ui" line="301"/>
<source>Static Port:</source>
<translation type="unfinished">Statischer Port:</translation>
<translation>Statischer Port:</translation>
</message>
<message>
<location filename="src/settingsdialog.ui" line="323"/>
<source>Always use static host name/port? (Overrides UPnP discovery/port forwarding)</source>
<translation type="unfinished">Statischen Rechnernamen/Port immer benutzen? (Überschreibt UPnP-discovery/Portweiterleitung)</translation>
<translation>Statischen Rechnernamen/Port immer benutzen? (Überschreibt UPnP-discovery/Portweiterleitung)</translation>
</message>
<message>
<location filename="src/settingsdialog.ui" line="347"/>
<source>Proxy Settings...</source>
<translation type="unfinished">Proxy-Einstellungen</translation>
<translation>Proxy-Einstellungen</translation>
</message>
<message>
<location filename="src/settingsdialog.ui" line="385"/>
<source>Playdar HTTP API</source>
<translation type="unfinished">Playdar HTTP API</translation>
<translation>Playdar HTTP API</translation>
</message>
<message>
<location filename="src/settingsdialog.ui" line="398"/>
<source>Connect automatically when Tomahawk starts</source>
<translation type="unfinished">Automatisch beim Start von Tomahawk verbinden</translation>
<translation>Automatisch beim Start von Tomahawk verbinden</translation>
</message>
<message>
<location filename="src/settingsdialog.ui" line="411"/>
<source>Use UPnP to establish port forward</source>
<translation type="unfinished">Benutze UPnP um die Portweiterleitung zu konfigurieren</translation>
<translation>Benutze UPnP um die Portweiterleitung einzurichten</translation>
</message>
<message>
<location filename="src/settingsdialog.ui" line="425"/>
<source>Local Music</source>
<translation type="unfinished">Lokale Musik</translation>
<translation>Lokale Musik</translation>
</message>
<message>
<location filename="src/settingsdialog.ui" line="436"/>
<source>Path to scan for music files:</source>
<translation type="unfinished">Pfad zu den Musikdateien:</translation>
<translation>Pfad zu den Musikdateien:</translation>
</message>
<message>
<location filename="src/settingsdialog.ui" line="448"/>
<source>...</source>
<translation type="unfinished"></translation>
<translation></translation>
</message>
<message>
<location filename="src/settingsdialog.ui" line="490"/>
<source>Last.fm</source>
<translation type="unfinished">Last.fm</translation>
<translation>Last.fm</translation>
</message>
<message>
<location filename="src/settingsdialog.ui" line="499"/>
<source>Scrobble tracks to Last.fm</source>
<translation type="unfinished">Gespielte Stücke an Last.fm übertragen</translation>
<translation>Gespielte Stücke an Last.fm übertragen</translation>
</message>
<message>
<location filename="src/settingsdialog.ui" line="506"/>
<source>Last.fm Login</source>
<translation type="unfinished">Last.fm Anmeldung</translation>
<translation>Last.fm Anmeldung</translation>
</message>
<message>
<location filename="src/settingsdialog.ui" line="514"/>
<source>Username:</source>
<translation type="unfinished">Benutzername:</translation>
<translation>Benutzername:</translation>
</message>
<message>
<location filename="src/settingsdialog.ui" line="540"/>
<source>Test Login</source>
<translation type="unfinished">Anmeldung Testen</translation>
<translation>Anmeldung testen</translation>
</message>
<message>
<location filename="src/settingsdialog.ui" line="564"/>
<source>Script Resolvers</source>
<translation type="unfinished"></translation>
<translation>Script Resolver</translation>
</message>
<message>
<location filename="src/settingsdialog.ui" line="570"/>
<source>Loaded script resolvers:</source>
<translation type="unfinished"></translation>
<translation>Geladene Script Resolver:</translation>
</message>
<message>
<location filename="src/settingsdialog.cpp" line="163"/>
<source>Select Music Folder</source>
<translation type="unfinished">Musikordner auswählen</translation>
<translation>Musikordner auswählen</translation>
</message>
<message>
<location filename="src/settingsdialog.cpp" line="250"/>
<location filename="src/settingsdialog.cpp" line="262"/>
<source>Failed</source>
<translation type="unfinished">Fehlgeschlagen</translation>
<translation>Fehlgeschlagen</translation>
</message>
<message>
<location filename="src/settingsdialog.cpp" line="255"/>
<source>Success</source>
<translation type="unfinished">Erfolgreich</translation>
<translation>Erfolgreich</translation>
</message>
<message>
<location filename="src/settingsdialog.cpp" line="268"/>
<source>Could not contact server</source>
<translation type="unfinished">Konnte den Server nicht erreichen</translation>
<translation>Konnte den Server nicht erreichen</translation>
</message>
<message>
<location filename="src/settingsdialog.cpp" line="338"/>
<source>Load script resolver file</source>
<translation type="unfinished"></translation>
<translation>Script Resolver laden</translation>
</message>
</context>
<context>
@@ -519,17 +519,17 @@
<message>
<location filename="src/sourcetree/sourcetreeview.cpp" line="558"/>
<source>Offline</source>
<translation type="unfinished">Nicht Verbunden</translation>
<translation>Nicht Verbunden</translation>
</message>
<message>
<location filename="src/sourcetree/sourcetreeview.cpp" line="560"/>
<source>All available tracks</source>
<translation type="unfinished">Alle verfügbaren Stücke</translation>
<translation>Alle verfügbaren Stücke</translation>
</message>
<message>
<location filename="src/sourcetree/sourcetreeview.cpp" line="564"/>
<source>Online</source>
<translation type="unfinished">Verbunden</translation>
<translation>Verbunden</translation>
</message>
</context>
<context>
@@ -537,27 +537,27 @@
<message>
<location filename="src/libtomahawk/widgets/infowidgets/sourceinfowidget.ui" line="26"/>
<source>Recent Albums</source>
<translation type="unfinished">Aktuelle Alben</translation>
<translation>Aktuelle Alben</translation>
</message>
<message>
<location filename="src/libtomahawk/widgets/infowidgets/sourceinfowidget.ui" line="68"/>
<source>Latest Additions to their Collection</source>
<translation type="unfinished">Zuletzt zur Sammlung hinzugefügte Stücke</translation>
<translation>Zuletzt zur Sammlung hinzugefügt</translation>
</message>
<message>
<location filename="src/libtomahawk/widgets/infowidgets/sourceinfowidget.ui" line="89"/>
<source>Recently played Tracks</source>
<translation type="unfinished">Aktuell gespiele Stücke</translation>
<translation>Zuletzt gespiele Stücke</translation>
</message>
<message>
<location filename="src/libtomahawk/widgets/infowidgets/sourceinfowidget.cpp" line="65"/>
<source>Info about %1</source>
<translation type="unfinished">Information über %1</translation>
<translation>Information über %1</translation>
</message>
<message>
<location filename="src/libtomahawk/widgets/infowidgets/sourceinfowidget.cpp" line="65"/>
<source>Your Collection</source>
<translation type="unfinished">Deine Sammlung</translation>
<translation>Deine Sammlung</translation>
</message>
</context>
<context>
@@ -654,17 +654,17 @@
<message>
<location filename="src/sourcetree/sourcetreeview.cpp" line="125"/>
<source>&amp;Load Playlist</source>
<translation type="unfinished">&amp;Lade Playliste</translation>
<translation>&amp;Lade Playliste</translation>
</message>
<message>
<location filename="src/sourcetree/sourcetreeview.cpp" line="126"/>
<source>&amp;Rename Playlist</source>
<translation type="unfinished">Playliste &amp;umbenennen</translation>
<translation>Playliste &amp;umbenennen</translation>
</message>
<message>
<location filename="src/sourcetree/sourcetreeview.cpp" line="128"/>
<source>&amp;Delete Playlist</source>
<translation type="unfinished">Playliste &amp;löschen</translation>
<translation>Playliste &amp;löschen</translation>
</message>
</context>
<context>
@@ -698,7 +698,7 @@ Bitte ändere den Filter oder versuche es erneut.</translation>
<message>
<location filename="src/libtomahawk/playlist/dynamic/widgets/DynamicSetupWidget.cpp" line="62"/>
<source>Generate</source>
<translation type="unfinished">Erzeugen</translation>
<translation>Erzeugen</translation>
</message>
</context>
<context>
@@ -706,17 +706,17 @@ Bitte ändere den Filter oder versuche es erneut.</translation>
<message>
<location filename="src/libtomahawk/playlist/dynamic/DynamicView.cpp" line="135"/>
<source>Add some filters above to seed this station!</source>
<translation type="unfinished">Füge einige Filter hinzu, um diese Station zu initialisieren!</translation>
<translation>Füge einige Filter hinzu, um diese Station zu starten!</translation>
</message>
<message>
<location filename="src/libtomahawk/playlist/dynamic/DynamicView.cpp" line="140"/>
<source>Press Generate to get started!</source>
<translation type="unfinished">Drücke Erzeugen, um zu beginnen!</translation>
<translation>Drücke Erzeugen, und los geht&apos;s!</translation>
</message>
<message>
<location filename="src/libtomahawk/playlist/dynamic/DynamicView.cpp" line="142"/>
<source>Add some filters above, and press Generate to get started!</source>
<translation type="unfinished">Füge oben einige Filter hinzu und drücke Erzeugen um zu beginnen!</translation>
<translation>Füge oben einige Filter hinzu und drücke Erzeugen um loszulegen!</translation>
</message>
</context>
<context>
@@ -1091,53 +1091,53 @@ Bitte ändere den Filter oder versuche es erneut.</translation>
<message>
<location filename="src/tomahawkwindow.ui" line="14"/>
<source>Tomahawk</source>
<translation type="unfinished">Tomahawk</translation>
<translation>Tomahawk</translation>
</message>
<message>
<location filename="src/tomahawkwindow.ui" line="43"/>
<source>&amp;Settings</source>
<translation type="unfinished">&amp;Einstellungen</translation>
<translation>&amp;Einstellungen</translation>
</message>
<message>
<location filename="src/tomahawkwindow.ui" line="49"/>
<source>&amp;Music Player</source>
<translation type="unfinished">&amp;Abspielprogramm</translation>
<translation>&amp;Music Player</translation>
</message>
<message>
<location filename="src/tomahawkwindow.ui" line="60"/>
<source>&amp;Playlist</source>
<translation type="unfinished">&amp;Playliste</translation>
<translation>&amp;Playliste</translation>
</message>
<message>
<location filename="src/tomahawkwindow.ui" line="70"/>
<source>&amp;Network</source>
<translation type="unfinished">&amp;Netzwerk</translation>
<translation>&amp;Netzwerk</translation>
</message>
<message>
<location filename="src/tomahawkwindow.ui" line="77"/>
<source>&amp;Help</source>
<translation type="unfinished">&amp;Hilfe</translation>
<translation>&amp;Hilfe</translation>
</message>
<message>
<location filename="src/tomahawkwindow.ui" line="90"/>
<source>&amp;Quit</source>
<translation type="unfinished">&amp;Verlassen</translation>
<translation>&amp;Verlassen</translation>
</message>
<message>
<location filename="src/tomahawkwindow.ui" line="93"/>
<source>Ctrl+Q</source>
<translation type="unfinished">Strg+Q</translation>
<translation>Ctrl+Q</translation>
</message>
<message>
<location filename="src/tomahawkwindow.ui" line="101"/>
<location filename="src/tomahawkwindow.cpp" line="471"/>
<source>Go &amp;online</source>
<translation type="unfinished">&amp;Verbindung herstellen</translation>
<translation>&amp;Verbindung herstellen</translation>
</message>
<message>
<location filename="src/tomahawkwindow.ui" line="106"/>
<source>Add &amp;Friend...</source>
<translation type="unfinished">Freund &amp;hinzufügen</translation>
<translation>Freund &amp;hinzufügen</translation>
</message>
<message>
<location filename="src/tomahawkwindow.ui" line="111"/>
@@ -1147,58 +1147,58 @@ Bitte ändere den Filter oder versuche es erneut.</translation>
<message>
<location filename="src/tomahawkwindow.ui" line="116"/>
<source>&amp;Configure Tomahawk...</source>
<translation type="unfinished">Tomahawk &amp;einrichten</translation>
<translation>Tomahawk &amp;einrichten</translation>
</message>
<message>
<location filename="src/tomahawkwindow.ui" line="124"/>
<source>Load &amp;XSPF...</source>
<translation type="unfinished">&amp;XSPF-Datei laden</translation>
<translation>&amp;XSPF laden</translation>
</message>
<message>
<location filename="src/tomahawkwindow.ui" line="129"/>
<source>Create &amp;New Playlist...</source>
<translation type="unfinished">Neue &amp;Playliste erstellen</translation>
<translation>Neue &amp;Playliste erstellen</translation>
</message>
<message>
<location filename="src/tomahawkwindow.ui" line="134"/>
<source>About &amp;Tomahawk...</source>
<translation type="unfinished">Über &amp;Tomahawk</translation>
<translation>Über &amp;Tomahawk</translation>
</message>
<message>
<location filename="src/tomahawkwindow.ui" line="142"/>
<source>Create New &amp;Automatic Playlist</source>
<translation type="unfinished">Neue, &amp;automatische Playliste erstellen</translation>
<translation>Neue &amp;automatische Playliste erstellen</translation>
</message>
<message>
<location filename="src/tomahawkwindow.ui" line="147"/>
<source>Create New &amp;Station</source>
<translation type="unfinished">Neue &amp;Station erstellen</translation>
<translation>Neue &amp;Station erstellen</translation>
</message>
<message>
<location filename="src/tomahawkwindow.ui" line="152"/>
<source>Show Offline Sources</source>
<translation type="unfinished">Nicht-Verfügbare Quellen anzeigen</translation>
<translation>Nicht-Verfügbare Quellen anzeigen</translation>
</message>
<message>
<location filename="src/tomahawkwindow.ui" line="157"/>
<source>Hide Offline Sources</source>
<translation type="unfinished">Nicht-Verfügbare Quellen ausblenden</translation>
<translation>Nicht-Verfügbare Quellen ausblenden</translation>
</message>
<message>
<location filename="src/tomahawkwindow.cpp" line="150"/>
<location filename="src/tomahawkwindow.cpp" line="166"/>
<source>Check for updates...</source>
<translation type="unfinished">Teste auf updates</translation>
<translation type="unfinished">Suche nach Updates</translation>
</message>
<message>
<location filename="src/tomahawkwindow.cpp" line="170"/>
<source>Back</source>
<translation type="unfinished">Zurück</translation>
<translation>Zurück</translation>
</message>
<message>
<location filename="src/tomahawkwindow.cpp" line="171"/>
<source>Forward</source>
<translation type="unfinished">Forwärts</translation>
<translation>Vorwärts</translation>
</message>
<message>
<location filename="src/tomahawkwindow.cpp" line="172"/>
@@ -1210,37 +1210,37 @@ Bitte ändere den Filter oder versuche es erneut.</translation>
<location filename="src/tomahawkwindow.cpp" line="339"/>
<location filename="src/tomahawkwindow.cpp" line="347"/>
<source>Connect To Peer</source>
<translation type="unfinished">Zu Gegenstelle verbinden</translation>
<translation>Zu Gegenstelle verbinden</translation>
</message>
<message>
<location filename="src/tomahawkwindow.cpp" line="333"/>
<source>Enter peer address:</source>
<translation type="unfinished">Gib die Adresse der Gegenstelle ein:</translation>
<translation>Gib die Adresse der Gegenstelle ein:</translation>
</message>
<message>
<location filename="src/tomahawkwindow.cpp" line="340"/>
<source>Enter peer port:</source>
<translation type="unfinished">Gib den Port der Gegenstelle ein:</translation>
<translation>Gib den Port der Gegenstelle ein:</translation>
</message>
<message>
<location filename="src/tomahawkwindow.cpp" line="348"/>
<source>Enter peer key:</source>
<translation type="unfinished">Gib den Schlüssel der Gegenstelle ein:</translation>
<translation>Gib den Schlüssel der Gegenstelle ein:</translation>
</message>
<message>
<location filename="src/tomahawkwindow.cpp" line="464"/>
<source>Go &amp;offline</source>
<translation type="unfinished">Verbindung &amp;trennen</translation>
<translation>Verbindung &amp;trennen</translation>
</message>
<message>
<location filename="src/tomahawkwindow.cpp" line="481"/>
<source>Authentication Error</source>
<translation type="unfinished">Authentifizierungsfehler</translation>
<translation>Authentifizierungsfehler</translation>
</message>
<message>
<location filename="src/tomahawkwindow.cpp" line="496"/>
<source>by</source>
<translation type="unfinished">von</translation>
<translation>von</translation>
</message>
<message>
<location filename="src/tomahawkwindow.cpp" line="506"/>
@@ -1357,17 +1357,17 @@ Bitte ändere den Filter oder versuche es erneut.</translation>
<message>
<location filename="src/transferview.cpp" line="46"/>
<source>Peer</source>
<translation type="unfinished">Gegenstelle</translation>
<translation>Gegenstelle</translation>
</message>
<message>
<location filename="src/transferview.cpp" line="46"/>
<source>Rate</source>
<translation type="unfinished">Rate</translation>
<translation>Rate</translation>
</message>
<message>
<location filename="src/transferview.cpp" line="46"/>
<source>Track</source>
<translation type="unfinished">Stück</translation>
<translation>Stück</translation>
</message>
</context>
<context>
@@ -1435,22 +1435,22 @@ If connections to peers seem to have been lost, just press the appropriate butto
<message>
<location filename="src/libtomahawk/widgets/welcomewidget.ui" line="22"/>
<source>Recently played playlists:</source>
<translation type="unfinished">Aktuell gespielte Playlisten:</translation>
<translation>Zuletzt gespielte Playlisten:</translation>
</message>
<message>
<location filename="src/libtomahawk/widgets/welcomewidget.ui" line="37"/>
<source>Recently played tracks:</source>
<translation type="unfinished">Aktuell gespielte Stücke:</translation>
<translation>Zuletzt gespielte Stücke:</translation>
</message>
<message>
<location filename="src/libtomahawk/widgets/welcomewidget.cpp" line="81"/>
<source>You have not played any playlists yet.</source>
<translation type="unfinished">Du hast bisher keine Playlisten abgespielt.</translation>
<translation>Du hast bisher keine Playlisten abgespielt.</translation>
</message>
<message>
<location filename="src/libtomahawk/widgets/welcomewidget.h" line="106"/>
<source>Welcome to Tomahawk</source>
<translation type="unfinished">Willkommen bei Tomahawk</translation>
<translation>Willkommen bei Tomahawk</translation>
</message>
</context>
<context>

View File

View File

View File

@@ -1,102 +1,110 @@
<RCC>
<qresource>
<file>./data/images/avatar-dude-plus.png</file>
<file>./data/images/avatar-dude.png</file>
<file>./data/images/back-pressed.png</file>
<file>./data/images/back-rest.png</file>
<file>./data/images/cover-shadow.png</file>
<file>./data/images/loved.png</file>
<file>./data/images/not-loved.png</file>
<file>./data/images/no-album-art-placeholder.png</file>
<file>./data/images/now-playing-panel.png</file>
<file>./data/images/now-playing-speaker.png</file>
<file>./data/images/pause-pressed.png</file>
<file>./data/images/pause-rest.png</file>
<file>./data/images/play-pressed.png</file>
<file>./data/images/play-rest.png</file>
<file>./data/images/sipplugin-add.png</file>
<file>./data/images/sipplugin-remove.png</file>
<file>./data/images/playlist-icon.png</file>
<file>./data/images/repeat-1-on-pressed.png</file>
<file>./data/images/repeat-1-on-rest.png</file>
<file>./data/images/repeat-all-on-pressed.png</file>
<file>./data/images/repeat-all-on-rest.png</file>
<file>./data/images/repeat-off-pressed.png</file>
<file>./data/images/repeat-off-rest.png</file>
<file>./data/images/search-box-dismiss-x.png</file>
<file>./data/images/seek-and-volume-knob-pressed.png</file>
<file>./data/images/seek-and-volume-knob-rest.png</file>
<file>./data/images/seek-slider-bkg.png</file>
<file>./data/images/seek-slider-level.png</file>
<file>./data/images/shuffle-off-pressed.png</file>
<file>./data/images/shuffle-off-rest.png</file>
<file>./data/images/shuffle-on-pressed.png</file>
<file>./data/images/shuffle-on-rest.png</file>
<file>./data/images/skip-pressed.png</file>
<file>./data/images/skip-rest.png</file>
<file>./data/images/user-avatar.png</file>
<file>./data/images/view-toggle-active-centre.png</file>
<file>./data/images/view-toggle-active-left.png</file>
<file>./data/images/view-toggle-active-right.png</file>
<file>./data/images/view-toggle-icon-artist-active.png</file>
<file>./data/images/view-toggle-icon-artist-inactive.png</file>
<file>./data/images/view-toggle-icon-cloud-active.png</file>
<file>./data/images/view-toggle-icon-cloud-inactive.png</file>
<file>./data/images/view-toggle-icon-list-active.png</file>
<file>./data/images/view-toggle-icon-list-inactive.png</file>
<file>./data/images/view-toggle-inactive-centre.png</file>
<file>./data/images/view-toggle-inactive-left.png</file>
<file>./data/images/view-toggle-inactive-right.png</file>
<file>./data/images/view-toggle-pressed-centre.png</file>
<file>./data/images/view-toggle-pressed-left.png</file>
<file>./data/images/view-toggle-pressed-right.png</file>
<file>./data/images/list-add.png</file>
<file>./data/images/list-remove.png</file>
<file>./data/images/arrow-up-double.png</file>
<file>./data/images/arrow-down-double.png</file>
<file>./data/images/volume-icon-full.png</file>
<file>./data/images/arrow-right-double.png</file>
<file>./data/images/view-refresh.png</file>
<file>./data/images/volume-icon-muted.png</file>
<file>./data/images/volume-slider-bkg.png</file>
<file>./data/images/volume-slider-level.png</file>
<file>./data/images/echonest_logo.png</file>
<file>./data/images/loading-animation.gif</file>
<file>./data/images/home.png</file>
<file>./data/images/back.png</file>
<file>./data/images/forward.png</file>
<file>./data/images/music-icon.png</file>
<file>./data/images/configure.png</file>
<file>./data/images/create-playlist.png</file>
<file>./data/images/add.png</file>
<file>./data/images/recently-played.png</file>
<file>./data/images/supercollection.png</file>
<file>./data/images/sipplugin-online.png</file>
<file>./data/images/sipplugin-offline.png</file>
<file>./data/images/advanced-settings.png</file>
<file>./data/images/account-settings.png</file>
<file>./data/images/music-settings.png</file>
<file>./data/images/resolvers-settings.png</file>
<file>./data/images/lastfm-settings.png</file>
<file>./data/images/automatic-playlist.png</file>
<file>./data/images/station.png</file>
<file>./data/images/new-additions.png</file>
<file>./data/stylesheets/topbar-radiobuttons.css</file>
<file>./data/icons/tomahawk-icon-16x16.png</file>
<file>./data/icons/tomahawk-icon-32x32.png</file>
<file>./data/icons/tomahawk-icon-64x64.png</file>
<file>./data/icons/tomahawk-icon-128x128.png</file>
<file>./data/icons/tomahawk-icon-256x256.png</file>
<file>./data/icons/tomahawk-icon-512x512.png</file>
<file>./data/icons/audio-x-generic-22x22.png</file>
<file>./data/icons/audio-x-generic-32x32.png</file>
<file>./data/icons/audio-x-generic-16x16.png</file>
<file>./data/www/auth.html</file>
<file>./data/www/auth.na.html</file>
<file>./data/www/tomahawk_banner_small.png</file>
<file>./data/sql/dbmigrate-22_to_23.sql</file>
<file>./data/sql/dbmigrate-23_to_24.sql</file>
<file>./data/sql/dbmigrate-24_to_25.sql</file>
<file>./data/js/tomahawk.js</file>
</qresource>
<qresource prefix="/">
<file>data/images/avatar-dude-plus.png</file>
<file>data/images/avatar-dude.png</file>
<file>data/images/back-pressed.png</file>
<file>data/images/back-rest.png</file>
<file>data/images/cover-shadow.png</file>
<file>data/images/filter.png</file>
<file>data/images/loved.png</file>
<file>data/images/not-loved.png</file>
<file>data/images/no-album-art-placeholder.png</file>
<file>data/images/no-artist-image-placeholder.png</file>
<file>data/images/track-placeholder.png</file>
<file>data/images/now-playing-panel.png</file>
<file>data/images/now-playing-speaker.png</file>
<file>data/images/pause-pressed.png</file>
<file>data/images/pause-rest.png</file>
<file>data/images/play-pressed.png</file>
<file>data/images/play-rest.png</file>
<file>data/images/sipplugin-add.png</file>
<file>data/images/sipplugin-remove.png</file>
<file>data/images/playlist-icon.png</file>
<file>data/images/repeat-1-on-pressed.png</file>
<file>data/images/repeat-1-on-rest.png</file>
<file>data/images/repeat-all-on-pressed.png</file>
<file>data/images/repeat-all-on-rest.png</file>
<file>data/images/repeat-off-pressed.png</file>
<file>data/images/repeat-off-rest.png</file>
<file>data/images/search-box-dismiss-x.png</file>
<file>data/images/seek-and-volume-knob-pressed.png</file>
<file>data/images/seek-and-volume-knob-rest.png</file>
<file>data/images/seek-slider-bkg.png</file>
<file>data/images/seek-slider-level.png</file>
<file>data/images/shuffle-off-pressed.png</file>
<file>data/images/shuffle-off-rest.png</file>
<file>data/images/shuffle-on-pressed.png</file>
<file>data/images/shuffle-on-rest.png</file>
<file>data/images/skip-pressed.png</file>
<file>data/images/skip-rest.png</file>
<file>data/images/user-avatar.png</file>
<file>data/images/view-toggle-active-centre.png</file>
<file>data/images/view-toggle-active-left.png</file>
<file>data/images/view-toggle-active-right.png</file>
<file>data/images/view-toggle-icon-artist-active.png</file>
<file>data/images/view-toggle-icon-artist-inactive.png</file>
<file>data/images/view-toggle-icon-cloud-active.png</file>
<file>data/images/view-toggle-icon-cloud-inactive.png</file>
<file>data/images/view-toggle-icon-list-active.png</file>
<file>data/images/view-toggle-icon-list-inactive.png</file>
<file>data/images/view-toggle-inactive-centre.png</file>
<file>data/images/view-toggle-inactive-left.png</file>
<file>data/images/view-toggle-inactive-right.png</file>
<file>data/images/view-toggle-pressed-centre.png</file>
<file>data/images/view-toggle-pressed-left.png</file>
<file>data/images/view-toggle-pressed-right.png</file>
<file>data/images/list-add.png</file>
<file>data/images/list-remove.png</file>
<file>data/images/arrow-up-double.png</file>
<file>data/images/arrow-down-double.png</file>
<file>data/images/volume-icon-full.png</file>
<file>data/images/arrow-right-double.png</file>
<file>data/images/view-refresh.png</file>
<file>data/images/volume-icon-muted.png</file>
<file>data/images/volume-slider-bkg.png</file>
<file>data/images/volume-slider-level.png</file>
<file>data/images/echonest_logo.png</file>
<file>data/images/loading-animation.gif</file>
<file>data/images/info.png</file>
<file>data/images/home.png</file>
<file>data/images/back.png</file>
<file>data/images/forward.png</file>
<file>data/images/music-icon.png</file>
<file>data/images/configure.png</file>
<file>data/images/create-playlist.png</file>
<file>data/images/add.png</file>
<file>data/images/recently-played.png</file>
<file>data/images/supercollection.png</file>
<file>data/images/sipplugin-online.png</file>
<file>data/images/sipplugin-offline.png</file>
<file>data/images/advanced-settings.png</file>
<file>data/images/account-settings.png</file>
<file>data/images/music-settings.png</file>
<file>data/images/resolvers-settings.png</file>
<file>data/images/lastfm-settings.png</file>
<file>data/images/automatic-playlist.png</file>
<file>data/images/station.png</file>
<file>data/images/new-additions.png</file>
<file>data/images/loved_playlist.png</file>
<file>data/images/dashboard.png</file>
<file>data/stylesheets/topbar-radiobuttons.css</file>
<file>data/icons/tomahawk-icon-16x16.png</file>
<file>data/icons/tomahawk-icon-32x32.png</file>
<file>data/icons/tomahawk-icon-64x64.png</file>
<file>data/icons/tomahawk-icon-128x128.png</file>
<file>data/icons/tomahawk-icon-256x256.png</file>
<file>data/icons/tomahawk-icon-512x512.png</file>
<file>data/icons/audio-x-generic-22x22.png</file>
<file>data/icons/audio-x-generic-32x32.png</file>
<file>data/icons/audio-x-generic-16x16.png</file>
<file>data/www/auth.html</file>
<file>data/www/auth.na.html</file>
<file>data/www/tomahawk_banner_small.png</file>
<file>data/sql/dbmigrate-22_to_23.sql</file>
<file>data/sql/dbmigrate-23_to_24.sql</file>
<file>data/sql/dbmigrate-24_to_25.sql</file>
<file>data/sql/dbmigrate-25_to_26.sql</file>
<file>data/js/tomahawk.js</file>
<file>data/images/avatar_frame.png</file>
</qresource>
</RCC>

View File

@@ -41,12 +41,17 @@ if (APPLE)
edited_plist # save in this variable
"${plist}" # from the contents of this var
)
IF( NOT CMAKE_BUILD_TYPE STREQUAL "Release" )
STRING( REPLACE "http://download.tomahawk-player.org/sparkle" # match this
"http://download.tomahawk-player.org/sparkle-debug" #replace with debug url
edited_plist # save in this variable
"${edited_plist}" # from the contents of this var
)
ENDIF()
# Disable non-release sparkle for now. We haven't used it yet.
# IF( NOT CMAKE_BUILD_TYPE STREQUAL "Release" )
# STRING( REPLACE "http://download.tomahawk-player.org/sparkle" # match this
# "http://download.tomahawk-player.org/sparkle-debug" #replace with debug url
# edited_plist # save in this variable
# "${edited_plist}" # from the contents of this var
# )
# ENDIF()
FILE( WRITE ${CMAKE_BINARY_DIR}/Info.plist "${edited_plist}" )
FILE(COPY ${CMAKE_SOURCE_DIR}/admin/mac/sparkle_pub.pem
DESTINATION "${CMAKE_BINARY_DIR}/tomahawk.app/Contents/Resources")
endif (APPLE)

View File

@@ -14,7 +14,7 @@ SET( QT_USE_QTXML TRUE )
SET( QT_USE_QTWEBKIT TRUE )
INCLUDE( ${QT_USE_FILE} )
INCLUDE( ${CMAKE_MODULE_PATH}/AddAppIconMacro.cmake )
INCLUDE( AddAppIconMacro )
#SET( CMAKE_BUILD_TYPE "Release" )
SET( CMAKE_VERBOSE_MAKEFILE ON )
@@ -72,6 +72,7 @@ SET( tomahawkSourcesGui ${tomahawkSourcesGui}
configdelegatebase.cpp
sipconfigdelegate.cpp
resolverconfigdelegate.cpp
settingslistdelegate.cpp
resolversmodel.cpp
tomahawkwindow.cpp
)
@@ -115,6 +116,7 @@ SET( tomahawkHeadersGui ${tomahawkHeadersGui}
configdelegatebase.h
resolverconfigdelegate.h
sipconfigdelegate.h
settingslistdelegate.h
resolversmodel.h
delegateconfigwrapper.h
tomahawkwindow.h
@@ -235,7 +237,6 @@ TARGET_LINK_LIBRARIES( tomahawk
${QXTWEB_LIBRARIES}
${QJSON_LIBRARIES}
${TAGLIB_LIBRARIES}
${CLUCENE_LIBRARIES}
)

View File

@@ -1,70 +0,0 @@
# cd build ; cmake -DCPACK_GENERATOR=DEB .. ; make package
INCLUDE(InstallRequiredSystemLibraries)
set(CPACK_PACKAGING_INSTALL_PREFIX /usr/local)
SET(CPACK_PACKAGE_DESCRIPTION_SUMMARY "Tomahawk desktop player")
SET(CPACK_PACKAGE_NAME "tomahawk")
SET(CPACK_PACKAGE_VENDOR "tomahawk.org")
SET(CPACK_PACKAGE_CONTACT "Richard Jones")
SET(CPACK_DEBIAN_PACKAGE_MAINTAINER "rj@tomahawk.org")
SET(CPACK_PACKAGE_DESCRIPTION_FILE "${CMAKE_CURRENT_SOURCE_DIR}/../README")
SET(CPACK_RESOURCE_FILE_LICENSE "${CMAKE_CURRENT_SOURCE_DIR}/../LICENSE.txt")
SET(CPACK_PACKAGE_VERSION_MAJOR "0")
SET(CPACK_PACKAGE_VERSION_MINOR "0")
SET(CPACK_PACKAGE_VERSION_PATCH "1")
SET(CPACK_PACKAGE_VERSION "${CPACK_PACKAGE_VERSION_MAJOR}.${CPACK_PACKAGE_VERSION_MINOR}.${CPACK_PACKAGE_VERSION_PATCH}")
#SET(CPACK_DEBIAN_PACKAGE_ARCHITECTURE "i386") # Default: Output of dpkg --print-architecture or i386
# Copied from generator script, needs to be set for inclusion into filename of package:
# $ dpkg --print-architecture
FIND_PROGRAM(DPKG_CMD dpkg)
IF(NOT DPKG_CMD)
MESSAGE(STATUS "Can not find dpkg in your path, default to i386.")
SET(CPACK_DEBIAN_PACKAGE_ARCHITECTURE i386)
ELSE(NOT DPKG_CMD)
EXECUTE_PROCESS(COMMAND "${DPKG_CMD}" --print-architecture
OUTPUT_VARIABLE CPACK_DEBIAN_PACKAGE_ARCHITECTURE
OUTPUT_STRIP_TRAILING_WHITESPACE
)
ENDIF(NOT DPKG_CMD)
EXECUTE_PROCESS(COMMAND "date" "+%s"
OUTPUT_VARIABLE TIMEMARK
OUTPUT_STRIP_TRAILING_WHITESPACE
)
# eg: tomahawk-i386-1.0.0
SET(CPACK_PACKAGE_FILE_NAME "${CPACK_PACKAGE_NAME}-${CPACK_DEBIAN_PACKAGE_ARCHITECTURE}-${CPACK_PACKAGE_VERSION}_${TIMEMARK}")
SET(CPACK_PACKAGE_INSTALL_DIRECTORY "CMake ${CMake_VERSION_MAJOR}.${CMake_VERSION_MINOR}")
IF(WIN32 AND NOT UNIX)
###
ELSE(WIN32 AND NOT UNIX)
# SET(CPACK_STRIP_FILES "tomahawk")
# SET(CPACK_SOURCE_STRIP_FILES "")
ENDIF(WIN32 AND NOT UNIX)
# Nsis only? SET(CPACK_PACKAGE_EXECUTABLES "tomahawk" "tomahawk")
#gnutls is in here because gloox needs it, and we link statically to gloox:
SET(CPACK_DEBIAN_PACKAGE_DEPENDS "libqtgui4 (>=4:4.7.0-0ubuntu1), libtag1c2a (>=1.6.2-0ubuntu1), liblastfm-dev (>=0.4.0~really0.3.3-0ubuntu1), libqt4-sql-sqlite (>=4:4.7.0-0ubuntu1), libvorbis0a (>=1.2.3-3ubuntu1), libmad0 (>=0.15.1b-4ubuntu1), libasound2 (>=1.0.22-0ubuntu7), zlib1g (>=1:1.2.3.3.dfsg-15ubuntu1), libqjson-dev (>=0.7.1-1), libgnutls26 (>= 2.7.14-0), libgloox8 (>=1.0-1)")
#SET(CPACK_DEBIAN_PACKAGE_SECTION "music")
INSTALL(
TARGETS tomahawk DESTINATION bin
RUNTIME DESTINATION bin
# LIBRARY DESTINATION lib${LIB_SUFFIX}
# ARCHIVE DESTINATION lib${LIB_SUFFIX}
)
INSTALL(
PROGRAMS ${CMAKE_BINARY_DIR}/tomahawk
DESTINATION bin
)
INCLUDE(CPack)

View File

@@ -23,6 +23,8 @@
#include "libtomahawk/pipeline.h"
#include "utils/logger.h"
using namespace Tomahawk;
@@ -41,6 +43,7 @@ PipelineStatusView::PipelineStatusView( AnimatedSplitter* parent )
headers << tr( "Searching For" ) << tr( "Pending" );
m_tree->setHeaderLabels( headers );
m_tree->setHorizontalScrollBarPolicy( Qt::ScrollBarAlwaysOff );
m_tree->setSizePolicy( QSizePolicy::Preferred, QSizePolicy::Ignored );
m_tree->setColumnCount( 2 );
m_tree->setColumnWidth( 0, 200 );
@@ -57,6 +60,17 @@ PipelineStatusView::PipelineStatusView( AnimatedSplitter* parent )
connect( Pipeline::instance(), SIGNAL( resolving( Tomahawk::query_ptr ) ), SLOT( onPipelineUpdate( Tomahawk::query_ptr ) ) );
connect( Pipeline::instance(), SIGNAL( idle() ), SLOT( onPipelineUpdate() ) );
#ifndef Q_WS_WIN
QFont f = font();
f.setPointSize( f.pointSize() - 1 );
setFont( f );
#endif
#ifdef Q_WS_MAC
f.setPointSize( f.pointSize() - 2 );
setFont( f );
#endif
onPipelineUpdate();
}
@@ -64,8 +78,6 @@ PipelineStatusView::PipelineStatusView( AnimatedSplitter* parent )
void
PipelineStatusView::onPipelineUpdate( const query_ptr& query )
{
qDebug() << Q_FUNC_INFO;
QTreeWidgetItem* ti = m_tree->invisibleRootItem()->child( 0 );
if ( Pipeline::instance()->activeQueryCount() && !query.isNull() )

View File

@@ -19,7 +19,6 @@
#ifndef PIPELINESTATUSVIEW_H
#define PIPELINESTATUSVIEW_H
#include <QDebug>
#include <QTreeWidget>
#include "typedefs.h"
@@ -35,7 +34,6 @@ public:
explicit PipelineStatusView( AnimatedSplitter* parent );
virtual ~PipelineStatusView()
{
qDebug() << Q_FUNC_INFO;
}
QSize sizeHint() const;

View File

@@ -20,16 +20,23 @@
#include "ui_audiocontrols.h"
#include <QNetworkReply>
#include <QDropEvent>
#include <QMouseEvent>
#include "audio/audioengine.h"
#include "viewmanager.h"
#include "utils/imagebutton.h"
#include "utils/tomahawkutils.h"
#include "playlist/playlistview.h"
#include "database/database.h"
#include "database/databasecommand_socialaction.h"
#include "album.h"
#include "utils/imagebutton.h"
#include "utils/tomahawkutils.h"
#include "utils/logger.h"
#include <globalactionmanager.h>
#include "dropjob.h"
using namespace Tomahawk;
static QString s_acInfoIdentifier = QString( "AUDIOCONTROLS" );
@@ -42,8 +49,7 @@ AudioControls::AudioControls( QWidget* parent )
, m_shuffled( false )
{
ui->setupUi( this );
ui->buttonAreaLayout->setSpacing( 2 );
setAcceptDrops( true );
QFont font( ui->artistTrackLabel->font() );
font.setPixelSize( 12 );
@@ -85,54 +91,9 @@ AudioControls::AudioControls( QWidget* parent )
ui->ownerLabel->setForegroundRole( QPalette::Dark );
ui->metaDataArea->setStyleSheet( "QWidget#metaDataArea {\nborder-width: 4px;\nborder-image: url(" RESPATH "images/now-playing-panel.png) 4 4 4 4 stretch stretch; }" );
ui->seekSlider->setFixedHeight( 20 );
ui->seekSlider->setEnabled( true );
ui->seekSlider->setStyleSheet( "QSlider::groove::horizontal {"
"margin: 5px; border-width: 3px;"
"border-image: url(" RESPATH "images/seek-slider-bkg.png) 3 3 3 3 stretch stretch;"
"}"
"QSlider::sub-page:horizontal {"
"margin: 5px; border-width: 3px;"
"border-image: url(" RESPATH "images/seek-slider-level.png) 3 3 3 3 stretch stretch;"
"}"
"QSlider::handle::horizontal {"
"margin-bottom: -7px; margin-top: -7px;"
"height: 17px; width: 16px;"
"background-image: url(" RESPATH "images/seek-and-volume-knob-rest.png);"
"background-repeat: no-repeat;"
"}" );
ui->volumeSlider->setFixedHeight( 20 );
ui->volumeSlider->setRange( 0, 100 );
ui->volumeSlider->setValue( AudioEngine::instance()->volume() );
ui->volumeSlider->setStyleSheet( "QSlider::groove::horizontal {"
"margin: 5px; border-width: 3px;"
"border-image: url(" RESPATH "images/volume-slider-bkg.png) 3 3 3 3 stretch stretch;"
"}"
"QSlider::sub-page:horizontal {"
"margin: 5px; border-width: 3px;"
"border-image: url(" RESPATH "images/seek-slider-level.png) 3 3 3 3 stretch stretch;"
"}"
"QSlider::handle::horizontal {"
"margin-bottom: -7px; margin-top: -7px;"
"height: 17px; width: 16px;"
"background-image: url(" RESPATH "images/seek-and-volume-knob-rest.png);"
"background-repeat: no-repeat;"
"}" );
/* m_playAction = new QAction( this );
m_pauseAction = new QAction( this );
m_prevAction = new QAction( this );
m_nextAction = new QAction( this );
connect( m_playAction, SIGNAL( triggered() ), (QObject*)APP->audioEngine(), SLOT( play() ) );
connect( m_pauseAction, SIGNAL( triggered() ), (QObject*)APP->audioEngine(), SLOT( pause() ) );
connect( m_prevAction, SIGNAL( triggered() ), (QObject*)APP->audioEngine(), SLOT( previous() ) );
connect( m_nextAction, SIGNAL( triggered() ), (QObject*)APP->audioEngine(), SLOT( next() ) ); */
connect( ui->seekSlider, SIGNAL( valueChanged( int ) ), AudioEngine::instance(), SLOT( seek( int ) ) );
connect( ui->volumeSlider, SIGNAL( valueChanged( int ) ), AudioEngine::instance(), SLOT( setVolume( int ) ) );
@@ -172,6 +133,14 @@ AudioControls::AudioControls( QWidget* parent )
connect( Tomahawk::InfoSystem::InfoSystem::instance(), SIGNAL( finished( QString ) ), SLOT( infoSystemFinished( QString ) ) );
ui->buttonAreaLayout->setSpacing( 0 );
ui->stackedLayout->setSpacing( 0 );
ui->stackedLayout->setContentsMargins( 0, 0, 0, 0 );
ui->stackedLayout->setMargin( 0 );
ui->playPauseButton->setContentsMargins( 0, 0, 0, 0 );
ui->pauseButton->setContentsMargins( 0, 0, 0, 0 );
ui->stackedLayout->setSizeConstraint( QLayout::SetFixedSize );
onPlaybackStopped(); // initial state
}
@@ -210,7 +179,7 @@ AudioControls::onVolumeChanged( int volume )
void
AudioControls::onPlaybackStarted( const Tomahawk::result_ptr& result )
{
qDebug() << Q_FUNC_INFO;
tDebug( LOGEXTRA ) << Q_FUNC_INFO;
onPlaybackLoading( result );
@@ -223,7 +192,7 @@ AudioControls::onPlaybackStarted( const Tomahawk::result_ptr& result )
requestData.type = Tomahawk::InfoSystem::InfoAlbumCoverArt;
requestData.input = QVariant::fromValue< Tomahawk::InfoSystem::InfoCriteriaHash >( trackInfo );
requestData.customData = QVariantMap();
Tomahawk::InfoSystem::InfoSystem::instance()->getInfo( requestData );
}
@@ -231,22 +200,20 @@ AudioControls::onPlaybackStarted( const Tomahawk::result_ptr& result )
void
AudioControls::infoSystemInfo( Tomahawk::InfoSystem::InfoRequestData requestData, QVariant output )
{
qDebug() << Q_FUNC_INFO << requestData.caller << requestData.type << s_acInfoIdentifier << Tomahawk::InfoSystem::InfoAlbumCoverArt;
if ( requestData.caller != s_acInfoIdentifier || requestData.type != Tomahawk::InfoSystem::InfoAlbumCoverArt )
{
qDebug() << "Info of wrong type or not with our identifier";
return;
}
if ( m_currentTrack.isNull() )
{
qDebug() << "Current track is null when trying to apply fetched cover art";
tLog() << "Current track is null when trying to apply fetched cover art";
return;
}
if ( !output.canConvert< QVariantMap >() )
{
qDebug() << "Cannot convert fetched art from a QByteArray";
tDebug( LOGINFO ) << "Cannot convert fetched art from a QByteArray";
return;
}
@@ -269,14 +236,13 @@ void
AudioControls::infoSystemFinished( QString target )
{
Q_UNUSED( target );
qDebug() << Q_FUNC_INFO;
}
void
AudioControls::onPlaybackLoading( const Tomahawk::result_ptr& result )
{
qDebug() << Q_FUNC_INFO;
tDebug( LOGEXTRA ) << Q_FUNC_INFO;
m_currentTrack = result;
@@ -292,27 +258,34 @@ AudioControls::onPlaybackLoading( const Tomahawk::result_ptr& result )
ui->seekSlider->setValue( 0 );
ui->seekSlider->setVisible( true );
/* m_playAction->setEnabled( false );
m_pauseAction->setEnabled( true ); */
ui->stackedLayout->setCurrentWidget( ui->pauseButton );
ui->pauseButton->setEnabled( true );
ui->pauseButton->setVisible( true );
ui->playPauseButton->setVisible( false );
ui->playPauseButton->setEnabled( false );
ui->loveButton->setEnabled( true );
ui->loveButton->setVisible( true );
result->loadSocialActions();
if ( result->loved() )
connect( result.data(), SIGNAL( socialActionsLoaded() ), this, SLOT( socialActionsLoaded() ) );
}
void
AudioControls::socialActionsLoaded()
{
Result* r = qobject_cast< Result* >( sender() );
Q_ASSERT( r );
if ( m_currentTrack.data() == r )
{
ui->loveButton->setPixmap( RESPATH "images/loved.png" );
ui->loveButton->setChecked( true );
}
else
{
ui->loveButton->setPixmap( RESPATH "images/not-loved.png" );
ui->loveButton->setChecked( false );
if ( m_currentTrack->loved() )
{
ui->loveButton->setPixmap( RESPATH "images/loved.png" );
ui->loveButton->setChecked( true );
}
else
{
ui->loveButton->setPixmap( RESPATH "images/not-loved.png" );
ui->loveButton->setChecked( false );
}
}
}
@@ -320,26 +293,13 @@ AudioControls::onPlaybackLoading( const Tomahawk::result_ptr& result )
void
AudioControls::onPlaybackPaused()
{
/* m_pauseAction->setEnabled( false );
m_playAction->setEnabled( true ); */
ui->pauseButton->setVisible( false );
ui->pauseButton->setEnabled( false );
ui->playPauseButton->setEnabled( true );
ui->playPauseButton->setVisible( true );
ui->stackedLayout->setCurrentWidget( ui->playPauseButton );
}
void
AudioControls::onPlaybackResumed()
{
/* m_playAction->setEnabled( false );
m_pauseAction->setEnabled( true ); */
ui->playPauseButton->setVisible( false );
ui->playPauseButton->setEnabled( false );
ui->pauseButton->setVisible( true );
ui->pauseButton->setEnabled( true );
ui->stackedLayout->setCurrentWidget( ui->pauseButton );
ui->loveButton->setVisible( true );
}
@@ -357,15 +317,9 @@ AudioControls::onPlaybackStopped()
ui->coverImage->setPixmap( QPixmap() );
ui->seekSlider->setVisible( false );
ui->pauseButton->setVisible( false );
ui->pauseButton->setEnabled( false );
ui->playPauseButton->setEnabled( true );
ui->playPauseButton->setVisible( true );
ui->stackedLayout->setCurrentWidget( ui->playPauseButton );
ui->loveButton->setEnabled( false );
ui->loveButton->setVisible( false );
/* m_pauseAction->setEnabled( false );
m_playAction->setEnabled( true ); */
}
@@ -505,6 +459,54 @@ AudioControls::onTrackClicked()
}
void
AudioControls::dragEnterEvent( QDragEnterEvent* e )
{
if ( DropJob::acceptsMimeData( e->mimeData() ) )
e->acceptProposedAction();
}
void
AudioControls::dragMoveEvent( QDragMoveEvent* /* e */ )
{
// if ( GlobalActionManager::instance()->acceptsMimeData( e->mimeData() ) )
// e->acceptProposedAction();
}
void
AudioControls::dropEvent( QDropEvent* e )
{
tDebug() << "AudioControls got drop:" << e->mimeData()->formats();
if ( DropJob::acceptsMimeData( e->mimeData() ) )
{
DropJob *dj = new DropJob();
connect( dj, SIGNAL( tracks( QList<Tomahawk::query_ptr> ) ), this, SLOT( droppedTracks( QList<Tomahawk::query_ptr> ) ) );
dj->tracksFromMimeData( e->mimeData() );
e->accept();
}
}
void
AudioControls::droppedTracks( QList< query_ptr > tracks )
{
if ( !tracks.isEmpty() )
{
// queue and play the first if nothign is playing
GlobalActionManager::instance()->handleOpenTrack( tracks.first() );
// just queue the rest
for ( int i = 1; i < tracks.size(); i++ )
{
ViewManager::instance()->queue()->model()->append( tracks[ i ] );
}
}
}
void
AudioControls::onLoveButtonClicked( bool checked )
{

View File

@@ -25,6 +25,9 @@
#include "playlistinterface.h"
#include "infosystem/infosystem.h"
class QDropEvent;
class QDragEnterEvent;
class QDragMoveEvent;
namespace Ui
{
class AudioControls;
@@ -48,6 +51,9 @@ public slots:
protected:
void changeEvent( QEvent* e );
void dragEnterEvent ( QDragEnterEvent* );
void dragMoveEvent ( QDragMoveEvent* );
void dropEvent ( QDropEvent* );
private slots:
void onPlaybackStarted( const Tomahawk::result_ptr& result );
@@ -70,14 +76,12 @@ private slots:
void infoSystemInfo( Tomahawk::InfoSystem::InfoRequestData requestData, QVariant output );
void infoSystemFinished( QString target );
void droppedTracks( QList<Tomahawk::query_ptr> );
void socialActionsLoaded();
private:
Ui::AudioControls *ui;
QAction* m_playAction;
QAction* m_pauseAction;
QAction* m_prevAction;
QAction* m_nextAction;
QPixmap m_defaultCover;
Tomahawk::result_ptr m_currentTrack;

View File

@@ -6,7 +6,7 @@
<rect>
<x>0</x>
<y>0</y>
<width>939</width>
<width>929</width>
<height>80</height>
</rect>
</property>
@@ -60,7 +60,7 @@
</property>
<layout class="QHBoxLayout" name="buttonAreaLayout">
<item>
<spacer name="horizontalSpacer">
<spacer name="horizontalSpacer_2">
<property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
@@ -80,18 +80,25 @@
</widget>
</item>
<item>
<widget class="ImageButton" name="playPauseButton">
<property name="text">
<string>Play</string>
<layout class="QStackedLayout" name="stackedLayout">
<property name="spacing">
<number>0</number>
</property>
</widget>
</item>
<item>
<widget class="ImageButton" name="pauseButton">
<property name="text">
<string>Pause</string>
</property>
</widget>
<item>
<widget class="ImageButton" name="playPauseButton">
<property name="text">
<string>Play</string>
</property>
</widget>
</item>
<item>
<widget class="ImageButton" name="pauseButton">
<property name="text">
<string>Pause</string>
</property>
</widget>
</item>
</layout>
</item>
<item>
<widget class="ImageButton" name="nextButton">
@@ -101,7 +108,7 @@
</widget>
</item>
<item>
<spacer name="horizontalSpacer_2">
<spacer name="horizontalSpacer">
<property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
@@ -330,7 +337,7 @@
</widget>
</item>
<item>
<widget class="QSlider" name="seekSlider">
<widget class="SeekSlider" name="seekSlider">
<property name="minimumSize">
<size>
<width>0</width>
@@ -482,7 +489,7 @@
</widget>
</item>
<item>
<widget class="QSlider" name="volumeSlider">
<widget class="SeekSlider" name="volumeSlider">
<property name="minimumSize">
<size>
<width>0</width>
@@ -522,6 +529,11 @@
</layout>
</widget>
<customwidgets>
<customwidget>
<class>SeekSlider</class>
<extends>QSlider</extends>
<header location="global">widgets/SeekSlider.h</header>
</customwidget>
<customwidget>
<class>ImageButton</class>
<extends>QPushButton</extends>

View File

@@ -18,12 +18,13 @@
#include "configdelegatebase.h"
#include "utils/tomahawkutils.h"
#include <QPainter>
#include <QApplication>
#include <QMouseEvent>
#include "utils/tomahawkutils.h"
#include "utils/logger.h"
ConfigDelegateBase::ConfigDelegateBase ( QObject* parent )
: QStyledItemDelegate ( parent )
{
@@ -97,13 +98,13 @@ ConfigDelegateBase::editorEvent ( QEvent* event, QAbstractItemModel* model, cons
return false;
// eat the double click events inside the check rect
if( event->type() == QEvent::MouseButtonDblClick ) {
return true;
}
if( event->type() == QEvent::MouseButtonDblClick ) {
return true;
}
Qt::CheckState curState = static_cast< Qt::CheckState >( index.data( Qt::CheckStateRole ).toInt() );
Qt::CheckState newState = curState == Qt::Checked ? Qt::Unchecked : Qt::Checked;
return model->setData( index, newState, Qt::CheckStateRole );
Qt::CheckState curState = static_cast< Qt::CheckState >( index.data( Qt::CheckStateRole ).toInt() );
Qt::CheckState newState = curState == Qt::Checked ? Qt::Unchecked : Qt::Checked;
return model->setData( index, newState, Qt::CheckStateRole );
} else if( event->type() == QEvent::MouseButtonPress ) {
QMouseEvent* me = static_cast< QMouseEvent* >( event );

View File

@@ -19,17 +19,21 @@
#include "diagnosticsdialog.h"
#include "ui_diagnosticsdialog.h"
#include "config.h"
#include <sip/SipHandler.h>
#include <network/servent.h>
#include <sourcelist.h>
#include <QTextEdit>
#include <QDebug>
#include <QDialogButtonBox>
#include <QPushButton>
#include <QApplication>
#include <QClipboard>
#include "utils/logger.h"
DiagnosticsDialog::DiagnosticsDialog( QWidget *parent )
: QDialog( parent )
, ui( new Ui::DiagnosticsDialog )
@@ -52,6 +56,11 @@ void DiagnosticsDialog::updateLogView()
.arg( QDateTime::currentDateTime().toString() )
);
// network
log.append(
"TOMAHAWK-VERSION: " TOMAHAWK_VERSION "\n\n\n"
);
// network
log.append(
"NETWORK:\n"

View File

@@ -20,7 +20,6 @@
#define DIAGNOSTICSDIALOG_H
#include <QDialog>
#include <QDebug>
namespace Ui
{

View File

@@ -6,8 +6,8 @@
<rect>
<x>0</x>
<y>0</y>
<width>621</width>
<height>434</height>
<width>724</width>
<height>433</height>
</rect>
</property>
<property name="minimumSize">
@@ -20,6 +20,9 @@
<string>Tomahawk Diagnostics</string>
</property>
<layout class="QVBoxLayout" name="verticalLayout_2">
<property name="margin">
<number>4</number>
</property>
<item>
<layout class="QVBoxLayout" name="verticalLayout">
<item>
@@ -57,8 +60,6 @@
</item>
</layout>
</widget>
<resources>
<include location="../resources.qrc"/>
</resources>
<resources/>
<connections/>
</ui>

View File

@@ -21,7 +21,6 @@ set( libSources
artist.cpp
album.cpp
collection.cpp
webcollection.cpp
playlist.cpp
resolver.cpp
query.cpp
@@ -31,7 +30,8 @@ set( libSources
viewpage.cpp
viewmanager.cpp
globalactionmanager.cpp
contextMenu.cpp
contextmenu.cpp
dropjob.cpp
sip/SipPlugin.cpp
sip/SipHandler.cpp
@@ -76,6 +76,7 @@ set( libSources
database/databasecommand_setdynamicplaylistrevision.cpp
database/databasecommand_createdynamicplaylist.cpp
database/databasecommand_loaddynamicplaylist.cpp
database/databasecommand_loaddynamicplaylistentries.cpp
database/databasecommand_loadallautoplaylists.cpp
database/databasecommand_loadallstations.cpp
database/databasecommand_deletedynamicplaylist.cpp
@@ -83,6 +84,7 @@ set( libSources
database/databasecommand_clientauthvalid.cpp
database/databasecommand_socialaction.cpp
database/databasecommand_loadsocialactions.cpp
database/databasecommand_genericselect.cpp
database/database.cpp
infosystem/infosystemcache.cpp
@@ -91,6 +93,7 @@ set( libSources
infosystem/infoplugins/generic/echonestplugin.cpp
infosystem/infoplugins/generic/lastfmplugin.cpp
infosystem/infoplugins/generic/musixmatchplugin.cpp
infosystem/infoplugins/generic/musicbrainzPlugin.cpp
playlist/treemodel.cpp
playlist/treeproxymodel.cpp
@@ -117,6 +120,7 @@ set( libSources
playlist/albumitemdelegate.cpp
playlist/albumview.cpp
playlist/artistview.cpp
playlist/customplaylistview.cpp
playlist/topbar/topbar.cpp
playlist/topbar/clearbutton.cpp
@@ -143,6 +147,8 @@ set( libSources
playlist/dynamic/widgets/CollapsibleControls.cpp
playlist/dynamic/widgets/DynamicSetupWidget.cpp
playlist/dynamic/widgets/LoadingSpinner.cpp
playlist/dynamic/database/DatabaseControl.cpp
playlist/dynamic/database/DatabaseGenerator.cpp
network/bufferiodevice.cpp
network/msgprocessor.cpp
@@ -158,22 +164,29 @@ set( libSources
utils/querylabel.cpp
utils/elidedlabel.cpp
utils/imagebutton.cpp
utils/progresstreeview.cpp
utils/logger.cpp
utils/proxystyle.cpp
utils/widgetdragfilter.cpp
utils/animatedsplitter.cpp
utils/xspfloader.cpp
utils/xspfgenerator.cpp
utils/jspfloader.cpp
utils/spotifyparser.cpp
utils/rdioparser.cpp
utils/shortenedlinkparser.cpp
widgets/newplaylistwidget.cpp
widgets/searchwidget.cpp
widgets/SeekSlider.cpp
widgets/playlisttypeselectordlg.cpp
widgets/welcomewidget.cpp
widgets/welcomeplaylistmodel.cpp
widgets/overlaywidget.cpp
widgets/HeaderLabel.cpp
widgets/SocialPlaylistWidget.cpp
widgets/infowidgets/sourceinfowidget.cpp
widgets/infowidgets/ArtistInfoWidget.cpp
widgets/infowidgets/AlbumInfoWidget.cpp
kdsingleapplicationguard/kdsingleapplicationguard.cpp
kdsingleapplicationguard/kdsharedmemorylocker.cpp
@@ -189,7 +202,6 @@ set( libHeaders
aclsystem.h
collection.h
webcollection.h
query.h
resolver.h
result.h
@@ -197,11 +209,11 @@ set( libHeaders
sourceplaylistinterface.h
viewmanager.h
globalactionmanager.h
contextMenu.h
contextmenu.h
dropjob.h
artist.h
album.h
track.h
playlist.h
sip/SipPlugin.h
@@ -247,6 +259,7 @@ set( libHeaders
database/databasecommand_setdynamicplaylistrevision.h
database/databasecommand_createdynamicplaylist.h
database/databasecommand_loaddynamicplaylist.h
database/databasecommand_loaddynamicplaylistentries.h
database/databasecommand_deletedynamicplaylist.h
database/databasecommand_loadallautoplaylists.h
database/databasecommand_loadallstations.h
@@ -254,6 +267,7 @@ set( libHeaders
database/databasecommand_clientauthvalid.h
database/databasecommand_socialaction.h
database/databasecommand_loadsocialactions.h
database/databasecommand_genericselect.h
infosystem/infosystem.h
infosystem/infosystemworker.h
@@ -261,6 +275,7 @@ set( libHeaders
infosystem/infoplugins/generic/echonestplugin.h
infosystem/infoplugins/generic/lastfmplugin.h
infosystem/infoplugins/generic/musixmatchplugin.h
infosystem/infoplugins/generic/musicbrainzPlugin.h
network/bufferiodevice.h
network/msgprocessor.h
@@ -297,6 +312,7 @@ set( libHeaders
playlist/albumitemdelegate.h
playlist/albumview.h
playlist/artistview.h
playlist/customplaylistview.h
playlist/topbar/topbar.h
playlist/topbar/clearbutton.h
@@ -323,26 +339,34 @@ set( libHeaders
playlist/dynamic/widgets/CollapsibleControls.h
playlist/dynamic/widgets/DynamicSetupWidget.h
playlist/dynamic/widgets/LoadingSpinner.h
playlist/dynamic/database/DatabaseControl.h
playlist/dynamic/database/DatabaseGenerator.h
utils/querylabel.h
utils/elidedlabel.h
utils/animatedcounterlabel.h
utils/imagebutton.h
utils/progresstreeview.h
utils/widgetdragfilter.h
utils/animatedsplitter.h
utils/xspfloader.h
utils/xspfgenerator.h
utils/jspfloader.h
utils/spotifyparser.h
utils/rdioparser.h
utils/shortenedlinkparser.h
widgets/newplaylistwidget.h
widgets/searchwidget.h
widgets/SeekSlider.h
widgets/playlisttypeselectordlg.h
widgets/welcomewidget.h
widgets/welcomeplaylistmodel.h
widgets/overlaywidget.h
widgets/HeaderLabel.h
widgets/SocialPlaylistWidget.h
widgets/infowidgets/sourceinfowidget.h
widgets/infowidgets/ArtistInfoWidget.h
widgets/infowidgets/AlbumInfoWidget.h
kdsingleapplicationguard/kdsingleapplicationguard.h
)
@@ -363,8 +387,10 @@ set( libUI ${libUI}
widgets/newplaylistwidget.ui
widgets/searchwidget.ui
widgets/welcomewidget.ui
widgets/SocialPlaylistWidget.ui
widgets/infowidgets/sourceinfowidget.ui
widgets/infowidgets/ArtistInfoWidget.ui
widgets/infowidgets/AlbumInfoWidget.ui
playlist/topbar/topbar.ui
playlist/infobar/infobar.ui
)
@@ -416,11 +442,14 @@ IF( APPLE )
FIND_LIBRARY( SCRIPTINGBRIDGE_LIBRARY ScriptingBridge )
MARK_AS_ADVANCED( COREAUDIO_LIBRARY COREFOUNDATION_LIBRARY FOUNDATION_LIBRARY SCRIPTINGBRIDGE_LIBRARY )
SET( libSources ${libSources}
SET( libSources ${libSources}
infosystem/infoplugins/mac/adium.mm
infosystem/infoplugins/mac/adiumplugin.cpp )
infosystem/infoplugins/mac/adiumplugin.cpp
widgets/maclineedit.mm
utils/tomahawkutils_mac.mm )
SET( libHeaders ${libHeaders}
SET( libHeaders ${libHeaders}
widgets/maclineedit.h
infosystem/infoplugins/mac/adium.h
infosystem/infoplugins/mac/adiumplugin.h )
@@ -431,6 +460,8 @@ IF( APPLE )
${COREFOUNDATION_LIBRARY}
${FOUNDATION_LIBRARY}
${SCRIPTINGBRIDGE_LIBRARY}
/System/Library/Frameworks/AppKit.framework
)
ENDIF( APPLE )
@@ -455,6 +486,7 @@ target_link_libraries( tomahawklib
${TAGLIB_LIBRARIES}
${CLUCENE_LIBRARIES}
${LIBECHONEST_LIBRARY}
${QT_QTUITOOLS_LIBRARY}
${QT_LIBRARIES}
${OS_SPECIFIC_LINK_LIBRARIES}
${CMAKE_THREAD_LIBS_INIT}

View File

@@ -18,12 +18,14 @@
#include "aclsystem.h"
#include <QtDebug>
#include <QMutexLocker>
#include <QVariant>
#include <tomahawksettings.h>
#include "utils/logger.h"
ACLSystem* ACLSystem::s_instance = 0;
ACLSystem*

View File

@@ -18,15 +18,26 @@
#include "album.h"
#include <QDebug>
#include "collection.h"
#include "database/database.h"
#include "database/databasecommand_alltracks.h"
#include "utils/logger.h"
using namespace Tomahawk;
album_ptr
Album::get( const Tomahawk::artist_ptr& artist, const QString& name, bool autoCreate )
{
int albid = Database::instance()->impl()->albumId( artist->id(), name, autoCreate );
if ( albid < 1 )
return album_ptr();
return Album::get( albid, name, artist );
}
album_ptr
Album::get( unsigned int id, const QString& name, const Tomahawk::artist_ptr& artist )
{

View File

@@ -37,6 +37,7 @@ class DLLEXPORT Album : public QObject, public PlaylistInterface
Q_OBJECT
public:
static album_ptr get( const Tomahawk::artist_ptr& artist, const QString& name, bool autoCreate = false );
static album_ptr get( unsigned int id, const QString& name, const Tomahawk::artist_ptr& artist );
Album( unsigned int id, const QString& name, const Tomahawk::artist_ptr& artist );

View File

@@ -18,12 +18,12 @@
#include "artist.h"
#include <QDebug>
#include "collection.h"
#include "database/database.h"
#include "database/databasecommand_alltracks.h"
#include "utils/logger.h"
using namespace Tomahawk;

View File

@@ -30,12 +30,15 @@
#include "album.h"
#include "utils/logger.h"
using namespace Tomahawk;
AudioEngine* AudioEngine::s_instance = 0;
static QString s_aeInfoIdentifier = QString( "AUDIOENGINE" );
AudioEngine*
AudioEngine::instance()
{
@@ -46,18 +49,18 @@ AudioEngine::instance()
AudioEngine::AudioEngine()
: QObject()
, m_isPlayingHttp( false )
, m_playlist( 0 )
, m_currentTrackPlaylist( 0 )
, m_queue( 0 )
, m_timeElapsed( 0 )
, m_expectStop( false )
, m_waitingOnNewTrack( false )
, m_infoSystemConnected( false )
, m_state( Stopped )
{
s_instance = this;
qDebug() << "Init AudioEngine";
tDebug() << "Init AudioEngine";
qRegisterMetaType< AudioErrorCode >("AudioErrorCode");
qRegisterMetaType< AudioState >("AudioState");
m_mediaObject = new Phonon::MediaObject( this );
m_audioOutput = new Phonon::AudioOutput( Phonon::MusicCategory, this );
@@ -81,7 +84,7 @@ AudioEngine::AudioEngine()
AudioEngine::~AudioEngine()
{
qDebug() << Q_FUNC_INFO;
tDebug() << Q_FUNC_INFO;
m_mediaObject->stop();
// stop();
@@ -90,6 +93,21 @@ AudioEngine::~AudioEngine()
}
QStringList
AudioEngine::supportedMimeTypes() const
{
if ( m_supportedMimeTypes.isEmpty() )
{
m_supportedMimeTypes = Phonon::BackendCapabilities::availableMimeTypes();
m_supportedMimeTypes << "audio/basic";
return m_supportedMimeTypes;
}
else
return m_supportedMimeTypes;
}
void
AudioEngine::playPause()
{
@@ -103,7 +121,7 @@ AudioEngine::playPause()
void
AudioEngine::play()
{
qDebug() << Q_FUNC_INFO;
tDebug( LOGEXTRA ) << Q_FUNC_INFO;
if ( isPaused() )
{
@@ -126,10 +144,11 @@ AudioEngine::play()
void
AudioEngine::pause()
{
qDebug() << Q_FUNC_INFO;
tDebug( LOGEXTRA ) << Q_FUNC_INFO;
m_mediaObject->pause();
emit paused();
Tomahawk::InfoSystem::InfoSystem::instance()->pushInfo( s_aeInfoIdentifier, Tomahawk::InfoSystem::InfoNowPaused, QVariant() );
}
@@ -137,12 +156,13 @@ AudioEngine::pause()
void
AudioEngine::stop()
{
qDebug() << Q_FUNC_INFO;
tDebug( LOGEXTRA ) << Q_FUNC_INFO;
setState( Stopped );
m_mediaObject->stop();
if ( m_playlist )
m_playlist->reset();
if ( !m_playlist.isNull() )
m_playlist.data()->reset();
setCurrentTrack( Tomahawk::result_ptr() );
emit stopped();
@@ -166,13 +186,13 @@ AudioEngine::stop()
void
AudioEngine::previous()
{
qDebug() << Q_FUNC_INFO;
tDebug( LOGEXTRA ) << Q_FUNC_INFO;
if ( !m_playlist )
if ( m_playlist.isNull() )
return;
if ( m_playlist->skipRestrictions() == PlaylistInterface::NoSkip ||
m_playlist->skipRestrictions() == PlaylistInterface::NoSkipBackwards )
if ( m_playlist.data()->skipRestrictions() == PlaylistInterface::NoSkip ||
m_playlist.data()->skipRestrictions() == PlaylistInterface::NoSkipBackwards )
return;
loadPreviousTrack();
@@ -182,17 +202,17 @@ AudioEngine::previous()
void
AudioEngine::next()
{
qDebug() << Q_FUNC_INFO;
tDebug( LOGEXTRA ) << Q_FUNC_INFO;
if ( !m_playlist )
if ( m_playlist.isNull() )
return;
if ( m_playlist->skipRestrictions() == PlaylistInterface::NoSkip ||
m_playlist->skipRestrictions() == PlaylistInterface::NoSkipForwards )
if ( m_playlist.data()->skipRestrictions() == PlaylistInterface::NoSkip ||
m_playlist.data()->skipRestrictions() == PlaylistInterface::NoSkipForwards )
return;
if ( !m_currentTrack.isNull() && !m_playlist->hasNextItem() &&
m_currentTrack->id() == m_playlist->currentItem()->id() )
if ( !m_currentTrack.isNull() && !m_playlist.data()->hasNextItem() &&
( m_playlist.data()->currentItem().isNull() || ( m_currentTrack->id() == m_playlist.data()->currentItem()->id() ) ) )
{
//For instance, when doing a catch-up while listening along, but the person
//you're following hasn't started a new track yet...don't do anything
@@ -206,15 +226,12 @@ AudioEngine::next()
void
AudioEngine::seek( int ms )
{
if ( !m_playlist )
return;
if ( m_playlist->seekRestrictions() == PlaylistInterface::NoSeek )
if ( !m_playlist.isNull() && m_playlist.data()->seekRestrictions() == PlaylistInterface::NoSeek )
return;
if ( isPlaying() || isPaused() )
{
qDebug() << Q_FUNC_INFO << ms;
tDebug( LOGVERBOSE ) << Q_FUNC_INFO << ms;
m_mediaObject->seek( ms );
}
}
@@ -223,13 +240,14 @@ AudioEngine::seek( int ms )
void
AudioEngine::setVolume( int percentage )
{
//qDebug() << Q_FUNC_INFO;
tDebug( LOGVERBOSE ) << Q_FUNC_INFO << percentage;
percentage = qBound( 0, percentage, 100 );
m_audioOutput->setVolume( (qreal)percentage / 100.0 );
emit volumeChanged( percentage );
}
void
AudioEngine::mute()
{
@@ -251,19 +269,19 @@ AudioEngine::sendWaitingNotification() const
void
AudioEngine::sendNowPlayingNotification()
{
qDebug() << Q_FUNC_INFO;
tDebug( LOGEXTRA ) << Q_FUNC_INFO;
if ( ! m_infoSystemConnected )
{
connect( Tomahawk::InfoSystem::InfoSystem::instance(),
SIGNAL( info( Tomahawk::InfoSystem::InfoRequestData, QVariant ) ),
SLOT( infoSystemInfo( Tomahawk::InfoSystem::InfoRequestData, QVariant ) ) );
connect( Tomahawk::InfoSystem::InfoSystem::instance(), SIGNAL( finished( QString ) ), SLOT( infoSystemFinished( QString ) ) );
m_infoSystemConnected = true;
}
Tomahawk::InfoSystem::InfoCriteriaHash trackInfo;
trackInfo["artist"] = m_currentTrack->album()->artist()->name();
trackInfo["album"] = m_currentTrack->album()->name();
@@ -273,7 +291,7 @@ AudioEngine::sendNowPlayingNotification()
requestData.type = Tomahawk::InfoSystem::InfoAlbumCoverArt;
requestData.input = QVariant::fromValue< Tomahawk::InfoSystem::InfoCriteriaHash >( trackInfo );
requestData.customData = QVariantMap();
Tomahawk::InfoSystem::InfoSystem::instance()->getInfo( requestData );
}
@@ -281,12 +299,9 @@ AudioEngine::sendNowPlayingNotification()
void
AudioEngine::infoSystemInfo( Tomahawk::InfoSystem::InfoRequestData requestData, QVariant output )
{
qDebug() << Q_FUNC_INFO;
if ( requestData.caller != s_aeInfoIdentifier ||
requestData.type != Tomahawk::InfoSystem::InfoAlbumCoverArt )
{
qDebug() << Q_FUNC_INFO << " not destined for us or wrong type, caller is " << requestData.caller << " and type is " << requestData.type;
return;
}
@@ -297,10 +312,8 @@ AudioEngine::infoSystemInfo( Tomahawk::InfoSystem::InfoRequestData requestData,
.arg( m_currentTrack->album()->name() );
if ( !output.isNull() && output.isValid() )
{
qDebug() << Q_FUNC_INFO << " output is valid";
QVariantMap returnedData = output.value< QVariantMap >();
const QByteArray ba = returnedData["imgbytes"].toByteArray();
qDebug() << "ba.length = " << ba.length();
if ( ba.length() )
{
QPixmap pm;
@@ -308,7 +321,7 @@ AudioEngine::infoSystemInfo( Tomahawk::InfoSystem::InfoRequestData requestData,
playInfo["image"] = QVariant( pm.toImage() );
}
}
Tomahawk::InfoSystem::InfoSystem::instance()->pushInfo(
s_aeInfoIdentifier, Tomahawk::InfoSystem::InfoNotifyUser,
QVariant::fromValue< QVariantMap >( playInfo ) );
@@ -319,24 +332,13 @@ void
AudioEngine::infoSystemFinished( QString caller )
{
Q_UNUSED( caller );
qDebug() << Q_FUNC_INFO;
}
void
AudioEngine::onTrackAboutToFinish()
{
qDebug() << Q_FUNC_INFO;
}
bool
AudioEngine::loadTrack( const Tomahawk::result_ptr& result )
{
qDebug() << Q_FUNC_INFO << thread() << result;
bool err = false;
{
QSharedPointer<QIODevice> io;
@@ -352,7 +354,7 @@ AudioEngine::loadTrack( const Tomahawk::result_ptr& result )
if ( !io || io.isNull() )
{
qDebug() << "Error getting iodevice for item";
tLog() << "Error getting iodevice for" << result->url();
err = true;
}
}
@@ -360,7 +362,7 @@ AudioEngine::loadTrack( const Tomahawk::result_ptr& result )
if ( !err )
{
qDebug() << "Starting new song from url:" << m_currentTrack->url();
tLog() << "Starting new song:" << m_currentTrack->url();
emit loading( m_currentTrack );
if ( !isHttpResult( m_currentTrack->url() ) && !isLocalResult( m_currentTrack->url() ) )
@@ -371,13 +373,26 @@ AudioEngine::loadTrack( const Tomahawk::result_ptr& result )
}
else
{
QUrl furl = m_currentTrack->url();
if ( m_currentTrack->url().contains( "?" ) )
if ( !isLocalResult( m_currentTrack->url() ) )
{
furl = QUrl( m_currentTrack->url().left( m_currentTrack->url().indexOf( '?' ) ) );
furl.setEncodedQuery( QString( m_currentTrack->url().mid( m_currentTrack->url().indexOf( '?' ) + 1 ) ).toLocal8Bit() );
QUrl furl = m_currentTrack->url();
if ( m_currentTrack->url().contains( "?" ) )
{
furl = QUrl( m_currentTrack->url().left( m_currentTrack->url().indexOf( '?' ) ) );
furl.setEncodedQuery( QString( m_currentTrack->url().mid( m_currentTrack->url().indexOf( '?' ) + 1 ) ).toLocal8Bit() );
}
m_mediaObject->setCurrentSource( furl );
}
m_mediaObject->setCurrentSource( furl );
else
{
QString furl = m_currentTrack->url();
#ifdef Q_OS_WIN32
if ( furl.startsWith( "file://" ) )
furl = furl.right( furl.length() - 7 );
#endif
m_mediaObject->setCurrentSource( furl );
}
m_mediaObject->currentSource().setAutoDelete( true );
m_isPlayingHttp = true;
}
@@ -398,7 +413,7 @@ AudioEngine::loadTrack( const Tomahawk::result_ptr& result )
trackInfo["title"] = m_currentTrack->track();
trackInfo["artist"] = m_currentTrack->artist()->name();
trackInfo["album"] = m_currentTrack->album()->name();
if ( TomahawkSettings::instance()->verboseNotifications() )
sendNowPlayingNotification();
@@ -419,18 +434,19 @@ AudioEngine::loadTrack( const Tomahawk::result_ptr& result )
return true;
}
void
AudioEngine::loadPreviousTrack()
{
qDebug() << Q_FUNC_INFO;
tDebug( LOGEXTRA ) << Q_FUNC_INFO;
if ( !m_playlist )
if ( m_playlist.isNull() )
{
stop();
return;
}
Tomahawk::result_ptr result = m_playlist->previousItem();
Tomahawk::result_ptr result = m_playlist.data()->previousItem();
if ( !result.isNull() )
loadTrack( result );
else
@@ -441,7 +457,7 @@ AudioEngine::loadPreviousTrack()
void
AudioEngine::loadNextTrack()
{
qDebug() << Q_FUNC_INFO;
tDebug( LOGEXTRA ) << Q_FUNC_INFO;
Tomahawk::result_ptr result;
@@ -450,16 +466,16 @@ AudioEngine::loadNextTrack()
result = m_queue->nextItem();
}
if ( m_playlist && result.isNull() )
if ( !m_playlist.isNull() && result.isNull() )
{
result = m_playlist->nextItem();
result = m_playlist.data()->nextItem();
}
if ( !result.isNull() )
loadTrack( result );
else
{
if ( m_playlist && m_playlist->retryMode() == Tomahawk::PlaylistInterface::Retry )
if ( !m_playlist.isNull() && m_playlist.data()->retryMode() == Tomahawk::PlaylistInterface::Retry )
m_waitingOnNewTrack = true;
stop();
}
@@ -469,17 +485,17 @@ AudioEngine::loadNextTrack()
void
AudioEngine::playItem( Tomahawk::PlaylistInterface* playlist, const Tomahawk::result_ptr& result )
{
qDebug() << Q_FUNC_INFO;
tDebug( LOGEXTRA ) << Q_FUNC_INFO << ( result.isNull() ? QString() : result->url() );
if ( m_playlist )
m_playlist->reset();
if ( !m_playlist.isNull() )
m_playlist.data()->reset();
setPlaylist( playlist );
m_currentTrackPlaylist = playlist;
m_currentTrackPlaylist = playlist->getSharedPointer();
if ( !result.isNull() )
loadTrack( result );
else if ( m_playlist && m_playlist->retryMode() == PlaylistInterface::Retry )
else if ( !m_playlist.isNull() && m_playlist.data()->retryMode() == PlaylistInterface::Retry )
{
m_waitingOnNewTrack = true;
stop();
@@ -501,7 +517,7 @@ AudioEngine::playlistNextTrackReady()
void
AudioEngine::onAboutToFinish()
{
qDebug() << Q_FUNC_INFO;
tDebug( LOGVERBOSE ) << Q_FUNC_INFO;
m_expectStop = true;
}
@@ -509,23 +525,43 @@ AudioEngine::onAboutToFinish()
void
AudioEngine::onStateChanged( Phonon::State newState, Phonon::State oldState )
{
qDebug() << Q_FUNC_INFO << oldState << newState << m_expectStop;
tDebug( LOGVERBOSE ) << Q_FUNC_INFO << oldState << newState << m_expectStop;
if ( newState == Phonon::ErrorState )
{
qDebug() << "Phonon Error:" << m_mediaObject->errorString() << m_mediaObject->errorType();
tLog() << "Phonon Error:" << m_mediaObject->errorString() << m_mediaObject->errorType();
return;
}
if ( !m_expectStop )
return;
m_expectStop = false;
if ( newState == Phonon::PlayingState )
setState( Playing );
if ( oldState == Phonon::PlayingState )
{
if ( newState == Phonon::PausedState || newState == Phonon::StoppedState )
bool stopped = false;
switch ( newState )
{
qDebug() << "Loading next track.";
case Phonon::PausedState:
{
qint64 duration = m_mediaObject->totalTime() > 0 ? m_mediaObject->totalTime() : m_currentTrack->duration() * 1000;
stopped = ( duration - 1000 < m_mediaObject->currentTime() );
if ( !stopped )
setState( Paused );
break;
}
case Phonon::StoppedState:
{
stopped = true;
break;
}
default:
break;
}
if ( stopped && m_expectStop )
{
m_expectStop = false;
tDebug( LOGEXTRA ) << "Finding next track.";
loadNextTrack();
}
}
@@ -557,13 +593,15 @@ AudioEngine::timerTriggered( qint64 time )
void
AudioEngine::setPlaylist( PlaylistInterface* playlist )
{
if ( m_playlist )
m_playlist->reset();
if ( !m_playlist.isNull() )
m_playlist.data()->reset();
m_playlist = playlist;
if ( !playlist )
return;
m_playlist = playlist->getSharedPointer();
if ( m_playlist && m_playlist->object() && m_playlist->retryMode() == PlaylistInterface::Retry )
connect( m_playlist->object(), SIGNAL( nextTrackReady() ), SLOT( playlistNextTrackReady() ) );
if ( m_playlist.data()->object() && m_playlist.data()->retryMode() == PlaylistInterface::Retry )
connect( m_playlist.data()->object(), SIGNAL( nextTrackReady() ), SLOT( playlistNextTrackReady() ) );
emit playlistChanged( playlist );
}
@@ -597,3 +635,13 @@ AudioEngine::isLocalResult( const QString& url ) const
{
return url.startsWith( "file://" );
}
void
AudioEngine::setState( AudioState state )
{
AudioState oldState = m_state;
m_state = state;
emit stateChanged( state, oldState );
}

View File

@@ -24,6 +24,7 @@
#include <phonon/MediaObject>
#include <phonon/AudioOutput>
#include <phonon/BackendCapabilities>
#include "infosystem/infosystem.h"
@@ -45,24 +46,29 @@ Q_OBJECT
public:
enum AudioErrorCode { StreamReadError, AudioDeviceError, DecodeError };
enum AudioState { Stopped, Playing, Paused };
static AudioEngine* instance();
explicit AudioEngine();
~AudioEngine();
QStringList supportedMimeTypes() const;
unsigned int volume() const { return m_audioOutput->volume() * 100.0; } // in percent
bool isPlaying() const { return m_mediaObject->state() == Phonon::PlayingState; }
bool isPaused() const { return m_mediaObject->state() == Phonon::PausedState; }
AudioState state() const { return m_state; }
bool isPlaying() const { return m_state == Playing; }
bool isPaused() const { return m_state == Paused; }
bool isStopped() const { return m_state == Stopped; }
/* Returns the PlaylistInterface of the currently playing track. Note: This might be different to the current playlist! */
Tomahawk::PlaylistInterface* currentTrackPlaylist() const { return m_currentTrackPlaylist; }
Tomahawk::PlaylistInterface* currentTrackPlaylist() const { return m_currentTrackPlaylist.data(); }
/* Returns the PlaylistInterface of the current playlist. Note: The currently playing track might still be from a different playlist! */
Tomahawk::PlaylistInterface* playlist() const { return m_playlist; }
Tomahawk::PlaylistInterface* playlist() const { return m_playlist.data(); }
Tomahawk::result_ptr currentTrack() const { return m_currentTrack; }
public slots:
void playPause();
void play();
@@ -83,8 +89,6 @@ public slots:
void setPlaylist( Tomahawk::PlaylistInterface* playlist );
void setQueue( Tomahawk::PlaylistInterface* queue ) { m_queue = queue; }
void onTrackAboutToFinish();
void playlistNextTrackReady();
void infoSystemInfo( Tomahawk::InfoSystem::InfoRequestData requestData, QVariant output );
@@ -98,6 +102,7 @@ signals:
void paused();
void resumed();
void stateChanged( AudioState newState, AudioState oldState );
void volumeChanged( int volume /* in percent */ );
void timerMilliSeconds( qint64 msElapsed );
@@ -120,8 +125,11 @@ private slots:
void setCurrentTrack( const Tomahawk::result_ptr& result );
private:
void setState( AudioState state );
bool isHttpResult( const QString& ) const;
bool isLocalResult( const QString& ) const;
void sendWaitingNotification() const;
void sendNowPlayingNotification();
@@ -130,8 +138,8 @@ private:
Tomahawk::result_ptr m_currentTrack;
Tomahawk::result_ptr m_lastTrack;
Tomahawk::PlaylistInterface* m_playlist;
Tomahawk::PlaylistInterface* m_currentTrackPlaylist;
QWeakPointer< Tomahawk::PlaylistInterface > m_playlist;
QWeakPointer< Tomahawk::PlaylistInterface > m_currentTrackPlaylist;
Tomahawk::PlaylistInterface* m_queue;
Phonon::MediaObject* m_mediaObject;
@@ -142,6 +150,9 @@ private:
bool m_waitingOnNewTrack;
bool m_infoSystemConnected;
mutable QStringList m_supportedMimeTypes;
AudioState m_state;
static AudioEngine* s_instance;
};

View File

@@ -24,6 +24,8 @@
#include "dynamic/DynamicPlaylist.h"
#include "playlist.h"
#include "utils/logger.h"
using namespace Tomahawk;
@@ -61,19 +63,17 @@ source_ptr& Collection::source() const
void
Collection::addPlaylist( const Tomahawk::playlist_ptr& p )
{
// qDebug() << Q_FUNC_INFO;
if ( m_playlists.contains( p->guid() ) )
return;
QList<playlist_ptr> toadd;
toadd << p;
qDebug() << "Inserted playlist with guid:" << p->guid();
// qDebug() << "Inserted playlist with guid:" << p->guid();
m_playlists.insert( p->guid(), p );
qDebug() << Q_FUNC_INFO << "Collection name" << name()
/* qDebug() << Q_FUNC_INFO << "Collection name" << name()
<< "from source id" << source()->id()
<< "numplaylists:" << m_playlists.count();
<< "numplaylists:" << m_playlists.count();*/
emit playlistsAdded( toadd );
}
@@ -81,16 +81,14 @@ Collection::addPlaylist( const Tomahawk::playlist_ptr& p )
void
Collection::addAutoPlaylist( const Tomahawk::dynplaylist_ptr& p )
{
// qDebug() << Q_FUNC_INFO;
QList<dynplaylist_ptr> toadd;
toadd << p;
qDebug() << "Inserted dynamic playlist with guid:" << p->guid();
// qDebug() << "Inserted dynamic playlist with guid:" << p->guid();
m_autoplaylists.insert( p->guid(), p );
qDebug() << Q_FUNC_INFO << "Collection name" << name()
/* qDebug() << Q_FUNC_INFO << "Collection name" << name()
<< "from source id" << source()->id()
<< "numplaylists:" << m_playlists.count();
<< "numplaylists:" << m_playlists.count();*/
emit autoPlaylistsAdded( toadd );
}
@@ -98,16 +96,14 @@ Collection::addAutoPlaylist( const Tomahawk::dynplaylist_ptr& p )
void
Collection::addStation( const dynplaylist_ptr& s )
{
// qDebug() << Q_FUNC_INFO;
QList<dynplaylist_ptr> toadd;
toadd << s;
qDebug() << "Inserted station with guid:" << s->guid();
// qDebug() << "Inserted station with guid:" << s->guid();
m_stations.insert( s->guid(), s );
qDebug() << Q_FUNC_INFO << "Collection name" << name()
/* qDebug() << Q_FUNC_INFO << "Collection name" << name()
<< "from source id" << source()->id()
<< "numplaylists:" << m_playlists.count();
<< "numplaylists:" << m_playlists.count();*/
emit stationsAdded( toadd );
}
@@ -115,15 +111,13 @@ Collection::addStation( const dynplaylist_ptr& s )
void
Collection::deletePlaylist( const Tomahawk::playlist_ptr& p )
{
// qDebug() << Q_FUNC_INFO;
QList<playlist_ptr> todelete;
todelete << p;
m_playlists.remove( p->guid() );
qDebug() << Q_FUNC_INFO << "Collection name" << name()
/* qDebug() << Q_FUNC_INFO << "Collection name" << name()
<< "from source id" << source()->id()
<< "numplaylists:" << m_playlists.count();
<< "numplaylists:" << m_playlists.count();*/
emit playlistsDeleted( todelete );
}
@@ -131,15 +125,13 @@ Collection::deletePlaylist( const Tomahawk::playlist_ptr& p )
void
Collection::deleteAutoPlaylist( const Tomahawk::dynplaylist_ptr& p )
{
// qDebug() << Q_FUNC_INFO;
QList<dynplaylist_ptr> todelete;
todelete << p;
m_autoplaylists.remove( p->guid() );
qDebug() << Q_FUNC_INFO << "Collection name" << name()
/* qDebug() << Q_FUNC_INFO << "Collection name" << name()
<< "from source id" << source()->id()
<< "numplaylists:" << m_playlists.count();
<< "numplaylists:" << m_playlists.count();*/
emit autoPlaylistsDeleted( todelete );
}
@@ -147,15 +139,13 @@ Collection::deleteAutoPlaylist( const Tomahawk::dynplaylist_ptr& p )
void
Collection::deleteStation( const dynplaylist_ptr& s )
{
// qDebug() << Q_FUNC_INFO;
QList<dynplaylist_ptr> todelete;
todelete << s;
m_stations.remove( s->guid() );
qDebug() << Q_FUNC_INFO << "Collection name" << name()
/* qDebug() << Q_FUNC_INFO << "Collection name" << name()
<< "from source id" << source()->id()
<< "numplaylists:" << m_playlists.count();
<< "numplaylists:" << m_playlists.count();*/
emit stationsDeleted( todelete );
}

View File

@@ -30,7 +30,6 @@
#include <QDir>
#include <QList>
#include <QSharedPointer>
#include <QDebug>
#include "functimeout.h"
#include "playlist.h"

View File

@@ -16,14 +16,14 @@
* along with Tomahawk. If not, see <http://www.gnu.org/licenses/>.
*/
#include "contextMenu.h"
#include <QDebug>
#include "contextmenu.h"
#include "globalactionmanager.h"
#include "playlistview.h"
#include "viewmanager.h"
#include "utils/logger.h"
using namespace Tomahawk;

View File

@@ -23,7 +23,8 @@
#include <QMenu>
#include "typedefs.h"
#include "album.h"
#include "artist.h"
#include "dllmacro.h"
namespace Tomahawk

View File

@@ -18,6 +18,8 @@
#include "database.h"
#include "utils/logger.h"
#define DEFAULT_WORKER_THREADS 4
#define MAX_WORKER_THREADS 16
@@ -105,7 +107,7 @@ Database::enqueue( QSharedPointer<DatabaseCommand> lc )
happyThread = worker;
}
qDebug() << "Enqueueing command to thread:" << happyThread << busyThreads << lc->commandname();
// qDebug() << "Enqueueing command to thread:" << happyThread << busyThreads << lc->commandname();
happyThread->enqueue( lc );
}
}

View File

@@ -81,6 +81,7 @@ private:
static Database* s_instance;
friend class Tomahawk::Artist;
friend class Tomahawk::Album;
};
#endif // DATABASE_H

View File

@@ -26,6 +26,8 @@
#include "databasecommand_loadallautoplaylists.h"
#include "databasecommand_loadallstations.h"
#include "utils/logger.h"
using namespace Tomahawk;

View File

@@ -18,8 +18,6 @@
#include "databasecommand.h"
#include <QDebug>
#include "databasecommand_addfiles.h"
#include "databasecommand_createplaylist.h"
#include "databasecommand_deletefiles.h"
@@ -31,7 +29,8 @@
#include "databasecommand_deletedynamicplaylist.h"
#include "databasecommand_setdynamicplaylistrevision.h"
#include "databasecommand_socialaction.h"
#include "databasecommand_loadsocialactions.h"
#include "utils/logger.h"
DatabaseCommand::DatabaseCommand( QObject* parent )

View File

@@ -1,5 +1,5 @@
/* === This file is part of Tomahawk Player - <http://tomahawk-player.org> ===
*
*
* Copyright 2010-2011, Christian Muehlhaeuser <muesli@tomahawk-player.org>
*
* Tomahawk is free software: you can redistribute it and/or modify
@@ -18,9 +18,12 @@
#include "databasecommand_addclientauth.h"
DatabaseCommand_AddClientAuth::DatabaseCommand_AddClientAuth( const QString& clientToken,
const QString& website,
const QString& name,
#include "utils/logger.h"
DatabaseCommand_AddClientAuth::DatabaseCommand_AddClientAuth( const QString& clientToken,
const QString& website,
const QString& name,
const QString& userAgent,
QObject* parent )
: DatabaseCommand( parent )
@@ -31,7 +34,8 @@ DatabaseCommand_AddClientAuth::DatabaseCommand_AddClientAuth( const QString& cli
{
}
void DatabaseCommand_AddClientAuth::exec(DatabaseImpl* lib)
void DatabaseCommand_AddClientAuth::exec( DatabaseImpl* lib )
{
TomahawkSqlQuery q = lib->newquery();
q.prepare( "INSERT INTO http_client_auth (token, website, name, ua, mtime, permissions) VALUES (?, ?, ?, ?, ?, ?)" );
@@ -41,8 +45,9 @@ void DatabaseCommand_AddClientAuth::exec(DatabaseImpl* lib)
q.addBindValue( m_userAgent );
q.addBindValue( 0 );
q.addBindValue( "*" );
if( !q.exec() ) {
if ( !q.exec() )
{
qWarning() << "Failed to insert http client into auth table!";
}
}

View File

@@ -27,6 +27,9 @@
#include "databasecommand_collectionstats.h"
#include "databaseimpl.h"
#include "network/controlconnection.h"
#include "sourcelist.h"
#include "utils/logger.h"
using namespace Tomahawk;
@@ -70,7 +73,15 @@ DatabaseCommand_AddFiles::postCommitHook()
emit notify( m_queries );
if( source()->isLocal() )
{
Servent::instance()->triggerDBSync();
// Re-calculate local db stats
DatabaseCommand_CollectionStats* cmd = new DatabaseCommand_CollectionStats( SourceList::instance()->getLocal() );
connect( cmd, SIGNAL( done( QVariantMap ) ),
SourceList::instance()->getLocal().data(), SLOT( setStats( QVariantMap ) ), Qt::QueuedConnection );
Database::instance()->enqueue( QSharedPointer<DatabaseCommand>( cmd ) );
}
}

View File

@@ -1,5 +1,5 @@
/* === This file is part of Tomahawk Player - <http://tomahawk-player.org> ===
*
*
* Copyright 2010-2011, Christian Muehlhaeuser <muesli@tomahawk-player.org>
*
* Tomahawk is free software: you can redistribute it and/or modify
@@ -16,9 +16,12 @@
* along with Tomahawk. If not, see <http://www.gnu.org/licenses/>.
*/
#include <QSqlQuery>
#include "databasecommand_addsource.h"
#include <QSqlQuery>
#include "databaseimpl.h"
#include "utils/logger.h"
DatabaseCommand_addSource::DatabaseCommand_addSource( const QString& username, const QString& fname, QObject* parent )

View File

@@ -21,6 +21,7 @@
#include <QSqlQuery>
#include "databaseimpl.h"
#include "utils/logger.h"
void
@@ -73,8 +74,7 @@ DatabaseCommand_AllAlbums::execForArtist( DatabaseImpl* dbi )
al << album;
}
if ( al.count() )
emit albums( al, data() );
emit albums( al, data() );
emit done();
}
@@ -123,8 +123,7 @@ DatabaseCommand_AllAlbums::execForCollection( DatabaseImpl* dbi )
al << album;
}
if ( al.count() )
emit albums( al, data() );
emit albums( al, data() );
emit done();
}

View File

@@ -38,7 +38,7 @@ public:
ModificationTime = 1
};
explicit DatabaseCommand_AllAlbums( const Tomahawk::collection_ptr& collection, const Tomahawk::artist_ptr& artist = Tomahawk::artist_ptr(), QObject* parent = 0 )
explicit DatabaseCommand_AllAlbums( const Tomahawk::collection_ptr& collection = Tomahawk::collection_ptr(), const Tomahawk::artist_ptr& artist = Tomahawk::artist_ptr(), QObject* parent = 0 )
: DatabaseCommand( parent )
, m_collection( collection )
, m_artist( artist )
@@ -55,6 +55,7 @@ public:
void execForCollection( DatabaseImpl* );
void execForArtist( DatabaseImpl* );
void setArtist( const Tomahawk::artist_ptr& artist ) { m_artist = artist; }
void setLimit( unsigned int amount ) { m_amount = amount; }
void setSortOrder( DatabaseCommand_AllAlbums::SortOrder order ) { m_sortOrder = order; }
void setSortDescending( bool descending ) { m_sortDescending = descending; }

View File

@@ -21,6 +21,8 @@
#include <QSqlQuery>
#include "databaseimpl.h"
#include "utils/logger.h"
void
DatabaseCommand_AllArtists::exec( DatabaseImpl* dbi )

View File

@@ -24,6 +24,7 @@
#include "artist.h"
#include "album.h"
#include "sourcelist.h"
#include "utils/logger.h"
void

View File

@@ -1,5 +1,5 @@
/* === This file is part of Tomahawk Player - <http://tomahawk-player.org> ===
*
*
* Copyright 2010-2011, Christian Muehlhaeuser <muesli@tomahawk-player.org>
*
* Tomahawk is free software: you can redistribute it and/or modify
@@ -18,27 +18,36 @@
#include "databasecommand_clientauthvalid.h"
#include "utils/logger.h"
DatabaseCommand_ClientAuthValid::DatabaseCommand_ClientAuthValid( const QString& clientToken, QObject* parent )
: DatabaseCommand( parent )
, m_clientToken( clientToken )
{
}
void DatabaseCommand_ClientAuthValid::exec(DatabaseImpl* lib)
void DatabaseCommand_ClientAuthValid::exec( DatabaseImpl* lib )
{
TomahawkSqlQuery q = lib->newquery();
q.prepare( "SELECT name FROM http_client_auth WHERE token = ?" );
q.prepare( "SELECT name FROM http_client_auth WHERE token = ?" );
q.addBindValue( m_clientToken );
if( q.exec() ) {
if( q.next() ) {
if ( q.exec() )
{
if ( q.next() )
{
QString name = q.value( 0 ).toString();
emit authValid( m_clientToken, name, true );
} else {
}
else
{
emit authValid( m_clientToken, QString(), false );
}
} else {
}
else
{
qWarning() << "Failed to query http auth table for client:" << m_clientToken;
}
}

View File

@@ -1,5 +1,5 @@
/* === This file is part of Tomahawk Player - <http://tomahawk-player.org> ===
*
*
* Copyright 2010-2011, Christian Muehlhaeuser <muesli@tomahawk-player.org>
*
* Tomahawk is free software: you can redistribute it and/or modify
@@ -19,6 +19,7 @@
#include "databasecommand_collectionstats.h"
#include "databaseimpl.h"
#include "utils/logger.h"
using namespace Tomahawk;

View File

@@ -27,23 +27,26 @@
#include "network/servent.h"
#include "viewmanager.h"
#include "utils/logger.h"
using namespace Tomahawk;
DatabaseCommand_CreateDynamicPlaylist::DatabaseCommand_CreateDynamicPlaylist( QObject* parent )
: DatabaseCommand_CreatePlaylist( parent )
: DatabaseCommand_CreatePlaylist( parent )
, m_autoLoad( true )
{
qDebug() << Q_FUNC_INFO << "creating dynamiccreatecommand 1";
tDebug() << Q_FUNC_INFO << "creating dynamiccreatecommand 1";
}
DatabaseCommand_CreateDynamicPlaylist::DatabaseCommand_CreateDynamicPlaylist( const source_ptr& author,
const dynplaylist_ptr& playlist )
const dynplaylist_ptr& playlist, bool autoLoad )
: DatabaseCommand_CreatePlaylist( author, playlist.staticCast<Playlist>() )
, m_playlist( playlist )
, m_autoLoad( autoLoad )
{
qDebug() << Q_FUNC_INFO << "creating dynamiccreatecommand 2";
tDebug() << Q_FUNC_INFO << "creating dynamiccreatecommand 2";
}
@@ -60,8 +63,8 @@ DatabaseCommand_CreateDynamicPlaylist::exec( DatabaseImpl* lib )
qDebug() << "Create dynamic execing!" << m_playlist << m_v;
TomahawkSqlQuery cre = lib->newquery();
cre.prepare( "INSERT INTO dynamic_playlist( guid, pltype, plmode ) "
"VALUES( ?, ?, ? )" );
cre.prepare( "INSERT INTO dynamic_playlist( guid, pltype, plmode, autoload ) "
"VALUES( ?, ?, ?, ? )" );
if( m_playlist.isNull() ) {
QVariantMap m = m_v.toMap();
@@ -73,6 +76,7 @@ DatabaseCommand_CreateDynamicPlaylist::exec( DatabaseImpl* lib )
cre.addBindValue( m_playlist->type() );
cre.addBindValue( m_playlist->mode() );
}
cre.addBindValue( m_autoLoad );
cre.exec();
}
@@ -87,7 +91,7 @@ DatabaseCommand_CreateDynamicPlaylist::postCommitHook()
return;
}
if( report() == false )
if( !DatabaseCommand_CreatePlaylist::report() || report() == false )
return;
qDebug() << Q_FUNC_INFO << "..reporting..";

View File

@@ -1,5 +1,5 @@
/* === This file is part of Tomahawk Player - <http://tomahawk-player.org> ===
*
*
* Copyright 2010-2011, Christian Muehlhaeuser <muesli@tomahawk-player.org>
*
* Tomahawk is free software: you can redistribute it and/or modify
@@ -24,21 +24,31 @@
#include "dynamic/DynamicPlaylist.h"
#include "typedefs.h"
/**
* Create a new dynamic playlist in the database, based on an existing playlist.
*
* If autoLoad is true, this playlist will *not* show up in the sidebar under the playlist tree, and
* it will *not* be replicated to peers. It is useful to show a "specially crafted" playlist in other places
*/
class DatabaseCommand_CreateDynamicPlaylist : public DatabaseCommand_CreatePlaylist
{
Q_OBJECT
Q_PROPERTY( QVariant playlist READ playlistV WRITE setPlaylistV )
public:
explicit DatabaseCommand_CreateDynamicPlaylist( QObject* parent = 0 );
explicit DatabaseCommand_CreateDynamicPlaylist( const Tomahawk::source_ptr& author, const Tomahawk::dynplaylist_ptr& playlist );
explicit DatabaseCommand_CreateDynamicPlaylist( const Tomahawk::source_ptr& author, const Tomahawk::dynplaylist_ptr& playlist, bool autoLoad = true );
QString commandname() const { return "createdynamicplaylist"; }
virtual void exec( DatabaseImpl* lib );
virtual void postCommitHook();
virtual bool doesMutates() const { return true; }
virtual bool loggable() const { return m_autoLoad; }
QVariant playlistV() const
{
if( m_v.isNull() )
@@ -46,14 +56,18 @@ public:
else
return m_v;
}
void setPlaylistV( const QVariant& v )
{
m_v = v;
}
protected:
virtual bool report() { return m_autoLoad; }
private:
Tomahawk::dynplaylist_ptr m_playlist;
bool m_autoLoad;
};
#endif // DATABASECOMMAND_CREATEDYNAMICPLAYLIST_H

View File

@@ -22,6 +22,7 @@
#include "network/servent.h"
#include "viewmanager.h"
#include "utils/logger.h"
using namespace Tomahawk;
@@ -30,7 +31,6 @@ DatabaseCommand_CreatePlaylist::DatabaseCommand_CreatePlaylist( QObject* parent
: DatabaseCommandLoggable( parent )
, m_report( true )
{
qDebug() << Q_FUNC_INFO << "def";
}
@@ -40,7 +40,6 @@ DatabaseCommand_CreatePlaylist::DatabaseCommand_CreatePlaylist( const source_ptr
, m_playlist( playlist )
, m_report( false ) //this ctor used when creating locally, reporting done elsewhere
{
qDebug() << Q_FUNC_INFO;
}
@@ -55,10 +54,14 @@ void
DatabaseCommand_CreatePlaylist::postCommitHook()
{
qDebug() << Q_FUNC_INFO;
if ( source()->isLocal() )
Servent::instance()->triggerDBSync();
if ( m_report == false )
return;
qDebug() << Q_FUNC_INFO << "reporting...";
tDebug() << Q_FUNC_INFO << "reporting...";
if ( m_playlist.isNull() )
{
source_ptr src = source();
@@ -72,16 +75,12 @@ DatabaseCommand_CreatePlaylist::postCommitHook()
{
m_playlist->reportCreated( m_playlist );
}
if ( source()->isLocal() )
Servent::instance()->triggerDBSync();
}
void
DatabaseCommand_CreatePlaylist::createPlaylist( DatabaseImpl* lib, bool dynamic)
{
qDebug() << Q_FUNC_INFO;
Q_ASSERT( !( m_playlist.isNull() && m_v.isNull() ) );
Q_ASSERT( !source().isNull() );
@@ -122,7 +121,6 @@ DatabaseCommand_CreatePlaylist::createPlaylist( DatabaseImpl* lib, bool dynamic)
cre.bindValue( ":creator", m.value( "creator" ) );
cre.bindValue( ":lastmodified", m.value( "lastmodified", 0 ) );
}
qDebug() << "CREATE PLAYLIST:" << cre.boundValues();
cre.exec();
}

View File

@@ -1,5 +1,5 @@
/* === This file is part of Tomahawk Player - <http://tomahawk-player.org> ===
*
*
* Copyright 2010-2011, Christian Muehlhaeuser <muesli@tomahawk-player.org>
*
* Tomahawk is free software: you can redistribute it and/or modify
@@ -53,13 +53,14 @@ public:
{
m_v = v;
}
protected:
void createPlaylist( DatabaseImpl* lib, bool dynamic = false );
bool report() { return m_report; }
virtual bool report() { return m_report; }
void setPlaylist( const Tomahawk::playlist_ptr& playlist ) { m_playlist = playlist; }
QVariant m_v;
private:
Tomahawk::playlist_ptr m_playlist;

View File

@@ -18,10 +18,11 @@
#include "databasecommand_deletedynamicplaylist.h"
#include <QSqlQuery>
#include "dynamic/DynamicPlaylist.h"
#include "network/servent.h"
#include <QSqlQuery>
#include "utils/logger.h"
using namespace Tomahawk;

View File

@@ -27,6 +27,7 @@
#include "databasecommand_collectionstats.h"
#include "databaseimpl.h"
#include "network/controlconnection.h"
#include "utils/logger.h"
using namespace Tomahawk;

View File

@@ -1,5 +1,5 @@
/* === This file is part of Tomahawk Player - <http://tomahawk-player.org> ===
*
*
* Copyright 2010-2011, Christian Muehlhaeuser <muesli@tomahawk-player.org>
*
* Tomahawk is free software: you can redistribute it and/or modify
@@ -21,6 +21,7 @@
#include <QSqlQuery>
#include "network/servent.h"
#include "utils/logger.h"
using namespace Tomahawk;
@@ -57,7 +58,7 @@ DatabaseCommand_DeletePlaylist::postCommitHook()
qDebug() << "Source has gone offline, not emitting to GUI.";
return;
}
playlist_ptr playlist = source()->collection()->playlist( m_playlistguid );
Q_ASSERT( !playlist.isNull() );

View File

@@ -21,6 +21,7 @@
#include <QSqlQuery>
#include "databaseimpl.h"
#include "utils/logger.h"
void

View File

@@ -21,6 +21,7 @@
#include <QSqlQuery>
#include "databaseimpl.h"
#include "utils/logger.h"
void

View File

@@ -0,0 +1,115 @@
/* === This file is part of Tomahawk Player - <http://tomahawk-player.org> ===
*
* Copyright 2010-2011, Leo Franchi <lfranchi@kde.org>
*
* Tomahawk is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* Tomahawk is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with Tomahawk. If not, see <http://www.gnu.org/licenses/>.
*/
#include "databasecommand_genericselect.h"
#include "databaseimpl.h"
#include "utils/logger.h"
#include <sourcelist.h>
#include <artist.h>
#include <album.h>
using namespace Tomahawk;
DatabaseCommand_GenericSelect::DatabaseCommand_GenericSelect( const QString& sqlSelect, QueryType type, int limit, QObject* parent )
: DatabaseCommand( parent )
, m_sqlSelect( sqlSelect )
, m_queryType( type )
, m_limit( limit )
{
}
void
DatabaseCommand_GenericSelect::exec( DatabaseImpl* dbi )
{
TomahawkSqlQuery query = dbi->newquery();
query.prepare( QString( "%1 %2;" ).arg( m_sqlSelect ).arg( m_limit > -1 ? QString( " LIMIT %1" ).arg( m_limit ) : QString() ) );
query.exec();
QList< query_ptr > queries;
QList< artist_ptr > arts;
QList< album_ptr > albs;
// Expecting
while ( query.next() )
{
query_ptr qry;
artist_ptr artist;
album_ptr album;
if ( m_queryType == Track )
{
QString artist, track;
track = query.value( 0 ).toString();
artist = query.value( 1 ).toString();
qry = Tomahawk::Query::get( artist, track, QString(), uuid(), true ); // Only auto-resolve non-local results
} else if ( m_queryType == Artist )
{
int artistId = query.value( 0 ).toInt();
QString artistName = query.value( 1 ).toString();
artist = Tomahawk::Artist::get( artistId, artistName );
} else if ( m_queryType == Album )
{
int albumId = query.value( 0 ).toInt();
QString albumName = query.value( 1 ).toString();
int artistId = query.value( 2 ).toInt();
QString artistName = query.value( 3 ).toString();
artist = Tomahawk::Artist::get( artistId, artistName );
album = Tomahawk::Album::get( albumId, albumName, artist );
}
QVariantList extraData;
int count = 2;
while ( query.value( count ).isValid() )
{
extraData << query.value( count );
count++;
}
if ( m_queryType == Track )
{
if ( !extraData.isEmpty() )
qry->setProperty( "data", extraData );
queries << qry;
} else if ( m_queryType == Artist )
{
if ( !extraData.isEmpty() )
artist->setProperty( "data", extraData );
arts << artist;
} else if ( m_queryType == Album )
{
if ( !extraData.isEmpty() )
album->setProperty( "data", extraData );
albs << album;
}
}
if ( m_queryType == Track )
emit tracks( queries );
else if ( m_queryType == Artist )
emit artists( arts );
else if ( m_queryType == Album )
emit albums( albs );
}

View File

@@ -0,0 +1,80 @@
/* === This file is part of Tomahawk Player - <http://tomahawk-player.org> ===
*
* Copyright 2010-2011, Leo Franchi <lfranchi@kde.org>
*
* Tomahawk is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* Tomahawk is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with Tomahawk. If not, see <http://www.gnu.org/licenses/>.
*/
#ifndef DATABASECOMMAND_GENERICSELECT_H
#define DATABASECOMMAND_GENERICSELECT_H
#include <QVariantMap>
#include "databasecommand.h"
#include "source.h"
#include "typedefs.h"
#include "dllmacro.h"
/**
* This dbcmd takes a generic SELECT command that operates on the database and returns a list of query_ptrs
* that match.
*
* In order for the conversion to query_ptr to work, the SELECT command should select the following items:
*
* track query:
* track.name, artist.name [, optional extra values ]
*
* artist query:
* artist.id, artist.name [, optional extra values ]
*
* album query:
* album.id, album.name, artist.id, artist.name [, optional extra values ]
*
* Any extra values in the resultset will be returned as a QVariantList attached to the "data" property of each query_ptr
*
* Notes:
* * Do not trail your SQL command with ;
* * Do not use the LIMIT command if you pass limitResults > -1
*
*/
class DLLEXPORT DatabaseCommand_GenericSelect : public DatabaseCommand
{
Q_OBJECT
public:
enum QueryType {
Track,
Artist,
Album
};
explicit DatabaseCommand_GenericSelect( const QString& sqlSelect, QueryType type, int limitResults = -1, QObject* parent = 0 );
virtual void exec( DatabaseImpl* lib );
virtual bool doesMutates() const { return false; }
virtual QString commandname() const { return "genericselect"; }
signals:
void tracks( const QList< Tomahawk::query_ptr >& tracks );
void artists( const QList< Tomahawk::artist_ptr >& artists );
void albums( const QList< Tomahawk::album_ptr >& albums );
private:
QString m_sqlSelect;
QueryType m_queryType;
int m_limit;
};
#endif // DATABASECOMMAND_GENERICSELECT_H

View File

@@ -1,5 +1,5 @@
/* === This file is part of Tomahawk Player - <http://tomahawk-player.org> ===
*
*
* Copyright 2010-2011, Christian Muehlhaeuser <muesli@tomahawk-player.org>
*
* Tomahawk is free software: you can redistribute it and/or modify
@@ -23,8 +23,11 @@
#include "tomahawk/query.h"
#include "tomahawk/playlist.h"
#include "databaseimpl.h"
#include "utils/logger.h"
void DatabaseCommand_ImportPlaylist::exec(DatabaseImpl * dbi)
void
DatabaseCommand_ImportPlaylist::exec( DatabaseImpl * dbi )
{
/*
qDebug() << "Importing playlist of" << m_playlist->length() << "tracks";

View File

@@ -1,6 +1,6 @@
/* === This file is part of Tomahawk Player - <http://tomahawk-player.org> ===
*
* Copyright 2010-2011, Christian Muehlhaeuser <muesli@tomahawk-player.org>
* Copyright 2010-2011, Leo Franchi <lfranchi@kde.org>
*
* Tomahawk is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
@@ -22,16 +22,18 @@
#include "dynamic/DynamicPlaylist.h"
#include "databaseimpl.h"
#include "utils/logger.h"
using namespace Tomahawk;
void DatabaseCommand_LoadAllAutoPlaylists::exec( DatabaseImpl* dbi )
void
DatabaseCommand_LoadAllAutoPlaylists::exec( DatabaseImpl* dbi )
{
TomahawkSqlQuery query = dbi->newquery();
query.exec( QString( "SELECT playlist.guid as guid, title, info, creator, createdOn, lastmodified, shared, currentrevision, dynamic_playlist.pltype, dynamic_playlist.plmode "
"FROM playlist, dynamic_playlist WHERE source %1 AND dynplaylist = 'true' AND playlist.guid = dynamic_playlist.guid AND dynamic_playlist.plmode = %2" )
"FROM playlist, dynamic_playlist WHERE source %1 AND dynplaylist = 'true' AND playlist.guid = dynamic_playlist.guid AND dynamic_playlist.plmode = %2 AND dynamic_playlist.autoload = 'true'" )
.arg( source()->isLocal() ? "IS NULL" : QString( "=%1" ).arg( source()->id() ) )
.arg( Static ) );

View File

@@ -1,6 +1,6 @@
/* === This file is part of Tomahawk Player - <http://tomahawk-player.org> ===
*
* Copyright 2010-2011, Christian Muehlhaeuser <muesli@tomahawk-player.org>
* Copyright 2010-2011, Leo Franchi <lfranchi@kde.org>
*
* Tomahawk is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by

View File

@@ -22,11 +22,13 @@
#include "playlist.h"
#include "databaseimpl.h"
#include "utils/logger.h"
using namespace Tomahawk;
void DatabaseCommand_LoadAllPlaylists::exec( DatabaseImpl* dbi )
void
DatabaseCommand_LoadAllPlaylists::exec( DatabaseImpl* dbi )
{
TomahawkSqlQuery query = dbi->newquery();

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