Skip to content

Commit

Permalink
Merge pull request #722 from lrisora/patch05
Browse files Browse the repository at this point in the history
修正英文系统上编译时间字符串的问题
  • Loading branch information
zhongyang219 authored Jul 11, 2024
2 parents 2457549 + e74dc5a commit ba5db30
Show file tree
Hide file tree
Showing 27 changed files with 199 additions and 179 deletions.
11 changes: 8 additions & 3 deletions MusicPlayer2/AboutDlg.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -37,15 +37,20 @@ bool CAboutDlg::InitializeControls()
temp += L" (Debug)";
#endif

wstring time_str, hash_str;
CCommon::GetLastCompileTime(time_str, hash_str);
if (!hash_str.empty())
temp += L" (" + hash_str + L")";

SetDlgItemTextW(IDC_STATIC_VERSION, temp.c_str());
temp = L"Copyright (C) 2017-" COPY_RIGHT_YEAR L" By ZhongYang\r\n";
temp += theApp.m_str_table.LoadTextFormat(L"TXT_ABOUTBOX_LAST_BUILD_DATE", { CCommon::GetLastCompileTime() });
temp += theApp.m_str_table.LoadTextFormat(L"TXT_ABOUTBOX_LAST_BUILD_DATE", { time_str });
SetDlgItemTextW(IDC_STATIC_COPYRIGHT, temp.c_str());
temp = theApp.m_str_table.LoadText(L"TXT_ABOUTBOX_THIRD_PARTY_LIB");
SetDlgItemTextW(IDC_STATIC_THIRD_PARTY_LIB, temp.c_str());
temp = theApp.m_str_table.LoadText(L"TXT_ABOUTBOX_OTHER_SOFTWARE");
SetDlgItemTextW(IDC_STATIC_OTHER_SOFTWARE, temp.c_str());
temp = L"<a>" + theApp.m_str_table.LoadText(L"TXT_ABOUTBOX_CONTRACT_AUTHOR") + L"</a>";
temp = L"<a>" + theApp.m_str_table.LoadText(L"TXT_ABOUTBOX_CONTACT_AUTHOR") + L"</a>";
SetDlgItemTextW(IDC_SYSLINK1, temp.c_str());
temp = L"<a>" + theApp.m_str_table.LoadText(L"TXT_ABOUTBOX_CHECK_UPDATE") + L"</a>";
SetDlgItemTextW(IDC_SYSLINK2, temp.c_str());
Expand Down Expand Up @@ -104,7 +109,7 @@ BOOL CAboutDlg::OnInitDialog()
SetBackgroundColor(GetSysColor(COLOR_WINDOW));

m_tool_tip.Create(this);
m_tool_tip.AddTool(GetDlgItem(IDC_SYSLINK1), (theApp.m_str_table.LoadText(L"TIP_ABOUTBOX_SEND_EMAIL_TO_ATHOUR") + L"\r\nmailto:zhongyang219@hotmail.com").c_str());
m_tool_tip.AddTool(GetDlgItem(IDC_SYSLINK1), (theApp.m_str_table.LoadText(L"TIP_ABOUTBOX_SEND_EMAIL_TO_AUTHOR") + L"\r\nmailto:zhongyang219@hotmail.com").c_str());
m_tool_tip.AddTool(GetDlgItem(IDC_GITHUB_SYSLINK), (theApp.m_str_table.LoadText(L"TIP_ABOUTBOX_GOTO_GITHUB") + L"\r\nhttps://github.com/zhongyang219/MusicPlayer2").c_str());
m_tool_tip.AddTool(GetDlgItem(IDC_SYSLINK_BASS), L"http://www.un4seen.com/bass.html");
m_tool_tip.AddTool(GetDlgItem(IDC_SYSLINK_TAGLIB), L"http://taglib.org/");
Expand Down
4 changes: 2 additions & 2 deletions MusicPlayer2/CPlayerUIBase.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1327,7 +1327,7 @@ void CPlayerUIBase::SetRepeatModeToolTipText()
auto repeat_mode = CPlayer::GetInstance().GetRepeatMode();
switch (repeat_mode)
{
case RM_PLAY_ORDER: mode_str = theApp.m_str_table.LoadText(L"UI_TIP_REPEAT_OREDE");break;
case RM_PLAY_ORDER: mode_str = theApp.m_str_table.LoadText(L"UI_TIP_REPEAT_ORDER");break;
case RM_PLAY_SHUFFLE: mode_str = theApp.m_str_table.LoadText(L"UI_TIP_REPEAT_SHUFFLE"); break;
case RM_PLAY_RANDOM: mode_str = theApp.m_str_table.LoadText(L"UI_TIP_REPEAT_RANDOM"); break;
case RM_LOOP_PLAYLIST: mode_str = theApp.m_str_table.LoadText(L"UI_TIP_REPEAT_PLAYLIST"); break;
Expand All @@ -1342,7 +1342,7 @@ void CPlayerUIBase::SetSongInfoToolTipText()
{
const SongInfo& songInfo = CPlayer::GetInstance().GetCurrentSongInfo();

m_info_tip = theApp.m_str_table.LoadText(L"UI_TIP_BTN_PROPETRY") + GetCmdShortcutKeyForTooltips(ID_SONG_INFO).GetString() + L"\r\n";
m_info_tip = theApp.m_str_table.LoadText(L"UI_TIP_BTN_PROPERTY") + GetCmdShortcutKeyForTooltips(ID_SONG_INFO).GetString() + L"\r\n";
m_info_tip += theApp.m_str_table.LoadText(L"TXT_TITLE") + L": " + songInfo.GetTitle() + L"\r\n";
m_info_tip += theApp.m_str_table.LoadText(L"TXT_ARTIST") + L": " + songInfo.GetArtist() + L"\r\n";
m_info_tip += theApp.m_str_table.LoadText(L"TXT_ALBUM") + L": " + songInfo.GetAlbum();
Expand Down
6 changes: 3 additions & 3 deletions MusicPlayer2/CSelectPlaylist.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -529,7 +529,7 @@ void CSelectPlaylistDlg::OnRenamePlaylist()
wstring new_path = CCommon::FileRename(sel_playlist_path, new_playlist_name); //播放列表后命名后的路径
if (new_path.empty())
{
const wstring& info = theApp.m_str_table.LoadText(L"MSG_PLAYLIST_REMANE_FAILED");
const wstring& info = theApp.m_str_table.LoadText(L"MSG_PLAYLIST_RENANE_FAILED");
MessageBox(info.c_str(), NULL, MB_ICONWARNING | MB_OK);
return;
}
Expand Down Expand Up @@ -780,8 +780,8 @@ void CSelectPlaylistDlg::OnPlaylistFixPathError()
{
if (LeftSelectValid())
{
const wstring& inquary_info = theApp.m_str_table.LoadText(L"MSG_PLAYLIST_FIX_ERROR_PATH_INQUARY");
if (MessageBox(inquary_info.c_str(), NULL, MB_ICONQUESTION | MB_YESNO) == IDYES)
const wstring& inquiry_info = theApp.m_str_table.LoadText(L"MSG_PLAYLIST_FIX_ERROR_PATH_INQUIRY");
if (MessageBox(inquiry_info.c_str(), NULL, MB_ICONQUESTION | MB_YESNO) == IDYES)
{
PlaylistInfo playlist_info{ GetSelectedPlaylist() };
CMusicPlayerCmdHelper helper;
Expand Down
13 changes: 4 additions & 9 deletions MusicPlayer2/Common.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1844,18 +1844,13 @@ POINT CCommon::CalculateWindowMoveOffset(CRect& check_rect, vector<CRect>& scree
return mov;
}

wstring CCommon::GetLastCompileTime()
void CCommon::GetLastCompileTime(wstring& time_str, wstring& hash_str)
{
wstring compile_time = GetTextResource(IDR_COMPILE_TIME, CodeType::ANSI);
size_t pos = compile_time.find(L"\r\n");
while (pos != wstring::npos)
{
compile_time.replace(pos, 2, L"");
pos = compile_time.find(L"\r\n");
}
if (!compile_time.empty())
compile_time.pop_back();
return compile_time;
time_str = compile_time.substr(0, pos);
if (compile_time.size() > pos + 10) // 如果hash存在
hash_str = compile_time.substr(pos + 2, 8); // 截取hash前8位
}

unsigned __int64 CCommon::GetCurTimeElapse()
Expand Down
2 changes: 1 addition & 1 deletion MusicPlayer2/Common.h
Original file line number Diff line number Diff line change
Expand Up @@ -434,7 +434,7 @@ class CCommon
static POINT CalculateWindowMoveOffset(CRect& check_rect, vector<CRect>& screen_rects);

//从资源文件读取上次编译时间
static wstring GetLastCompileTime();
static void GetLastCompileTime(wstring& time_str, wstring& hash_str);

static unsigned __int64 GetCurTimeElapse();

Expand Down
12 changes: 6 additions & 6 deletions MusicPlayer2/DataSettingsDlg.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -59,8 +59,8 @@ bool CDataSettingsDlg::InitializeControls()
SetDlgItemTextW(IDC_MINIMIZE_TO_NOTIFY_RADIO, temp.c_str());
temp = theApp.m_str_table.LoadText(L"TXT_OPT_DATA_CLOSE_MAIN_WINDOW_EXIT");
SetDlgItemTextW(IDC_EXIT_PROGRAM_RADIO, temp.c_str());
temp = theApp.m_str_table.LoadText(L"TXT_OPT_DATA_AUTO_DL_SETTING");
SetDlgItemTextW(IDC_TXT_OPT_DATA_AUTO_DL_SETTING_STATIC, temp.c_str());
temp = theApp.m_str_table.LoadText(L"TXT_OPT_DATA_DL_SETTING");
SetDlgItemTextW(IDC_TXT_OPT_DATA_DL_SETTING_STATIC, temp.c_str());
temp = theApp.m_str_table.LoadText(L"TXT_OPT_DATA_AUTO_DL_LYRIC");
SetDlgItemTextW(IDC_LYRIC_AUTO_DOWNLOAD_CHECK, temp.c_str());
temp = theApp.m_str_table.LoadText(L"TXT_OPT_DATA_AUTO_DL_LYRIC_SAVE_SEL");
Expand All @@ -70,9 +70,9 @@ bool CDataSettingsDlg::InitializeControls()
temp = theApp.m_str_table.LoadText(L"TXT_OPT_DATA_AUTO_DL_LYRIC_SAVE_LYRIC_DIR");
SetDlgItemTextW(IDC_SAVE_TO_LYRIC_FOLDER, temp.c_str());

SetDlgControlText(IDC_DOWN_LOAD_LYRIC_TRANSLATION_FORMAT_STATIC, L"TXT_OPT_DATA_DL_LYRIC_TRANSLATION_FORMAT");
SetDlgControlText(IDC_LYRIC_AND_TRANSLATION_IN_SAME_LINE_RADIO, L"TXT_OPT_DATA_DL_LYRIC_AND_TRANSLATION_IN_SAME_LINE");
SetDlgControlText(IDC_LYRIC_AND_TRANSLATION_IN_DIFFERENT_LINE_RADIO, L"TXT_OPT_DATA_DL_LYRIC_AND_TRANSLATION_IN_DIFFERENT_LINE");
SetDlgControlText(IDC_DOWN_LOAD_LYRIC_TRANSLATION_FORMAT_STATIC, L"TXT_OPT_DATA_DL_LYRIC_TRANSLATION_FORMAT_SEL");
SetDlgControlText(IDC_LYRIC_AND_TRANSLATION_IN_SAME_LINE_RADIO, L"TXT_OPT_DATA_DL_LYRIC_TRANSLATION_FORMAT_SAME_LINE");
SetDlgControlText(IDC_LYRIC_AND_TRANSLATION_IN_DIFFERENT_LINE_RADIO, L"TXT_OPT_DATA_DL_LYRIC_TRANSLATION_FORMAT_DIFFERENT_LINE");

temp = theApp.m_str_table.LoadText(L"TXT_OPT_DATA_AUTO_DL_COVER");
SetDlgItemTextW(IDC_COVER_AUTO_DOWNLOAD_CHECK, temp.c_str());
Expand Down Expand Up @@ -240,7 +240,7 @@ BOOL CDataSettingsDlg::OnInitDialog()
m_toolTip.SetMaxTipWidth(theApp.DPI(300));
m_toolTip.AddTool(GetDlgItem(IDC_DOWNLOAD_WHEN_TAG_FULL_CHECK), theApp.m_str_table.LoadText(L"TIP_OPT_DATA_AUTO_DL_ONLY_WHEN_TAG_FULL").c_str());
//m_toolTip.AddTool(GetDlgItem(IDC_SF2_PATH_EDIT), _T("需要额外的音色库才能播放 MIDI 音乐。"));
m_toolTip.AddTool(GetDlgItem(IDC_MIDI_USE_INNER_LYRIC_CHECK), theApp.m_str_table.LoadText(L"TIP_OPT_DATA_MIDI_INNER_LYRIC_FIRSR").c_str());
m_toolTip.AddTool(GetDlgItem(IDC_MIDI_USE_INNER_LYRIC_CHECK), theApp.m_str_table.LoadText(L"TIP_OPT_DATA_MIDI_INNER_LYRIC_FIRST").c_str());
m_toolTip.AddTool(GetDlgItem(IDC_SAVE_TO_APPDATA_RADIO), theApp.m_appdata_dir.c_str());
m_toolTip.AddTool(GetDlgItem(IDC_SAVE_TO_PROGRAM_DIR_RADIO), theApp.m_module_dir.c_str());

Expand Down
6 changes: 3 additions & 3 deletions MusicPlayer2/FormatConvertDlg.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -566,7 +566,7 @@ void CFormatConvertDlg::SetProgressInfo(int progress)
{
wstring info;
if (progress >= 100)
info = theApp.m_str_table.LoadText(L"TXT_FORMAT_CONVERT_PROGRESS_INFO_COMPLEATE");
info = theApp.m_str_table.LoadText(L"TXT_FORMAT_CONVERT_PROGRESS_INFO_COMPLETE");
else
info = theApp.m_str_table.LoadTextFormat(L"TXT_FORMAT_CONVERT_PROGRESS_INFO", { progress });
SetDlgItemText(IDC_PROGRESS_TEXT, info.c_str());
Expand Down Expand Up @@ -675,11 +675,11 @@ afx_msg LRESULT CFormatConvertDlg::OnConvertProgress(WPARAM wParam, LPARAM lPara
}
else if (percent == 101)
{
status_str = theApp.m_str_table.LoadText(L"TXT_FORMAT_CONVERT_STAUS_COMPLEATE");
status_str = theApp.m_str_table.LoadText(L"TXT_FORMAT_CONVERT_STAUS_COMPLETE");
}
else if (percent == 102)
{
status_str = theApp.m_str_table.LoadText(L"TXT_FORMAT_CONVERT_STAUS_SKIPED");
status_str = theApp.m_str_table.LoadText(L"TXT_FORMAT_CONVERT_STAUS_SKIPPED");
}
else
{
Expand Down
6 changes: 3 additions & 3 deletions MusicPlayer2/LyricBatchDownloadDlg.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -315,7 +315,7 @@ UINT CLyricBatchDownloadDlg::ThreadFunc(LPVOID lpParam)
bool lyric_exist = CCommon::FileExist(lyric_path) || (!pInfo->playlist->at(i).lyric_file.empty());
if (pInfo->skip_exist && lyric_exist) //如果设置了跳过已存在歌词的曲目,并且歌词已经存在,则跳过它
{
pInfo->list_ctrl->SetItemText(i, 4, theApp.m_str_table.LoadText(L"TXT_LYRIC_BDL_STATUS_SKIPED").c_str());
pInfo->list_ctrl->SetItemText(i, 4, theApp.m_str_table.LoadText(L"TXT_LYRIC_BDL_STATUS_SKIPPED").c_str());
continue;
}

Expand Down Expand Up @@ -407,11 +407,11 @@ UINT CLyricBatchDownloadDlg::ThreadFunc(LPVOID lpParam)
if (char_cannot_convert)
pInfo->list_ctrl->SetItemText(i, 4, theApp.m_str_table.LoadText(L"TXT_LYRIC_BDL_STATUS_ENCODE_WARNING").c_str()); //char_cannot_convert为true,则说明有无法转换的Unicode字符
else
pInfo->list_ctrl->SetItemText(i, 4, theApp.m_str_table.LoadText(L"TXT_LYRIC_BDL_STATUS_SUCCESSED").c_str());
pInfo->list_ctrl->SetItemText(i, 4, theApp.m_str_table.LoadText(L"TXT_LYRIC_BDL_STATUS_SUCCEEDED").c_str());
}
else
{
pInfo->list_ctrl->SetItemText(i, 4, theApp.m_str_table.LoadText(L"TXT_LYRIC_BDL_STATUS_SUCCESSED").c_str());
pInfo->list_ctrl->SetItemText(i, 4, theApp.m_str_table.LoadText(L"TXT_LYRIC_BDL_STATUS_SUCCEEDED").c_str());
}

if (pInfo->download_translate)
Expand Down
2 changes: 1 addition & 1 deletion MusicPlayer2/LyricDownloadDlg.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -602,7 +602,7 @@ afx_msg LRESULT CLyricDownloadDlg::OnDownloadComplate(WPARAM wParam, LPARAM lPar
wstring saved_path = GetSavedPath();
if (CCommon::FileExist(saved_path))
{
const wstring& info = theApp.m_str_table.LoadText(L"MSG_LYRIC_OVERWRITE_INQUARY");
const wstring& info = theApp.m_str_table.LoadText(L"MSG_LYRIC_OVERWRITE_INQUIRY");
if (MessageBox(info.c_str(), NULL, MB_ICONWARNING | MB_OKCANCEL) == IDCANCEL)
return 0;
}
Expand Down
4 changes: 2 additions & 2 deletions MusicPlayer2/MediaLibSettingDlg.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -101,7 +101,7 @@ bool CMediaLibSettingDlg::InitializeControls()
SetDlgItemTextW(IDC_FOLDER_EXPLORE_CHECK, temp.c_str());
temp = theApp.m_str_table.LoadText(L"TXT_OPT_MEDIA_LIB_PLAYLIST_OPT");
SetDlgItemTextW(IDC_TXT_OPT_MEDIA_LIB_PLAYLIST_OPT_STATIC, temp.c_str());
temp = theApp.m_str_table.LoadText(L"TXT_OPT_MEDIA_LIB_DISABLE_DRAGE_SORT");
temp = theApp.m_str_table.LoadText(L"TXT_OPT_MEDIA_LIB_DISABLE_DRAG_SORT");
SetDlgItemTextW(IDC_DISABLE_DRAGE_SORT_CHECK, temp.c_str());
temp = theApp.m_str_table.LoadText(L"TXT_OPT_MEDIA_LIB_INS_BEGIN");
SetDlgItemTextW(IDC_INSERT_BEGIN_CHECK, temp.c_str());
Expand Down Expand Up @@ -503,7 +503,7 @@ void CMediaLibSettingDlg::OnBnClickedClearRecentPlayedListBtn()
// TODO: 在此添加控件通知处理程序代码

//清除歌曲的上次播放时间
const wstring& info = theApp.m_str_table.LoadText(L"MSG_OPT_MEDIA_LIB_RECENT_PLAY_CLEAR_INQUARY");
const wstring& info = theApp.m_str_table.LoadText(L"MSG_OPT_MEDIA_LIB_RECENT_PLAY_CLEAR_INQUIRY");
if (MessageBox(info.c_str(), NULL, MB_ICONINFORMATION | MB_YESNO) == IDYES)
{
CSongDataManager::GetInstance().ClearLastPlayedTime();
Expand Down
2 changes: 1 addition & 1 deletion MusicPlayer2/MediaLibTabDlg.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,7 @@ void CMediaLibTabDlg::OnOK()
CMediaClassifier::ClassificationType type = GetClassificationType();
if (type != CMediaClassifier::CT_NONE)
{
ok = CPlayer::GetInstance().SetMediaLibPlaylist(type, GetClassificationItemName(), GetItemSelected());
ok = CPlayer::GetInstance().SetMediaLibPlaylist(type, GetClassificationItemName(), GetItemSelected(), true, true);
}
else
{
Expand Down
2 changes: 1 addition & 1 deletion MusicPlayer2/MusicPlayer2.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -205,7 +205,7 @@ BOOL CMusicPlayerApp::InitInstance()
LoadConfig();
m_str_table.Init(m_local_dir + L"language\\", m_general_setting_data.language_);
CCommon::SetThreadLanguageList(m_str_table.GetLanguageTag());
const wstring& info = theApp.m_str_table.LoadText(L"MSG_APP_RUNING_INFO");
const wstring& info = theApp.m_str_table.LoadText(L"MSG_APP_RUNNING_INFO");
AfxMessageBox(info.c_str(), MB_ICONINFORMATION | MB_OK);
}
return FALSE; //退出当前程序
Expand Down
8 changes: 4 additions & 4 deletions MusicPlayer2/MusicPlayer2.rc
Original file line number Diff line number Diff line change
Expand Up @@ -811,7 +811,7 @@ BEGIN
CONTROL "Minimize to notification area",IDC_MINIMIZE_TO_NOTIFY_RADIO,
"Button",BS_AUTORADIOBUTTON | WS_GROUP,157,74,173,8
CONTROL "Exit the program",IDC_EXIT_PROGRAM_RADIO,"Button",BS_AUTORADIOBUTTON,157,86,173,8
GROUPBOX "Automatic Download Settings",IDC_TXT_OPT_DATA_AUTO_DL_SETTING_STATIC,7,103,330,121
GROUPBOX "Automatic Download Settings",IDC_TXT_OPT_DATA_DL_SETTING_STATIC,7,103,330,121
CONTROL "Automatically download when lyric is not exist",IDC_LYRIC_AUTO_DOWNLOAD_CHECK,
"Button",BS_AUTOCHECKBOX | WS_TABSTOP,14,114,316,8
LTEXT "Automatically Download Lyrics Save Location:",IDC_TXT_OPT_DATA_AUTO_DL_LYRIC_SAVE_SEL_STATIC,14,125,316,8
Expand All @@ -827,10 +827,10 @@ BEGIN
CONTROL "Automatically download when album cover is not exist",IDC_COVER_AUTO_DOWNLOAD_CHECK,
"Button",BS_AUTOCHECKBOX | WS_TABSTOP,14,179,316,8
LTEXT "Automatically Download Album Cover Save Location:",IDC_TXT_OPT_DATA_AUTO_DL_COVER_SAVE_SEL_STATIC,14,189,316,8
CONTROL "Save to the same directory as the song",IDC_SAVE_TO_SONG_FOLDER3,
"Button",BS_AUTORADIOBUTTON | WS_GROUP,150,200,180,8
CONTROL "Save to album cover directory",IDC_SAVE_TO_ALBUM_FOLDER3,
"Button",BS_AUTORADIOBUTTON,21,200,119,8
CONTROL "Save to the same directory as the song",IDC_SAVE_TO_SONG_FOLDER3,
"Button",BS_AUTORADIOBUTTON | WS_GROUP,150,200,180,8
CONTROL "Download automatically only when the song information is complete",IDC_DOWNLOAD_WHEN_TAG_FULL_CHECK,
"Button",BS_AUTOCHECKBOX | WS_TABSTOP,14,211,316,8
GROUPBOX "MIDI Setting",IDC_TXT_OPT_DATA_MIDI_SETTING_STATIC,7,229,330,39
Expand Down Expand Up @@ -2268,8 +2268,8 @@ BEGIN
0, 0, 100, 0,
0, 0, 100, 0,
0, 0, 100, 0,
44, 0, 56, 0,
0, 0, 44, 0,
44, 0, 56, 0,
0, 0, 100, 0,
0, 0, 100, 0,
0, 0, 100, 0,
Expand Down
4 changes: 2 additions & 2 deletions MusicPlayer2/MusicPlayerCmdHelper.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -204,7 +204,7 @@ bool CMusicPlayerCmdHelper::DeleteSongsFromDisk(const std::vector<SongInfo>& fil
if (theApp.m_media_lib_setting_data.disable_delete_from_disk)
return false;

wstring info = theApp.m_str_table.LoadTextFormat(L"MSG_DELETE_SEL_AUDIO_FILE_INQUARY", { files.size() });
wstring info = theApp.m_str_table.LoadTextFormat(L"MSG_DELETE_SEL_AUDIO_FILE_INQUIRY", { files.size() });
if (GetOwner()->MessageBox(info.c_str(), NULL, MB_ICONWARNING | MB_OKCANCEL) != IDOK)
return false;

Expand Down Expand Up @@ -742,7 +742,7 @@ void CMusicPlayerCmdHelper::OnRecentItemSelected(const CRecentFolderAndPlaylist:
{
if (item->medialib_info != nullptr)
{
if (!CPlayer::GetInstance().SetMediaLibPlaylist(item->medialib_info->medialib_type, item->medialib_info->path, -1, false))
if (!CPlayer::GetInstance().SetMediaLibPlaylist(item->medialib_info->medialib_type, item->medialib_info->path))
{
const wstring& info = theApp.m_str_table.LoadText(L"MSG_WAIT_AND_RETRY");
AfxMessageBox(info.c_str(), NULL, MB_ICONINFORMATION | MB_OK);
Expand Down
Loading

0 comments on commit ba5db30

Please sign in to comment.