From 0668d82c3f543d81e4471ad674f4e1bc182f2e2a Mon Sep 17 00:00:00 2001 From: Tomahawk CI Date: Tue, 1 Jan 2013 01:17:07 +0100 Subject: [PATCH 1/8] Automatic merge of Transifex translations --- lang/tomahawk_fr.ts | 38 +++++++++++++++++++------------------- 1 file changed, 19 insertions(+), 19 deletions(-) diff --git a/lang/tomahawk_fr.ts b/lang/tomahawk_fr.ts index c60aef685..3d6585879 100644 --- a/lang/tomahawk_fr.ts +++ b/lang/tomahawk_fr.ts @@ -547,7 +547,7 @@ de se connecter et streamer de vous? Steer this station: - + Modifier cette station : @@ -632,12 +632,12 @@ de se connecter et streamer de vous? Apply steering command - + Appliquer la modification Reset all steering commands - + Annuler toutes les modifications @@ -1017,42 +1017,42 @@ de se connecter et streamer de vous? Accuracy - + Précision Perfect match - + Correspondance parfaite Very good match - + Très bonne correspondance Good match - + Bonne correspondance Vague match - + Vague correspondance Bad match - + Mauvaise correspondance Very bad match - + Très mauvaise correspondance Not available - + Indisponible @@ -1328,13 +1328,13 @@ de se connecter et streamer de vous? %1 Config - + %1 Configuration %1 Configuration - + %1 Configuration @@ -2418,7 +2418,7 @@ Essayez de vous authentifier de nouveau. Local Network - + Réseau local @@ -2426,7 +2426,7 @@ Essayez de vous authentifier de nouveau. Local Network - + Réseau local @@ -3146,7 +3146,7 @@ Essayez de changer les filtres pour avoir de nouveaux morceaux à jouer. %n people - + %n personne%n personnes @@ -3175,7 +3175,7 @@ Essayez de changer les filtres pour avoir de nouveaux morceaux à jouer. Track '%1' by %2 is not streamable. - + La piste '%1' par %2 n'est pas écoutable. @@ -3266,7 +3266,7 @@ saisissez le numéro PIN ici : Local Network - + Réseau local @@ -3547,7 +3547,7 @@ saisissez le numéro PIN ici : Sorry, there is a problem accessing your audio device or the desired track, current track will be skipped. - Désolé, il y a un problème d'accès à votre matériel audio ou la piste en cours va être sauter. + Désolé, il y a un problème d'accès à votre matériel audio ou la piste en cours , celle-ci va être sautée. From ae4663f4c48e937721d02d50fb005249fb9c4972 Mon Sep 17 00:00:00 2001 From: Tomahawk CI Date: Wed, 2 Jan 2013 11:11:59 +0100 Subject: [PATCH 2/8] Automatic merge of Transifex translations --- lang/tomahawk_cs.ts | 4242 +++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 4242 insertions(+) create mode 100644 lang/tomahawk_cs.ts diff --git a/lang/tomahawk_cs.ts b/lang/tomahawk_cs.ts new file mode 100644 index 000000000..764d0d437 --- /dev/null +++ b/lang/tomahawk_cs.ts @@ -0,0 +1,4242 @@ + + + ACLJobDelegate + + + Allow %1 to +connect and stream from you? + + + + + Allow Streaming + + + + + Deny Access + + + + + ACLJobItem + + + Tomahawk needs you to decide whether %1 is allowed to connect. + + + + + AccountFactoryWrapper + + + Dialog + + + + + Description goes here + + + + + Add Account + + + + + AccountFactoryWrapperDelegate + + + Online + + + + + Connecting... + + + + + Offline + + + + + AccountListWidget + + + Connections + + + + + + Connect &All + + + + + Disconnect &All + + + + + AccountWidget + + + Invite + + + + + AccountsToolButton + + + Configure Accounts + + + + + ActionCollection + + + &Listen Along + + + + + Stop &Listening Along + + + + + &Follow in real-time + + + + + + &Listen Privately + + + + + + &Listen Publicly + + + + + &Load Playlist + + + + + &Rename Playlist + + + + + &Copy Playlist Link + + + + + &Play + + + + + &Stop + + + + + &Previous Track + + + + + &Next Track + + + + + &Quit + + + + + Load &XSPF... + + + + + U&pdate Collection + + + + + Fully &Rescan Collection + + + + + Show Offline Sources + + + + + &Configure Tomahawk... + + + + + Minimize + + + + + Zoom + + + + + Hide Menu Bar + + + + + Diagnostics... + + + + + About &Tomahawk... + + + + + &Legal Information... + + + + + Check For Updates... + + + + + &Controls + + + + + &Settings + + + + + &Help + + + + + &Window + + + + + Main Menu + + + + + AlbumInfoWidget + + + Tracklist + + + + + Other Albums + + + + + Sorry, we could not find any other albums for this artist! + + + + + Sorry, we could not find any tracks for this album! + + + + + Other Albums by %1 + + + + + AlbumModel + + + + All albums from %1 + + + + + All albums + + + + + ArtistInfoWidget + + + Top Hits + + + + + Related Artists + + + + + Albums + + + + + Sorry, we could not find any albums for this artist! + + + + + Sorry, we could not find any related artists! + + + + + Sorry, we could not find any top hits for this artist! + + + + + AudioControls + + + Shuffle + + + + + Repeat + + + + + Time Elapsed + + + + + Time Remaining + + + + + Playing from %1 + + + + + Share + + + + + Love + + + + + AudioEngine + + + Sorry, Tomahawk couldn't find the track '%1' by %2 + + + + + Sorry, Tomahawk couldn't find the artist '%1' + + + + + Sorry, Tomahawk couldn't find the album '%1' by %2 + + + + + CategoryAddItem + + + Create new Playlist + + + + + Create new Station + + + + + + New Station + + + + + + %1 Station + + + + + CategoryItem + + + Playlists + + + + + Stations + + + + + ClearButton + + + Clear + + + + + ContextWidget + + + + Show Footnotes + + + + + Hide Footnotes + + + + + CrashReporter + + + Tomahawk Crash Reporter + + + + + <html><head/><body><p><span style=" font-weight:600;">Sorry!</span> Tomahawk crashed. Please tell us about it! Tomahawk has created an error report for you that can help improve the stability in the future. You can now send this report directly to the Tomahawk developers.</p></body></html> + + + + + Send this report + + + + + Don't send + + + + + Abort + + + + + You can disable sending crash reports in the configuration dialog. + + + + + Uploaded %L1 of %L2 KB. + + + + + + Close + + + + + Sent! <b>Many thanks</b>. + + + + + Failed to send crash info. + + + + + DatabaseCommand_AllAlbums + + + Unknown + + + + + DelegateConfigWrapper + + + About + + + + + Delete Account + + + + + About this Account + + + + + DiagnosticsDialog + + + Tomahawk Diagnostics + + + + + &Copy to Clipboard + + + + + Open &Log-file + + + + + EchonestSteerer + + + Steer this station: + + + + + Much less + + + + + Less + + + + + A bit less + + + + + Keep at current + + + + + A bit more + + + + + More + + + + + Much more + + + + + Tempo + + + + + Loudness + + + + + Danceability + + + + + Energy + + + + + Song Hotttnesss + + + + + Artist Hotttnesss + + + + + Artist Familiarity + + + + + By Description + + + + + Enter a description + + + + + Apply steering command + + + + + Reset all steering commands + + + + + FlexibleHeader + + + Filter... + + + + + FlexibleView + + + This playlist is currently empty. + + + + + This playlist is currently empty. Add some tracks to it and enjoy the music! + + + + + IndexingJobItem + + + Indexing database + + + + + InfoBar + + + Filter... + + + + + LastFmConfig + + + Scrobble tracks to Last.fm + + + + + Username: + + + + + Password: + + + + + Test Login + + + + + Import Playback History + + + + + Synchronize Loved Tracks + + + + + LastfmContext + + + Last.fm + + + + + LatchedStatusItem + + + %1 is listening along with you! + + + + + LoadXSPF + + + Load XSPF + + + + + Playlist URL + + + + + Enter URL... + + + + + ... + + + + + Automatically update + + + + + LoadXSPFDialog + + + Load XSPF File + + + + + XSPF Files (*.xspf) + + + + + LocalCollection + + + Bookmarks + + + + + Saved tracks + + + + + LovedTracksItem + + + Top Loved Tracks + + + + + Sorry, we could not find any loved tracks! + + + + + The most loved tracks from all your friends + + + + + All of your loved tracks + + + + + All of %1's loved tracks + + + + + Loved Tracks + + + + + MetadataEditor + + + Tags + + + + + Title: + + + + + Title... + + + + + Artist: + + + + + Artist... + + + + + Album: + + + + + Album... + + + + + Track Number: + + + + + Duration: + + + + + 00.00 + + + + + Year: + + + + + Bitrate: + + + + + File + + + + + File Name: + + + + + File Name... + + + + + File Size... + + + + + File size... + + + + + File Size: + + + + + Back + + + + + Forward + + + + + Properties + + + + + NewPlaylistWidget + + + Enter a title for the new playlist: + + + + + Tomahawk offers a variety of ways to help you create playlists and find music you enjoy! + + + + + Just enter a genre or tag name and Tomahawk will suggest a few songs to get you started with your new playlist: + + + + + &Create Playlist + + + + + Create a new playlist + + + + + NewReleasesWidget + + + New Releases + + + + + PlayableModel + + + Artist + + + + + Title + + + + + Composer + + + + + Album + + + + + Track + + + + + Duration + + + + + Bitrate + + + + + Age + + + + + Year + + + + + Size + + + + + Origin + + + + + Accuracy + + + + + Perfect match + + + + + Very good match + + + + + Good match + + + + + Vague match + + + + + Bad match + + + + + Very bad match + + + + + Not available + + + + + + Name + + + + + PlaylistItemDelegate + + + played %1 by you + + + + + played %1 by %2 + + + + + PlaylistLargeItemDelegate + + + played %1 by you + e.g. played 3 hours ago by you + + + + + played %1 by %2 + e.g. played 3 hours ago by SomeSource + + + + + added %1 + e.g. added 3 hours ago + + + + + by <b>%1</b> + e.g. by SomeArtist + + + + + by <b>%1</b> on <b>%2</b> + e.g. by SomeArtist on SomeAlbum + + + + + PlaylistModel + + + A playlist you created %1. + + + + + + A playlist by %1, created %2. + + + + + All tracks by %1 on album %2 + + + + + All tracks by %1 + + + + + PlaylistTypeSelectorDlg + + + New Playlist + + + + + Just a regular old playlist... Give it a name, drag in some tracks, and go! + + + + + Don't know exactly what you want? Give Tomahawk a few pointers and let it build a playlist for you! + + + + + Name: + + + + + New Playlist... + + + + + Create Manual Playlist + + + + + Create Automatic Playlist + + + + + PlaylistView + + + This playlist is currently empty. + + + + + This playlist is currently empty. Add some tracks to it and enjoy the music! + + + + + ProxyDialog + + + Proxy Settings + + + + + Hostname of proxy server + + + + + Host + + + + + Port + + + + + Proxy login + + + + + User + + + + + Password + + + + + Proxy password + + + + + No Proxy Hosts: +(Overrides system proxy) + + + + + localhost *.example.com (space separated) + + + + + Use proxy for DNS lookups? + + + + + QObject + + + %n year(s) ago + + + + + %n year(s) + + + + + %n month(s) ago + + + + + %n month(s) + + + + + %n week(s) ago + + + + + %n week(s) + + + + + %n day(s) ago + + + + + %n day(s) + + + + + %n hour(s) ago + + + + + %n hour(s) + + + + + %1 minutes ago + + + + + %1 minutes + + + + + just now + + + + + Friend Finders + + + + + Music Finders + + + + + Status Updaters + + + + + + %1 Config + + + + + + %1 Configuration + + + + + QuaZipFilePrivate + + + ZIP/UNZIP API error %1 + + + + + QueueView + + + + Open Queue + + + + + Open Queue - %n item(s) + + + + + Close Queue + + + + + RelatedArtistsContext + + + Related Artists + + + + + ResolverConfigDelegate + + + Not found: %1 + + + + + Failed to load: %1 + + + + + SearchLineEdit + + + Search + + + + + SearchWidget + + + Search: %1 + + + + + Results for '%1' + + + + + SettingsDialog + + + Collection + + + + + Advanced + + + + + All + + + + + Some changed settings will not take effect until Tomahawk is restarted + + + + + Services + + + + + Install from file + + + + + Configure the accounts and services used by Tomahawk to search and retrieve music, find your friends and update your status. + + + + + Manage how Tomahawk finds music on your computer. + + + + + Configure Tomahawk's advanced settings, including network connectivity settings, browser interaction and more. + + + + + Install resolver from file + + + + + Delete all Access Control entries? + + + + + Do you really want to delete all Access Control entries? You will be asked for a decision again for each peer that you connect to. + + + + + Information + + + + + Settings_Accounts + + + Filter by capability: + + + + + Settings_Advanced + + + Remote Peer Connection Method + + + + + None (outgoing connections only) + + + + + Use UPnP to establish port forward (recommended) + + + + + Use static external IP address/host name and port + + + + + Set this to your external IP address or host name. Make sure to forward the port to this host! + + + + + Static Host Name: + + + + + Static Port: + + + + + SOCKS Proxy + + + + + Use SOCKS Proxy + + + + + Proxy Settings... + + + + + Other Settings + + + + + Allow web browsers to interact with Tomahawk (recommended) + + + + + Send reports after Tomahawk crashed + + + + + Show notification when a new song starts to play + + + + + Clear All Access Control Entries + + + + + Settings_Collection + + + Path to scan for music files: + + + + + The Echo Nest supports keeping track of your catalog metadata + and using it to craft personalized radios. Enabling this option + will allow you (and all your friends) to create automatic playlists + and stations based on your personal taste profile. + + + + + Upload collection list to The Echo Nest to enable user radio + + + + + Watch for changes + + + + + Time between scans, in seconds: + + + + + SlideSwitchButton + + + On + + + + + Off + + + + + SocialPlaylistWidget + + + Popular New Albums From Your Friends + + + + + Most Played Playlists + + + + + Most Played Tracks You Don't Have + + + + + SocialWidget + + + Facebook + + + + + Twitter + + + + + Tweet + + + + + Listening to "%1" by %2. %3 + + + + + Listening to "%1" by %2 on "%3". %4 + + + + + %1 characters left + + + + + SourceDelegate + + + Track + + + + + Album + + + + + Artist + + + + + Local + + + + + Top 10 + + + + + All available tracks + + + + + + Show + + + + + + Hide + + + + + SourceInfoWidget + + + Recent Albums + + + + + Latest Additions + + + + + Recently Played Tracks + + + + + New Additions + + + + + My recent activity + + + + + Recent activity from %1 + + + + + SourceItem + + + Collection + + + + + + Latest Additions + + + + + Recently Played + + + + + SuperCollection + + + + + Latest additions to your collection + + + + + Latest additions to %1's collection + + + + + Sorry, we could not find any recent additions! + + + + + Recently Played Tracks + + + + + Your recently played tracks + + + + + %1's recently played tracks + + + + + Sorry, we could not find any recent plays! + + + + + SourceTreeView + + + &Copy Link + + + + + &Delete %1 + + + + + Add to my Playlists + + + + + Add to my Automatic Playlists + + + + + Add to my Stations + + + + + &Export Playlist + + + + + playlist + + + + + automatic playlist + + + + + station + + + + + Would you like to delete the %1 <b>"%2"</b>? + e.g. Would you like to delete the playlist named Foobar? + + + + + Delete + + + + + Save XSPF + + + + + Playlists (*.xspf) + + + + + SourcesModel + + + Group + + + + + Collection + + + + + Playlist + + + + + Automatic Playlist + + + + + Station + + + + + Browse + + + + + Search History + + + + + My Music + + + + + SuperCollection + + + + + Dashboard + + + + + Recently Played + + + + + Charts + + + + + New Releases + + + + + Friends + + + + + SpotifyConfig + + + Configure your Spotify account + + + + + Username or Facebook Email + + + + + Log In + + + + + Right click on any Tomahawk playlist to sync it to Spotify. + + + + + Select All + + + + + Sync Starred tracks to Loved tracks + + + + + High Quality Streams + + + + + Spotify playlists to keep in sync: + + + + + Delete Tomahawk playlist when removing synchronization + + + + + Username: + + + + + Password: + + + + + SpotifyPlaylistUpdater + + + Delete associated Spotify playlist? + + + + + TemporaryPageItem + + + Copy Artist Link + + + + + Copy Album Link + + + + + Copy Track Link + + + + + Tomahawk::Accounts::AccountDelegate + + + Add Account + + + + + Remove + + + + + %1 downloads + + + + + Online + + + + + Connecting... + + + + + Offline + + + + + Tomahawk::Accounts::AccountModel + + + Manual Install Required + + + + + Unfortunately, automatic installation of this resolver is not available or disabled for your platform.<br /><br />Please use "Install from file" above, by fetching it from your distribution or compiling it yourself. Further instructions can be found here:<br /><br />http://www.tomahawk-player.org/resolvers/%1 + + + + + Tomahawk::Accounts::GoogleWrapper + + + Configure this Google Account + + + + + Google Address: + + + + + Enter your Google login to connect with your friends using Tomahawk! + + + + + username@gmail.com + + + + + Tomahawk::Accounts::GoogleWrapperFactory + + + Connect to Google Talk to find your friends + + + + + Tomahawk::Accounts::GoogleWrapperSip + + + Enter Google Address + + + + + Add Friend + + + + + Enter Google Address: + + + + + Tomahawk::Accounts::LastFmAccountFactory + + + Scrobble your tracks to last.fm, and find freely downloadable tracks to play + + + + + Tomahawk::Accounts::LastFmConfig + + + Testing... + + + + + Test Login + + + + + Importing %1 + e.g. Importing 2012/01/01 + + + + + Importing History... + + + + + History Incomplete. Resume + Text on a button that resumes import + + + + + Playback History Imported + + + + + + Failed + + + + + Success + + + + + Could not contact server + + + + + Synchronizing... + + + + + Synchronization Finished + + + + + Tomahawk::Accounts::SpotifyAccount + + + Sync with Spotify + + + + + Re-enable syncing with Spotify + + + + + Create local copy + + + + + Subscribe to playlist changes + + + + + Re-enable playlist subscription + + + + + Stop subscribing to changes + + + + + Enable Spotify collaborations + + + + + Disable Spotify collaborations + + + + + Stop syncing with Spotify + + + + + Tomahawk::Accounts::SpotifyAccountConfig + + + Logging in... + + + + + Failed: %1 + + + + + Logged in as %1 + + + + + Log Out + + + + + + Log In + + + + + Tomahawk::Accounts::SpotifyAccountFactory + + + Play music from and sync your playlists with Spotify Premium + + + + + Tomahawk::Accounts::TwitterAccountFactory + + + Connect to your Twitter followers. + + + + + Tomahawk::Accounts::TwitterConfigWidget + + + + + Tweet! + + + + + + Status: No saved credentials + + + + + + + Authenticate + + + + + + Status: Credentials saved for %1 + + + + + + De-authenticate + + + + + + + + + + + Tweetin' Error + + + + + The credentials could not be verified. +You may wish to try re-authenticating. + + + + + Status: Error validating credentials + + + + + Global Tweet + + + + + Direct Message + + + + + Send Message! + + + + + @Mention + + + + + Send Mention! + + + + + You must enter a user name for this type of tweet. + + + + + Your saved credentials could not be loaded. +You may wish to try re-authenticating. + + + + + Your saved credentials could not be verified. +You may wish to try re-authenticating. + + + + + + There was an error posting your status -- sorry! + + + + + + Tweeted! + + + + + Your tweet has been posted! + + + + + There was an error posting your direct message -- sorry! + + + + + Your message has been posted! + + + + + Tomahawk::Accounts::XmppAccountFactory + + + Log on to your Jabber/XMPP account to connect to your friends + + + + + Tomahawk::Accounts::ZeroconfAccount + + + + Local Network + + + + + Tomahawk::Accounts::ZeroconfFactory + + + Local Network + + + + + Automatically connect to Tomahawks on the local network + + + + + Tomahawk::ContextMenu + + + &Play + + + + + + + Add to &Queue + + + + + Continue Playback after this &Track + + + + + Stop Playback after this &Track + + + + + + &Love + + + + + + + &Go to "%1" + + + + + + + Go to "%1" + + + + + &Copy Track Link + + + + + Copy Album &Link + + + + + Copy Artist &Link + + + + + Un-&Love + + + + + &Delete Items + + + + + Properties... + + + + + &Delete Item + + + + + Tomahawk::DropJobNotifier + + + playlist + + + + + artist + + + + + track + + + + + album + + + + + Fetching %1 from database + + + + + Parsing %1 %2 + + + + + Tomahawk::DynamicControlList + + + Click to collapse + + + + + Tomahawk::DynamicModel + + + + Could not find a playable track. + +Please change the filters or try again. + + + + + Failed to generate preview with the desired filters + + + + + Tomahawk::DynamicSetupWidget + + + Type: + + + + + Generate + + + + + Tomahawk::DynamicView + + + Add some filters above to seed this station! + + + + + Press Generate to get started! + + + + + Add some filters above, and press Generate to get started! + + + + + Tomahawk::DynamicWidget + + + Station ran out of tracks! + +Try tweaking the filters for a new set of songs to play. + + + + + Tomahawk::EchonestControl + + + + + + + + is + + + + + from user + + + + + + No users with Echo Nest Catalogs enabled. Try enabling option in Collection settings + + + + + similar to + + + + + + + + + + + Less + + + + + + + + + + + More + + + + + 0 BPM + + + + + 500 BPM + + + + + 0 secs + + + + + 3600 secs + + + + + -100 dB + + + + + 100 dB + + + + + Major + + + + + Minor + + + + + C + + + + + C Sharp + + + + + D + + + + + E Flat + + + + + E + + + + + F + + + + + F Sharp + + + + + G + + + + + A Flat + + + + + A + + + + + B Flat + + + + + B + + + + + Ascending + + + + + Descending + + + + + Tempo + + + + + Duration + + + + + Loudness + + + + + + Artist Familiarity + + + + + + Artist Hotttnesss + + + + + + Song Hotttnesss + + + + + Latitude + + + + + Longitude + + + + + Mode + + + + + Key + + + + + + Energy + + + + + + Danceability + + + + + only by ~%1 + + + + + + similar to ~%1 + + + + + with genre ~%1 + + + + + + from no one + + + + + My Collection + + + + + from my radio + + + + + from %1 radio + + + + + Variety + + + + + Adventurousness + + + + + very low + + + + + low + + + + + moderate + + + + + high + + + + + very high + + + + + with %1 %2 + + + + + about %1 BPM + + + + + about %n minute(s) long + + + + + about %1 dB + + + + + at around %1%2 %3 + + + + + in %1 + + + + + in a %1 key + + + + + sorted in %1 %2 order + + + + + with a %1 mood + + + + + in a %1 style + + + + + Tomahawk::GroovesharkParser + + + Error fetching Grooveshark information from the network! + + + + + Tomahawk::InfoSystem::ChartsPlugin + + + Top Overall + + + + + Artists + + + + + Albums + + + + + Tracks + + + + + Tomahawk::InfoSystem::FdoNotifyPlugin + + + Tomahawk is playing "%1" by %2%3. + + + + + on "%1" + + + + + Tomahawk::InfoSystem::LastFmInfoPlugin + + + Top Tracks + + + + + Loved Tracks + + + + + Hyped Tracks + + + + + Top Artists + + + + + Hyped Artists + + + + + Tomahawk::InfoSystem::NewReleasesPlugin + + + Albums + + + + + Tomahawk::InfoSystem::TwitterInfoPlugin + + + Listening to "%1" by %2 and loving it! %3 + + + + + Tomahawk::ItunesParser + + + Error fetching iTunes information from the network! + + + + + Tomahawk::JSPFLoader + + + New Playlist + + + + + Failed to save tracks + + + + + Some tracks in the playlist do not contain an artist and a title. They will be ignored. + + + + + XSPF Error + + + + + This is not a valid XSPF playlist. + + + + + Tomahawk::LatchManager + + + &Catch Up + + + + + + &Listen Along + + + + + Tomahawk::Playlist + + + Would you like to delete the playlist <b>"%2"</b>? + e.g. Would you like to delete the playlist named Foobar? + + + + + Delete + + + + + Tomahawk::Query + + + and + + + + + You + + + + + you + + + + + and + + + + + %n other(s) + + + + + %n people + + + + + loved this track + + + + + Tomahawk::RdioParser + + + Error fetching Rdio information from the network! + + + + + Tomahawk::ShortenedLinkParser + + + Network error parsing shortened link! + + + + + Tomahawk::SoundcloudParser + + + Track '%1' by %2 is not streamable. + + + + + Tomahawk::Source + + + + Scanning (%L1 tracks) + + + + + Scanning + + + + + Checking + + + + + Syncing + + + + + Importing + + + + + Saving (%1%) + + + + + Online + + + + + Offline + + + + + Tomahawk::SpotifyParser + + + Error fetching Spotify information from the network! + + + + + Tomahawk::XspfUpdater + + + Automatically update from XSPF + + + + + TomahawkApp + + + My Collection + + + + + TomahawkOAuthTwitter + + + Twitter PIN + + + + + After authenticating on Twitter's web site, +enter the displayed PIN number here: + + + + + TomahawkSettings + + + Local Network + + + + + TomahawkTrayIcon + + + &Stop Playback after current Track + + + + + + Hide Tomahawk Window + + + + + Show Tomahawk Window + + + + + Currently not playing. + + + + + Play + + + + + Pause + + + + + &Love + + + + + Un-&Love + + + + + &Continue Playback after current Track + + + + + TomahawkWindow + + + Tomahawk + + + + + &Quit + + + + + Ctrl+Q + + + + + Go &Online + + + + + Add &Friend... + + + + + U&pdate Collection + + + + + Update Collection + + + + + &Configure Tomahawk... + + + + + Load &XSPF... + + + + + Create &New Playlist... + + + + + About &Tomahawk... + + + + + Create New &Automatic Playlist + + + + + Create New &Station + + + + + Show Offline Sources + + + + + Hide Offline Sources + + + + + Minimize + + + + + Ctrl+M + + + + + Zoom + + + + + Meta+Ctrl+Z + + + + + &Legal Info... + + + + + Diagnostics... + + + + + Fully &Rescan Collection + + + + + Fully Rescan Collection + + + + + Play + + + + + Space + + + + + Previous + + + + + Next + + + + + Back + + + + + Go back one page + + + + + Forward + + + + + Go forward one page + + + + + + Hide Menu Bar + + + + + + Show Menu Bar + + + + + Search for any artist, album or song... + + + + + &Main Menu + + + + + + + Connect To Peer + + + + + Enter peer address: + + + + + Enter peer port: + + + + + Enter peer key: + + + + + XSPF Error + + + + + This is not a valid XSPF playlist. + + + + + Failed to save tracks + + + + + Some tracks in the playlist do not contain an artist and a title. They will be ignored. + + + + + Sorry, there is a problem accessing your audio device or the desired track, current track will be skipped. Make sure you have a suitable Phonon backend and required plugins installed. + + + + + Sorry, there is a problem accessing your audio device or the desired track, current track will be skipped. + + + + + Station + + + + + Create New Station + + + + + Name: + + + + + Playlist + + + + + Automatic Playlist + + + + + Pause + + + + + &Play + + + + + Authentication Error + + + + + Error connecting to SIP: Authentication failed! + + + + + %1 by %2 + track, artist name + + + + + %1 - %2 + current track, some window title + + + + + <h2><b>Tomahawk %1<br/>(%2)</h2> + + + + + <h2><b>Tomahawk %1</h2> + + + + + Copyright 2010 - 2012 + + + + + Thanks to: + + + + + About Tomahawk + + + + + TopTracksContext + + + Top Hits + + + + + TrackInfoWidget + + + Similar Tracks + + + + + Sorry, but we could not find similar tracks for this song! + + + + + You've listened to this track %n time(s). + + + + + You've never listened to this track before. + + + + + You first listened to it on %1. + + + + + You've listened to %1 %n time(s). + + + + + You've never listened to %1 before. + + + + + TrackView + + + Sorry, your filter '%1' did not match any results. + + + + + TransferStatusItem + + + from + streaming artist - track from friend + + + + + to + streaming artist - track to friend + + + + + TreeItemDelegate + + + Unknown + + + + + TreeModel + + + All Artists + + + + + + My Collection + + + + + + Collection of %1 + + + + + TreeView + + + Sorry, your filter '%1' did not match any results. + + + + + TwitterConfigWidget + + + Configure this Twitter account + + + + + The Twitter plugin allows you to discover and play music from your Twitter friends running Tomahawk and post messages to your account. + + + + + Status: No saved credentials + + + + + Authenticate with Twitter + + + + + Twitter Connections + + + + + +If you only want to post tweets, you're done. + +If you want to connect Tomahawk to your friends using Twitter, select the type of tweet and press the button below to send a sync message. You must both be following each other as Direct Messages are used. Then be (very) patient -- it can take several minutes! + +You can re-send a sync message at any time simply by sending another tweet using the button. + + + + + Select the kind of tweet you would like, then press the button to post it: + + + + + Global Tweet + + + + + @Mention + + + + + Direct Message + + + + + e.g. @tomahawk + + + + + Send Message + + + + + TwitterSipPlugin + + + Enter Twitter username + + + + + ViewManager + + + This playlist is empty! + + + + + After you have scanned your music collection you will find your tracks right here. + + + + + This collection is empty. + + + + + SuperCollection + + + + + Combined libraries of all your online friends + + + + + Recently Played Tracks + + + + + Recently played tracks from all your friends + + + + + Sorry, we could not find any recent plays! + + + + + WelcomeWidget + + + Recent Additions + + + + + Newest Stations & Playlists + + + + + Recently Played Tracks + + + + + Recently played tracks + + + + + No recently created playlists in your network. + + + + + Welcome to Tomahawk + + + + + WhatsHotWidget + + + Charts + + + + + WikipediaContext + + + Wikipedia + + + + + XMPPBot + + + +Terms for %1: + + + + + + No terms found, sorry. + + + + + +Hotttness for %1: %2 + + + + + + +Familiarity for %1: %2 + + + + + + +Lyrics for "%1" by %2: + +%3 + + + + + + XSPFLoader + + + Failed to parse contents of XSPF playlist + + + + + Some playlist entries were found without artist and track name, they will be omitted + + + + + Failed to fetch the desired playlist from the network, or the desired file does not exist + + + + + New Playlist + + + + + XmlConsole + + + Xml stream console + + + + + + Filter + + + + + Save log + + + + + Disabled + + + + + By JID + + + + + By namespace uri + + + + + By all attributes + + + + + Visible stanzas + + + + + Information query + + + + + Message + + + + + Presence + + + + + Custom + + + + + Close + + + + + Save XMPP log to file + + + + + OpenDocument Format (*.odf);;HTML file (*.html);;Plain text (*.txt) + + + + + XmppConfigWidget + + + Xmpp Configuration + + + + + Configure this Xmpp account + + + + + Enter your Xmpp login to connect with your friends using Tomahawk! + + + + + Login Information + + + + + Xmpp ID: + + + + + e.g. user@example.com + + + + + Password: + + + + + An account with this name already exists! + + + + + Advanced Xmpp Settings + + + + + Server: + + + + + Port: + + + + + Lots of servers don't support this (e.g. GTalk, jabber.org) + + + + + Publish currently playing track + + + + + Enforce secure connection + + + + + XmppSipPlugin + + + User Interaction + + + + + Host is unknown + + + + + Item not found + + + + + Authorization Error + + + + + Remote Stream Error + + + + + Remote Connection failed + + + + + Internal Server Error + + + + + System shutdown + + + + + Conflict + + + + + Unknown + + + + + Do you want to add <b>%1</b> to your friend list? + + + + + No Compression Support + + + + + Enter Jabber ID + + + + + No Encryption Support + + + + + No Authorization Support + + + + + No Supported Feature + + + + + Add Friend + + + + + Enter Xmpp ID: + + + + + Add Friend... + + + + + XML Console... + + + + + I'm sorry -- I'm just an automatic presence used by Tomahawk Player (http://gettomahawk.com). If you are getting this message, the person you are trying to reach is probably not signed on, so please try again later! + + + + + Authorize User + + + + + ZeroconfConfig + + + Local Network configuration + + + + + This plugin will automatically find other users running Tomahawk on your local network + + + + + Connect automatically when Tomahawk starts + + + + \ No newline at end of file From aa168ef57218b197b81ed365214cc6b7e8bcb09c Mon Sep 17 00:00:00 2001 From: Christian Muehlhaeuser Date: Tue, 1 Jan 2013 15:22:03 +0100 Subject: [PATCH 3/8] * Fixed debug output in Api_v1. --- src/web/Api_v1.cpp | 38 +++++++++++++++++++------------------- 1 file changed, 19 insertions(+), 19 deletions(-) diff --git a/src/web/Api_v1.cpp b/src/web/Api_v1.cpp index 819d8c6a2..632f3e2f3 100644 --- a/src/web/Api_v1.cpp +++ b/src/web/Api_v1.cpp @@ -43,11 +43,11 @@ Api_v1::Api_v1(QxtAbstractWebSessionManager* sm, QObject* parent) void Api_v1::auth_1( QxtWebRequestEvent* event, QString arg ) { - qDebug() << "AUTH_1 HTTP" << event->url.toString() << arg; + tDebug( LOGVERBOSE ) << "AUTH_1 HTTP" << event->url.toString() << arg; if ( !event->url.hasQueryItem( "website" ) || !event->url.hasQueryItem( "name" ) ) { - qDebug() << "Malformed HTTP resolve request"; + tDebug( LOGVERBOSE ) << "Malformed HTTP resolve request"; send404( event ); return; } @@ -80,10 +80,10 @@ Api_v1::auth_1( QxtWebRequestEvent* event, QString arg ) void Api_v1::auth_2( QxtWebRequestEvent* event, QString arg ) { - qDebug() << "AUTH_2 HTTP" << event->url.toString() << arg; + tDebug( LOGVERBOSE ) << "AUTH_2 HTTP" << event->url.toString() << arg; if ( event->content.isNull() ) { - qDebug() << "Null content"; + tDebug( LOGVERBOSE ) << "Null content"; send404( event ); return; } @@ -99,13 +99,13 @@ Api_v1::auth_2( QxtWebRequestEvent* event, QString arg ) if ( keyval.size() == 2 ) queryItems.insert( keyval.first(), keyval.last() ); else - qDebug() << "Failed parsing url parameters:" << part; + tDebug( LOGVERBOSE ) << "Failed parsing url parameters:" << part; } - qDebug() << "has query items:" << pieces; + tDebug( LOGVERBOSE ) << "has query items:" << pieces; if ( !params.contains( "website" ) || !params.contains( "name" ) || !params.contains( "formtoken" ) ) { - qDebug() << "Malformed HTTP resolve request"; + tDebug( LOGVERBOSE ) << "Malformed HTTP resolve request"; send404( event ); return; } @@ -113,7 +113,7 @@ Api_v1::auth_2( QxtWebRequestEvent* event, QString arg ) QString website = queryItems[ "website" ]; QString name = queryItems[ "name" ]; QByteArray authtoken = uuid().toLatin1(); - qDebug() << "HEADERS:" << event->headers; + tDebug( LOGVERBOSE ) << "HEADERS:" << event->headers; if ( !queryItems.contains( "receiverurl" ) || queryItems.value( "receiverurl" ).isEmpty() ) { //no receiver url, so do it ourselves @@ -139,7 +139,7 @@ Api_v1::auth_2( QxtWebRequestEvent* event, QString arg ) // do what the client wants QUrl receiverurl = QUrl( queryItems.value( "receiverurl" ), QUrl::TolerantMode ); receiverurl.addEncodedQueryItem( "authtoken", "#" + authtoken ); - qDebug() << "Got receiver url:" << receiverurl.toString(); + tDebug( LOGVERBOSE ) << "Got receiver url:" << receiverurl.toString(); QxtWebRedirectEvent* e = new QxtWebRedirectEvent( event->sessionID, event->requestID, receiverurl.toString() ); postEvent( e ); @@ -155,7 +155,7 @@ Api_v1::auth_2( QxtWebRequestEvent* event, QString arg ) void Api_v1::api( QxtWebRequestEvent* event ) { - qDebug() << "HTTP" << event->url.toString(); + tDebug( LOGVERBOSE ) << "HTTP" << event->url.toString(); const QUrl& url = event->url; if ( url.hasQueryItem( "method" ) ) @@ -178,7 +178,7 @@ Api_v1::sid( QxtWebRequestEvent* event, QString unused ) Q_UNUSED( unused ); RID rid = event->url.path().mid( 5 ); - qDebug() << "Request for sid" << rid; + tDebug( LOGVERBOSE ) << "Request for sid" << rid; result_ptr rp = Pipeline::instance()->result( rid ); if ( rp.isNull() ) @@ -204,7 +204,7 @@ Api_v1::sid( QxtWebRequestEvent* event, QString unused ) void Api_v1::send404( QxtWebRequestEvent* event ) { - qDebug() << "404" << event->url.toString(); + tDebug() << "404" << event->url.toString(); QxtWebPageEvent* wpe = new QxtWebPageEvent( event->sessionID, event->requestID, "

