Skip to content

Commit

Permalink
4.21.2
Browse files Browse the repository at this point in the history
  • Loading branch information
RealRaven2000 committed Apr 18, 2021
1 parent 6a4eb68 commit d6d8194
Show file tree
Hide file tree
Showing 12 changed files with 126 additions and 13 deletions.
2 changes: 1 addition & 1 deletion build.bat
Original file line number Diff line number Diff line change
Expand Up @@ -10,4 +10,4 @@ rem "C:\Program Files\7-Zip\7z" a -xr!.svn quickFolders.zip install.rdf chrome.m
echo %quickFoldersRev% > revision.txt
move QuickFolders*.xpi "..\..\Release\_Test Versions\4.21\"
pwsh -Command "Start-Sleep -m 150"
rename QuickFoldersWeb.zip QuickFolders-wx-4.21.1pre%quickFoldersRev%.xpi
rename QuickFoldersWeb.zip QuickFolders-wx-4.21.2pre%quickFoldersRev%.xpi
5 changes: 3 additions & 2 deletions chrome/content/quickfolders-interface.js
Original file line number Diff line number Diff line change
Expand Up @@ -5778,7 +5778,7 @@ QuickFolders.Interface = {
const util = QuickFolders.Util,
prefs = QuickFolders.Preferences;
try {
let tabMode = tabInfo ? util.getTabMode(tabInfo) : this.CurrentTabMode
let tabMode = tabInfo ? util.getTabMode(tabInfo) : this.CurrentTabMode;
util.logDebugOptional("interface.currentFolderBar", 'initCurrentFolderTab(' + (folder ? folder.prettyName : 'null') + ')\n'
+ "tabMode: " + tabMode);
this.hoistCurrentFolderBar(currentFolderTab, tabInfo);
Expand Down Expand Up @@ -6822,7 +6822,8 @@ QuickFolders.Interface = {
if (selectedTab>=0) {
let tab = util.getTabInfoByIndex(tabmail, selectedTab);
if (tab) {
tabMode = util.getTabMode(tab); // test in Postbox
tabMode = util.getTabMode(tab);
util.logDebug("CurrentTabMode() \n selectedTab = " + selectedTab + "\n tabMode = " + tabMode);
if (tabMode == "glodaSearch" && tab.collection) { //distinguish gloda search result
tabMode = "glodaSearch-result";
}
Expand Down
48 changes: 42 additions & 6 deletions chrome/content/quickfolders-util.js
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ QuickFolders.Util = {
_isCSSGradients: -1,
_isCSSRadius: -1,
_isCSSShadow: true,
HARDCODED_CURRENTVERSION : "4.21.1", // will later be overriden call to AddonManager
HARDCODED_CURRENTVERSION : "4.21.2", // will later be overriden call to AddonManager
HARDCODED_EXTENSION_TOKEN : ".hc",
ADDON_ID: "[email protected]",
FolderFlags : { // nsMsgFolderFlags
Expand Down Expand Up @@ -702,7 +702,7 @@ QuickFolders.Util = {
} ,

// find the first mail tab representing a folder and open it
ensureFolderViewTab: function ensureFolderViewTab() {
ensureFolderViewTab: function ensureFolderViewTab(folder) {
const util = QuickFolders.Util;
// TB 3 bug 22295 - if a single mail tab is opened this appears to close it!
let found=false,
Expand All @@ -718,15 +718,28 @@ QuickFolders.Util = {
// switchToTab
// iterate tabs
let tabInfoCount = util.getTabInfoLength(tabmail);
let firstFound = -1;
for (let i = 0; i < tabInfoCount; i++) {
let info = util.getTabInfoByIndex(tabmail, i);
if (info && this.getTabMode(info) == util.mailFolderTypeName) {
util.logDebugOptional ("mailTabs","switching to tab: " + info.title);
tabmail.switchToTab(i);
found = true;
break;
if (firstFound<0) firstFound = i;
if (!folder)
break;
else {
let fD = info ? info.folderDisplay : null;
if (fD.view && fD.view.displayedFolder && folder.URI == fD.view.displayedFolder.URI) {
firstFound = i;
break; // this is the one we want
}
}
}
}
if (firstFound>=0) {
tabmail.switchToTab(firstFound);
found = true;
}

// if it can't find a tab with folders ideally it should call openTab to display a new folder tab
for (let i=0;(!found) && i < tabInfoCount; i++) {
let info = util.getTabInfoByIndex(tabmail, i);
Expand Down Expand Up @@ -919,12 +932,23 @@ QuickFolders.Util = {
return null;
}


// [issue 132] Shift-M opens a new tab after moving the message...
// if we move the email and are in a single message window, we need to jump to the next unread mail first!
let tabMail = document.getElementById("tabmail"),
currentTabInfo = tabMail.tabInfo[QuickFolders.tabContainer.selectedIndex],
// currentTabId = currentTabInfo.tabId,
currentTabSelIdx = QuickFolders.tabContainer.selectedIndex,
moveFromSingleMailTab = false,
isGoNext = prefs.getBoolPref("quickMove.gotoNextMsgAfterMove");
if (!makeCopy && QuickFolders.Interface.CurrentTabMode == "message") {
moveFromSingleMailTab = true;
// either go to the next mail... or close the tab
if (prefs.getBoolPref("quickMove.gotoNextMsgAfterMove"))
if (isGoNext) {
goDoCommand('cmd_nextMsg');
QuickFolders.Interface.ensureCurrentFolder();
}
document.getElementById('messagepane').focus();
}

step = 5;
Expand All @@ -941,9 +965,20 @@ QuickFolders.Util = {
'listener = QuickFolders.CopyListener\n' +
'msgWindow = ' + msgWindow + '\n' +
'allowUndo = true)');
let currentTab = tabMail.selectedTab;
cs.CopyMessages(sourceFolder, messageList, targetFolder, isMove, QuickFolders.CopyListener, msgWindow, true);
step = 8;
util.touch(targetFolder); // set MRUTime
if (moveFromSingleMailTab && currentTabSelIdx > 0 && !isGoNext) {
// close single message tab:
util.logDebug("moveMessages: currentTabSelIdx = " + currentTabSelIdx);
if (currentTabSelIdx == QuickFolders.tabContainer.selectedIndex) {
// TO DO: goto corresponding folder tab or at least tab 0
util.ensureFolderViewTab(sourceFolder);
// now close the tab Tb opened.
tabMail.closeTab(currentTab, false);
}
}
return messageIdList; // we need the first element for further processing
}
catch(e) {
Expand Down Expand Up @@ -999,6 +1034,7 @@ QuickFolders.Util = {
} ,

getTabInfoByIndex: function getTabInfoByIndex(tabmail, idx) {
this.logDebug("getTabInfoByIndex(tabmail, " + idx + ") tabInfo: " + tabmail.tabInfo);
if (tabmail.tabInfo && tabmail.tabInfo.length)
return tabmail.tabInfo[idx];
if (tabmail.tabOwners)
Expand Down
2 changes: 1 addition & 1 deletion chrome/content/quickfolders.js
Original file line number Diff line number Diff line change
Expand Up @@ -535,7 +535,7 @@ var QuickFolders_PrepareSessionStore = function () {
orgRestore(aTabmail, aPersistedState);
let txt;
try {
aPersistedState.QuickFoldersCategory || "(no category)";
txt = aPersistedState.QuickFoldersCategory || "(no category)";
} catch(ex) {;}
util.logDebug("restored tabs: " + txt);
let rdf = Components.classes['@mozilla.org/rdf/rdf-service;1'].getService(CI.nsIRDFService),
Expand Down
55 changes: 55 additions & 0 deletions chrome/skin/mac/style.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,55 @@
/* platform styles - Mac */
#qf-header-container {
padding-bottom: 0.9em;
}
#QuickFolders-Options-Tabbox tab {
padding: 2px 0;
margin-bottom: -3px;
}

#QuickFolders-Options-quickhelp {
font-size: 10pt !important;
}

/* #btnLicense - note this will get special rules for Mac */
.niceFont,
.niceFont * {
font-family: initial !important; /* or inherit ? */
font-size: 10pt !important;
}

#firstName, #lastName {
width: 12em;
}
/*
#QuickFolders-Options-Tabbox tab .tab-text {
margin-top: -6px;
}
#QuickFolders-Options-Tabbox tab .tab-icon {
margin-top: -3px;
}
#QuickFolders-Options-Tabbox tabpanels {
padding-top: 1em;
}
#QuickFolders-Options-Tabbox tab .tab-icon {
margin: -15px 0px -6px 0px;
}
*/

#QuickFolders-CurrentFolderTools toolbarbutton {
max-width: 20px;
padding-left: 0px;
padding-right: 0px;
}
/** make sure empty labels don't take up space **/
#QuickFolders-CurrentFolderTools toolbarbutton > .toolbarbutton-text,
#QuickFolders-oneButtonPanel toolbarbutton > .toolbarbutton-text {
visibility: collapse;
margin: 0 !important;
}

/* Mac width fix */
#QuickFolders-Options-Tabbox tab:not([selected="true"]) .tab-text{
max-width:80px;
text-overflow: ellipsis;
}
14 changes: 14 additions & 0 deletions chrome/skin/unix/style.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
/* platform styles - Linux */
#QuickFolders-Options-Tabbox tab {
padding: 0.2em 0.6em;
}

toolbar.quickfolders-flat ,
toolbar.quickfolders-pills {
/* in linux -moz-appearance is 'toolbar' and this overrides any coloring of background / borders */
-moz-appearance: none !important;
}

#qf-options {
min-height: 640px;
}
2 changes: 2 additions & 0 deletions chrome/skin/win/about.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
/* fix a problem in about dialog: double contributorsBox */
#contributorsBox.indent { display:none; }
1 change: 1 addition & 0 deletions chrome/skin/win/qf-platform.xul
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
<?xml version="1.0" encoding="UTF-8"?>
4 changes: 4 additions & 0 deletions chrome/skin/win/style.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
/* platform styles - Windows */
#QuickFolders-Options-Tabbox tab {
padding: 0.2em 0.6em;
}
2 changes: 1 addition & 1 deletion manifest.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
"manifest_version": 2,
"name": "QuickFolders",
"description": "Bookmark your favorite mail folders in Thunderbird.",
"version": "4.21.1",
"version": "4.21.2",
"developer": {
"name": "Axel Grude",
"url": "https://quickfolders.org/index.html"
Expand Down
2 changes: 1 addition & 1 deletion release-notes.html
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
Release 4.21.1
Release 4.21.2

This release backports some of the fixes that were also done in the new version for Thunderbird 78. If you want to get the latest features, I highly recommend updating Thunderbird to the current 78 release version.
To support QuickFolders, <a href="http://sites.fastspring.com/quickfolders/product/quickfolders?referrer=atn-version-page">buy a license</a> or <a href="https://quickfolders.org/donate.html?referrer=atn-version-page">donate</a> to support the project.
Expand Down
2 changes: 1 addition & 1 deletion revision.txt
Original file line number Diff line number Diff line change
@@ -1 +1 @@
29
44

0 comments on commit d6d8194

Please sign in to comment.