Hello community,
here is the log from the commit of package leechcraft for openSUSE:Factory checked in at 2013-09-12 17:46:30
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/leechcraft (Old)
and /work/SRC/openSUSE:Factory/.leechcraft.new (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "leechcraft"
Changes:
--------
--- /work/SRC/openSUSE:Factory/leechcraft/leechcraft-doc.changes 2013-07-16 15:34:55.000000000 +0200
+++ /work/SRC/openSUSE:Factory/.leechcraft.new/leechcraft-doc.changes 2013-09-12 17:46:31.000000000 +0200
@@ -1,0 +2,5 @@
+Wed Sep 11 20:50:53 UTC 2013 - dap.darkness@gmail.com
+
+- 0.6.0 bugfix release.
+
+-------------------------------------------------------------------
--- /work/SRC/openSUSE:Factory/leechcraft/leechcraft.changes 2013-07-16 15:34:55.000000000 +0200
+++ /work/SRC/openSUSE:Factory/.leechcraft.new/leechcraft.changes 2013-09-12 17:46:31.000000000 +0200
@@ -1,0 +2,22 @@
+Wed Sep 11 20:51:25 UTC 2013 - dap.darkness@gmail.com
+
+- 0.6.0 release fixes lots of bugs in
+ * Core, Util & XSD,
+ * AdvancedNotifications,
+ * Aggregator,
+ * Azoth, Azoth AdiumStyles, Azoth Autoidler,
+ Azoth p100q, Azoth Vader & Azoth Xoox,
+ * Dolozhee (set proper stretch on widgets),
+ * LastFMScrobble (fixed leaking),
+ * Launchy (use own settings instead of messing with LMP),
+ * Liznoo (try autostarting UPower if it's unavailable),
+ * LMP & LMP Graffiti,
+ * Poshuku & Poshuku CleanWeb,
+ * Summary (fixed leaking context menu actions).
+- Spec fixing up:
+ * Obsoletes nacheku because of ustream request.
+ * DSTRICT_LICENSING=True to suggest IM clients icons.
+ * DENABLE_MEDIACALLS=True to enable Jingle support.
+ * DENABLE_BITTORRENT_GEOIP=True to enable countries flags.
+
+-------------------------------------------------------------------
Old:
----
leechcraft-0.5.99.tar.xz
New:
----
leechcraft-0.6.0.tar.xz
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Other differences:
------------------
++++++ leechcraft-doc.spec ++++++
--- /var/tmp/diff_new_pack.GSlz9T/_old 2013-09-12 17:46:32.000000000 +0200
+++ /var/tmp/diff_new_pack.GSlz9T/_new 2013-09-12 17:46:32.000000000 +0200
@@ -17,13 +17,13 @@
Name: leechcraft-doc
-Version: 0.5.99
+Version: 0.6.0
Release: 0
Summary: Modular Internet Client Documentation
License: BSL-1.0
Group: Development/Libraries/Other
Url: http://leechcraft.org
-Source0: http://netcologne.dl.sourceforge.net/project/leechcraft/LeechCraft/0.6.0/leechcraft-%{version}.tar.xz
+Source0: http://dist.leechcraft.org/LeechCraft/%{version}/leechcraft-%{version}.tar.xz
%if 0%{?suse_version} > 1210
BuildRequires: doxygen >= 1.8.3.1
++++++ leechcraft.spec ++++++
--- /var/tmp/diff_new_pack.GSlz9T/_old 2013-09-12 17:46:32.000000000 +0200
+++ /var/tmp/diff_new_pack.GSlz9T/_new 2013-09-12 17:46:32.000000000 +0200
@@ -22,13 +22,13 @@
%define azoth_dir %{_datadir}/%{name}/azoth
Name: leechcraft
-Version: 0.5.99
+Version: 0.6.0
Release: 0
Summary: Modular Internet Client
License: BSL-1.0
Group: Productivity/Networking/Other
Url: http://leechcraft.org
-Source0: http://netcologne.dl.sourceforge.net/project/leechcraft/LeechCraft/0.6.0/leechcraft-%{version}.tar.xz
+Source0: http://dist.leechcraft.org/LeechCraft/%{version}/leechcraft-%{version}.tar.xz
%if 0%{?suse_version} > 1230
BuildRequires: boost-devel >= 1.50
@@ -86,6 +86,7 @@
Obsoletes: %{name}-eiskaltdcpp
Obsoletes: %{name}-iconset-oxygen
Obsoletes: %{name}-iconset-tango
+Obsoletes: %{name}-nacheku
Obsoletes: %{name}-tabpp
%description
@@ -1170,19 +1171,6 @@
This package provides a MusicBrainz.org client plugin for LeechCraft.
-%package nacheku
-Summary: LeechCraft Link watcher Module
-License: BSL-1.0
-Group: Productivity/Networking/Other
-Requires: %{name} = %{version}
-
-%description nacheku
-This package provides a Nacheku plugin for LeechCraft.
-
-It allows to watch clipboard and directory in order to
-get links and download files.
-
-
%package netstoremanager
Summary: LeechCraft Network file storages Module
License: BSL-1.0
@@ -1717,6 +1705,7 @@
-DCMAKE_CXX_FLAGS="%{optflags} -Doverride=" \
-DCMAKE_INSTALL_PREFIX=%{_prefix} \
-DCMAKE_BUILD_TYPE=RelWithDebInfo \
+ -DSTRICT_LICENSING=True \
-DENABLE_ADVANCEDNOTIFICATIONS=True \
-DENABLE_AUSCRIE=True \
-DENABLE_AZOTH=True \
@@ -1732,8 +1721,8 @@
-DENABLE_KNOWHOW=True \
-DENABLE_LACKMAN=True \
-DENABLE_LADS=False \
- -DENABLE_MEDIACALLS=False \
- -DENABLE_NACHEKU=True \
+ -DENABLE_MEDIACALLS=True \
+ -DENABLE_NACHEKU=False \
-DENABLE_NEWLIFE=True \
-DENABLE_PINTAB=True \
-DENABLE_POPISHU=True \
@@ -1776,6 +1765,7 @@
-DENABLE_SHAITAN=True \
-DENABLE_TABSESSMANAGER=True \
-DENABLE_TORRENT=True \
+ -DENABLE_BITTORRENT_GEOIP=True \
-DENABLE_TPI=True \
-DENABLE_VROOBY=True \
%if 0%{?suse_version} > 1230
@@ -2255,11 +2245,6 @@
%defattr(-,root,root)
%{_libdir}/%{name}/plugins/lib%{name}_musiczombie.so
-%files nacheku
-%defattr(-,root,root)
-%{_libdir}/%{name}/plugins/lib%{name}_nacheku.so
-%{_datadir}/%{name}/settings/nachekusettings.xml
-
%files netstoremanager
%defattr(-,root,root)
%{plugin_dir}/*%{name}_netstoremanager.so
++++++ leechcraft-0.5.99.tar.xz -> leechcraft-0.6.0.tar.xz ++++++
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/leechcraft-0.5.99/CHANGELOG new/leechcraft-0.6.0/CHANGELOG
--- old/leechcraft-0.5.99/CHANGELOG 2013-07-13 11:04:11.000000000 +0200
+++ new/leechcraft-0.6.0/CHANGELOG 2013-09-11 20:32:54.000000000 +0200
@@ -1,6 +1,53 @@
This file lists only more or less major changes, refer to `git log` for
the rest.
+!!! 0.6.0
+* Core: fixed showing toolbar after last tab is closed.
+* Core: fixed reapplying color theme, explicitly setting palette on all
+ widgets.
+* Core: check if there is a tab before activating it on DnD.
+* Core: set default locale according to language settings.
+* Util: fixed a possible use-after-free error in ResourceLoader on large
+ pixmaps.
+* XSD: don't count an item with just set datasource as changed.
+* AN: fixed three bugs that led to rules being considered modified when
+ they weren't.
+* Aggregator: feed URL string can already be encoded, check for it.
+* Aggregator: fixed tooltip cleanup code, removing tags like font, span,
+ div, p, h{1,2,3,4,5,6} tags.
+* Aggregator: don't notify about zero something.
+* Azoth: fixed a rare XML parsing issue.
+* Azoth: cancel roster search on Esc or as soon as search text is empty.
+* Azoth AdiumStyles: don't segfault on unknown entries.
+* Azoth Autoidler: handle only Online and Free to Chat statuses.
+* Azoth p100q: fixed bookmarks label in settings.
+* Azoth Vader: fixed compatibility with crappy clients not knowing about
+ BOM.
+* Azoth Vader: fixed microblog status encoding.
+* Azoth Xoox: fixed restoring file logging settings.
+* Azoth Xoox: fixed cancelling connecting to the server if there is a
+ network error.
+* Azoth Xoox: added *.jpeg and *.bmp masks to avatar filter.
+* Dolozhee: set proper stretch on widgets.
+* LastFMScrobble: fixed leaking attend markers.
+* LastFMScrobble: fixed leaking recent releases.
+* Launchy: use own settings instead of messing with LMP.
+* Liznoo: try autostarting UPower if it's unavailable.
+* LMP: properly handle playlists on DnD.
+* LMP: similarity label now is always under artist name.
+* LMP: consider arbitrary-named album art if it's a single image.
+* LMP: album-art autofetching now made optional.
+* LMP: format datetimes according to locale settings.
+* LMP Graffiti: fixed CUE splitting.
+* LMP Graffiti: fixed linking issues with primary LMP library.
+* LMP Graffiti: fixed garbage in plugin icon.
+* Poshuku: set target="_blank" on links in widgets requested by other
+ plugins.
+* Poshuku: fixed freezing on garbage collection with large history
+ databases.
+* Poshuku CW: don't complain about unsupported filters.
+* Summary: fixed leaking context menu actions.
+
!!! 0.5.99
* AN: fixed a typo in user string.
* AN: updated English and Russian translations.
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/leechcraft-0.5.99/src/CMakeLists.txt new/leechcraft-0.6.0/src/CMakeLists.txt
--- old/leechcraft-0.5.99/src/CMakeLists.txt 2013-07-13 11:04:11.000000000 +0200
+++ new/leechcraft-0.6.0/src/CMakeLists.txt 2013-09-11 20:32:54.000000000 +0200
@@ -34,13 +34,13 @@
SET (CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wall -Wextra")
ENDIF (EXTRA_WARNINGS)
- IF (("${CMAKE_CXX_COMPILER_ID}" STREQUAL "Clang") AND ENABLE_CLANG_QUIRKS)
+ IF (("${CMAKE_CXX_COMPILER_ID}" STREQUAL "Clang") OR ENABLE_CLANG_QUIRKS)
MESSAGE (STATUS "Enable Clang-specific quirks for Qt...")
SET (CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -DQ_COMPILER_RVALUE_REFS -DQ_COMPILER_DECLTYPE")
SET (CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -DQ_COMPILER_VARIADIC_TEMPLATES -DQ_COMPILER_AUTO_TYPE -DQ_COMPILER_EXTERN_TEMPLATES -DQ_COMPILER_DEFAULT_DELETE_MEMBERS -DQ_COMPILER_CLASS_ENUM -DQ_COMPILER_INITIALIZER_LISTS")
SET (CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -DQ_COMPILER_LAMBDA -DQ_COMPILER_UNICODE_STRINGS")
- SET (CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -DQ_COMPILER_CONSTEXPR")
- ENDIF (("${CMAKE_CXX_COMPILER_ID}" STREQUAL "Clang") AND ENABLE_CLANG_QUIRKS)
+ SET (CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -DQ_COMPILER_CONSTEXPR -DQ_COMPILER_AUTO_FUNCTION")
+ ENDIF (("${CMAKE_CXX_COMPILER_ID}" STREQUAL "Clang") OR ENABLE_CLANG_QUIRKS)
ENDIF (UNIX OR (WIN32 AND MINGW))
OPTION (USE_QT5 "Enable Qt5 build" OFF)
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/leechcraft-0.5.99/src/core/application.cpp new/leechcraft-0.6.0/src/core/application.cpp
--- old/leechcraft-0.5.99/src/core/application.cpp 2013-07-13 11:04:11.000000000 +0200
+++ new/leechcraft-0.6.0/src/core/application.cpp 2013-09-11 20:32:54.000000000 +0200
@@ -200,7 +200,7 @@
this,
SLOT (handleQuit ()));
- Splash_ = new QSplashScreen (QPixmap (":/resources/images/macaroni.jpg"), Qt::SplashScreen);
+ Splash_ = new QSplashScreen (QPixmap (":/resources/images/splash.svg"), Qt::SplashScreen);
Splash_->show ();
Splash_->setUpdatesEnabled (true);
Splash_->showMessage (tr ("Initializing LeechCraft..."), Qt::AlignLeft | Qt::AlignBottom, QColor ("#FF3000"));
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/leechcraft-0.5.99/src/core/colorthemeengine.cpp new/leechcraft-0.6.0/src/core/colorthemeengine.cpp
--- old/leechcraft-0.5.99/src/core/colorthemeengine.cpp 2013-07-13 11:04:11.000000000 +0200
+++ new/leechcraft-0.6.0/src/core/colorthemeengine.cpp 2013-09-11 20:32:54.000000000 +0200
@@ -28,15 +28,18 @@
**********************************************************************/
#include "colorthemeengine.h"
-#include
#include <algorithm>
#include <map>
#include <QFile>
#include <QStringList>
#include <QApplication>
+#include <QMainWindow>
#include <QDir>
#include <QtDebug>
#include <QSettings>
+#include
+#include "core.h"
+#include "rootwindowsmanager.h"
namespace LeechCraft
{
@@ -170,6 +173,7 @@
return;
}
+ auto palette = StartupPalette_;
if (QFile::exists (themePath + "/colors.rc"))
{
QSettings settings (themePath + "/colors.rc", QSettings::IniFormat);
@@ -181,11 +185,18 @@
return;
}
- auto palette = UpdatePalette (StartupPalette_, settings);
- QApplication::setPalette (palette);
+ palette = UpdatePalette (StartupPalette_, settings);
+ }
+ QApplication::setPalette (palette);
+ const auto rootWinMgr = Core::Instance ().GetRootWindowsManager ();
+ for (int i = 0; i < rootWinMgr->GetWindowsCount (); ++i)
+ {
+ const auto win = rootWinMgr->GetMainWindow (i);
+ win->setPalette (palette);
+
+ for (auto w : win->findChildren ())
+ w->setPalette (palette);
}
- else
- QApplication::setPalette (StartupPalette_);
QSettings qmlSettings (themePath + "/qml.rc", QSettings::IniFormat);
FillQML (qmlSettings);
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/leechcraft-0.5.99/src/core/coreinstanceobject.cpp new/leechcraft-0.6.0/src/core/coreinstanceobject.cpp
--- old/leechcraft-0.5.99/src/core/coreinstanceobject.cpp 2013-07-13 11:04:11.000000000 +0200
+++ new/leechcraft-0.6.0/src/core/coreinstanceobject.cpp 2013-09-11 20:32:54.000000000 +0200
@@ -180,6 +180,10 @@
XmlSettingsDialog_->SetCustomWidget ("ShortcutManager", ShortcutManager_);
XmlSettingsDialog_->SetCustomWidget ("AcceptLanguages", new AcceptLangWidget);
+
+ const auto& lang = XmlSettingsManager::Instance ()->property ("Language").toString ();
+ if (lang != "system")
+ QLocale::setDefault ({ lang });
}
void CoreInstanceObject::SecondInit ()
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/leechcraft-0.5.99/src/core/mainresources.qrc new/leechcraft-0.6.0/src/core/mainresources.qrc
--- old/leechcraft-0.5.99/src/core/mainresources.qrc 2013-07-13 11:04:11.000000000 +0200
+++ new/leechcraft-0.6.0/src/core/mainresources.qrc 2013-09-11 20:32:54.000000000 +0200
@@ -3,6 +3,5 @@
<file>resources/images/leechcraft.svg</file>
<file>resources/images/defaultpluginicon.svg</file>
<file>resources/images/splash.svg</file>
- <file>resources/images/macaroni.jpg</file>
</qresource>
</RCC>
Files old/leechcraft-0.5.99/src/core/resources/images/funsplash.jpg and new/leechcraft-0.6.0/src/core/resources/images/funsplash.jpg differ
Files old/leechcraft-0.5.99/src/core/resources/images/macaroni.jpg and new/leechcraft-0.6.0/src/core/resources/images/macaroni.jpg differ
Files old/leechcraft-0.5.99/src/core/resources/images/splashscreen.png and new/leechcraft-0.6.0/src/core/resources/images/splashscreen.png differ
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/leechcraft-0.5.99/src/core/separatetabbar.cpp new/leechcraft-0.6.0/src/core/separatetabbar.cpp
--- old/leechcraft-0.5.99/src/core/separatetabbar.cpp 2013-07-13 11:04:11.000000000 +0200
+++ new/leechcraft-0.6.0/src/core/separatetabbar.cpp 2013-09-11 20:32:54.000000000 +0200
@@ -241,7 +241,7 @@
if (formats.contains ("x-leechcraft/tab-drag-action") &&
data->data ("x-leechcraft/tab-drag-action") == "reordering")
event->acceptProposedAction ();
- else
+ else if (tabIdx >= 0)
TabWidget_->setCurrentIndex (tabIdx);
if (auto idt = qobject_cast (TabWidget_->Widget (tabIdx)))
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/leechcraft-0.5.99/src/core/toolbarguard.cpp new/leechcraft-0.6.0/src/core/toolbarguard.cpp
--- old/leechcraft-0.5.99/src/core/toolbarguard.cpp 2013-07-13 11:04:11.000000000 +0200
+++ new/leechcraft-0.6.0/src/core/toolbarguard.cpp 2013-09-11 20:32:54.000000000 +0200
@@ -50,13 +50,13 @@
void ToolbarGuard::AddToolbar (QToolBar *newToolbar)
{
- if (Toolbar_ == newToolbar)
- return;
-
- if (Toolbar_)
- Window_->GetTabWidget ()->RemoveWidgetFromSeparateTabWidget (Toolbar_);
+ if (Toolbar_ != newToolbar)
+ {
+ if (Toolbar_)
+ Window_->GetTabWidget ()->RemoveWidgetFromSeparateTabWidget (Toolbar_);
- Toolbar_ = newToolbar;
+ Toolbar_ = newToolbar;
+ }
if (Toolbar_)
{
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/leechcraft-0.5.99/src/plugins/advancednotifications/notificationrule.cpp new/leechcraft-0.6.0/src/plugins/advancednotifications/notificationrule.cpp
--- old/leechcraft-0.5.99/src/plugins/advancednotifications/notificationrule.cpp 2013-07-13 11:04:11.000000000 +0200
+++ new/leechcraft-0.6.0/src/plugins/advancednotifications/notificationrule.cpp 2013-09-11 20:32:54.000000000 +0200
@@ -120,9 +120,9 @@
Category_ = cat;
}
- QStringList NotificationRule::GetTypes () const
+ QSet<QString> NotificationRule::GetTypes () const
{
- return Types_;
+ return Types_.toSet ();
}
void NotificationRule::SetTypes (const QStringList& types)
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/leechcraft-0.5.99/src/plugins/advancednotifications/notificationrule.h new/leechcraft-0.6.0/src/plugins/advancednotifications/notificationrule.h
--- old/leechcraft-0.5.99/src/plugins/advancednotifications/notificationrule.h 2013-07-13 11:04:11.000000000 +0200
+++ new/leechcraft-0.6.0/src/plugins/advancednotifications/notificationrule.h 2013-09-11 20:32:54.000000000 +0200
@@ -103,7 +103,7 @@
QString GetCategory () const;
void SetCategory (const QString&);
- QStringList GetTypes () const;
+ QSet<QString> GetTypes () const;
void SetTypes (const QStringList&);
NotificationMethods GetMethods () const;
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/leechcraft-0.5.99/src/plugins/advancednotifications/notificationruleswidget.cpp new/leechcraft-0.6.0/src/plugins/advancednotifications/notificationruleswidget.cpp
--- old/leechcraft-0.5.99/src/plugins/advancednotifications/notificationruleswidget.cpp 2013-07-13 11:04:11.000000000 +0200
+++ new/leechcraft-0.6.0/src/plugins/advancednotifications/notificationruleswidget.cpp 2013-09-11 20:32:54.000000000 +0200
@@ -139,7 +139,7 @@
const int audioIdx = Ui_.AudioFile_->currentIndex ();
const QString& audioFile = audioIdx >= 0 ?
- Ui_.AudioFile_->itemData (audioIdx).toString () :
+ Ui_.AudioFile_->itemText (audioIdx) :
QString ();
rule.SetAudioParams (AudioParams (audioFile));
@@ -210,7 +210,7 @@
const int catIdx = Ui_.EventCat_->findData (rule.GetCategory ());
Ui_.EventCat_->setCurrentIndex (std::max (catIdx, 0));
- const QStringList& types = rule.GetTypes ();
+ const auto& types = rule.GetTypes ();
for (int i = 0; i < Ui_.EventTypes_->topLevelItemCount (); ++i)
{
QTreeWidgetItem *item = Ui_.EventTypes_->topLevelItem (i);
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/leechcraft-0.5.99/src/plugins/aggregator/core.cpp new/leechcraft-0.6.0/src/plugins/aggregator/core.cpp
--- old/leechcraft-0.5.99/src/plugins/aggregator/core.cpp 2013-07-13 11:04:11.000000000 +0200
+++ new/leechcraft-0.6.0/src/plugins/aggregator/core.cpp 2013-09-11 20:32:54.000000000 +0200
@@ -470,9 +470,11 @@
AddFeed (url, Proxy_->GetTagsManager ()->Split (tagString));
}
- void Core::AddFeed (const QString& url, const QStringList& tags,
+ void Core::AddFeed (QString url, const QStringList& tags,
std::shared_ptrFeed::FeedSettings fs)
{
+ const auto& fixedUrl = QUrl::fromUserInput (url);
+ url = fixedUrl.toString ();
if (StorageBackend_->FindFeed (url) != static_cast (-1))
{
ErrorNotification (tr ("Feed addition error"),
@@ -482,7 +484,7 @@
}
QString name = LeechCraft::Util::GetTemporaryName ();
- LeechCraft::Entity e = LeechCraft::Util::MakeEntity (QUrl (url),
+ LeechCraft::Entity e = LeechCraft::Util::MakeEntity (fixedUrl,
name,
LeechCraft::Internal |
LeechCraft::DoNotNotifyUser |
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/leechcraft-0.5.99/src/plugins/aggregator/core.h new/leechcraft-0.6.0/src/plugins/aggregator/core.h
--- old/leechcraft-0.5.99/src/plugins/aggregator/core.h 2013-07-13 11:04:11.000000000 +0200
+++ new/leechcraft-0.6.0/src/plugins/aggregator/core.h 2013-09-11 20:32:54.000000000 +0200
@@ -164,7 +164,7 @@
bool ReinitStorage ();
void AddFeed (const QString&, const QString&);
- void AddFeed (const QString&, const QStringList&,
+ void AddFeed (QString, const QStringList&,
FeedSettings_ptr = FeedSettings_ptr ());
void RemoveFeed (const QModelIndex&);
void RemoveChannel (const QModelIndex&);
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/leechcraft-0.5.99/src/plugins/aggregator/dbupdatethreadworker.cpp new/leechcraft-0.6.0/src/plugins/aggregator/dbupdatethreadworker.cpp
--- old/leechcraft-0.5.99/src/plugins/aggregator/dbupdatethreadworker.cpp 2013-07-13 11:04:11.000000000 +0200
+++ new/leechcraft-0.6.0/src/plugins/aggregator/dbupdatethreadworker.cpp 2013-09-11 20:32:54.000000000 +0200
@@ -269,9 +269,14 @@
if (shouldShow)
{
- QString str = tr ("Updated channel \"%1\" (%2, %3)").arg (channel->Title_)
- .arg (tr ("%n new item(s)", "Channel update", newItems))
- .arg (tr ("%n updated item(s)", "Channel update", updatedItems));
+ QStringList substrs;
+ if (newItems)
+ substrs << tr ("%n new item(s)", "Channel update", newItems);
+ if (updatedItems)
+ substrs << tr ("%n updated item(s)", "Channel update", updatedItems);
+ const auto& str = tr ("Updated channel \"%1\" (%2).")
+ .arg (channel->Title_)
+ .arg (substrs.join (", "));
emit gotEntity (Util::MakeNotification ("Aggregator", str, PInfo_));
}
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/leechcraft-0.5.99/src/plugins/aggregator/itemslistmodel.cpp new/leechcraft-0.6.0/src/plugins/aggregator/itemslistmodel.cpp
--- old/leechcraft-0.5.99/src/plugins/aggregator/itemslistmodel.cpp 2013-07-13 11:04:11.000000000 +0200
+++ new/leechcraft-0.6.0/src/plugins/aggregator/itemslistmodel.cpp 2013-09-11 20:32:54.000000000 +0200
@@ -210,7 +210,7 @@
void RemoveTag (const QString& name, QString& str)
{
int startPos = 0;
- while ((startPos = str.indexOf ("<" + name, startPos, Qt::CaseInsensitive)) > 0)
+ while ((startPos = str.indexOf ("<" + name, startPos, Qt::CaseInsensitive)) >= 0)
{
const int end = str.indexOf ('>', startPos);
if (end < 0)
@@ -219,6 +219,12 @@
str.remove (startPos, end - startPos + 1);
}
}
+
+ void RemovePair (const QString& name, QString& str)
+ {
+ RemoveTag (name, str);
+ RemoveTag ('/' + name, str);
+ }
}
QVariant ItemsListModel::data (const QModelIndex& index, int role) const
@@ -324,6 +330,12 @@
const int maxDescriptionSize = 1000;
auto descr = item->Description_;
RemoveTag ("img", descr);
+ RemovePair ("font", descr);
+ RemovePair ("span", descr);
+ RemovePair ("p", descr);
+ RemovePair ("div", descr);
+ for (auto i : { 1, 2, 3, 4, 5, 6 })
+ RemovePair ("h" + QString::number (i), descr);
result += descr.left (maxDescriptionSize);
if (descr.size () > maxDescriptionSize)
result += "...";
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/leechcraft-0.5.99/src/plugins/azoth/keyboardrosterfixer.cpp new/leechcraft-0.6.0/src/plugins/azoth/keyboardrosterfixer.cpp
--- old/leechcraft-0.5.99/src/plugins/azoth/keyboardrosterfixer.cpp 2013-07-13 11:04:11.000000000 +0200
+++ new/leechcraft-0.6.0/src/plugins/azoth/keyboardrosterfixer.cpp 2013-09-11 20:32:54.000000000 +0200
@@ -31,16 +31,19 @@
#include <QKeyEvent>
#include <QApplication>
#include <QTreeView>
+#include <QLineEdit>
namespace LeechCraft
{
namespace Azoth
{
- KeyboardRosterFixer::KeyboardRosterFixer (QTreeView *view, QObject *parent)
+ KeyboardRosterFixer::KeyboardRosterFixer (QLineEdit *edit, QTreeView *view, QObject *parent)
: QObject (parent)
+ , Edit_ (edit)
, View_ (view)
, IsSearching_ (false)
{
+ Edit_->installEventFilter (this);
}
bool KeyboardRosterFixer::eventFilter (QObject*, QEvent *e)
@@ -49,6 +52,10 @@
e->type () != QEvent::KeyRelease)
return false;
+ if (IsSearching_ &&
+ Edit_->text ().isEmpty ())
+ IsSearching_ = false;
+
QKeyEvent *ke = static_cast (e);
if (!IsSearching_)
{
@@ -72,6 +79,7 @@
case Qt::Key_PageUp:
case Qt::Key_Enter:
case Qt::Key_Return:
+ case Qt::Key_Escape:
IsSearching_ = false;
qApp->sendEvent (View_, e);
return true;
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/leechcraft-0.5.99/src/plugins/azoth/keyboardrosterfixer.h new/leechcraft-0.6.0/src/plugins/azoth/keyboardrosterfixer.h
--- old/leechcraft-0.5.99/src/plugins/azoth/keyboardrosterfixer.h 2013-07-13 11:04:11.000000000 +0200
+++ new/leechcraft-0.6.0/src/plugins/azoth/keyboardrosterfixer.h 2013-09-11 20:32:54.000000000 +0200
@@ -32,6 +32,7 @@
#include <QObject>
class QTreeView;
+class QLineEdit;
namespace LeechCraft
{
@@ -39,10 +40,11 @@
{
class KeyboardRosterFixer : public QObject
{
- QTreeView *View_;
+ QLineEdit * const Edit_;
+ QTreeView * const View_;
bool IsSearching_;
public:
- KeyboardRosterFixer (QTreeView*, QObject* = 0);
+ KeyboardRosterFixer (QLineEdit*, QTreeView*, QObject* = 0);
protected:
bool eventFilter (QObject*, QEvent*);
};
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/leechcraft-0.5.99/src/plugins/azoth/mainwidget.cpp new/leechcraft-0.6.0/src/plugins/azoth/mainwidget.cpp
--- old/leechcraft-0.5.99/src/plugins/azoth/mainwidget.cpp 2013-07-13 11:04:11.000000000 +0200
+++ new/leechcraft-0.6.0/src/plugins/azoth/mainwidget.cpp 2013-09-11 20:32:54.000000000 +0200
@@ -99,7 +99,7 @@
Ui_.FilterLine_->setPlaceholderText (tr ("Search..."));
Ui_.CLTree_->setFocusProxy (Ui_.FilterLine_);
- Ui_.FilterLine_->installEventFilter (new KeyboardRosterFixer (Ui_.CLTree_, this));
+ new KeyboardRosterFixer (Ui_.FilterLine_, Ui_.CLTree_, this);
Ui_.CLTree_->setItemDelegate (new ContactListDelegate (Ui_.CLTree_));
ProxyModel_->setSourceModel (Core::Instance ().GetCLModel ());
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/leechcraft-0.5.99/src/plugins/azoth/plugins/adiumstyles/adiumstylesource.cpp new/leechcraft-0.6.0/src/plugins/azoth/plugins/adiumstyles/adiumstylesource.cpp
--- old/leechcraft-0.5.99/src/plugins/azoth/plugins/adiumstyles/adiumstylesource.cpp 2013-07-13 11:04:11.000000000 +0200
+++ new/leechcraft-0.6.0/src/plugins/azoth/plugins/adiumstyles/adiumstylesource.cpp 2013-09-11 20:32:54.000000000 +0200
@@ -498,6 +498,7 @@
<< msg->GetBody ()
<< msg->OtherPart ()
<< msg->ParentCLEntry ();
+ return templ;
}
IAccount *acc = other ?
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/leechcraft-0.5.99/src/plugins/azoth/plugins/autoidler/autoidler.cpp new/leechcraft-0.6.0/src/plugins/azoth/plugins/autoidler/autoidler.cpp
--- old/leechcraft-0.5.99/src/plugins/azoth/plugins/autoidler/autoidler.cpp 2013-07-13 11:04:11.000000000 +0200
+++ new/leechcraft-0.6.0/src/plugins/azoth/plugins/autoidler/autoidler.cpp 2013-09-11 20:32:54.000000000 +0200
@@ -157,7 +157,9 @@
auto acc = qobject_cast (accObj);
const auto& accState = acc->GetState ();
- if (accState.State_ == State::SOffline)
+ if (!OldStatuses_.contains (accObj) &&
+ accState.State_ != State::SOnline &&
+ accState.State_ != State::SChat)
continue;
if (!OldStatuses_.contains (accObj))
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/leechcraft-0.5.99/src/plugins/azoth/plugins/p100q/azothp100qsettings.xml new/leechcraft-0.6.0/src/plugins/azoth/plugins/p100q/azothp100qsettings.xml
--- old/leechcraft-0.5.99/src/plugins/azoth/plugins/p100q/azothp100qsettings.xml 2013-07-13 11:04:11.000000000 +0200
+++ new/leechcraft-0.6.0/src/plugins/azoth/plugins/p100q/azothp100qsettings.xml 2013-09-11 20:32:54.000000000 +0200
@@ -38,7 +38,7 @@
<label value="Recommend this psto" />
</item>
<item type="checkbox" property="AddToBookmarkButton" default="true">
- <label value="Request Comments" />
+ <label value="Add to bookmarks" />
</item>
</groupbox>
</groupbox>
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/leechcraft-0.5.99/src/plugins/azoth/plugins/vader/proto/conversions.cpp new/leechcraft-0.6.0/src/plugins/azoth/plugins/vader/proto/conversions.cpp
--- old/leechcraft-0.5.99/src/plugins/azoth/plugins/vader/proto/conversions.cpp 2013-07-13 11:04:11.000000000 +0200
+++ new/leechcraft-0.6.0/src/plugins/azoth/plugins/vader/proto/conversions.cpp 2013-09-11 20:32:54.000000000 +0200
@@ -47,7 +47,7 @@
QByteArray ToMRIM16 (const QString& string)
{
- return QTextCodec::codecForName ("UTF-16LE")->fromUnicode (string);
+ return QTextCodec::codecForName ("UTF-16LE")->fromUnicode (string).mid (2);
}
QByteArray ToMRIM (const QString& string)
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/leechcraft-0.5.99/src/plugins/azoth/plugins/vader/proto/packetfactory.cpp new/leechcraft-0.6.0/src/plugins/azoth/plugins/vader/proto/packetfactory.cpp
--- old/leechcraft-0.5.99/src/plugins/azoth/plugins/vader/proto/packetfactory.cpp 2013-07-13 11:04:11.000000000 +0200
+++ new/leechcraft-0.6.0/src/plugins/azoth/plugins/vader/proto/packetfactory.cpp 2013-09-11 20:32:54.000000000 +0200
@@ -119,7 +119,7 @@
Packet PacketFactory::Microblog (BlogStatus st, const QString& text)
{
- const QByteArray& data = ToMRIM (static_cast<quint32> (st), text);
+ const QByteArray& data = ToMRIM (static_cast<quint32> (st), ToMRIM16 (text));
return HalfPacket { Header (Packets::MicroblogPost, Seq_++), data };
}
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/leechcraft-0.5.99/src/plugins/azoth/plugins/xoox/clientconnection.cpp new/leechcraft-0.6.0/src/plugins/azoth/plugins/xoox/clientconnection.cpp
--- old/leechcraft-0.5.99/src/plugins/azoth/plugins/xoox/clientconnection.cpp 2013-07-13 11:04:11.000000000 +0200
+++ new/leechcraft-0.6.0/src/plugins/azoth/plugins/xoox/clientconnection.cpp 2013-09-11 20:32:54.000000000 +0200
@@ -855,6 +855,8 @@
logger->setLogFilePath (path);
logger->setMessageTypes (QXmppLogger::AnyMessage);
Client_->setLogger (logger);
+
+ SetSignaledLog (false);
}
void ClientConnection::Split (const QString& jid,
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/leechcraft-0.5.99/src/plugins/azoth/plugins/xoox/clientconnectionerrormgr.cpp new/leechcraft-0.6.0/src/plugins/azoth/plugins/xoox/clientconnectionerrormgr.cpp
--- old/leechcraft-0.5.99/src/plugins/azoth/plugins/xoox/clientconnectionerrormgr.cpp 2013-07-13 11:04:11.000000000 +0200
+++ new/leechcraft-0.6.0/src/plugins/azoth/plugins/xoox/clientconnectionerrormgr.cpp 2013-09-11 20:32:54.000000000 +0200
@@ -181,6 +181,15 @@
void ClientConnectionErrorMgr::handleError (QXmppClient::Error error)
{
+ if (ClientConn_->GetLastState ().State_ == SOffline &&
+ error == QXmppClient::SocketError)
+ {
+ qDebug () << Q_FUNC_INFO
+ << "killing stale error";
+ Client_->disconnectFromServer ();
+ return;
+ }
+
QString str;
switch (error)
{
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/leechcraft-0.5.99/src/plugins/azoth/plugins/xoox/vcarddialog.cpp new/leechcraft-0.6.0/src/plugins/azoth/plugins/xoox/vcarddialog.cpp
--- old/leechcraft-0.5.99/src/plugins/azoth/plugins/xoox/vcarddialog.cpp 2013-07-13 11:04:11.000000000 +0200
+++ new/leechcraft-0.6.0/src/plugins/azoth/plugins/xoox/vcarddialog.cpp 2013-09-11 20:32:54.000000000 +0200
@@ -483,7 +483,7 @@
const QString& fname = QFileDialog::getOpenFileName (this,
tr ("Choose new photo"),
QDir::homePath (),
- tr ("Images (*.png *.jpg *.gif);;All files (*.*)"));
+ tr ("Images (*.png *.jpg *.jpeg *.gif *.bmp);;All files (*.*)"));
if (fname.isEmpty ())
return;
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/leechcraft-0.5.99/src/plugins/azoth/proxyobject.cpp new/leechcraft-0.6.0/src/plugins/azoth/proxyobject.cpp
--- old/leechcraft-0.5.99/src/plugins/azoth/proxyobject.cpp 2013-07-13 11:04:11.000000000 +0200
+++ new/leechcraft-0.6.0/src/plugins/azoth/proxyobject.cpp 2013-09-11 20:32:54.000000000 +0200
@@ -337,7 +337,9 @@
{
const auto& link = LinkRegexp_.cap (1);
if (pos > 0 &&
- (body.at (pos - 1) == '"' || body.at (pos - 1) == '='))
+ (body.at (pos - 1) == '"' ||
+ body.at (pos - 1) == '=' ||
+ body.at (pos - 1) == '\''))
{
pos += link.size ();
continue;
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/leechcraft-0.5.99/src/plugins/azoth/userslistwidget.cpp new/leechcraft-0.6.0/src/plugins/azoth/userslistwidget.cpp
--- old/leechcraft-0.5.99/src/plugins/azoth/userslistwidget.cpp 2013-07-13 11:04:11.000000000 +0200
+++ new/leechcraft-0.6.0/src/plugins/azoth/userslistwidget.cpp 2013-09-11 20:32:54.000000000 +0200
@@ -87,7 +87,8 @@
Ui_.ListView_->setFocusProxy (Ui_.FilterLine_);
Ui_.ListView_->setFocus ();
- Ui_.FilterLine_->installEventFilter (new KeyboardRosterFixer (Ui_.ListView_, this));
+
+ new KeyboardRosterFixer (Ui_.FilterLine_, Ui_.ListView_, this);
}
QObject* UsersListWidget::GetActivatedParticipant () const
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/leechcraft-0.5.99/src/plugins/bittorrent/core.cpp new/leechcraft-0.6.0/src/plugins/bittorrent/core.cpp
--- old/leechcraft-0.5.99/src/plugins/bittorrent/core.cpp 2013-07-13 11:04:11.000000000 +0200
+++ new/leechcraft-0.6.0/src/plugins/bittorrent/core.cpp 2013-09-11 20:32:54.000000000 +0200
@@ -543,13 +543,8 @@
else if (!status.paused &&
(status.state == libtorrent::torrent_status::finished ||
status.state == libtorrent::torrent_status::seeding))
- {
- auto total = status.num_incomplete;
- if (total <= 0)
- total = status.list_peers - status.list_seeds;
return tr ("100% (%1)")
.arg (Util::MakePrettySize (status.total_wanted));
- }
else
return tr ("%1% (%2 of %3)")
.arg (status.progress * 100, 0, 'f', 2)
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/leechcraft-0.5.99/src/plugins/dolozhee/bugreportpage.ui new/leechcraft-0.6.0/src/plugins/dolozhee/bugreportpage.ui
--- old/leechcraft-0.5.99/src/plugins/dolozhee/bugreportpage.ui 2013-07-13 11:04:11.000000000 +0200
+++ new/leechcraft-0.6.0/src/plugins/dolozhee/bugreportpage.ui 2013-09-11 20:32:54.000000000 +0200
@@ -6,8 +6,8 @@
<rect>
<x>0</x>
<y>0</y>
- <width>429</width>
- <height>403</height>
+ <width>476</width>
+ <height>389</height>
</rect>
</property>
<property name="windowTitle">
@@ -35,7 +35,14 @@
</widget>
</item>
<item row="1" column="1">
- <widget class="QPlainTextEdit" name="ShortDesc_"/>
+ <widget class="QPlainTextEdit" name="ShortDesc_">
+ <property name="sizePolicy">
+ <sizepolicy hsizetype="Expanding" vsizetype="Expanding">
+ <horstretch>0</horstretch>
+ <verstretch>1</verstretch>
+ </sizepolicy>
+ </property>
+ </widget>
</item>
<item row="4" column="0">
<widget class="QLabel" name="label_3">
@@ -45,7 +52,14 @@
</widget>
</item>
<item row="4" column="1">
- <widget class="QPlainTextEdit" name="STR_"/>
+ <widget class="QPlainTextEdit" name="STR_">
+ <property name="sizePolicy">
+ <sizepolicy hsizetype="Expanding" vsizetype="Expanding">
+ <horstretch>0</horstretch>
+ <verstretch>1</verstretch>
+ </sizepolicy>
+ </property>
+ </widget>
</item>
<item row="2" column="0">
<widget class="QLabel" name="label_4">
@@ -55,7 +69,14 @@
</widget>
</item>
<item row="2" column="1">
- <widget class="QPlainTextEdit" name="ER_"/>
+ <widget class="QPlainTextEdit" name="ER_">
+ <property name="sizePolicy">
+ <sizepolicy hsizetype="Expanding" vsizetype="Expanding">
+ <horstretch>0</horstretch>
+ <verstretch>1</verstretch>
+ </sizepolicy>
+ </property>
+ </widget>
</item>
<item row="3" column="0">
<widget class="QLabel" name="label_5">
@@ -65,7 +86,14 @@
</widget>
</item>
<item row="3" column="1">
- <widget class="QPlainTextEdit" name="AR_"/>
+ <widget class="QPlainTextEdit" name="AR_">
+ <property name="sizePolicy">
+ <sizepolicy hsizetype="Expanding" vsizetype="Expanding">
+ <horstretch>0</horstretch>
+ <verstretch>1</verstretch>
+ </sizepolicy>
+ </property>
+ </widget>
</item>
</layout>
</widget>
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/leechcraft-0.5.99/src/plugins/dolozhee/featurerequestpage.ui new/leechcraft-0.6.0/src/plugins/dolozhee/featurerequestpage.ui
--- old/leechcraft-0.5.99/src/plugins/dolozhee/featurerequestpage.ui 2013-07-13 11:04:11.000000000 +0200
+++ new/leechcraft-0.6.0/src/plugins/dolozhee/featurerequestpage.ui 2013-09-11 20:32:54.000000000 +0200
@@ -35,7 +35,14 @@
</widget>
</item>
<item row="1" column="1">
- <widget class="QPlainTextEdit" name="Description_"/>
+ <widget class="QPlainTextEdit" name="Description_">
+ <property name="sizePolicy">
+ <sizepolicy hsizetype="Expanding" vsizetype="Expanding">
+ <horstretch>0</horstretch>
+ <verstretch>1</verstretch>
+ </sizepolicy>
+ </property>
+ </widget>
</item>
</layout>
</widget>
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/leechcraft-0.5.99/src/plugins/lastfmscrobble/eventattendmarker.cpp new/leechcraft-0.6.0/src/plugins/lastfmscrobble/eventattendmarker.cpp
--- old/leechcraft-0.5.99/src/plugins/lastfmscrobble/eventattendmarker.cpp 2013-07-13 11:04:11.000000000 +0200
+++ new/leechcraft-0.6.0/src/plugins/lastfmscrobble/eventattendmarker.cpp 2013-09-11 20:32:54.000000000 +0200
@@ -85,12 +85,14 @@
void EventAttendMarker::handleFinished ()
{
+ sender ()->deleteLater ();
emit finished ();
deleteLater ();
}
void EventAttendMarker::handleError ()
{
+ sender ()->deleteLater ();
qWarning () << Q_FUNC_INFO
<< "error marking event";
deleteLater ();
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/leechcraft-0.5.99/src/plugins/lastfmscrobble/recentreleasesfetcher.cpp new/leechcraft-0.6.0/src/plugins/lastfmscrobble/recentreleasesfetcher.cpp
--- old/leechcraft-0.5.99/src/plugins/lastfmscrobble/recentreleasesfetcher.cpp 2013-07-13 11:04:11.000000000 +0200
+++ new/leechcraft-0.6.0/src/plugins/lastfmscrobble/recentreleasesfetcher.cpp 2013-09-11 20:32:54.000000000 +0200
@@ -120,6 +120,7 @@
}
emit gotRecentReleases (releases);
+ deleteLater ();
}
void RecentReleasesFetcher::handleReplyError ()
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/leechcraft-0.5.99/src/plugins/launchy/favoritesmanager.cpp new/leechcraft-0.6.0/src/plugins/launchy/favoritesmanager.cpp
--- old/leechcraft-0.5.99/src/plugins/launchy/favoritesmanager.cpp 2013-07-13 11:04:11.000000000 +0200
+++ new/leechcraft-0.6.0/src/plugins/launchy/favoritesmanager.cpp 2013-09-11 20:32:54.000000000 +0200
@@ -74,7 +74,7 @@
void FavoritesManager::Save () const
{
QSettings settings (QCoreApplication::organizationName (),
- QCoreApplication::applicationName () + "_LMP");
+ QCoreApplication::applicationName () + "_Launchy");
settings.beginGroup ("Favorites");
settings.setValue ("IDs", QStringList (Favorites_.toList ()));
settings.endGroup ();
@@ -83,7 +83,7 @@
void FavoritesManager::Load ()
{
QSettings settings (QCoreApplication::organizationName (),
- QCoreApplication::applicationName () + "_LMP");
+ QCoreApplication::applicationName () + "_Launchy");
settings.beginGroup ("Favorites");
Favorites_ = QSet<QString>::fromList (settings.value ("IDs").toStringList ());
settings.endGroup ();
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/leechcraft-0.5.99/src/plugins/liznoo/dbusconnector.cpp new/leechcraft-0.6.0/src/plugins/liznoo/dbusconnector.cpp
--- old/leechcraft-0.5.99/src/plugins/liznoo/dbusconnector.cpp 2013-07-13 11:04:11.000000000 +0200
+++ new/leechcraft-0.6.0/src/plugins/liznoo/dbusconnector.cpp 2013-09-11 20:32:54.000000000 +0200
@@ -31,6 +31,7 @@
#include <QTimer>
#include <QDBusInterface>
#include <QDBusReply>
+#include <QDBusConnectionInterface>
#include <QtDebug>
#include
#include "batteryinfo.h"
@@ -43,6 +44,23 @@
: QObject (parent)
, SB_ (QDBusConnection::systemBus ())
{
+ auto iface = SB_.interface ();
+ auto checkRunning = [&iface]
+ {
+ return !iface->registeredServiceNames ()
+ .value ().filter ("org.freedesktop.UPower").isEmpty ();
+ };
+ if (!checkRunning ())
+ {
+ iface->startService ("org.freedesktop.UPower");
+ if (!checkRunning ())
+ {
+ qWarning () << Q_FUNC_INFO
+ << "failed to autostart UPower, we won't work :(";
+ return;
+ }
+ }
+
SB_.connect ("org.freedesktop.UPower",
"/org/freedesktop/UPower",
"org.freedesktop.UPower",
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/leechcraft-0.5.99/src/plugins/lmp/CMakeLists.txt new/leechcraft-0.6.0/src/plugins/lmp/CMakeLists.txt
--- old/leechcraft-0.5.99/src/plugins/lmp/CMakeLists.txt 2013-07-13 11:04:11.000000000 +0200
+++ new/leechcraft-0.6.0/src/plugins/lmp/CMakeLists.txt 2013-09-11 20:32:54.000000000 +0200
@@ -48,13 +48,25 @@
${TAGLIB_INCLUDES}
${LEECHCRAFT_INCLUDE_DIR}
)
+SET (COMMON_SRCS
+ mediainfo.cpp
+ )
+IF (${UNIX})
+ SET_SOURCE_FILES_PROPERTIES (${COMMON_SRCS}
+ PROPERTIES
+ COMPILE_FLAGS "-fPIC")
+ENDIF (${UNIX})
+
+ADD_LIBRARY (leechcraft_lmp_common STATIC
+ ${COMMON_SRCS}
+ )
+
SET (SRCS
lmp.cpp
xmlsettingsmanager.cpp
playertab.cpp
player.cpp
core.cpp
- mediainfo.cpp
localfileresolver.cpp
playlistdelegate.cpp
localcollection.cpp
@@ -161,6 +173,7 @@
${TAGLIB_LIBRARIES}
${MPRIS_SUBLIB}
+ leechcraft_lmp_common
)
INSTALL (TARGETS leechcraft_lmp DESTINATION ${LC_PLUGINS_DEST})
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/leechcraft-0.5.99/src/plugins/lmp/albumartmanager.cpp new/leechcraft-0.6.0/src/plugins/lmp/albumartmanager.cpp
--- old/leechcraft-0.5.99/src/plugins/lmp/albumartmanager.cpp 2013-07-13 11:04:11.000000000 +0200
+++ new/leechcraft-0.6.0/src/plugins/lmp/albumartmanager.cpp 2013-09-11 20:32:54.000000000 +0200
@@ -51,7 +51,8 @@
void AlbumArtManager::CheckAlbumArt (const Collection::Artist& artist, Collection::Album_ptr album)
{
- if (!album->CoverPath_.isEmpty ())
+ const auto& path = album->CoverPath_;
+ if (!path.isEmpty () && QFile::exists (path))
return;
CheckAlbumArt (artist.Name_, album->Name_, false);
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/leechcraft-0.5.99/src/plugins/lmp/hypeswidget.cpp new/leechcraft-0.6.0/src/plugins/lmp/hypeswidget.cpp
--- old/leechcraft-0.5.99/src/plugins/lmp/hypeswidget.cpp 2013-07-13 11:04:11.000000000 +0200
+++ new/leechcraft-0.6.0/src/plugins/lmp/hypeswidget.cpp 2013-09-11 20:32:54.000000000 +0200
@@ -103,7 +103,6 @@
root->setContextProperty ("topsText", tr ("Show tops"));
root->setContextProperty ("colorProxy",
new Util::ColorThemeProxy (Core::Instance ().GetProxy ()->GetColorThemeManager (), this));
- root->setContextProperty ("similarLabelPosition", "underArtist");
Ui_.HypesView_->setSource (QUrl ("qrc:/lmp/resources/qml/HypesView.qml"));
connect (Ui_.InfoProvider_,
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/leechcraft-0.5.99/src/plugins/lmp/interfaces/lmp/lmpconfig.h new/leechcraft-0.6.0/src/plugins/lmp/interfaces/lmp/lmpconfig.h
--- old/leechcraft-0.5.99/src/plugins/lmp/interfaces/lmp/lmpconfig.h 2013-07-13 11:04:11.000000000 +0200
+++ new/leechcraft-0.6.0/src/plugins/lmp/interfaces/lmp/lmpconfig.h 1970-01-01 01:00:00.000000000 +0100
@@ -1,39 +0,0 @@
-/**********************************************************************
- * LeechCraft - modular cross-platform feature rich internet client.
- * Copyright (C) 2006-2013 Georg Rudoy
- *
- * Boost Software License - Version 1.0 - August 17th, 2003
- *
- * Permission is hereby granted, free of charge, to any person or organization
- * obtaining a copy of the software and accompanying documentation covered by
- * this license (the "Software") to use, reproduce, display, distribute,
- * execute, and transmit the Software, and to prepare derivative works of the
- * Software, and to permit third-parties to whom the Software is furnished to
- * do so, all subject to the following:
- *
- * The copyright notices in the Software and this entire statement, including
- * the above license grant, this restriction and the following disclaimer,
- * must be included in all copies of the Software, in whole or in part, and
- * all derivative works of the Software, unless such copies or derivative
- * works are solely in the form of machine-executable object code generated by
- * a source language processor.
- *
- * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
- * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
- * FITNESS FOR A PARTICULAR PURPOSE, TITLE AND NON-INFRINGEMENT. IN NO EVENT
- * SHALL THE COPYRIGHT HOLDERS OR ANYONE DISTRIBUTING THE SOFTWARE BE LIABLE
- * FOR ANY DAMAGES OR OTHER LIABILITY, WHETHER IN CONTRACT, TORT OR OTHERWISE,
- * ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
- * DEALINGS IN THE SOFTWARE.
- **********************************************************************/
-
-#pragma once
-
-#include <QtGlobal>
-
-# if defined(leechcraft_lmp_EXPORTS)
-# define LMP_API Q_DECL_EXPORT
-# else
-# define LMP_API Q_DECL_IMPORT
-#endif
-
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/leechcraft-0.5.99/src/plugins/lmp/interfaces/lmp/mediainfo.h new/leechcraft-0.6.0/src/plugins/lmp/interfaces/lmp/mediainfo.h
--- old/leechcraft-0.5.99/src/plugins/lmp/interfaces/lmp/mediainfo.h 2013-07-13 11:04:11.000000000 +0200
+++ new/leechcraft-0.6.0/src/plugins/lmp/interfaces/lmp/mediainfo.h 2013-09-11 20:32:54.000000000 +0200
@@ -32,13 +32,12 @@
#include <QStringList>
#include <QMetaType>
#include
-#include "lmpconfig.h"
namespace LeechCraft
{
namespace LMP
{
- struct LMP_API MediaInfo
+ struct MediaInfo
{
QString LocalPath_;
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/leechcraft-0.5.99/src/plugins/lmp/lmpsettings.xml new/leechcraft-0.6.0/src/plugins/lmp/lmpsettings.xml
--- old/leechcraft-0.5.99/src/plugins/lmp/lmpsettings.xml 2013-07-13 11:04:11.000000000 +0200
+++ new/leechcraft-0.6.0/src/plugins/lmp/lmpsettings.xml 2013-09-11 20:32:54.000000000 +0200
@@ -25,6 +25,9 @@
<item type="checkbox" property="RequestLyrics" default="true">
<label value="Request lyrics" />
</item>
+ <item type="checkbox" property="AutoFetchAlbumArt" default="true">
+ <label value="Automatically fetch missing album art" />
+ </item>
<item type="checkbox" property="RememberUsedProviders" default="true">
<label value="Remember used data providers" />
</item>
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/leechcraft-0.5.99/src/plugins/lmp/localcollection.cpp new/leechcraft-0.6.0/src/plugins/lmp/localcollection.cpp
--- old/leechcraft-0.5.99/src/plugins/lmp/localcollection.cpp 2013-07-13 11:04:11.000000000 +0200
+++ new/leechcraft-0.6.0/src/plugins/lmp/localcollection.cpp 2013-09-11 20:32:54.000000000 +0200
@@ -536,16 +536,19 @@
int trackCount = 0;
const bool shouldEmit = !Artists_.isEmpty ();
- Q_FOREACH (const auto& artist, artists)
+ for (const auto& artist : artists)
{
if (std::find_if (Artists_.begin (), Artists_.end (),
[&artist] (decltype (artist) present) { return present.ID_ == artist.ID_; }) == Artists_.end ())
Artists_ += artist;
- Q_FOREACH (auto album, artist.Albums_)
- Q_FOREACH (const auto& track, album->Tracks_)
+ for (const auto& album : artist.Albums_)
+ for (const auto& track : album->Tracks_)
PresentPaths_ << track.FilePath_;
}
+ const auto autoFetchAA = XmlSettingsManager::Instance ()
+ .property ("AutoFetchAlbumArt").toBool ();
+
for (const auto& artist : artists)
{
albumCount += artist.Albums_.size ();
@@ -564,7 +567,8 @@
{
trackCount += album->Tracks_.size ();
- AlbumArtMgr_->CheckAlbumArt (artist, album);
+ if (autoFetchAA)
+ AlbumArtMgr_->CheckAlbumArt (artist, album);
auto albumItem = GetItem (Album2Item_,
album->ID_,
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/leechcraft-0.5.99/src/plugins/lmp/nowplayingwidget.cpp new/leechcraft-0.6.0/src/plugins/lmp/nowplayingwidget.cpp
--- old/leechcraft-0.5.99/src/plugins/lmp/nowplayingwidget.cpp 2013-07-13 11:04:11.000000000 +0200
+++ new/leechcraft-0.6.0/src/plugins/lmp/nowplayingwidget.cpp 2013-09-11 20:32:54.000000000 +0200
@@ -145,13 +145,13 @@
const QDateTime& current = QDateTime::currentDateTime ();
const int days = datetime.daysTo (current);
if (days > 30)
- return datetime.toString ("MMMM yyyy");
+ return QLocale ().toString (datetime, "MMMM yyyy");
else if (days >= 7)
return NowPlayingWidget::tr ("%n day(s) ago", 0, days);
else if (days >= 1)
- return datetime.toString ("dddd");
+ return QLocale ().toString (datetime, "dddd");
else
- return datetime.time ().toString ();
+ return QLocale ().toString (datetime.time ());
}
}
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/leechcraft-0.5.99/src/plugins/lmp/player.cpp new/leechcraft-0.6.0/src/plugins/lmp/player.cpp
--- old/leechcraft-0.5.99/src/plugins/lmp/player.cpp 2013-07-13 11:04:11.000000000 +0200
+++ new/leechcraft-0.6.0/src/plugins/lmp/player.cpp 2013-09-11 20:32:54.000000000 +0200
@@ -150,7 +150,19 @@
const auto& localPath = url.toLocalFile ();
if (QFileInfo (localPath).isFile ())
{
- sources << Phonon::MediaSource (localPath);
+ bool playlistHandled = false;
+ if (auto f = MakePlaylistParser (localPath))
+ {
+ const auto& playlistSrcs = f (localPath);
+ if (!playlistSrcs.isEmpty ())
+ {
+ playlistHandled = true;
+ sources += playlistSrcs;
+ }
+ }
+
+ if (!playlistHandled)
+ sources << Phonon::MediaSource (localPath);
continue;
}
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/leechcraft-0.5.99/src/plugins/lmp/plugins/graffiti/CMakeLists.txt new/leechcraft-0.6.0/src/plugins/lmp/plugins/graffiti/CMakeLists.txt
--- old/leechcraft-0.5.99/src/plugins/lmp/plugins/graffiti/CMakeLists.txt 2013-07-13 11:04:11.000000000 +0200
+++ new/leechcraft-0.6.0/src/plugins/lmp/plugins/graffiti/CMakeLists.txt 2013-09-11 20:32:54.000000000 +0200
@@ -44,7 +44,7 @@
${QT_LIBRARIES}
${LEECHCRAFT_LIBRARIES}
${TAGLIB_LIBRARIES}
- leechcraft_lmp
+ leechcraft_lmp_common
)
INSTALL (TARGETS leechcraft_lmp_graffiti DESTINATION ${LC_PLUGINS_DEST})
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/leechcraft-0.5.99/src/plugins/lmp/plugins/graffiti/cuesplitter.cpp new/leechcraft-0.6.0/src/plugins/lmp/plugins/graffiti/cuesplitter.cpp
--- old/leechcraft-0.5.99/src/plugins/lmp/plugins/graffiti/cuesplitter.cpp 2013-07-13 11:04:11.000000000 +0200
+++ new/leechcraft-0.6.0/src/plugins/lmp/plugins/graffiti/cuesplitter.cpp 2013-09-11 20:32:54.000000000 +0200
@@ -240,7 +240,7 @@
void CueSplitter::split ()
{
- const auto& cue = ParseCue (CueFile_);
+ const auto& cue = ParseCue (QDir (Dir_).absoluteFilePath (CueFile_));
qDebug () << cue.IsValid () << cue.Album_ << cue.Performer_ << cue.Date_;
for (const auto& file : cue.Files_)
{
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/leechcraft-0.5.99/src/plugins/lmp/plugins/graffiti/resources/images/graffiti.svg new/leechcraft-0.6.0/src/plugins/lmp/plugins/graffiti/resources/images/graffiti.svg
--- old/leechcraft-0.5.99/src/plugins/lmp/plugins/graffiti/resources/images/graffiti.svg 2013-07-13 11:04:11.000000000 +0200
+++ new/leechcraft-0.6.0/src/plugins/lmp/plugins/graffiti/resources/images/graffiti.svg 2013-09-11 20:32:54.000000000 +0200
@@ -14,8 +14,8 @@
width="96"
height="96"
id="svg2408"
- inkscape:version="0.48.3.1 r9886"
- sodipodi:docname="lmp.svg"
+ inkscape:version="0.48.4 r9939"
+ sodipodi:docname="graffiti.svg"
inkscape:export-filename="/home/buckstabu/Dropbox/Public/lcicons/lcproto_poshuku.png"
inkscape:export-xdpi="90"
inkscape:export-ydpi="90">
@@ -28,15 +28,15 @@
guidetolerance="10"
inkscape:pageopacity="0"
inkscape:pageshadow="2"
- inkscape:window-width="1366"
- inkscape:window-height="719"
+ inkscape:window-width="1918"
+ inkscape:window-height="1037"
id="namedview68"
showgrid="false"
inkscape:zoom="3.3333333"
- inkscape:cx="-10.926025"
- inkscape:cy="76.362502"
+ inkscape:cx="-22.926025"
+ inkscape:cy="1.9707938"
inkscape:window-x="0"
- inkscape:window-y="29"
+ inkscape:window-y="19"
inkscape:window-maximized="1"
inkscape:current-layer="svg2408" />
dc:formatimage/svg+xml
http://purl.org/dc/dcmitype/StillImage" />
- dc:title
+
</metadata>
-
-
- </g>
-
-
- </g>
-
-
-
- </g>
-
-
- </g>
</g>
- </flowRegion>graffiti</flowPara></flowRoot> </g>
+ </g>
</g>
-</svg>
+ graffiti</tspan></text>
+</svg>
\ No newline at end of file
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/leechcraft-0.5.99/src/plugins/lmp/resources/qml/ArtistBrowserView.qml new/leechcraft-0.6.0/src/plugins/lmp/resources/qml/ArtistBrowserView.qml
--- old/leechcraft-0.5.99/src/plugins/lmp/resources/qml/ArtistBrowserView.qml 2013-07-13 11:04:11.000000000 +0200
+++ new/leechcraft-0.6.0/src/plugins/lmp/resources/qml/ArtistBrowserView.qml 2013-09-11 20:32:54.000000000 +0200
@@ -37,7 +37,6 @@
onBookmarkArtistRequested: rootRect.bookmarkArtistRequested(id, page, tags)
onPreviewRequested: rootRect.previewRequested(artist)
onBrowseInfo: rootRect.browseInfo(artist)
- similarLabelPosition: "underArtist"
}
}
}
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/leechcraft-0.5.99/src/plugins/lmp/resources/qml/SimilarView.qml new/leechcraft-0.6.0/src/plugins/lmp/resources/qml/SimilarView.qml
--- old/leechcraft-0.5.99/src/plugins/lmp/resources/qml/SimilarView.qml 2013-07-13 11:04:11.000000000 +0200
+++ new/leechcraft-0.6.0/src/plugins/lmp/resources/qml/SimilarView.qml 2013-09-11 20:32:54.000000000 +0200
@@ -23,7 +23,6 @@
signal browseInfo(string artist)
property alias model: similarView.model
- property string similarLabelPosition: "right"
Image {
id: fullSizeArtistImg
@@ -213,12 +212,10 @@
id: similarityLabel
text: similarity
color: colorProxy.color_TextBox_Aux1TextColor
- anchors.top: similarLabelPosition == "right" ? parent.top : artistNameLabel.bottom
+ anchors.top: artistNameLabel.bottom
anchors.topMargin: 2
- anchors.right: similarLabelPosition == "right" ? parent.right : undefined
- anchors.rightMargin: similarLabelPosition == "right" ? 2 : 0
- anchors.left: similarLabelPosition == "right" ? undefined : artistImageThumb.right
- anchors.leftMargin: similarLabelPosition == "right" ? 0 : 5
+ anchors.left: artistImageThumb.right
+ anchors.leftMargin: 5
}
Text {
@@ -227,7 +224,7 @@
color: colorProxy.color_TextBox_Aux2TextColor
anchors.leftMargin: 5
anchors.left: artistImageThumb.right
- anchors.top: similarLabelPosition == "right" ? artistNameLabel.bottom : similarityLabel.bottom
+ anchors.top: similarityLabel.bottom
anchors.topMargin: 0
anchors.right: parent.right
anchors.rightMargin: 5
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/leechcraft-0.5.99/src/plugins/lmp/rootpathsettingsmanager.cpp new/leechcraft-0.6.0/src/plugins/lmp/rootpathsettingsmanager.cpp
--- old/leechcraft-0.5.99/src/plugins/lmp/rootpathsettingsmanager.cpp 2013-07-13 11:04:11.000000000 +0200
+++ new/leechcraft-0.6.0/src/plugins/lmp/rootpathsettingsmanager.cpp 2013-09-11 20:32:54.000000000 +0200
@@ -30,6 +30,7 @@
#include "rootpathsettingsmanager.h"
#include <QStandardItemModel>
#include <QFile>
+#include <QMessageBox>
#include
#include "xmlsettingsmanager.h"
#include "core.h"
@@ -63,6 +64,21 @@
void RootPathSettingsManager::addRequested (const QString&, const QVariantList& list)
{
+ if (!XmlSettingsManager::Instance ().Property ("HasAskedAboutAAFetch", false).toBool ())
+ {
+ XmlSettingsManager::Instance ().setProperty ("HasAskedAboutAAFetch", true);
+ const auto fetch = QMessageBox::question (nullptr,
+ "LeechCraft",
+ tr ("Do you want LMP to automatically fetch missing album art? It is done in "
+ "the background and won't disturb you, but can consume quite some traffic "
+ "and local storage space, especially if you have a lot of albums in your "
+ "collection.<br/><br/>You can always toggle this option later in LMP "
+ "settings"),
+ QMessageBox::Yes | QMessageBox::No) == QMessageBox::Yes;
+
+ XmlSettingsManager::Instance ().setProperty ("AutoFetchAlbumArt", fetch);
+ }
+
const QString& str = list.value (0).toString ();
if (QFile::exists (str))
Core::Instance ().GetLocalCollection ()->Scan (str);
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/leechcraft-0.5.99/src/plugins/lmp/similarviewmanager.cpp new/leechcraft-0.6.0/src/plugins/lmp/similarviewmanager.cpp
--- old/leechcraft-0.5.99/src/plugins/lmp/similarviewmanager.cpp 2013-07-13 11:04:11.000000000 +0200
+++ new/leechcraft-0.6.0/src/plugins/lmp/similarviewmanager.cpp 2013-09-11 20:32:54.000000000 +0200
@@ -54,7 +54,6 @@
, Model_ (new SimilarModel (this))
{
View_->rootContext ()->setContextProperty ("similarModel", Model_);
- View_->rootContext ()->setContextProperty ("similarLabelPosition", "right");
View_->rootContext ()->setContextProperty ("colorProxy",
new Util::ColorThemeProxy (Core::Instance ().GetProxy ()->GetColorThemeManager (), this));
}
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/leechcraft-0.5.99/src/plugins/lmp/util.cpp new/leechcraft-0.6.0/src/plugins/lmp/util.cpp
--- old/leechcraft-0.5.99/src/plugins/lmp/util.cpp 2013-07-13 11:04:11.000000000 +0200
+++ new/leechcraft-0.6.0/src/plugins/lmp/util.cpp 2013-09-11 20:32:54.000000000 +0200
@@ -126,16 +126,23 @@
possibleBases << "cover" << "folder" << "front";
const QDir& dir = QFileInfo (near).absoluteDir ();
- const QStringList& entryList = dir.entryList (QStringList ("*.jpg") << "*.png" << "*.bmp");
- auto pos = std::find_if (entryList.begin (), entryList.end (),
- [&possibleBases] (const QString& name) -> bool
- {
- Q_FOREACH (const QString& pBase, possibleBases)
- if (name.startsWith (pBase, Qt::CaseInsensitive))
- return true;
- return false;
- });
- return pos == entryList.end () ? QString () : dir.filePath (*pos);
+ const QStringList& entryList = dir.entryList ({ "*.jpg", "*.png", "*.bmp" });
+ if (entryList.size () > 1)
+ {
+ auto pos = std::find_if (entryList.begin (), entryList.end (),
+ [&possibleBases] (const QString& name) -> bool
+ {
+ for (const auto& pBase : possibleBases)
+ if (name.startsWith (pBase, Qt::CaseInsensitive))
+ return true;
+ return false;
+ });
+ return pos == entryList.end () ? QString () : dir.filePath (*pos);
+ }
+ else if (entryList.size () == 1)
+ return dir.filePath (entryList.first ());
+ else
+ return {};
}
QPixmap FindAlbumArt (const QString& near, bool ignoreCollection)
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/leechcraft-0.5.99/src/plugins/poshuku/browserwidget.cpp new/leechcraft-0.6.0/src/plugins/poshuku/browserwidget.cpp
--- old/leechcraft-0.5.99/src/plugins/poshuku/browserwidget.cpp 2013-07-13 11:04:11.000000000 +0200
+++ new/leechcraft-0.6.0/src/plugins/poshuku/browserwidget.cpp 2013-09-11 20:32:54.000000000 +0200
@@ -675,6 +675,19 @@
Ui_.URLFrame_->GetEdit ()->clear ();
HtmlMode_ = true;
WebView_->setHtml (html, base);
+
+ if (!Own_)
+ {
+ auto links = WebView_->page ()->mainFrame ()->findAllElements ("a");
+ for (int i = 0; i < links.count (); ++i)
+ {
+ auto elem = links.at (i);
+ if (elem.attribute ("target") == "_blank")
+ continue;
+
+ elem.setAttribute ("target", "_blank");
+ }
+ }
}
void BrowserWidget::SetNavBarVisible (bool visible)
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/leechcraft-0.5.99/src/plugins/poshuku/historymodel.cpp new/leechcraft-0.6.0/src/plugins/poshuku/historymodel.cpp
--- old/leechcraft-0.5.99/src/plugins/poshuku/historymodel.cpp 2013-07-13 11:04:11.000000000 +0200
+++ new/leechcraft-0.6.0/src/plugins/poshuku/historymodel.cpp 2013-09-11 20:32:54.000000000 +0200
@@ -121,7 +121,7 @@
connect (GarbageTimer_,
SIGNAL (timeout ()),
this,
- SLOT (loadData ()));
+ SLOT (collectGarbage ()));
}
HistoryModel::~HistoryModel ()
@@ -299,15 +299,12 @@
void HistoryModel::loadData ()
{
+ collectGarbage ();
+
beginResetModel ();
while (RootItem_->ChildCount ())
RootItem_->RemoveChild (0);
- int age = XmlSettingsManager::Instance ()->
- property ("HistoryClearOlderThan").toInt ();
- int maxItems = XmlSettingsManager::Instance ()->
- property ("HistoryKeepLessThan").toInt ();
- Core::Instance ().GetStorageBackend ()->ClearOldHistory (age, maxItems);
Items_.clear ();
Core::Instance ().GetStorageBackend ()->LoadHistory (Items_);
@@ -326,5 +323,14 @@
Items_.push_back (item);
Add (item, true);
}
+
+ void HistoryModel::collectGarbage ()
+ {
+ int age = XmlSettingsManager::Instance ()->
+ property ("HistoryClearOlderThan").toInt ();
+ int maxItems = XmlSettingsManager::Instance ()->
+ property ("HistoryKeepLessThan").toInt ();
+ Core::Instance ().GetStorageBackend ()->ClearOldHistory (age, maxItems);
+ }
}
}
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/leechcraft-0.5.99/src/plugins/poshuku/historymodel.h new/leechcraft-0.6.0/src/plugins/poshuku/historymodel.h
--- old/leechcraft-0.5.99/src/plugins/poshuku/historymodel.h 2013-07-13 11:04:11.000000000 +0200
+++ new/leechcraft-0.6.0/src/plugins/poshuku/historymodel.h 2013-09-11 20:32:54.000000000 +0200
@@ -90,6 +90,7 @@
void Add (const HistoryItem&, bool announce);
private slots:
void loadData ();
+ void collectGarbage ();
void handleItemAdded (const HistoryItem&);
signals:
// Hook support signals
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/leechcraft-0.5.99/src/plugins/poshuku/plugins/autosearch/autosearch.cpp new/leechcraft-0.6.0/src/plugins/poshuku/plugins/autosearch/autosearch.cpp
--- old/leechcraft-0.5.99/src/plugins/poshuku/plugins/autosearch/autosearch.cpp 2013-07-13 11:04:11.000000000 +0200
+++ new/leechcraft-0.6.0/src/plugins/poshuku/plugins/autosearch/autosearch.cpp 2013-09-11 20:32:54.000000000 +0200
@@ -56,23 +56,22 @@
QByteArray Plugin::GetUniqueID () const
{
- return "org.LeechCraft.Poshuku.Plugin";
+ return "org.LeechCraft.Poshuku.Autosearch";
}
QString Plugin::GetName () const
{
- return "Poshuku Plugin";
+ return "Poshuku Autosearch";
}
QString Plugin::GetInfo () const
{
- return tr ("Provides support for file:// scheme.");
+ return tr ("Provides support for Google search suggestions.");
}
QIcon Plugin::GetIcon () const
{
- static QIcon icon (":/plugins/poshuku/plugins/filescheme/resources/images/poshuku_filescheme.svg");
- return icon;
+ return QIcon ();
}
QSet<QByteArray> Plugin::GetPluginClasses () const
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/leechcraft-0.5.99/src/plugins/poshuku/plugins/cleanweb/lineparser.cpp new/leechcraft-0.6.0/src/plugins/poshuku/plugins/cleanweb/lineparser.cpp
--- old/leechcraft-0.5.99/src/plugins/poshuku/plugins/cleanweb/lineparser.cpp 2013-07-13 11:04:11.000000000 +0200
+++ new/leechcraft-0.6.0/src/plugins/poshuku/plugins/cleanweb/lineparser.cpp 2013-09-11 20:32:54.000000000 +0200
@@ -262,10 +262,12 @@
const auto& remaining = ParseOptions (splitted.at (1).split (',', QString::SkipEmptyParts), f);
if (remaining.size ())
{
+ /*
qWarning () << Q_FUNC_INFO
<< "unsupported options for filter"
<< actualLine
<< remaining;
+ */
return;
}
}
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/leechcraft-0.5.99/src/plugins/summary/summarywidget.cpp new/leechcraft-0.6.0/src/plugins/summary/summarywidget.cpp
--- old/leechcraft-0.5.99/src/plugins/summary/summarywidget.cpp 2013-07-13 11:04:11.000000000 +0200
+++ new/leechcraft-0.6.0/src/plugins/summary/summarywidget.cpp 2013-09-11 20:32:54.000000000 +0200
@@ -255,7 +255,7 @@
Q_FOREACH (QAction *action, Toolbar_->actions ())
{
auto wa = qobject_cast (action);
- if (!wa)
+ if (!wa || wa->defaultWidget () != SearchWidget_)
{
Toolbar_->removeAction (action);
delete action;
@@ -265,21 +265,21 @@
}
}
- QList SummaryWidget::CreateProxyActions (const QList& actions) const
+ QList SummaryWidget::CreateProxyActions (const QList& actions, QObject *parent) const
{
QList proxies;
Q_FOREACH (QAction *action, actions)
{
- QAction *pa = new QAction (action->icon (),
- action->text (), Toolbar_.get ());
- if (action->isSeparator ())
- pa->setSeparator (true);
- else if (qobject_cast (action))
+ if (qobject_cast (action))
{
proxies << action;
continue;
}
+
+ QAction *pa = new QAction (action->icon (), action->text (), parent);
+ if (action->isSeparator ())
+ pa->setSeparator (true);
else
{
pa->setCheckable (action->isCheckable ());
@@ -407,7 +407,7 @@
action->setIcon (Core::Instance ().GetProxy ()->GetIcon (ai));
}
- const auto& proxies = CreateProxyActions (controls->actions ());
+ const auto& proxies = CreateProxyActions (controls->actions (), Toolbar_.get ());
Toolbar_->insertActions (Toolbar_->actions ().first (), proxies);
}
if (addiInfo != Ui_.ControlsDockWidget_->widget ())
@@ -451,7 +451,7 @@
this,
SLOT (handleActionTriggered (QAction*)));
menu->setAttribute (Qt::WA_DeleteOnClose, true);
- menu->addActions (CreateProxyActions (sourceMenu->actions ()));
+ menu->addActions (CreateProxyActions (sourceMenu->actions (), menu));
menu->setTitle (sourceMenu->title ());
menu->popup (Ui_.PluginsTasksTree_->viewport ()->mapToGlobal (pos));
}
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/leechcraft-0.5.99/src/plugins/summary/summarywidget.h new/leechcraft-0.6.0/src/plugins/summary/summarywidget.h
--- old/leechcraft-0.5.99/src/plugins/summary/summarywidget.h 2013-07-13 11:04:11.000000000 +0200
+++ new/leechcraft-0.6.0/src/plugins/summary/summarywidget.h 2013-09-11 20:32:54.000000000 +0200
@@ -89,7 +89,7 @@
void ConnectObject (QObject*);
SearchWidget* CreateSearchWidget ();
void ReinitToolbar ();
- QList CreateProxyActions (const QList&) const;
+ QList CreateProxyActions (const QList&, QObject*) const;
private slots:
void handleActionTriggered (QAction*);
void checkDataChanged (const QModelIndex&, const QModelIndex&);
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/leechcraft-0.5.99/src/plugins/vrooby/backends/udisks2/udisks2backend.cpp new/leechcraft-0.6.0/src/plugins/vrooby/backends/udisks2/udisks2backend.cpp
--- old/leechcraft-0.5.99/src/plugins/vrooby/backends/udisks2/udisks2backend.cpp 2013-07-13 11:04:11.000000000 +0200
+++ new/leechcraft-0.6.0/src/plugins/vrooby/backends/udisks2/udisks2backend.cpp 2013-09-11 20:32:54.000000000 +0200
@@ -206,14 +206,7 @@
auto driveIface = driveId.isEmpty () ? QDBusInterface_ptr () : GetDevInterface (driveId);
if (!driveIface || !driveIface->isValid ())
- {
- qWarning () << Q_FUNC_INFO
- << "no associated device"
- << str
- << blockIface->property ("Drive")
- << driveId;
return false;
- }
auto partitionIface = GetPartitionInterface (str);
const bool isPartition = !partitionIface->property ("Type").toString ().isEmpty ();
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/leechcraft-0.5.99/src/util/resourceloader.cpp new/leechcraft-0.6.0/src/util/resourceloader.cpp
--- old/leechcraft-0.5.99/src/util/resourceloader.cpp 2013-07-13 11:04:11.000000000 +0200
+++ new/leechcraft-0.6.0/src/util/resourceloader.cpp 2013-09-11 20:32:54.000000000 +0200
@@ -270,10 +270,11 @@
return QPixmap ();
const auto& data = dev->readAll ();
- auto px = new QPixmap;
- px->loadFromData (data);
- CachePixmaps_.insert (basename, px, data.size ());
- return *px;
+
+ QPixmap result;
+ result.loadFromData (data);
+ CachePixmaps_.insert (basename, new QPixmap (result), data.size ());
+ return result;
}
QAbstractItemModel* ResourceLoader::GetSubElemModel () const
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/leechcraft-0.5.99/src/xmlsettingsdialog/itemhandlers/itemhandlercombobox.cpp new/leechcraft-0.6.0/src/xmlsettingsdialog/itemhandlers/itemhandlercombobox.cpp
--- old/leechcraft-0.5.99/src/xmlsettingsdialog/itemhandlers/itemhandlercombobox.cpp 2013-07-13 11:04:11.000000000 +0200
+++ new/leechcraft-0.6.0/src/xmlsettingsdialog/itemhandlers/itemhandlercombobox.cpp 2013-09-11 20:32:54.000000000 +0200
@@ -233,5 +233,8 @@
<< box
<< data
<< "not found";
+
+ if (!data.toString ().isEmpty ())
+ ChangedProperties_.remove (prop);
}
}
--
To unsubscribe, e-mail: opensuse-commit+unsubscribe@opensuse.org
For additional commands, e-mail: opensuse-commit+help@opensuse.org