Not Found

" ); wpe->status = 404; wpe->statusMessage = "no event found"; @@ -215,11 +215,11 @@ Api_v1::send404( QxtWebRequestEvent* event ) void Api_v1::stat( QxtWebRequestEvent* event ) { - qDebug() << "Got Stat request:" << event->url.toString(); + tDebug( LOGVERBOSE ) << "Got Stat request:" << event->url.toString(); m_storedEvent = event; if ( !event->content.isNull() ) - qDebug() << "BODY:" << event->content->readAll(); + tDebug( LOGVERBOSE ) << "BODY:" << event->content->readAll(); if ( event->url.hasQueryItem( "auth" ) ) { @@ -262,7 +262,7 @@ Api_v1::resolve( QxtWebRequestEvent* event ) if ( !event->url.hasQueryItem( "artist" ) || !event->url.hasQueryItem( "track" ) ) { - qDebug() << "Malformed HTTP resolve request"; + tDebug( LOGVERBOSE ) << "Malformed HTTP resolve request"; return send404( event ); } @@ -273,7 +273,7 @@ Api_v1::resolve( QxtWebRequestEvent* event ) if ( artist.trimmed().isEmpty() || track.trimmed().isEmpty() ) { - qDebug() << "Malformed HTTP resolve request"; + tDebug( LOGVERBOSE ) << "Malformed HTTP resolve request"; return send404( event ); } @@ -300,7 +300,7 @@ Api_v1::resolve( QxtWebRequestEvent* event ) void Api_v1::staticdata( QxtWebRequestEvent* event, const QString& str ) { - qDebug() << "STATIC request:" << event << str; + tDebug( LOGVERBOSE ) << "STATIC request:" << event << str; if ( str.contains( "tomahawk_auth_logo.png" ) ) { QFile f( RESPATH "www/tomahawk_banner_small.png" ); @@ -318,7 +318,7 @@ Api_v1::get_results( QxtWebRequestEvent* event ) { if ( !event->url.hasQueryItem( "qid" ) ) { - tDebug() << "Malformed HTTP get_results request"; + tDebug( LOGVERBOSE ) << "Malformed HTTP get_results request"; send404( event ); return; } @@ -372,7 +372,7 @@ Api_v1::sendJSON( const QVariantMap& m, QxtWebRequestEvent* event ) e->contentType = ctype; e->headers.insert( "Content-Length", QString::number( body.length() ) ); postEvent( e ); - qDebug() << "JSON response" << event->url.toString() << body; + tDebug( LOGVERBOSE ) << "JSON response" << event->url.toString() << body; } From 2e4cb838ee875cf637226f2747928f4e832cd1c7 Mon Sep 17 00:00:00 2001 From: Christian Muehlhaeuser Date: Wed, 2 Jan 2013 11:09:21 +0100 Subject: [PATCH 4/8] * Added new translation languages to CMakeLists.txt. --- CMakeLists.txt | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index a254e8fd2..f7221bc5e 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -14,10 +14,9 @@ SET( TOMAHAWK_DESCRIPTION_SUMMARY "The social media player" ) SET( TOMAHAWK_VERSION_MAJOR 0 ) SET( TOMAHAWK_VERSION_MINOR 5 ) SET( TOMAHAWK_VERSION_PATCH 99 ) - #SET( TOMAHAWK_VERSION_RC 0 ) -SET( TOMAHAWK_TRANSLATION_LANGUAGES ar bg ca de en es fi fr ja pl pt_BR ru sv tr zh_CN zh_TW ) +SET( TOMAHAWK_TRANSLATION_LANGUAGES ar bg bn_IN ca cs de en el es fi fr hi_IN hu gl it ja lt pl pt_BR ru sv tr zh_CN zh_TW ) # enforce proper symbol exporting on all platforms add_definitions( "-fvisibility=hidden" ) From 4d4b0a29e46b2b90fecb8209aca0170cf3c4431c Mon Sep 17 00:00:00 2001 From: Christian Muehlhaeuser Date: Wed, 2 Jan 2013 11:10:17 +0100 Subject: [PATCH 5/8] * Cleaned up translations.cmake. --- lang/translations.cmake | 32 ++++++++++++++++---------------- 1 file changed, 16 insertions(+), 16 deletions(-) diff --git a/lang/translations.cmake b/lang/translations.cmake index 6b4f89557..7ce1ba422 100644 --- a/lang/translations.cmake +++ b/lang/translations.cmake @@ -1,33 +1,33 @@ macro(add_tomahawk_translations language) - list(APPEND TOMAHAWK_LANGUAGES ${ARGV}) + list( APPEND TOMAHAWK_LANGUAGES ${ARGV} ) - set(tomahawk_i18n_qrc_content "\n") + set( tomahawk_i18n_qrc_content "\n" ) # tomahawk and qt language files - set(tomahawk_i18n_qrc_content "${tomahawk_i18n_qrc_content}\n") - foreach(lang ${TOMAHAWK_LANGUAGES}) - set(tomahawk_i18n_qrc_content "${tomahawk_i18n_qrc_content}tomahawk_${lang}.qm\n") - if(NOT lang STREQUAL "en" AND EXISTS ${QT_TRANSLATIONS_DIR}/qt_${lang}.qm) - file(COPY ${QT_TRANSLATIONS_DIR}/qt_${lang}.qm DESTINATION ${CMAKE_CURRENT_BINARY_DIR}) - set(tomahawk_i18n_qrc_content "${tomahawk_i18n_qrc_content}qt_${lang}.qm\n") + set( tomahawk_i18n_qrc_content "${tomahawk_i18n_qrc_content}\n" ) + foreach( lang ${TOMAHAWK_LANGUAGES} ) + set( tomahawk_i18n_qrc_content "${tomahawk_i18n_qrc_content}tomahawk_${lang}.qm\n" ) + if( NOT lang STREQUAL "en" AND EXISTS ${QT_TRANSLATIONS_DIR}/qt_${lang}.qm ) + file( COPY ${QT_TRANSLATIONS_DIR}/qt_${lang}.qm DESTINATION ${CMAKE_CURRENT_BINARY_DIR} ) + set( tomahawk_i18n_qrc_content "${tomahawk_i18n_qrc_content}qt_${lang}.qm\n" ) endif() # build explicitly enabled languages - list(APPEND TS_FILES "${CMAKE_SOURCE_DIR}/lang/tomahawk_${lang}.ts") + list( APPEND TS_FILES "${CMAKE_SOURCE_DIR}/lang/tomahawk_${lang}.ts" ) endforeach() - set(tomahawk_i18n_qrc_content "${tomahawk_i18n_qrc_content}\n") - set(tomahawk_i18n_qrc_content "${tomahawk_i18n_qrc_content}\n") + set( tomahawk_i18n_qrc_content "${tomahawk_i18n_qrc_content}\n" ) + set( tomahawk_i18n_qrc_content "${tomahawk_i18n_qrc_content}\n" ) - file(WRITE ${CMAKE_BINARY_DIR}/lang/tomahawk_i18n.qrc "${tomahawk_i18n_qrc_content}" ) + file( WRITE ${CMAKE_BINARY_DIR}/lang/tomahawk_i18n.qrc "${tomahawk_i18n_qrc_content}" ) - QT4_ADD_TRANSLATION(QM_FILES ${TS_FILES}) + QT4_ADD_TRANSLATION( QM_FILES ${TS_FILES} ) ## HACK HACK HACK - around rcc limitations to allow out of source-tree building SET( trans_file tomahawk_i18n ) - SET( trans_srcfile ${CMAKE_BINARY_DIR}/lang/${trans_file}.qrc) - SET( trans_infile ${CMAKE_CURRENT_BINARY_DIR}/${trans_file}.qrc) - SET( trans_outfile ${CMAKE_CURRENT_BINARY_DIR}/qrc_${trans_file}.cxx) + SET( trans_srcfile ${CMAKE_BINARY_DIR}/lang/${trans_file}.qrc ) + SET( trans_infile ${CMAKE_CURRENT_BINARY_DIR}/${trans_file}.qrc ) + SET( trans_outfile ${CMAKE_CURRENT_BINARY_DIR}/qrc_${trans_file}.cxx ) # Copy the QRC file to the output directory ADD_CUSTOM_COMMAND( From 31d47c0454411d4596e77039a3777219dedce8cf Mon Sep 17 00:00:00 2001 From: Kilian Lackhove Date: Wed, 2 Jan 2013 14:00:10 +0100 Subject: [PATCH 6/8] show icon in accountswidget for external resolvers, too --- src/libtomahawk/accounts/AccountDelegate.cpp | 2 +- src/libtomahawk/accounts/ResolverAccount.cpp | 5 +++++ src/libtomahawk/accounts/ResolverAccount.h | 3 ++- 3 files changed, 8 insertions(+), 2 deletions(-) diff --git a/src/libtomahawk/accounts/AccountDelegate.cpp b/src/libtomahawk/accounts/AccountDelegate.cpp index b8816c989..ac64bd964 100644 --- a/src/libtomahawk/accounts/AccountDelegate.cpp +++ b/src/libtomahawk/accounts/AccountDelegate.cpp @@ -171,7 +171,7 @@ AccountDelegate::paint ( QPainter* painter, const QStyleOptionViewItem& option, QPixmap p = index.data( Qt::DecorationRole ).value< QPixmap >(); QRect pixmapRect( leftEdge + PADDING, center - ICONSIZE/2, ICONSIZE, ICONSIZE ); if ( p.isNull() ) // default image... TODO - p = TomahawkUtils::defaultPixmap( TomahawkUtils::SipPluginOnline, TomahawkUtils::Original, pixmapRect.size() ); + p = TomahawkUtils::defaultPixmap( TomahawkUtils::DefaultResolver, TomahawkUtils::Original, pixmapRect.size() ); else p = p.scaled( pixmapRect.size(), Qt::KeepAspectRatio, Qt::SmoothTransformation ); diff --git a/src/libtomahawk/accounts/ResolverAccount.cpp b/src/libtomahawk/accounts/ResolverAccount.cpp index d759335ca..26b38eea3 100644 --- a/src/libtomahawk/accounts/ResolverAccount.cpp +++ b/src/libtomahawk/accounts/ResolverAccount.cpp @@ -232,6 +232,11 @@ ResolverAccount::resolverChanged() emit connectionStateChanged( connectionState() ); } +QPixmap +ResolverAccount::icon() const +{ + return m_resolver.data()->icon(); +} /// AtticaResolverAccount diff --git a/src/libtomahawk/accounts/ResolverAccount.h b/src/libtomahawk/accounts/ResolverAccount.h index e5b182497..e977931f5 100644 --- a/src/libtomahawk/accounts/ResolverAccount.h +++ b/src/libtomahawk/accounts/ResolverAccount.h @@ -77,8 +77,9 @@ public: QString path() const; + virtual QPixmap icon() const; + // Not relevant - virtual QPixmap icon() const { return QPixmap(); } virtual SipPlugin* sipPlugin() { return 0; } virtual Tomahawk::InfoSystem::InfoPluginPtr infoPlugin() { return Tomahawk::InfoSystem::InfoPluginPtr(); } virtual QWidget* aclWidget() { return 0; } From 0b29b6a444b301d9768df498dacd494f5d3cfc80 Mon Sep 17 00:00:00 2001 From: Christian Muehlhaeuser Date: Wed, 2 Jan 2013 14:13:20 +0100 Subject: [PATCH 7/8] * We now use 4.8.4 on OSX. --- admin/mac/macdeploy.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/admin/mac/macdeploy.py b/admin/mac/macdeploy.py index 888b8b8ca..7f425f1ca 100755 --- a/admin/mac/macdeploy.py +++ b/admin/mac/macdeploy.py @@ -217,7 +217,7 @@ TOMAHAWK_PLUGINS = [ ] QT_PLUGINS_SEARCH_PATH=[ - '/usr/local/Cellar/qt/4.8.2/plugins', + '/usr/local/Cellar/qt/4.8.4/plugins', ] From 5de9f2f7bda83e64b2199c1a1f78567a8e2670cc Mon Sep 17 00:00:00 2001 From: Christian Muehlhaeuser Date: Thu, 3 Jan 2013 05:54:47 +0100 Subject: [PATCH 8/8] * Make artist name in PlayableCover clickable. --- src/libtomahawk/widgets/PlayableCover.cpp | 74 +++++++++++++++++++++-- src/libtomahawk/widgets/PlayableCover.h | 6 ++ 2 files changed, 74 insertions(+), 6 deletions(-) diff --git a/src/libtomahawk/widgets/PlayableCover.cpp b/src/libtomahawk/widgets/PlayableCover.cpp index 74eca96f3..bcd095df1 100644 --- a/src/libtomahawk/widgets/PlayableCover.cpp +++ b/src/libtomahawk/widgets/PlayableCover.cpp @@ -18,7 +18,9 @@ #include "PlayableCover.h" +#include "Artist.h" #include "Album.h" +#include "ViewManager.h" #include "audio/AudioEngine.h" #include "widgets/ImageButton.h" #include "utils/TomahawkUtilsGui.h" @@ -77,6 +79,56 @@ PlayableCover::resizeEvent( QResizeEvent* event ) } +void +PlayableCover::mouseMoveEvent( QMouseEvent* event ) +{ + QLabel::mouseMoveEvent( event ); + + foreach ( const QRect& rect, m_itemRects ) + { + if ( rect.contains( event->pos() ) ) + { + if ( m_hoveredRect != rect ) + { + setCursor( Qt::PointingHandCursor ); + m_hoveredRect = rect; + repaint(); + } + return; + } + } + + if ( !m_hoveredRect.isNull() ) + { + setCursor( Qt::ArrowCursor ); + m_hoveredRect = QRect(); + repaint(); + } +} + + +void +PlayableCover::mouseReleaseEvent( QMouseEvent* event ) +{ + QLabel::mouseReleaseEvent( event ); + + foreach ( const QRect& rect, m_itemRects ) + { + if ( rect.contains( event->pos() ) ) + { + if ( m_artist ) + ViewManager::instance()->show( m_artist ); + else if ( m_album ) + ViewManager::instance()->show( m_album->artist() ); + else if ( m_query ) + ViewManager::instance()->show( Tomahawk::Artist::get( m_query->artist() ) ); + + return; + } + } +} + + void PlayableCover::setPixmap( const QPixmap& pixmap ) { @@ -87,6 +139,8 @@ PlayableCover::setPixmap( const QPixmap& pixmap ) void PlayableCover::paintEvent( QPaintEvent* event ) { + Q_UNUSED( event ); + QPainter painter( this ); painter.setRenderHint( QPainter::Antialiasing ); painter.drawPixmap( 0, 0, pixmap() ); @@ -98,6 +152,7 @@ PlayableCover::paintEvent( QPaintEvent* event ) QPixmap buffer( r.size() ); buffer.fill( Qt::transparent ); QPainter bufpainter( &buffer ); + bufpainter.setRenderHint( QPainter::Antialiasing ); QTextOption to; to.setWrapMode( QTextOption::NoWrap ); @@ -181,18 +236,25 @@ PlayableCover::paintEvent( QPaintEvent* event ) bufpainter.drawText( textRect, text, to ); bufpainter.setFont( font ); - // If the user is hovering over an artist rect, draw a background so she knows it's clickable + QRect r = textRect; r.setTop( r.bottom() - bufpainter.fontMetrics().height() ); r.adjust( 4, 0, -4, -1 ); -/* if ( m_hoveringOver == index ) + + text = bufpainter.fontMetrics().elidedText( bottom, Qt::ElideRight, textRect.width() - 16 ); + int textWidth = bufpainter.fontMetrics().width( text ); + r.adjust( ( r.width() - textWidth ) / 2 - 6, 0, - ( ( r.width() - textWidth ) / 2 - 6 ), 0 ); + + m_itemRects.clear(); + m_itemRects << r; + + if ( m_hoveredRect == r ) { - TomahawkUtils::drawQueryBackground( bufpainter, opt.palette, r, 1.1 ); - bufpainter.setPen( opt.palette.color( QPalette::HighlightedText ) ); - }*/ + TomahawkUtils::drawQueryBackground( &bufpainter, palette(), r, 1.1 ); + bufpainter.setPen( Qt::white ); + } to.setAlignment( Qt::AlignHCenter | Qt::AlignBottom ); - text = bufpainter.fontMetrics().elidedText( bottom, Qt::ElideRight, textRect.width() - 16 ); bufpainter.drawText( textRect.adjusted( 5, -1, -5, -1 ), text, to ); } diff --git a/src/libtomahawk/widgets/PlayableCover.h b/src/libtomahawk/widgets/PlayableCover.h index 9179a0f0e..f96f1cba2 100644 --- a/src/libtomahawk/widgets/PlayableCover.h +++ b/src/libtomahawk/widgets/PlayableCover.h @@ -56,6 +56,9 @@ protected: virtual void resizeEvent( QResizeEvent* event ); virtual void paintEvent( QPaintEvent* event ); + virtual void mouseMoveEvent( QMouseEvent* event ); + virtual void mouseReleaseEvent( QMouseEvent* event ); + void leaveEvent( QEvent* event ); void enterEvent( QEvent* event ); @@ -70,6 +73,9 @@ private: Tomahawk::album_ptr m_album; Tomahawk::query_ptr m_query; + QList< QRect > m_itemRects; + QRect m_hoveredRect; + bool m_showText; };