You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Sep 6, 2021. It is now read-only.
That issue that affects brackets-git affects other Extensions too, such as brackets-todo. Is there a way to (at least temporarily / during 1.6.) to throw a warning if panel was closed but the button state remained + link to say Brackets-Wiki where those events would be explained). That would provide a easy way for extension makers that use panels to know that they should update their extensions).
The text was updated successfully, but these errors were encountered:
A simple/naive way to catch it is to check if the buttons have changed after toggling the panels. Something along the lines of
//localsvar_previouslyOpenPanelIDs=[],panelsToggled=false,layoutUpdated=false,panelToggleUpgradeNeededCheck=true;// This local can be removed in 1.7// A bit later/** * hide all open panels. Remove the check in 1.7. */function_hidePanelsIfRequired(){varpanelIDs=WorkspaceManager.getAllPanelIDs(),i=0,panelButtonsBefore,panelButtonsAfter;if(panelToggleUpgradeNeededCheck){panelButtonsBefore=$("#main-toolbar").find(".buttons > a");}_previouslyOpenPanelIDs=[];for(i=0;i<panelIDs.length;i++){if(WorkspaceManager.getPanelForID(panelIDs[i]).isVisible()){WorkspaceManager.getPanelForID(panelIDs[i]).hide();_previouslyOpenPanelIDs.push(panelIDs[i]);}}if(panelToggleUpgradeNeededCheck){panelButtonsAfter=$("#main-toolbar").find(".buttons > a");panelButtonsBefore.each(function(i,elem){var$this=$(this),classList=$this.attr("class");if(classList&&classList===panelButtonsAfter.eq(i).attr("class")){console.warn("Extension panel upgrade warning here + link to wiki. Extension icon is "+($this.attr("title")||$this.attr("id")||$this.html()));}});panelToggleUpgradeNeededCheck=false;}}
Another way would be checking if the icon has actually changed by checking the background image for example, but the approach would be the same.
There's a small issue with toggle panels though (other than the shortcut not showing up/working)
brackets-eslint
)That issue that affects
brackets-git
affects other Extensions too, such asbrackets-todo
. Is there a way to (at least temporarily / during 1.6.) to throw a warning if panel was closed but the button state remained + link to say Brackets-Wiki where those events would be explained). That would provide a easy way for extension makers that use panels to know that they should update their extensions).The text was updated successfully, but these errors were encountered: