Re-enable debug for Konachan
This commit is contained in:
		
					parent
					
						
							
								ba79760a4b
							
						
					
				
			
			
				commit
				
					
						f2ffeb8cc2
					
				
			
		
					 1 changed files with 7 additions and 6 deletions
				
			
		| 
						 | 
					@ -22,6 +22,7 @@
 | 
				
			||||||
#include "danboorupool.h"
 | 
					#include "danboorupool.h"
 | 
				
			||||||
#include "danboorutag.h"
 | 
					#include "danboorutag.h"
 | 
				
			||||||
#include "utils.h"
 | 
					#include "utils.h"
 | 
				
			||||||
 | 
					#include "libdanbooru_debug.h"
 | 
				
			||||||
 | 
					
 | 
				
			||||||
// KF5
 | 
					// KF5
 | 
				
			||||||
 | 
					
 | 
				
			||||||
| 
						 | 
					@ -72,7 +73,7 @@ void KonachanDanbooruService::getPostList() {
 | 
				
			||||||
    QUrl danbooruUrl = requestUrl(m_url, postUri(), m_username,
 | 
					    QUrl danbooruUrl = requestUrl(m_url, postUri(), m_username,
 | 
				
			||||||
                                  m_password, parameters, m_tags);
 | 
					                                  m_password, parameters, m_tags);
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    //     qCDebug(LIBDANBOORU) << "Final constructed post URL" << danbooruUrl;
 | 
					    qCDebug(LIBDANBOORU) << "Final constructed post URL" << danbooruUrl;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    KIO::StoredTransferJob *job = KIO::storedGet(danbooruUrl, KIO::NoReload,
 | 
					    KIO::StoredTransferJob *job = KIO::storedGet(danbooruUrl, KIO::NoReload,
 | 
				
			||||||
                                  KIO::HideProgressInfo);
 | 
					                                  KIO::HideProgressInfo);
 | 
				
			||||||
| 
						 | 
					@ -87,7 +88,7 @@ void KonachanDanbooruService::getPostList() {
 | 
				
			||||||
void KonachanDanbooruService::processPostList(KJob *job)
 | 
					void KonachanDanbooruService::processPostList(KJob *job)
 | 
				
			||||||
{
 | 
					{
 | 
				
			||||||
 | 
					
 | 
				
			||||||
//     qCDebug(LIBDANBOORU) << "Got post data OK";
 | 
					    qCDebug(LIBDANBOORU) << "Got post data OK";
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    if (job->error()) {
 | 
					    if (job->error()) {
 | 
				
			||||||
        Q_EMIT(downloadError(job->errorString()));
 | 
					        Q_EMIT(downloadError(job->errorString()));
 | 
				
			||||||
| 
						 | 
					@ -123,7 +124,7 @@ void KonachanDanbooruService::processPostList(KJob *job)
 | 
				
			||||||
    // How many posts do we have to fetch?
 | 
					    // How many posts do we have to fetch?
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    if (postList.isEmpty()) {
 | 
					    if (postList.isEmpty()) {
 | 
				
			||||||
//         qCDebug(LIBDANBOORU) << "No posts found";
 | 
					        qCDebug(LIBDANBOORU) << "No posts found";
 | 
				
			||||||
        Q_EMIT(postDownloadFinished());
 | 
					        Q_EMIT(postDownloadFinished());
 | 
				
			||||||
        return;
 | 
					        return;
 | 
				
			||||||
    }
 | 
					    }
 | 
				
			||||||
| 
						 | 
					@ -145,7 +146,7 @@ void KonachanDanbooruService::processPostList(KJob *job)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
        QPixmap pix;
 | 
					        QPixmap pix;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
//         qCDebug(LIBDANBOORU) << "About to donwload images";
 | 
					        qCDebug(LIBDANBOORU) << "About to donwload images";
 | 
				
			||||||
 | 
					
 | 
				
			||||||
        if (m_cache && m_cache->findPixmap(post->thumbnailUrl().url(), &pix)) {
 | 
					        if (m_cache && m_cache->findPixmap(post->thumbnailUrl().url(), &pix)) {
 | 
				
			||||||
 | 
					
 | 
				
			||||||
| 
						 | 
					@ -199,12 +200,12 @@ void KonachanDanbooruService::processPostList(KJob *job)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
                m_postsToFetch--; // One less post to do
 | 
					                m_postsToFetch--; // One less post to do
 | 
				
			||||||
 | 
					
 | 
				
			||||||
                //qCDebug(LIBDANBOORU) << "Current posts remaining" << m_currentPosts;
 | 
					                qCDebug(LIBDANBOORU) << "Current posts remaining: " << m_postsToFetch;
 | 
				
			||||||
                Q_EMIT(postDownloaded(post));
 | 
					                Q_EMIT(postDownloaded(post));
 | 
				
			||||||
 | 
					
 | 
				
			||||||
                if (m_postsToFetch == 0)
 | 
					                if (m_postsToFetch == 0)
 | 
				
			||||||
                {
 | 
					                {
 | 
				
			||||||
//                     qCDebug(LIBDANBOORU) << "Post download finished";
 | 
					                    qCDebug(LIBDANBOORU) << "Post download finished";
 | 
				
			||||||
                    Q_EMIT(postDownloadFinished());
 | 
					                    Q_EMIT(postDownloadFinished());
 | 
				
			||||||
                }
 | 
					                }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue