Revision | 29531 (tree) |
---|---|
Time | 2023-03-01 03:05:47 |
Author | stefankueng |
respect ancestry when merging to a WC
@@ -91,7 +91,7 @@ | ||
91 | 91 | #define WM_TSVN_MONITOR_TREEDROP (WM_APP + 4) |
92 | 92 | #define WM_TSVN_MONITOR_SNARLREPLY (WM_APP + 5) |
93 | 93 | |
94 | -#define OVERLAY_MODIFIED 1 | |
94 | +#define OVERLAY_MODIFIED 1 | |
95 | 95 | |
96 | 96 | auto g_snarlInterface = Snarl::V42::SnarlInterface(); |
97 | 97 | UINT g_snarlGlobalMsg = 0; |
@@ -572,8 +572,8 @@ | ||
572 | 572 | void CLogDlg::LoadIconsForActionColumns() |
573 | 573 | { |
574 | 574 | // load the icons for the action columns |
575 | - int cx = GetSystemMetrics(SM_CXSMICON); | |
576 | - int cy = GetSystemMetrics(SM_CYSMICON); | |
575 | + int cx = GetSystemMetrics(SM_CXSMICON); | |
576 | + int cy = GetSystemMetrics(SM_CYSMICON); | |
577 | 577 | |
578 | 578 | m_hModifiedIcon = CCommonAppUtils::LoadIconEx(IDI_ACTIONMODIFIED, cx, cy); |
579 | 579 | m_hReplacedIcon = CCommonAppUtils::LoadIconEx(IDI_ACTIONREPLACED, cx, cy); |
@@ -589,7 +589,7 @@ | ||
589 | 589 | { |
590 | 590 | CString temp; |
591 | 591 | // set up the columns |
592 | - int c = m_logList.GetHeaderCtrl()->GetItemCount() - 1; | |
592 | + int c = m_logList.GetHeaderCtrl()->GetItemCount() - 1; | |
593 | 593 | while (c >= 0) |
594 | 594 | m_logList.DeleteColumn(c--); |
595 | 595 | temp.LoadString(IDS_LOG_REVISION); |
@@ -959,8 +959,8 @@ | ||
959 | 959 | if (ranges.size() < 2) |
960 | 960 | return; |
961 | 961 | |
962 | - auto begin = ranges.begin(); | |
963 | - auto end = ranges.end(); | |
962 | + auto begin = ranges.begin(); | |
963 | + auto end = ranges.end(); | |
964 | 964 | |
965 | 965 | auto target = begin; |
966 | 966 | for (auto source = begin + 1; source != end; ++source) |
@@ -977,8 +977,8 @@ | ||
977 | 977 | { |
978 | 978 | struct SMarkerInfo |
979 | 979 | { |
980 | - CString sText; | |
981 | - std::wstring text; | |
980 | + CString sText; | |
981 | + std::wstring text; | |
982 | 982 | |
983 | 983 | std::vector<CHARRANGE> ranges; |
984 | 984 | std::vector<CHARRANGE> idRanges; |
@@ -985,11 +985,11 @@ | ||
985 | 985 | std::vector<CHARRANGE> revRanges; |
986 | 986 | std::vector<CHARRANGE> urlRanges; |
987 | 987 | |
988 | - BOOL RunRegex(ProjectProperties* project) | |
988 | + BOOL RunRegex(ProjectProperties* project) | |
989 | 989 | { |
990 | 990 | // turn bug ID's into links if the bugtraq: properties have been set |
991 | 991 | // and we can find a match of those in the log message |
992 | - idRanges = project->FindBugIDPositions(sText); | |
992 | + idRanges = project->FindBugIDPositions(sText); | |
993 | 993 | |
994 | 994 | // underline all revisions mentioned in the message |
995 | 995 | revRanges = CAppUtils::FindRegexMatches(text, project->GetLogRevRegex(), L"\\d+"); |
@@ -1248,7 +1248,7 @@ | ||
1248 | 1248 | |
1249 | 1249 | void CLogDlg::Refresh(bool autoGoOnline) |
1250 | 1250 | { |
1251 | - //does the user force the cache to refresh (shift or control key down)? | |
1251 | + // does the user force the cache to refresh (shift or control key down)? | |
1252 | 1252 | m_nRefresh = ((GetKeyState(VK_CONTROL) < 0) || (GetKeyState(VK_SHIFT) < 0)) ? Cache : Simple; |
1253 | 1253 | |
1254 | 1254 | // refreshing means re-downloading the already shown log messages |
@@ -1341,7 +1341,7 @@ | ||
1341 | 1341 | // rev is is revision we already have and we will receive it again |
1342 | 1342 | // -> fetch one extra revision to get NumberOfLogs *new* revisions |
1343 | 1343 | |
1344 | - m_limit = static_cast<int>(static_cast<DWORD>(CRegDWORD(L"Software\\TortoiseSVN\\NumberOfLogs", 100))) + 1; | |
1344 | + m_limit = static_cast<int>(static_cast<DWORD>(CRegDWORD(L"Software\\TortoiseSVN\\NumberOfLogs", 100))) + 1; | |
1345 | 1345 | InterlockedExchange(&m_bLogThreadRunning, TRUE); |
1346 | 1346 | SetSortArrow(&m_logList, -1, true); |
1347 | 1347 |
@@ -1419,11 +1419,11 @@ | ||
1419 | 1419 | MonitorHideDlg(); |
1420 | 1420 | return; |
1421 | 1421 | } |
1422 | - bool bWasCancelled = m_bCancelled; | |
1422 | + bool bWasCancelled = m_bCancelled; | |
1423 | 1423 | // canceling means stopping the working thread if it's still running. |
1424 | 1424 | // we do this by using the Subversion cancel callback. |
1425 | 1425 | |
1426 | - m_bCancelled = true; | |
1426 | + m_bCancelled = true; | |
1427 | 1427 | |
1428 | 1428 | // We want to close the dialog -> give the background threads some time |
1429 | 1429 | // to actually finish. Otherwise, we might not save the latest data. |
@@ -1492,7 +1492,7 @@ | ||
1492 | 1492 | { |
1493 | 1493 | if (m_bLogThreadRunning) |
1494 | 1494 | { |
1495 | - m_bCancelled = true; | |
1495 | + m_bCancelled = true; | |
1496 | 1496 | |
1497 | 1497 | bool threadsStillRunning = !netScheduler.WaitForEmptyQueueOrTimeout(5000) || !diskScheduler.WaitForEmptyQueueOrTimeout(5000); |
1498 | 1498 |
@@ -1586,7 +1586,7 @@ | ||
1586 | 1586 | return TRUE; |
1587 | 1587 | } |
1588 | 1588 | |
1589 | -//this is the thread function which calls the subversion function | |
1589 | +// this is the thread function which calls the subversion function | |
1590 | 1590 | void CLogDlg::LogThread() |
1591 | 1591 | { |
1592 | 1592 | InterlockedExchange(&m_bLogThreadRunning, TRUE); |
@@ -1600,8 +1600,8 @@ | ||
1600 | 1600 | |
1601 | 1601 | new async::CAsyncCall(this, &CLogDlg::StatusThread, &diskScheduler); |
1602 | 1602 | |
1603 | - //disable the "Get All" button while we're receiving | |
1604 | - //log messages. | |
1603 | + // disable the "Get All" button while we're receiving | |
1604 | + // log messages. | |
1605 | 1605 | DialogEnableWindow(IDC_GETALL, FALSE); |
1606 | 1606 | DialogEnableWindow(IDC_NEXTHUNDRED, FALSE); |
1607 | 1607 | DialogEnableWindow(IDC_HIDENONMERGEABLE, FALSE); |
@@ -1997,7 +1997,7 @@ | ||
1997 | 1997 | PostMessage(WM_TIMER, LOGFILTER_TIMER); |
1998 | 1998 | } |
1999 | 1999 | |
2000 | -//this is the thread function which calls the subversion function | |
2000 | +// this is the thread function which calls the subversion function | |
2001 | 2001 | void CLogDlg::StatusThread() |
2002 | 2002 | { |
2003 | 2003 | bool bAllowStatusCheck = m_bMonitoringMode || !!static_cast<DWORD>(CRegDWORD(L"Software\\TortoiseSVN\\LogStatusCheck", TRUE)); |
@@ -2028,7 +2028,7 @@ | ||
2028 | 2028 | // we can paste this list into a code review tool |
2029 | 2029 | void CLogDlg::CopyCommaSeparatedRevisionsToClipboard() const |
2030 | 2030 | { |
2031 | - POSITION pos = m_logList.GetFirstSelectedItemPosition(); | |
2031 | + POSITION pos = m_logList.GetFirstSelectedItemPosition(); | |
2032 | 2032 | |
2033 | 2033 | std::set<svn_revnum_t> setSelectedRevisions; |
2034 | 2034 |
@@ -2257,9 +2257,9 @@ | ||
2257 | 2257 | if (pLogEntry == nullptr) |
2258 | 2258 | continue; |
2259 | 2259 | |
2260 | - CString logMessage = CUnicodeUtils::StdGetUnicode(pLogEntry->GetMessageW()).c_str(); | |
2260 | + CString logMessage = CUnicodeUtils::StdGetUnicode(pLogEntry->GetMessageW()).c_str(); | |
2261 | 2261 | |
2262 | - std::set<CString> setBugIDs = m_projectProperties.FindBugIDs(logMessage); | |
2262 | + std::set<CString> setBugIDs = m_projectProperties.FindBugIDs(logMessage); | |
2263 | 2263 | setAllBugIDs.merge(setBugIDs); |
2264 | 2264 | } |
2265 | 2265 | } |
@@ -2378,7 +2378,7 @@ | ||
2378 | 2378 | if (pos == nullptr) |
2379 | 2379 | return; // nothing is selected, get out of here |
2380 | 2380 | |
2381 | - CString sPaths; | |
2381 | + CString sPaths; | |
2382 | 2382 | |
2383 | 2383 | POSITION pos2 = m_changedFileListCtrl.GetFirstSelectedItemPosition(); |
2384 | 2384 | while (pos2) |
@@ -2516,11 +2516,11 @@ | ||
2516 | 2516 | |
2517 | 2517 | if (m_pFindDialog->FindNext()) |
2518 | 2518 | { |
2519 | - //read data from dialog | |
2520 | - CString findText = m_pFindDialog->GetFindString(); | |
2521 | - bool bMatchCase = (m_pFindDialog->MatchCase() == TRUE); | |
2522 | - std::wregex pat; | |
2523 | - bool bRegex = ValidateRegexp(findText, pat, bMatchCase); | |
2519 | + // read data from dialog | |
2520 | + CString findText = m_pFindDialog->GetFindString(); | |
2521 | + bool bMatchCase = (m_pFindDialog->MatchCase() == TRUE); | |
2522 | + std::wregex pat; | |
2523 | + bool bRegex = ValidateRegexp(findText, pat, bMatchCase); | |
2524 | 2524 | |
2525 | 2525 | bool scanRelevantPathsOnly = (m_cShowPaths.GetState() & 0x0003) == BST_CHECKED; |
2526 | 2526 | CLogDlgFilter filter(findText, bRegex, LOGFILTER_ALL, bMatchCase, m_tFrom, m_tTo, scanRelevantPathsOnly, &m_mergedRevs, !!m_bHideNonMergeables, m_copyFromRev, -1); |
@@ -2660,7 +2660,7 @@ | ||
2660 | 2660 | { |
2661 | 2661 | sUrl = GetURLFromPath(m_path); |
2662 | 2662 | } |
2663 | - sUrl = sUrl.Mid(m_sRepositoryRoot.GetLength()); | |
2663 | + sUrl = sUrl.Mid(m_sRepositoryRoot.GetLength()); | |
2664 | 2664 | |
2665 | 2665 | const CLogChangedPathArray& paths = pLogEntry->GetChangedPaths(); |
2666 | 2666 | for (size_t cp = 0; cp < paths.GetCount(); ++cp) |
@@ -2793,8 +2793,8 @@ | ||
2793 | 2793 | } |
2794 | 2794 | else |
2795 | 2795 | { |
2796 | - const CLogChangedPathArray& paths = pLogEntry->GetChangedPaths(); | |
2797 | - rev2 = rev1 - 1; | |
2796 | + const CLogChangedPathArray& paths = pLogEntry->GetChangedPaths(); | |
2797 | + rev2 = rev1 - 1; | |
2798 | 2798 | // nothing or only one revision selected in the log list |
2799 | 2799 | |
2800 | 2800 | const CLogChangedPath& changedPath = m_currentChangedArray[selIndex]; |
@@ -2833,7 +2833,7 @@ | ||
2833 | 2833 | else |
2834 | 2834 | { |
2835 | 2835 | CTSVNPath tempFile = CTempFiles::Instance().GetTempFilePath(false, |
2836 | - CTSVNPath(changedPath.GetPath())); | |
2836 | + CTSVNPath(changedPath.GetPath())); | |
2837 | 2837 | CTSVNPath tempFile2 = CTempFiles::Instance().GetTempFilePath(false, |
2838 | 2838 | CTSVNPath(changedPath.GetPath())); |
2839 | 2839 | SVNRev r = rev1; |
@@ -2938,15 +2938,15 @@ | ||
2938 | 2938 | PLOGENTRYDATA pLogEntry = m_logEntries.GetVisible(m_logList.GetNextSelectedItem(pos)); |
2939 | 2939 | if (pLogEntry == nullptr) |
2940 | 2940 | return; |
2941 | - long rev1 = pLogEntry->GetRevision(); | |
2942 | - long rev2 = rev1 - 1; | |
2943 | - CTSVNPath path = m_path; | |
2941 | + long rev1 = pLogEntry->GetRevision(); | |
2942 | + long rev2 = rev1 - 1; | |
2943 | + CTSVNPath path = m_path; | |
2944 | 2944 | |
2945 | 2945 | // See how many files under the relative root were changed in selected revision |
2946 | - int nChanged = 0; | |
2947 | - size_t lastChangedIndex = static_cast<size_t>(-1); | |
2946 | + int nChanged = 0; | |
2947 | + size_t lastChangedIndex = static_cast<size_t>(-1); | |
2948 | 2948 | |
2949 | - const CLogChangedPathArray& paths = pLogEntry->GetChangedPaths(); | |
2949 | + const CLogChangedPathArray& paths = pLogEntry->GetChangedPaths(); | |
2950 | 2950 | for (size_t c = 0; c < paths.GetCount(); ++c) |
2951 | 2951 | if (paths[c].IsRelevantForStartPath()) |
2952 | 2952 | { |
@@ -2993,7 +2993,7 @@ | ||
2993 | 2993 | { |
2994 | 2994 | DialogEnableWindow(IDOK, FALSE); |
2995 | 2995 | SetPromptApp(&theApp); |
2996 | - //get the filename | |
2996 | + // get the filename | |
2997 | 2997 | CString filepath; |
2998 | 2998 | if (SVN::PathIsURL(m_path)) |
2999 | 2999 | { |
@@ -3006,7 +3006,7 @@ | ||
3006 | 3006 | { |
3007 | 3007 | ReportNoUrlOfFile(filepath); |
3008 | 3008 | EnableOKButton(); |
3009 | - return; //exit | |
3009 | + return; // exit | |
3010 | 3010 | } |
3011 | 3011 | } |
3012 | 3012 | m_bCancelled = FALSE; |
@@ -3015,13 +3015,13 @@ | ||
3015 | 3015 | { |
3016 | 3016 | ShowErrorDialog(m_hWnd); |
3017 | 3017 | EnableOKButton(); |
3018 | - return; //exit | |
3018 | + return; // exit | |
3019 | 3019 | } |
3020 | 3020 | // filepath is in escaped form. But since the changedpath |
3021 | 3021 | // is not, we have to unescape the filepath here first, |
3022 | 3022 | // so the escaped parts won't get escaped again in case changedpath |
3023 | 3023 | // needs escaping as well |
3024 | - filepath = CPathUtils::PathUnescape(filepath); | |
3024 | + filepath = CPathUtils::PathUnescape(filepath); | |
3025 | 3025 | |
3026 | 3026 | svn_node_kind_t nodeKind = svn_node_unknown; |
3027 | 3027 |
@@ -3152,7 +3152,7 @@ | ||
3152 | 3152 | |
3153 | 3153 | LogCache::CCachedLogInfo* toUpdate = GetLogCache(CTSVNPath(m_sRepositoryRoot)); |
3154 | 3154 | |
3155 | - CProgressDlg progDlg; | |
3155 | + CProgressDlg progDlg; | |
3156 | 3156 | progDlg.SetTitle(IDS_APPNAME); |
3157 | 3157 | progDlg.SetLine(1, CString(MAKEINTRESOURCE(IDS_PROGRESSWAIT))); |
3158 | 3158 | progDlg.SetTime(true); |
@@ -3207,13 +3207,13 @@ | ||
3207 | 3207 | SetPromptApp(&theApp); |
3208 | 3208 | CLogWndHourglass wait; |
3209 | 3209 | |
3210 | - CString url; | |
3210 | + CString url; | |
3211 | 3211 | if (SVN::PathIsURL(m_path)) |
3212 | 3212 | url = m_path.GetSVNPathString(); |
3213 | 3213 | else |
3214 | 3214 | url = GetURLFromPath(m_path); |
3215 | 3215 | |
3216 | - CString name = CString(SVN_PROP_REVISION_LOG); | |
3216 | + CString name = CString(SVN_PROP_REVISION_LOG); | |
3217 | 3217 | |
3218 | 3218 | PLOGENTRYDATA pLogEntry = m_logEntries.GetVisible(index); |
3219 | 3219 | if (pLogEntry == nullptr) |
@@ -3269,16 +3269,16 @@ | ||
3269 | 3269 | |
3270 | 3270 | BOOL CLogDlg::PreTranslateMessage(MSG* pMsg) |
3271 | 3271 | { |
3272 | - CWnd* wndFocus = GetFocus(); | |
3272 | + CWnd* wndFocus = GetFocus(); | |
3273 | 3273 | |
3274 | 3274 | // Skip Ctrl-C when copying text out of the log message or search filter |
3275 | - BOOL bSkipAccelerator = (pMsg->message == WM_KEYDOWN && | |
3275 | + BOOL bSkipAccelerator = (pMsg->message == WM_KEYDOWN && | |
3276 | 3276 | (pMsg->wParam == L'C' || pMsg->wParam == VK_INSERT) && |
3277 | 3277 | (wndFocus == GetDlgItem(IDC_MSGVIEW) || wndFocus == GetDlgItem(IDC_SEARCHEDIT)) && |
3278 | 3278 | GetKeyState(VK_CONTROL) & 0x8000); |
3279 | 3279 | |
3280 | 3280 | // Skip the 'Delete' key if the filter box is not empty |
3281 | - bSkipAccelerator = bSkipAccelerator || (pMsg->message == WM_KEYDOWN && | |
3281 | + bSkipAccelerator = bSkipAccelerator || (pMsg->message == WM_KEYDOWN && | |
3282 | 3282 | (pMsg->wParam == VK_DELETE) && |
3283 | 3283 | (GetDlgItem(IDC_SEARCHEDIT)->GetWindowTextLength() > 0)); |
3284 | 3284 | if (pMsg->message == WM_KEYDOWN && pMsg->wParam == VK_RETURN) |
@@ -3470,7 +3470,7 @@ | ||
3470 | 3470 | } |
3471 | 3471 | // now check whether it matches a revision |
3472 | 3472 | const std::wregex regMatch(m_projectProperties.GetLogRevRegex(), |
3473 | - std::regex_constants::icase | std::regex_constants::ECMAScript); | |
3473 | + std::regex_constants::icase | std::regex_constants::ECMAScript); | |
3474 | 3474 | const std::wsregex_iterator end; |
3475 | 3475 | std::wstring s = static_cast<LPCWSTR>(msg); |
3476 | 3476 | for (std::wsregex_iterator it(s.begin(), s.end(), regMatch); it != end; ++it) |
@@ -3557,7 +3557,7 @@ | ||
3557 | 3557 | |
3558 | 3558 | std::map<__time64_t, PLOGENTRYDATA> revsByDate; |
3559 | 3559 | |
3560 | - std::set<svn_revnum_t> revisionsCovered; | |
3560 | + std::set<svn_revnum_t> revisionsCovered; | |
3561 | 3561 | for (size_t i = 0; i < m_logEntries.GetVisibleCount(); ++i) |
3562 | 3562 | { |
3563 | 3563 | PLOGENTRYDATA entry = m_logEntries.GetVisible(i); |
@@ -3597,7 +3597,7 @@ | ||
3597 | 3597 | { |
3598 | 3598 | NMLVCUSTOMDRAW* pLVCD = reinterpret_cast<NMLVCUSTOMDRAW*>(pNMHDR); |
3599 | 3599 | // Take the default processing unless we set this to something else below. |
3600 | - *pResult = CDRF_DODEFAULT; | |
3600 | + *pResult = CDRF_DODEFAULT; | |
3601 | 3601 | |
3602 | 3602 | if (m_bLogThreadRunning) |
3603 | 3603 | return; |
@@ -3680,11 +3680,11 @@ | ||
3680 | 3680 | if (pLogEntry == nullptr) |
3681 | 3681 | return; |
3682 | 3682 | |
3683 | - int nIcons = 0; | |
3684 | - int iconWidth = ::GetSystemMetrics(SM_CXSMICON); | |
3685 | - int iconHeight = ::GetSystemMetrics(SM_CYSMICON); | |
3683 | + int nIcons = 0; | |
3684 | + int iconWidth = ::GetSystemMetrics(SM_CXSMICON); | |
3685 | + int iconHeight = ::GetSystemMetrics(SM_CYSMICON); | |
3686 | 3686 | |
3687 | - CRect rect = DrawListColumnBackground(m_logList, pLVCD, pLogEntry); | |
3687 | + CRect rect = DrawListColumnBackground(m_logList, pLVCD, pLogEntry); | |
3688 | 3688 | CMemDC myDC(*CDC::FromHandle(pLVCD->nmcd.hdc), rect); |
3689 | 3689 | BitBlt(myDC.GetDC(), rect.left, rect.top, rect.Width(), rect.Height(), pLVCD->nmcd.hdc, rect.left, rect.top, SRCCOPY); |
3690 | 3690 |
@@ -3754,7 +3754,7 @@ | ||
3754 | 3754 | return; |
3755 | 3755 | } |
3756 | 3756 | break; |
3757 | - case 4: //message or bug id | |
3757 | + case 4: // message or bug id | |
3758 | 3758 | if (pLogEntry == nullptr) |
3759 | 3759 | return; |
3760 | 3760 | if (m_bShowBugtraqColumn) |
@@ -3802,7 +3802,7 @@ | ||
3802 | 3802 | else if (CDDS_ITEMPREPAINT == pLVCD->nmcd.dwDrawStage) |
3803 | 3803 | { |
3804 | 3804 | // Tell Windows to send draw notifications for each subitem. |
3805 | - *pResult = CDRF_NOTIFYSUBITEMDRAW; | |
3805 | + *pResult = CDRF_NOTIFYSUBITEMDRAW; | |
3806 | 3806 | |
3807 | 3807 | COLORREF crText = CTheme::Instance().IsDarkTheme() ? CTheme::darkTextColor : GetSysColor(COLOR_WINDOWTEXT); |
3808 | 3808 | bool bGrayed = false; |
@@ -3968,13 +3968,13 @@ | ||
3968 | 3968 | std::vector<CHARRANGE> ranges = m_filter.GetMatchRanges(matchText); |
3969 | 3969 | if (!ranges.empty()) |
3970 | 3970 | { |
3971 | - int drawPos = 0; | |
3971 | + int drawPos = 0; | |
3972 | 3972 | |
3973 | 3973 | // even though we initialize the 'rect' here with nmcd.rc, |
3974 | 3974 | // we must not use it but use the rects from GetItemRect() |
3975 | 3975 | // and GetSubItemRect(). Because on XP, the nmcd.rc has |
3976 | 3976 | // bogus data in it. |
3977 | - CRect rect = pLVCD->nmcd.rc; | |
3977 | + CRect rect = pLVCD->nmcd.rc; | |
3978 | 3978 | |
3979 | 3979 | // find the margin where the text label starts |
3980 | 3980 | CRect labelRC, boundsRC, iconRC; |
@@ -4068,7 +4068,7 @@ | ||
4068 | 4068 | InflateRect(&rect, -(2 * borderWidth), 0); |
4069 | 4069 | |
4070 | 4070 | rect.left += leftMargin; |
4071 | - RECT rc = rect; | |
4071 | + RECT rc = rect; | |
4072 | 4072 | |
4073 | 4073 | // is the column left- or right-aligned? (we don't handle centered (yet)) |
4074 | 4074 | LVCOLUMN column; |
@@ -4139,16 +4139,16 @@ | ||
4139 | 4139 | CRect messageViewRect; |
4140 | 4140 | GetDlgItem(IDC_MSGVIEW)->GetClientRect(messageViewRect); |
4141 | 4141 | |
4142 | - int messageViewDelta = max(-delta, 20 - messageViewRect.Height()); | |
4143 | - int changeFileListDelta = -delta - messageViewDelta; | |
4142 | + int messageViewDelta = max(-delta, 20 - messageViewRect.Height()); | |
4143 | + int changeFileListDelta = -delta - messageViewDelta; | |
4144 | 4144 | |
4145 | 4145 | // set new sizes & positions |
4146 | 4146 | |
4147 | - auto hdwp = BeginDeferWindowPos(4); | |
4148 | - hdwp = CSplitterControl::ChangeRect(hdwp, &m_logList, 0, 0, 0, delta); | |
4149 | - hdwp = CSplitterControl::ChangeRect(hdwp, GetDlgItem(IDC_MSGVIEW), 0, delta, 0, delta + messageViewDelta); | |
4150 | - hdwp = CSplitterControl::ChangeRect(hdwp, GetDlgItem(IDC_SPLITTERBOTTOM), 0, -changeFileListDelta, 0, -changeFileListDelta); | |
4151 | - hdwp = CSplitterControl::ChangeRect(hdwp, &m_changedFileListCtrl, 0, -changeFileListDelta, 0, 0); | |
4147 | + auto hdwp = BeginDeferWindowPos(4); | |
4148 | + hdwp = CSplitterControl::ChangeRect(hdwp, &m_logList, 0, 0, 0, delta); | |
4149 | + hdwp = CSplitterControl::ChangeRect(hdwp, GetDlgItem(IDC_MSGVIEW), 0, delta, 0, delta + messageViewDelta); | |
4150 | + hdwp = CSplitterControl::ChangeRect(hdwp, GetDlgItem(IDC_SPLITTERBOTTOM), 0, -changeFileListDelta, 0, -changeFileListDelta); | |
4151 | + hdwp = CSplitterControl::ChangeRect(hdwp, &m_changedFileListCtrl, 0, -changeFileListDelta, 0, 0); | |
4152 | 4152 | EndDeferWindowPos(hdwp); |
4153 | 4153 | |
4154 | 4154 | AddMainAnchors(); |
@@ -4171,15 +4171,15 @@ | ||
4171 | 4171 | CRect messageViewRect; |
4172 | 4172 | GetDlgItem(IDC_MSGVIEW)->GetClientRect(messageViewRect); |
4173 | 4173 | |
4174 | - int messageViewDelta = max(delta, 20 - messageViewRect.Height()); | |
4175 | - int logListDelta = delta - messageViewDelta; | |
4174 | + int messageViewDelta = max(delta, 20 - messageViewRect.Height()); | |
4175 | + int logListDelta = delta - messageViewDelta; | |
4176 | 4176 | |
4177 | 4177 | // set new sizes & positions |
4178 | - auto hdwp = BeginDeferWindowPos(4); | |
4179 | - hdwp = CSplitterControl::ChangeRect(hdwp, &m_logList, 0, 0, 0, logListDelta); | |
4180 | - hdwp = CSplitterControl::ChangeRect(hdwp, GetDlgItem(IDC_SPLITTERTOP), 0, logListDelta, 0, logListDelta); | |
4181 | - hdwp = CSplitterControl::ChangeRect(hdwp, GetDlgItem(IDC_MSGVIEW), 0, logListDelta, 0, logListDelta + messageViewDelta); | |
4182 | - hdwp = CSplitterControl::ChangeRect(hdwp, &m_changedFileListCtrl, 0, delta, 0, 0); | |
4178 | + auto hdwp = BeginDeferWindowPos(4); | |
4179 | + hdwp = CSplitterControl::ChangeRect(hdwp, &m_logList, 0, 0, 0, logListDelta); | |
4180 | + hdwp = CSplitterControl::ChangeRect(hdwp, GetDlgItem(IDC_SPLITTERTOP), 0, logListDelta, 0, logListDelta); | |
4181 | + hdwp = CSplitterControl::ChangeRect(hdwp, GetDlgItem(IDC_MSGVIEW), 0, logListDelta, 0, logListDelta + messageViewDelta); | |
4182 | + hdwp = CSplitterControl::ChangeRect(hdwp, &m_changedFileListCtrl, 0, delta, 0, 0); | |
4183 | 4183 | EndDeferWindowPos(hdwp); |
4184 | 4184 | |
4185 | 4185 | AddMainAnchors(); |
@@ -4447,7 +4447,7 @@ | ||
4447 | 4447 | NMLVDISPINFO* pDispInfo = reinterpret_cast<NMLVDISPINFO*>(pNMHDR); |
4448 | 4448 | |
4449 | 4449 | // Create a pointer to the item |
4450 | - LV_ITEM* pItem = &(pDispInfo)->item; | |
4450 | + LV_ITEM* pItem = &(pDispInfo)->item; | |
4451 | 4451 | |
4452 | 4452 | // Which item number? |
4453 | 4453 | size_t itemId = pItem->iItem; |
@@ -4469,12 +4469,12 @@ | ||
4469 | 4469 | UINT state = m_logList.GetItemState(pItem->iItem, LVIS_SELECTED); |
4470 | 4470 | if (state & LVIS_SELECTED) |
4471 | 4471 | { |
4472 | - //Turn check box on | |
4472 | + // Turn check box on | |
4473 | 4473 | pItem->state = INDEXTOSTATEIMAGEMASK(2); |
4474 | 4474 | } |
4475 | 4475 | else |
4476 | 4476 | { |
4477 | - //Turn check box off | |
4477 | + // Turn check box off | |
4478 | 4478 | pItem->state = INDEXTOSTATEIMAGEMASK(1); |
4479 | 4479 | } |
4480 | 4480 | } |
@@ -4494,7 +4494,7 @@ | ||
4494 | 4494 | // Which column? |
4495 | 4495 | switch (pItem->iSubItem) |
4496 | 4496 | { |
4497 | - case 0: //revision | |
4497 | + case 0: // revision | |
4498 | 4498 | if (pLogEntry) |
4499 | 4499 | { |
4500 | 4500 | swprintf_s(pItem->pszText, pItem->cchTextMax, L"%ld", pLogEntry->GetRevision()); |
@@ -4517,7 +4517,7 @@ | ||
4517 | 4517 | if (pLogEntry) |
4518 | 4518 | lstrcpyn(pItem->pszText, L"Action column" /*L"XXXXXXXXXXXXXXXX"*/, pItem->cchTextMax - 1); |
4519 | 4519 | break; |
4520 | - case 2: //author | |
4520 | + case 2: // author | |
4521 | 4521 | if (pLogEntry) |
4522 | 4522 | { |
4523 | 4523 | lstrcpyn(pItem->pszText, CUnicodeUtils::StdGetUnicode(pLogEntry->GetAuthor()).c_str(), |
@@ -4524,7 +4524,7 @@ | ||
4524 | 4524 | pItem->cchTextMax - 1); |
4525 | 4525 | } |
4526 | 4526 | break; |
4527 | - case 3: //date | |
4527 | + case 3: // date | |
4528 | 4528 | if (pLogEntry) |
4529 | 4529 | { |
4530 | 4530 | lstrcpyn(pItem->pszText, CUnicodeUtils::StdGetUnicode(pLogEntry->GetDateString()).c_str(), |
@@ -4531,7 +4531,7 @@ | ||
4531 | 4531 | pItem->cchTextMax - 1); |
4532 | 4532 | } |
4533 | 4533 | break; |
4534 | - case 4: //message or bug id | |
4534 | + case 4: // message or bug id | |
4535 | 4535 | if (m_bShowBugtraqColumn) |
4536 | 4536 | { |
4537 | 4537 | if (pLogEntry) |
@@ -4573,11 +4573,11 @@ | ||
4573 | 4573 | |
4574 | 4574 | void CLogDlg::OnLvnGetdispinfoChangedFileList(NMHDR* pNMHDR, LRESULT* pResult) |
4575 | 4575 | { |
4576 | - *pResult = 0; | |
4576 | + *pResult = 0; | |
4577 | 4577 | |
4578 | 4578 | NMLVDISPINFO* pDispInfo = reinterpret_cast<NMLVDISPINFO*>(pNMHDR); |
4579 | - //Create a pointer to the item | |
4580 | - LV_ITEM* pItem = &(pDispInfo)->item; | |
4579 | + // Create a pointer to the item | |
4580 | + LV_ITEM* pItem = &(pDispInfo)->item; | |
4581 | 4581 | |
4582 | 4582 | if (m_bLogThreadRunning) |
4583 | 4583 | { |
@@ -4598,25 +4598,25 @@ | ||
4598 | 4598 | return; |
4599 | 4599 | } |
4600 | 4600 | |
4601 | - //Does the list need text information? | |
4601 | + // Does the list need text information? | |
4602 | 4602 | if (pItem->mask & LVIF_TEXT) |
4603 | 4603 | { |
4604 | - //Which column? | |
4604 | + // Which column? | |
4605 | 4605 | switch (pItem->iSubItem) |
4606 | 4606 | { |
4607 | - case 0: //path | |
4607 | + case 0: // path | |
4608 | 4608 | lstrcpyn(pItem->pszText, static_cast<LPCWSTR>(m_currentChangedArray.GetCount() > 0 ? m_currentChangedArray[pItem->iItem].GetPath() : m_currentChangedPathList[pItem->iItem].GetSVNPathString()), pItem->cchTextMax - 1); |
4609 | 4609 | break; |
4610 | 4610 | |
4611 | - case 1: //Action | |
4611 | + case 1: // Action | |
4612 | 4612 | lstrcpyn(pItem->pszText, m_bSingleRevision && m_currentChangedArray.GetCount() > static_cast<size_t>(pItem->iItem) ? static_cast<LPCWSTR>(CUnicodeUtils::GetUnicode(m_currentChangedArray[pItem->iItem].GetActionString().c_str())) : L"", pItem->cchTextMax - 1); |
4613 | 4613 | break; |
4614 | 4614 | |
4615 | - case 2: //copyfrom path | |
4615 | + case 2: // copyfrom path | |
4616 | 4616 | lstrcpyn(pItem->pszText, m_bSingleRevision && m_currentChangedArray.GetCount() > static_cast<size_t>(pItem->iItem) ? static_cast<LPCWSTR>(m_currentChangedArray[pItem->iItem].GetCopyFromPath()) : L"", pItem->cchTextMax - 1); |
4617 | 4617 | break; |
4618 | 4618 | |
4619 | - case 3: //revision | |
4619 | + case 3: // revision | |
4620 | 4620 | svn_revnum_t revision = 0; |
4621 | 4621 | if (m_bSingleRevision && m_currentChangedArray.GetCount() > static_cast<size_t>(pItem->iItem)) |
4622 | 4622 | revision = m_currentChangedArray[pItem->iItem].GetCopyFromRev(); |
@@ -4849,7 +4849,7 @@ | ||
4849 | 4849 | if (pLogEntry) |
4850 | 4850 | { |
4851 | 4851 | CString sRevMsg; |
4852 | - sRevMsg.FormatMessage(m_sMultiLogFormat, //L"r%1!ld!\n%2!s!\n---------------------\n", | |
4852 | + sRevMsg.FormatMessage(m_sMultiLogFormat, // L"r%1!ld!\n%2!s!\n---------------------\n", | |
4853 | 4853 | pLogEntry->GetRevision(), |
4854 | 4854 | static_cast<LPCWSTR>(pLogEntry->GetShortMessageUTF16())); |
4855 | 4855 | sMessageSketch += sRevMsg; |
@@ -4856,9 +4856,9 @@ | ||
4856 | 4856 | const CLogChangedPathArray& cPathArray = pLogEntry->GetChangedPaths(); |
4857 | 4857 | for (size_t cpPathIndex = 0; cpPathIndex < cPathArray.GetCount(); ++cpPathIndex) |
4858 | 4858 | { |
4859 | - const CLogChangedPath& cPath = cPathArray[cpPathIndex]; | |
4859 | + const CLogChangedPath& cPath = cPathArray[cpPathIndex]; | |
4860 | 4860 | |
4861 | - LogCache::index_t pathID = cPath.GetCachedPath().GetIndex(); | |
4861 | + LogCache::index_t pathID = cPath.GetCachedPath().GetIndex(); | |
4862 | 4862 | if (pathIDsAdded.contains(pathID)) |
4863 | 4863 | continue; |
4864 | 4864 |
@@ -4903,7 +4903,7 @@ | ||
4903 | 4903 | void CLogDlg::OnLvnColumnclick(NMHDR* pNMHDR, LRESULT* pResult) |
4904 | 4904 | { |
4905 | 4905 | if ((m_bLogThreadRunning) || (m_logList.HasText())) |
4906 | - return; //no sorting while the arrays are filled | |
4906 | + return; // no sorting while the arrays are filled | |
4907 | 4907 | LPNMLISTVIEW pNMLV = reinterpret_cast<LPNMLISTVIEW>(pNMHDR); |
4908 | 4908 | const int nColumn = pNMLV->iSubItem; |
4909 | 4909 | m_bAscending = nColumn == m_nSortColumn ? !m_bAscending : TRUE; |
@@ -4956,7 +4956,7 @@ | ||
4956 | 4956 | void CLogDlg::OnLvnColumnclickChangedFileList(NMHDR* pNMHDR, LRESULT* pResult) |
4957 | 4957 | { |
4958 | 4958 | if ((m_bLogThreadRunning) || (m_logList.HasText())) |
4959 | - return; //no sorting while the arrays are filled | |
4959 | + return; // no sorting while the arrays are filled | |
4960 | 4960 | |
4961 | 4961 | LPNMLISTVIEW pNMLV = reinterpret_cast<LPNMLISTVIEW>(pNMHDR); |
4962 | 4962 | const int nColumn = pNMLV->iSubItem; |
@@ -5200,7 +5200,7 @@ | ||
5200 | 5200 | { |
5201 | 5201 | m_endRev = 0; |
5202 | 5202 | |
5203 | - m_limit = 0; | |
5203 | + m_limit = 0; | |
5204 | 5204 | Refresh(); |
5205 | 5205 | } |
5206 | 5206 |
@@ -5277,8 +5277,8 @@ | ||
5277 | 5277 | pCmi->selLogEntry = m_logEntries.GetVisible(indexNext); |
5278 | 5278 | if (pCmi->selLogEntry == nullptr) |
5279 | 5279 | return false; |
5280 | - pCmi->revSelected = pCmi->selLogEntry->GetRevision(); | |
5281 | - pCmi->revPrevious = static_cast<svn_revnum_t>(pCmi->revSelected) - 1; | |
5280 | + pCmi->revSelected = pCmi->selLogEntry->GetRevision(); | |
5281 | + pCmi->revPrevious = static_cast<svn_revnum_t>(pCmi->revSelected) - 1; | |
5282 | 5282 | |
5283 | 5283 | const CLogChangedPathArray& paths = pCmi->selLogEntry->GetChangedPaths(); |
5284 | 5284 | if (paths.GetCount() <= 2) |
@@ -5761,7 +5761,7 @@ | ||
5761 | 5761 | if (pCmi->pathURL.IsEmpty()) |
5762 | 5762 | { |
5763 | 5763 | ReportNoUrlOfFile(m_path.GetUIPathString()); |
5764 | - return; //exit | |
5764 | + return; // exit | |
5765 | 5765 | } |
5766 | 5766 | |
5767 | 5767 | if (ConfirmRevert(m_path.GetUIPathString())) |
@@ -5785,7 +5785,7 @@ | ||
5785 | 5785 | if (pCmi->pathURL.IsEmpty()) |
5786 | 5786 | { |
5787 | 5787 | ReportNoUrlOfFile(m_path.GetUIPathString()); |
5788 | - return; //exit | |
5788 | + return; // exit | |
5789 | 5789 | } |
5790 | 5790 | |
5791 | 5791 | CString path = m_path.GetWinPathString(); |
@@ -5832,7 +5832,7 @@ | ||
5832 | 5832 | } |
5833 | 5833 | CSVNProgressDlg dlg; |
5834 | 5834 | dlg.SetCommand(CSVNProgressDlg::SVNProgress_Merge); |
5835 | - dlg.SetOptions(ProgOptIgnoreAncestry | ProgOptAllowMixedRev); | |
5835 | + dlg.SetOptions(ProgOptAllowMixedRev); | |
5836 | 5836 | dlg.SetPathList(CTSVNPathList(CTSVNPath(path))); |
5837 | 5837 | dlg.SetUrl(pCmi->pathURL); |
5838 | 5838 | dlg.SetSecondUrl(pCmi->pathURL); |
@@ -5849,7 +5849,7 @@ | ||
5849 | 5849 | if (pCmi->pathURL.IsEmpty()) |
5850 | 5850 | { |
5851 | 5851 | ReportNoUrlOfFile(m_path.GetUIPathString()); |
5852 | - return; //exit | |
5852 | + return; // exit | |
5853 | 5853 | } |
5854 | 5854 | |
5855 | 5855 | if (ConfirmRevert(m_path.GetWinPath(), true)) |
@@ -5874,7 +5874,7 @@ | ||
5874 | 5874 | if (pCmi->pathURL.IsEmpty()) |
5875 | 5875 | { |
5876 | 5876 | ReportNoUrlOfFile(m_path.GetUIPathString()); |
5877 | - return; //exit | |
5877 | + return; // exit | |
5878 | 5878 | } |
5879 | 5879 | |
5880 | 5880 | CCopyDlg dlg; |
@@ -5909,7 +5909,7 @@ | ||
5909 | 5909 | |
5910 | 5910 | void CLogDlg::ExecuteCompareWithWorkingCopyMenuRevisions(std::shared_ptr<CContextMenuInfoForRevisions>& pCmi) |
5911 | 5911 | { |
5912 | - //user clicked on the menu item "compare with working copy" | |
5912 | + // user clicked on the menu item "compare with working copy" | |
5913 | 5913 | if (PromptShown()) |
5914 | 5914 | { |
5915 | 5915 | auto f = [=]() { |
@@ -5947,7 +5947,7 @@ | ||
5947 | 5947 | { |
5948 | 5948 | nodeKind = m_path.IsDirectory() ? svn_node_dir : svn_node_file; |
5949 | 5949 | } |
5950 | - //user clicked on the menu item "compare revisions" | |
5950 | + // user clicked on the menu item "compare revisions" | |
5951 | 5951 | if (PromptShown()) |
5952 | 5952 | { |
5953 | 5953 | auto f = [=]() { |
@@ -6005,8 +6005,8 @@ | ||
6005 | 6005 | |
6006 | 6006 | void CLogDlg::ExecuteBlameCompareMenuRevisions(std::shared_ptr<CContextMenuInfoForRevisions>& pCmi) |
6007 | 6007 | { |
6008 | - //user clicked on the menu item "compare with working copy" | |
6009 | - //now first get the revision which is selected | |
6008 | + // user clicked on the menu item "compare with working copy" | |
6009 | + // now first get the revision which is selected | |
6010 | 6010 | if (PromptShown()) |
6011 | 6011 | { |
6012 | 6012 | auto f = [=]() { |
@@ -6030,7 +6030,7 @@ | ||
6030 | 6030 | |
6031 | 6031 | void CLogDlg::ExecuteBlameTwoMenuRevisions(std::shared_ptr<CContextMenuInfoForRevisions>& pCmi) |
6032 | 6032 | { |
6033 | - //user clicked on the menu item "compare and blame revisions" | |
6033 | + // user clicked on the menu item "compare and blame revisions" | |
6034 | 6034 | svn_node_kind_t nodekind = svn_node_unknown; |
6035 | 6035 | if (!m_path.IsUrl()) |
6036 | 6036 | { |
@@ -6062,7 +6062,7 @@ | ||
6062 | 6062 | |
6063 | 6063 | void CLogDlg::ExecuteWithPreviousMenuRevisions(std::shared_ptr<CContextMenuInfoForRevisions>& pCmi) |
6064 | 6064 | { |
6065 | - //user clicked on the menu item "Compare and Blame with previous revision" | |
6065 | + // user clicked on the menu item "Compare and Blame with previous revision" | |
6066 | 6066 | svn_node_kind_t nodekind = svn_node_unknown; |
6067 | 6067 | if (!m_path.IsUrl()) |
6068 | 6068 | { |
@@ -6093,7 +6093,7 @@ | ||
6093 | 6093 | |
6094 | 6094 | void CLogDlg::ExecuteSaveAsMenuRevisions(std::shared_ptr<CContextMenuInfoForRevisions>& pCmi) |
6095 | 6095 | { |
6096 | - //now first get the revision which is selected | |
6096 | + // now first get the revision which is selected | |
6097 | 6097 | CString revFilename; |
6098 | 6098 | CString strWinPath = CPathUtils::GetFileNameFromPath(pCmi->pathURL); |
6099 | 6099 | strWinPath = CPathUtils::PathUnescape(strWinPath); |
@@ -6194,7 +6194,7 @@ | ||
6194 | 6194 | bool textViewer = !!dlg.m_bTextView; |
6195 | 6195 | CString options = SVN::GetOptionsString(!!dlg.m_bIgnoreEOL, dlg.m_ignoreSpaces); |
6196 | 6196 | |
6197 | - auto f = [=]() { | |
6197 | + auto f = [=]() { | |
6198 | 6198 | CoInitialize(nullptr); |
6199 | 6199 | OnOutOfScope(CoUninitialize()); |
6200 | 6200 | this->EnableWindow(FALSE); |
@@ -6202,12 +6202,12 @@ | ||
6202 | 6202 | |
6203 | 6203 | CBlame blame; |
6204 | 6204 | CString tempFile = blame.BlameToTempFile(m_path, startRev, endRev, m_pegRev, |
6205 | - options, includeMerge, TRUE, TRUE); | |
6205 | + options, includeMerge, TRUE, TRUE); | |
6206 | 6206 | if (!tempFile.IsEmpty()) |
6207 | 6207 | { |
6208 | 6208 | if (textViewer) |
6209 | 6209 | { |
6210 | - //open the default text editor for the result file | |
6210 | + // open the default text editor for the result file | |
6211 | 6211 | CAppUtils::StartTextViewer(tempFile); |
6212 | 6212 | } |
6213 | 6213 | else |
@@ -6214,11 +6214,11 @@ | ||
6214 | 6214 | { |
6215 | 6215 | CString sParams = L"/path:\"" + m_path.GetSVNPathString() + L"\" "; |
6216 | 6216 | CAppUtils::LaunchTortoiseBlame(tempFile, |
6217 | - CPathUtils::GetFileNameFromPath(m_path.GetFileOrDirectoryName()), | |
6218 | - sParams, | |
6219 | - startRev, | |
6220 | - endRev, | |
6221 | - m_pegRev); | |
6217 | + CPathUtils::GetFileNameFromPath(m_path.GetFileOrDirectoryName()), | |
6218 | + sParams, | |
6219 | + startRev, | |
6220 | + endRev, | |
6221 | + m_pegRev); | |
6222 | 6222 | } |
6223 | 6223 | } |
6224 | 6224 | else |
@@ -6339,16 +6339,16 @@ | ||
6339 | 6339 | // need this shortcut that can't easily go into the helper class |
6340 | 6340 | const CLogChangedPath& changedLogPath = m_currentChangedArray[selIndex]; |
6341 | 6341 | |
6342 | - //entry is selected, now show the popup menu | |
6343 | - CIconMenu popup; | |
6344 | - CIconMenu clipSubMenu; | |
6342 | + // entry is selected, now show the popup menu | |
6343 | + CIconMenu popup; | |
6344 | + CIconMenu clipSubMenu; | |
6345 | 6345 | if (!clipSubMenu.CreatePopupMenu()) |
6346 | 6346 | return; |
6347 | 6347 | |
6348 | 6348 | PopulateContextMenuForChangedPaths(pCmi, popup, clipSubMenu); |
6349 | 6349 | int cmd = popup.TrackPopupMenu(TPM_RETURNCMD | TPM_LEFTALIGN | TPM_NONOTIFY | |
6350 | - TPM_RIGHTBUTTON, | |
6351 | - point.x, point.y, this, nullptr); | |
6350 | + TPM_RIGHTBUTTON, | |
6351 | + point.x, point.y, this, nullptr); | |
6352 | 6352 | CLogWndHourglass wait; |
6353 | 6353 | |
6354 | 6354 | switch (cmd) |
@@ -6476,7 +6476,7 @@ | ||
6476 | 6476 | GetDlgItem(IDC_LOGINFO)->GetWindowRect(rcBottomLimit); |
6477 | 6477 | ScreenToClient(rcBottomLimit); |
6478 | 6478 | |
6479 | - auto minCtrlHeight = MIN_CTRL_HEIGHT; | |
6479 | + auto minCtrlHeight = MIN_CTRL_HEIGHT; | |
6480 | 6480 | |
6481 | 6481 | // the IDC_LOGINFO and the changed file list control |
6482 | 6482 | // have a space of 3 dlg units between them (check in the dlg resource editor) |
@@ -6644,7 +6644,7 @@ | ||
6644 | 6644 | |
6645 | 6645 | // Draw the icon(s) into the compatible DC |
6646 | 6646 | |
6647 | - DWORD actions = pLogEntry->GetChangedPaths().GetActions(); | |
6647 | + DWORD actions = pLogEntry->GetChangedPaths().GetActions(); | |
6648 | 6648 | |
6649 | 6649 | std::string actionText; |
6650 | 6650 | if (actions & LOGACTIONS_MODIFIED) |
@@ -6924,7 +6924,7 @@ | ||
6924 | 6924 | entry.dwSize = sizeof(PROCESSENTRY32); |
6925 | 6925 | m_bVisualStudioRunningAtStart = false; |
6926 | 6926 | |
6927 | - CAutoGeneralHandle snapShot = CreateToolhelp32Snapshot(TH32CS_SNAPPROCESS, NULL); | |
6927 | + CAutoGeneralHandle snapShot = CreateToolhelp32Snapshot(TH32CS_SNAPPROCESS, NULL); | |
6928 | 6928 | |
6929 | 6929 | if (Process32First(snapShot, &entry)) |
6930 | 6930 | { |
@@ -7030,12 +7030,12 @@ | ||
7030 | 7030 | |
7031 | 7031 | CString CLogDlg::GetWcPathFromUrl(CString url) |
7032 | 7032 | { |
7033 | - CString fileUrl = GetRepositoryRoot(m_path) + url.Trim(); | |
7033 | + CString fileUrl = GetRepositoryRoot(m_path) + url.Trim(); | |
7034 | 7034 | // firstfile = (e.g.) http://mydomain.com/repos/trunk/folder/file1 |
7035 | 7035 | // sUrl = http://mydomain.com/repos/trunk/folder |
7036 | 7036 | CString sUnescapedUrl = CPathUtils::PathUnescape(GetSUrl()); |
7037 | 7037 | // find out until which char the urls are identical |
7038 | - int j = 0; | |
7038 | + int j = 0; | |
7039 | 7039 | while ((j < fileUrl.GetLength()) && (j < sUnescapedUrl.GetLength()) && (fileUrl[j] == sUnescapedUrl[j])) |
7040 | 7040 | { |
7041 | 7041 | j++; |
@@ -7069,7 +7069,7 @@ | ||
7069 | 7069 | _bstr_t bstrFileName(filename); |
7070 | 7070 | |
7071 | 7071 | // ok, open one file in VS |
7072 | - HRESULT result = pItemOperations->OpenFile(bstrFileName, bstrKind, &pWindow); | |
7072 | + HRESULT result = pItemOperations->OpenFile(bstrFileName, bstrKind, &pWindow); | |
7073 | 7073 | if (FAILED(result)) |
7074 | 7074 | return false; |
7075 | 7075 | return true; |
@@ -7204,8 +7204,8 @@ | ||
7204 | 7204 | |
7205 | 7205 | bool CLogDlg::GetContextMenuInfoForChangedPaths(ContextMenuInfoForChangedPathsPtr& pCmi) |
7206 | 7206 | { |
7207 | - POSITION pos = m_logList.GetFirstSelectedItemPosition(); | |
7208 | - INT_PTR selIndex = m_changedFileListCtrl.GetSelectionMark(); | |
7207 | + POSITION pos = m_logList.GetFirstSelectedItemPosition(); | |
7208 | + INT_PTR selIndex = m_changedFileListCtrl.GetSelectionMark(); | |
7209 | 7209 | |
7210 | 7210 | PLOGENTRYDATA pLogEntry = m_logEntries.GetVisible(m_logList.GetNextSelectedItem(pos)); |
7211 | 7211 | if (pLogEntry == nullptr) |
@@ -7244,7 +7244,7 @@ | ||
7244 | 7244 | { |
7245 | 7245 | // only one revision is selected in the log dialog top pane |
7246 | 7246 | // but multiple items could be selected in the changed items list |
7247 | - pCmi->rev2 = pCmi->rev1 - 1; | |
7247 | + pCmi->rev2 = pCmi->rev1 - 1; | |
7248 | 7248 | |
7249 | 7249 | POSITION pos2 = m_changedFileListCtrl.GetFirstSelectedItemPosition(); |
7250 | 7250 | while (pos2) |
@@ -7251,7 +7251,7 @@ | ||
7251 | 7251 | { |
7252 | 7252 | const CLogChangedPathArray& paths = pLogEntry->GetChangedPaths(); |
7253 | 7253 | |
7254 | - int nItem = m_changedFileListCtrl.GetNextSelectedItem(pos2); | |
7254 | + int nItem = m_changedFileListCtrl.GetNextSelectedItem(pos2); | |
7255 | 7255 | pCmi->changedLogPathIndices.push_back(static_cast<size_t>(nItem)); |
7256 | 7256 | if ((m_cShowPaths.GetState() & 0x0003) == BST_CHECKED) |
7257 | 7257 | { |
@@ -7295,7 +7295,7 @@ | ||
7295 | 7295 | } |
7296 | 7296 | } |
7297 | 7297 | |
7298 | - pCmi->sUrl = GetSUrl(); | |
7298 | + pCmi->sUrl = GetSUrl(); | |
7299 | 7299 | |
7300 | 7300 | // find the working copy path of the selected item from the URL |
7301 | 7301 | CString sUrlRoot = GetRepositoryRoot(m_path); |
@@ -7488,13 +7488,13 @@ | ||
7488 | 7488 | |
7489 | 7489 | DialogEnableWindow(IDOK, FALSE); |
7490 | 7490 | SetPromptApp(&theApp); |
7491 | - CTSVNPath tsvnfilepath = CTSVNPath(pCmi->fileUrl); | |
7491 | + CTSVNPath tsvnfilepath = CTSVNPath(pCmi->fileUrl); | |
7492 | 7492 | |
7493 | 7493 | CProgressDlg progDlg; |
7494 | 7494 | progDlg.SetTitle(IDS_APPNAME); |
7495 | 7495 | CString sInfoLine; |
7496 | 7496 | sInfoLine.FormatMessage(IDS_PROGRESSGETFILEREVISION, static_cast<LPCWSTR>(pCmi->fileUrl), |
7497 | - static_cast<LPCWSTR>(getRev.ToString())); | |
7497 | + static_cast<LPCWSTR>(getRev.ToString())); | |
7498 | 7498 | progDlg.SetLine(1, sInfoLine, true); |
7499 | 7499 | SetAndClearProgressInfo(&progDlg); |
7500 | 7500 | progDlg.ShowModeless(m_hWnd); |
@@ -7521,8 +7521,8 @@ | ||
7521 | 7521 | CAppUtils::GetMimeType(tsvnfilepath, mimetype); |
7522 | 7522 | |
7523 | 7523 | CAppUtils::StartExtDiff(tempFile, CTSVNPath(pCmi->wcPath), sName1, sName2, tsvnfilepath, tsvnfilepath, |
7524 | - getRev, getRev, getRev, flags, 0, | |
7525 | - CPathUtils::GetFileNameFromPath(pCmi->fileUrl), mimetype); | |
7524 | + getRev, getRev, getRev, flags, 0, | |
7525 | + CPathUtils::GetFileNameFromPath(pCmi->fileUrl), mimetype); | |
7526 | 7526 | EnableOKButton(); |
7527 | 7527 | }; |
7528 | 7528 | new async::CAsyncCall(f, &netScheduler); |
@@ -7610,7 +7610,7 @@ | ||
7610 | 7610 | // tell the user how to work around this. |
7611 | 7611 | TaskDialog(GetSafeHwnd(), AfxGetResourceHandle(), MAKEINTRESOURCE(IDS_APPNAME), MAKEINTRESOURCE(IDS_ERR_ERROROCCURED), MAKEINTRESOURCE(IDS_LOG_REVERTREV_ERROR), TDCBF_OK_BUTTON, TD_ERROR_ICON, nullptr); |
7612 | 7612 | EnableOKButton(); |
7613 | - return; //exit | |
7613 | + return; // exit | |
7614 | 7614 | } |
7615 | 7615 | dlg.SetCommand(CSVNProgressDlg::SVNProgress_Merge); |
7616 | 7616 | dlg.SetOptions(ProgOptIgnoreAncestry | ProgOptAllowMixedRev); |
@@ -7654,12 +7654,12 @@ | ||
7654 | 7654 | ReportNoUrlOfFile(m_path.GetWinPath()); |
7655 | 7655 | return; |
7656 | 7656 | } |
7657 | - m_bCancelled = false; | |
7658 | - CString sRoot = GetRepositoryRoot(CTSVNPath(pCmi->fileUrl)); | |
7659 | - CString sUrlRootUnescaped = CPathUtils::PathUnescape(sRoot); | |
7657 | + m_bCancelled = false; | |
7658 | + CString sRoot = GetRepositoryRoot(CTSVNPath(pCmi->fileUrl)); | |
7659 | + CString sUrlRootUnescaped = CPathUtils::PathUnescape(sRoot); | |
7660 | 7660 | // if more than one entry is selected, we save them |
7661 | 7661 | // one by one into a folder the user has selected |
7662 | - bool bTargetSelected = false; | |
7662 | + bool bTargetSelected = false; | |
7663 | 7663 | CTSVNPath targetPath; |
7664 | 7664 | if (m_changedFileListCtrl.GetSelectedCount() > 1) |
7665 | 7665 | { |
@@ -7702,9 +7702,9 @@ | ||
7702 | 7702 | { |
7703 | 7703 | const CLogChangedPath& changedLogPathI = m_currentChangedArray[pCmi->changedLogPathIndices[i]]; |
7704 | 7704 | |
7705 | - SVNRev getrev = (changedLogPathI.GetAction() == LOGACTIONS_DELETED) ? pCmi->rev2 : pCmi->rev1; | |
7705 | + SVNRev getrev = (changedLogPathI.GetAction() == LOGACTIONS_DELETED) ? pCmi->rev2 : pCmi->rev1; | |
7706 | 7706 | |
7707 | - CString sInfoLine; | |
7707 | + CString sInfoLine; | |
7708 | 7708 | sInfoLine.FormatMessage(IDS_PROGRESSGETFILEREVISION, |
7709 | 7709 | static_cast<LPCWSTR>(CPathUtils::GetFileNameFromPath(changedLogPathI.GetPath())), |
7710 | 7710 | static_cast<LPCWSTR>(getrev.ToString())); |
@@ -7747,7 +7747,7 @@ | ||
7747 | 7747 | { |
7748 | 7748 | DialogEnableWindow(IDOK, FALSE); |
7749 | 7749 | SetPromptApp(&theApp); |
7750 | - m_bCancelled = false; | |
7750 | + m_bCancelled = false; | |
7751 | 7751 | |
7752 | 7752 | bool bTargetSelected = false; |
7753 | 7753 | CTSVNPath targetPath; |
@@ -7782,9 +7782,9 @@ | ||
7782 | 7782 | |
7783 | 7783 | const CString& schangedlogpath = m_currentChangedArray[pCmi->changedLogPathIndices[i]].GetPath(); |
7784 | 7784 | |
7785 | - SVNRev getRev = pCmi->rev1; | |
7785 | + SVNRev getRev = pCmi->rev1; | |
7786 | 7786 | |
7787 | - CTSVNPath tempFile = targetPath; | |
7787 | + CTSVNPath tempFile = targetPath; | |
7788 | 7788 | tempFile.AppendPathString(schangedlogpath); |
7789 | 7789 | |
7790 | 7790 | CString sInfoLine; |
@@ -7857,12 +7857,12 @@ | ||
7857 | 7857 | OnOutOfScope(this->EnableWindow(TRUE); this->SetFocus()); |
7858 | 7858 | CBlame blame; |
7859 | 7859 | CString tempFile = blame.BlameToTempFile(CTSVNPath(pCmi->fileUrl), startRev, |
7860 | - endRev, pegRev, options, includeMerge, TRUE, TRUE); | |
7860 | + endRev, pegRev, options, includeMerge, TRUE, TRUE); | |
7861 | 7861 | if (!tempFile.IsEmpty()) |
7862 | 7862 | { |
7863 | 7863 | if (textView) |
7864 | 7864 | { |
7865 | - //open the default text editor for the result file | |
7865 | + // open the default text editor for the result file | |
7866 | 7866 | CAppUtils::StartTextViewer(tempFile); |
7867 | 7867 | } |
7868 | 7868 | else |
@@ -7869,11 +7869,11 @@ | ||
7869 | 7869 | { |
7870 | 7870 | CString sParams = L"/path:\"" + pCmi->fileUrl + L"\" "; |
7871 | 7871 | CAppUtils::LaunchTortoiseBlame(tempFile, |
7872 | - CPathUtils::GetFileNameFromPath(pCmi->fileUrl), | |
7873 | - sParams, | |
7874 | - startRev, | |
7875 | - endRev, | |
7876 | - pegRev); | |
7872 | + CPathUtils::GetFileNameFromPath(pCmi->fileUrl), | |
7873 | + sParams, | |
7874 | + startRev, | |
7875 | + endRev, | |
7876 | + pegRev); | |
7877 | 7877 | } |
7878 | 7878 | } |
7879 | 7879 | else |
@@ -7989,14 +7989,14 @@ | ||
7989 | 7989 | |
7990 | 7990 | void CLogDlg::CopyChangedPathInfoToClipboard(ContextMenuInfoForChangedPathsPtr pCmi, int cmd) const |
7991 | 7991 | { |
7992 | - int nPaths = static_cast<int>(pCmi->changedLogPathIndices.size()); | |
7992 | + int nPaths = static_cast<int>(pCmi->changedLogPathIndices.size()); | |
7993 | 7993 | |
7994 | 7994 | CString sClipboard; |
7995 | 7995 | for (int i = 0; i < nPaths; ++i) |
7996 | 7996 | { |
7997 | - INT_PTR selIndex = static_cast<INT_PTR>(pCmi->changedLogPathIndices[i]); | |
7997 | + INT_PTR selIndex = static_cast<INT_PTR>(pCmi->changedLogPathIndices[i]); | |
7998 | 7998 | |
7999 | - CLogChangedPath path = m_currentChangedArray[selIndex]; | |
7999 | + CLogChangedPath path = m_currentChangedArray[selIndex]; | |
8000 | 8000 | switch (cmd) |
8001 | 8001 | { |
8002 | 8002 | case ID_COPYCLIPBOARDURL: |
@@ -8079,14 +8079,14 @@ | ||
8079 | 8079 | ::SendMessage(m_hwndToolbar, TB_BUTTONSTRUCTSIZE, static_cast<WPARAM>(sizeof(TBBUTTON)), 0); |
8080 | 8080 | |
8081 | 8081 | #define MONITORMODE_TOOLBARBUTTONCOUNT 11 |
8082 | - TBBUTTON tbb[MONITORMODE_TOOLBARBUTTONCOUNT] = {0}; | |
8082 | + TBBUTTON tbb[MONITORMODE_TOOLBARBUTTONCOUNT] = {0}; | |
8083 | 8083 | // create an image list containing the icons for the toolbar |
8084 | - const int iconSizeX = static_cast<int>(24 * CDPIAware::Instance().ScaleFactor(GetSafeHwnd())); | |
8085 | - const int iconSizeY = static_cast<int>(24 * CDPIAware::Instance().ScaleFactor(GetSafeHwnd())); | |
8084 | + const int iconSizeX = static_cast<int>(24 * CDPIAware::Instance().ScaleFactor(GetSafeHwnd())); | |
8085 | + const int iconSizeY = static_cast<int>(24 * CDPIAware::Instance().ScaleFactor(GetSafeHwnd())); | |
8086 | 8086 | if (!m_toolbarImages.Create(iconSizeX, iconSizeY, ILC_COLOR32 | ILC_MASK | ILC_HIGHQUALITYSCALE, MONITORMODE_TOOLBARBUTTONCOUNT, 4)) |
8087 | 8087 | return false; |
8088 | 8088 | auto iString = ::SendMessage(m_hwndToolbar, TB_ADDSTRING, |
8089 | - reinterpret_cast<WPARAM>(AfxGetResourceHandle()), static_cast<LPARAM>(IDS_MONITOR_TOOLBARTEXTS)); | |
8089 | + reinterpret_cast<WPARAM>(AfxGetResourceHandle()), static_cast<LPARAM>(IDS_MONITOR_TOOLBARTEXTS)); | |
8090 | 8090 | int index = 0; |
8091 | 8091 | HICON hIcon = CCommonAppUtils::LoadIconEx(IDI_MONITOR_GETALL, iconSizeX, iconSizeY); |
8092 | 8092 | tbb[index].iBitmap = m_toolbarImages.Add(hIcon); |
@@ -8228,12 +8228,12 @@ | ||
8228 | 8228 | hdwp = CSplitterControl::ChangeRect(hdwp, GetDlgItem(IDC_DATETO), 0, rect.Height(), 0, rect.Height()); |
8229 | 8229 | hdwp = CSplitterControl::ChangeRect(hdwp, &m_logList, delta, rect.Height(), 0, 0); |
8230 | 8230 | |
8231 | - hdwp = CSplitterControl::ChangeRect(hdwp, &m_wndSplitter1, delta, 0, 0, 0); | |
8232 | - hdwp = CSplitterControl::ChangeRect(hdwp, GetDlgItem(IDC_MSGVIEW), delta, 0, 0, 0); | |
8233 | - hdwp = CSplitterControl::ChangeRect(hdwp, &m_wndSplitter2, delta, 0, 0, 0); | |
8234 | - hdwp = CSplitterControl::ChangeRect(hdwp, &m_changedFileListCtrl, delta, 0, 0, 75); | |
8235 | - hdwp = CSplitterControl::ChangeRect(hdwp, &m_logProgress, delta, 20, -rcGetAll.Width(), 20); | |
8236 | - hdwp = CSplitterControl::ChangeRect(hdwp, GetDlgItem(IDC_LOGINFO), delta, 75, 0, 75); | |
8231 | + hdwp = CSplitterControl::ChangeRect(hdwp, &m_wndSplitter1, delta, 0, 0, 0); | |
8232 | + hdwp = CSplitterControl::ChangeRect(hdwp, GetDlgItem(IDC_MSGVIEW), delta, 0, 0, 0); | |
8233 | + hdwp = CSplitterControl::ChangeRect(hdwp, &m_wndSplitter2, delta, 0, 0, 0); | |
8234 | + hdwp = CSplitterControl::ChangeRect(hdwp, &m_changedFileListCtrl, delta, 0, 0, 75); | |
8235 | + hdwp = CSplitterControl::ChangeRect(hdwp, &m_logProgress, delta, 20, -rcGetAll.Width(), 20); | |
8236 | + hdwp = CSplitterControl::ChangeRect(hdwp, GetDlgItem(IDC_LOGINFO), delta, 75, 0, 75); | |
8237 | 8237 | EndDeferWindowPos(hdwp); |
8238 | 8238 | |
8239 | 8239 | DWORD exStyle = TVS_EX_AUTOHSCROLL | TVS_EX_DOUBLEBUFFER; |
@@ -8251,8 +8251,8 @@ | ||
8251 | 8251 | // Set up the tray icon |
8252 | 8252 | ChangeWindowMessageFilter(WM_TASKBARCREATED, MSGFLT_ADD); |
8253 | 8253 | |
8254 | - m_hMonitorIconNormal = CCommonAppUtils::LoadIconEx(IDI_MONITORNORMAL, 0, 0); | |
8255 | - m_hMonitorIconNewCommits = CCommonAppUtils::LoadIconEx(IDI_MONITORCOMMITS, 0, 0); | |
8254 | + m_hMonitorIconNormal = CCommonAppUtils::LoadIconEx(IDI_MONITORNORMAL, 0, 0); | |
8255 | + m_hMonitorIconNewCommits = CCommonAppUtils::LoadIconEx(IDI_MONITORCOMMITS, 0, 0); | |
8256 | 8256 | |
8257 | 8257 | m_systemTray.cbSize = sizeof(NOTIFYICONDATA); |
8258 | 8258 | m_systemTray.uVersion = NOTIFYICON_VERSION_4; |
@@ -8361,7 +8361,7 @@ | ||
8361 | 8361 | |
8362 | 8362 | void CLogDlg::RefreshMonitorProjTree() |
8363 | 8363 | { |
8364 | - static bool firstCall = true; | |
8364 | + static bool firstCall = true; | |
8365 | 8365 | |
8366 | 8366 | CSimpleIni::TNamesDepend mItems; |
8367 | 8367 | m_monitoringFile.GetAllSections(mItems); |
@@ -8752,7 +8752,7 @@ | ||
8752 | 8752 | pEditProject->userName = CStringUtils::Encrypt(dlg.m_sUsername); |
8753 | 8753 | pEditProject->password = CStringUtils::Encrypt(dlg.m_sPassword); |
8754 | 8754 | pEditProject->parentPath = dlg.m_isParentPath; |
8755 | - pEditProject->sMsgRegex = dlg.m_sIgnoreRegex; | |
8755 | + pEditProject->sMsgRegex = dlg.m_sIgnoreRegex; | |
8756 | 8756 | try |
8757 | 8757 | { |
8758 | 8758 | pEditProject->msgRegex = std::wregex(pEditProject->sMsgRegex, std::regex_constants::ECMAScript | std::regex_constants::icase); |
@@ -9035,7 +9035,7 @@ | ||
9035 | 9035 | // page from inside a repository |
9036 | 9036 | // some repositories show |
9037 | 9037 | // "<h2>projectname - Revision XX: /trunk</h2> |
9038 | - const char* reTitle = "<\\s*h2\\s*>[^/]+Revision\\s*\\d+:[^<]+<\\s*/\\s*h2\\s*>"; | |
9038 | + const char* reTitle = "<\\s*h2\\s*>[^/]+Revision\\s*\\d+:[^<]+<\\s*/\\s*h2\\s*>"; | |
9039 | 9039 | // xsl transformed pages don't have an easy way to determine |
9040 | 9040 | // the inside from outside of a repository. |
9041 | 9041 | // We therefore check for <index rev="0" to make sure it's either |
@@ -9049,8 +9049,8 @@ | ||
9049 | 9049 | continue; |
9050 | 9050 | } |
9051 | 9051 | |
9052 | - const char* re = "<\\s*LI\\s*>\\s*<\\s*A\\s+[^>]*HREF\\s*=\\s*\"([^\"]*)\"\\s*>([^<]+)<\\s*/\\s*A\\s*>\\s*<\\s*/\\s*LI\\s*>"; | |
9053 | - const char* re2 = "<\\s*DIR\\s*name\\s*=\\s*\"([^\"]*)\"\\s*HREF\\s*=\\s*\"([^\"]*)\"\\s*/\\s*>"; | |
9052 | + const char* re = "<\\s*LI\\s*>\\s*<\\s*A\\s+[^>]*HREF\\s*=\\s*\"([^\"]*)\"\\s*>([^<]+)<\\s*/\\s*A\\s*>\\s*<\\s*/\\s*LI\\s*>"; | |
9053 | + const char* re2 = "<\\s*DIR\\s*name\\s*=\\s*\"([^\"]*)\"\\s*HREF\\s*=\\s*\"([^\"]*)\"\\s*/\\s*>"; | |
9054 | 9054 | |
9055 | 9055 | const std::regex expression(re, std::regex_constants::icase | std::regex_constants::ECMAScript); |
9056 | 9056 | const std::regex expression2(re2, std::regex_constants::icase | std::regex_constants::ECMAScript); |
@@ -9064,17 +9064,17 @@ | ||
9064 | 9064 | // what[0] contains the whole string |
9065 | 9065 | // what[1] contains the url part. |
9066 | 9066 | // what[2] contains the name |
9067 | - auto url = CUnicodeUtils::GetUnicode(std::string(match[1]).c_str()); | |
9068 | - url = item.wcPathOrUrl + _T("/") + url; | |
9067 | + auto url = CUnicodeUtils::GetUnicode(std::string(match[1]).c_str()); | |
9068 | + url = item.wcPathOrUrl + _T("/") + url; | |
9069 | 9069 | |
9070 | 9070 | // we found a new URL, add it to our list |
9071 | - MonitorItem mi = item; | |
9072 | - mi.name = CPathUtils::PathUnescape(std::string(match[2]).c_str()).TrimRight('/'); | |
9073 | - mi.wcPathOrUrl = url; | |
9074 | - mi.authFailed = false; | |
9075 | - mi.parentPath = false; | |
9076 | - mi.lastChecked = 0; | |
9077 | - mi.lastCheckedRobots = 0; | |
9071 | + MonitorItem mi = item; | |
9072 | + mi.name = CPathUtils::PathUnescape(std::string(match[2]).c_str()).TrimRight('/'); | |
9073 | + mi.wcPathOrUrl = url; | |
9074 | + mi.authFailed = false; | |
9075 | + mi.parentPath = false; | |
9076 | + mi.lastChecked = 0; | |
9077 | + mi.lastCheckedRobots = 0; | |
9078 | 9078 | mi.lastErrorMsg.Empty(); |
9079 | 9079 | mi.lastHead = 0; |
9080 | 9080 | mi.unreadFirst = 0; |
@@ -9097,16 +9097,16 @@ | ||
9097 | 9097 | // what[0] contains the whole string |
9098 | 9098 | // what[1] contains the url part. |
9099 | 9099 | // what[2] contains the name |
9100 | - auto url = CUnicodeUtils::GetUnicode(std::string(match[1]).c_str()); | |
9101 | - url = item.wcPathOrUrl + _T("/") + url; | |
9100 | + auto url = CUnicodeUtils::GetUnicode(std::string(match[1]).c_str()); | |
9101 | + url = item.wcPathOrUrl + _T("/") + url; | |
9102 | 9102 | |
9103 | - MonitorItem mi = item; | |
9104 | - mi.name = CPathUtils::PathUnescape(std::string(match[2]).c_str()).TrimRight('/'); | |
9105 | - mi.wcPathOrUrl = url; | |
9106 | - mi.authFailed = false; | |
9107 | - mi.parentPath = false; | |
9108 | - mi.lastChecked = 0; | |
9109 | - mi.lastCheckedRobots = 0; | |
9103 | + MonitorItem mi = item; | |
9104 | + mi.name = CPathUtils::PathUnescape(std::string(match[2]).c_str()).TrimRight('/'); | |
9105 | + mi.wcPathOrUrl = url; | |
9106 | + mi.authFailed = false; | |
9107 | + mi.parentPath = false; | |
9108 | + mi.lastChecked = 0; | |
9109 | + mi.lastCheckedRobots = 0; | |
9110 | 9110 | mi.lastErrorMsg.Empty(); |
9111 | 9111 | mi.lastHead = 0; |
9112 | 9112 | mi.unreadFirst = 0; |
@@ -9488,8 +9488,8 @@ | ||
9488 | 9488 | auto hItem = FindMonitorItem(mip.second.wcPathOrUrl); |
9489 | 9489 | if (hItem == nullptr) |
9490 | 9490 | { |
9491 | - auto item = new MonitorItem(); | |
9492 | - *item = mip.second; | |
9491 | + auto item = new MonitorItem(); | |
9492 | + *item = mip.second; | |
9493 | 9493 | |
9494 | 9494 | auto hParent = FindMonitorItem(mip.first); |
9495 | 9495 | if (hParent) |
@@ -9632,8 +9632,8 @@ | ||
9632 | 9632 | POINT pt; |
9633 | 9633 | GetCursorPos(&pt); |
9634 | 9634 | |
9635 | - HMENU hMenu = ::LoadMenu(AfxGetResourceHandle(), MAKEINTRESOURCE(IDR_MONITORTRAY)); | |
9636 | - hMenu = ::GetSubMenu(hMenu, 0); | |
9635 | + HMENU hMenu = ::LoadMenu(AfxGetResourceHandle(), MAKEINTRESOURCE(IDR_MONITORTRAY)); | |
9636 | + hMenu = ::GetSubMenu(hMenu, 0); | |
9637 | 9637 | |
9638 | 9638 | // set the default entry |
9639 | 9639 | MENUITEMINFO iinfo = {0}; |
@@ -9786,7 +9786,7 @@ | ||
9786 | 9786 | if (head == 0) |
9787 | 9787 | head = GetHEADRevision(CTSVNPath(pItem->wcPathOrUrl), false); |
9788 | 9788 | |
9789 | - m_limit = static_cast<int>(static_cast<DWORD>(CRegDWORD(L"Software\\TortoiseSVN\\NumberOfLogs", 100))) + 1; | |
9789 | + m_limit = static_cast<int>(static_cast<DWORD>(CRegDWORD(L"Software\\TortoiseSVN\\NumberOfLogs", 100))) + 1; | |
9790 | 9790 | |
9791 | 9791 | m_path = CTSVNPath(pItem->wcPathOrUrl); |
9792 | 9792 | m_pegRev = head; |
@@ -9886,7 +9886,7 @@ | ||
9886 | 9886 | { |
9887 | 9887 | LPNMTVDISPINFO pTVDispInfo = reinterpret_cast<LPNMTVDISPINFO>(pNMHDR); |
9888 | 9888 | |
9889 | - MonitorItem* pItem = reinterpret_cast<MonitorItem*>(m_projTree.GetItemData(pTVDispInfo->item.hItem)); | |
9889 | + MonitorItem* pItem = reinterpret_cast<MonitorItem*>(m_projTree.GetItemData(pTVDispInfo->item.hItem)); | |
9890 | 9890 | if (pItem && pTVDispInfo->item.pszText) |
9891 | 9891 | { |
9892 | 9892 | CString sName = pTVDispInfo->item.pszText; |
@@ -9970,7 +9970,7 @@ | ||
9970 | 9970 | } |
9971 | 9971 | } |
9972 | 9972 | int cmd = popup.TrackPopupMenu(TPM_RETURNCMD | TPM_LEFTALIGN | TPM_NONOTIFY | TPM_RIGHTBUTTON, |
9973 | - point.x, point.y, this, nullptr); | |
9973 | + point.x, point.y, this, nullptr); | |
9974 | 9974 | CLogWndHourglass wait; |
9975 | 9975 | |
9976 | 9976 | switch (cmd) |
@@ -10106,7 +10106,7 @@ | ||
10106 | 10106 | static CString sMarkAllAsReadTooltip(MAKEINTRESOURCE(IDS_MONITOR_MARKASREADTT)); |
10107 | 10107 | static CString sUpdateAllTooltip(MAKEINTRESOURCE(IDS_MONITOR_UPDATEALLTT)); |
10108 | 10108 | |
10109 | - LPNMHDR lpnmhdr = reinterpret_cast<LPNMHDR>(lParam); | |
10109 | + LPNMHDR lpnmhdr = reinterpret_cast<LPNMHDR>(lParam); | |
10110 | 10110 | if ((lpnmhdr->code == TBN_GETINFOTIP) && (lpnmhdr->hwndFrom == m_hwndToolbar)) |
10111 | 10111 | { |
10112 | 10112 | LPNMTBGETINFOTIP lptbgit = reinterpret_cast<LPNMTBGETINFOTIPW>(lParam); |