Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Tag: v1.0.7 #52

Merged
merged 28 commits into from
Aug 6, 2018
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
28 commits
Select commit Hold shift + click to select a range
2dfaa75
Ignore: add forgotten semicolon
fofajardo Mar 17, 2018
b1c468c
Major: Resolve #42 - Wrap AiOS' functions into a module pattern
fofajardo Apr 24, 2018
abbe914
Minor: Fix MultiPanel for PM v28
fofajardo Apr 24, 2018
3fc3413
Ignore: use only one customization event handler
fofajardo Apr 24, 2018
2057019
Minor: Fix #44 - Update the way we handle full screen switching
fofajardo May 5, 2018
c0e793f
Ignore: bump max version
fofajardo May 5, 2018
ec2bc79
Minor: Don't hide sidebar switch when in fullscreen by default
fofajardo May 5, 2018
5ed8796
Ignore: remove extra space
fofajardo May 5, 2018
9b19153
Ignore: update locales
fofajardo May 6, 2018
293383b
Ignore: use ternary operators in invisible switch options
fofajardo May 16, 2018
40a8ced
Minor: Use -moz-box-ordinal-group instead of ugly RTL hack
fofajardo May 16, 2018
1dc5723
Minor: Save switch/toolbar/sidebar states and restore them after cust…
fofajardo Jun 7, 2018
02f1a52
Minor: Scrap second pane search for Bookmarks/History
fofajardo Jun 22, 2018
11b6616
Minor: Force disable+hide second pane of Bookmarks when 2 Pane Bookma…
fofajardo Jun 22, 2018
960262c
Minor: Add option to reject click interactions with SS when ISS is en…
fofajardo Jun 22, 2018
2b947ca
Minor: Don't remove timeout on autohide when certain conditions were met
fofajardo Jun 25, 2018
f863877
Ignore: Reduce duration of invisible SS highlight on hover
fofajardo Jun 25, 2018
bcf0ccf
Minor: remove advanced mode (and show them all by default)
fofajardo Jul 23, 2018
243ad9a
Minor: Follow up to #40 for preferences window
fofajardo Jul 23, 2018
623c9ac
Minor: Cleanup and some re-arrangements to options window
fofajardo Jul 23, 2018
c6eba8a
Minor: Allow sidebar collapsing to apply also to old windows
fofajardo Jul 23, 2018
a8c1ddf
Ignore: make background rules for TGS toggle button [invisible] impor…
fofajardo Jul 29, 2018
2b93c96
Ignore: Add icon for sidebar switch pane in options window
fofajardo Jul 29, 2018
8ceb3fe
Minor: Changes to drag and drop functionality should apply on change
fofajardo Aug 6, 2018
f3ecd3e
Minor: Typo on determining invisible mouse cursor
fofajardo Aug 6, 2018
9b23785
Minor: Add option to remove/hide sidebar switch on some occasions
fofajardo Aug 6, 2018
0105400
Ignore: update locales
fofajardo Aug 6, 2018
61c5c4a
Ignore: update changelog
fofajardo Aug 6, 2018
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
29 changes: 27 additions & 2 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,31 @@

# Changelog

