summaryrefslogtreecommitdiff
path: root/plugins/HistoryStats
diff options
context:
space:
mode:
authorGeorge Hazan <george.hazan@gmail.com>2016-07-26 09:20:25 +0000
committerGeorge Hazan <george.hazan@gmail.com>2016-07-26 09:20:25 +0000
commit6e53dfca72b932c4bdcd7aa02ca62bf8b2630eac (patch)
tree2e8bb660c908b54914abd562af8aafa4a486c846 /plugins/HistoryStats
parenta61c8728b379057fe7f0a0d86fe0b037598229dd (diff)
less TCHARs:
- TCHAR is replaced with wchar_t everywhere; - LPGENT replaced with either LPGENW or LPGEN; - fixes for ANSI plugins that improperly used _t functions; - TCHAR *t removed from MAllStrings; - ptszGroup, ptszTitle & ptszTab in OPTIONSDIALOGPAGE replaced with pwsz* git-svn-id: http://svn.miranda-ng.org/main/trunk@17133 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'plugins/HistoryStats')
-rw-r--r--plugins/HistoryStats/src/_consts.h112
-rw-r--r--plugins/HistoryStats/src/bandctrl.cpp2
-rw-r--r--plugins/HistoryStats/src/bandctrl.h2
-rw-r--r--plugins/HistoryStats/src/bandctrldefs.h4
-rw-r--r--plugins/HistoryStats/src/bandctrlimpl.cpp6
-rw-r--r--plugins/HistoryStats/src/bandctrlimpl.h2
-rw-r--r--plugins/HistoryStats/src/canvas.cpp4
-rw-r--r--plugins/HistoryStats/src/canvas.h2
-rw-r--r--plugins/HistoryStats/src/column.h16
-rw-r--r--plugins/HistoryStats/src/column_chatduration.cpp20
-rw-r--r--plugins/HistoryStats/src/column_chatduration.h6
-rw-r--r--plugins/HistoryStats/src/column_events.cpp34
-rw-r--r--plugins/HistoryStats/src/column_events.h6
-rw-r--r--plugins/HistoryStats/src/column_group.h6
-rw-r--r--plugins/HistoryStats/src/column_inout.cpp56
-rw-r--r--plugins/HistoryStats/src/column_inout.h6
-rw-r--r--plugins/HistoryStats/src/column_inoutgraph.cpp16
-rw-r--r--plugins/HistoryStats/src/column_inoutgraph.h6
-rw-r--r--plugins/HistoryStats/src/column_nick.h6
-rw-r--r--plugins/HistoryStats/src/column_protocol.h6
-rw-r--r--plugins/HistoryStats/src/column_rank.h6
-rw-r--r--plugins/HistoryStats/src/column_split.cpp72
-rw-r--r--plugins/HistoryStats/src/column_split.h6
-rw-r--r--plugins/HistoryStats/src/column_splittimeline.cpp68
-rw-r--r--plugins/HistoryStats/src/column_splittimeline.h6
-rw-r--r--plugins/HistoryStats/src/column_timeline.cpp52
-rw-r--r--plugins/HistoryStats/src/column_timeline.h6
-rw-r--r--plugins/HistoryStats/src/column_wordcount.cpp16
-rw-r--r--plugins/HistoryStats/src/column_wordcount.h6
-rw-r--r--plugins/HistoryStats/src/column_words.cpp16
-rw-r--r--plugins/HistoryStats/src/column_words.h6
-rw-r--r--plugins/HistoryStats/src/dlgfilterwords.cpp28
-rw-r--r--plugins/HistoryStats/src/dlgoption.cpp18
-rw-r--r--plugins/HistoryStats/src/dlgoption.h10
-rw-r--r--plugins/HistoryStats/src/dlgoption_subcolumns.cpp18
-rw-r--r--plugins/HistoryStats/src/dlgoption_subglobal.cpp18
-rw-r--r--plugins/HistoryStats/src/dlgoption_suboutput.cpp104
-rw-r--r--plugins/HistoryStats/src/iconlib.cpp48
-rw-r--r--plugins/HistoryStats/src/iconlib.h4
-rw-r--r--plugins/HistoryStats/src/main.cpp14
-rw-r--r--plugins/HistoryStats/src/message.cpp24
-rw-r--r--plugins/HistoryStats/src/message.h2
-rw-r--r--plugins/HistoryStats/src/mirandasettings.cpp10
-rw-r--r--plugins/HistoryStats/src/mirandasettings.h10
-rw-r--r--plugins/HistoryStats/src/mu_common.cpp26
-rw-r--r--plugins/HistoryStats/src/mu_common.h12
-rw-r--r--plugins/HistoryStats/src/optionsctrl.cpp52
-rw-r--r--plugins/HistoryStats/src/optionsctrl.h26
-rw-r--r--plugins/HistoryStats/src/optionsctrldefs.h32
-rw-r--r--plugins/HistoryStats/src/optionsctrlimpl.cpp26
-rw-r--r--plugins/HistoryStats/src/optionsctrlimpl.h56
-rw-r--r--plugins/HistoryStats/src/optionsctrlimpl_button.cpp4
-rw-r--r--plugins/HistoryStats/src/optionsctrlimpl_check.cpp2
-rw-r--r--plugins/HistoryStats/src/optionsctrlimpl_color.cpp4
-rw-r--r--plugins/HistoryStats/src/optionsctrlimpl_combo.cpp6
-rw-r--r--plugins/HistoryStats/src/optionsctrlimpl_datetime.cpp4
-rw-r--r--plugins/HistoryStats/src/optionsctrlimpl_edit.cpp10
-rw-r--r--plugins/HistoryStats/src/optionsctrlimpl_group.cpp2
-rw-r--r--plugins/HistoryStats/src/optionsctrlimpl_item.cpp4
-rw-r--r--plugins/HistoryStats/src/optionsctrlimpl_radio.cpp2
-rw-r--r--plugins/HistoryStats/src/settings.cpp24
-rw-r--r--plugins/HistoryStats/src/settings.h26
-rw-r--r--plugins/HistoryStats/src/settingsserializer.cpp2
-rw-r--r--plugins/HistoryStats/src/settingsserializer.h2
-rw-r--r--plugins/HistoryStats/src/settingstree.cpp24
-rw-r--r--plugins/HistoryStats/src/settingstree.h20
-rw-r--r--plugins/HistoryStats/src/statistic.cpp32
-rw-r--r--plugins/HistoryStats/src/statistic.h2
-rw-r--r--plugins/HistoryStats/src/stdafx.h1
-rw-r--r--plugins/HistoryStats/src/utf8buffer.h10
-rw-r--r--plugins/HistoryStats/src/utils.cpp102
-rw-r--r--plugins/HistoryStats/src/utils.h28
72 files changed, 712 insertions, 715 deletions
diff --git a/plugins/HistoryStats/src/_consts.h b/plugins/HistoryStats/src/_consts.h
index f1e8c8fa47..cd06f27fe3 100644
--- a/plugins/HistoryStats/src/_consts.h
+++ b/plugins/HistoryStats/src/_consts.h
@@ -4,11 +4,9 @@
#include "stdafx.h"
#if defined(HISTORYSTATS_CONST_DEFINE)
-#define CONST_T(nam, txt) extern const TCHAR* nam = _T(txt);
#define CONST_A(nam, txt) extern const char* nam = txt;
#define CONST_W(nam, txt) extern const WCHAR* nam = L#txt;
#else
-#define CONST_T(nam, txt) extern const TCHAR* nam;
#define CONST_A(nam, txt) extern const char* nam;
#define CONST_W(nam, txt) extern const WCHAR* nam;
#endif
@@ -109,72 +107,72 @@ namespace con
CONST_A(SettGroup , "Group" )
// column tags
- CONST_T(ColChatDuration , "chatduration" )
- CONST_T(ColEvents , "events" )
- CONST_T(ColGroup , "group" )
- CONST_T(ColInOut , "inouttext" )
- CONST_T(ColInOutGraph , "inout" )
- CONST_T(ColNick , "nick" )
- CONST_T(ColProtocol , "protocol" )
- CONST_T(ColRank , "rank" )
- CONST_T(ColSplit , "split" )
- CONST_T(ColSplitTimeline , "splittimeline" )
- CONST_T(ColTimeline , "timeline" )
- CONST_T(ColWordCount , "wordcount" )
- CONST_T(ColWords , "commonwords" )
+ CONST_W(ColChatDuration , "chatduration" )
+ CONST_W(ColEvents , "events" )
+ CONST_W(ColGroup , "group" )
+ CONST_W(ColInOut , "inouttext" )
+ CONST_W(ColInOutGraph , "inout" )
+ CONST_W(ColNick , "nick" )
+ CONST_W(ColProtocol , "protocol" )
+ CONST_W(ColRank , "rank" )
+ CONST_W(ColSplit , "split" )
+ CONST_W(ColSplitTimeline , "splittimeline" )
+ CONST_W(ColTimeline , "timeline" )
+ CONST_W(ColWordCount , "wordcount" )
+ CONST_W(ColWords , "commonwords" )
// suffix for column-specific settings
- CONST_T(SuffixData , "/data" )
+ CONST_W(SuffixData , "/data" )
// suffix for shared column data (filter words)
- CONST_T(SuffixWords , "/words" )
+ CONST_W(SuffixWords , "/words" )
// keys for common column settings
- CONST_T(KeyGUID , "guid" )
- CONST_T(KeyEnabled , "enabled" )
- CONST_T(KeyTitle , "title" )
+ CONST_W(KeyGUID , "guid" )
+ CONST_W(KeyEnabled , "enabled" )
+ CONST_W(KeyTitle , "title" )
// keys for column-specific settings
- CONST_T(KeyAbsolute , "absolute" ) // InOut, InOutGraph
- CONST_T(KeyAbsTime , "abs_time" ) // InOut, InOutGraph
- CONST_T(KeyBlocks , "blocks" ) // Split, SplitTimeline
- CONST_T(KeyBlockUnit , "block_unit" ) // Split, SplitTimeline
- CONST_T(KeyContactCount , "contact_count" ) // Nick
- CONST_T(KeyCustomGroup , "custom_group" ) // SplitTimeline
- CONST_T(KeyDays , "days" ) // Timeline
- CONST_T(KeyDetail , "detail" ) // ChatDuration, InOutGraph, Nick, Split, Timeline, WordCount, Words
- CONST_T(KeyDetailInOut , "detail_inout" ) // Words
- CONST_T(KeyDetailInvert , "detail_invert" ) // InOutGraph
- CONST_T(KeyDetailPercent , "detail_percent" ) // InOutGraph
- CONST_T(KeyDOWGroup , "dow_group" ) // SplitTimeline
- CONST_T(KeyFilterLinks , "filter_links" ) // [Base]Words
- CONST_T(KeyFilterWords , "filter_words" ) // [Base]Words
- CONST_T(KeyGraph , "graph" ) // ChatDuration
- CONST_T(KeyGraphAlign , "graph_align" ) // Split, SplitTimeline
- CONST_T(KeyGraphPercent , "graph_percent" ) // InOutGraph
- CONST_T(KeyHODGroup , "hod_group" ) // SplitTimeline
- CONST_T(KeyIgnoreOld , "ignore_old" ) // Timeline
- CONST_T(KeyInOutColor , "in_out_color" ) // Words
- CONST_T(KeyMaxLength , "max_length" ) // [Base]Words
- CONST_T(KeyMinLength , "min_length" ) // [Base]Words
- CONST_T(KeyNum , "num" ) // Words, **keys for common column settings**
- CONST_T(KeyOffset , "offset" ) // Words
- CONST_T(KeyShowSum , "show_sum" ) // InOutGraph
- CONST_T(KeySource , "source" ) // [Base]Words, Events, InOut, InOutGraph, Split, SplitTimeline, Timeline
- CONST_T(KeySourceType , "source_type" ) // Split, SplitTimeline, Timeline
- CONST_T(KeyTopPerColumn , "top_per_column" ) // SplitTimeline
- CONST_T(KeyUnitsPerBlock , "units_per_block" ) // Split, SplitTimeline
- CONST_T(KeyVisMode , "vis_mode" ) // ChatDuration, Split, SplitTimeline, WordCount, Words
+ CONST_W(KeyAbsolute , "absolute" ) // InOut, InOutGraph
+ CONST_W(KeyAbsTime , "abs_time" ) // InOut, InOutGraph
+ CONST_W(KeyBlocks , "blocks" ) // Split, SplitTimeline
+ CONST_W(KeyBlockUnit , "block_unit" ) // Split, SplitTimeline
+ CONST_W(KeyContactCount , "contact_count" ) // Nick
+ CONST_W(KeyCustomGroup , "custom_group" ) // SplitTimeline
+ CONST_W(KeyDays , "days" ) // Timeline
+ CONST_W(KeyDetail , "detail" ) // ChatDuration, InOutGraph, Nick, Split, Timeline, WordCount, Words
+ CONST_W(KeyDetailInOut , "detail_inout" ) // Words
+ CONST_W(KeyDetailInvert , "detail_invert" ) // InOutGraph
+ CONST_W(KeyDetailPercent , "detail_percent" ) // InOutGraph
+ CONST_W(KeyDOWGroup , "dow_group" ) // SplitTimeline
+ CONST_W(KeyFilterLinks , "filter_links" ) // [Base]Words
+ CONST_W(KeyFilterWords , "filter_words" ) // [Base]Words
+ CONST_W(KeyGraph , "graph" ) // ChatDuration
+ CONST_W(KeyGraphAlign , "graph_align" ) // Split, SplitTimeline
+ CONST_W(KeyGraphPercent , "graph_percent" ) // InOutGraph
+ CONST_W(KeyHODGroup , "hod_group" ) // SplitTimeline
+ CONST_W(KeyIgnoreOld , "ignore_old" ) // Timeline
+ CONST_W(KeyInOutColor , "in_out_color" ) // Words
+ CONST_W(KeyMaxLength , "max_length" ) // [Base]Words
+ CONST_W(KeyMinLength , "min_length" ) // [Base]Words
+ CONST_W(KeyNum , "num" ) // Words, **keys for common column settings**
+ CONST_W(KeyOffset , "offset" ) // Words
+ CONST_W(KeyShowSum , "show_sum" ) // InOutGraph
+ CONST_W(KeySource , "source" ) // [Base]Words, Events, InOut, InOutGraph, Split, SplitTimeline, Timeline
+ CONST_W(KeySourceType , "source_type" ) // Split, SplitTimeline, Timeline
+ CONST_W(KeyTopPerColumn , "top_per_column" ) // SplitTimeline
+ CONST_W(KeyUnitsPerBlock , "units_per_block" ) // Split, SplitTimeline
+ CONST_W(KeyVisMode , "vis_mode" ) // ChatDuration, Split, SplitTimeline, WordCount, Words
// keeys for shared column data (filter words)
- CONST_T(KeyID , "id" )
- CONST_T(KeyName , "name" )
- CONST_T(KeyMode , "mode" )
- CONST_T(KeyNumWords , "num_words" )
+ CONST_W(KeyID , "id" )
+ CONST_W(KeyName , "name" )
+ CONST_W(KeyMode , "mode" )
+ CONST_W(KeyNumWords , "num_words" )
// keys for sort settings
- CONST_T(KeyAsc , "asc" )
- CONST_T(KeyBy , "by" )
+ CONST_W(KeyAsc , "asc" )
+ CONST_W(KeyBy , "by" )
// miranda services created by historystats
CONST_A(SvcConfigure , "HistoryStats/Configure" )
@@ -206,7 +204,7 @@ namespace con
const COLORREF ColorTotals = RGB(0xDF, 0xDF, 0xDF);
}
-#undef CONST_T
+#undef CONST_W
#undef CONST_A
#undef CONST_W
diff --git a/plugins/HistoryStats/src/bandctrl.cpp b/plugins/HistoryStats/src/bandctrl.cpp
index 5569efbf3c..2240b1f55c 100644
--- a/plugins/HistoryStats/src/bandctrl.cpp
+++ b/plugins/HistoryStats/src/bandctrl.cpp
@@ -10,7 +10,7 @@ void BandCtrl::setLayout(int nLayout)
SendMessage(m_hBandWnd, BCM_SETLAYOUT, nLayout, 0);
}
-HANDLE BandCtrl::addButton(DWORD dwFlags, HICON hIcon, INT_PTR dwData, const TCHAR *szTooltip, const TCHAR *szText)
+HANDLE BandCtrl::addButton(DWORD dwFlags, HICON hIcon, INT_PTR dwData, const wchar_t *szTooltip, const wchar_t *szText)
{
BCBUTTON bcb;
diff --git a/plugins/HistoryStats/src/bandctrl.h b/plugins/HistoryStats/src/bandctrl.h
index 77f1b7d023..4917545c87 100644
--- a/plugins/HistoryStats/src/bandctrl.h
+++ b/plugins/HistoryStats/src/bandctrl.h
@@ -25,7 +25,7 @@ public:
public:
void setLayout(int nLayout);
- HANDLE addButton(DWORD dwFlags, HICON hIcon, INT_PTR dwData, const TCHAR* szTooltip = NULL, const TCHAR* szText = NULL);
+ HANDLE addButton(DWORD dwFlags, HICON hIcon, INT_PTR dwData, const wchar_t* szTooltip = NULL, const wchar_t* szText = NULL);
bool isButtonChecked(HANDLE hButton);
void checkButton(HANDLE hButton, bool bCheck);
DWORD getButtonData(HANDLE hButton);
diff --git a/plugins/HistoryStats/src/bandctrldefs.h b/plugins/HistoryStats/src/bandctrldefs.h
index a48ac238e8..1be373dcfa 100644
--- a/plugins/HistoryStats/src/bandctrldefs.h
+++ b/plugins/HistoryStats/src/bandctrldefs.h
@@ -44,8 +44,8 @@ public:
struct BCBUTTON {
DWORD dwFlags;
HICON hIcon;
- const TCHAR *m_szText;
- const TCHAR *m_szTooltip;
+ const wchar_t *m_szText;
+ const wchar_t *m_szTooltip;
INT_PTR dwData;
};
diff --git a/plugins/HistoryStats/src/bandctrlimpl.cpp b/plugins/HistoryStats/src/bandctrlimpl.cpp
index 76e8b47dbe..d3ed8a4f65 100644
--- a/plugins/HistoryStats/src/bandctrlimpl.cpp
+++ b/plugins/HistoryStats/src/bandctrlimpl.cpp
@@ -8,7 +8,7 @@
* BandCtrlImpl
*/
-const TCHAR* BandCtrlImpl::m_ClassName = L"HistoryStatsBand";
+const wchar_t* BandCtrlImpl::m_ClassName = L"HistoryStatsBand";
const int BandCtrlImpl::m_PollId = 100;
const int BandCtrlImpl::m_PollDelay = 50;
@@ -604,7 +604,7 @@ void BandCtrlImpl::recalcButtonRects()
m_Items[i].uTTId, // uId
m_Items[i].rItem, // rect
NULL, // hInstance
- const_cast<TCHAR*>(m_Items[i].tooltip.c_str()), // lpszText
+ const_cast<wchar_t*>(m_Items[i].tooltip.c_str()), // lpszText
};
SendMessage(m_hTooltip, TTM_SETTOOLINFO, 0, reinterpret_cast<LPARAM>(&ti));
@@ -625,7 +625,7 @@ void BandCtrlImpl::recalcButtonRects()
m_hTooltip = CreateWindowEx(WS_EX_TOPMOST, TOOLTIPS_CLASS, L"", WS_POPUP, 0, 0, 0, 0, NULL, NULL, g_hInst, NULL);
TOOLINFO ti = { sizeof(TOOLINFO), TTF_SUBCLASS, m_hWnd, UINT_PTR(i+1), m_Items[i].rItem, NULL,
- const_cast<TCHAR*>(m_Items[i].tooltip.c_str()), // lpszText
+ const_cast<wchar_t*>(m_Items[i].tooltip.c_str()), // lpszText
};
if (SendMessage(m_hTooltip, TTM_ADDTOOL, 0, reinterpret_cast<LPARAM>(&ti)))
diff --git a/plugins/HistoryStats/src/bandctrlimpl.h b/plugins/HistoryStats/src/bandctrlimpl.h
index a9df939a00..7eef92ba68 100644
--- a/plugins/HistoryStats/src/bandctrlimpl.h
+++ b/plugins/HistoryStats/src/bandctrlimpl.h
@@ -31,7 +31,7 @@ private:
};
private:
- static const TCHAR* m_ClassName;
+ static const wchar_t* m_ClassName;
static const int m_PollId;
static const int m_PollDelay;
diff --git a/plugins/HistoryStats/src/canvas.cpp b/plugins/HistoryStats/src/canvas.cpp
index be0cd3978c..118534209d 100644
--- a/plugins/HistoryStats/src/canvas.cpp
+++ b/plugins/HistoryStats/src/canvas.cpp
@@ -131,13 +131,13 @@ bool Canvas::getDigest(Digest& digest)
return true;
}
-bool Canvas::writePNG(const TCHAR* szFileName)
+bool Canvas::writePNG(const wchar_t* szFileName)
{
IMGSRVC_INFO img = { 0 };
img.cbSize = sizeof(img);
img.dwMask = IMGI_HBITMAP;
img.hbm = m_hBmp;
img.fif = FIF_PNG;
- img.tszName = (TCHAR*)szFileName;
+ img.tszName = (wchar_t*)szFileName;
return CallService(MS_IMG_SAVE, (WPARAM)&img, IMGL_TCHAR) == 0;
}
diff --git a/plugins/HistoryStats/src/canvas.h b/plugins/HistoryStats/src/canvas.h
index a5b7f06519..99213316f2 100644
--- a/plugins/HistoryStats/src/canvas.h
+++ b/plugins/HistoryStats/src/canvas.h
@@ -48,7 +48,7 @@ public:
void endDraw();
bool getDigest(Digest& digest);
- bool writePNG(const TCHAR* szFileName);
+ bool writePNG(const wchar_t* szFileName);
};
#endif // HISTORYSTATS_GUARD_CANVAS_H
diff --git a/plugins/HistoryStats/src/column.h b/plugins/HistoryStats/src/column.h
index 1c1aaca70e..bb03bc1291 100644
--- a/plugins/HistoryStats/src/column.h
+++ b/plugins/HistoryStats/src/column.h
@@ -38,8 +38,8 @@ private:
{
public:
ext::string m_UID;
- const TCHAR* m_Title;
- const TCHAR* m_Description;
+ const wchar_t* m_Title;
+ const wchar_t* m_Description;
FactoryBase* m_pFactory;
};
@@ -170,9 +170,9 @@ public:
/*
* public interface for virtual functions
*/
- const TCHAR* getUID() const { return impl_getUID(); }
- const TCHAR* getTitle() const { return impl_getTitle(); }
- const TCHAR* getDescription() const { return impl_getDescription(); }
+ const wchar_t* getUID() const { return impl_getUID(); }
+ const wchar_t* getTitle() const { return impl_getTitle(); }
+ const wchar_t* getDescription() const { return impl_getDescription(); }
void copyConfig(const Column* pSource) { impl_copyConfig(pSource); }
int getFeatures() const { return impl_getFeatures(); }
void configRead(const SettingsTree& settings) { impl_configRead(settings); }
@@ -206,19 +206,19 @@ protected:
* Returns a unique ID for column.
* [virtual/abstract]
*/
- virtual const TCHAR* impl_getUID() const = 0;
+ virtual const wchar_t* impl_getUID() const = 0;
/*
* Returns the title for the column.
* [virtual/abstract]
*/
- virtual const TCHAR* impl_getTitle() const = 0;
+ virtual const wchar_t* impl_getTitle() const = 0;
/*
* Returns the description for the column.
* [virtual/abstract]
*/
- virtual const TCHAR* impl_getDescription() const = 0;
+ virtual const wchar_t* impl_getDescription() const = 0;
/*
* Creates a exact copy of the column.
diff --git a/plugins/HistoryStats/src/column_chatduration.cpp b/plugins/HistoryStats/src/column_chatduration.cpp
index 4954f693b8..762e750d1b 100644
--- a/plugins/HistoryStats/src/column_chatduration.cpp
+++ b/plugins/HistoryStats/src/column_chatduration.cpp
@@ -79,11 +79,11 @@ Column::StyleList ColChatDuration::impl_outputGetAdditionalStyles(IDProvider& id
void ColChatDuration::impl_outputRenderHeader(ext::ostream& tos, int row, int rowSpan) const
{
- static const TCHAR* szVisModeDesc[] = {
- LPGENT("Minimum chat duration"),
- LPGENT("Average chat duration"),
- LPGENT("Maximum chat duration"),
- LPGENT("Total chat duration"),
+ static const wchar_t* szVisModeDesc[] = {
+ LPGENW("Minimum chat duration"),
+ LPGENW("Average chat duration"),
+ LPGENW("Maximum chat duration"),
+ LPGENW("Total chat duration"),
};
if (row == 1)
@@ -162,11 +162,11 @@ void ColChatDuration::impl_outputRenderRow(ext::ostream& tos, const Contact& con
// output tooltip
if (m_bDetail)
{
- static const TCHAR* szPrefixes[] = {
- LPGENT("[Min] #{amount}"),
- LPGENT("[Avg] #{amount}"),
- LPGENT("[Max] #{amount}"),
- LPGENT("[Sum] #{amount}"),
+ static const wchar_t* szPrefixes[] = {
+ LPGENW("[Min] #{amount}"),
+ LPGENW("[Avg] #{amount}"),
+ LPGENW("[Max] #{amount}"),
+ LPGENW("[Sum] #{amount}"),
};
ext::string strTooltip;
diff --git a/plugins/HistoryStats/src/column_chatduration.h b/plugins/HistoryStats/src/column_chatduration.h
index b3f325692e..95e8e237ce 100644
--- a/plugins/HistoryStats/src/column_chatduration.h
+++ b/plugins/HistoryStats/src/column_chatduration.h
@@ -27,9 +27,9 @@ public:
explicit ColChatDuration();
protected:
- virtual const TCHAR* impl_getUID() const { return con::ColChatDuration; }
- virtual const TCHAR* impl_getTitle() const { return LPGENT("Chat duration"); }
- virtual const TCHAR* impl_getDescription() const { return LPGENT("Column holding the amount of time you have chatted with the given contact."); }
+ virtual const wchar_t* impl_getUID() const { return con::ColChatDuration; }
+ virtual const wchar_t* impl_getTitle() const { return LPGENW("Chat duration"); }
+ virtual const wchar_t* impl_getDescription() const { return LPGENW("Column holding the amount of time you have chatted with the given contact."); }
virtual void impl_copyConfig(const Column* pSource);
virtual int impl_getFeatures() const { return cfHasConfig; }
virtual void impl_configRead(const SettingsTree& settings);
diff --git a/plugins/HistoryStats/src/column_events.cpp b/plugins/HistoryStats/src/column_events.cpp
index 5b2c859d8c..1ecea2f2d5 100644
--- a/plugins/HistoryStats/src/column_events.cpp
+++ b/plugins/HistoryStats/src/column_events.cpp
@@ -31,13 +31,13 @@ void ColEvents::impl_configToUI(OptionsCtrl& Opt, OptionsCtrl::Item hGroup)
{
m_hSource = Opt.insertCombo(hGroup, TranslateT("Events to count"));
- static const TCHAR* sourceTexts[] = {
- LPGENT("URLs (incoming)"),
- LPGENT("URLs (outgoing)"),
- LPGENT("URLs (all)"),
- LPGENT("Files (incoming)"),
- LPGENT("Files (outgoing)"),
- LPGENT("Files (all)"),
+ static const wchar_t* sourceTexts[] = {
+ LPGENW("URLs (incoming)"),
+ LPGENW("URLs (outgoing)"),
+ LPGENW("URLs (all)"),
+ LPGENW("Files (incoming)"),
+ LPGENW("Files (outgoing)"),
+ LPGENW("Files (all)"),
};
array_each_(i, sourceTexts)
@@ -55,18 +55,18 @@ void ColEvents::impl_configFromUI(OptionsCtrl& Opt)
void ColEvents::impl_outputRenderHeader(ext::ostream& tos, int row, int rowSpan) const
{
- static const TCHAR* szShortDesc[] = {
- LPGENT("URLs"),
- LPGENT("Files"),
+ static const wchar_t* szShortDesc[] = {
+ LPGENW("URLs"),
+ LPGENW("Files"),
};
- static const TCHAR* szSourceDesc[] = {
- LPGENT("Incoming URLs"),
- LPGENT("Outgoing URLs"),
- LPGENT("URLs"),
- LPGENT("Incoming files"),
- LPGENT("Outgoing files"),
- LPGENT("Files"),
+ static const wchar_t* szSourceDesc[] = {
+ LPGENW("Incoming URLs"),
+ LPGENW("Outgoing URLs"),
+ LPGENW("URLs"),
+ LPGENW("Incoming files"),
+ LPGENW("Outgoing files"),
+ LPGENW("Files"),
};
if (row == 1)
diff --git a/plugins/HistoryStats/src/column_events.h b/plugins/HistoryStats/src/column_events.h
index 09a045c92c..5fd9d52dff 100644
--- a/plugins/HistoryStats/src/column_events.h
+++ b/plugins/HistoryStats/src/column_events.h
@@ -19,9 +19,9 @@ public:
explicit ColEvents();
protected:
- virtual const TCHAR* impl_getUID() const { return con::ColEvents; }
- virtual const TCHAR* impl_getTitle() const { return LPGENT("Events"); }
- virtual const TCHAR* impl_getDescription() const { return LPGENT("Column holding event counts for incoming, outgoing or total number of files or URLs."); }
+ virtual const wchar_t* impl_getUID() const { return con::ColEvents; }
+ virtual const wchar_t* impl_getTitle() const { return LPGENW("Events"); }
+ virtual const wchar_t* impl_getDescription() const { return LPGENW("Column holding event counts for incoming, outgoing or total number of files or URLs."); }
virtual void impl_copyConfig(const Column* pSource);
virtual int impl_getFeatures() const { return cfHasConfig; }
virtual void impl_configRead(const SettingsTree& settings);
diff --git a/plugins/HistoryStats/src/column_group.h b/plugins/HistoryStats/src/column_group.h
index caf7061500..4683bdb47e 100644
--- a/plugins/HistoryStats/src/column_group.h
+++ b/plugins/HistoryStats/src/column_group.h
@@ -11,9 +11,9 @@ class ColGroup
: public Column
{
protected:
- virtual const TCHAR* impl_getUID() const { return con::ColGroup; }
- virtual const TCHAR* impl_getTitle() const { return LPGENT("Group"); }
- virtual const TCHAR* impl_getDescription() const { return LPGENT("Column holding the contact list's group name the contact is in."); }
+ virtual const wchar_t* impl_getUID() const { return con::ColGroup; }
+ virtual const wchar_t* impl_getTitle() const { return LPGENW("Group"); }
+ virtual const wchar_t* impl_getDescription() const { return LPGENW("Column holding the contact list's group name the contact is in."); }
virtual int impl_getFeatures() const { return 0; }
virtual int impl_configGetRestrictions(ext::string*) const { return crHTMLFull; }
virtual void impl_outputRenderHeader(ext::ostream& tos, int row, int rowSpan) const;
diff --git a/plugins/HistoryStats/src/column_inout.cpp b/plugins/HistoryStats/src/column_inout.cpp
index 6bdc88909c..67a8d7d35f 100644
--- a/plugins/HistoryStats/src/column_inout.cpp
+++ b/plugins/HistoryStats/src/column_inout.cpp
@@ -46,16 +46,16 @@ void ColInOut::impl_configToUI(OptionsCtrl& Opt, OptionsCtrl::Item hGroup)
Opt.insertRadio(m_hAbsolute, m_hAbsTime, TranslateT("Units per week"));
Opt.insertRadio(m_hAbsolute, m_hAbsTime, TranslateT("Units per month (30 days)"));
- static const TCHAR* sourceTexts[] = {
- LPGENT("Characters (incoming)"),
- LPGENT("Characters (outgoing)"),
- LPGENT("Characters (all)"),
- LPGENT("Messages (incoming)"),
- LPGENT("Messages (outgoing)"),
- LPGENT("Messages (all)"),
- LPGENT("Chats (incoming)"),
- LPGENT("Chats (outgoing)"),
- LPGENT("Chats (all)"),
+ static const wchar_t* sourceTexts[] = {
+ LPGENW("Characters (incoming)"),
+ LPGENW("Characters (outgoing)"),
+ LPGENW("Characters (all)"),
+ LPGENW("Messages (incoming)"),
+ LPGENW("Messages (outgoing)"),
+ LPGENW("Messages (all)"),
+ LPGENW("Chats (incoming)"),
+ LPGENW("Chats (outgoing)"),
+ LPGENW("Chats (all)"),
};
array_each_(i, sourceTexts)
@@ -77,28 +77,28 @@ void ColInOut::impl_configFromUI(OptionsCtrl& Opt)
void ColInOut::impl_outputRenderHeader(ext::ostream& tos, int row, int rowSpan) const
{
- static const TCHAR* szShortDesc[] = {
- LPGENT("Characters"),
- LPGENT("Messages"),
- LPGENT("Chats")
+ static const wchar_t* szShortDesc[] = {
+ LPGENW("Characters"),
+ LPGENW("Messages"),
+ LPGENW("Chats")
};
- static const TCHAR* szSourceDesc[] = {
- LPGENT("Incoming characters"),
- LPGENT("Outgoing characters"),
- LPGENT("Characters"),
- LPGENT("Incoming messages"),
- LPGENT("Outgoing messages"),
- LPGENT("Messages"),
- LPGENT("Incoming chats"),
- LPGENT("Outgoing chats"),
- LPGENT("Chats")
+ static const wchar_t* szSourceDesc[] = {
+ LPGENW("Incoming characters"),
+ LPGENW("Outgoing characters"),
+ LPGENW("Characters"),
+ LPGENW("Incoming messages"),
+ LPGENW("Outgoing messages"),
+ LPGENW("Messages"),
+ LPGENW("Incoming chats"),
+ LPGENW("Outgoing chats"),
+ LPGENW("Chats")
};
- static const TCHAR* szUnitDesc[] = {
- LPGENT("day"),
- LPGENT("week"),
- LPGENT("month"),
+ static const wchar_t* szUnitDesc[] = {
+ LPGENW("day"),
+ LPGENW("week"),
+ LPGENW("month"),
};
if (row == 1)
diff --git a/plugins/HistoryStats/src/column_inout.h b/plugins/HistoryStats/src/column_inout.h
index 1a5ff19d39..c1ece71bff 100644
--- a/plugins/HistoryStats/src/column_inout.h
+++ b/plugins/HistoryStats/src/column_inout.h
@@ -23,9 +23,9 @@ public:
explicit ColInOut();
protected:
- virtual const TCHAR* impl_getUID() const { return con::ColInOut; }
- virtual const TCHAR* impl_getTitle() const { return LPGENT("In/out"); }
- virtual const TCHAR* impl_getDescription() const { return LPGENT("Column holding counts for incoming, outgoing or total characters, messages or chats. This column can display absolute and average values."); }
+ virtual const wchar_t* impl_getUID() const { return con::ColInOut; }
+ virtual const wchar_t* impl_getTitle() const { return LPGENW("In/out"); }
+ virtual const wchar_t* impl_getDescription() const { return LPGENW("Column holding counts for incoming, outgoing or total characters, messages or chats. This column can display absolute and average values."); }
virtual void impl_copyConfig(const Column* pSource);
virtual int impl_getFeatures() const { return cfHasConfig; }
virtual void impl_configRead(const SettingsTree& settings);
diff --git a/plugins/HistoryStats/src/column_inoutgraph.cpp b/plugins/HistoryStats/src/column_inoutgraph.cpp
index be00a85cb6..288080c6fa 100644
--- a/plugins/HistoryStats/src/column_inoutgraph.cpp
+++ b/plugins/HistoryStats/src/column_inoutgraph.cpp
@@ -132,16 +132,16 @@ SIZE ColInOutGraph::impl_outputMeasureHeader() const
void ColInOutGraph::impl_outputRenderHeader(ext::ostream& tos, int row, int rowSpan) const
{
- static const TCHAR* szSourceDesc[] = {
- LPGENT("Characters"),
- LPGENT("Messages"),
- LPGENT("Chats")
+ static const wchar_t* szSourceDesc[] = {
+ LPGENW("Characters"),
+ LPGENW("Messages"),
+ LPGENW("Chats")
};
- static const TCHAR* szSourceUnit[] = {
- LPGENT("day"),
- LPGENT("week"),
- LPGENT("month"),
+ static const wchar_t* szSourceUnit[] = {
+ LPGENW("day"),
+ LPGENW("week"),
+ LPGENW("month"),
};
if (row == 1)
diff --git a/plugins/HistoryStats/src/column_inoutgraph.h b/plugins/HistoryStats/src/column_inoutgraph.h
index 67089c260b..6b08170ff4 100644
--- a/plugins/HistoryStats/src/column_inoutgraph.h
+++ b/plugins/HistoryStats/src/column_inoutgraph.h
@@ -35,9 +35,9 @@ public:
ColInOutGraph();
protected:
- virtual const TCHAR* impl_getUID() const { return con::ColInOutGraph; }
- virtual const TCHAR* impl_getTitle() const { return LPGENT("In/out graph"); }
- virtual const TCHAR* impl_getDescription() const { return LPGENT("Column holding in/out bar graphs for characters, messages or chats."); }
+ virtual const wchar_t* impl_getUID() const { return con::ColInOutGraph; }
+ virtual const wchar_t* impl_getTitle() const { return LPGENW("In/out graph"); }
+ virtual const wchar_t* impl_getDescription() const { return LPGENW("Column holding in/out bar graphs for characters, messages or chats."); }
virtual void impl_copyConfig(const Column* pSource);
virtual int impl_getFeatures() const { return cfHasConfig; }
virtual void impl_configRead(const SettingsTree& settings);
diff --git a/plugins/HistoryStats/src/column_nick.h b/plugins/HistoryStats/src/column_nick.h
index 6701aa1976..b11959838e 100644
--- a/plugins/HistoryStats/src/column_nick.h
+++ b/plugins/HistoryStats/src/column_nick.h
@@ -21,9 +21,9 @@ public:
explicit ColNick();
protected:
- virtual const TCHAR* impl_getUID() const { return con::ColNick; }
- virtual const TCHAR* impl_getTitle() const { return LPGENT("Nick"); }
- virtual const TCHAR* impl_getDescription() const { return LPGENT("Column holding the contact's nick and first/last message time if selected."); }
+ virtual const wchar_t* impl_getUID() const { return con::ColNick; }
+ virtual const wchar_t* impl_getTitle() const { return LPGENW("Nick"); }
+ virtual const wchar_t* impl_getDescription() const { return LPGENW("Column holding the contact's nick and first/last message time if selected."); }
virtual void impl_copyConfig(const Column* pSource);
virtual int impl_getFeatures() const { return cfHasConfig; }
virtual void impl_configRead(const SettingsTree& settings);
diff --git a/plugins/HistoryStats/src/column_protocol.h b/plugins/HistoryStats/src/column_protocol.h
index 611b4fbc7a..1fc303e91f 100644
--- a/plugins/HistoryStats/src/column_protocol.h
+++ b/plugins/HistoryStats/src/column_protocol.h
@@ -11,9 +11,9 @@ class ColProtocol
: public Column
{
protected:
- virtual const TCHAR* impl_getUID() const { return con::ColProtocol; }
- virtual const TCHAR* impl_getTitle() const { return LPGENT("Protocol"); }
- virtual const TCHAR* impl_getDescription() const { return LPGENT("Column holding the contact's protocol."); }
+ virtual const wchar_t* impl_getUID() const { return con::ColProtocol; }
+ virtual const wchar_t* impl_getTitle() const { return LPGENW("Protocol"); }
+ virtual const wchar_t* impl_getDescription() const { return LPGENW("Column holding the contact's protocol."); }
virtual int impl_getFeatures() const { return 0; }
virtual int impl_configGetRestrictions(ext::string*) const { return crHTMLFull; }
virtual void impl_outputRenderHeader(ext::ostream& tos, int row, int rowSpan) const;
diff --git a/plugins/HistoryStats/src/column_rank.h b/plugins/HistoryStats/src/column_rank.h
index b0c152db84..fddadbaae7 100644
--- a/plugins/HistoryStats/src/column_rank.h
+++ b/plugins/HistoryStats/src/column_rank.h
@@ -14,9 +14,9 @@ private:
int m_nNextRank;
protected:
- virtual const TCHAR* impl_getUID() const { return con::ColRank; }
- virtual const TCHAR* impl_getTitle() const { return LPGENT("Rank"); }
- virtual const TCHAR* impl_getDescription() const { return LPGENT("Column holding the contact's placing according to your sorting criteria."); }
+ virtual const wchar_t* impl_getUID() const { return con::ColRank; }
+ virtual const wchar_t* impl_getTitle() const { return LPGENW("Rank"); }
+ virtual const wchar_t* impl_getDescription() const { return LPGENW("Column holding the contact's placing according to your sorting criteria."); }
virtual int impl_getFeatures() const { return 0; }
virtual int impl_configGetRestrictions(ext::string*) const { return crHTMLFull; }
virtual void impl_outputRenderHeader(ext::ostream& tos, int row, int rowSpan) const;
diff --git a/plugins/HistoryStats/src/column_split.cpp b/plugins/HistoryStats/src/column_split.cpp
index 0b3be3ca4f..c0b2ce3990 100644
--- a/plugins/HistoryStats/src/column_split.cpp
+++ b/plugins/HistoryStats/src/column_split.cpp
@@ -73,16 +73,16 @@ void ColSplit::impl_configToUI(OptionsCtrl& Opt, OptionsCtrl::Item hGroup)
Opt.insertRadio(hTemp, m_hGraphAlign, TranslateT("Align on week boundary"));
m_hDetail = Opt.insertCheck(hGroup, TranslateT("Details for every bar (tooltip)"));
- static const TCHAR* sourceTexts[] = {
- LPGENT("Characters (incoming)"),
- LPGENT("Characters (outgoing)"),
- LPGENT("Characters (all)"),
- LPGENT("Messages (incoming)"),
- LPGENT("Messages (outgoing)"),
- LPGENT("Messages (all)"),
- LPGENT("Chats (incoming)"),
- LPGENT("Chats (outgoing)"),
- LPGENT("Chats (all)"),
+ static const wchar_t* sourceTexts[] = {
+ LPGENW("Characters (incoming)"),
+ LPGENW("Characters (outgoing)"),
+ LPGENW("Characters (all)"),
+ LPGENW("Messages (incoming)"),
+ LPGENW("Messages (outgoing)"),
+ LPGENW("Messages (all)"),
+ LPGENW("Chats (incoming)"),
+ LPGENW("Chats (outgoing)"),
+ LPGENW("Chats (all)"),
};
array_each_(i, sourceTexts)
@@ -90,10 +90,10 @@ void ColSplit::impl_configToUI(OptionsCtrl& Opt, OptionsCtrl::Item hGroup)
Opt.addComboItem(m_hSource, TranslateTS(sourceTexts[i]));
}
- static const TCHAR* unitTexts[] = {
- LPGENT("Hours"),
- LPGENT("Days"),
- LPGENT("Weeks"),
+ static const wchar_t* unitTexts[] = {
+ LPGENW("Hours"),
+ LPGENW("Days"),
+ LPGENW("Weeks"),
};
array_each_(i, unitTexts)
@@ -263,22 +263,22 @@ Column::StyleList ColSplit::impl_outputGetAdditionalStyles(IDProvider& idp)
void ColSplit::impl_outputRenderHeader(ext::ostream& tos, int row, int rowSpan) const
{
- static const TCHAR* szTypeDesc[] = {
- LPGENT("Hours of day"),
- LPGENT("Days of week"),
- LPGENT("\"Split\""),
+ static const wchar_t* szTypeDesc[] = {
+ LPGENW("Hours of day"),
+ LPGENW("Days of week"),
+ LPGENW("\"Split\""),
};
- static const TCHAR* szSourceDesc[] = {
- LPGENT("incoming characters"),
- LPGENT("outgoing characters"),
- LPGENT("all characters"),
- LPGENT("incoming messages"),
- LPGENT("outgoing messages"),
- LPGENT("all messages"),
- LPGENT("incoming chats"),
- LPGENT("outgoing chats"),
- LPGENT("all chats"),
+ static const wchar_t* szSourceDesc[] = {
+ LPGENW("incoming characters"),
+ LPGENW("outgoing characters"),
+ LPGENW("all characters"),
+ LPGENW("incoming messages"),
+ LPGENW("outgoing messages"),
+ LPGENW("all messages"),
+ LPGENW("incoming chats"),
+ LPGENW("outgoing chats"),
+ LPGENW("all chats"),
};
if (row == 1)
@@ -344,14 +344,14 @@ void ColSplit::impl_outputRenderRow(ext::ostream& tos, const Contact& contact, D
{
SplitParams params = getParams();
- static const TCHAR* szWDayName[] = {
- LPGENT("wday3:Mon"),
- LPGENT("wday3:Tue"),
- LPGENT("wday3:Wed"),
- LPGENT("wday3:Thu"),
- LPGENT("wday3:Fri"),
- LPGENT("wday3:Sat"),
- LPGENT("wday3:Sun")
+ static const wchar_t* szWDayName[] = {
+ LPGENW("wday3:Mon"),
+ LPGENW("wday3:Tue"),
+ LPGENW("wday3:Wed"),
+ LPGENW("wday3:Thu"),
+ LPGENW("wday3:Fri"),
+ LPGENW("wday3:Sat"),
+ LPGENW("wday3:Sun")
};
const int* pData = reinterpret_cast<const int*>(contact.getSlot(contactDataSlotGet()));
diff --git a/plugins/HistoryStats/src/column_split.h b/plugins/HistoryStats/src/column_split.h
index 06159d1615..4dbe77fe3d 100644
--- a/plugins/HistoryStats/src/column_split.h
+++ b/plugins/HistoryStats/src/column_split.h
@@ -49,9 +49,9 @@ public:
explicit ColSplit();
protected:
- virtual const TCHAR* impl_getUID() const { return con::ColSplit; }
- virtual const TCHAR* impl_getTitle() const { return LPGENT("\"Split\""); }
- virtual const TCHAR* impl_getDescription() const { return LPGENT("Column holding a graphical overview of your chatting amount split by day of week or by hour of day. Different chatting amount measures are available."); }
+ virtual const wchar_t* impl_getUID() const { return con::ColSplit; }
+ virtual const wchar_t* impl_getTitle() const { return LPGENW("\"Split\""); }
+ virtual const wchar_t* impl_getDescription() const { return LPGENW("Column holding a graphical overview of your chatting amount split by day of week or by hour of day. Different chatting amount measures are available."); }
virtual void impl_copyConfig(const Column* pSource);
virtual int impl_getFeatures() const { return cfHasConfig | cfAcquiresData; }
virtual void impl_configRead(const SettingsTree& settings);
diff --git a/plugins/HistoryStats/src/column_splittimeline.cpp b/plugins/HistoryStats/src/column_splittimeline.cpp
index 17e139ba78..55d8f791c3 100644
--- a/plugins/HistoryStats/src/column_splittimeline.cpp
+++ b/plugins/HistoryStats/src/column_splittimeline.cpp
@@ -90,19 +90,19 @@ void ColSplitTimeline::impl_configToUI(OptionsCtrl& Opt, OptionsCtrl::Item hGrou
m_hCustomGroup = Opt.insertEdit (hTempRadio, TranslateT("Number of columns to group"), L"", OptionsCtrl::OCF_NUMBER);
m_hTopPerColumn = Opt.insertCheck(hGroup, TranslateT("Calculate maximum per column (not per graph)"));
- static const TCHAR* sourceTexts[] = {
- LPGENT("Characters (incoming)"),
- LPGENT("Characters (outgoing)"),
- LPGENT("Characters (all)"),
- LPGENT("Characters (in/out ratio)"),
- LPGENT("Messages (incoming)"),
- LPGENT("Messages (outgoing)"),
- LPGENT("Messages (all)"),
- LPGENT("Messages (in/out ratio)"),
- LPGENT("Chats (incoming)"),
- LPGENT("Chats (outgoing)"),
- LPGENT("Chats (all)"),
- LPGENT("Chats (in/out ratio)"),
+ static const wchar_t* sourceTexts[] = {
+ LPGENW("Characters (incoming)"),
+ LPGENW("Characters (outgoing)"),
+ LPGENW("Characters (all)"),
+ LPGENW("Characters (in/out ratio)"),
+ LPGENW("Messages (incoming)"),
+ LPGENW("Messages (outgoing)"),
+ LPGENW("Messages (all)"),
+ LPGENW("Messages (in/out ratio)"),
+ LPGENW("Chats (incoming)"),
+ LPGENW("Chats (outgoing)"),
+ LPGENW("Chats (all)"),
+ LPGENW("Chats (in/out ratio)"),
};
array_each_(i, sourceTexts)
@@ -110,10 +110,10 @@ void ColSplitTimeline::impl_configToUI(OptionsCtrl& Opt, OptionsCtrl::Item hGrou
Opt.addComboItem(m_hSource, TranslateTS(sourceTexts[i]));
}
- static const TCHAR* unitTexts[] = {
- LPGENT("Hours"),
- LPGENT("Days"),
- LPGENT("Weeks"),
+ static const wchar_t* unitTexts[] = {
+ LPGENW("Hours"),
+ LPGENW("Days"),
+ LPGENW("Weeks"),
};
array_each_(i, unitTexts)
@@ -250,25 +250,25 @@ void ColSplitTimeline::impl_contactDataMerge(Contact& contact, const Contact& in
void ColSplitTimeline::impl_outputRenderHeader(ext::ostream& tos, int row, int rowSpan) const
{
- static const TCHAR* szTypeDesc[] = {
- LPGENT("Hours of day timeline"),
- LPGENT("Days of week timeline"),
- LPGENT("\"Split\" timeline"),
+ static const wchar_t* szTypeDesc[] = {
+ LPGENW("Hours of day timeline"),
+ LPGENW("Days of week timeline"),
+ LPGENW("\"Split\" timeline"),
};
- static const TCHAR* szSourceDesc[] = {
- LPGENT("incoming characters"),
- LPGENT("outgoing characters"),
- LPGENT("all characters"),
- LPGENT("in/out ratio of characters"),
- LPGENT("incoming messages"),
- LPGENT("outgoing messages"),
- LPGENT("all messages"),
- LPGENT("in/out ratio of messages"),
- LPGENT("incoming chats"),
- LPGENT("outgoing chats"),
- LPGENT("all chats"),
- LPGENT("in/out ratio of chats"),
+ static const wchar_t* szSourceDesc[] = {
+ LPGENW("incoming characters"),
+ LPGENW("outgoing characters"),
+ LPGENW("all characters"),
+ LPGENW("in/out ratio of characters"),
+ LPGENW("incoming messages"),
+ LPGENW("outgoing messages"),
+ LPGENW("all messages"),
+ LPGENW("in/out ratio of messages"),
+ LPGENW("incoming chats"),
+ LPGENW("outgoing chats"),
+ LPGENW("all chats"),
+ LPGENW("in/out ratio of chats"),
};
if (row == 1)
diff --git a/plugins/HistoryStats/src/column_splittimeline.h b/plugins/HistoryStats/src/column_splittimeline.h
index ad2d41548b..4b28d74646 100644
--- a/plugins/HistoryStats/src/column_splittimeline.h
+++ b/plugins/HistoryStats/src/column_splittimeline.h
@@ -76,9 +76,9 @@ public:
explicit ColSplitTimeline();
protected:
- virtual const TCHAR* impl_getUID() const { return con::ColSplitTimeline; }
- virtual const TCHAR* impl_getTitle() const { return LPGENT("\"Split\" timeline"); }
- virtual const TCHAR* impl_getDescription() const { return LPGENT("Column holding a graphical overview of your chatting behavior (out, in, total, in/out ratio) from the first to the last day of your history. The information is spread along x- and y-axis and the values are encoded as color values. Different chatting behavior measures are available."); }
+ virtual const wchar_t* impl_getUID() const { return con::ColSplitTimeline; }
+ virtual const wchar_t* impl_getTitle() const { return LPGENW("\"Split\" timeline"); }
+ virtual const wchar_t* impl_getDescription() const { return LPGENW("Column holding a graphical overview of your chatting behavior (out, in, total, in/out ratio) from the first to the last day of your history. The information is spread along x- and y-axis and the values are encoded as color values. Different chatting behavior measures are available."); }
virtual void impl_copyConfig(const Column* pSource);
virtual int impl_getFeatures() const { return cfHasConfig | cfAcquiresData; }
virtual void impl_configRead(const SettingsTree& settings);
diff --git a/plugins/HistoryStats/src/column_timeline.cpp b/plugins/HistoryStats/src/column_timeline.cpp
index b6a5dc55c5..67e579ca0e 100644
--- a/plugins/HistoryStats/src/column_timeline.cpp
+++ b/plugins/HistoryStats/src/column_timeline.cpp
@@ -47,19 +47,19 @@ void ColTimeline::impl_configToUI(OptionsCtrl& Opt, OptionsCtrl::Item hGroup)
m_hDetail = Opt.insertCheck(hGroup, TranslateT("Details for every bar (tooltip)"));
m_hDays = Opt.insertEdit (hGroup, TranslateT("Number of days to group"), L"", OptionsCtrl::OCF_NUMBER);
- static const TCHAR* sourceTexts[] = {
- LPGENT("Characters (incoming)"),
- LPGENT("Characters (outgoing)"),
- LPGENT("Characters (all)"),
- LPGENT("Characters (in/out ratio)"),
- LPGENT("Messages (incoming)"),
- LPGENT("Messages (outgoing)"),
- LPGENT("Messages (all)"),
- LPGENT("Messages (in/out ratio)"),
- LPGENT("Chats (incoming)"),
- LPGENT("Chats (outgoing)"),
- LPGENT("Chats (all)"),
- LPGENT("Chats (in/out ratio)"),
+ static const wchar_t* sourceTexts[] = {
+ LPGENW("Characters (incoming)"),
+ LPGENW("Characters (outgoing)"),
+ LPGENW("Characters (all)"),
+ LPGENW("Characters (in/out ratio)"),
+ LPGENW("Messages (incoming)"),
+ LPGENW("Messages (outgoing)"),
+ LPGENW("Messages (all)"),
+ LPGENW("Messages (in/out ratio)"),
+ LPGENW("Chats (incoming)"),
+ LPGENW("Chats (outgoing)"),
+ LPGENW("Chats (all)"),
+ LPGENW("Chats (in/out ratio)"),
};
array_each_(i, sourceTexts)
@@ -190,19 +190,19 @@ Column::StyleList ColTimeline::impl_outputGetAdditionalStyles(IDProvider& idp)
void ColTimeline::impl_outputRenderHeader(ext::ostream& tos, int row, int rowSpan) const
{
- static const TCHAR* szSourceDesc[] = {
- LPGENT("incoming characters"),
- LPGENT("outgoing characters"),
- LPGENT("all characters"),
- LPGENT("in/out ratio of characters"),
- LPGENT("incoming messages"),
- LPGENT("outgoing messages"),
- LPGENT("all messages"),
- LPGENT("in/out ratio of messages"),
- LPGENT("incoming chats"),
- LPGENT("outgoing chats"),
- LPGENT("all chats"),
- LPGENT("in/out ratio of chats"),
+ static const wchar_t* szSourceDesc[] = {
+ LPGENW("incoming characters"),
+ LPGENW("outgoing characters"),
+ LPGENW("all characters"),
+ LPGENW("in/out ratio of characters"),
+ LPGENW("incoming messages"),
+ LPGENW("outgoing messages"),
+ LPGENW("all messages"),
+ LPGENW("in/out ratio of messages"),
+ LPGENW("incoming chats"),
+ LPGENW("outgoing chats"),
+ LPGENW("all chats"),
+ LPGENW("in/out ratio of chats"),
};
if (row == 1)
diff --git a/plugins/HistoryStats/src/column_timeline.h b/plugins/HistoryStats/src/column_timeline.h
index 3e8125fd68..fb0b9c5b85 100644
--- a/plugins/HistoryStats/src/column_timeline.h
+++ b/plugins/HistoryStats/src/column_timeline.h
@@ -52,9 +52,9 @@ public:
explicit ColTimeline();
protected:
- virtual const TCHAR* impl_getUID() const { return con::ColTimeline; }
- virtual const TCHAR* impl_getTitle() const { return LPGENT("Timeline"); }
- virtual const TCHAR* impl_getDescription() const { return LPGENT("Column holding a graphical overview of your chatting behavior (out, in, total, in/out ratio) from the first to the last day of your history on a daily basis. Multiple days can be grouped. Different chatting behavior measures are available."); }
+ virtual const wchar_t* impl_getUID() const { return con::ColTimeline; }
+ virtual const wchar_t* impl_getTitle() const { return LPGENW("Timeline"); }
+ virtual const wchar_t* impl_getDescription() const { return LPGENW("Column holding a graphical overview of your chatting behavior (out, in, total, in/out ratio) from the first to the last day of your history on a daily basis. Multiple days can be grouped. Different chatting behavior measures are available."); }
virtual void impl_copyConfig(const Column* pSource);
virtual int impl_getFeatures() const { return cfHasConfig | cfAcquiresData; }
virtual void impl_configRead(const SettingsTree& settings);
diff --git a/plugins/HistoryStats/src/column_wordcount.cpp b/plugins/HistoryStats/src/column_wordcount.cpp
index a00d9c510d..a83f27e652 100644
--- a/plugins/HistoryStats/src/column_wordcount.cpp
+++ b/plugins/HistoryStats/src/column_wordcount.cpp
@@ -110,16 +110,16 @@ void ColWordCount::impl_contactDataTransformCleanup(Contact& contact) const
void ColWordCount::impl_outputRenderHeader(ext::ostream& tos, int row, int rowSpan) const
{
- static const TCHAR* szTypeDesc[] = {
- LPGENT("Total word count"),
- LPGENT("Distinct word count"),
- LPGENT("Ratio total/distinct words")
+ static const wchar_t* szTypeDesc[] = {
+ LPGENW("Total word count"),
+ LPGENW("Distinct word count"),
+ LPGENW("Ratio total/distinct words")
};
- static const TCHAR* szSourceDesc[] = {
- LPGENT("incoming messages"),
- LPGENT("outgoing messages"),
- LPGENT("all messages"),
+ static const wchar_t* szSourceDesc[] = {
+ LPGENW("incoming messages"),
+ LPGENW("outgoing messages"),
+ LPGENW("all messages"),
};
if (row == 1)
diff --git a/plugins/HistoryStats/src/column_wordcount.h b/plugins/HistoryStats/src/column_wordcount.h
index 6277bc6cbb..e29b6836aa 100644
--- a/plugins/HistoryStats/src/column_wordcount.h
+++ b/plugins/HistoryStats/src/column_wordcount.h
@@ -21,9 +21,9 @@ public:
explicit ColWordCount();
protected:
- virtual const TCHAR* impl_getUID() const { return con::ColWordCount; }
- virtual const TCHAR* impl_getTitle() const { return LPGENT("Word count"); }
- virtual const TCHAR* impl_getDescription() const { return LPGENT("Column holding the number of (distinct) words used by you, by your contact, or by both of you."); }
+ virtual const wchar_t* impl_getUID() const { return con::ColWordCount; }
+ virtual const wchar_t* impl_getTitle() const { return LPGENW("Word count"); }
+ virtual const wchar_t* impl_getDescription() const { return LPGENW("Column holding the number of (distinct) words used by you, by your contact, or by both of you."); }
virtual void impl_copyConfig(const Column* pSource);
virtual void impl_configRead(const SettingsTree& settings);
virtual void impl_configWrite(SettingsTree& settings) const;
diff --git a/plugins/HistoryStats/src/column_words.cpp b/plugins/HistoryStats/src/column_words.cpp
index 6de8d42440..7d79cb467f 100644
--- a/plugins/HistoryStats/src/column_words.cpp
+++ b/plugins/HistoryStats/src/column_words.cpp
@@ -216,16 +216,16 @@ Column::StyleList ColWords::impl_outputGetAdditionalStyles(IDProvider&)
void ColWords::impl_outputRenderHeader(ext::ostream& tos, int row, int rowSpan) const
{
- static const TCHAR* szTypeDesc[] = {
- LPGENT("Most common words"),
- LPGENT("Least common words"),
- LPGENT("Longest words"),
+ static const wchar_t* szTypeDesc[] = {
+ LPGENW("Most common words"),
+ LPGENW("Least common words"),
+ LPGENW("Longest words"),
};
- static const TCHAR* szSourceDesc[] = {
- LPGENT("incoming messages"),
- LPGENT("outgoing messages"),
- LPGENT("all messages"),
+ static const wchar_t* szSourceDesc[] = {
+ LPGENW("incoming messages"),
+ LPGENW("outgoing messages"),
+ LPGENW("all messages"),
};
if (row == 1)
diff --git a/plugins/HistoryStats/src/column_words.h b/plugins/HistoryStats/src/column_words.h
index 0ec4c4fbc4..d215fd4753 100644
--- a/plugins/HistoryStats/src/column_words.h
+++ b/plugins/HistoryStats/src/column_words.h
@@ -64,9 +64,9 @@ public:
explicit ColWords();
protected:
- virtual const TCHAR* impl_getUID() const { return con::ColWords; }
- virtual const TCHAR* impl_getTitle() const { return LPGENT("Words"); }
- virtual const TCHAR* impl_getDescription() const { return LPGENT("Column holding a list of a specified number of most/least common words or longest words used by you, by your contact, or by both of you."); }
+ virtual const wchar_t* impl_getUID() const { return con::ColWords; }
+ virtual const wchar_t* impl_getTitle() const { return LPGENW("Words"); }
+ virtual const wchar_t* impl_getDescription() const { return LPGENW("Column holding a list of a specified number of most/least common words or longest words used by you, by your contact, or by both of you."); }
virtual void impl_copyConfig(const Column* pSource);
virtual void impl_configRead(const SettingsTree& settings);
virtual void impl_configWrite(SettingsTree& settings) const;
diff --git a/plugins/HistoryStats/src/dlgfilterwords.cpp b/plugins/HistoryStats/src/dlgfilterwords.cpp
index 48d1dfb4da..9344e55f19 100644
--- a/plugins/HistoryStats/src/dlgfilterwords.cpp
+++ b/plugins/HistoryStats/src/dlgfilterwords.cpp
@@ -78,11 +78,11 @@ void DlgFilterWords::onWMInitDialog()
static const struct
{
WORD iconId;
- TCHAR* szTooltip;
+ wchar_t* szTooltip;
bool bDisabled;
} columnBand[] = {
- { IDI_COL_ADD, LPGENT("Add set"), false },
- { IDI_COL_DEL, LPGENT("Delete set"), true },
+ { IDI_COL_ADD, LPGENW("Add set"), false },
+ { IDI_COL_DEL, LPGENW("Delete set"), true },
};
array_each_(i, columnBand)
@@ -109,15 +109,15 @@ void DlgFilterWords::onWMInitDialog()
}
// init other controls
- static const TCHAR* szWordFilterModes[] = {
- LPGENT("Filter words matching"),
- LPGENT("Filter words containing"),
- LPGENT("Filter words starting with"),
- LPGENT("Filter words ending with"),
- LPGENT("Filter messages matching"),
- LPGENT("Filter messages containing"),
- LPGENT("Filter messages starting with"),
- LPGENT("Filter messages ending with"),
+ static const wchar_t* szWordFilterModes[] = {
+ LPGENW("Filter words matching"),
+ LPGENW("Filter words containing"),
+ LPGENW("Filter words starting with"),
+ LPGENW("Filter words ending with"),
+ LPGENW("Filter messages matching"),
+ LPGENW("Filter messages containing"),
+ LPGENW("Filter messages starting with"),
+ LPGENW("Filter messages ending with"),
};
array_each_(i, szWordFilterModes)
@@ -209,7 +209,7 @@ void DlgFilterWords::onSetSelChanging(HANDLE hItem, INT_PTR dwData)
// set name
HWND hText = GetDlgItem(m_hWnd, IDC_SETNAME);
int nLen = GetWindowTextLength(hText);
- TCHAR* szText = new TCHAR[nLen + 1];
+ wchar_t* szText = new wchar_t[nLen + 1];
if (GetWindowText(hText, szText, nLen + 1)) {
pFilter->setName(szText);
@@ -221,7 +221,7 @@ void DlgFilterWords::onSetSelChanging(HANDLE hItem, INT_PTR dwData)
// words
hText = GetDlgItem(m_hWnd, IDC_WORDS);
nLen = GetWindowTextLength(hText);
- szText = new TCHAR[nLen + 1];
+ szText = new wchar_t[nLen + 1];
if (GetWindowText(hText, szText, nLen + 1)) {
ext::string strText = szText;
diff --git a/plugins/HistoryStats/src/dlgoption.cpp b/plugins/HistoryStats/src/dlgoption.cpp
index 03125b1857..61a67c04f2 100644
--- a/plugins/HistoryStats/src/dlgoption.cpp
+++ b/plugins/HistoryStats/src/dlgoption.cpp
@@ -90,21 +90,21 @@ void DlgOption::onWMInitDialog()
static const struct
{
WORD iconId;
- TCHAR* szText;
- TCHAR* szTooltip;
+ wchar_t* szText;
+ wchar_t* szTooltip;
bool bRight;
WORD dlgId;
bool bVisible;
bool bDropDown;
}
pageBand[] = {
- { IDI_SETT_GLOBAL, LPGENT("Global"), LPGENT("Global settings"), false, IDD_SUB_GLOBAL, true, false },
- { IDI_SETT_EXCLUDE, LPGENT("Exclude"), LPGENT("Exclude contacts"), false, IDD_SUB_EXCLUDE, true, false },
- { IDI_SETT_INPUT, LPGENT("Input"), LPGENT("Input settings"), false, IDD_SUB_INPUT, true, false },
- { IDI_SETT_COLUMNS, LPGENT("Columns"), LPGENT("Column settings"), false, IDD_SUB_COLUMNS, true, false },
- { IDI_SETT_OUTPUT, LPGENT("Output"), LPGENT("Output settings"), false, IDD_SUB_OUTPUT, true, false },
- { IDI_CREATE, LPGENT("Create"), LPGENT("Create statistics"), true, 0, true, true },
- { IDI_CREATE_WARNING, LPGENT("Create"), LPGENT("Create statistics (there are warnings)"), true, 0, false, true },
+ { IDI_SETT_GLOBAL, LPGENW("Global"), LPGENW("Global settings"), false, IDD_SUB_GLOBAL, true, false },
+ { IDI_SETT_EXCLUDE, LPGENW("Exclude"), LPGENW("Exclude contacts"), false, IDD_SUB_EXCLUDE, true, false },
+ { IDI_SETT_INPUT, LPGENW("Input"), LPGENW("Input settings"), false, IDD_SUB_INPUT, true, false },
+ { IDI_SETT_COLUMNS, LPGENW("Columns"), LPGENW("Column settings"), false, IDD_SUB_COLUMNS, true, false },
+ { IDI_SETT_OUTPUT, LPGENW("Output"), LPGENW("Output settings"), false, IDD_SUB_OUTPUT, true, false },
+ { IDI_CREATE, LPGENW("Create"), LPGENW("Create statistics"), true, 0, true, true },
+ { IDI_CREATE_WARNING, LPGENW("Create"), LPGENW("Create statistics (there are warnings)"), true, 0, false, true },
};
array_each_(i, pageBand)
diff --git a/plugins/HistoryStats/src/dlgoption.h b/plugins/HistoryStats/src/dlgoption.h
index 03b882eb24..2621b48ea0 100644
--- a/plugins/HistoryStats/src/dlgoption.h
+++ b/plugins/HistoryStats/src/dlgoption.h
@@ -75,11 +75,11 @@ private:
{
private:
struct SupportInfo {
- TCHAR* szPlugin;
- TCHAR* szTeaser;
- TCHAR* szDescription;
- TCHAR* szLinkTexts;
- TCHAR* szLinkURLs;
+ wchar_t* szPlugin;
+ wchar_t* szTeaser;
+ wchar_t* szDescription;
+ wchar_t* szLinkTexts;
+ wchar_t* szLinkURLs;
};
private:
diff --git a/plugins/HistoryStats/src/dlgoption_subcolumns.cpp b/plugins/HistoryStats/src/dlgoption_subcolumns.cpp
index cf385fe4ad..f6c635bfa0 100644
--- a/plugins/HistoryStats/src/dlgoption_subcolumns.cpp
+++ b/plugins/HistoryStats/src/dlgoption_subcolumns.cpp
@@ -163,16 +163,16 @@ void DlgOption::SubColumns::onWMInitDialog()
static const struct
{
WORD iconId;
- TCHAR* szTooltip;
+ wchar_t* szTooltip;
bool bRight;
bool bDropDown;
bool bDisabled;
}
columnBand[] = {
- { IDI_COL_ADD, LPGENT("Add column..."), false, true, false },
- { IDI_COL_DEL, LPGENT("Delete column"), false, false, true },
- { IDI_COL_DOWN, LPGENT("Move down"), true, false, true },
- { IDI_COL_UP, LPGENT("Move up"), true, false, true },
+ { IDI_COL_ADD, LPGENW("Add column..."), false, true, false },
+ { IDI_COL_DEL, LPGENW("Delete column"), false, false, true },
+ { IDI_COL_DOWN, LPGENW("Move down"), true, false, true },
+ { IDI_COL_UP, LPGENW("Move up"), true, false, true },
};
array_each_(i, columnBand)
@@ -311,7 +311,7 @@ void DlgOption::SubColumns::rearrangeControls()
void DlgOption::SubColumns::toggleInfo()
{
HWND hInfo = GetDlgItem(getHWnd(), IDC_INFO);
- const TCHAR* szInfoLabelText = m_bShowInfo ? LPGENT("Hide additional column info...") : LPGENT("Show additional column info...");
+ const wchar_t* szInfoLabelText = m_bShowInfo ? LPGENW("Hide additional column info...") : LPGENW("Show additional column info...");
SetDlgItemText(getHWnd(), IDC_INFOLABEL, TranslateTS(szInfoLabelText));
ShowWindow(hInfo, m_bShowInfo ? SW_SHOW : SW_HIDE);
@@ -407,7 +407,7 @@ void DlgOption::SubColumns::onColSelChanged(HANDLE hItem, INT_PTR)
tvi.item.state = TVIS_EXPANDED;
tvi.item.stateMask = TVIS_EXPANDED;
- tvi.item.pszText = const_cast<TCHAR*>(TranslateT("For this config the selected column..."));
+ tvi.item.pszText = const_cast<wchar_t*>(TranslateT("For this config the selected column..."));
tvi.hParent = TreeView_InsertItem(hInfo, &tvi);
// show capabilities of column
@@ -425,7 +425,7 @@ void DlgOption::SubColumns::onColSelChanged(HANDLE hItem, INT_PTR)
msg += ((restrictions & Column::crPNGMask) == Column::crPNGPartial) ? TranslateT("PNG (partial)") : L"PNG";
}
- tvi.item.pszText = const_cast<TCHAR*>(msg.c_str());
+ tvi.item.pszText = const_cast<wchar_t*>(msg.c_str());
TreeView_InsertItem(hInfo, &tvi);
// show effect of current config
@@ -464,7 +464,7 @@ void DlgOption::SubColumns::onColSelChanged(HANDLE hItem, INT_PTR)
msg += ((restrictions & Column::crHTMLMask) == Column::crHTMLFull) ? L"HTML" : L"PNG";
}
- tvi.item.pszText = const_cast<TCHAR*>(msg.c_str());
+ tvi.item.pszText = const_cast<wchar_t*>(msg.c_str());
TreeView_InsertItem(hInfo, &tvi);
SendMessage(hInfo, WM_SETREDRAW, TRUE, 0);
diff --git a/plugins/HistoryStats/src/dlgoption_subglobal.cpp b/plugins/HistoryStats/src/dlgoption_subglobal.cpp
index d04db4d390..ec6c21ae94 100644
--- a/plugins/HistoryStats/src/dlgoption_subglobal.cpp
+++ b/plugins/HistoryStats/src/dlgoption_subglobal.cpp
@@ -94,10 +94,10 @@ INT_PTR CALLBACK DlgOption::SubGlobal::staticInfoProc(HWND hDlg, UINT msg, WPARA
if (HIWORD(wParam) == STN_CLICKED) {
HWND hLink = reinterpret_cast<HWND>(lParam);
int nLen = GetWindowTextLength(hLink);
- TCHAR* szTitle = new TCHAR[nLen + 1];
+ wchar_t* szTitle = new wchar_t[nLen + 1];
if (GetWindowText(hLink, szTitle, nLen + 1)) {
- TCHAR* szEndOfURL = (TCHAR*)ext::strfunc::str(szTitle, L" [");
+ wchar_t* szEndOfURL = (wchar_t*)ext::strfunc::str(szTitle, L" [");
if (szEndOfURL) {
*szEndOfURL = '\0';
g_pSettings->openURL(szTitle);
@@ -112,7 +112,7 @@ INT_PTR CALLBACK DlgOption::SubGlobal::staticInfoProc(HWND hDlg, UINT msg, WPARA
case WM_CTLCOLORSTATIC:
HWND hStatic = reinterpret_cast<HWND>(lParam);
- TCHAR szClassName[64];
+ wchar_t szClassName[64];
if (GetClassName(hStatic, szClassName, _countof(szClassName)) && ext::strfunc::cmp(szClassName, WC_EDIT) == 0) {
HDC hDC = reinterpret_cast<HDC>(wParam);
@@ -313,9 +313,9 @@ void DlgOption::SubGlobal::initSupportInfo()
static const SupportInfo Infos[] = {
{
TranslateT("At this time there is no external plugin supported."),
- LPGENT(""),
- LPGENT(""),
- LPGENT(""),
+ LPGENW(""),
+ LPGENW(""),
+ LPGENW(""),
L""
},
};
@@ -335,14 +335,14 @@ void DlgOption::SubGlobal::initSupportInfo()
tvi.item.state = TVIS_EXPANDED | TVIS_BOLD;
tvi.item.stateMask = TVIS_EXPANDED | TVIS_BOLD;
- tvi.item.pszText = const_cast<TCHAR*>(TranslateT("Supported plugins (double-click to learn more):"));
+ tvi.item.pszText = const_cast<wchar_t*>(TranslateT("Supported plugins (double-click to learn more):"));
tvi.hParent = TreeView_InsertItem(hInfo, &tvi);
tvi.item.stateMask &= ~TVIS_BOLD;
array_each_(i, Infos)
{
- tvi.item.pszText = const_cast<TCHAR*>(Infos[i].szPlugin);
+ tvi.item.pszText = const_cast<wchar_t*>(Infos[i].szPlugin);
tvi.item.lParam = reinterpret_cast<LPARAM>(&Infos[i]);
TreeView_InsertItem(hInfo, &tvi);
}
@@ -385,7 +385,7 @@ void DlgOption::SubGlobal::rearrangeControls()
void DlgOption::SubGlobal::toggleInfo()
{
HWND hInfo = GetDlgItem(getHWnd(), IDC_INFO);
- const TCHAR* szInfoLabelText = m_bShowInfo ? LPGENT("HistoryStats supports several plugins. Click to hide info...") : LPGENT("HistoryStats supports several plugins. Click to learn more...");
+ const wchar_t* szInfoLabelText = m_bShowInfo ? LPGENW("HistoryStats supports several plugins. Click to hide info...") : LPGENW("HistoryStats supports several plugins. Click to learn more...");
SetDlgItemText(getHWnd(), IDC_INFOLABEL, TranslateTS(szInfoLabelText));
ShowWindow(hInfo, m_bShowInfo ? SW_SHOW : SW_HIDE);
diff --git a/plugins/HistoryStats/src/dlgoption_suboutput.cpp b/plugins/HistoryStats/src/dlgoption_suboutput.cpp
index 866c865dd6..67c58f9910 100644
--- a/plugins/HistoryStats/src/dlgoption_suboutput.cpp
+++ b/plugins/HistoryStats/src/dlgoption_suboutput.cpp
@@ -137,44 +137,44 @@ void DlgOption::SubOutput::onWMInitDialog()
m_hAutoOpenMenu = m_Options.insertCheck(hTemp2, TranslateT("...via Miranda NG main menu"));
// our sort levels
- static const TCHAR* sortLevels[Settings::cNumSortLevels] = {
- LPGENT("First sort by"),
- LPGENT("Then sort by"),
- LPGENT("Finally sort by")
+ static const wchar_t* sortLevels[Settings::cNumSortLevels] = {
+ LPGENW("First sort by"),
+ LPGENW("Then sort by"),
+ LPGENW("Finally sort by")
};
// our sort keys
static const struct {
int key;
- TCHAR* desc;
+ wchar_t* desc;
} sortKeys[] = {
- { Settings::skNick , LPGENT("Nick") },
- { Settings::skProtocol , LPGENT("Protocol") },
- { Settings::skGroup , LPGENT("Group") },
- { Settings::skBytesIn , LPGENT("Characters (incoming, absolute)") },
- { Settings::skBytesOut , LPGENT("Characters (outgoing, absolute)") },
- { Settings::skBytesTotal , LPGENT("Characters (all, absolute)") },
- { Settings::skBytesInAvg , LPGENT("Characters (incoming, average)") },
- { Settings::skBytesOutAvg , LPGENT("Characters (outgoing, average)") },
- { Settings::skBytesTotalAvg , LPGENT("Characters (all, average)") },
- { Settings::skMessagesIn , LPGENT("Messages (incoming, absolute)") },
- { Settings::skMessagesOut , LPGENT("Messages (outgoing, absolute)") },
- { Settings::skMessagesTotal , LPGENT("Messages (all, absolute)") },
- { Settings::skMessagesInAvg , LPGENT("Messages (incoming, average)") },
- { Settings::skMessagesOutAvg , LPGENT("Messages (outgoing, average)") },
- { Settings::skMessagesTotalAvg , LPGENT("Messages (all, average)") },
- { Settings::skChatsIn , LPGENT("Chats (incoming, absolute)") },
- { Settings::skChatsOut , LPGENT("Chats (outgoing, absolute)") },
- { Settings::skChatsTotal , LPGENT("Chats (all, absolute)") },
- { Settings::skChatsInAvg , LPGENT("Chats (incoming, average)") },
- { Settings::skChatsOutAvg , LPGENT("Chats (outgoing, average)") },
- { Settings::skChatsTotalAvg , LPGENT("Chats (all, average)") },
- { Settings::skChatDurationTotal , LPGENT("Chat duration (total)") },
- { Settings::skChatDurationMin , LPGENT("Chat duration (minimum)") },
- { Settings::skChatDurationAvg , LPGENT("Chat duration (average)") },
- { Settings::skChatDurationMax , LPGENT("Chat duration (maximum)") },
- { Settings::skTimeOfFirstMessage, LPGENT("Time of first message to/from contact") },
- { Settings::skTimeOfLastMessage , LPGENT("Time of last message to/from contact") },
+ { Settings::skNick , LPGENW("Nick") },
+ { Settings::skProtocol , LPGENW("Protocol") },
+ { Settings::skGroup , LPGENW("Group") },
+ { Settings::skBytesIn , LPGENW("Characters (incoming, absolute)") },
+ { Settings::skBytesOut , LPGENW("Characters (outgoing, absolute)") },
+ { Settings::skBytesTotal , LPGENW("Characters (all, absolute)") },
+ { Settings::skBytesInAvg , LPGENW("Characters (incoming, average)") },
+ { Settings::skBytesOutAvg , LPGENW("Characters (outgoing, average)") },
+ { Settings::skBytesTotalAvg , LPGENW("Characters (all, average)") },
+ { Settings::skMessagesIn , LPGENW("Messages (incoming, absolute)") },
+ { Settings::skMessagesOut , LPGENW("Messages (outgoing, absolute)") },
+ { Settings::skMessagesTotal , LPGENW("Messages (all, absolute)") },
+ { Settings::skMessagesInAvg , LPGENW("Messages (incoming, average)") },
+ { Settings::skMessagesOutAvg , LPGENW("Messages (outgoing, average)") },
+ { Settings::skMessagesTotalAvg , LPGENW("Messages (all, average)") },
+ { Settings::skChatsIn , LPGENW("Chats (incoming, absolute)") },
+ { Settings::skChatsOut , LPGENW("Chats (outgoing, absolute)") },
+ { Settings::skChatsTotal , LPGENW("Chats (all, absolute)") },
+ { Settings::skChatsInAvg , LPGENW("Chats (incoming, average)") },
+ { Settings::skChatsOutAvg , LPGENW("Chats (outgoing, average)") },
+ { Settings::skChatsTotalAvg , LPGENW("Chats (all, average)") },
+ { Settings::skChatDurationTotal , LPGENW("Chat duration (total)") },
+ { Settings::skChatDurationMin , LPGENW("Chat duration (minimum)") },
+ { Settings::skChatDurationAvg , LPGENW("Chat duration (average)") },
+ { Settings::skChatDurationMax , LPGENW("Chat duration (maximum)") },
+ { Settings::skTimeOfFirstMessage, LPGENW("Time of first message to/from contact") },
+ { Settings::skTimeOfLastMessage , LPGENW("Time of last message to/from contact") },
};
m_SortKeyToIndex.resize(Settings::skLAST - Settings::skFIRST + 1);
@@ -205,26 +205,26 @@ void DlgOption::SubOutput::onWMInitDialog()
}
// our "omit by value" data
- static const TCHAR* omitData[] = {
- LPGENT("Characters (incoming, absolute)"),
- LPGENT("Characters (outgoing, absolute)"),
- LPGENT("Characters (all, absolute)"),
- LPGENT("Characters (incoming, average per week)"),
- LPGENT("Characters (outgoing, average per week)"),
- LPGENT("Characters (all, average per week)"),
- LPGENT("Messages (incoming, absolute)"),
- LPGENT("Messages (outgoing, absolute)"),
- LPGENT("Messages (all, absolute)"),
- LPGENT("Messages (incoming, average per week)"),
- LPGENT("Messages (outgoing, average per week)"),
- LPGENT("Messages (all, average per week)"),
- LPGENT("Chats (incoming, absolute)"),
- LPGENT("Chats (outgoing, absolute)"),
- LPGENT("Chats (all, absolute)"),
- LPGENT("Chats (incoming, average per week)"),
- LPGENT("Chats (outgoing, average per week)"),
- LPGENT("Chats (all, average per week)"),
- LPGENT("Chat duration (total, hours)"),
+ static const wchar_t* omitData[] = {
+ LPGENW("Characters (incoming, absolute)"),
+ LPGENW("Characters (outgoing, absolute)"),
+ LPGENW("Characters (all, absolute)"),
+ LPGENW("Characters (incoming, average per week)"),
+ LPGENW("Characters (outgoing, average per week)"),
+ LPGENW("Characters (all, average per week)"),
+ LPGENW("Messages (incoming, absolute)"),
+ LPGENW("Messages (outgoing, absolute)"),
+ LPGENW("Messages (all, absolute)"),
+ LPGENW("Messages (incoming, average per week)"),
+ LPGENW("Messages (outgoing, average per week)"),
+ LPGENW("Messages (all, average per week)"),
+ LPGENW("Chats (incoming, absolute)"),
+ LPGENW("Chats (outgoing, absolute)"),
+ LPGENW("Chats (all, absolute)"),
+ LPGENW("Chats (incoming, average per week)"),
+ LPGENW("Chats (outgoing, average per week)"),
+ LPGENW("Chats (all, average per week)"),
+ LPGENW("Chat duration (total, hours)"),
};
array_each_(i, omitData)
diff --git a/plugins/HistoryStats/src/iconlib.cpp b/plugins/HistoryStats/src/iconlib.cpp
index 3f105824fa..7993c26a3b 100644
--- a/plugins/HistoryStats/src/iconlib.cpp
+++ b/plugins/HistoryStats/src/iconlib.cpp
@@ -8,30 +8,30 @@ bool IconLib::m_bIcoLibAvailable = false;
HANDLE IconLib::m_hHookSkin2IconsChanged = NULL;
IconLib::IconInfo IconLib::m_IconInfo[] = {
- { IDI_HISTORYSTATS , "main_menu" , NULL, LPGENT("Create statistics (main menu)") },
- { IDI_HISTORYSTATS , "menu_show" , NULL, LPGENT("Show statistics (main menu)") },
- { IDI_HISTORYSTATS , "menu_config" , NULL, LPGENT("Configure... (main menu)") },
- { IDI_HISTORYSTATS , "contact_menu" , NULL, LPGENT("Contact menu") },
- { IDI_EXCLUDE_NO , "exclude_no" , NULL, LPGENT("Unexcluded contacts") },
- { IDI_EXCLUDE_YES , "exclude_yes" , NULL, LPGENT("Excluded contacts") },
- { IDI_TREE_CHECK1 , "tree_check1" , LPGENT("Options tree"), LPGENT("Checkbox") },
- { IDI_TREE_CHECK2 , "tree_check2" , LPGENT("Options tree"), LPGENT("Checkbox (checked)") },
- { IDI_TREE_CHECK3 , "tree_check3" , LPGENT("Options tree"), LPGENT("Checkbox (disabled)") },
- { IDI_TREE_CHECK4 , "tree_check4" , LPGENT("Options tree"), LPGENT("Checkbox (checked & disabled)") },
- { IDI_TREE_RADIO1 , "tree_radio1" , LPGENT("Options tree"), LPGENT("Radio button") },
- { IDI_TREE_RADIO2 , "tree_radio2" , LPGENT("Options tree"), LPGENT("Radio button (checked)") },
- { IDI_TREE_RADIO3 , "tree_radio3" , LPGENT("Options tree"), LPGENT("Radio button (disabled)") },
- { IDI_TREE_RADIO4 , "tree_radio4" , LPGENT("Options tree"), LPGENT("Radio button (checked & disabled)") },
- { IDI_TREE_EDIT1 , "tree_edit1" , LPGENT("Options tree"), LPGENT("Edit control") },
- { IDI_TREE_EDIT2 , "tree_edit2" , LPGENT("Options tree"), LPGENT("Edit control (disabled)") },
- { IDI_TREE_COMBO1 , "tree_combo1" , LPGENT("Options tree"), LPGENT("Combo box") },
- { IDI_TREE_COMBO2 , "tree_combo2" , LPGENT("Options tree"), LPGENT("Combo box (disabled)") },
- { IDI_TREE_FOLDER1 , "tree_folder1" , LPGENT("Options tree"), LPGENT("Folder") },
- { IDI_TREE_FOLDER2 , "tree_folder2" , LPGENT("Options tree"), LPGENT("Folder (disabled)") },
- { IDI_TREE_BUTTON1 , "tree_button1" , LPGENT("Options tree"), LPGENT("Button") },
- { IDI_TREE_BUTTON2 , "tree_button2" , LPGENT("Options tree"), LPGENT("Button (disabled)") },
- { IDI_TREE_DATETIME1, "tree_datetime1", LPGENT("Options tree"), LPGENT("Date/time picker") },
- { IDI_TREE_DATETIME2, "tree_datetime2", LPGENT("Options tree"), LPGENT("Date/time picker (disabled)") },
+ { IDI_HISTORYSTATS , "main_menu" , NULL, LPGENW("Create statistics (main menu)") },
+ { IDI_HISTORYSTATS , "menu_show" , NULL, LPGENW("Show statistics (main menu)") },
+ { IDI_HISTORYSTATS , "menu_config" , NULL, LPGENW("Configure... (main menu)") },
+ { IDI_HISTORYSTATS , "contact_menu" , NULL, LPGENW("Contact menu") },
+ { IDI_EXCLUDE_NO , "exclude_no" , NULL, LPGENW("Unexcluded contacts") },
+ { IDI_EXCLUDE_YES , "exclude_yes" , NULL, LPGENW("Excluded contacts") },
+ { IDI_TREE_CHECK1 , "tree_check1" , LPGENW("Options tree"), LPGENW("Checkbox") },
+ { IDI_TREE_CHECK2 , "tree_check2" , LPGENW("Options tree"), LPGENW("Checkbox (checked)") },
+ { IDI_TREE_CHECK3 , "tree_check3" , LPGENW("Options tree"), LPGENW("Checkbox (disabled)") },
+ { IDI_TREE_CHECK4 , "tree_check4" , LPGENW("Options tree"), LPGENW("Checkbox (checked & disabled)") },
+ { IDI_TREE_RADIO1 , "tree_radio1" , LPGENW("Options tree"), LPGENW("Radio button") },
+ { IDI_TREE_RADIO2 , "tree_radio2" , LPGENW("Options tree"), LPGENW("Radio button (checked)") },
+ { IDI_TREE_RADIO3 , "tree_radio3" , LPGENW("Options tree"), LPGENW("Radio button (disabled)") },
+ { IDI_TREE_RADIO4 , "tree_radio4" , LPGENW("Options tree"), LPGENW("Radio button (checked & disabled)") },
+ { IDI_TREE_EDIT1 , "tree_edit1" , LPGENW("Options tree"), LPGENW("Edit control") },
+ { IDI_TREE_EDIT2 , "tree_edit2" , LPGENW("Options tree"), LPGENW("Edit control (disabled)") },
+ { IDI_TREE_COMBO1 , "tree_combo1" , LPGENW("Options tree"), LPGENW("Combo box") },
+ { IDI_TREE_COMBO2 , "tree_combo2" , LPGENW("Options tree"), LPGENW("Combo box (disabled)") },
+ { IDI_TREE_FOLDER1 , "tree_folder1" , LPGENW("Options tree"), LPGENW("Folder") },
+ { IDI_TREE_FOLDER2 , "tree_folder2" , LPGENW("Options tree"), LPGENW("Folder (disabled)") },
+ { IDI_TREE_BUTTON1 , "tree_button1" , LPGENW("Options tree"), LPGENW("Button") },
+ { IDI_TREE_BUTTON2 , "tree_button2" , LPGENW("Options tree"), LPGENW("Button (disabled)") },
+ { IDI_TREE_DATETIME1, "tree_datetime1", LPGENW("Options tree"), LPGENW("Date/time picker") },
+ { IDI_TREE_DATETIME2, "tree_datetime2", LPGENW("Options tree"), LPGENW("Date/time picker (disabled)") },
};
ext::string IconLib::m_Section;
diff --git a/plugins/HistoryStats/src/iconlib.h b/plugins/HistoryStats/src/iconlib.h
index 6586d1284e..5ac891850c 100644
--- a/plugins/HistoryStats/src/iconlib.h
+++ b/plugins/HistoryStats/src/iconlib.h
@@ -44,8 +44,8 @@ private:
{
WORD wID;
char* szIconName;
- TCHAR* szSection;
- TCHAR* szDescription;
+ wchar_t* szSection;
+ wchar_t* szDescription;
HICON hIcon;
};
diff --git a/plugins/HistoryStats/src/main.cpp b/plugins/HistoryStats/src/main.cpp
index f44efb8a85..4f3db4a67f 100644
--- a/plugins/HistoryStats/src/main.cpp
+++ b/plugins/HistoryStats/src/main.cpp
@@ -156,18 +156,18 @@ void AddMainMenu()
CreateServiceFunction(con::SvcShowStatistics, MenuShowStatistics);
CreateServiceFunction(con::SvcConfigure, MenuConfigure);
- HGENMENU hRoot = bInPopup ? Menu_CreateRoot(MO_MAIN, LPGENT("Statistics"), 1910000000) : NULL;
+ HGENMENU hRoot = bInPopup ? Menu_CreateRoot(MO_MAIN, LPGENW("Statistics"), 1910000000) : NULL;
Menu_ConfigureItem(hRoot, MCI_OPT_UID, "7F116B24-9D84-4D04-B6AA-EED95051A184");
g_hMenuCreateStatistics = mu::clist::addMainMenuItem(
- LPGENT("Create statistics"), 0, 1910000000, IconLib::getIcon(IconLib::iiMenuCreateStatistics), con::SvcCreateStatistics, hRoot);
+ LPGENW("Create statistics"), 0, 1910000000, IconLib::getIcon(IconLib::iiMenuCreateStatistics), con::SvcCreateStatistics, hRoot);
g_hMenuShowStatistics = mu::clist::addMainMenuItem(
- LPGENT("Show statistics"), // MEMO: implicit translation
+ LPGENW("Show statistics"), // MEMO: implicit translation
0, 1910000001, IconLib::getIcon(IconLib::iiMenuShowStatistics), con::SvcShowStatistics, hRoot);
g_hMenuConfigure = mu::clist::addMainMenuItem(
- bInPopup ? LPGENT("Configure...") : LPGENT("Configure statistics..."), // MEMO: implicit translation
+ bInPopup ? LPGENW("Configure...") : LPGENW("Configure statistics..."), // MEMO: implicit translation
0, 1910000002, IconLib::getIcon(IconLib::iiMenuConfigure), con::SvcConfigure, hRoot);
}
@@ -317,7 +317,7 @@ void AddContactMenu()
CreateServiceFunction(con::SvcToggleExclude, MenuToggleExclude);
g_hMenuToggleExclude = mu::clist::addContactMenuItem(
- LPGENT("Exclude from statistics"), // MEMO: implicit translation
+ LPGENW("Exclude from statistics"), // MEMO: implicit translation
0,
800000,
IconLib::getIcon(IconLib::iiContactMenu),
@@ -328,14 +328,14 @@ void AddContactMenu()
CreateServiceFunction(con::SvcHistoryPaste, MenuHistoryPaste);
g_hMenuHistoryCopy = mu::clist::addContactMenuItem(
- LPGENT("Copy history")), // MEMO: implicit translation
+ LPGENW("Copy history")), // MEMO: implicit translation
0,
800001,
NULL,
con::SvcHistoryCopy);
g_hMenuHistoryPaste = mu::clist::addContactMenuItem(
- LPGENT("Paste history...")), // MEMO: implicit translation
+ LPGENW("Paste history...")), // MEMO: implicit translation
0,
800002,
NULL,
diff --git a/plugins/HistoryStats/src/message.cpp b/plugins/HistoryStats/src/message.cpp
index 66a928bc8a..a42974a8fe 100644
--- a/plugins/HistoryStats/src/message.cpp
+++ b/plugins/HistoryStats/src/message.cpp
@@ -22,7 +22,7 @@ void Message::makeRawAvailable()
break;
}
- m_Raw.assign(reinterpret_cast<const TCHAR*>(m_RawSource), m_nLength);
+ m_Raw.assign(reinterpret_cast<const wchar_t*>(m_RawSource), m_nLength);
m_Available |= Raw;
}
while (false);
@@ -42,14 +42,14 @@ void Message::stripRawRTF()
void Message::stripBBCodes()
{
- static const TCHAR* szSimpleBBCodes[][2] = {
+ static const wchar_t* szSimpleBBCodes[][2] = {
{ L"[b]", L"[/b]" },
{ L"[u]", L"[/u]" },
{ L"[i]", L"[/i]" },
{ L"[s]", L"[/s]" },
};
- static const TCHAR* szParamBBCodes[][2] = {
+ static const wchar_t* szParamBBCodes[][2] = {
{ L"[url=", L"[/url]" },
{ L"[color=", L"[/color]" },
};
@@ -60,8 +60,8 @@ void Message::stripBBCodes()
// remove simple BBcodes
array_each_(i, szSimpleBBCodes)
{
- const TCHAR* szOpenTag = szSimpleBBCodes[i][0];
- const TCHAR* szCloseTag = szSimpleBBCodes[i][1];
+ const wchar_t* szOpenTag = szSimpleBBCodes[i][0];
+ const wchar_t* szCloseTag = szSimpleBBCodes[i][1];
int lenOpen = ext::strfunc::len(szOpenTag);
int lenClose = ext::strfunc::len(szCloseTag);
@@ -88,8 +88,8 @@ void Message::stripBBCodes()
// remove BBcodes with parameters
array_each_(i, szParamBBCodes)
{
- const TCHAR* szOpenTag = szParamBBCodes[i][0];
- const TCHAR* szCloseTag = szParamBBCodes[i][1];
+ const wchar_t* szOpenTag = szParamBBCodes[i][0];
+ const wchar_t* szCloseTag = szParamBBCodes[i][1];
int lenOpen = ext::strfunc::len(szOpenTag);
int lenClose = ext::strfunc::len(szCloseTag);
@@ -120,11 +120,11 @@ void Message::stripBBCodes()
void Message::filterLinks()
{
- static const TCHAR* szSpaces = L" \r\r\n";
- static const TCHAR* szPrefixes = L"([{<:\"'";
- static const TCHAR* szSuffixes = L".,:;!?)]}>\"'";
- static const TCHAR* szValidProtocol = L"abcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZ";
- static const TCHAR* szValidHost = L".-abcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZ";
+ static const wchar_t* szSpaces = L" \r\r\n";
+ static const wchar_t* szPrefixes = L"([{<:\"'";
+ static const wchar_t* szSuffixes = L".,:;!?)]}>\"'";
+ static const wchar_t* szValidProtocol = L"abcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZ";
+ static const wchar_t* szValidHost = L".-abcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZ";
// init with raw text
m_WithoutLinks = getRaw();
diff --git a/plugins/HistoryStats/src/message.h b/plugins/HistoryStats/src/message.h
index 6dc9e2f28a..f3aa8e75a7 100644
--- a/plugins/HistoryStats/src/message.h
+++ b/plugins/HistoryStats/src/message.h
@@ -56,7 +56,7 @@ public:
m_Timestamp = localTimestamp;
}
- void assignText(const TCHAR* msg, ext::string::size_type len)
+ void assignText(const wchar_t* msg, ext::string::size_type len)
{
m_RawSource = msg;
m_nLength = len;
diff --git a/plugins/HistoryStats/src/mirandasettings.cpp b/plugins/HistoryStats/src/mirandasettings.cpp
index cc6623545d..e2b9bc9d49 100644
--- a/plugins/HistoryStats/src/mirandasettings.cpp
+++ b/plugins/HistoryStats/src/mirandasettings.cpp
@@ -27,7 +27,7 @@ int MirandaSettings::readDWord(const char* szSetting, int dwDefault) const
return db_get_dw(m_hContact, m_strModule.c_str(), szSetting, dwDefault);
}
-ext::string MirandaSettings::readStr(const char* szSetting, const TCHAR* szDefault) const
+ext::string MirandaSettings::readStr(const char* szSetting, const wchar_t* szDefault) const
{
DBVARIANT dbv;
if (db_get_s(m_hContact, m_strModule.c_str(), szSetting, &dbv))
@@ -38,7 +38,7 @@ ext::string MirandaSettings::readStr(const char* szSetting, const TCHAR* szDefau
return str;
}
-ext::string MirandaSettings::readStrDirect(const char* szSetting, const TCHAR* szDefault) const
+ext::string MirandaSettings::readStrDirect(const char* szSetting, const wchar_t* szDefault) const
{
DBVARIANT dbv;
@@ -73,7 +73,7 @@ ext::string MirandaSettings::readStrDirect(const char* szSetting, const TCHAR* s
return str;
}
-void MirandaSettings::readTree(const char* szSetting, const TCHAR* szDefault, SettingsTree& value) const
+void MirandaSettings::readTree(const char* szSetting, const wchar_t* szDefault, SettingsTree& value) const
{
value.fromString(readStr(szSetting, szDefault));
}
@@ -98,12 +98,12 @@ void MirandaSettings::writeDWord(const char* szSetting, int dwValue) const
db_set_dw(m_hContact, m_strModule.c_str(), szSetting, dwValue);
}
-void MirandaSettings::writeStr(const char* szSetting, const TCHAR* szValue) const
+void MirandaSettings::writeStr(const char* szSetting, const wchar_t* szValue) const
{
db_set_ts(m_hContact, m_strModule.c_str(), szSetting, szValue);
}
-void MirandaSettings::writeStrDirect(const char* szSetting, const TCHAR* szValue) const
+void MirandaSettings::writeStrDirect(const char* szSetting, const wchar_t* szValue) const
{
db_set_ts(m_hContact, m_strModule.c_str(), szSetting, szValue);
}
diff --git a/plugins/HistoryStats/src/mirandasettings.h b/plugins/HistoryStats/src/mirandasettings.h
index 11e743c977..c8671faa4c 100644
--- a/plugins/HistoryStats/src/mirandasettings.h
+++ b/plugins/HistoryStats/src/mirandasettings.h
@@ -39,17 +39,17 @@ public:
int readByte(const char* szSetting, int bDefault) const;
int readWord(const char* szSetting, int wDefault) const;
int readDWord(const char* szSetting, int dwDeault) const;
- ext::string readStr(const char* szSetting, const TCHAR* szDefault) const;
- ext::string readStrDirect(const char* szSetting, const TCHAR* szDefault) const;
- void readTree(const char* szSetting, const TCHAR* szDefault, SettingsTree& value) const;
+ ext::string readStr(const char* szSetting, const wchar_t* szDefault) const;
+ ext::string readStrDirect(const char* szSetting, const wchar_t* szDefault) const;
+ void readTree(const char* szSetting, const wchar_t* szDefault, SettingsTree& value) const;
// writing
void writeBool(const char* szSetting, bool bValue) const;
void writeByte(const char* szSetting, int bValue) const;
void writeWord(const char* szSetting, int wValue) const;
void writeDWord(const char* szSetting, int dwValue) const;
- void writeStr(const char* szSetting, const TCHAR* szValue) const;
- void writeStrDirect(const char* szSetting, const TCHAR* szValue) const;
+ void writeStr(const char* szSetting, const wchar_t* szValue) const;
+ void writeStrDirect(const char* szSetting, const wchar_t* szValue) const;
void writeTree(const char* szSetting, const SettingsTree& value) const;
// misc functions
diff --git a/plugins/HistoryStats/src/mu_common.cpp b/plugins/HistoryStats/src/mu_common.cpp
index 4bdf16a7f1..7b1ee72f8d 100644
--- a/plugins/HistoryStats/src/mu_common.cpp
+++ b/plugins/HistoryStats/src/mu_common.cpp
@@ -15,11 +15,11 @@ namespace mu
namespace clist
{
- HGENMENU addMainMenuItem(const TCHAR* pszName, DWORD flags, int position, HICON hIcon, const char* pszService, HGENMENU hRoot)
+ HGENMENU addMainMenuItem(const wchar_t* pszName, DWORD flags, int position, HICON hIcon, const char* pszService, HGENMENU hRoot)
{
// TODO: support for unicode-core with unicode-aware CList
CMenuItem mi;
- mi.name.t = (TCHAR*)pszName;
+ mi.name.w = (wchar_t*)pszName;
mi.flags = flags | CMIF_TCHAR;
mi.position = position;
mi.hIcolibItem = hIcon;
@@ -29,11 +29,11 @@ namespace mu
return Menu_AddMainMenuItem(&mi);
}
- HGENMENU addContactMenuItem(const TCHAR* pszName, DWORD flags, int position, HICON hIcon, const char* pszService)
+ HGENMENU addContactMenuItem(const wchar_t* pszName, DWORD flags, int position, HICON hIcon, const char* pszService)
{
// TODO: support for unicode-core with unicode-aware CList
CMenuItem mi;
- mi.name.t = (TCHAR*)pszName;
+ mi.name.w = (wchar_t*)pszName;
mi.flags = flags | CMIF_TCHAR;
mi.position = position;
mi.hIcolibItem = hIcon;
@@ -49,12 +49,12 @@ namespace mu
namespace db
{
- int getProfilePath(int cbName, TCHAR* pszName)
+ int getProfilePath(int cbName, wchar_t* pszName)
{
return CallService(MS_DB_GETPROFILEPATHT, cbName, reinterpret_cast<LPARAM>(pszName));
}
- int getProfileName(int cbName, TCHAR* pszName)
+ int getProfileName(int cbName, wchar_t* pszName)
{
return CallService(MS_DB_GETPROFILENAMET, cbName, reinterpret_cast<LPARAM>(pszName));
}
@@ -95,11 +95,11 @@ namespace mu
return true;
}
- void addIcon(const TCHAR* szSection, const TCHAR* szDescription, const char* szIconName, const char* szDefaultFile, int iDefaultIndex)
+ void addIcon(const wchar_t* szSection, const wchar_t* szDescription, const char* szIconName, const char* szDefaultFile, int iDefaultIndex)
{
SKINICONDESC sid = { 0 };
- sid.section.t = const_cast<TCHAR*>(szSection);
- sid.description.t = const_cast<TCHAR*>(szDescription);
+ sid.section.w = const_cast<wchar_t*>(szSection);
+ sid.description.w = const_cast<wchar_t*>(szDescription);
sid.pszName = const_cast<char*>(szIconName);
sid.defaultFile.a = const_cast<char*>(szDefaultFile);
sid.iDefaultIndex = iDefaultIndex;
@@ -119,16 +119,16 @@ namespace mu
namespace opt
{
- void addPage(WPARAM addInfo, const TCHAR* pszGroup, const TCHAR* pszTitle, const TCHAR* pszTab, DLGPROC pfnDlgProc, const char* pszTemplate, HINSTANCE hInstance, DWORD flags /* = ODPF_BOLDGROUPS */)
+ void addPage(WPARAM addInfo, const wchar_t* pszGroup, const wchar_t* pszTitle, const wchar_t* pszTab, DLGPROC pfnDlgProc, const char* pszTemplate, HINSTANCE hInstance, DWORD flags /* = ODPF_BOLDGROUPS */)
{
OPTIONSDIALOGPAGE odp = { 0 };
- odp.ptszTitle = const_cast<TCHAR*>(pszTitle);
+ odp.pwszTitle = const_cast<wchar_t*>(pszTitle);
odp.pfnDlgProc = pfnDlgProc;
odp.pszTemplate = const_cast<char*>(pszTemplate);
odp.hInstance = hInstance;
- odp.ptszGroup = const_cast<TCHAR*>(pszGroup);
+ odp.pwszGroup = const_cast<wchar_t*>(pszGroup);
odp.flags = flags | ODPF_TCHAR;
- odp.ptszTab = const_cast<TCHAR*>(pszTab);
+ odp.pwszTab = const_cast<wchar_t*>(pszTab);
Options_AddPage(addInfo, &odp);
}
}
diff --git a/plugins/HistoryStats/src/mu_common.h b/plugins/HistoryStats/src/mu_common.h
index 98bab3800e..cc82ea61da 100644
--- a/plugins/HistoryStats/src/mu_common.h
+++ b/plugins/HistoryStats/src/mu_common.h
@@ -13,8 +13,8 @@ namespace mu
namespace clist
{
- HGENMENU addMainMenuItem(const TCHAR* pszName, DWORD flags, int position, HICON hIcon, const char* pszService, HGENMENU hRoot = 0);
- HGENMENU addContactMenuItem(const TCHAR* pszName, DWORD flags, int position, HICON hIcon, const char* pszService);
+ HGENMENU addMainMenuItem(const wchar_t* pszName, DWORD flags, int position, HICON hIcon, const char* pszService, HGENMENU hRoot = 0);
+ HGENMENU addContactMenuItem(const wchar_t* pszName, DWORD flags, int position, HICON hIcon, const char* pszService);
}
/*
@@ -23,8 +23,8 @@ namespace mu
namespace db
{
- int getProfilePath(int cbName, TCHAR* pszName);
- int getProfileName(int cbName, TCHAR* pszName);
+ int getProfilePath(int cbName, wchar_t* pszName);
+ int getProfileName(int cbName, wchar_t* pszName);
void setSafetyMode(bool safetyMode);
}
@@ -45,7 +45,7 @@ namespace mu
namespace icolib
{
bool _available();
- void addIcon(const TCHAR* szSection, const TCHAR* szDescription, const char* szIconName, const char* szDefaultFile, int iDefaultIndex);
+ void addIcon(const wchar_t* szSection, const wchar_t* szDescription, const char* szIconName, const char* szDefaultFile, int iDefaultIndex);
HICON getIcon(const char* szIconName);
}
@@ -55,7 +55,7 @@ namespace mu
namespace opt
{
- void addPage(WPARAM addInfo, const TCHAR* pszGroup, const TCHAR* pszTitle, const TCHAR* pszTab, DLGPROC pfnDlgProc, const char* pszTemplate, HINSTANCE hInstance, DWORD flags = ODPF_BOLDGROUPS);
+ void addPage(WPARAM addInfo, const wchar_t* pszGroup, const wchar_t* pszTitle, const wchar_t* pszTab, DLGPROC pfnDlgProc, const char* pszTemplate, HINSTANCE hInstance, DWORD flags = ODPF_BOLDGROUPS);
}
/*
diff --git a/plugins/HistoryStats/src/optionsctrl.cpp b/plugins/HistoryStats/src/optionsctrl.cpp
index 2359259bad..c2b6e2738f 100644
--- a/plugins/HistoryStats/src/optionsctrl.cpp
+++ b/plugins/HistoryStats/src/optionsctrl.cpp
@@ -7,98 +7,98 @@
* OptionsCtrl
*/
-HANDLE OptionsCtrl::insertGroup(HANDLE hParent, const TCHAR* szLabel, DWORD dwFlags /* = 0 */, INT_PTR dwData /* = 0 */)
+HANDLE OptionsCtrl::insertGroup(HANDLE hParent, const wchar_t* szLabel, DWORD dwFlags /* = 0 */, INT_PTR dwData /* = 0 */)
{
OCGROUP ocg;
ocg.dwFlags = dwFlags;
- ocg.szLabel = const_cast<TCHAR*>(szLabel);
+ ocg.szLabel = const_cast<wchar_t*>(szLabel);
ocg.dwData = dwData;
return reinterpret_cast<HANDLE>(SendMessage(m_hOptWnd, OCM_INSERTGROUP, reinterpret_cast<WPARAM>(hParent), reinterpret_cast<LPARAM>(&ocg)));
}
-HANDLE OptionsCtrl::insertCheck(HANDLE hParent, const TCHAR* szLabel, DWORD dwFlags /* = 0 */, INT_PTR dwData /* = 0 */)
+HANDLE OptionsCtrl::insertCheck(HANDLE hParent, const wchar_t* szLabel, DWORD dwFlags /* = 0 */, INT_PTR dwData /* = 0 */)
{
OCCHECK occ;
occ.dwFlags = dwFlags;
- occ.szLabel = const_cast<TCHAR*>(szLabel);
+ occ.szLabel = const_cast<wchar_t*>(szLabel);
occ.dwData = dwData;
return reinterpret_cast<HANDLE>(SendMessage(m_hOptWnd, OCM_INSERTCHECK, reinterpret_cast<WPARAM>(hParent), reinterpret_cast<LPARAM>(&occ)));
}
-HANDLE OptionsCtrl::insertRadio(HANDLE hParent, HANDLE hSibling, const TCHAR* szLabel, DWORD dwFlags /* = 0 */, INT_PTR dwData /* = 0 */)
+HANDLE OptionsCtrl::insertRadio(HANDLE hParent, HANDLE hSibling, const wchar_t* szLabel, DWORD dwFlags /* = 0 */, INT_PTR dwData /* = 0 */)
{
OCRADIO ocr;
ocr.dwFlags = dwFlags;
- ocr.szLabel = const_cast<TCHAR*>(szLabel);
+ ocr.szLabel = const_cast<wchar_t*>(szLabel);
ocr.dwData = dwData;
ocr.hSibling = hSibling;
return reinterpret_cast<HANDLE>(SendMessage(m_hOptWnd, OCM_INSERTRADIO, reinterpret_cast<WPARAM>(hParent), reinterpret_cast<LPARAM>(&ocr)));
}
-HANDLE OptionsCtrl::insertEdit(HANDLE hParent, const TCHAR* szLabel, const TCHAR* szEdit /* = L"" */, DWORD dwFlags /* = 0 */, INT_PTR dwData /* = 0 */)
+HANDLE OptionsCtrl::insertEdit(HANDLE hParent, const wchar_t* szLabel, const wchar_t* szEdit /* = L"" */, DWORD dwFlags /* = 0 */, INT_PTR dwData /* = 0 */)
{
OCEDIT oce;
oce.dwFlags = dwFlags;
- oce.szLabel = const_cast<TCHAR*>(szLabel);
+ oce.szLabel = const_cast<wchar_t*>(szLabel);
oce.dwData = dwData;
- oce.szEdit = const_cast<TCHAR*>(szEdit);
+ oce.szEdit = const_cast<wchar_t*>(szEdit);
return reinterpret_cast<HANDLE>(SendMessage(m_hOptWnd, OCM_INSERTEDIT, reinterpret_cast<WPARAM>(hParent), reinterpret_cast<LPARAM>(&oce)));
}
-HANDLE OptionsCtrl::insertCombo(HANDLE hParent, const TCHAR* szLabel, DWORD dwFlags /* = 0 */, INT_PTR dwData /* = 0 */)
+HANDLE OptionsCtrl::insertCombo(HANDLE hParent, const wchar_t* szLabel, DWORD dwFlags /* = 0 */, INT_PTR dwData /* = 0 */)
{
OCCOMBO occ;
occ.dwFlags = dwFlags;
- occ.szLabel = const_cast<TCHAR*>(szLabel);
+ occ.szLabel = const_cast<wchar_t*>(szLabel);
occ.dwData = dwData;
return reinterpret_cast<HANDLE>(SendMessage(m_hOptWnd, OCM_INSERTCOMBO, reinterpret_cast<WPARAM>(hParent), reinterpret_cast<LPARAM>(&occ)));
}
-HANDLE OptionsCtrl::insertButton(HANDLE hParent, const TCHAR* szLabel, const TCHAR* szButton, DWORD dwFlags /* = 0 */, INT_PTR dwData /* = 0 */)
+HANDLE OptionsCtrl::insertButton(HANDLE hParent, const wchar_t* szLabel, const wchar_t* szButton, DWORD dwFlags /* = 0 */, INT_PTR dwData /* = 0 */)
{
OCBUTTON ocb;
ocb.dwFlags = dwFlags;
- ocb.szLabel = const_cast<TCHAR*>(szLabel);
+ ocb.szLabel = const_cast<wchar_t*>(szLabel);
ocb.dwData = dwData;
- ocb.szButton = const_cast<TCHAR*>(szButton);
+ ocb.szButton = const_cast<wchar_t*>(szButton);
return reinterpret_cast<HANDLE>(SendMessage(m_hOptWnd, OCM_INSERTBUTTON, reinterpret_cast<WPARAM>(hParent), reinterpret_cast<LPARAM>(&ocb)));
}
-HANDLE OptionsCtrl::insertDateTime(HANDLE hParent, const TCHAR* szLabel, DWORD dwDateTime, const TCHAR* szFormat /* = L"%Y-%m-%d" */, DWORD dwFlags /* = 0 */, INT_PTR dwData /* = 0 */)
+HANDLE OptionsCtrl::insertDateTime(HANDLE hParent, const wchar_t* szLabel, DWORD dwDateTime, const wchar_t* szFormat /* = L"%Y-%m-%d" */, DWORD dwFlags /* = 0 */, INT_PTR dwData /* = 0 */)
{
OCDATETIME ocdt;
ocdt.dwFlags = dwFlags;
- ocdt.szLabel = const_cast<TCHAR*>(szLabel);
+ ocdt.szLabel = const_cast<wchar_t*>(szLabel);
ocdt.dwData = dwData;
- ocdt.szFormat = const_cast<TCHAR*>(szFormat);
+ ocdt.szFormat = const_cast<wchar_t*>(szFormat);
ocdt.dwDateTime = dwDateTime;
return reinterpret_cast<HANDLE>(SendMessage(m_hOptWnd, OCM_INSERTDATETIME, reinterpret_cast<WPARAM>(hParent), reinterpret_cast<LPARAM>(&ocdt)));
}
-HANDLE OptionsCtrl::insertColor(HANDLE hParent, const TCHAR* szLabel, COLORREF crColor /* = 0 */, DWORD dwFlags /* = 0 */, INT_PTR dwData /* = 0 */)
+HANDLE OptionsCtrl::insertColor(HANDLE hParent, const wchar_t* szLabel, COLORREF crColor /* = 0 */, DWORD dwFlags /* = 0 */, INT_PTR dwData /* = 0 */)
{
OCCOLOR occ;
occ.dwFlags = dwFlags;
- occ.szLabel = const_cast<TCHAR*>(szLabel);
+ occ.szLabel = const_cast<wchar_t*>(szLabel);
occ.dwData = dwData;
occ.crColor = crColor;
return reinterpret_cast<HANDLE>(SendMessage(m_hOptWnd, OCM_INSERTCOLOR, reinterpret_cast<WPARAM>(hParent), reinterpret_cast<LPARAM>(&occ)));
}
-const TCHAR* OptionsCtrl::getItemLabel(HANDLE hItem)
+const wchar_t* OptionsCtrl::getItemLabel(HANDLE hItem)
{
- return reinterpret_cast<const TCHAR*>(SendMessage(m_hOptWnd, OCM_GETITEMLABEL, reinterpret_cast<WPARAM>(hItem), 0));
+ return reinterpret_cast<const wchar_t*>(SendMessage(m_hOptWnd, OCM_GETITEMLABEL, reinterpret_cast<WPARAM>(hItem), 0));
}
-void OptionsCtrl::setItemLabel(HANDLE hItem, const TCHAR* szLabel)
+void OptionsCtrl::setItemLabel(HANDLE hItem, const wchar_t* szLabel)
{
SendMessage(m_hOptWnd, OCM_SETITEMLABEL, reinterpret_cast<WPARAM>(hItem), reinterpret_cast<LPARAM>(szLabel));
}
@@ -153,17 +153,17 @@ void OptionsCtrl::setEditNumber(HANDLE hEdit, int nNumber)
SendMessage(m_hOptWnd, OCM_SETEDITNUMBER, reinterpret_cast<WPARAM>(hEdit), nNumber);
}
-const TCHAR* OptionsCtrl::getEditString(HANDLE hEdit)
+const wchar_t* OptionsCtrl::getEditString(HANDLE hEdit)
{
- return reinterpret_cast<const TCHAR*>(SendMessage(m_hOptWnd, OCM_GETEDITSTRING, reinterpret_cast<WPARAM>(hEdit), 0));
+ return reinterpret_cast<const wchar_t*>(SendMessage(m_hOptWnd, OCM_GETEDITSTRING, reinterpret_cast<WPARAM>(hEdit), 0));
}
-void OptionsCtrl::setEditString(HANDLE hEdit, const TCHAR* szString)
+void OptionsCtrl::setEditString(HANDLE hEdit, const wchar_t* szString)
{
SendMessage(m_hOptWnd, OCM_SETEDITSTRING, reinterpret_cast<WPARAM>(hEdit), reinterpret_cast<LPARAM>(szString));
}
-void OptionsCtrl::addComboItem(HANDLE hCombo, const TCHAR* szItem)
+void OptionsCtrl::addComboItem(HANDLE hCombo, const wchar_t* szItem)
{
SendMessage(m_hOptWnd, OCM_ADDCOMBOITEM, reinterpret_cast<WPARAM>(hCombo), reinterpret_cast<LPARAM>(szItem));
}
diff --git a/plugins/HistoryStats/src/optionsctrl.h b/plugins/HistoryStats/src/optionsctrl.h
index 026a535176..629249e99b 100644
--- a/plugins/HistoryStats/src/optionsctrl.h
+++ b/plugins/HistoryStats/src/optionsctrl.h
@@ -39,16 +39,16 @@ public:
operator HWND() { return m_hOptWnd; }
public:
- HANDLE insertGroup(HANDLE hParent, const TCHAR* szLabel, DWORD dwFlags = 0, INT_PTR dwData = 0);
- HANDLE insertCheck(HANDLE hParent, const TCHAR* szLabel, DWORD dwFlags = 0, INT_PTR dwData = 0);
- HANDLE insertRadio(HANDLE hParent, HANDLE hSibling, const TCHAR* szLabel, DWORD dwFlags = 0, INT_PTR dwData = 0);
- HANDLE insertEdit(HANDLE hParent, const TCHAR* szLabel, const TCHAR* szEdit = L"", DWORD dwFlags = 0, INT_PTR dwData = 0);
- HANDLE insertCombo(HANDLE hParent, const TCHAR* szLabel, DWORD dwFlags = 0, INT_PTR dwData = 0);
- HANDLE insertButton(HANDLE hParent, const TCHAR* szLabel, const TCHAR* szButton, DWORD dwFlags = 0, INT_PTR dwData = 0);
- HANDLE insertDateTime(HANDLE hParent, const TCHAR* szLabel, DWORD dwDateTime, const TCHAR* szFormat = L"%Y-%m-%d", DWORD dwFlags = 0, INT_PTR dwData = 0);
- HANDLE insertColor(HANDLE hParent, const TCHAR* szLabel, COLORREF crColor = 0, DWORD dwFlags = 0, INT_PTR dwData = 0);
- const TCHAR* getItemLabel(HANDLE hItem);
- void setItemLabel(HANDLE hItem, const TCHAR* szLabel);
+ HANDLE insertGroup(HANDLE hParent, const wchar_t* szLabel, DWORD dwFlags = 0, INT_PTR dwData = 0);
+ HANDLE insertCheck(HANDLE hParent, const wchar_t* szLabel, DWORD dwFlags = 0, INT_PTR dwData = 0);
+ HANDLE insertRadio(HANDLE hParent, HANDLE hSibling, const wchar_t* szLabel, DWORD dwFlags = 0, INT_PTR dwData = 0);
+ HANDLE insertEdit(HANDLE hParent, const wchar_t* szLabel, const wchar_t* szEdit = L"", DWORD dwFlags = 0, INT_PTR dwData = 0);
+ HANDLE insertCombo(HANDLE hParent, const wchar_t* szLabel, DWORD dwFlags = 0, INT_PTR dwData = 0);
+ HANDLE insertButton(HANDLE hParent, const wchar_t* szLabel, const wchar_t* szButton, DWORD dwFlags = 0, INT_PTR dwData = 0);
+ HANDLE insertDateTime(HANDLE hParent, const wchar_t* szLabel, DWORD dwDateTime, const wchar_t* szFormat = L"%Y-%m-%d", DWORD dwFlags = 0, INT_PTR dwData = 0);
+ HANDLE insertColor(HANDLE hParent, const wchar_t* szLabel, COLORREF crColor = 0, DWORD dwFlags = 0, INT_PTR dwData = 0);
+ const wchar_t* getItemLabel(HANDLE hItem);
+ void setItemLabel(HANDLE hItem, const wchar_t* szLabel);
bool isItemEnabled(HANDLE hItem);
void enableItem(HANDLE hItem, bool bEnable);
DWORD getItemData(HANDLE hItem);
@@ -59,9 +59,9 @@ public:
void setRadioChecked(HANDLE hRadio, int nCheck);
int getEditNumber(HANDLE hEdit);
void setEditNumber(HANDLE hEdit, int nNumber);
- const TCHAR* getEditString(HANDLE hEdit);
- void setEditString(HANDLE hEdit, const TCHAR* szString);
- void addComboItem(HANDLE hCombo, const TCHAR* szItem);
+ const wchar_t* getEditString(HANDLE hEdit);
+ void setEditString(HANDLE hEdit, const wchar_t* szString);
+ void addComboItem(HANDLE hCombo, const wchar_t* szItem);
int getComboSelected(HANDLE hCombo);
void setComboSelected(HANDLE hCombo, int nSelect);
void ensureVisible(HANDLE hItem);
diff --git a/plugins/HistoryStats/src/optionsctrldefs.h b/plugins/HistoryStats/src/optionsctrldefs.h
index 837a41924e..7b24009cdf 100644
--- a/plugins/HistoryStats/src/optionsctrldefs.h
+++ b/plugins/HistoryStats/src/optionsctrldefs.h
@@ -17,8 +17,8 @@ public:
OCM_INSERTEDIT = WM_USER + 3, // (HANDLE hParent, OCEDIT* pEdit) -> HANDLE hEdit [Edit]
OCM_INSERTCOMBO = WM_USER + 4, // (HANDLE hParent, OCCOMBO* pCombo) -> HANDLE hCombo [Combo]
OCM_INSERTBUTTON = WM_USER + 5, // (HANDLE hParent, OCBUTTON* pButton) -> HANDLE hButton [Button]
- OCM_GETITEMLABEL = WM_USER + 6, // (HANDLE hItem, #) -> const TCHAR* szLabel
- OCM_SETITEMLABEL = WM_USER + 7, // (HANDLE hItem, const TCHAR* szLabel) -> #
+ OCM_GETITEMLABEL = WM_USER + 6, // (HANDLE hItem, #) -> const wchar_t* szLabel
+ OCM_SETITEMLABEL = WM_USER + 7, // (HANDLE hItem, const wchar_t* szLabel) -> #
OCM_ISITEMENABLED = WM_USER + 8, // (HANDLE hItem, #) -> BOOL bEnabled
OCM_ENABLEITEM = WM_USER + 9, // (HANDLE hItem, BOOL bEnable) -> #
OCM_GETITEMDATA = WM_USER + 10, // (HANDLE hItem, #) -> INT_PTR dwData
@@ -29,9 +29,9 @@ public:
OCM_SETRADIOCHECKED = WM_USER + 15, // (HANDLE hRadio, int nCheck) -> # [Radio]
OCM_GETEDITNUMBER = WM_USER + 16, // (HANDLE hEdit, #) -> int nNumber [Edit]
OCM_SETEDITNUMBER = WM_USER + 17, // (HANDLE hEdit, int nNumber) -> # [Edit]
- OCM_GETEDITSTRING = WM_USER + 18, // (HANDLE hEdit, #) -> const TCHAR* szString [Edit]
- OCM_SETEDITSTRING = WM_USER + 19, // (HANDLE hEdit, const TCHAR* szString) -> # [Edit]
- OCM_ADDCOMBOITEM = WM_USER + 20, // (HANDLE hCombo, const TCHAR* szItem) -> # [Combo]
+ OCM_GETEDITSTRING = WM_USER + 18, // (HANDLE hEdit, #) -> const wchar_t* szString [Edit]
+ OCM_SETEDITSTRING = WM_USER + 19, // (HANDLE hEdit, const wchar_t* szString) -> # [Edit]
+ OCM_ADDCOMBOITEM = WM_USER + 20, // (HANDLE hCombo, const wchar_t* szItem) -> # [Combo]
OCM_GETCOMBOSELECTED = WM_USER + 21, // (HANDLE hCombo, #) -> int nSelected [Combo]
OCM_SETCOMBOSELECTED = WM_USER + 22, // (HANDLE hCombo, int nSelect) -> # [Combo]
OCM_ENSUREVISIBLE = WM_USER + 23, // (HANDLE hItem, #) -> #
@@ -89,54 +89,54 @@ public:
struct OCGROUP {
DWORD dwFlags;
- TCHAR* szLabel;
+ wchar_t* szLabel;
INT_PTR dwData;
};
struct OCCHECK {
DWORD dwFlags;
- TCHAR* szLabel;
+ wchar_t* szLabel;
INT_PTR dwData;
};
struct OCRADIO {
DWORD dwFlags;
- TCHAR* szLabel;
+ wchar_t* szLabel;
INT_PTR dwData;
HANDLE hSibling;
};
struct OCEDIT {
DWORD dwFlags;
- TCHAR* szLabel;
+ wchar_t* szLabel;
INT_PTR dwData;
- TCHAR* szEdit;
+ wchar_t* szEdit;
};
struct OCCOMBO {
DWORD dwFlags;
- TCHAR* szLabel;
+ wchar_t* szLabel;
INT_PTR dwData;
};
struct OCBUTTON {
DWORD dwFlags;
- TCHAR* szLabel;
+ wchar_t* szLabel;
INT_PTR dwData;
- TCHAR* szButton;
+ wchar_t* szButton;
};
struct OCDATETIME {
DWORD dwFlags;
- TCHAR* szLabel;
+ wchar_t* szLabel;
INT_PTR dwData;
- TCHAR* szFormat;
+ wchar_t* szFormat;
DWORD dwDateTime;
};
struct OCCOLOR {
DWORD dwFlags;
- TCHAR* szLabel;
+ wchar_t* szLabel;
INT_PTR dwData;
COLORREF crColor;
};
diff --git a/plugins/HistoryStats/src/optionsctrlimpl.cpp b/plugins/HistoryStats/src/optionsctrlimpl.cpp
index f4d8e55e5e..95c17cd380 100644
--- a/plugins/HistoryStats/src/optionsctrlimpl.cpp
+++ b/plugins/HistoryStats/src/optionsctrlimpl.cpp
@@ -8,7 +8,7 @@
* OptionsCtrlImpl
*/
-const TCHAR* OptionsCtrlImpl::m_ClassName = L"HistoryStatsOptions";
+const wchar_t* OptionsCtrlImpl::m_ClassName = L"HistoryStatsOptions";
HIMAGELIST OptionsCtrlImpl::m_hStateIcons = NULL;
int OptionsCtrlImpl::m_nStateIconsRef = 0;
@@ -140,7 +140,7 @@ LRESULT CALLBACK OptionsCtrlImpl::staticWndProc(HWND hWnd, UINT msg, WPARAM wPar
return reinterpret_cast<LRESULT>(pCtrl->onOCMGetItemLabel(reinterpret_cast<HTREEITEM>(wParam)));
case OCM_SETITEMLABEL:
- pCtrl->onOCMSetItemLabel(reinterpret_cast<HTREEITEM>(wParam), reinterpret_cast<const TCHAR*>(lParam));
+ pCtrl->onOCMSetItemLabel(reinterpret_cast<HTREEITEM>(wParam), reinterpret_cast<const wchar_t*>(lParam));
return 0;
case OCM_ISITEMENABLED:
@@ -182,11 +182,11 @@ LRESULT CALLBACK OptionsCtrlImpl::staticWndProc(HWND hWnd, UINT msg, WPARAM wPar
return reinterpret_cast<LPARAM>(pCtrl->onOCMGetEditString(reinterpret_cast<HTREEITEM>(wParam)));
case OCM_SETEDITSTRING:
- pCtrl->onOCMSetEditString(reinterpret_cast<HTREEITEM>(wParam), reinterpret_cast<const TCHAR*>(lParam));
+ pCtrl->onOCMSetEditString(reinterpret_cast<HTREEITEM>(wParam), reinterpret_cast<const wchar_t*>(lParam));
return 0;
case OCM_ADDCOMBOITEM:
- pCtrl->onOCMAddComboItem(reinterpret_cast<HTREEITEM>(wParam), reinterpret_cast<const TCHAR*>(lParam));
+ pCtrl->onOCMAddComboItem(reinterpret_cast<HTREEITEM>(wParam), reinterpret_cast<const wchar_t*>(lParam));
return 0;
case OCM_GETCOMBOSELECTED:
@@ -839,12 +839,12 @@ HTREEITEM OptionsCtrlImpl::onOCMInsertColor(HTREEITEM hParent, OCCOLOR* pColor)
return (new Color(this, hParent ? getItem(hParent) : NULL, pColor->szLabel, pColor->crColor, pColor->dwFlags, pColor->dwData))->m_hItem;
}
-const TCHAR* OptionsCtrlImpl::onOCMGetItemLabel(HTREEITEM hItem)
+const wchar_t* OptionsCtrlImpl::onOCMGetItemLabel(HTREEITEM hItem)
{
return getItem(hItem)->getLabel();
}
-void OptionsCtrlImpl::onOCMSetItemLabel(HTREEITEM hItem, const TCHAR* szLabel)
+void OptionsCtrlImpl::onOCMSetItemLabel(HTREEITEM hItem, const wchar_t* szLabel)
{
assert(szLabel);
@@ -928,7 +928,7 @@ void OptionsCtrlImpl::onOCMSetEditNumber(HTREEITEM hEdit, int nNumber)
reinterpret_cast<Edit*>(pEdit)->setNumber(nNumber);
}
-const TCHAR* OptionsCtrlImpl::onOCMGetEditString(HTREEITEM hEdit)
+const wchar_t* OptionsCtrlImpl::onOCMGetEditString(HTREEITEM hEdit)
{
Item* pEdit = getItem(hEdit);
@@ -937,7 +937,7 @@ const TCHAR* OptionsCtrlImpl::onOCMGetEditString(HTREEITEM hEdit)
return reinterpret_cast<Edit*>(pEdit)->getString();
}
-void OptionsCtrlImpl::onOCMSetEditString(HTREEITEM hEdit, const TCHAR *szString)
+void OptionsCtrlImpl::onOCMSetEditString(HTREEITEM hEdit, const wchar_t *szString)
{
assert(szString);
@@ -948,7 +948,7 @@ void OptionsCtrlImpl::onOCMSetEditString(HTREEITEM hEdit, const TCHAR *szString)
reinterpret_cast<Edit*>(pEdit)->setString(szString);
}
-void OptionsCtrlImpl::onOCMAddComboItem(HTREEITEM hCombo, const TCHAR* szItem)
+void OptionsCtrlImpl::onOCMAddComboItem(HTREEITEM hCombo, const wchar_t* szItem)
{
assert(szItem);
@@ -1111,7 +1111,7 @@ void OptionsCtrlImpl::onOCMSetItemColor(HTREEITEM hColor, COLORREF crColor)
reinterpret_cast<Color*>(pColor)->setColor(crColor);
}
-void OptionsCtrlImpl::insertItem(Item* pParent, Item* pItem, const TCHAR* szNodeText, DWORD dwFlags, int iImage)
+void OptionsCtrlImpl::insertItem(Item* pParent, Item* pItem, const wchar_t* szNodeText, DWORD dwFlags, int iImage)
{
assert(!pParent || pParent->m_hItem);
assert(pItem);
@@ -1121,7 +1121,7 @@ void OptionsCtrlImpl::insertItem(Item* pParent, Item* pItem, const TCHAR* szNode
tvis.hParent = pParent ? pParent->m_hItem : TVI_ROOT;
tvis.hInsertAfter = TVI_LAST;
tvis.item.mask = TVIF_TEXT | TVIF_IMAGE | TVIF_SELECTEDIMAGE | TVIF_STATE | TVIF_PARAM;
- tvis.item.pszText = const_cast<TCHAR*>(szNodeText);
+ tvis.item.pszText = const_cast<wchar_t*>(szNodeText);
tvis.item.iImage = iImage;
tvis.item.iSelectedImage = iImage;
tvis.item.stateMask = TVIS_EXPANDED | ((dwFlags & OCF_BOLD) ? TVIS_BOLD : 0);
@@ -1192,7 +1192,7 @@ void OptionsCtrlImpl::setStateImage(HTREEITEM hItem, int iImage)
TreeView_SetItem(m_hTree, &tvi);
}
-void OptionsCtrlImpl::setNodeText(HTREEITEM hItem, const TCHAR* szNodeText)
+void OptionsCtrlImpl::setNodeText(HTREEITEM hItem, const wchar_t* szNodeText)
{
assert(hItem);
assert(szNodeText);
@@ -1200,7 +1200,7 @@ void OptionsCtrlImpl::setNodeText(HTREEITEM hItem, const TCHAR* szNodeText)
TVITEM tvi;
tvi.mask = TVIF_HANDLE | TVIF_TEXT;
tvi.hItem = hItem;
- tvi.pszText = const_cast<TCHAR*>(szNodeText);
+ tvi.pszText = const_cast<wchar_t*>(szNodeText);
TreeView_SetItem(m_hTree, &tvi);
}
diff --git a/plugins/HistoryStats/src/optionsctrlimpl.h b/plugins/HistoryStats/src/optionsctrlimpl.h
index e931aa8933..97d27a92a2 100644
--- a/plugins/HistoryStats/src/optionsctrlimpl.h
+++ b/plugins/HistoryStats/src/optionsctrlimpl.h
@@ -76,7 +76,7 @@ private:
INT_PTR m_dwData;
protected:
- explicit Item(OptionsCtrlImpl* pCtrl, ItemType ItemType, const TCHAR* szLabel, DWORD dwFlags, INT_PTR dwData);
+ explicit Item(OptionsCtrlImpl* pCtrl, ItemType ItemType, const wchar_t* szLabel, DWORD dwFlags, INT_PTR dwData);
void enableChilds(bool bEnable);
@@ -91,8 +91,8 @@ private:
virtual void setEnabled(bool bEnable) = 0;
virtual void childAdded(Item* pChild) = 0;
- virtual void setLabel(const TCHAR* szLabel);
- virtual const TCHAR* getLabel() { return m_strLabel.c_str(); }
+ virtual void setLabel(const wchar_t* szLabel);
+ virtual const wchar_t* getLabel() { return m_strLabel.c_str(); }
};
class Group
@@ -102,7 +102,7 @@ private:
bool m_bDrawLine;
public:
- explicit Group(OptionsCtrlImpl* pCtrl, Item* pParent, const TCHAR* szLabel, DWORD dwFlags, INT_PTR dwData);
+ explicit Group(OptionsCtrlImpl* pCtrl, Item* pParent, const wchar_t* szLabel, DWORD dwFlags, INT_PTR dwData);
virtual void setEnabled(bool bEnable);
virtual void childAdded(Item* pChild);
@@ -122,7 +122,7 @@ private:
void updateItem();
public:
- explicit Check(OptionsCtrlImpl* pCtrl, Item* pParent, const TCHAR* szLabel, DWORD dwFlags, INT_PTR dwData);
+ explicit Check(OptionsCtrlImpl* pCtrl, Item* pParent, const wchar_t* szLabel, DWORD dwFlags, INT_PTR dwData);
virtual void onToggle();
@@ -171,7 +171,7 @@ private:
void updateItem();
public:
- explicit Radio(OptionsCtrlImpl* pCtrl, Item* pParent, Radio* pSibling, const TCHAR* szLabel, DWORD dwFlags, INT_PTR dwData);
+ explicit Radio(OptionsCtrlImpl* pCtrl, Item* pParent, Radio* pSibling, const wchar_t* szLabel, DWORD dwFlags, INT_PTR dwData);
virtual ~Radio();
virtual void onToggle();
@@ -196,7 +196,7 @@ private:
ext::string getCombinedText();
public:
- explicit Edit(OptionsCtrlImpl* pCtrl, Item* pParent, const TCHAR* szLabel, const TCHAR* szEdit, DWORD dwFlags, INT_PTR dwData);
+ explicit Edit(OptionsCtrlImpl* pCtrl, Item* pParent, const wchar_t* szLabel, const wchar_t* szEdit, DWORD dwFlags, INT_PTR dwData);
virtual void onToggle() { onActivate(); }
virtual void onSelect();
@@ -206,11 +206,11 @@ private:
virtual void setEnabled(bool bEnable);
virtual void childAdded(Item* pChild);
- virtual void setLabel(const TCHAR* szLabel);
+ virtual void setLabel(const wchar_t* szLabel);
- const TCHAR* getString();
- void setString(const TCHAR* szString);
- int getNumber() { return _ttoi(getString()); }
+ const wchar_t* getString();
+ void setString(const wchar_t* szString);
+ int getNumber() { return _wtoi(getString()); }
void setNumber(int nNumber) { setString(utils::intToString(nNumber).c_str()); }
};
@@ -230,7 +230,7 @@ private:
ext::string getCombinedText();
public:
- explicit Combo(OptionsCtrlImpl* pCtrl, Item* pParent, const TCHAR* szLabel, DWORD dwFlags, INT_PTR dwData);
+ explicit Combo(OptionsCtrlImpl* pCtrl, Item* pParent, const wchar_t* szLabel, DWORD dwFlags, INT_PTR dwData);
virtual void onToggle() { onActivate(); }
virtual void onSelect();
@@ -240,9 +240,9 @@ private:
virtual void setEnabled(bool bEnable);
virtual void childAdded(Item* pChild);
- virtual void setLabel(const TCHAR* szLabel);
+ virtual void setLabel(const wchar_t* szLabel);
- void addItem(const TCHAR* szItem);
+ void addItem(const wchar_t* szItem);
int getSelected();
void setSelected(int nSelect);
void onSelChanged();
@@ -256,7 +256,7 @@ private:
HWND m_hButtonWnd;
public:
- explicit Button(OptionsCtrlImpl* pCtrl, Item* pParent, const TCHAR* szLabel, const TCHAR* szButton, DWORD dwFlags, INT_PTR dwData);
+ explicit Button(OptionsCtrlImpl* pCtrl, Item* pParent, const wchar_t* szLabel, const wchar_t* szButton, DWORD dwFlags, INT_PTR dwData);
virtual void onToggle() { onActivate(); }
virtual void onSelect();
@@ -266,7 +266,7 @@ private:
virtual void setEnabled(bool bEnable);
virtual void childAdded(Item* pChild);
- virtual void setLabel(const TCHAR* szLabel);
+ virtual void setLabel(const wchar_t* szLabel);
};
class DateTime
@@ -294,7 +294,7 @@ private:
ext::string getCombinedText();
public:
- explicit DateTime(OptionsCtrlImpl* pCtrl, Item* pParent, const TCHAR* szLabel, const TCHAR* szFormat, time_t timestamp, DWORD dwFlags, INT_PTR dwData);
+ explicit DateTime(OptionsCtrlImpl* pCtrl, Item* pParent, const wchar_t* szLabel, const wchar_t* szFormat, time_t timestamp, DWORD dwFlags, INT_PTR dwData);
virtual void onToggle() { onActivate(); }
virtual void onSelect();
@@ -304,7 +304,7 @@ private:
virtual void setEnabled(bool bEnable);
virtual void childAdded(Item* pChild);
- virtual void setLabel(const TCHAR* szLabel);
+ virtual void setLabel(const wchar_t* szLabel);
bool isNone();
void setNone();
@@ -325,7 +325,7 @@ private:
COLORREF getColorValue();
public:
- explicit Color(OptionsCtrlImpl* pCtrl, Item* pParent, const TCHAR* szLabel, COLORREF crColor, DWORD dwFlags, INT_PTR dwData);
+ explicit Color(OptionsCtrlImpl* pCtrl, Item* pParent, const wchar_t* szLabel, COLORREF crColor, DWORD dwFlags, INT_PTR dwData);
virtual void onToggle() { onActivate(); }
virtual void onSelect();
@@ -335,7 +335,7 @@ private:
virtual void setEnabled(bool bEnable);
virtual void childAdded(Item* pChild);
- virtual void setLabel(const TCHAR* szLabel);
+ virtual void setLabel(const wchar_t* szLabel);
COLORREF getColor();
void setColor(COLORREF crColor);
@@ -343,7 +343,7 @@ private:
};
private:
- static const TCHAR* m_ClassName;
+ static const wchar_t* m_ClassName;
static HIMAGELIST m_hStateIcons;
static int m_nStateIconsRef;
@@ -402,8 +402,8 @@ private:
HTREEITEM onOCMInsertButton(HTREEITEM hParent, OCBUTTON* pButton);
HTREEITEM onOCMInsertDateTime(HTREEITEM hParent, OCDATETIME* pDateTime);
HTREEITEM onOCMInsertColor(HTREEITEM hParent, OCCOLOR* pColor);
- const TCHAR* onOCMGetItemLabel(HTREEITEM hItem);
- void onOCMSetItemLabel(HTREEITEM hItem, const TCHAR* szLabel);
+ const wchar_t* onOCMGetItemLabel(HTREEITEM hItem);
+ void onOCMSetItemLabel(HTREEITEM hItem, const wchar_t* szLabel);
bool onOCMIsItemEnabled(HTREEITEM hItem);
void onOCMEnableItem(HTREEITEM hItem, bool bEnable);
DWORD onOCMGetItemData(HTREEITEM hItem);
@@ -414,9 +414,9 @@ private:
void onOCMSetRadioChecked(HTREEITEM hRadio, int nCheck);
int onOCMGetEditNumber(HTREEITEM hEdit);
void onOCMSetEditNumber(HTREEITEM hEdit, int nNumber);
- const TCHAR* onOCMGetEditString(HTREEITEM hEdit);
- void onOCMSetEditString(HTREEITEM hEdit, const TCHAR *szString);
- void onOCMAddComboItem(HTREEITEM hCombo, const TCHAR* szItem);
+ const wchar_t* onOCMGetEditString(HTREEITEM hEdit);
+ void onOCMSetEditString(HTREEITEM hEdit, const wchar_t *szString);
+ void onOCMAddComboItem(HTREEITEM hCombo, const wchar_t* szItem);
int onOCMGetComboSelected(HTREEITEM hCombo);
void onOCMSetComboSelected(HTREEITEM hCombo, int nSelect);
void onOCMEnsureVisible(HTREEITEM hItem);
@@ -434,13 +434,13 @@ private:
void onOCMSetItemColor(HTREEITEM hColor, COLORREF crColor);
private:
- void insertItem(Item* pParent, Item* pItem, const TCHAR* szNodeText, DWORD dwFlags, int iImage);
+ void insertItem(Item* pParent, Item* pItem, const wchar_t* szNodeText, DWORD dwFlags, int iImage);
void setModified(Item* pItem, bool bModified = true);
bool isItemValid(HTREEITEM hItem);
Item* getItem(HTREEITEM hItem);
void setItem(HTREEITEM hItem, Item* pItem);
void setStateImage(HTREEITEM hItem, int iImage);
- void setNodeText(HTREEITEM hItem, const TCHAR* szNodeText);
+ void setNodeText(HTREEITEM hItem, const wchar_t* szNodeText);
bool getItemFreeRect(HTREEITEM hItem, RECT& outRect);
};
diff --git a/plugins/HistoryStats/src/optionsctrlimpl_button.cpp b/plugins/HistoryStats/src/optionsctrlimpl_button.cpp
index 5c56523322..868fa46436 100644
--- a/plugins/HistoryStats/src/optionsctrlimpl_button.cpp
+++ b/plugins/HistoryStats/src/optionsctrlimpl_button.cpp
@@ -7,7 +7,7 @@
* OptionsCtrlImpl::Button
*/
-OptionsCtrlImpl::Button::Button(OptionsCtrlImpl* pCtrl, Item* pParent, const TCHAR* szLabel, const TCHAR* szButton, DWORD dwFlags, INT_PTR dwData)
+OptionsCtrlImpl::Button::Button(OptionsCtrlImpl* pCtrl, Item* pParent, const wchar_t* szLabel, const wchar_t* szButton, DWORD dwFlags, INT_PTR dwData)
: Item(pCtrl, itButton, szLabel, dwFlags, dwData)
, m_hButtonWnd(NULL)
, m_strButton(szButton)
@@ -113,7 +113,7 @@ void OptionsCtrlImpl::Button::childAdded(Item* pChild)
}
}
-void OptionsCtrlImpl::Button::setLabel(const TCHAR* szLabel)
+void OptionsCtrlImpl::Button::setLabel(const wchar_t* szLabel)
{
m_strLabel = szLabel;
diff --git a/plugins/HistoryStats/src/optionsctrlimpl_check.cpp b/plugins/HistoryStats/src/optionsctrlimpl_check.cpp
index 351c77b1d0..8776224299 100644
--- a/plugins/HistoryStats/src/optionsctrlimpl_check.cpp
+++ b/plugins/HistoryStats/src/optionsctrlimpl_check.cpp
@@ -25,7 +25,7 @@ void OptionsCtrlImpl::Check::updateItem()
enableChilds(getChildEnable());
}
-OptionsCtrlImpl::Check::Check(OptionsCtrlImpl* pCtrl, Item* pParent, const TCHAR* szLabel, DWORD dwFlags, INT_PTR dwData) :
+OptionsCtrlImpl::Check::Check(OptionsCtrlImpl* pCtrl, Item* pParent, const wchar_t* szLabel, DWORD dwFlags, INT_PTR dwData) :
Item(pCtrl, itCheck, szLabel, dwFlags, dwData)
{
m_bChecked = bool_(dwFlags & OCF_CHECKED);
diff --git a/plugins/HistoryStats/src/optionsctrlimpl_color.cpp b/plugins/HistoryStats/src/optionsctrlimpl_color.cpp
index a8991041f1..e0b330d147 100644
--- a/plugins/HistoryStats/src/optionsctrlimpl_color.cpp
+++ b/plugins/HistoryStats/src/optionsctrlimpl_color.cpp
@@ -12,7 +12,7 @@ COLORREF OptionsCtrlImpl::Color::getColorValue()
return SendMessage(m_hColorWnd, CPM_GETCOLOUR, 0, 0);
}
-OptionsCtrlImpl::Color::Color(OptionsCtrlImpl* pCtrl, Item* pParent, const TCHAR* szLabel, COLORREF crColor, DWORD dwFlags, INT_PTR dwData)
+OptionsCtrlImpl::Color::Color(OptionsCtrlImpl* pCtrl, Item* pParent, const wchar_t* szLabel, COLORREF crColor, DWORD dwFlags, INT_PTR dwData)
: Item(pCtrl, itColor, szLabel, dwFlags, dwData)
, m_hColorWnd(NULL)
, m_crColor(crColor)
@@ -130,7 +130,7 @@ void OptionsCtrlImpl::Color::childAdded(Item* pChild)
}
}
-void OptionsCtrlImpl::Color::setLabel(const TCHAR* szLabel)
+void OptionsCtrlImpl::Color::setLabel(const wchar_t* szLabel)
{
m_strLabel = szLabel;
diff --git a/plugins/HistoryStats/src/optionsctrlimpl_combo.cpp b/plugins/HistoryStats/src/optionsctrlimpl_combo.cpp
index 436e32aa13..db0837a97e 100644
--- a/plugins/HistoryStats/src/optionsctrlimpl_combo.cpp
+++ b/plugins/HistoryStats/src/optionsctrlimpl_combo.cpp
@@ -46,7 +46,7 @@ ext::string OptionsCtrlImpl::Combo::getCombinedText()
}
}
-OptionsCtrlImpl::Combo::Combo(OptionsCtrlImpl* pCtrl, Item* pParent, const TCHAR* szLabel, DWORD dwFlags, INT_PTR dwData)
+OptionsCtrlImpl::Combo::Combo(OptionsCtrlImpl* pCtrl, Item* pParent, const wchar_t* szLabel, DWORD dwFlags, INT_PTR dwData)
: Item(pCtrl, itCombo, szLabel, dwFlags, dwData), m_hComboWnd(NULL), m_nSelected(-1)
{
m_bDisableChildsOnIndex0 = bool_(dwFlags & OCF_DISABLECHILDSONINDEX0);
@@ -177,7 +177,7 @@ void OptionsCtrlImpl::Combo::childAdded(Item* pChild)
}
}
-void OptionsCtrlImpl::Combo::setLabel(const TCHAR* szLabel)
+void OptionsCtrlImpl::Combo::setLabel(const wchar_t* szLabel)
{
m_strLabel = szLabel;
@@ -188,7 +188,7 @@ void OptionsCtrlImpl::Combo::setLabel(const TCHAR* szLabel)
}
}
-void OptionsCtrlImpl::Combo::addItem(const TCHAR* szItem)
+void OptionsCtrlImpl::Combo::addItem(const wchar_t* szItem)
{
m_Items.push_back(szItem);
}
diff --git a/plugins/HistoryStats/src/optionsctrlimpl_datetime.cpp b/plugins/HistoryStats/src/optionsctrlimpl_datetime.cpp
index d55e4c0a38..0a32c7a29c 100644
--- a/plugins/HistoryStats/src/optionsctrlimpl_datetime.cpp
+++ b/plugins/HistoryStats/src/optionsctrlimpl_datetime.cpp
@@ -180,7 +180,7 @@ ext::string OptionsCtrlImpl::DateTime::getCombinedText()
return strTemp;
}
-OptionsCtrlImpl::DateTime::DateTime(OptionsCtrlImpl* pCtrl, Item* pParent, const TCHAR* szLabel, const TCHAR* szFormat, time_t timestamp, DWORD dwFlags, INT_PTR dwData)
+OptionsCtrlImpl::DateTime::DateTime(OptionsCtrlImpl* pCtrl, Item* pParent, const wchar_t* szLabel, const wchar_t* szFormat, time_t timestamp, DWORD dwFlags, INT_PTR dwData)
: Item(pCtrl, itDateTime, szLabel, dwFlags, dwData), m_hDateTimeWnd(NULL), m_strFormat(szFormat), m_timestamp(timestamp)
{
m_bDisableChildsOnNone = bool_(dwFlags & OCF_DISABLECHILDSONNONE);
@@ -313,7 +313,7 @@ void OptionsCtrlImpl::DateTime::childAdded(Item* pChild)
}
}
-void OptionsCtrlImpl::DateTime::setLabel(const TCHAR* szLabel)
+void OptionsCtrlImpl::DateTime::setLabel(const wchar_t* szLabel)
{
m_strLabel = szLabel;
diff --git a/plugins/HistoryStats/src/optionsctrlimpl_edit.cpp b/plugins/HistoryStats/src/optionsctrlimpl_edit.cpp
index ce8a053190..c297fedd16 100644
--- a/plugins/HistoryStats/src/optionsctrlimpl_edit.cpp
+++ b/plugins/HistoryStats/src/optionsctrlimpl_edit.cpp
@@ -10,7 +10,7 @@
ext::string OptionsCtrlImpl::Edit::getEditText()
{
int nLen = GetWindowTextLength(m_hEditWnd);
- TCHAR* szBuf = new TCHAR[nLen + 1];
+ wchar_t* szBuf = new wchar_t[nLen + 1];
GetWindowText(m_hEditWnd, szBuf, nLen + 1);
@@ -38,7 +38,7 @@ ext::string OptionsCtrlImpl::Edit::getCombinedText()
}
}
-OptionsCtrlImpl::Edit::Edit(OptionsCtrlImpl* pCtrl, Item* pParent, const TCHAR* szLabel, const TCHAR* szEdit, DWORD dwFlags, INT_PTR dwData)
+OptionsCtrlImpl::Edit::Edit(OptionsCtrlImpl* pCtrl, Item* pParent, const wchar_t* szLabel, const wchar_t* szEdit, DWORD dwFlags, INT_PTR dwData)
: Item(pCtrl, itEdit, szLabel, dwFlags, dwData), m_hEditWnd(NULL)
{
m_strEdit = szEdit;
@@ -154,7 +154,7 @@ void OptionsCtrlImpl::Edit::childAdded(Item* pChild)
}
}
-const TCHAR* OptionsCtrlImpl::Edit::getString()
+const wchar_t* OptionsCtrlImpl::Edit::getString()
{
if (m_hEditWnd)
{
@@ -164,7 +164,7 @@ const TCHAR* OptionsCtrlImpl::Edit::getString()
return m_strEdit.c_str();
}
-void OptionsCtrlImpl::Edit::setString(const TCHAR* szString)
+void OptionsCtrlImpl::Edit::setString(const wchar_t* szString)
{
m_strEdit = szString;
@@ -178,7 +178,7 @@ void OptionsCtrlImpl::Edit::setString(const TCHAR* szString)
}
}
-void OptionsCtrlImpl::Edit::setLabel(const TCHAR* szLabel)
+void OptionsCtrlImpl::Edit::setLabel(const wchar_t* szLabel)
{
m_strLabel = szLabel;
diff --git a/plugins/HistoryStats/src/optionsctrlimpl_group.cpp b/plugins/HistoryStats/src/optionsctrlimpl_group.cpp
index b92a88a42d..2d36374668 100644
--- a/plugins/HistoryStats/src/optionsctrlimpl_group.cpp
+++ b/plugins/HistoryStats/src/optionsctrlimpl_group.cpp
@@ -5,7 +5,7 @@
* OptionsCtrlImpl::Group
*/
-OptionsCtrlImpl::Group::Group(OptionsCtrlImpl* pCtrl, Item* pParent, const TCHAR* szLabel, DWORD dwFlags, INT_PTR dwData)
+OptionsCtrlImpl::Group::Group(OptionsCtrlImpl* pCtrl, Item* pParent, const wchar_t* szLabel, DWORD dwFlags, INT_PTR dwData)
: Item(pCtrl, itGroup, szLabel, dwFlags, dwData)
{
m_bDrawLine = bool_(dwFlags & OCF_DRAWLINE);
diff --git a/plugins/HistoryStats/src/optionsctrlimpl_item.cpp b/plugins/HistoryStats/src/optionsctrlimpl_item.cpp
index b628b834a5..2900ce6a44 100644
--- a/plugins/HistoryStats/src/optionsctrlimpl_item.cpp
+++ b/plugins/HistoryStats/src/optionsctrlimpl_item.cpp
@@ -5,7 +5,7 @@
* OptionsCtrlImpl::Item
*/
-OptionsCtrlImpl::Item::Item(OptionsCtrlImpl* pCtrl, ItemType ItemType, const TCHAR* szLabel, DWORD dwFlags, INT_PTR dwData) :
+OptionsCtrlImpl::Item::Item(OptionsCtrlImpl* pCtrl, ItemType ItemType, const wchar_t* szLabel, DWORD dwFlags, INT_PTR dwData) :
m_pCtrl(pCtrl), m_hItem(NULL), m_nRef(1), m_ItemType(ItemType), m_strLabel(szLabel), m_dwData(dwData)
{
m_bEnabled = !(dwFlags & OCF_DISABLED);
@@ -25,7 +25,7 @@ void OptionsCtrlImpl::Item::enableChilds(bool bEnable)
}
}
-void OptionsCtrlImpl::Item::setLabel(const TCHAR* szLabel)
+void OptionsCtrlImpl::Item::setLabel(const wchar_t* szLabel)
{
m_strLabel = szLabel;
diff --git a/plugins/HistoryStats/src/optionsctrlimpl_radio.cpp b/plugins/HistoryStats/src/optionsctrlimpl_radio.cpp
index f3ee55cb17..a8fc86ae86 100644
--- a/plugins/HistoryStats/src/optionsctrlimpl_radio.cpp
+++ b/plugins/HistoryStats/src/optionsctrlimpl_radio.cpp
@@ -74,7 +74,7 @@ void OptionsCtrlImpl::Radio::updateItem()
}
}
-OptionsCtrlImpl::Radio::Radio(OptionsCtrlImpl* pCtrl, Item* pParent, Radio* pSibling, const TCHAR* szLabel, DWORD dwFlags, INT_PTR dwData)
+OptionsCtrlImpl::Radio::Radio(OptionsCtrlImpl* pCtrl, Item* pParent, Radio* pSibling, const wchar_t* szLabel, DWORD dwFlags, INT_PTR dwData)
: Item(pCtrl, itRadio, szLabel, dwFlags, dwData)
{
m_bDisableChildsOnUncheck = bool_(dwFlags & OCF_DISABLECHILDSONUNCHECK);
diff --git a/plugins/HistoryStats/src/settings.cpp b/plugins/HistoryStats/src/settings.cpp
index ebd57958c7..34fbf1d640 100644
--- a/plugins/HistoryStats/src/settings.cpp
+++ b/plugins/HistoryStats/src/settings.cpp
@@ -13,11 +13,11 @@
Settings::CharMapper::CharMapper(const Settings& settings)
{
- static const TCHAR* defaultWordDelimiters = L"\n\r\t";
+ static const wchar_t* defaultWordDelimiters = L"\n\r\t";
array_each_(i, m_CharMap)
{
- m_CharMap[i] = static_cast<TCHAR>(i);
+ m_CharMap[i] = static_cast<wchar_t>(i);
}
LCID lcid = GetUserDefaultLCID();
@@ -63,12 +63,12 @@ Settings::Filter::Filter(const ext::string& strID)
* Settings
*/
-const TCHAR* Settings::getDefaultWordDelimiters()
+const wchar_t* Settings::getDefaultWordDelimiters()
{
return L".?!,:;()[]{}<>+-*/=\\_^&\"'~%#@|$";
}
-const TCHAR* Settings::getDefaultStyleSheet()
+const wchar_t* Settings::getDefaultStyleSheet()
{
static ext::string StyleSheet;
@@ -104,17 +104,17 @@ const TCHAR* Settings::getDefaultStyleSheet()
return StyleSheet.c_str();
}
-const TCHAR* Settings::getDefaultHideContactMenuProtos()
+const wchar_t* Settings::getDefaultHideContactMenuProtos()
{
return L"{num:0;}";
}
-const TCHAR* Settings::getDefaultProtosIgnore()
+const wchar_t* Settings::getDefaultProtosIgnore()
{
return L"{num:0;}";
}
-const TCHAR* Settings::getDefaultColumns()
+const wchar_t* Settings::getDefaultColumns()
{
return
L"{num:11;}"
@@ -131,7 +131,7 @@ const TCHAR* Settings::getDefaultColumns()
L"10{enabled:y;guid:split;}10/data{block_unit:0;blocks:28;detail:y;graph_align:1;source:0;source_type:2;units_per_block:6;vis_mode:0;}";
}
-const TCHAR* Settings::getDefaultSort()
+const wchar_t* Settings::getDefaultSort()
{
return
L"0{by:17;asc:n}"
@@ -139,17 +139,17 @@ const TCHAR* Settings::getDefaultSort()
L"2{by:-1;asc:y}";
}
-const TCHAR* Settings::getDefaultOutputFile()
+const wchar_t* Settings::getDefaultOutputFile()
{
return L"HistoryStats\\stats.html";
}
-const TCHAR* Settings::getDefaultOutputExtraFolder()
+const wchar_t* Settings::getDefaultOutputExtraFolder()
{
return L"extra";
}
-const TCHAR* Settings::getDefaultFilterWords()
+const wchar_t* Settings::getDefaultFilterWords()
{
return L"{num:0;}";
}
@@ -566,7 +566,7 @@ void Settings::ensureConstraints()
utils::ensureRange(m_TableHeaderRepeat, 0, 1000, 0);
}
-void Settings::openURL(const TCHAR* szURL)
+void Settings::openURL(const wchar_t* szURL)
{
if (m_PathToBrowser.empty())
ShellExecute(NULL, L"open", szURL, NULL, NULL, SW_SHOWNORMAL);
diff --git a/plugins/HistoryStats/src/settings.h b/plugins/HistoryStats/src/settings.h
index 2c91882230..77cafca6e7 100644
--- a/plugins/HistoryStats/src/settings.h
+++ b/plugins/HistoryStats/src/settings.h
@@ -138,16 +138,16 @@ public:
#else // _UNICODE
typedef unsigned char t_uchar;
#endif // _UNICODE
-#define T_NUMCHARS (1 << (sizeof(TCHAR) * 8))
+#define T_NUMCHARS (1 << (sizeof(wchar_t) * 8))
private:
- TCHAR m_CharMap[T_NUMCHARS];
+ wchar_t m_CharMap[T_NUMCHARS];
#undef T_NUMCHARS
public:
explicit CharMapper(const Settings& settings);
- TCHAR mapChar(TCHAR c) const { return m_CharMap[static_cast<t_uchar>(c)]; }
+ wchar_t mapChar(wchar_t c) const { return m_CharMap[static_cast<t_uchar>(c)]; }
};
typedef std::set<ext::string> WordSet;
@@ -193,15 +193,15 @@ public:
typedef std::vector<Column*> ColumnList;
public:
- static const TCHAR* getDefaultWordDelimiters();
- static const TCHAR* getDefaultStyleSheet();
- static const TCHAR* getDefaultHideContactMenuProtos();
- static const TCHAR* getDefaultProtosIgnore();
- static const TCHAR* getDefaultColumns();
- static const TCHAR* getDefaultSort();
- static const TCHAR* getDefaultOutputFile();
- static const TCHAR* getDefaultOutputExtraFolder();
- static const TCHAR* getDefaultFilterWords();
+ static const wchar_t* getDefaultWordDelimiters();
+ static const wchar_t* getDefaultStyleSheet();
+ static const wchar_t* getDefaultHideContactMenuProtos();
+ static const wchar_t* getDefaultProtosIgnore();
+ static const wchar_t* getDefaultColumns();
+ static const wchar_t* getDefaultSort();
+ static const wchar_t* getDefaultOutputFile();
+ static const wchar_t* getDefaultOutputExtraFolder();
+ static const wchar_t* getDefaultFilterWords();
public:
const DWORD m_VersionCurrent;
@@ -305,7 +305,7 @@ public:
void ensureConstraints();
- void openURL(const TCHAR* szURL);
+ void openURL(const wchar_t* szURL);
};
#endif // HISTORYSTATS_GUARD_SETTINGS_H
diff --git a/plugins/HistoryStats/src/settingsserializer.cpp b/plugins/HistoryStats/src/settingsserializer.cpp
index 0610fcf5e8..1c295460e9 100644
--- a/plugins/HistoryStats/src/settingsserializer.cpp
+++ b/plugins/HistoryStats/src/settingsserializer.cpp
@@ -484,7 +484,7 @@ ext::string SettingsSerializer::getLastStatisticsFile()
return m_DB.readStr(con::SettLastStatisticsFile, L"");
}
-void SettingsSerializer::setLastStatisticsFile(const TCHAR* szFileName)
+void SettingsSerializer::setLastStatisticsFile(const wchar_t* szFileName)
{
m_DB.writeStr(con::SettLastStatisticsFile, szFileName);
}
diff --git a/plugins/HistoryStats/src/settingsserializer.h b/plugins/HistoryStats/src/settingsserializer.h
index 6f967f20ca..88bd9e1c6d 100644
--- a/plugins/HistoryStats/src/settingsserializer.h
+++ b/plugins/HistoryStats/src/settingsserializer.h
@@ -33,7 +33,7 @@ public:
void setShowSupportInfo(bool bShow);
ext::string getLastStatisticsFile();
- void setLastStatisticsFile(const TCHAR* szFileName);
+ void setLastStatisticsFile(const wchar_t* szFileName);
bool canShowStatistics();
void showStatistics();
};
diff --git a/plugins/HistoryStats/src/settingstree.cpp b/plugins/HistoryStats/src/settingstree.cpp
index 2e8ab0a0a4..a73ef0f442 100644
--- a/plugins/HistoryStats/src/settingstree.cpp
+++ b/plugins/HistoryStats/src/settingstree.cpp
@@ -74,7 +74,7 @@ void SettingsTree::fromString(const ext::string& config)
ext::string SettingsTree::toString() const
{
- static const TCHAR* replaces[5][2] = {
+ static const wchar_t* replaces[5][2] = {
{ L"\\", L"\\\\" },
{ L"{", L"\\{" },
{ L"}", L"\\}" },
@@ -113,7 +113,7 @@ ext::string SettingsTree::toString() const
return data;
}
-void SettingsTree::setKey(const TCHAR* key)
+void SettingsTree::setKey(const wchar_t* key)
{
m_CurKey = key;
@@ -125,7 +125,7 @@ void SettingsTree::setKey(const TCHAR* key)
m_pCurValues = NULL;
}
-bool SettingsTree::readBool(const TCHAR* setting, bool errorValue) const
+bool SettingsTree::readBool(const wchar_t* setting, bool errorValue) const
{
if (m_pCurValues) {
ValueMap::iterator i = m_pCurValues->find(setting);
@@ -138,19 +138,19 @@ bool SettingsTree::readBool(const TCHAR* setting, bool errorValue) const
return errorValue;
}
-int SettingsTree::readInt(const TCHAR* setting, int errorValue) const
+int SettingsTree::readInt(const wchar_t* setting, int errorValue) const
{
if (m_pCurValues) {
ValueMap::iterator i = m_pCurValues->find(setting);
if (i != m_pCurValues->end())
- return _ttoi(i->second.c_str());
+ return _wtoi(i->second.c_str());
}
return errorValue;
}
-int SettingsTree::readIntRanged(const TCHAR* setting, int errorValue, int minValue, int maxValue) const
+int SettingsTree::readIntRanged(const wchar_t* setting, int errorValue, int minValue, int maxValue) const
{
int value = readInt(setting, errorValue);
if (minValue <= value && value <= maxValue)
@@ -159,7 +159,7 @@ int SettingsTree::readIntRanged(const TCHAR* setting, int errorValue, int minVal
return errorValue;
}
-ext::string SettingsTree::readStr(const TCHAR* setting, const TCHAR* errorValue) const
+ext::string SettingsTree::readStr(const wchar_t* setting, const wchar_t* errorValue) const
{
if (m_pCurValues) {
ValueMap::iterator i = m_pCurValues->find(setting);
@@ -171,28 +171,28 @@ ext::string SettingsTree::readStr(const TCHAR* setting, const TCHAR* errorValue)
return errorValue;
}
-void SettingsTree::writeBool(const TCHAR* setting, bool value)
+void SettingsTree::writeBool(const wchar_t* setting, bool value)
{
makeKeyValid();
(*m_pCurValues)[setting] = value ? L"y" : L"n";
}
-void SettingsTree::writeInt(const TCHAR* setting, int value)
+void SettingsTree::writeInt(const wchar_t* setting, int value)
{
makeKeyValid();
(*m_pCurValues)[setting] = utils::intToString(value);
}
-void SettingsTree::writeStr(const TCHAR* setting, const TCHAR* value)
+void SettingsTree::writeStr(const wchar_t* setting, const wchar_t* value)
{
makeKeyValid();
(*m_pCurValues)[setting] = value;
}
-bool SettingsTree::hasSetting(const TCHAR* setting) const
+bool SettingsTree::hasSetting(const wchar_t* setting) const
{
if (m_pCurValues) {
ValueMap::const_iterator i = m_pCurValues->find(setting);
@@ -203,7 +203,7 @@ bool SettingsTree::hasSetting(const TCHAR* setting) const
return false;
}
-bool SettingsTree::delSetting(const TCHAR* setting)
+bool SettingsTree::delSetting(const wchar_t* setting)
{
if (m_pCurValues) {
ValueMap::iterator i = m_pCurValues->find(setting);
diff --git a/plugins/HistoryStats/src/settingstree.h b/plugins/HistoryStats/src/settingstree.h
index c96261390b..f8c471e340 100644
--- a/plugins/HistoryStats/src/settingstree.h
+++ b/plugins/HistoryStats/src/settingstree.h
@@ -30,20 +30,20 @@ public:
void fromString(const ext::string& config);
ext::string toString() const;
- void setKey(const TCHAR* key);
+ void setKey(const wchar_t* key);
const ext::string& getKey() const { return m_CurKey; }
- bool readBool(const TCHAR* setting, bool errorValue) const;
- int readInt(const TCHAR* setting, int errorValue) const;
- int readIntRanged(const TCHAR* setting, int errorValue, int minValue, int maxValue) const;
- ext::string readStr(const TCHAR* setting, const TCHAR* errorValue) const;
+ bool readBool(const wchar_t* setting, bool errorValue) const;
+ int readInt(const wchar_t* setting, int errorValue) const;
+ int readIntRanged(const wchar_t* setting, int errorValue, int minValue, int maxValue) const;
+ ext::string readStr(const wchar_t* setting, const wchar_t* errorValue) const;
- void writeBool(const TCHAR* setting, bool value);
- void writeInt(const TCHAR* setting, int value);
- void writeStr(const TCHAR* setting, const TCHAR* value);
+ void writeBool(const wchar_t* setting, bool value);
+ void writeInt(const wchar_t* setting, int value);
+ void writeStr(const wchar_t* setting, const wchar_t* value);
- bool hasSetting(const TCHAR* setting) const;
- bool delSetting(const TCHAR* setting);
+ bool hasSetting(const wchar_t* setting) const;
+ bool delSetting(const wchar_t* setting);
};
#endif // HISTORYSTATS_GUARD_SETTINGSTREE_H \ No newline at end of file
diff --git a/plugins/HistoryStats/src/statistic.cpp b/plugins/HistoryStats/src/statistic.cpp
index 0f66d31c62..0d9b1deea9 100644
--- a/plugins/HistoryStats/src/statistic.cpp
+++ b/plugins/HistoryStats/src/statistic.cpp
@@ -193,7 +193,7 @@ DWORD Statistic::getHistoryTime()
ext::string Statistic::createFile(const ext::string& desiredName)
{
if (!m_Settings.m_OverwriteAlways && utils::fileExists(desiredName)) {
- TCHAR tempBuf[MAX_PATH];
+ wchar_t tempBuf[MAX_PATH];
UINT nUnique = GetTempFileName(m_TempPath.c_str(), L"his", 0, tempBuf);
@@ -220,7 +220,7 @@ ext::string Statistic::createFile(const ext::string& desiredName)
return desiredName;
}
-bool Statistic::newFile(const TCHAR* fileExt, ext::string& writeFile, ext::string& finalURL)
+bool Statistic::newFile(const wchar_t* fileExt, ext::string& writeFile, ext::string& finalURL)
{
++m_nLastFileNr;
@@ -352,7 +352,7 @@ void Statistic::stepProgress(bool bSub, int step /* = 1 */)
bool Statistic::stepInit()
{
// file management
- TCHAR tempPath[MAX_PATH];
+ wchar_t tempPath[MAX_PATH];
int nRes = GetTempPath(MAX_PATH, tempPath);
if (nRes > 0) {
@@ -1333,19 +1333,19 @@ bool Statistic::createStatisticsSteps()
static const struct
{
bool (Statistic::*stepFn)();
- TCHAR* stepMsg;
+ wchar_t* stepMsg;
}
stepsInfo[] = {
- { &Statistic::stepInit, LPGENT("Initializing") },
- { &Statistic::stepReadDB, LPGENT("Reading database") },
- { &Statistic::stepRemoveContacts, LPGENT("Removing contacts") },
- { &Statistic::stepSortContacts, LPGENT("Sorting contacts") },
- { &Statistic::stepPreOmitContacts, LPGENT("Precollecting column data") },
- { &Statistic::stepOmitContacts, LPGENT("Limiting number of contacts") },
- { &Statistic::stepCalcTotals, LPGENT("Calculating totals") },
- { &Statistic::stepPostOmitContacts, LPGENT("Postcollecting column data") },
- { &Statistic::stepTransformData, LPGENT("Transforming data") },
- { &Statistic::stepWriteHTML, LPGENT("Creating HTML") }
+ { &Statistic::stepInit, LPGENW("Initializing") },
+ { &Statistic::stepReadDB, LPGENW("Reading database") },
+ { &Statistic::stepRemoveContacts, LPGENW("Removing contacts") },
+ { &Statistic::stepSortContacts, LPGENW("Sorting contacts") },
+ { &Statistic::stepPreOmitContacts, LPGENW("Precollecting column data") },
+ { &Statistic::stepOmitContacts, LPGENW("Limiting number of contacts") },
+ { &Statistic::stepCalcTotals, LPGENW("Calculating totals") },
+ { &Statistic::stepPostOmitContacts, LPGENW("Postcollecting column data") },
+ { &Statistic::stepTransformData, LPGENW("Transforming data") },
+ { &Statistic::stepWriteHTML, LPGENW("Creating HTML") }
};
setProgressMax(false, _countof(stepsInfo));
@@ -1414,7 +1414,7 @@ INT_PTR CALLBACK Statistic::staticConflictProc(HWND hDlg, UINT uMsg, WPARAM wPar
lvc.mask = LVCF_TEXT | LVCF_WIDTH | LVCF_FMT;
lvc.fmt = LVCFMT_LEFT;
lvc.cx = 400;
- lvc.pszText = const_cast<TCHAR*>(TranslateT("Already existing file"));
+ lvc.pszText = const_cast<wchar_t*>(TranslateT("Already existing file"));
ListView_InsertColumn(hWndFiles, 0, &lvc);
int nIndex = 0;
@@ -1425,7 +1425,7 @@ INT_PTR CALLBACK Statistic::staticConflictProc(HWND hDlg, UINT uMsg, WPARAM wPar
lvi.mask = LVIF_TEXT;
lvi.iItem = nIndex++;
lvi.iSubItem = 0;
- lvi.pszText = const_cast<TCHAR*>(fi->first.c_str());
+ lvi.pszText = const_cast<wchar_t*>(fi->first.c_str());
ListView_InsertItem(hWndFiles, &lvi);
}
}
diff --git a/plugins/HistoryStats/src/statistic.h b/plugins/HistoryStats/src/statistic.h
index 07b502b200..93f3d729bf 100644
--- a/plugins/HistoryStats/src/statistic.h
+++ b/plugins/HistoryStats/src/statistic.h
@@ -182,7 +182,7 @@ public:
// file management
ext::string createFile(const ext::string& desiredName);
- bool newFile(const TCHAR* fileExt, ext::string& writeFile, ext::string& finalURL);
+ bool newFile(const wchar_t* fileExt, ext::string& writeFile, ext::string& finalURL);
bool newFilePNG(ext::string& writeFile, ext::string& finalURL) { return newFile(L".png", writeFile, finalURL); }
bool newFilePNG(Canvas& canvas, ext::string& finalURL);
};
diff --git a/plugins/HistoryStats/src/stdafx.h b/plugins/HistoryStats/src/stdafx.h
index 8646a67c1e..d4fcfc6f6b 100644
--- a/plugins/HistoryStats/src/stdafx.h
+++ b/plugins/HistoryStats/src/stdafx.h
@@ -19,7 +19,6 @@
#pragma comment(lib, "UxTheme.lib")
-#include <tchar.h>
#include <stdio.h>
#include <cstdio>
diff --git a/plugins/HistoryStats/src/utf8buffer.h b/plugins/HistoryStats/src/utf8buffer.h
index e4727afc30..56342adbf7 100644
--- a/plugins/HistoryStats/src/utf8buffer.h
+++ b/plugins/HistoryStats/src/utf8buffer.h
@@ -5,15 +5,15 @@
#include <string>
class UTF8Buffer
- : public std::basic_streambuf<TCHAR, std::char_traits<TCHAR> >
+ : public std::basic_streambuf<wchar_t, std::char_traits<wchar_t> >
, private pattern::NotCopyable<UTF8Buffer>
{
private:
- typedef std::char_traits<TCHAR> _Tr;
+ typedef std::char_traits<wchar_t> _Tr;
private:
int m_BufSize;
- TCHAR* m_pBuf;
+ wchar_t* m_pBuf;
ext::a::ostream& m_Stream;
char* m_pUTF8Buf;
WCHAR* m_pBufW;
@@ -23,7 +23,7 @@ private:
#endif // _UNICODE
private:
- void dump(const TCHAR* pBegin, const TCHAR* pEnd)
+ void dump(const wchar_t* pBegin, const wchar_t* pEnd)
{
size_t len = pEnd - pBegin;
@@ -81,7 +81,7 @@ public:
explicit UTF8Buffer(ext::a::ostream& outStream, int bufferSize = 4096)
: m_BufSize(bufferSize), m_Stream(outStream)
{
- m_pBuf = new TCHAR[m_BufSize];
+ m_pBuf = new wchar_t[m_BufSize];
m_pUTF8Buf = new char[3 * m_BufSize];
#if defined(_UNICODE)
diff --git a/plugins/HistoryStats/src/utils.cpp b/plugins/HistoryStats/src/utils.cpp
index 91dedaf163..b70ee4630e 100644
--- a/plugins/HistoryStats/src/utils.cpp
+++ b/plugins/HistoryStats/src/utils.cpp
@@ -12,23 +12,23 @@
namespace utils
{
- ext::string timestampToString(time_t value, const TCHAR* format)
+ ext::string timestampToString(time_t value, const wchar_t* format)
{
- TCHAR temp[100] = { 0 };
+ wchar_t temp[100] = { 0 };
return (ext::strfunc::ftime(temp, 100, format, gmtime(&value)) > 0) ? temp : L"";
}
- ext::string tmStructToString(const tm& value, const TCHAR* format)
+ ext::string tmStructToString(const tm& value, const wchar_t* format)
{
- TCHAR temp[100] = { 0 };
+ wchar_t temp[100] = { 0 };
return (ext::strfunc::ftime(temp, 100, format, &value) > 0) ? temp : L"";
}
ext::string durationToString(DWORD value)
{
- TCHAR temp[100] = { 0 };
+ wchar_t temp[100] = { 0 };
value += 59;
value /= 60;
@@ -48,9 +48,9 @@ namespace utils
struct tm dateTM;
- dateTM.tm_year = _ttoi(date.c_str() + 0) - 1900;
- dateTM.tm_mon = _ttoi(date.c_str() + 5) - 1;
- dateTM.tm_mday = _ttoi(date.c_str() + 8);
+ dateTM.tm_year = _wtoi(date.c_str() + 0) - 1900;
+ dateTM.tm_mon = _wtoi(date.c_str() + 5) - 1;
+ dateTM.tm_mday = _wtoi(date.c_str() + 8);
dateTM.tm_hour = dateTM.tm_min = dateTM.tm_sec = 0;
dateTM.tm_isdst = dateTM.tm_wday = dateTM.tm_yday = 0;
@@ -75,7 +75,7 @@ namespace utils
ext::string intToString(int value)
{
- TCHAR temp[100] = { 0 };
+ wchar_t temp[100] = { 0 };
ext::strfunc::sprintf(temp, L"%d", value);
@@ -84,7 +84,7 @@ namespace utils
ext::string intToPadded(int value, int len)
{
- TCHAR temp[100] = { 0 };
+ wchar_t temp[100] = { 0 };
ext::strfunc::sprintf(temp, L"%0*d", len, value);
@@ -93,7 +93,7 @@ namespace utils
ext::string intToGrouped(int value)
{
- TCHAR temp[100] = { 0 };
+ wchar_t temp[100] = { 0 };
const char* grouping = Locale::grouping();
ext::strfunc::sprintf(temp, L"%d", value);
@@ -117,7 +117,7 @@ namespace utils
ext::string floatToString(double value, int precision)
{
- TCHAR temp[100] = { 0 };
+ wchar_t temp[100] = { 0 };
ext::strfunc::sprintf(temp, L"%.*f", precision, value);
@@ -126,7 +126,7 @@ namespace utils
ext::string floatToGrouped(double value, int precision)
{
- TCHAR temp[100] = { 0 };
+ wchar_t temp[100] = { 0 };
const char* grouping = Locale::grouping();
ext::strfunc::sprintf(temp, L"%.*f", precision, value);
@@ -154,7 +154,7 @@ namespace utils
ext::string ratioToPercent(int numerator, int denominator)
{
float value = 0.0;
- TCHAR temp[100] = { 0 };
+ wchar_t temp[100] = { 0 };
if (denominator != 0) {
value = 1.0f * numerator / denominator;
@@ -165,7 +165,7 @@ namespace utils
return temp;
}
- void replaceAllInPlace(ext::string& text, const TCHAR* find, const TCHAR* replace)
+ void replaceAllInPlace(ext::string& text, const wchar_t* find, const wchar_t* replace)
{
ext::string::size_type pos = 0;
ext::string::size_type find_len = ext::strfunc::len(find);
@@ -186,7 +186,7 @@ namespace utils
replaceAllInPlace(text, L">", L"&gt;");
}
- const TCHAR* stripPrefix(const TCHAR* szPrefix, const TCHAR* szText)
+ const wchar_t* stripPrefix(const wchar_t* szPrefix, const wchar_t* szText)
{
int i = 0;
@@ -199,31 +199,31 @@ namespace utils
return szText;
}
- ext::string replaceVariables(const ext::string& strFormat, time_t timeValue, const TCHAR* szNick /* = L"" */)
+ ext::string replaceVariables(const ext::string& strFormat, time_t timeValue, const wchar_t* szNick /* = L"" */)
{
- static const TCHAR* szMonthName[][2] = {
- { LPGENT("month3:Jan"), LPGENT("monthF:January") },
- { LPGENT("month3:Feb"), LPGENT("monthF:February") },
- { LPGENT("month3:Mar"), LPGENT("monthF:March") },
- { LPGENT("month3:Apr"), LPGENT("monthF:April") },
- { LPGENT("month3:May"), LPGENT("monthF:May") },
- { LPGENT("month3:Jun"), LPGENT("monthF:June") },
- { LPGENT("month3:Jul"), LPGENT("monthF:July") },
- { LPGENT("month3:Aug"), LPGENT("monthF:August") },
- { LPGENT("month3:Sep"), LPGENT("monthF:September") },
- { LPGENT("month3:Oct"), LPGENT("monthF:October") },
- { LPGENT("month3:Nov"), LPGENT("monthF:November") },
- { LPGENT("month3:Dec"), LPGENT("monthF:December") },
+ static const wchar_t* szMonthName[][2] = {
+ { LPGENW("month3:Jan"), LPGENW("monthF:January") },
+ { LPGENW("month3:Feb"), LPGENW("monthF:February") },
+ { LPGENW("month3:Mar"), LPGENW("monthF:March") },
+ { LPGENW("month3:Apr"), LPGENW("monthF:April") },
+ { LPGENW("month3:May"), LPGENW("monthF:May") },
+ { LPGENW("month3:Jun"), LPGENW("monthF:June") },
+ { LPGENW("month3:Jul"), LPGENW("monthF:July") },
+ { LPGENW("month3:Aug"), LPGENW("monthF:August") },
+ { LPGENW("month3:Sep"), LPGENW("monthF:September") },
+ { LPGENW("month3:Oct"), LPGENW("monthF:October") },
+ { LPGENW("month3:Nov"), LPGENW("monthF:November") },
+ { LPGENW("month3:Dec"), LPGENW("monthF:December") },
};
- static const TCHAR* szWDayName[][3] = {
- { LPGENT("wday2:Mo"), LPGENT("wday3:Mon"), LPGENT("wdayF:Monday") },
- { LPGENT("wday2:Tu"), LPGENT("wday3:Tue"), LPGENT("wdayF:Tuesday") },
- { LPGENT("wday2:We"), LPGENT("wday3:Wed"), LPGENT("wdayF:Wednesday") },
- { LPGENT("wday2:Th"), LPGENT("wday3:Thu"), LPGENT("wdayF:Thursday") },
- { LPGENT("wday2:Fr"), LPGENT("wday3:Fri"), LPGENT("wdayF:Friday") },
- { LPGENT("wday2:Sa"), LPGENT("wday3:Sat"), LPGENT("wdayF:Saturday") },
- { LPGENT("wday2:Su"), LPGENT("wday3:Sun"), LPGENT("wdayF:Sunday") },
+ static const wchar_t* szWDayName[][3] = {
+ { LPGENW("wday2:Mo"), LPGENW("wday3:Mon"), LPGENW("wdayF:Monday") },
+ { LPGENW("wday2:Tu"), LPGENW("wday3:Tue"), LPGENW("wdayF:Tuesday") },
+ { LPGENW("wday2:We"), LPGENW("wday3:Wed"), LPGENW("wdayF:Wednesday") },
+ { LPGENW("wday2:Th"), LPGENW("wday3:Thu"), LPGENW("wdayF:Thursday") },
+ { LPGENW("wday2:Fr"), LPGENW("wday3:Fri"), LPGENW("wdayF:Friday") },
+ { LPGENW("wday2:Sa"), LPGENW("wday3:Sat"), LPGENW("wdayF:Saturday") },
+ { LPGENW("wday2:Su"), LPGENW("wday3:Sun"), LPGENW("wdayF:Sunday") },
};
struct tm* timeTM = gmtime(&timeValue);
@@ -337,7 +337,7 @@ namespace utils
ext::string toLowerCase(const ext::string& text)
{
int len = text.length();
- TCHAR* buf = new TCHAR[len + 1];
+ wchar_t* buf = new wchar_t[len + 1];
LCID lcid = GetUserDefaultLCID();
@@ -355,7 +355,7 @@ namespace utils
ext::string toUpperCase(const ext::string& text)
{
int len = text.length();
- TCHAR* buf = new TCHAR[len + 1];
+ wchar_t* buf = new wchar_t[len + 1];
LCID lcid = GetUserDefaultLCID();
@@ -387,7 +387,7 @@ namespace utils
dotPos = version.length();
}
- res.parts[part--] = _ttoi(version.substr(0, dotPos).c_str());
+ res.parts[part--] = _wtoi(version.substr(0, dotPos).c_str());
version.erase(0, dotPos + 1);
}
@@ -397,7 +397,7 @@ namespace utils
ext::string versionToDotted(DWORD version)
{
- TCHAR temp[16] = { 0 };
+ wchar_t temp[16] = { 0 };
ext::strfunc::sprintf(
temp,
@@ -440,7 +440,7 @@ namespace utils
return ret_str;
}
- ext::a::string convertTToUTF8(const TCHAR* str, size_t str_len)
+ ext::a::string convertTToUTF8(const wchar_t* str, size_t str_len)
{
#if defined(_UNICODE)
const WCHAR* conv_str = str;
@@ -649,7 +649,7 @@ namespace utils
return false;
// check for disallowed names
- static const TCHAR* disallowedNames[] = {
+ static const wchar_t* disallowedNames[] = {
L"clock$",
L"aux",
L"con",
@@ -776,7 +776,7 @@ namespace utils
ext::string colorToHTML(COLORREF crColor)
{
- static const TCHAR hexDigits[] = L"0123456789ABCDEF";
+ static const wchar_t hexDigits[] = L"0123456789ABCDEF";
ext::string htmlColor(7, '#');
@@ -823,7 +823,7 @@ namespace utils
ext::string getGUID()
{
- static const TCHAR hexDigits[] = L"0123456789ABCDEF";
+ static const wchar_t hexDigits[] = L"0123456789ABCDEF";
GUID guid;
CoCreateGuid(&guid);
@@ -893,7 +893,7 @@ namespace utils
static ext::string strMirandaPath;
if (strMirandaPath.empty()) {
- TCHAR szPath[MAX_PATH] = { 0 };
+ wchar_t szPath[MAX_PATH] = { 0 };
PathToAbsoluteT(L"x", szPath);
strMirandaPath = extractPath(szPath);
@@ -907,7 +907,7 @@ namespace utils
static ext::string strProfilePath;
if (strProfilePath.empty()) {
- TCHAR szPath[MAX_PATH] = { 0 };
+ wchar_t szPath[MAX_PATH] = { 0 };
mu::db::getProfilePath(MAX_PATH, szPath);
strProfilePath = szPath;
@@ -926,7 +926,7 @@ namespace utils
static ext::string strProfileName;
if (strProfileName.empty()) {
- TCHAR szName[MAX_PATH] = { 0 };
+ wchar_t szName[MAX_PATH] = { 0 };
mu::db::getProfileName(MAX_PATH, szName);
strProfileName = szName;
@@ -1031,7 +1031,7 @@ ext::t::string RTFFilter::filter(const ext::t::string& str)
return str;
}
- TCHAR* out_buf = new TCHAR[len / sizeof(TCHAR)];
+ wchar_t* out_buf = new wchar_t[len / sizeof(wchar_t)];
intptr_t res = m_Data.m_RTFConvString(
strA.c_str(),
@@ -1048,7 +1048,7 @@ ext::t::string RTFFilter::filter(const ext::t::string& str)
return str;
}
- ext::t::string out_str(out_buf, res / sizeof(TCHAR)-1);
+ ext::t::string out_str(out_buf, res / sizeof(wchar_t)-1);
delete[] out_buf;
return out_str;
diff --git a/plugins/HistoryStats/src/utils.h b/plugins/HistoryStats/src/utils.h
index 834b154ccb..884b1c7302 100644
--- a/plugins/HistoryStats/src/utils.h
+++ b/plugins/HistoryStats/src/utils.h
@@ -7,8 +7,8 @@
namespace utils
{
// time formatting
- ext::string timestampToString(time_t value, const TCHAR* format);
- ext::string tmStructToString(const tm& value, const TCHAR* format);
+ ext::string timestampToString(time_t value, const wchar_t* format);
+ ext::string tmStructToString(const tm& value, const wchar_t* format);
inline ext::string timestampToDateTime(DWORD value) { return timestampToString(value, L"%c"); }
inline ext::string timestampToDate(DWORD value) { return timestampToString(value, L"%x"); }
inline ext::string timestampToTime(DWORD value) { return timestampToString(value, L"%X"); }
@@ -27,12 +27,12 @@ namespace utils
ext::string ratioToPercent(int numerator, int denominator);
// text conversion
- void replaceAllInPlace(ext::string& text, const TCHAR* find, const TCHAR* replace);
+ void replaceAllInPlace(ext::string& text, const wchar_t* find, const wchar_t* replace);
void htmlEscapeInPlace(ext::string& text);
- inline ext::string replaceAll(ext::string text, const TCHAR* find, const TCHAR* replace) { replaceAllInPlace(text, find, replace); return text; }
+ inline ext::string replaceAll(ext::string text, const wchar_t* find, const wchar_t* replace) { replaceAllInPlace(text, find, replace); return text; }
inline ext::string htmlEscape(ext::string text) { htmlEscapeInPlace(text); return text; }
- const TCHAR* stripPrefix(const TCHAR* szPrefix, const TCHAR* szText);
- ext::string replaceVariables(const ext::string& strFormat, time_t timeValue, const TCHAR* szNick = L"");
+ const wchar_t* stripPrefix(const wchar_t* szPrefix, const wchar_t* szText);
+ ext::string replaceVariables(const ext::string& strFormat, time_t timeValue, const wchar_t* szNick = L"");
// case conversion
ext::string toLowerCase(const ext::string& text);
@@ -45,21 +45,21 @@ namespace utils
// character conversion (wide, ansi, utf8)
ext::a::string convertWToA(const WCHAR* str, size_t len);
ext::w::string convertAToW(const char* str, size_t len);
- ext::a::string convertTToUTF8(const TCHAR* str, size_t str_len);
+ ext::a::string convertTToUTF8(const wchar_t* str, size_t str_len);
ext::string convertUTF8ToT(const char* str, size_t str_len);
size_t rawUTF8Encode(const WCHAR* pIn, size_t lenIn, char* pOut);
size_t getUTF8Len(const char* str);
// character conversion (convenience functions)
- inline ext::a::string toA(const TCHAR* str) { return convertWToA(str, ext::strfunc::len(str)); }
- inline ext::w::string toW(const TCHAR* str) { return str; }
+ inline ext::a::string toA(const wchar_t* str) { return convertWToA(str, ext::strfunc::len(str)); }
+ inline ext::w::string toW(const wchar_t* str) { return str; }
inline ext::string fromA(const char* str) { return convertAToW(str, ext::a::strfunc::len(str)); }
inline ext::string fromW(const WCHAR* str) { return str; }
inline ext::a::string toA(const ext::string& str) { return convertWToA(str.c_str(), str.length()); }
inline ext::w::string toW(const ext::string& str) { return str; }
inline ext::string fromA(const ext::a::string& str) { return convertAToW(str.c_str(), str.length()); }
inline ext::string fromW(const ext::w::string& str) { return str; }
- inline ext::a::string toUTF8(const TCHAR* str) { return convertTToUTF8(str, ext::strfunc::len(str)); }
+ inline ext::a::string toUTF8(const wchar_t* str) { return convertTToUTF8(str, ext::strfunc::len(str)); }
inline ext::string fromUTF8(const char* str) { return convertUTF8ToT(str, ext::a::strfunc::len(str)); }
inline ext::a::string toUTF8(const ext::string& str) { return convertTToUTF8(str.c_str(), str.length()); }
inline ext::string fromUTF8(const ext::a::string& str) { return convertUTF8ToT(str.c_str(), str.length()); }
@@ -133,8 +133,8 @@ class Locale
: private pattern::NotCopyable<Locale>
{
private:
- TCHAR m_DecimalPoint;
- TCHAR m_ThousandSep;
+ wchar_t m_DecimalPoint;
+ wchar_t m_ThousandSep;
ext::a::string m_Grouping;
private:
@@ -145,8 +145,8 @@ private:
public:
static void init();
- static TCHAR decimalPoint() { return m_Data.m_DecimalPoint; }
- static TCHAR thousandSep() { return m_Data.m_ThousandSep; }
+ static wchar_t decimalPoint() { return m_Data.m_DecimalPoint; }
+ static wchar_t thousandSep() { return m_Data.m_ThousandSep; }
static const char* grouping() { return m_Data.m_Grouping.c_str(); }
};