From 8ae3679aa1339ce9abee53adb69902bd6b7513dc Mon Sep 17 00:00:00 2001 From: George Hazan Date: Mon, 25 Jul 2016 10:31:04 +0000 Subject: hello, Unix. phase 1: removing _T() git-svn-id: http://svn.miranda-ng.org/main/trunk@17127 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c --- plugins/MirandaG15/src/CAppletManager.cpp | 154 ++++++++++----------- plugins/MirandaG15/src/CChatScreen.cpp | 30 ++-- plugins/MirandaG15/src/CConfig.cpp | 14 +- plugins/MirandaG15/src/CContactList.cpp | 46 +++--- plugins/MirandaG15/src/CCreditsScreen.cpp | 60 ++++---- plugins/MirandaG15/src/CEvent.h | 4 +- plugins/MirandaG15/src/CEventScreen.cpp | 4 +- plugins/MirandaG15/src/CNotificationScreen.cpp | 12 +- plugins/MirandaG15/src/CScreen.cpp | 4 +- plugins/MirandaG15/src/CScreensaverScreen.cpp | 24 ++-- .../src/LCDFramework/CLCDConnectionLogitech.cpp | 14 +- plugins/MirandaG15/src/LCDFramework/CLCDDevice.h | 2 +- plugins/MirandaG15/src/LCDFramework/CLCDGfx.cpp | 12 +- plugins/MirandaG15/src/LCDFramework/CLCDInput.cpp | 24 ++-- plugins/MirandaG15/src/LCDFramework/CLCDLabel.cpp | 12 +- .../src/LCDFramework/CLCDOutputManager.cpp | 6 +- .../MirandaG15/src/LCDFramework/CLCDTextLog.cpp | 12 +- .../MirandaG15/src/LCDFramework/CLCDTextObject.cpp | 2 +- plugins/MirandaG15/src/LCDFramework/misc.cpp | 2 +- plugins/MirandaG15/src/Miranda.cpp | 18 +-- 20 files changed, 228 insertions(+), 228 deletions(-) (limited to 'plugins/MirandaG15') diff --git a/plugins/MirandaG15/src/CAppletManager.cpp b/plugins/MirandaG15/src/CAppletManager.cpp index 1ce1f559bb..b1be837708 100644 --- a/plugins/MirandaG15/src/CAppletManager.cpp +++ b/plugins/MirandaG15/src/CAppletManager.cpp @@ -440,7 +440,7 @@ tstring CAppletManager::GetContactDisplayname(MCONTACT hContact, bool bShortened tstring strNick = GetContactDisplayname(hContact, false); if (strNick.length() > (tstring::size_type)CConfig::GetIntSetting(NOTIFY_NICKCUTOFF_OFFSET)) - return strNick.erase(CConfig::GetIntSetting(NOTIFY_NICKCUTOFF_OFFSET)) + _T("..."); + return strNick.erase(CConfig::GetIntSetting(NOTIFY_NICKCUTOFF_OFFSET)) + L"..."; return strNick; } @@ -453,7 +453,7 @@ tstring CAppletManager::GetContactGroup(MCONTACT hContact) DBVARIANT dbv; int res = db_get_ts(hContact, "CList", "Group", &dbv); - tstring strGroup = _T(""); + tstring strGroup = L""; if (!res) strGroup = dbv.ptszVal; @@ -536,15 +536,15 @@ tstring CAppletManager::GetFormattedTimestamp(tm *tm_time) if (tm_time->tm_mday != tm_now.tm_mday || tm_time->tm_mon != tm_now.tm_mon) { if (CConfig::GetBoolSetting(TIMESTAMP_SECONDS)) - _tcsftime(buffer, 128, _T("[%x %H:%M:%S]"), tm_time); + _tcsftime(buffer, 128, L"[%x %H:%M:%S]", tm_time); else - _tcsftime(buffer, 128, _T("[%x %H:%M]"), tm_time); + _tcsftime(buffer, 128, L"[%x %H:%M]", tm_time); } else { if (CConfig::GetBoolSetting(TIMESTAMP_SECONDS)) - _tcsftime(buffer, 128, _T("[%H:%M:%S]"), tm_time); + _tcsftime(buffer, 128, L"[%H:%M:%S]", tm_time); else - _tcsftime(buffer, 128, _T("[%H:%M]"), tm_time); + _tcsftime(buffer, 128, L"[%H:%M]", tm_time); } return toTstring(buffer); @@ -555,7 +555,7 @@ tstring CAppletManager::GetFormattedTimestamp(tm *tm_time) //************************************************************************ void CAppletManager::HandleEvent(CEvent *pEvent) { - TRACE(_T("<< Event: %i\n"), (int)pEvent->eType); + TRACE(L"<< Event: %i\n", (int)pEvent->eType); // check if the event's timestamp needs to be set if (!pEvent->bTime) { @@ -625,7 +625,7 @@ void CAppletManager::UpdateMessageJobs() Event.hValue = (*iter)->hEvent; Event.hContact = (*iter)->hContact; Event.iValue = ACKRESULT_FAILED; - Event.strValue = TranslateString(_T("Timeout: No response from contact/server")); + Event.strValue = TranslateString(L"Timeout: No response from contact/server"); HandleEvent(&Event); @@ -764,11 +764,11 @@ MEVENT CAppletManager::SendMessageToContact(MCONTACT hContact, tstring strMessag GCDEST gcd = { szProto, 0, GC_EVENT_SENDMESSAGE }; gcd.ptszID = dbv.ptszVal; - tstring strID = tstring(gcd.ptszID) + _T(" - ") + tstring(_A2T(toNarrowString(pIRCCon->strNetwork).c_str())); + tstring strID = tstring(gcd.ptszID) + L" - " + tstring(_A2T(toNarrowString(pIRCCon->strNetwork).c_str())); gcd.ptszID = (LPTSTR)strID.c_str(); GCEVENT gce = { sizeof(gce), &gcd }; - gce.ptszStatus = _T(""); + gce.ptszStatus = L""; gce.ptszText = (LPTSTR)strAscii.c_str(); gce.time = time(NULL); gce.bIsMe = true; @@ -887,42 +887,42 @@ bool CAppletManager::TranslateDBEvent(CEvent *pEvent, WPARAM hContact, LPARAM hd pEvent->bNotification = true; } - pEvent->strDescription = strName + _T(": ") + pEvent->strValue; - pEvent->strSummary = TranslateString(_T("New message from %s"), strName.c_str()); + pEvent->strDescription = strName + L": " + pEvent->strValue; + pEvent->strSummary = TranslateString(L"New message from %s", strName.c_str()); break; case EVENTTYPE_URL: if (CConfig::GetBoolSetting(NOTIFY_URL)) pEvent->bNotification = true; pEvent->eType = EVENT_URL; - pEvent->strDescription = TranslateString(_T("Incoming URL from %s"), strName.c_str()); + pEvent->strDescription = TranslateString(L"Incoming URL from %s", strName.c_str()); break; case EVENTTYPE_CONTACTS: if (CConfig::GetBoolSetting(NOTIFY_CONTACTS)) pEvent->bNotification = true; - pEvent->strDescription = TranslateString(_T("Incoming contacts from %s"), strName.c_str()); + pEvent->strDescription = TranslateString(L"Incoming contacts from %s", strName.c_str()); pEvent->eType = EVENT_CONTACTS; break; case EVENTTYPE_ADDED: if (CConfig::GetBoolSetting(NOTIFY_CONTACTS)) pEvent->bNotification = true; - pEvent->strDescription = TranslateString(_T("You were added by %s"), strName.c_str()); + pEvent->strDescription = TranslateString(L"You were added by %s", strName.c_str()); pEvent->eType = EVENT_ADDED; break; case EVENTTYPE_AUTHREQUEST: if (CConfig::GetBoolSetting(NOTIFY_CONTACTS)) pEvent->bNotification = true; - pEvent->strDescription = TranslateString(_T("Incoming Authrequest!")); + pEvent->strDescription = TranslateString(L"Incoming Authrequest!"); pEvent->eType = EVENT_AUTHREQUEST; break; case EVENTTYPE_FILE: if (CConfig::GetBoolSetting(NOTIFY_FILE)) pEvent->bNotification = true; - pEvent->strDescription = TranslateString(_T("Incoming file from %s"), strName.c_str()); + pEvent->strDescription = TranslateString(L"Incoming file from %s", strName.c_str()); pEvent->eType = EVENT_FILE; break; default: @@ -932,7 +932,7 @@ bool CAppletManager::TranslateDBEvent(CEvent *pEvent, WPARAM hContact, LPARAM hd if (CConfig::GetBoolSetting(NOTIFY_SHOWPROTO)) { char *szProto = GetContactProto(pEvent->hContact); - pEvent->strDescription = _T("(") + toTstring(szProto) + _T(") ") + pEvent->strDescription; + pEvent->strDescription = L"(" + toTstring(szProto) + L") " + pEvent->strDescription; } // Clean up @@ -946,28 +946,28 @@ bool CAppletManager::TranslateDBEvent(CEvent *pEvent, WPARAM hContact, LPARAM hd tstring CAppletManager::StripIRCFormatting(tstring strText) { tstring::size_type start = 0, i = 0; - tstring strEntity = _T(""); - tstring strReplace = _T(""); + tstring strEntity = L""; + tstring strReplace = L""; while (i < strText.length()) { - start = strText.find(_T("%"), i); + start = strText.find(L"%", i); if (start != string::npos && start < strText.length() - 1) { strEntity = strText[start + 1]; - if (strEntity == _T("%")) { - strText.replace(start, 2, _T("%")); + if (strEntity == L"%") { + strText.replace(start, 2, L"%"); i = start + 1; } /* - else if(strEntity == _T("b") || strEntity == _T("B") || - strEntity == _T("i") || strEntity == _T("I") || - strEntity ==_T("u") || strEntity == _T("U") || - strEntity == _T("C") ||strEntity == _T("F")) + else if(strEntity == L"b" || strEntity == L"B" || + strEntity == L"i" || strEntity == L"I" || + strEntity ==L"u" || strEntity == L"U" || + strEntity == L"C" ||strEntity == L"F") { strText.erase(start,2); i = start; } */ - else if (strEntity == _T("c") || strEntity == _T("f")) { + else if (strEntity == L"c" || strEntity == L"f") { strText.erase(start, 4); i = start; } @@ -1004,7 +1004,7 @@ CIRCConnection *CAppletManager::CreateIRCConnection(tstring strProtocol) { CIRCConnection *pIRCCon = new CIRCConnection(); pIRCCon->strProtocol = strProtocol; - pIRCCon->strNetwork = _T(""); + pIRCCon->strNetwork = L""; m_vIRCConnections.push_back(pIRCCon); @@ -1112,24 +1112,24 @@ int CAppletManager::HookChatInbound(WPARAM, LPARAM lParam) GCDEST *gcd; if (gce == NULL || (gcd = gce->pDest) == NULL) { - TRACE(_T("<< [%s] skipping invalid event\n")); + TRACE(L"<< [%s] skipping invalid event\n"); return 0; } - TRACE(_T("<< [%s:%s] event %04X\n"), toTstring(gcd->pszModule).c_str(), gcd->ptszID, gcd->iType); + TRACE(L"<< [%s:%s] event %04X\n", toTstring(gcd->pszModule).c_str(), gcd->ptszID, gcd->iType); // get the matching irc connection entry CIRCConnection *pIRCCon = CAppletManager::GetInstance()->GetIRCConnection(toTstring(gcd->pszModule)); if (!pIRCCon) { - TRACE(_T("<< [%s] connection not found, skipping event\n"), toTstring(gcd->pszModule).c_str()); + TRACE(L"<< [%s] connection not found, skipping event\n", toTstring(gcd->pszModule).c_str()); return 0; } // fetch the network name if (gcd->iType == GC_EVENT_CHANGESESSIONAME) { - if (gcd->ptszID && !mir_tstrcmpi(gcd->ptszID, _T("Network log"))) { + if (gcd->ptszID && !mir_tstrcmpi(gcd->ptszID, L"Network log")) { pIRCCon->strNetwork = toTstring(gce->ptszText); - TRACE(_T("\t Found network identifier: %s\n"), pIRCCon->strNetwork.c_str()); + TRACE(L"\t Found network identifier: %s\n", pIRCCon->strNetwork.c_str()); return 0; } } @@ -1149,8 +1149,8 @@ int CAppletManager::HookChatInbound(WPARAM, LPARAM lParam) if (pos != tstring::npos) strChannel = strChannel.substr(0, pos - 1); else { - if (mir_tstrcmpi(gcd->ptszID, _T("Network log"))) - TRACE(_T("\t WARNING: ignoring unknown event!\n")); + if (mir_tstrcmpi(gcd->ptszID, L"Network log")) + TRACE(L"\t WARNING: ignoring unknown event!\n"); return 0; } pHistory = CAppletManager::GetInstance()->GetIRCHistoryByName(pIRCCon->strProtocol, strChannel); @@ -1165,7 +1165,7 @@ int CAppletManager::HookChatInbound(WPARAM, LPARAM lParam) Event.hContact = pHistory->hContact; } else if (gcd->iType != GC_EVENT_INFORMATION) { - TRACE(_T("\t WARNING: ignoring unknown event!\n")); + TRACE(L"\t WARNING: ignoring unknown event!\n"); return 0; } else @@ -1176,7 +1176,7 @@ int CAppletManager::HookChatInbound(WPARAM, LPARAM lParam) if (gcd->iType == GC_EVENT_JOIN && pHistory) pHistory->LUsers.push_back(toTstring(gce->ptszNick)); - TRACE(_T("\t Chatroom is hidden, skipping event!\n")); + TRACE(L"\t Chatroom is hidden, skipping event!\n"); return 0; } @@ -1185,17 +1185,17 @@ int CAppletManager::HookChatInbound(WPARAM, LPARAM lParam) tstring strStatus = toTstring(gce->ptszStatus); if (CConfig::GetBoolSetting(NOTIFY_NICKCUTOFF) && strNick.length() > (tstring::size_type)CConfig::GetIntSetting(NOTIFY_NICKCUTOFF_OFFSET)) - strNick = strNick.erase(CConfig::GetIntSetting(NOTIFY_NICKCUTOFF_OFFSET)) + _T("..."); + strNick = strNick.erase(CConfig::GetIntSetting(NOTIFY_NICKCUTOFF_OFFSET)) + L"..."; - TRACE(_T("\t Handling event...\t")); + TRACE(L"\t Handling event...\t"); switch (gcd->iType) { case GC_EVENT_INFORMATION: if (CConfig::GetBoolSetting(NOTIFY_IRC_CHANNEL)) Event.bNotification = true; - if (strText.find(_T("CTCP")) == 0) - Event.strValue = _T("--> ") + strText; + if (strText.find(L"CTCP") == 0) + Event.strValue = L"--> " + strText; else Event.strValue = strText; @@ -1203,12 +1203,12 @@ int CAppletManager::HookChatInbound(WPARAM, LPARAM lParam) case GC_EVENT_ACTION: if (CConfig::GetBoolSetting(NOTIFY_IRC_EMOTES)) Event.bNotification = true; - Event.strValue = strNick + _T(" ") + strText; + Event.strValue = strNick + L" " + strText; break; case GC_EVENT_MESSAGE: if (CConfig::GetBoolSetting(NOTIFY_IRC_MESSAGES)) Event.bNotification = true; - Event.strValue = strNick + _T(": ") + strText; + Event.strValue = strNick + L": " + strText; break; case GC_EVENT_JOIN: // Add the user to the list @@ -1219,7 +1219,7 @@ int CAppletManager::HookChatInbound(WPARAM, LPARAM lParam) // Skip join event for user if (gce->bIsMe) return 0; - Event.strValue = TranslateString(_T("%s has joined the channel"), strNick.c_str()); + Event.strValue = TranslateString(L"%s has joined the channel", strNick.c_str()); break; case GC_EVENT_PART: @@ -1227,7 +1227,7 @@ int CAppletManager::HookChatInbound(WPARAM, LPARAM lParam) if (CConfig::GetBoolSetting(NOTIFY_IRC_USERS)) Event.bNotification = true; tstring strFullNick = toTstring(gce->ptszNick); - Event.strValue = TranslateString(strText.empty() ? _T("%s has left") : _T("%s has left: %s"), strNick.c_str(), strText.c_str()); + Event.strValue = TranslateString(strText.empty() ? L"%s has left" : L"%s has left: %s", strNick.c_str(), strText.c_str()); if (pHistory) { // Remove the user from the list list::iterator iter = pHistory->LUsers.begin(); @@ -1244,12 +1244,12 @@ int CAppletManager::HookChatInbound(WPARAM, LPARAM lParam) case GC_EVENT_QUIT: if (CConfig::GetBoolSetting(NOTIFY_IRC_USERS)) Event.bNotification = true; - Event.strValue = TranslateString(strText.empty() ? _T("%s has disconnected") : _T("%s has disconnected: %s"), strNick.c_str(), strText.c_str()); + Event.strValue = TranslateString(strText.empty() ? L"%s has disconnected" : L"%s has disconnected: %s", strNick.c_str(), strText.c_str()); break; case GC_EVENT_KICK: if (CConfig::GetBoolSetting(NOTIFY_IRC_USERS)) Event.bNotification = true; - Event.strValue = TranslateString(_T("%s has kicked %s: %s"), strStatus.c_str(), strNick.c_str(), strText.c_str()); + Event.strValue = TranslateString(L"%s has kicked %s: %s", strStatus.c_str(), strNick.c_str(), strText.c_str()); break; case GC_EVENT_NICK: { @@ -1258,9 +1258,9 @@ int CAppletManager::HookChatInbound(WPARAM, LPARAM lParam) tstring strFullNick = toTstring(gce->ptszNick); if (CConfig::GetBoolSetting(NOTIFY_NICKCUTOFF) && strText.length() > (tstring::size_type)CConfig::GetIntSetting(NOTIFY_NICKCUTOFF_OFFSET)) - strText = strText.erase(CConfig::GetIntSetting(NOTIFY_NICKCUTOFF_OFFSET)) + _T("..."); + strText = strText.erase(CConfig::GetIntSetting(NOTIFY_NICKCUTOFF_OFFSET)) + L"..."; - Event.strValue = TranslateString(_T("%s is now known as %s"), strNick.c_str(), strText.c_str()); + Event.strValue = TranslateString(L"%s is now known as %s", strNick.c_str(), strText.c_str()); if (pHistory) { // change the nick in the userlist list::iterator iter = pHistory->LUsers.begin(); @@ -1275,12 +1275,12 @@ int CAppletManager::HookChatInbound(WPARAM, LPARAM lParam) case GC_EVENT_NOTICE: if (CConfig::GetBoolSetting(NOTIFY_IRC_NOTICES)) Event.bNotification = true; - Event.strValue = TranslateString(_T("Notice from %s: %s"), strNick.c_str(), strText.c_str()); + Event.strValue = TranslateString(L"Notice from %s: %s", strNick.c_str(), strText.c_str()); break; case GC_EVENT_TOPIC: if (CConfig::GetBoolSetting(NOTIFY_IRC_CHANNEL)) Event.bNotification = true; - Event.strValue = TranslateString(_T("Topic is now '%s' (set by %s)"), strText.c_str(), strNick.c_str()); + Event.strValue = TranslateString(L"Topic is now '%s' (set by %s)", strText.c_str(), strNick.c_str()); break; case GC_EVENT_ADDSTATUS: { @@ -1288,9 +1288,9 @@ int CAppletManager::HookChatInbound(WPARAM, LPARAM lParam) Event.bNotification = true; tstring strNick2 = toTstring(gce->ptszStatus); if (CConfig::GetBoolSetting(NOTIFY_NICKCUTOFF) && strNick2.length() > (tstring::size_type)CConfig::GetIntSetting(NOTIFY_NICKCUTOFF_OFFSET)) - strNick2 = strNick2.erase(CConfig::GetIntSetting(NOTIFY_NICKCUTOFF_OFFSET)) + _T("..."); + strNick2 = strNick2.erase(CConfig::GetIntSetting(NOTIFY_NICKCUTOFF_OFFSET)) + L"..."; - Event.strValue = TranslateString(_T("%s enables '%s' for %s"), strText.c_str(), strNick2.c_str(), strNick.c_str()); + Event.strValue = TranslateString(L"%s enables '%s' for %s", strText.c_str(), strNick2.c_str(), strNick.c_str()); break; } case GC_EVENT_REMOVESTATUS: @@ -1299,13 +1299,13 @@ int CAppletManager::HookChatInbound(WPARAM, LPARAM lParam) Event.bNotification = true; tstring strNick2 = toTstring(gce->ptszStatus); if (CConfig::GetBoolSetting(NOTIFY_NICKCUTOFF) && strNick2.length() > (tstring::size_type)CConfig::GetIntSetting(NOTIFY_NICKCUTOFF_OFFSET)) - strNick2 = strNick2.erase(CConfig::GetIntSetting(NOTIFY_NICKCUTOFF_OFFSET)) + _T("..."); + strNick2 = strNick2.erase(CConfig::GetIntSetting(NOTIFY_NICKCUTOFF_OFFSET)) + L"..."; - Event.strValue = TranslateString(_T("%s disables '%s' for %s"), strText.c_str(), strNick2.c_str(), strNick.c_str()); + Event.strValue = TranslateString(L"%s disables '%s' for %s", strText.c_str(), strNick2.c_str(), strNick.c_str()); break; } default: - TRACE(_T("OK!\n")); + TRACE(L"OK!\n"); return 0; } if (gce->bIsMe || gcd->ptszID == NULL) @@ -1348,8 +1348,8 @@ int CAppletManager::HookChatInbound(WPARAM, LPARAM lParam) Event.hContact = (*iter)->hContact; tstring strName = CAppletManager::GetContactDisplayname((*iter)->hContact, true); - Event.strDescription = strName + _T(" - ") + Event.strValue; - Event.strSummary = _T("(") + toTstring(gcd->pszModule) + _T(") ") + strName; + Event.strDescription = strName + L" - " + Event.strValue; + Event.strSummary = L"(" + toTstring(gcd->pszModule) + L") " + strName; CAppletManager::GetInstance()->HandleEvent(&Event); break; } @@ -1358,26 +1358,26 @@ int CAppletManager::HookChatInbound(WPARAM, LPARAM lParam) iter++; } } - TRACE(_T("OK!\n")); + TRACE(L"OK!\n"); return 0; } else if (gcd->ptszID != NULL) { - TRACE(_T("OK!\n")); + TRACE(L"OK!\n"); return 0; } if (pHistory) { tstring strChannel = pHistory->strChannel; if (CConfig::GetBoolSetting(NOTIFY_CHANNELCUTOFF) && strChannel.length() > CConfig::GetIntSetting(NOTIFY_CHANNELCUTOFF_OFFSET)) { - strChannel = strChannel.erase(CConfig::GetIntSetting(NOTIFY_CHANNELCUTOFF_OFFSET)) + _T("..."); + strChannel = strChannel.erase(CConfig::GetIntSetting(NOTIFY_CHANNELCUTOFF_OFFSET)) + L"..."; } - Event.strDescription = strChannel + _T(" - ") + Event.strValue; - Event.strSummary = _T("(") + toTstring(gcd->pszModule) + _T(") ") + pHistory->strChannel; + Event.strDescription = strChannel + L" - " + Event.strValue; + Event.strSummary = L"(" + toTstring(gcd->pszModule) + L") " + pHistory->strChannel; } else Event.strDescription = Event.strValue; - TRACE(_T("OK!\n")); + TRACE(L"OK!\n"); CAppletManager::GetInstance()->HandleEvent(&Event); @@ -1475,7 +1475,7 @@ int CAppletManager::HookStatusChanged(WPARAM wParam, LPARAM lParam) Event.eType = EVENT_SIGNED_ON; if (pIRCCon && db_get_b(Event.hContact, szProto, "ChatRoom", 0) != 0) { - Event.strDescription = TranslateString(_T("Joined %s"), strName.c_str()); + Event.strDescription = TranslateString(L"Joined %s", strName.c_str()); DBVARIANT dbv; if (db_get_ts(Event.hContact, szProto, "Nick", &dbv)) @@ -1484,7 +1484,7 @@ int CAppletManager::HookStatusChanged(WPARAM wParam, LPARAM lParam) db_free(&dbv); } else - Event.strDescription = TranslateString(_T("%s signed on (%s)"), strName.c_str(), Event.strValue.c_str()); + Event.strDescription = TranslateString(L"%s signed on (%s)", strName.c_str(), Event.strValue.c_str()); } // Contact signed off else if (iStatus == ID_STATUS_OFFLINE && iOldStatus != ID_STATUS_OFFLINE) { @@ -1493,12 +1493,12 @@ int CAppletManager::HookStatusChanged(WPARAM wParam, LPARAM lParam) Event.eType = EVENT_SIGNED_OFF; if (pIRCCon && db_get_b(Event.hContact, szProto, "ChatRoom", 0) != 0) { - Event.strDescription = TranslateString(_T("Left %s"), strName.c_str()); + Event.strDescription = TranslateString(L"Left %s", strName.c_str()); // delete IRC-Channel history CAppletManager::GetInstance()->DeleteIRCHistory(Event.hContact); } else - Event.strDescription = TranslateString(_T("%s signed off"), strName.c_str()); + Event.strDescription = TranslateString(L"%s signed off", strName.c_str()); } // Contact changed status else if (iStatus != iOldStatus) { @@ -1506,18 +1506,18 @@ int CAppletManager::HookStatusChanged(WPARAM wParam, LPARAM lParam) Event.bNotification = true; Event.eType = EVENT_STATUS; - Event.strDescription = TranslateString(_T("%s is now %s"), strName.c_str(), Event.strValue.c_str()); + Event.strDescription = TranslateString(L"%s is now %s", strName.c_str(), Event.strValue.c_str()); } // ignore remaining events else return 0; if (CConfig::GetBoolSetting(NOTIFY_SHOWPROTO)) - Event.strDescription = _T("(") + strProto + _T(") ") + Event.strDescription; + Event.strDescription = L"(" + strProto + L") " + Event.strDescription; - Event.strSummary = TranslateString(_T("Contactlist event")); + Event.strSummary = TranslateString(L"Contactlist event"); // Block notifications after connecting/disconnecting if (pProtocolData->iStatus == ID_STATUS_OFFLINE || (DWORD)pProtocolData->lTimeStamp + PROTOCOL_NOTIFY_DELAY > GetTickCount()) @@ -1554,7 +1554,7 @@ int CAppletManager::HookProtoAck(WPARAM, LPARAM lParam) if (pAck->lParam != 0) Event.strValue = toTstring((char*)pAck->lParam); else - Event.strValue = _T(""); + Event.strValue = L""; if (Event.iValue == ACKRESULT_SUCCESS) CAppletManager::GetInstance()->FinishMessageJob((*iter)); @@ -1576,7 +1576,7 @@ int CAppletManager::HookProtoAck(WPARAM, LPARAM lParam) tstring strProto = toTstring(pAck->szModule); // ignore metacontacts status changes - if (toLower(strProto) == _T("metacontacts")) + if (toLower(strProto) == L"metacontacts") return 0; CProtocolData *pProtoData = CAppletManager::GetInstance()->GetProtocolData(strProto); @@ -1610,8 +1610,8 @@ int CAppletManager::HookProtoAck(WPARAM, LPARAM lParam) // set the event description / summary tstring strStatus = toTstring(pcli->pfnGetStatusModeDescription(iNewStatus, 0)); - Event.strDescription = _T("(") + Event.strValue + _T(") ") + TranslateString(_T("You are now %s"), strStatus.c_str()); - Event.strSummary = TranslateString(_T("Protocol status change")); + Event.strDescription = L"(" + Event.strValue + L") " + TranslateString(L"You are now %s", strStatus.c_str()); + Event.strSummary = TranslateString(L"Protocol status change"); if (Event.eType != EVENT_PROTO_STATUS) pProtoData->lTimeStamp = GetTickCount(); @@ -1649,7 +1649,7 @@ int CAppletManager::HookContactDeleted(WPARAM wParam, LPARAM) tstring strName = CAppletManager::GetContactDisplayname(Event.hContact, true); - Event.strDescription = TranslateString(_T("%s was deleted from contactlist!"), strName.c_str()); + Event.strDescription = TranslateString(L"%s was deleted from contactlist!", strName.c_str()); CAppletManager::GetInstance()->HandleEvent(&Event); return 0; diff --git a/plugins/MirandaG15/src/CChatScreen.cpp b/plugins/MirandaG15/src/CChatScreen.cpp index 6a1224afe6..34c228c697 100644 --- a/plugins/MirandaG15/src/CChatScreen.cpp +++ b/plugins/MirandaG15/src/CChatScreen.cpp @@ -41,22 +41,22 @@ bool CChatScreen::Initialize() // other attributes m_InfoText.SetAlignment(DT_CENTER); m_InfoText.SetWordWrap(TRUE); - m_InfoText.SetText(_T("")); + m_InfoText.SetText(L""); m_InfoText.Show(0); m_UserName.SetAlignment(DT_CENTER); m_UserName.SetWordWrap(TRUE); - m_UserName.SetText(_T("Proto")); + m_UserName.SetText(L"Proto"); m_UserStatus.SetAlignment(DT_LEFT); m_UserStatus.SetWordWrap(TRUE); - m_UserStatus.SetText(_T("Status")); + m_UserStatus.SetText(L"Status"); m_UserProto.SetAlignment(DT_RIGHT); m_UserProto.SetWordWrap(TRUE); - m_UserProto.SetText(_T("User")); + m_UserProto.SetText(L"User"); m_Input.Show(0); @@ -170,11 +170,11 @@ void CChatScreen::UpdateLabels() char *szProto = GetContactProto(m_hContact); m_iStatus = ID_STATUS_OFFLINE; - tstring strProto = _T(""); - tstring strStatus = _T(""); + tstring strProto = L""; + tstring strStatus = L""; if(szProto != NULL) { - strProto = _T("(") + toTstring(szProto) + _T(")"); + strProto = L"(" + toTstring(szProto) + L")"; m_iStatus = db_get_w(m_hContact,szProto,"Status",ID_STATUS_OFFLINE); } @@ -186,7 +186,7 @@ void CChatScreen::UpdateLabels() m_UserStatus.SetText(strStatus.c_str()); if(m_bContactTyping && CConfig::GetBoolSetting(SESSION_SHOWTYPING)) - m_UserProto.SetText(CAppletManager::TranslateString(_T("typing.."))); + m_UserProto.SetText(CAppletManager::TranslateString(L"typing..")); else m_UserProto.SetText(strProto.c_str()); } @@ -267,7 +267,7 @@ void CChatScreen::LoadHistory() time(&now); localtime_s(&tm_now,&now); - AddIncomingMessage(CAppletManager::TranslateString(_T("IRC-Chatroom support is disabled!\nYou need to install the patched IRC.dll (see the readme) to use IRC-Chatrooms on the LCD")),&tm_now,true); + AddIncomingMessage(CAppletManager::TranslateString(L"IRC-Chatroom support is disabled!\nYou need to install the patched IRC.dll (see the readme) to use IRC-Chatrooms on the LCD"),&tm_now,true); } else { @@ -416,9 +416,9 @@ bool CChatScreen::Draw(CLCDGfx *pGfx) //************************************************************************ void CChatScreen::AddOutgoingMessage(tstring strMessage,tm *time,bool bIRC) { - tstring strPrefix = bIRC?_T(""):_T(">> "); + tstring strPrefix = bIRC?L"":L">> "; if(CConfig::GetBoolSetting(SESSION_TIMESTAMPS)) - strPrefix += CAppletManager::GetFormattedTimestamp(time) + _T(" "); + strPrefix += CAppletManager::GetFormattedTimestamp(time) + L" "; // adjust the scroll mode m_TextLog.SetAutoscrollMode(SCROLL_LINE); @@ -433,9 +433,9 @@ void CChatScreen::AddOutgoingMessage(tstring strMessage,tm *time,bool bIRC) //************************************************************************ void CChatScreen::AddIncomingMessage(tstring strMessage,tm *time,bool bIRC) { - tstring strPrefix = bIRC?_T(""):_T("<< "); + tstring strPrefix = bIRC?L"":L"<< "; if(CConfig::GetBoolSetting(SESSION_TIMESTAMPS)) - strPrefix += CAppletManager::GetFormattedTimestamp(time) + _T(" "); + strPrefix += CAppletManager::GetFormattedTimestamp(time) + L" "; // adjust the scroll mode @@ -495,7 +495,7 @@ void CChatScreen::SendCurrentMessage() m_Input.DeactivateInput(); - m_InfoText.SetText(CAppletManager::TranslateString(_T("Sending message..."))); + m_InfoText.SetText(CAppletManager::TranslateString(L"Sending message...")); m_InfoText.Show(1); m_Input.Show(0); @@ -621,7 +621,7 @@ void CChatScreen::OnEventReceived(CEvent *pEvent) if(pEvent->iValue == ACKRESULT_SUCCESS) DeactivateMessageMode(); else - InvalidateMessageMode(pEvent->strValue.empty()?CAppletManager::TranslateString(_T("Could not send the message!")):pEvent->strValue); + InvalidateMessageMode(pEvent->strValue.empty()?CAppletManager::TranslateString(L"Could not send the message!"):pEvent->strValue); break; case EVENT_IRC_SENT: // Add the message to the log diff --git a/plugins/MirandaG15/src/CConfig.cpp b/plugins/MirandaG15/src/CConfig.cpp index 337cad2886..46cd677105 100644 --- a/plugins/MirandaG15/src/CConfig.cpp +++ b/plugins/MirandaG15/src/CConfig.cpp @@ -127,9 +127,9 @@ void CConfig::LoadSettings() pProtoFilter = new CProtoFilter(); pProtoFilter->strName = toTstring(ppAccounts[i]->szModuleName); - strSetting = _T("ProtoFilter_") + pProtoFilter->strName; + strSetting = L"ProtoFilter_" + pProtoFilter->strName; pProtoFilter->bNotificationFilter = db_get_dw(NULL, "MirandaG15", toNarrowString(strSetting).c_str(), 1) != 0; - strSetting = _T("ProtoCListFilter_") + pProtoFilter->strName; + strSetting = L"ProtoCListFilter_" + pProtoFilter->strName; pProtoFilter->bContactlistFilter = db_get_dw(NULL, "MirandaG15", toNarrowString(strSetting).c_str(), 1) != 0; m_ProtoList.push_back(pProtoFilter); } @@ -215,11 +215,11 @@ void CConfig::SaveSettings() // save protocol specific settings vector::iterator iter = m_ProtoList.begin(); - tstring strSetting = _T(""); + tstring strSetting = L""; while (iter != m_ProtoList.end()) { - strSetting = _T("ProtoFilter_") + (*iter)->strName; + strSetting = L"ProtoFilter_" + (*iter)->strName; db_set_dw(NULL, "MirandaG15", toNarrowString(strSetting).c_str(), (*iter)->bNotificationFilter); - strSetting = _T("ProtoCListFilter_") + (*iter)->strName; + strSetting = L"ProtoCListFilter_" + (*iter)->strName; db_set_dw(NULL, "MirandaG15", toNarrowString(strSetting).c_str(), (*iter)->bContactlistFilter); iter++; } @@ -338,7 +338,7 @@ void CConfig::LoadFontSettings(int iFont) mir_snprintf(szSetting, "Font%dName", iFont); DBVARIANT dbv; if (db_get_ts(NULL, "MirandaG15", szSetting, &dbv)) - mir_tstrcpy(m_logfont[iFont].lfFaceName, _T("Small Fonts")); + mir_tstrcpy(m_logfont[iFont].lfFaceName, L"Small Fonts"); else { mir_tstrcpy(m_logfont[iFont].lfFaceName, dbv.ptszVal); db_free(&dbv); @@ -453,7 +453,7 @@ INT_PTR CALLBACK CConfig::AppearanceDlgProc(HWND hwndDlg, UINT uMsg, WPARAM wPar DeleteObject(m_hSampleFont[iFont]); m_hSampleFont[iFont] = CreateFontIndirect(&m_templogfont[iFont]); SendDlgItemMessage(hwndDlg, CConfig::GetSampleField(iFont), WM_SETFONT, (WPARAM)m_hSampleFont[iFont], (LPARAM)true); - TRACE(_T("Font selected!")); + TRACE(L"Font selected!"); } } if (LOWORD(wParam) == IDC_DEVICE && SendDlgItemMessage(hwndDlg, IDC_DEVICE, CB_GETCURSEL, 0, 0) != m_aiIntSettings[DEVICE]) { diff --git a/plugins/MirandaG15/src/CContactList.cpp b/plugins/MirandaG15/src/CContactList.cpp index d15d1fcc5f..6e6f42593b 100644 --- a/plugins/MirandaG15/src/CContactList.cpp +++ b/plugins/MirandaG15/src/CContactList.cpp @@ -78,7 +78,7 @@ CContactListEntry *CContactList::GetContactData(CListEntrystrName; + strGroup = L""; + strGroup += (strGroup.empty()?L"":L"\\")+psContact->strName; pGroup = GetGroupByString(strGroup); if(pGroup == NULL) pGroup = AddGroupByString(strGroup); @@ -195,7 +195,7 @@ bool CContactList::IsVisible(CContactListEntry *pEntry) { return false; } - if(pEntry->strProto != _T("MetaContacts")) { + if(pEntry->strProto != L"MetaContacts") { if(pEntry->iStatus == ID_STATUS_OFFLINE && CConfig::GetBoolSetting(CLIST_HIDEOFFLINE)) { return false; } @@ -321,7 +321,7 @@ CListContainer *CContactList::GetGroupByS CListContainer *CContactList::AddGroupByString(tstring strGroup) { tstring strParse = strGroup; - tstring strPath = _T(""); + tstring strPath = L""; CListContainer *pGroup = (CListContainer*)this; CListContainer *pGroup2 = NULL; @@ -344,7 +344,7 @@ CListContainer *CContactList::AddGroupByS pGroup = pGroup2; } ASSERT(pGroup != NULL); - strPath += _T("\\"); + strPath += L"\\"; } strPath += strParse; if(pGroup2 = FindGroupInGroup(strParse,pGroup)) @@ -402,11 +402,11 @@ void CContactList::DrawEntry(CLCDGfx *pGfx,CContactListEntry *pEntry,bool bSelec if(pEntry == NULL) return; - tstring strText = _T(""); + tstring strText = L""; if(pEntry->iMessages > 0) { - strText = _T("["); + strText = L"["; strText += pEntry->strMessages; - strText += _T("]"); + strText += L"]"; } strText += pEntry->strName; @@ -445,7 +445,7 @@ void CContactList::DrawGroup(CLCDGfx *pGfx,CContactListGroup *pGroup,bool bOpen, if(!pGroup->hMetaContact) { if(CConfig::GetBoolSetting(CLIST_COUNTERS)) - strText = strText + _T(" (") + toTstring(num2).c_str()+ _T("/") + toTstring(num).c_str() + _T(")"); + strText = strText + L" (" + toTstring(num2).c_str()+ L"/" + toTstring(num).c_str() + L")"; } else { @@ -456,16 +456,16 @@ void CContactList::DrawGroup(CLCDGfx *pGfx,CContactListGroup *pGroup,bool bOpen, if(iEvents != 0) { itoa(iEvents,num,10); - strText = _T("[") + toTstring(num) + _T("]") + strText; + strText = L"[" + toTstring(num) + L"]" + strText; } int iOffset = !pGroup->hMetaContact?m_iFontHeight*0.8:m_iFontHeight*0.8+8; pGfx->DrawText(iOffset,0,pGfx->GetClipWidth()-iOffset,strText.c_str()); if(bOpen) - pGfx->DrawText(1,0,_T("-")); + pGfx->DrawText(1,0,L"-"); else - pGfx->DrawText(1,0,_T("+")); + pGfx->DrawText(1,0,L"+"); if(bSelected && (GetTickCount() - m_dwLastScroll < 1000|| !CConfig::GetBoolSetting(CLIST_SELECTION))) { @@ -687,7 +687,7 @@ void CContactList::OnContactNickChanged(MCONTACT hContact, tstring strNick) CListContainer *pGroup = ((CListContainer*)pContactEntry); pGroup->GetGroupData()->strName = strNick; tstring strPath = GetContactGroupPath(hContact); - pGroup->GetGroupData()->strPath = strPath + (strPath.empty()?_T(""):_T("\\")) + strNick; + pGroup->GetGroupData()->strPath = strPath + (strPath.empty()?L"":L"\\") + strNick; } CContactListEntry* pEntry = GetContactData(pContactEntry); @@ -865,7 +865,7 @@ void CContactList::OnContactGroupChanged(MCONTACT hContact,tstring strGroup) { iter = pGroup->begin(); if((*iter)->GetType() == ITEM) - OnContactGroupChanged(GetContactData(*iter)->hHandle,_T("")); + OnContactGroupChanged(GetContactData(*iter)->hHandle,L""); Sleep(1); } } @@ -877,10 +877,10 @@ void CContactList::OnContactGroupChanged(MCONTACT hContact,tstring strGroup) if(bMetaContact) { tstring strName = CAppletManager::GetContactDisplayname(hContact); - tstring strPath = _T(""); + tstring strPath = L""; if(pOldGroup) strPath += pOldGroup->strPath; - strPath += (strPath.empty()?_T(""):_T("\\")) + strName; + strPath += (strPath.empty()?L"":L"\\") + strName; DeleteGroupObjectByPath(strPath); } @@ -920,7 +920,7 @@ void CContactList::UpdateMessageCounter(CListEntryiMessages >= 100) - pEntry->strMessages = _T(">99"); + pEntry->strMessages = L">99"; else { char buffer[8]; @@ -1003,10 +1003,10 @@ void CContactList::InitializeGroupObjects() if(szProto && db_get_b(NULL,META_PROTO,"Enabled",1) && !mir_strcmpi(szProto,META_PROTO)) { tstring strName = CAppletManager::GetContactDisplayname(hContact); - tstring strPath = _T(""); + tstring strPath = L""; if(CConfig::GetBoolSetting(CLIST_USEGROUPS)) strPath += strGroup; - strPath += (strPath.empty()?_T(""):_T("\\")) + strName; + strPath += (strPath.empty()?L"":L"\\") + strName; CContactListGroup *pGroup = CreateGroupObjectByPath(strPath); pGroup->hMetaContact = hContact; @@ -1060,7 +1060,7 @@ CContactListGroup *CContactList::CreateGroupObjectByPath(tstring strPath) CContactListGroup *pNewGroup = new CContactListGroup(); CContactListGroup *pParentGroup = NULL; - tstring strParsePath = _T(""); + tstring strParsePath = L""; tstring strName = strPath; tstring::size_type pos; @@ -1072,7 +1072,7 @@ CContactListGroup *CContactList::CreateGroupObjectByPath(tstring strPath) pParentGroup = GetGroupObjectByPath(strParsePath); if(!pParentGroup) pParentGroup = CreateGroupObjectByPath(strParsePath); - strParsePath += _T("\\"); + strParsePath += L"\\"; } if(pParentGroup) diff --git a/plugins/MirandaG15/src/CCreditsScreen.cpp b/plugins/MirandaG15/src/CCreditsScreen.cpp index 8001426b9d..9a025ffe51 100644 --- a/plugins/MirandaG15/src/CCreditsScreen.cpp +++ b/plugins/MirandaG15/src/CCreditsScreen.cpp @@ -28,8 +28,8 @@ bool CCreditsScreen::Initialize() m_Label.SetAlignment(DT_CENTER); m_Label.SetWordWrap(TRUE); - m_Label.SetText(_T("")); - m_Label.SetFontFaceName(_T("Microsoft Sans Serif")); + m_Label.SetText(L""); + m_Label.SetFontFaceName(L"Microsoft Sans Serif"); m_Label.SetFontPointSize(10); m_Label.SetFontWeight(FW_BOLD); @@ -65,94 +65,94 @@ bool CCreditsScreen::Update() if(dwTimeElapsed > m_dwDuration) { m_dwDuration = 4000; - m_Label.SetText(_T("")); - m_Label2.SetText(_T("")); + m_Label.SetText(L""); + m_Label2.SetText(L""); switch(m_iPosition) { case 0: - m_Label.SetText(_T("MirandaG15")); - m_Label2.SetText(_T("2008 by Martin Kleinhans")); + m_Label.SetText(L"MirandaG15"); + m_Label2.SetText(L"2008 by Martin Kleinhans"); m_dwDuration = 2500; break; case 1: m_Label.SetSize(GetWidth(),GetHeight()); - m_Label.SetText(_T("Special thanks to:")); + m_Label.SetText(L"Special thanks to:"); m_dwDuration = 2000; break; case 2: m_Label.SetSize(GetWidth(),25); - m_Label.SetText(_T("Shere Khan\n")); - m_Label2.SetText(_T("Concept, Ideas, Testing")); + m_Label.SetText(L"Shere Khan\n"); + m_Label2.SetText(L"Concept, Ideas, Testing"); m_dwDuration = 2500; break; case 3: m_Label.SetSize(GetWidth(),25); - m_Label.SetText(_T("Tauu and Cloonix\n")); - m_Label2.SetText(_T("Ideas, Testing")); + m_Label.SetText(L"Tauu and Cloonix\n"); + m_Label2.SetText(L"Ideas, Testing"); m_dwDuration = 2500; break; case 4: m_Label.SetSize(GetWidth(),GetHeight()); m_Label.SetFontPointSize(10); m_Label.SetFontWeight(FW_BOLD); - m_Label.SetText(_T("Betatesters:")); + m_Label.SetText(L"Betatesters:"); m_dwDuration = 2000; break; case 5: m_Label.SetSize(GetWidth(),25); m_Label2.SetFontPointSize(10); m_Label2.SetFontWeight(FW_BOLD); - m_Label.SetText(_T("Cyberz")); - m_Label2.SetText(_T("Cimlite")); + m_Label.SetText(L"Cyberz"); + m_Label2.SetText(L"Cimlite"); m_dwDuration = 2000; break; case 6: - m_Label.SetText(_T("Vullcan")); - m_Label2.SetText(_T("Snake")); + m_Label.SetText(L"Vullcan"); + m_Label2.SetText(L"Snake"); m_dwDuration = 2000; break; case 7: - m_Label.SetText(_T("Wiebbe")); - m_Label2.SetText(_T("Maluku")); + m_Label.SetText(L"Wiebbe"); + m_Label2.SetText(L"Maluku"); m_dwDuration = 2000; break; case 8: - m_Label.SetText(_T("lastwebpage")); + m_Label.SetText(L"lastwebpage"); m_dwDuration = 2000; break; case 9: m_Label.SetSize(GetWidth(),GetHeight()); - m_Label.SetText(_T("Additional thanks to:")); + m_Label.SetText(L"Additional thanks to:"); m_dwDuration = 2000; break; case 10: m_Label.SetSize(GetWidth(),25); m_Label2.SetFontPointSize(8); m_Label2.SetFontWeight(FW_NORMAL); - m_Label.SetText(_T("Everyone")); - m_Label2.SetText(_T("on G15Forums.com")); + m_Label.SetText(L"Everyone"); + m_Label2.SetText(L"on G15Forums.com"); m_dwDuration = 2000; break; case 11: - m_Label.SetText(_T("Everyone else")); - m_Label2.SetText(_T("for feedback and suggestions")); + m_Label.SetText(L"Everyone else"); + m_Label2.SetText(L"for feedback and suggestions"); m_dwDuration = 2000; break; case 12: m_Label.SetFontPointSize(10); m_Label.SetFontWeight(FW_BOLD); m_Label.SetSize(GetWidth(),25); - m_Label.SetText(_T("Logitech")); - m_Label2.SetText(_T("for obvious reasons")); + m_Label.SetText(L"Logitech"); + m_Label2.SetText(L"for obvious reasons"); m_dwDuration = 2000; break; case 13: m_Label.SetSize(GetWidth(),10); - m_Label.SetText(_T("You can contact me at:")); + m_Label.SetText(L"You can contact me at:"); m_Label2.SetSize(GetWidth(),33); m_Label2.SetOrigin(0,10); m_Label2.SetFontPointSize(8); - m_Label2.SetText(_T("mail@mkleinhans.de\nwww.mkleinhans.de")); + m_Label2.SetText(L"mail@mkleinhans.de\nwww.mkleinhans.de"); m_dwDuration = 2500; break; default: @@ -182,8 +182,8 @@ void CCreditsScreen::Reset() m_Label2.SetAlignment(DT_CENTER); m_Label2.SetWordWrap(TRUE); - m_Label2.SetText(_T("")); - m_Label2.SetFontFaceName(_T("Microsoft Sans Serif")); + m_Label2.SetText(L""); + m_Label2.SetFontFaceName(L"Microsoft Sans Serif"); m_Label2.SetFontPointSize(8); m_Label.SetOrigin(0,0); diff --git a/plugins/MirandaG15/src/CEvent.h b/plugins/MirandaG15/src/CEvent.h index c94e98d108..4222600ca4 100644 --- a/plugins/MirandaG15/src/CEvent.h +++ b/plugins/MirandaG15/src/CEvent.h @@ -44,11 +44,11 @@ public: hContact = NULL; bNotification = false; bLog = true; - strDescription = _T(""); + strDescription = L""; iValue = NULL; hValue = NULL; - strValue = _T(""); + strValue = L""; } enum EventType eType; diff --git a/plugins/MirandaG15/src/CEventScreen.cpp b/plugins/MirandaG15/src/CEventScreen.cpp index 819ec8b3b9..e03a36301e 100644 --- a/plugins/MirandaG15/src/CEventScreen.cpp +++ b/plugins/MirandaG15/src/CEventScreen.cpp @@ -111,7 +111,7 @@ void CEventScreen::OnConfigChanged() while(iter != m_EventLog.end()) { pItem = static_cast*>(*iter); - pItem->GetItemData()->strTimestamp = CAppletManager::GetFormattedTimestamp(&pItem->GetItemData()->Time) + _T(" "); + pItem->GetItemData()->strTimestamp = CAppletManager::GetFormattedTimestamp(&pItem->GetItemData()->Time) + L" "; iter++; } @@ -133,7 +133,7 @@ void CEventScreen::OnEventReceived(CEvent *pEvent) pEntry->eType = pEvent->eType; pEntry->Time = pEvent->Time; - pEntry->strTimestamp = CAppletManager::GetFormattedTimestamp(&pEvent->Time) + _T(" "); + pEntry->strTimestamp = CAppletManager::GetFormattedTimestamp(&pEvent->Time) + L" "; pEntry->strValue = pEvent->strDescription; // add it to the list and scroll to it diff --git a/plugins/MirandaG15/src/CNotificationScreen.cpp b/plugins/MirandaG15/src/CNotificationScreen.cpp index 0eb1cb3bdc..26955ebf78 100644 --- a/plugins/MirandaG15/src/CNotificationScreen.cpp +++ b/plugins/MirandaG15/src/CNotificationScreen.cpp @@ -35,7 +35,7 @@ bool CNotificationScreen::Initialize() //m_Input.Initialize(); //m_Input.Show(0); - m_TitleText.SetText(_T("Miranda-IM")); + m_TitleText.SetText(L"Miranda-IM"); m_TitleText.SetAlignment(DT_LEFT); m_Timestamp.SetAlignment(DT_RIGHT); @@ -125,14 +125,14 @@ void CNotificationScreen::DisplayNotification(CNotificationEntry *pEntry) m_pEntry = pEntry; if(CConfig::GetIntSetting(NOTIFY_TITLE) == NOTIFY_TITLE_NAME || pEntry->strTitle.empty()) - m_TitleText.SetText(_T("Miranda-IM")); + m_TitleText.SetText(L"Miranda-IM"); else m_TitleText.SetText(pEntry->strTitle); if(CConfig::GetBoolSetting(NOTIFY_TIMESTAMPS)) m_Timestamp.SetText(strTime); else - m_Timestamp.SetText(_T("")); + m_Timestamp.SetText(L""); if(pEntry->hContact) @@ -249,7 +249,7 @@ void CNotificationScreen::OnEventReceived(CEvent *pEvent) if(CConfig::GetIntSetting(NOTIFY_TITLE) == NOTIFY_TITLE_INFO) pEntry->strText = pEvent->strValue; else - pEntry->strText = strUser + (pEvent->eType == EVENT_IRC_RECEIVED?_T(" - "):_T(": "))+ pEvent->strValue; + pEntry->strText = strUser + (pEvent->eType == EVENT_IRC_RECEIVED?L" - ":L": ")+ pEvent->strValue; } else { @@ -367,8 +367,8 @@ void CNotificationScreen::OnExpiration() delete pEntry; } // reset the object's content - m_EventText.SetText(_T("")); - m_MessageText.SetText(_T("")); + m_EventText.SetText(L""); + m_MessageText.SetText(L""); m_pEntry = NULL; } \ No newline at end of file diff --git a/plugins/MirandaG15/src/CScreen.cpp b/plugins/MirandaG15/src/CScreen.cpp index cf095aab76..a49207baf1 100644 --- a/plugins/MirandaG15/src/CScreen.cpp +++ b/plugins/MirandaG15/src/CScreen.cpp @@ -45,9 +45,9 @@ bool CScreen::Initialize() m_Clock.SetOrigin(68,0); m_Clock.SetSize(40,2); - m_Clock.SetText(_T("23:00 - ")); + m_Clock.SetText(L"23:00 - "); - m_Clock.SetFontFaceName(_T("Small Fonts"));//Digital Limit 3õ3 C")); + m_Clock.SetFontFaceName(L"Small Fonts");//Digital Limit 3õ3 C")); m_Clock.SetFontPointSize(10); //m_Clock.SetFont(CConfig::GetFont(FONT_CLIST)); diff --git a/plugins/MirandaG15/src/CScreensaverScreen.cpp b/plugins/MirandaG15/src/CScreensaverScreen.cpp index d50e1e856f..0ba40da901 100644 --- a/plugins/MirandaG15/src/CScreensaverScreen.cpp +++ b/plugins/MirandaG15/src/CScreensaverScreen.cpp @@ -30,15 +30,15 @@ bool CScreensaverScreen::Initialize() m_Label.SetAlignment(DT_CENTER); m_Label.SetWordWrap(TRUE); - m_Label.SetText(_T("Screensaver is active")); - m_Label.SetFontFaceName(_T("Microsoft Sans Serif")); + m_Label.SetText(L"Screensaver is active"); + m_Label.SetFontFaceName(L"Microsoft Sans Serif"); m_Label.SetFontPointSize(10); m_Label.SetFontWeight(FW_BOLD); m_Label2.SetAlignment(DT_CENTER); m_Label2.SetWordWrap(TRUE); - m_Label2.SetText(_T("")); - m_Label2.SetFontFaceName(_T("Microsoft Sans Serif")); + m_Label2.SetText(L""); + m_Label2.SetFontFaceName(L"Microsoft Sans Serif"); m_Label2.SetFontPointSize(8); m_Label.SetOrigin(0,0); @@ -80,20 +80,20 @@ bool CScreensaverScreen::Update() if(dwTimeElapsed > m_dwDuration) { m_dwDuration = 4000; - m_Label.SetText(_T("")); - m_Label2.SetText(_T("")); + m_Label.SetText(L""); + m_Label2.SetText(L""); switch(m_iPosition) { case 0: m_Label.SetFontPointSize(8); - m_Label.SetText(_T("MirandaG15")); - m_Label2.SetText(_T("Screensaver is active")); + m_Label.SetText(L"MirandaG15"); + m_Label2.SetText(L"Screensaver is active"); m_dwDuration = 1800; break; case 1: m_Label.SetFontPointSize(11); - m_Label.SetText(_T("MirandaG15")); - m_Label2.SetText(_T("Applet locked")); + m_Label.SetText(L"MirandaG15"); + m_Label2.SetText(L"Applet locked"); m_dwDuration = 1800; m_iPosition = -1; break; @@ -122,8 +122,8 @@ void CScreensaverScreen::Reset() m_Label.SetFontPointSize(10); - m_Label.SetText(_T("")); - m_Label2.SetText(_T("")); + m_Label.SetText(L""); + m_Label2.SetText(L""); CAppletManager::GetInstance()->GetLCDConnection()->SetAsForeground(true); } diff --git a/plugins/MirandaG15/src/LCDFramework/CLCDConnectionLogitech.cpp b/plugins/MirandaG15/src/LCDFramework/CLCDConnectionLogitech.cpp index bd882b136f..768e586c39 100644 --- a/plugins/MirandaG15/src/LCDFramework/CLCDConnectionLogitech.cpp +++ b/plugins/MirandaG15/src/LCDFramework/CLCDConnectionLogitech.cpp @@ -166,10 +166,10 @@ bool CLCDConnectionLogitech::Initialize(tstring strAppletName, bool bAutostart, //************************************************************************ tstring CLCDConnectionLogitech::GetDeviceName() { if (m_pConnectedDevice->GetIndex() == LGLCD_DEVICE_BW) { - return _T("G15/Z10"); + return L"G15/Z10"; } else { - return _T("G19"); + return L"G19"; } } @@ -237,7 +237,7 @@ bool CLCDConnectionLogitech::Connect(int iIndex) m_hConnection = m_connectContext.connection; m_hDevice = LGLCD_INVALID_CONNECTION; - TRACE(_T("CLCDConnectionLogitech: Connection to LCDManager established successfully!\n")); + TRACE(L"CLCDConnectionLogitech: Connection to LCDManager established successfully!\n"); } else { return false; @@ -323,7 +323,7 @@ bool CLCDConnectionLogitech::Shutdown() //************************************************************************ bool CLCDConnectionLogitech::HIDReadData(BYTE* data) { static OVERLAPPED olRead; - static HANDLE hReadEvent = CreateEvent(NULL, false, true, _T("ReadEvent")); + static HANDLE hReadEvent = CreateEvent(NULL, false, true, L"ReadEvent"); static BYTE privateBuffer[9]; DWORD TransBytes; @@ -460,7 +460,7 @@ bool CLCDConnectionLogitech::Update() } } if (button != 0) { - TRACE(_T("GKey pressed: %d \n"), button); + TRACE(L"GKey pressed: %d \n", button); } } @@ -630,14 +630,14 @@ void CLCDConnectionLogitech::HandleErrorFromAPI(DWORD dwRes) break; // we lost our device case ERROR_DEVICE_NOT_CONNECTED: - TRACE(_T("CLCDConnectionLogitech::HandleErrorFromAPI(): Device was unplugged, closing device\n")); + TRACE(L"CLCDConnectionLogitech::HandleErrorFromAPI(): Device was unplugged, closing device\n"); Disconnect(); SetReconnect(true); SetVolumeWheelHook(false); break; default: - TRACE(_T("CLCDConnectionLogitech::HandleErrorFromAPI(): FATAL ERROR, closing device and connection\n")); + TRACE(L"CLCDConnectionLogitech::HandleErrorFromAPI(): FATAL ERROR, closing device and connection\n"); Disconnect(); SetReconnect(true); diff --git a/plugins/MirandaG15/src/LCDFramework/CLCDDevice.h b/plugins/MirandaG15/src/LCDFramework/CLCDDevice.h index d7d2efe35e..5d4776e0f5 100644 --- a/plugins/MirandaG15/src/LCDFramework/CLCDDevice.h +++ b/plugins/MirandaG15/src/LCDFramework/CLCDDevice.h @@ -42,7 +42,7 @@ public: // Returns the display name tstring GetDisplayName() { - return m_iBPP == 1? _T("G15") : _T("G19"); + return m_iBPP == 1? L"G15" : L"G19"; } // Returns the display size diff --git a/plugins/MirandaG15/src/LCDFramework/CLCDGfx.cpp b/plugins/MirandaG15/src/LCDFramework/CLCDGfx.cpp index b258952b16..7d874a7a33 100644 --- a/plugins/MirandaG15/src/LCDFramework/CLCDGfx.cpp +++ b/plugins/MirandaG15/src/LCDFramework/CLCDGfx.cpp @@ -60,7 +60,7 @@ bool CLCDGfx::Initialize(int nWidth, int nHeight, int nBPP, PBYTE pLcdBitmapBits m_hDC = CreateCompatibleDC(NULL); if(NULL == m_hDC) { - TRACE(_T("CLCDGfx::Initialize(): failed to create compatible DC.\n")); + TRACE(L"CLCDGfx::Initialize(): failed to create compatible DC.\n"); Shutdown(); return false; } @@ -69,7 +69,7 @@ bool CLCDGfx::Initialize(int nWidth, int nHeight, int nBPP, PBYTE pLcdBitmapBits m_pBitmapInfo = (BITMAPINFO *) new BYTE [nBMISize]; if(NULL == m_pBitmapInfo) { - TRACE(_T("CLCDGfx::Initialize(): failed to allocate bitmap info.\n")); + TRACE(L"CLCDGfx::Initialize(): failed to allocate bitmap info.\n"); Shutdown(); return false; } @@ -100,7 +100,7 @@ bool CLCDGfx::Initialize(int nWidth, int nHeight, int nBPP, PBYTE pLcdBitmapBits m_hBitmap = CreateDIBSection(m_hDC, m_pBitmapInfo, DIB_RGB_COLORS, (PVOID *) &m_pBitmapBits, NULL, 0); if(NULL == m_hBitmap) { - TRACE(_T("CLCDGfx::Initialize(): failed to create bitmap.\n")); + TRACE(L"CLCDGfx::Initialize(): failed to create bitmap.\n"); Shutdown(); return false; } @@ -317,7 +317,7 @@ void CLCDGfx::DrawText(int nX,int nY,int nWidth,tstring strText) SIZE sizeLine = {0, 0}; SIZE sizeCutOff = {0, 0}; - GetTextExtentPoint(GetHDC(),_T("..."),3,&sizeCutOff); + GetTextExtentPoint(GetHDC(),L"...",3,&sizeCutOff); int *piWidths = new int[strText.length()]; int iMaxChars = 0; @@ -329,7 +329,7 @@ void CLCDGfx::DrawText(int nX,int nY,int nWidth,tstring strText) if(piWidths[iMaxChars] + sizeCutOff.cx <= nWidth) break; - DrawText(nX,nY,(strText.substr(0,iMaxChars) + _T("...")).c_str()); + DrawText(nX,nY,(strText.substr(0,iMaxChars) + L"...").c_str()); } else DrawText(nX,nY,strText.c_str()); delete[] piWidths; @@ -721,7 +721,7 @@ void CLCDGfx::Cache() m_dwTransitionStart = GetTickCount(); - TRACE(_T("Textmorphing: time consumed: %0.2f\n"),(double)(m_dwTransitionStart-dwStart)/(double)1000); + TRACE(L"Textmorphing: time consumed: %0.2f\n",(double)(m_dwTransitionStart-dwStart)/(double)1000); } //************************************************************************ diff --git a/plugins/MirandaG15/src/LCDFramework/CLCDInput.cpp b/plugins/MirandaG15/src/LCDFramework/CLCDInput.cpp index 547216ac09..1ca9bd4378 100644 --- a/plugins/MirandaG15/src/LCDFramework/CLCDInput.cpp +++ b/plugins/MirandaG15/src/LCDFramework/CLCDInput.cpp @@ -298,9 +298,9 @@ LRESULT CLCDInput::ProcessKeyEvent(int Code, WPARAM wParam, LPARAM lParam) /* if(bKeyDown) - TRACE(_T("Key pressed: %i\n"),key->vkCode); + TRACE(L"Key pressed: %i\n",key->vkCode); else - TRACE(_T("Key released: %i\n"),key->vkCode); + TRACE(L"Key released: %i\n",key->vkCode); */ // Only handle Keyup if(bKeyDown) @@ -310,7 +310,7 @@ LRESULT CLCDInput::ProcessKeyEvent(int Code, WPARAM wParam, LPARAM lParam) && m_acKeyboardState[VK_SHIFT] & 0x80) { ActivateKeyboardLayout((HKL)HKL_NEXT,0);//KLF_SETFORPROCESS); - TRACE(_T("Keyboardlayout switched!\n")); + TRACE(L"Keyboardlayout switched!\n"); return 1; } @@ -566,7 +566,7 @@ void CLCDInput::Reset() memset(&m_Marker[0], 0, sizeof(SMarker)); - m_strText = _T(""); + m_strText = L""; m_vLineOffsets.clear(); m_iLinePosition = 0; SLineEntry offset; @@ -623,7 +623,7 @@ void CLCDInput::UpdateOffsets(int iModified) bool bLineClosed = false; - // TRACE(_T("InputText: Begin Update at #%i\n"),iLine); + // TRACE(L"InputText: Begin Update at #%i\n",iLine); for(;iLine iLen) { - // TRACE(_T("InputText: Deleted offset #%i\n"),iLine); + // TRACE(L"InputText: Deleted offset #%i\n",iLine); m_vLineOffsets.erase(m_vLineOffsets.begin()+iLine); continue; } @@ -647,7 +647,7 @@ void CLCDInput::UpdateOffsets(int iModified) iWordOffset= iChar; GetTextExtentExPoint(hDC,pszText+iChar,iLen-iChar,GetWidth(),&iMaxChars,piWidths,&sizeLine); - pos = m_strText.find(_T("\n"),iChar); + pos = m_strText.find(L"\n",iChar); // check for linebreaks if(pos != tstring::npos && pos >= iChar && pos <= iChar + iMaxChars) { @@ -658,7 +658,7 @@ void CLCDInput::UpdateOffsets(int iModified) else { // find the last space in the line - pos = m_strText.rfind(_T(" "),iChar + iMaxChars); + pos = m_strText.rfind(L" ",iChar + iMaxChars); if(pos != tstring::npos && pos >= iChar) iWordOffset = (int)pos +1; else @@ -701,7 +701,7 @@ void CLCDInput::UpdateOffsets(int iModified) // if there are other offsets in front of this one, delete them if(iLine2 != iLine + 1 ) { - // TRACE(_T("InputText: Deleted offsets #%i to #%i\n"),iLine+1,iLine2-1); + // TRACE(L"InputText: Deleted offsets #%i to #%i\n",iLine+1,iLine2-1); m_vLineOffsets.erase(m_vLineOffsets.begin()+iLine+1,m_vLineOffsets.begin()+iLine2); } break; @@ -724,7 +724,7 @@ void CLCDInput::UpdateOffsets(int iModified) else m_vLineOffsets[iLine].iWidth = 0; - // TRACE(_T("InputText: shifted offsets #%i to end %i position(s)\n"),iLine+1,iDistance); + // TRACE(L"InputText: shifted offsets #%i to end %i position(s)\n",iLine+1,iDistance); for(iLine++;iLine= i && pos != i+iMaxChars) iMaxChars = 1 + (int)pos - i; @@ -170,7 +170,7 @@ void CLCDLabel::UpdateCutOffIndex() else if(iMaxChars < iLen - i || sizeLine.cx >= GetWidth()) { // find the last space in the line ( substract -1 from offset to ignore spaces as last chars ) - pos = m_strText.rfind(_T(" "),i + iMaxChars -1 ); + pos = m_strText.rfind(L" ",i + iMaxChars -1 ); if(pos != tstring::npos && pos != i && pos >= i && pos != i+iMaxChars) iMaxChars = 1 + (int)pos - i; } @@ -188,7 +188,7 @@ void CLCDLabel::UpdateCutOffIndex() // calculate the cutoff position - GetTextExtentPoint(hDC,_T("..."),3,&sizeCutOff); + GetTextExtentPoint(hDC,L"...",3,&sizeCutOff); int *piWidths = new int[(*--m_vLines.end()).length()]; int iMaxChars = 0; @@ -202,7 +202,7 @@ void CLCDLabel::UpdateCutOffIndex() if(piWidths[iMaxChars] + sizeCutOff.cx <= iWidth) break; } - (*--m_vLines.end()) = (*--m_vLines.end()).substr(0,iMaxChars) + _T("..."); + (*--m_vLines.end()) = (*--m_vLines.end()).substr(0,iMaxChars) + L"..."; } delete[] piWidths; diff --git a/plugins/MirandaG15/src/LCDFramework/CLCDOutputManager.cpp b/plugins/MirandaG15/src/LCDFramework/CLCDOutputManager.cpp index 42bc3361de..cf8c680d12 100644 --- a/plugins/MirandaG15/src/LCDFramework/CLCDOutputManager.cpp +++ b/plugins/MirandaG15/src/LCDFramework/CLCDOutputManager.cpp @@ -21,7 +21,7 @@ CLCDOutputManager::CLCDOutputManager() : m_dwButtonRepeatDelay(300), m_pGfx(0), ASSERT(m_pInstance == NULL); m_pInstance = this; - m_strAppletName = _T(""); + m_strAppletName = L""; } //************************************************************************ @@ -140,7 +140,7 @@ void CLCDOutputManager::InitializeGfxObject() { if(m_pGfx->IsInitialized()) return; - TRACE(_T("CLCDOutputManager::UpdateGfxObject(): initializing CLCDGfx\n")); + TRACE(L"CLCDOutputManager::UpdateGfxObject(): initializing CLCDGfx\n"); SIZE size; size = m_pLcdConnection->GetDisplaySize(); @@ -176,7 +176,7 @@ void CLCDOutputManager::DeinitializeGfxObject() { if(!m_pGfx->IsInitialized()) return; - TRACE(_T("CLCDOutputManager::UpdateGfxObject(): shutting down CLCDGfx\n")); + TRACE(L"CLCDOutputManager::UpdateGfxObject(): shutting down CLCDGfx\n"); m_pGfx->Shutdown(); free(m_pbButtonStates); diff --git a/plugins/MirandaG15/src/LCDFramework/CLCDTextLog.cpp b/plugins/MirandaG15/src/LCDFramework/CLCDTextLog.cpp index 1db6536e08..f0c30b78cf 100644 --- a/plugins/MirandaG15/src/LCDFramework/CLCDTextLog.cpp +++ b/plugins/MirandaG15/src/LCDFramework/CLCDTextLog.cpp @@ -299,8 +299,8 @@ void CLCDTextLog::WrapMessage(CLogEntry *pEntry) int iLen = (int)strString.size(); int i = 0; - tstring strLine = _T(""); - tstring strWord = _T(""); + tstring strLine = L""; + tstring strWord = L""; SIZE sizeLine = {0, 0}; int *piExtents = new int[strString.length()]; @@ -320,7 +320,7 @@ void CLCDTextLog::WrapMessage(CLogEntry *pEntry) if(strString[i] == '\n' || strString[i] == ' ') i++; - pos = strString.rfind(_T("\n"),i+iMaxChars); + pos = strString.rfind(L"\n",i+iMaxChars); // check for linebreaks if(pos != tstring::npos && pos != i && pos >= i && pos != i+iMaxChars) iMaxChars = 1 + (int)pos - i; @@ -328,7 +328,7 @@ void CLCDTextLog::WrapMessage(CLogEntry *pEntry) else if(iMaxChars < iLen - i || sizeLine.cx >= GetWidth()) { // find the last space in the line ( substract -1 from offset to ignore spaces as last chars ) - pos = strString.rfind(_T(" "),i + iMaxChars -1 ); + pos = strString.rfind(L" ",i + iMaxChars -1 ); if(pos != tstring::npos && pos != i && pos >= i && pos != i+iMaxChars) iMaxChars = 1 + (int)pos - i; } @@ -351,7 +351,7 @@ void CLCDTextLog::WrapMessage(CLogEntry *pEntry) sizeLine.cx += sizeWord.cx; strLine += strWord; - strWord = _T(""); + strWord = L""; sizeWord.cx = 0; } @@ -365,7 +365,7 @@ void CLCDTextLog::WrapMessage(CLogEntry *pEntry) } pEntry->vLines.push_back(strLine); - strLine = _T(""); + strLine = L""; sizeLine.cx = 0; } i++; diff --git a/plugins/MirandaG15/src/LCDFramework/CLCDTextObject.cpp b/plugins/MirandaG15/src/LCDFramework/CLCDTextObject.cpp index ccbb420206..56c2d9f68c 100644 --- a/plugins/MirandaG15/src/LCDFramework/CLCDTextObject.cpp +++ b/plugins/MirandaG15/src/LCDFramework/CLCDTextObject.cpp @@ -34,7 +34,7 @@ bool CLCDTextObject::Initialize() m_hFont = (HFONT) GetStockObject(DEFAULT_GUI_FONT); if(NULL != m_hFont) { - SetFontFaceName(_T("Small Fonts")); + SetFontFaceName(L"Small Fonts"); SetFontPointSize(6); } return true; diff --git a/plugins/MirandaG15/src/LCDFramework/misc.cpp b/plugins/MirandaG15/src/LCDFramework/misc.cpp index d4a491f446..968bb5ce6c 100644 --- a/plugins/MirandaG15/src/LCDFramework/misc.cpp +++ b/plugins/MirandaG15/src/LCDFramework/misc.cpp @@ -111,7 +111,7 @@ tstring toLower(const tstring &i_str) tstring Utf8_Decode(const char *str) { - tstring strRes = _T(""); + tstring strRes = L""; int i; char *p; diff --git a/plugins/MirandaG15/src/Miranda.cpp b/plugins/MirandaG15/src/Miranda.cpp index 8b3c76e946..03d98766bf 100644 --- a/plugins/MirandaG15/src/Miranda.cpp +++ b/plugins/MirandaG15/src/Miranda.cpp @@ -105,7 +105,7 @@ EXTERN_C int __declspec(dllexport) Load() g_bInitialized = false; InitDebug(); - TRACE(_T("Plugin loaded\n")); + TRACE(L"Plugin loaded\n"); // Schedule actual initialization for later HookEvent(ME_SYSTEM_MODULESLOADED, Init); return 0; @@ -115,15 +115,15 @@ EXTERN_C int __declspec(dllexport) Load() EXTERN_C int __declspec(dllexport) Unload(void) { if(!g_bInitialized) { - TRACE(_T("ERROR: Unload requested, but plugin is not initialized?!\n")); + TRACE(L"ERROR: Unload requested, but plugin is not initialized?!\n"); return 0; } - TRACE(_T("-------------------------------------------\nUnloading started\n")); + TRACE(L"-------------------------------------------\nUnloading started\n"); UnInit(); - TRACE(_T("Unloading successful\n")); - TRACE(_T("Cleaning up: ")); + TRACE(L"Unloading successful\n"); + TRACE(L"Cleaning up: "); UnInitDebug(); - TRACE(_T("OK!\n")); + TRACE(L"OK!\n"); return 0; } @@ -161,17 +161,17 @@ int Init(WPARAM, LPARAM) if(!g_AppletManager->Initialize(toTstring(APP_SHORTNAME))) { if(CConfig::GetBoolSetting(SKIP_DRIVER_ERROR)) { - tstring text = _T("Failed to initialize the LCD connection\n Make sure you have the newest Logitech drivers installed (>=1.03).\n"); + tstring text = L"Failed to initialize the LCD connection\n Make sure you have the newest Logitech drivers installed (>=1.03).\n"; tstring title = _T(APP_SHORTNAME); MessageBox(NULL, text.c_str(), title.c_str(), MB_OK | MB_ICONEXCLAMATION); } - TRACE(_T("Initialization failed!.\n")); + TRACE(L"Initialization failed!.\n"); return 0; } g_bInitialized = true; - TRACE(_T("Initialization completed successfully.\n-------------------------------------------\n")); + TRACE(L"Initialization completed successfully.\n-------------------------------------------\n"); return 0; } //************************************************************************ -- cgit v1.2.3