Fossil SCM
Settings menu now closes if a click or ESC happens outside of the menu.
Commit
1f000368845a6d994735db760a02d0cb10ff5eee1d91526b1fbac1c7ccd8a13e
Parent
cffd66ffe9ed970…
1 file changed
+3
-6
+3
-6
| --- src/chat.js | ||
| +++ src/chat.js | ||
| @@ -642,16 +642,13 @@ | ||
| 642 | 642 | } |
| 643 | 643 | D.append(settingsPopup.e, line); |
| 644 | 644 | btn.addEventListener('click', callback); |
| 645 | 645 | }); |
| 646 | 646 | }; |
| 647 | - /** | |
| 648 | - Reminder: | |
| 649 | - settingsPopup.installClickToHide(); | |
| 650 | - Don't do this for this popup! It interferes with the embedded | |
| 651 | - "?" buttons in the popup, which are also PopupWidget users. | |
| 652 | - */ | |
| 647 | + settingsPopup.installClickToHide() | |
| 648 | + /** Reminder: that interferes with "?" embedded within the popup, | |
| 649 | + so cannot be used together with those. */; | |
| 653 | 650 | D.attr(settingsButton, 'role', 'button'); |
| 654 | 651 | settingsButton.addEventListener('click',function(ev){ |
| 655 | 652 | //ev.preventDefault(); |
| 656 | 653 | if(settingsPopup.isShown()) settingsPopup.hide(); |
| 657 | 654 | else settingsPopup.show(settingsButton); |
| 658 | 655 |
| --- src/chat.js | |
| +++ src/chat.js | |
| @@ -642,16 +642,13 @@ | |
| 642 | } |
| 643 | D.append(settingsPopup.e, line); |
| 644 | btn.addEventListener('click', callback); |
| 645 | }); |
| 646 | }; |
| 647 | /** |
| 648 | Reminder: |
| 649 | settingsPopup.installClickToHide(); |
| 650 | Don't do this for this popup! It interferes with the embedded |
| 651 | "?" buttons in the popup, which are also PopupWidget users. |
| 652 | */ |
| 653 | D.attr(settingsButton, 'role', 'button'); |
| 654 | settingsButton.addEventListener('click',function(ev){ |
| 655 | //ev.preventDefault(); |
| 656 | if(settingsPopup.isShown()) settingsPopup.hide(); |
| 657 | else settingsPopup.show(settingsButton); |
| 658 |
| --- src/chat.js | |
| +++ src/chat.js | |
| @@ -642,16 +642,13 @@ | |
| 642 | } |
| 643 | D.append(settingsPopup.e, line); |
| 644 | btn.addEventListener('click', callback); |
| 645 | }); |
| 646 | }; |
| 647 | settingsPopup.installClickToHide() |
| 648 | /** Reminder: that interferes with "?" embedded within the popup, |
| 649 | so cannot be used together with those. */; |
| 650 | D.attr(settingsButton, 'role', 'button'); |
| 651 | settingsButton.addEventListener('click',function(ev){ |
| 652 | //ev.preventDefault(); |
| 653 | if(settingsPopup.isShown()) settingsPopup.hide(); |
| 654 | else settingsPopup.show(settingsButton); |
| 655 |