Decompile fn_09842 (UIMacroReporterWnd::sub_7EF680)
Batch #10794 by cremane: 0 byte-identical, 1 confirmed by peer review. - fn_09842 UIMacroReporterWnd::sub_7EF680: logic confirmed by peer review Peer-reviewed-by: Tanke, dori, StrawberrysherbetIX Accepted without human review: peers confirmed the logic ("same" ahead by at least 3, with 70% of the votes).
This commit is contained in:
parent
e2076698fa
commit
2edca0dbf5
1 changed files with 4 additions and 4 deletions
|
|
@ -152,6 +152,7 @@ std::string UIMacroReporterWnd::sub_7EF680(int maxWidth, const char* text, int f
|
|||
|
||||
std::string fitted(text);
|
||||
std::wstring wide(ATL::CA2WEX<128>(text, CP_THREAD_ACP));
|
||||
|
||||
while (wide.size() > 1) {
|
||||
if (wide.size() >= 2) {
|
||||
const std::size_t size = wide.size();
|
||||
|
|
@ -159,15 +160,14 @@ std::string UIMacroReporterWnd::sub_7EF680(int maxWidth, const char* text, int f
|
|||
wide.resize(size - cut);
|
||||
}
|
||||
|
||||
fitted = ATL::CW2AEX<128>(wide.c_str(), CP_THREAD_ACP);
|
||||
fitted += "...";
|
||||
fitted = std::string(ATL::CW2AEX<128>(wide.c_str(), CP_THREAD_ACP)) + "...";
|
||||
|
||||
if (this->TextWidth(fitted.c_str(), 0, font, height, bold, 0) <= maxWidth) {
|
||||
return fitted;
|
||||
}
|
||||
}
|
||||
|
||||
fitted = ATL::CW2AEX<128>(wide.c_str(), CP_THREAD_ACP);
|
||||
fitted += "...";
|
||||
fitted = std::string(ATL::CW2AEX<128>(wide.c_str(), CP_THREAD_ACP)) + "...";
|
||||
return fitted;
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue