diff options
author | Ken Moore <ken@pcbsd.org> | 2014-12-18 07:47:48 -0500 |
---|---|---|
committer | Ken Moore <ken@pcbsd.org> | 2014-12-18 07:47:48 -0500 |
commit | 71c2fda95224f0a04316c5f1059628d33564ca43 (patch) | |
tree | ca74dbe49dd2f555e73893e7f5f06154d6dab763 /lumina-fm/main.cpp | |
parent | Oops, forgot to add knowledge of the new "Wine" app category to the userbutton. (diff) | |
download | lumina-71c2fda95224f0a04316c5f1059628d33564ca43.tar.gz lumina-71c2fda95224f0a04316c5f1059628d33564ca43.tar.bz2 lumina-71c2fda95224f0a04316c5f1059628d33564ca43.zip |
Commit a checkpoint on the conversion of Lumina to Qt5.
It is functional at the moment, but still has a few rough edges with regards to the X11 background interface (due to the move from XLib to XCB in Qt5). This reulst in some of the window manager interactions not behaving properly (such as sticky status on panels).
Diffstat (limited to 'lumina-fm/main.cpp')
-rw-r--r-- | lumina-fm/main.cpp | 23 |
1 files changed, 12 insertions, 11 deletions
diff --git a/lumina-fm/main.cpp b/lumina-fm/main.cpp index e2f70bc1..760ca7ad 100644 --- a/lumina-fm/main.cpp +++ b/lumina-fm/main.cpp @@ -1,11 +1,12 @@ #include <QTranslator> -#ifdef __FreeBSD__ +/*#ifdef __FreeBSD__ #include <qtsingleapplication.h> -#endif -#include <QtGui/QApplication> +#endif*/ +#include <QApplication> #include <QDebug> #include <QFile> -#include <QTextCodec> +#include <QStringList> +//#include <QTextCodec> #include "MainUI.h" #include <LuminaOS.h> @@ -25,32 +26,32 @@ int main(int argc, char ** argv) } } if(in.isEmpty()){ in << QDir::homePath(); } - #ifdef __FreeBSD__ + /*#ifdef __FreeBSD__ QtSingleApplication a(argc, argv); if( a.isRunning() ){ return !(a.sendMessage(in.join("\n"))); } - #else + #else*/ QApplication a(argc, argv); - #endif + qDebug() << "Loaded QApplication"; + //#endif a.setApplicationName("Insight File Manager"); LuminaThemeEngine themes(&a); //Load current Locale QTranslator translator; QLocale mylocale; QString langCode = mylocale.name(); - if ( ! QFile::exists(LOS::LuminaShare()+"i18n/lumina-fm_" + langCode + ".qm" ) ) langCode.truncate(langCode.indexOf("_")); translator.load( QString("lumina-fm_") + langCode, LOS::LuminaShare()+"i18n/" ); a.installTranslator( &translator ); qDebug() << "Locale:" << langCode; //Load current encoding for this locale - QTextCodec::setCodecForTr( QTextCodec::codecForLocale() ); //make sure to use the same codec - qDebug() << "Locale Encoding:" << QTextCodec::codecForLocale()->name(); + //QTextCodec::setCodecForTr( QTextCodec::codecForLocale() ); //make sure to use the same codec + //qDebug() << "Locale Encoding:" << QTextCodec::codecForLocale()->name(); MainUI w; - QObject::connect(&a, SIGNAL(messageReceived(const QString&)), &w, SLOT(slotSingleInstance(const QString&)) ); + //QObject::connect(&a, SIGNAL(messageReceived(const QString&)), &w, SLOT(slotSingleInstance(const QString&)) ); QObject::connect(&themes, SIGNAL(updateIcons()), &w, SLOT(setupIcons()) ); w.OpenDirs(in); w.show(); |