### 1.0.7 (08.06.2018)
* This release is compatible with Pale Moon 28.
* Major: Wrap AiOS' functions into a module pattern
* Major: Update the way we handle fullscreen switching
* The way this is done is patterned on the way Pale Moon's full screen component handles this event
* Mark sidebar header toolbar as 'fullscreen toolbar' in order for it to not be hidden when entering fullscreen
* Hide TGS toolbars & switch when entering DOM Fullscreen (they're unnecessary in that mode)
* Minor: Don't hide sidebar switch when in fullscreen by default
* Minor: remove advanced mode (and show them all by default)
* Minor: Use -moz-box-ordinal-group instead of ugly RTL hack
* Minor: Save switch/toolbar/sidebar states and restore them after customization
* Minor: Scrap second pane search for Bookmarks/History
* Minor: Improve compatibility with 2 Pane Bookmarks
* Minor: Add option to reject click interactions on Sidebar Switch when it is invisible
* Minor: Add option to remove/hide sidebar switch on some occasions
* Ignore: Fix invalid variable error on mouse cursor variable (ISS)
* Small typo: hand should be default
* Ignore: Changes to drag and drop functionality should apply on change
* Ignore: Move sidebar switch tab into its own panel in Preferences/Options
* Ignore: make background rules for TGS toggle button [invisible] important
* Changing --aios-switch-hovercolor variable still works
* Ignore: Reduce duration of invisible SS highlight on hover
* It feels tooooo.. slow..
* Ignore: Refactoring/changes under the hood

### 1.0.6 (03.14.2018)
* Major: Revise invisible sidebar switch implementation
* This...
Expand Down Expand Up @@ -74,12 +99,12 @@
* Minor: Prevent non-numbers from being placed on input boxes in prefs window
* Prevents some invalid values like putting letters in places where numbers are the only accepted values
* Also adds a spin button beside the boxes
* Prevent negative values (for miliseconds/pixels/percent)
* Prevent negative values (for milliseconds/pixels/percent)
* Minor: Resolve #28 - Expose options when dragging something above the sidebar switch
* When options for delay is set to 0, this means that there is no delay
* Minor: Shading items in DL list should controllable by pref
* Allows shading to happen even in non-default themes
* Minor: Properly show some strings on key config (and some others)
* Minor: Properly show some strings on keyconfig (and some others)
* In the past (including AiOS 0.7.21.1), some parts of the UI will show the camel case name of the string instead of the actual string itself
* Adds 'keyconf.properties' and reads the string from the string bundle instead
* Now properly displays 'Browser restart required' when resetting keys
Expand Down
23 changes: 0 additions & 23 deletions content/_helper.js
Original file line number Diff line number Diff line change
Expand Up @@ -296,29 +296,6 @@ function aios_openDialog(which, args) {
toOpenWindowByType(theId, theUrl, theFeatures);
}

/*
* Check which elements should be displayed
* => Called by initialization
*/
function aios_synchElements(aElems) {
var elem,
child,
childElems,
childMode;

for (var i = 0; i < aElems.length; i++) {
elem = document.getElementById(aElems[i]);

if (elem) {
childElems = elem.getAttribute('aiosChilds');
if (childElems) {
childMode = !aios_getBoolean(elem, 'checked');
aios_toggleChilds(childElems, childMode);
}
}
}
}

/*
* Toggles a menu item and/or its/their element(s)
* => Called through the menuitems in the aios.xul
Expand Down
57 changes: 31 additions & 26 deletions content/_lib.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,18 +5,18 @@ Components.utils.import("resource://gre/modules/Downloads.jsm");
* => Calling aios_initSidebar() and aios_getSidebarMenu() (MenuButton Events 'onpopupshowing')
*/
function aios_modSidebarMenu() {
aios_getObjects();
AiOS_Objects.get();

var actSidebar = aios_remLastSidebar();
var actSidebar = AiOS.remLastSidebar();
var command,
commandParent;

// take over every single menu item or change it if necessary
for (var i = 0; i < fx_sidebarMenu.childNodes.length; i++) {
for (var i = 0; i < AiOS_Objects.sidebarMenu.childNodes.length; i++) {
command = null;
commandParent = null;
var broadcaster = null;
var item = fx_sidebarMenu.childNodes[i];
var item = AiOS_Objects.sidebarMenu.childNodes[i];

// Show or hide the icons
try {
Expand Down Expand Up @@ -104,17 +104,17 @@ function aios_modSidebarMenu() {
} catch (e) {}

// Move menu entries all the way down if the menu has not been edited yet
if (!aios_getBoolean(fx_sidebarMenu, 'aios-modified')) {
fx_sidebarMenu.appendChild(showhideMenuseparator);
fx_sidebarMenu.appendChild(paneltabMitem1);
fx_sidebarMenu.appendChild(paneltabMitem2);
fx_sidebarMenu.appendChild(sidebarshowMitem);
fx_sidebarMenu.appendChild(sidebarhideMitem);
fx_sidebarMenu.appendChild(prefsMitem);
if (!aios_getBoolean(AiOS_Objects.sidebarMenu, 'aios-modified')) {
AiOS_Objects.sidebarMenu.appendChild(showhideMenuseparator);
AiOS_Objects.sidebarMenu.appendChild(paneltabMitem1);
AiOS_Objects.sidebarMenu.appendChild(paneltabMitem2);
AiOS_Objects.sidebarMenu.appendChild(sidebarshowMitem);
AiOS_Objects.sidebarMenu.appendChild(sidebarhideMitem);
AiOS_Objects.sidebarMenu.appendChild(prefsMitem);
}

// Remember the sidebar menu as edited
fx_sidebarMenu.setAttribute('aios-modified', true);
AiOS_Objects.sidebarMenu.setAttribute('aios-modified', true);
}

/*
Expand Down Expand Up @@ -252,11 +252,11 @@ function aios_panelTab(event) {
}
// about:
else if (tabHref.indexOf("about:") >= 0) {
aios_setMultiPanel(tabHref);
AiOS_MP.setMultiPanel(tabHref);
}
// normal Website
else {
aios_setMultiPanel('page');
AiOS_MP.setMultiPanel('page');
}
}
/*
Expand All @@ -265,7 +265,7 @@ function aios_panelTab(event) {
else {
var newSrc;

if (fx_sidebarBox.hidden)
if (AiOS_Objects.sidebarBox.hidden)
return false;

var sidebarDoc = top.document.getElementById('sidebar').contentDocument;
Expand Down Expand Up @@ -472,16 +472,20 @@ function aios_setTargets() {
var prefInfotip = false,
ptReverse = false,
enable_rightclick = false,
switchTip = true;
switchTip = true,
inv_switch = false,
inv_noclick = false;
try {
prefInfotip = AiOS_HELPER.prefBranchAiOS.getBoolPref("infotips");
ptReverse = AiOS_HELPER.prefBranchAiOS.getBoolPref("paneltab.reverse");
enable_rightclick = AiOS_HELPER.prefBranchAiOS.getBoolPref("rightclick");
switchTip = AiOS_HELPER.prefBranchAiOS.getBoolPref("switchtip");
inv_switch = AiOS_HELPER.prefBranchAiOS.getBoolPref('gen.switch.inv');
inv_noclick = AiOS_HELPER.prefBranchAiOS.getBoolPref('gen.switch.invnoclick');

if (prefInfotip) {
if (elem_switch)
elem_switch.removeAttribute('tooltiptext');
if (AiOS_Objects.sbSwitch)
AiOS_Objects.sbSwitch.removeAttribute('tooltiptext');

// in loop because there may be several buttons with the same ID
objects = document.getElementsByAttribute('id', 'paneltab-button');
Expand All @@ -490,9 +494,10 @@ function aios_setTargets() {
}
}

if (!switchTip)
if (elem_switch)
elem_switch.removeAttribute('tooltip');
// If tooltip for the switch is disabled/it's not logical to show the tooltip, remove it
if (!switchTip || (inv_switch && inv_noclick))
if (AiOS_Objects.sbSwitch)
AiOS_Objects.sbSwitch.removeAttribute('tooltip');

if (document.getElementById('paneltab-button')) {
if (ptReverse)
Expand Down Expand Up @@ -704,17 +709,17 @@ function aios_isWinMax() {
* => depends on the sidebar method
*/
function aios_isSidebarHidden() {
aios_getObjects();
AiOS_Objects.get();

let pref = 'collapse';
if (AiOS_HELPER.prefBranchAiOS.getPrefType(pref)) {
var aios_collapseSidebar = AiOS_HELPER.prefBranchAiOS.getBoolPref(pref);
}

if (aios_collapseSidebar)
return (fx_sidebarBox.hidden || fx_sidebarBox.collapsed);
return (AiOS_Objects.sidebarBox.hidden || AiOS_Objects.sidebarBox.collapsed);
else
return fx_sidebarBox.hidden;
return AiOS_Objects.sidebarBox.hidden;
}

/*
Expand All @@ -727,9 +732,9 @@ function aios_initAutohide() {
document.getElementById('aios-enableAutohide').setAttribute('checked', AiOS_HELPER.prefBranchAiOS.getBoolPref("gen.switch.autoshow"));

// Add autohide feature/command
fx_sidebarBox.addEventListener("mouseover", function () {
AiOS_Objects.sidebarBox.addEventListener("mouseover", function () {
if (document.getElementById('appcontent'))
document.getElementById('appcontent').addEventListener("mouseover", aios_autoShowHide, true);
document.getElementById('appcontent').addEventListener("mouseover", AiOS.autoShowHide, true);
}, true);

window.addEventListener("focus", function (e) {
Expand Down
35 changes: 18 additions & 17 deletions content/aios.xul
Original file line number Diff line number Diff line change
Expand Up @@ -208,7 +208,7 @@
command="aiosCmd_panelTab2" />
<key id="aiosKey_sidebar"
keycode="&keys.sidebar;"
oncommand="aios_toggleSidebar(this);"
oncommand="AiOS.toggleSidebar(this);"
label="&button.toggle.tooltip;" />
<key id="aiosKey_prefs"
modifiers="&keys.modifiers;"
Expand All @@ -233,15 +233,15 @@
<observes id="aios_observeHidden"
element="sidebar-box"
attribute="hidden"
onbroadcast="if(!aios_collapseSidebar) aios_observeSidebar('hidden');" />
onbroadcast="if (!AiOS.isCollapsingEnabled()) AiOS.observeSidebar('hidden');" />
<observes id="aios_observeCollapsed"
element="sidebar-box"
attribute="collapsed"
onbroadcast="if(aios_collapseSidebar) aios_observeSidebar('collapsed');" />
onbroadcast="if (AiOS.isCollapsingEnabled()) AiOS.observeSidebar('collapsed');" />
<!-- Monitor src status of sidebar => remember last sidebar -->
<observes element="sidebar"
attribute="src"
onbroadcast="aios_remLastSidebar();" />
onbroadcast="AiOS.remLastSidebar();" />
</vbox>


Expand All @@ -253,15 +253,15 @@
<grippy id="aios-sidebarGrippy"
hidden="true"
persist="hidden"
onclick="aios_useGrippy();" />
onclick="AiOS.useGrippy();" />
</splitter>


<!-- TGS Toolbar Buttons -->
<toolbarpalette id="BrowserToolbarPalette">
<toolbarbutton id="sidebarclose-button"
class="tabs-closebutton close-icon"
oncommand="aios_toggleSidebar(this);"
oncommand="AiOS.toggleSidebar(this);"
ondblclick="event.stopPropagation();"
tooltiptext="&sidebarCloseButton.tooltip;"
label="&sidebarCloseButton.tooltip;" />
Expand Down Expand Up @@ -363,17 +363,17 @@
class="toolbarbutton-1 chromeclass-toolbar-additional aios-tbutton"
label="&button.menu.label;"
tooltiptext="&button.menu.tooltip;">
<menupopup onpopupshowing="aios_getSidebarMenu(this);" />
<menupopup onpopupshowing="AiOS.getSidebarMenu(this);" />
</toolbarbutton>
<toolbarbutton id="sidebars-togglebutton"
class="toolbarbutton-1 chromeclass-toolbar-additional aios-tbutton"
type="menu-button"
oncommand="aios_toggleSidebar(this);"
oncommand="AiOS.toggleSidebar(this);"
label="&button.toggle.label;"
tooltiptext="&button.toggle.tooltip;">
<observes element="sidebar-box"
attribute="checked" />
<menupopup onpopupshowing="aios_getSidebarMenu(this);"
<menupopup onpopupshowing="AiOS.getSidebarMenu(this);"
oncommand="event.stopPropagation();" />
</toolbarbutton>

Expand Down Expand Up @@ -675,13 +675,13 @@
key="aiosKey_sidebar"
position="97"
class="menuitem-iconic"
oncommand="aios_toggleSidebar(this);" />
oncommand="AiOS.toggleSidebar(this);" />
<menuitem id="aios-sidebar-mitem-hide"
label="&sidebar.close.label;"
key="aiosKey_sidebar"
position="98"
class="menuitem-iconic"
oncommand="aios_toggleSidebar(this);" />
oncommand="AiOS.toggleSidebar(this);" />
<menuitem id="aios-sidebar-mitem-prefs"
label="&menu.prefs.label;"
key="aiosKey_prefs"
Expand All @@ -705,7 +705,7 @@
<!-- Monitor window mode for narrow switch (maximized, normal, minimized) -->
<observes element="main-window"
attribute="sizemode"
onbroadcast="aios_checkSidebarSwitch();" />
onbroadcast="AiOS.checkSidebarSwitch();" />

<toolbar id="aios-toggle-toolbar"
class="chromeclass-toolbar"
Expand All @@ -718,9 +718,9 @@
id="aios-toggle-button"
tooltip="switch-tooltip"
tooltiptext="&button.toggle.tooltip;"
onclick="aios_controlSwitch(event, this);"
onmouseover="aios_autoShowHide('switch'); event.stopPropagation();"
ondragenter="aios_toggleSidebar('switch', true); event.stopPropagation();" />
onclick="AiOS.controlSwitch(event, this);"
onmouseover="AiOS.autoShowHide('switch'); event.stopPropagation();"
ondragenter="AiOS.toggleSidebar('switch', true); event.stopPropagation();" />
</toolbar>

<toolbarset />
Expand Down Expand Up @@ -831,7 +831,7 @@
attribute="value" />
</label>

<menupopup onpopupshowing="aios_getSidebarMenu(this);" />
<menupopup onpopupshowing="AiOS.getSidebarMenu(this);" />
</toolbarbutton>

<spacer id="sidebarheader-spacer"
Expand Down Expand Up @@ -861,7 +861,8 @@
persist="mode iconsize"
defaultset="autohide-button,paneltab-button,sidebarclose-button"
toolbarlabel="&sbhtoolbar.label;:"
flexbuttons="false" >
fullscreentoolbar="true"
flexbuttons="false">

<!-- Prevents the toolbar from being moved to a mode other than icons -->
<observes element="aios-sbhtoolbar"
Expand Down
Loading