diff options
author | B. Stack <bgstack15@gmail.com> | 2023-02-25 13:21:45 +0000 |
---|---|---|
committer | B. Stack <bgstack15@gmail.com> | 2023-02-25 13:21:45 +0000 |
commit | ef6260e9dfabc92fb008b59d2c2a09cd49880e07 (patch) | |
tree | 4982d5e9fb7f9ce024a2ad4b7edd621d04d75ce8 /freefilesync/05_traditional_view.patch | |
parent | Merge branch 'scite-bump' into 'master' (diff) | |
parent | ffs rpm libcurl version for 38, rawhide (diff) | |
download | stackrpms-ef6260e9dfabc92fb008b59d2c2a09cd49880e07.tar.gz stackrpms-ef6260e9dfabc92fb008b59d2c2a09cd49880e07.tar.bz2 stackrpms-ef6260e9dfabc92fb008b59d2c2a09cd49880e07.zip |
Merge branch 'freefilesync-bump' into 'master'
Freefilesync 12.1
See merge request bgstack15/stackrpms!340
Diffstat (limited to 'freefilesync/05_traditional_view.patch')
-rw-r--r-- | freefilesync/05_traditional_view.patch | 158 |
1 files changed, 71 insertions, 87 deletions
diff --git a/freefilesync/05_traditional_view.patch b/freefilesync/05_traditional_view.patch index 2c7ab23..bea475f 100644 --- a/freefilesync/05_traditional_view.patch +++ b/freefilesync/05_traditional_view.patch @@ -1,22 +1,21 @@ -Version: 11.22 -Date: 2022-06-26 +Version: 12.0 +Date: 2023-01-23 Author: bgstack15@gmail.com Message: restore a traditional view to FreeFileSync, and disable "welcomeShownVersion" About dialog -diff -x '*.orig' -x '*.rej' -aur 11.3-0/FreeFileSync/Source/ui/file_grid.cpp 11.3-1/FreeFileSync/Source/ui/file_grid.cpp ---- 11.21-0/FreeFileSync/Source/ui/file_grid.cpp 2022-05-22 17:09:32.242809600 -0400 -+++ 11.21-1/FreeFileSync/Source/ui/file_grid.cpp 2022-05-22 20:23:04.015916689 -0400 -@@ -475,8 +475,10 @@ - case ItemPathFormat::name: - return utfTo<std::wstring>(fsObj->getItemName<side>()); - case ItemPathFormat::relative: -+ case ItemPathFormat::tradrel: - return utfTo<std::wstring>(fsObj->getRelativePath<side>()); - case ItemPathFormat::full: -+ case ItemPathFormat::traditional: - return AFS::getDisplayPath(fsObj->getAbstractPath<side>()); - } - assert(false); -@@ -529,8 +531,13 @@ +--- a/FreeFileSync/Source/ui/file_grid.cpp ++++ b/FreeFileSync/Source/ui/file_grid.cpp +@@ -473,8 +473,10 @@ private: + case ItemPathFormat::name: + return utfTo<std::wstring>(fsObj->getItemName<side>()); + case ItemPathFormat::relative: ++ case ItemPathFormat::tradrel: + return utfTo<std::wstring>(fsObj->getRelativePath<side>()); + case ItemPathFormat::full: ++ case ItemPathFormat::traditional: + return AFS::getDisplayPath(fsObj->getAbstractPath<side>()); + } + +@@ -534,8 +536,13 @@ private: else GridData::renderRowBackgound(dc, rect, row, true /*enabled*/, true /*selected*/, rowHover); @@ -31,7 +30,7 @@ diff -x '*.orig' -x '*.rej' -aur 11.3-0/FreeFileSync/Source/ui/file_grid.cpp 11. clearArea(dc, rectLine, row == pdi.groupLastRow - 1 /*last group item*/ ? getColorGridLine() : getDefaultBackgroundColorAlternating(pdi.groupIdx % 2 != 0)); } -@@ -636,6 +643,26 @@ +@@ -641,6 +648,26 @@ private: else //=> BaseFolderPair groupParentFolder = AFS::getDisplayPath(pdi.fsObj->base().getAbstractPath<side>()); break; @@ -58,7 +57,7 @@ diff -x '*.orig' -x '*.rej' -aur 11.3-0/FreeFileSync/Source/ui/file_grid.cpp 11. } //path components should follow the app layout direction and are NOT a single piece of text! -@@ -661,11 +688,38 @@ +@@ -666,11 +693,38 @@ private: int groupNameWidth = groupName.empty() ? 0 : (gapSize_ + iconSize + gapSize_ + getTextExtentBuffered(dc, groupName).x); const int groupNameMinWidth = groupName.empty() ? 0 : (gapSize_ + iconSize + gapSize_ + ellipsisWidth); @@ -74,7 +73,7 @@ diff -x '*.orig' -x '*.rej' -aur 11.3-0/FreeFileSync/Source/ui/file_grid.cpp 11. int groupItemsWidth = groupSepWidth + (drawFileIcons ? gapSize_ + iconSize : 0) + gapSize_ + groupItemNamesWidth; const int groupItemsMinWidth = groupSepWidth + (drawFileIcons ? gapSize_ + iconSize : 0) + gapSize_ + ellipsisWidth; -+ // start trad patch ++ // start trad patch + + // rearrange this one section + switch (itemPathFormat_) @@ -98,19 +97,19 @@ diff -x '*.orig' -x '*.rej' -aur 11.3-0/FreeFileSync/Source/ui/file_grid.cpp 11. //not enough space? => collapse if (int excessWidth = groupParentWidth + groupNameWidth + groupItemsWidth - maxWidth; excessWidth > 0) -@@ -731,6 +785,11 @@ - } +@@ -737,6 +791,11 @@ private: } } -+ + + // end of original section, and back to the trad patch! + break; + } + // and end the addition for trad patch - ++ return { -@@ -851,6 +910,9 @@ + itemName, +@@ -877,6 +936,9 @@ private: rectGroup = rectGroupParent = rectGroupName = rectTmp; rectGroupParent.width = groupParentWidth; @@ -120,7 +119,7 @@ diff -x '*.orig' -x '*.rej' -aur 11.3-0/FreeFileSync/Source/ui/file_grid.cpp 11. rectGroupName .width = groupNameWidth; if (stackedGroupRender) -@@ -874,6 +936,11 @@ +@@ -900,6 +962,11 @@ private: rectGroupItems.width = 0; } @@ -132,33 +131,37 @@ diff -x '*.orig' -x '*.rej' -aur 11.3-0/FreeFileSync/Source/ui/file_grid.cpp 11. //------------------------------------------------------------------------- { //clear background below parent path => harmonize with renderRowBackgound() -@@ -884,8 +951,8 @@ +@@ -910,8 +977,9 @@ private: wxRect rectGroupBack = rectGroup; rectGroupBack.width += 2 * gapSize_; //include gap before vline - if (row == pdi.groupLastRow - 1 /*last group item*/) //preserve the group separation line! - rectGroupBack.height -= fastFromDIP(1); + if (row == pdi.groupLastRow - 1 /*last group item*/) //preserve the group separation line! ++ if (itemPathFormat_ != ItemPathFormat::traditional && itemPathFormat_ != ItemPathFormat::tradrel) + rectGroupBack.height -= lineWidth; clearArea(dc, rectGroupBack, getDefaultBackgroundColorAlternating(pdi.groupIdx % 2 == 0)); //clearArea() is surprisingly expensive => call just once! -@@ -900,7 +967,8 @@ - rectNav.width = fastFromDIP(20); - - if (row == pdi.groupLastRow - 1 /*last group item*/) //preserve the group separation line! -- rectNav.height -= fastFromDIP(1); -+ if (itemPathFormat_ != ItemPathFormat::traditional && itemPathFormat_ != ItemPathFormat::tradrel) -+ rectNav.height -= lineWidth; +@@ -919,9 +987,9 @@ private: + //accessibility: always set *both* foreground AND background colors! + } - wxColor backCol = wxSystemSettings::GetColour(wxSYS_COLOUR_WINDOW); - dc.GetPixel(rectNav.GetTopRight(), &backCol); //e.g. selected row! -@@ -908,13 +976,13 @@ - dc.GradientFillLinear(rectNav, getColorSelectionGradientFrom(), backCol, wxEAST); - } +- if (!groupParentFolder.empty() && ++ if (itemPathFormat_ == ItemPathFormat::traditional || itemPathFormat_ == ItemPathFormat::tradrel || (!groupParentFolder.empty() && + (( stackedGroupRender && row == groupFirstRow + 1) || +- (!stackedGroupRender && row == groupFirstRow)) && ++ (!stackedGroupRender && row == groupFirstRow))) && + (groupName.empty() || !pdi.folderGroupObj->isEmpty<side>())) //don't show for missing folders + { + tryDrawNavMarker(rectGroupParent); +@@ -933,14 +1001,14 @@ private: + drawCellText(dc, rectGroupParentText, groupParentFolder, wxALIGN_LEFT | wxALIGN_CENTER_VERTICAL, &getTextExtentBuffered(dc, groupParentFolder)); + } -- if (!groupName.empty() && row == groupFirstRow) -+ if (!(itemPathFormat_ == ItemPathFormat::traditional || itemPathFormat_ == ItemPathFormat::tradrel) && !groupName.empty() && row == groupFirstRow) +- if (!groupName.empty() && ++ if (!(itemPathFormat_ == ItemPathFormat::traditional || itemPathFormat_ == ItemPathFormat::tradrel) && !groupName.empty() && + row == groupFirstRow) { wxRect rectGroupNameBack = rectGroupName; @@ -169,19 +172,7 @@ diff -x '*.orig' -x '*.rej' -aur 11.3-0/FreeFileSync/Source/ui/file_grid.cpp 11. wxDCTextColourChanger textColorGroupName(dc); //folder background: coordinate with renderRowBackgound() -@@ -947,9 +1015,9 @@ - drawCellText(dc, rectGroupName, groupName, wxALIGN_LEFT | wxALIGN_CENTER_VERTICAL, &getTextExtentBuffered(dc, groupName)); - } - -- if (!groupParentFolder.empty() && -+ if (itemPathFormat_ == ItemPathFormat::traditional || itemPathFormat_ == ItemPathFormat::tradrel || (!groupParentFolder.empty() && - (( stackedGroupRender && row == groupFirstRow + 1) || -- (!stackedGroupRender && row == groupFirstRow)) && -+ (!stackedGroupRender && row == groupFirstRow))) && - (groupName.empty() || !pdi.folderGroupObj->isEmpty<side>())) //don't show for missing folders - { - wxRect rectGroupParentText = rectGroupParent; -@@ -969,16 +1037,16 @@ +@@ -984,16 +1052,16 @@ private: rectGroupItems.x += 2 * gapSize_; rectGroupItems.width -= 2 * gapSize_; @@ -201,8 +192,8 @@ diff -x '*.orig' -x '*.rej' -aur 11.3-0/FreeFileSync/Source/ui/file_grid.cpp 11. + rectItemsBack.height -= lineWidth; //preserve item separation lines! drawCudHighlight(rectItemsBack, pdi.fsObj->getSyncOperation()); - -@@ -1105,7 +1173,12 @@ + tryDrawNavMarker(rectGroupItems); +@@ -1124,7 +1192,12 @@ private: groupNameWidth] = getGroupRenderLayout(dc, row, pdi, insanelyHugeWidth); assert(!stackedGroupRender); @@ -216,7 +207,7 @@ diff -x '*.orig' -x '*.rej' -aur 11.3-0/FreeFileSync/Source/ui/file_grid.cpp 11. const int fileIconWidth = getIconManager().getIconBuffer() ? gapSize_ + getIconManager().getIconSize() : 0; const int ellipsisWidth = getTextExtentBuffered(dc, ELLIPSIS).x; const int itemWidth = itemName.empty() ? 0 : -@@ -1137,6 +1210,10 @@ +@@ -1156,6 +1229,10 @@ private: return _("Relative path"); case ItemPathFormat::full: return _("Full path"); @@ -227,7 +218,7 @@ diff -x '*.orig' -x '*.rej' -aur 11.3-0/FreeFileSync/Source/ui/file_grid.cpp 11. } assert(false); break; -@@ -1393,7 +1470,8 @@ +@@ -1413,7 +1490,8 @@ private: GridData::renderRowBackgound(dc, rect, row, true /*enabled*/, true /*selected*/, rowHover); //---------------------------------------------------------------------------------- @@ -237,7 +228,7 @@ diff -x '*.orig' -x '*.rej' -aur 11.3-0/FreeFileSync/Source/ui/file_grid.cpp 11. clearArea(dc, rectLine, row == pdi.groupLastRow - 1 /*last group item*/ ? getColorGridLine() : getDefaultBackgroundColorAlternating(pdi.groupIdx % 2 != 0)); } -@@ -1417,7 +1495,8 @@ +@@ -1437,7 +1515,8 @@ private: { wxRect rectBack = rect; if (row == pdi.groupLastRow - 1 /*last group item*/) //preserve the group separation line! @@ -247,10 +238,9 @@ diff -x '*.orig' -x '*.rej' -aur 11.3-0/FreeFileSync/Source/ui/file_grid.cpp 11. clearArea(dc, rectBack, col); } -diff -x '.git*' -x '*.orig' -x '*.rej' -aur 11.2-1/FreeFileSync/Source/ui/file_grid_attr.h 11.2-1-trad3/FreeFileSync/Source/ui/file_grid_attr.h ---- 11.2-1/FreeFileSync/Source/ui/file_grid_attr.h 2020-10-02 14:39:05.313463564 -0400 -+++ 11.2-1-trad3/FreeFileSync/Source/ui/file_grid_attr.h 2020-10-02 20:21:48.863111642 -0400 -@@ -79,6 +79,8 @@ +--- a/FreeFileSync/Source/ui/file_grid_attr.h ++++ b/FreeFileSync/Source/ui/file_grid_attr.h +@@ -79,6 +79,8 @@ enum class ItemPathFormat name, relative, full, @@ -259,10 +249,17 @@ diff -x '.git*' -x '*.orig' -x '*.rej' -aur 11.2-1/FreeFileSync/Source/ui/file_g }; const ItemPathFormat defaultItemPathFormatLeftGrid = ItemPathFormat::relative; -diff -x '.git*' -x '*.orig' -x '*.rej' -aur 11.2-1/FreeFileSync/Source/ui/main_dlg.cpp 11.2-1-trad3/FreeFileSync/Source/ui/main_dlg.cpp ---- 11.2-1/FreeFileSync/Source/ui/main_dlg.cpp 2020-10-02 20:49:11.487782099 -0400 -+++ 11.21-1/FreeFileSync/Source/ui/main_dlg.cpp 2022-05-22 20:26:31.350461792 -0400 -@@ -2741,6 +2741,8 @@ +--- a/FreeFileSync/Source/ui/main_dlg.cpp ++++ b/FreeFileSync/Source/ui/main_dlg.cpp +@@ -439,7 +439,6 @@ void MainDialog::create(const Zstring& g + if (mainDlg->globalCfg_.welcomeDialogLastVersion != ffsVersion) + { + mainDlg->globalCfg_.welcomeDialogLastVersion = ffsVersion; +- showAboutDialog(mainDlg); + } + + +@@ -2765,6 +2764,8 @@ void MainDialog::onGridLabelContextRim(G addFormatEntry(_("Item name" ), ItemPathFormat::name); addFormatEntry(_("Relative path"), ItemPathFormat::relative); addFormatEntry(_("Full path" ), ItemPathFormat::full); @@ -271,10 +268,9 @@ diff -x '.git*' -x '*.orig' -x '*.rej' -aur 11.2-1/FreeFileSync/Source/ui/main_d //---------------------------------------------------------------------------------------------- auto setIconSize = [&](GridIconSize sz, bool showIcons) -diff -x '.git*' -x '*.orig' -x '*.rej' -aur 11.2-1/FreeFileSync/Source/config.cpp 11.2-1-trad3/FreeFileSync/Source/config.cpp ---- 11.2-1/FreeFileSync/Source/config.cpp 2020-10-02 14:39:05.233462578 -0400 -+++ 11.2-1-trad3/FreeFileSync/Source/config.cpp 2020-10-02 20:22:24.275555557 -0400 -@@ -528,6 +528,12 @@ +--- a/FreeFileSync/Source/config.cpp ++++ b/FreeFileSync/Source/config.cpp +@@ -494,6 +494,12 @@ void writeText(const ItemPathFormat& val case ItemPathFormat::full: output = "Full"; break; @@ -287,7 +283,7 @@ diff -x '.git*' -x '*.orig' -x '*.rej' -aur 11.2-1/FreeFileSync/Source/config.cp } } -@@ -541,6 +547,10 @@ +@@ -507,6 +513,10 @@ bool readText(const std::string& input, value = ItemPathFormat::relative; else if (tmp == "Full") value = ItemPathFormat::full; @@ -298,10 +294,9 @@ diff -x '.git*' -x '*.orig' -x '*.rej' -aur 11.2-1/FreeFileSync/Source/config.cp else return false; return true; -diff -x '.git*' -x '*.orig' -x '*.rej' -aur 11.2-1/FreeFileSync/Source/ui/file_view.cpp 11.2-1-trad3/FreeFileSync/Source/ui/file_view.cpp ---- 11.2-1/FreeFileSync/Source/ui/file_view.cpp 2020-10-02 14:39:05.305463465 -0400 -+++ 11.2-1-trad3/FreeFileSync/Source/ui/file_view.cpp 2020-10-02 20:22:38.439733112 -0400 -@@ -798,11 +798,13 @@ +--- a/FreeFileSync/Source/ui/file_view.cpp ++++ b/FreeFileSync/Source/ui/file_view.cpp +@@ -798,11 +798,13 @@ void FileView::sortView(ColumnTypeRim ty break; case ItemPathFormat::relative: @@ -315,14 +310,3 @@ diff -x '.git*' -x '*.orig' -x '*.rej' -aur 11.2-1/FreeFileSync/Source/ui/file_v if ( ascending && onLeft) std::sort(sortedRef_.begin(), sortedRef_.end(), LessFullPath<true, SelectSide::left>(folderPairs_)); else if ( ascending && !onLeft) std::sort(sortedRef_.begin(), sortedRef_.end(), LessFullPath<true, SelectSide::right>(folderPairs_)); else if (!ascending && onLeft) std::sort(sortedRef_.begin(), sortedRef_.end(), LessFullPath<false, SelectSide::left>(folderPairs_)); -diff -aur 11.22-0/FreeFileSync/Source/ui/main_dlg.cpp 11.22-1/FreeFileSync/Source/ui/main_dlg.cpp ---- 11.22-0/FreeFileSync/Source/ui/main_dlg.cpp 2022-06-26 12:01:15.634291415 -0400 -+++ 11.22-1/FreeFileSync/Source/ui/main_dlg.cpp 2022-06-26 15:39:46.313320272 -0400 -@@ -436,7 +436,6 @@ - if (mainDlg->globalCfg_.welcomeShownVersion != ffsVersion) - { - mainDlg->globalCfg_.welcomeShownVersion = ffsVersion; -- showAboutDialog(mainDlg); - } - - |