From 65a50c5a85d14d9e41d9f9f593a06a259d5b8f78 Mon Sep 17 00:00:00 2001 From: Jeff Mitchell Date: Fri, 26 Aug 2011 17:47:08 -0400 Subject: [PATCH] Better structuring --- src/libtomahawk/utils/tomahawkutils.cpp | 68 +++++++++++++++++-------- 1 file changed, 46 insertions(+), 22 deletions(-) diff --git a/src/libtomahawk/utils/tomahawkutils.cpp b/src/libtomahawk/utils/tomahawkutils.cpp index 2fcb74a0b..d2a431803 100644 --- a/src/libtomahawk/utils/tomahawkutils.cpp +++ b/src/libtomahawk/utils/tomahawkutils.cpp @@ -18,15 +18,17 @@ #include "tomahawkutils.h" -#include -#include -#include -#include -#include -#include -#include -#include -#include +#include "headlesscheck.h" +#include + +#include +#include +#include +#include +#include +#include +#include +#include #ifdef WIN32 #include @@ -38,6 +40,18 @@ #include #endif +#ifndef TOMAHAWK_HEADLESS + #include + #if defined(Q_WS_X11) + #include "tomahawkapp.h" + #include "tomahawkwindow.h" + #elif defined(Q_WS_WIN) + #include "tomahawkapp.h" + #include "tomahawkwindow.h" + #endif +#endif + + #include #include "utils/logger.h" #include "config.h" @@ -506,20 +520,30 @@ setNam( QNetworkAccessManager* nam ) } -#ifdef Q_WS_X11 -void -bringToFront() -{ -} +#ifndef TOMAHAWK_HEADLESS + #if defined(Q_WS_X11) + void + bringToFront() + { + } + #elif defined(Q_WS_WIN) + void + bringToFront() + { + } + #else + #ifndef Q_OS_MAC + void + bringToFront() + { + } + #endif + #endif #else - -#ifndef Q_OS_MAC -void -bringToFront() -{ -} -#endif - + void + bringToFront() + { + } #endif QPixmap