From 71b9391c20b85503b6663fde02c81e3a6c50f9ca Mon Sep 17 00:00:00 2001 From: csoler Date: Sun, 25 Jan 2009 14:00:45 +0000 Subject: [PATCH] Put emoticon images and .acs file into qrc image file git-svn-id: http://svn.code.sf.net/p/retroshare/code/trunk@945 b45a01b8-16f6-495d-af2f-9b41ad6348cc --- retroshare-gui/src/gui/chat/PopupChatDialog.cpp | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/retroshare-gui/src/gui/chat/PopupChatDialog.cpp b/retroshare-gui/src/gui/chat/PopupChatDialog.cpp index 4c3798796..3a0aab5dc 100644 --- a/retroshare-gui/src/gui/chat/PopupChatDialog.cpp +++ b/retroshare-gui/src/gui/chat/PopupChatDialog.cpp @@ -389,8 +389,12 @@ void PopupChatDialog::loadEmoticons2() void PopupChatDialog::loadEmoticons() { QString sm_codes; - QFile sm_file(QApplication::applicationDirPath() + "/emoticons/emotes.acs"); - sm_file.open(QIODevice::ReadOnly); + QFile sm_file(QString(":/emoticons/emotes.acs")); + if(!sm_file.open(QIODevice::ReadOnly)) + { + std::cout << "error opening ressource file" << std::endl ; + return ; + } sm_codes = sm_file.readAll(); sm_file.close(); sm_codes.remove("\n");