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

Global activity action: align with existing patterns #27461

Closed
bpasero opened this issue May 29, 2017 · 4 comments
Closed

Global activity action: align with existing patterns #27461

bpasero opened this issue May 29, 2017 · 4 comments
Assignees
Labels
debt Code quality issues

Comments

@bpasero
Copy link
Member

bpasero commented May 29, 2017

Provided we decide to keep the global activity action in the bottom of the activity bar, I suggest to tackle some debt associated with it:

  • we introduce a new registry for global activity which seems odd, instead I suggest to use the already existing GLOBAL scope within IActionBarRegistry that can be used to register an action bar contributor for this scope. the activity bar part can then easily read out those actions from the global scope and use them
  • instead of introducing a new type IGlobalActivity that has to return actions that will show on click in the context menu we should just register an instance of IAction that inside its run method shows actions using the context menu service

Given these changes, I think we no longer need activity.ts and we basically have the old concept we used to have which is to register a global action that just implements everything through the run method.

/cc @joaomoreno

@joaomoreno
Copy link
Member

@bpasero Going along with this, how could we display a badge without reinventing the wheel?

@bpasero
Copy link
Member Author

bpasero commented Sep 4, 2017

@joaomoreno I would make IActivityBarService.showActivity fit so that it can show activity on anything that is in the activity bar that matches the passed in ID (for viewlets, the viewlet ID, for global actions, the action ID).

@bpasero bpasero assigned bpasero and unassigned joaomoreno and isidorn Sep 5, 2017
bpasero added a commit that referenced this issue Sep 6, 2017
@bpasero
Copy link
Member Author

bpasero commented Sep 6, 2017

Pushed some cleanup but overall think we can leave this as is. My original complaint to move to the actions (#27464) was meanwhile fixed, so I think the solution works quite nicely.

@bpasero bpasero closed this as completed Sep 6, 2017
@isidorn
Copy link
Contributor

isidorn commented Sep 6, 2017

@bpasero thanks for cleaning this up nicely

@vscodebot vscodebot bot locked and limited conversation to collaborators Nov 17, 2017
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
debt Code quality issues
Projects
None yet
Development

No branches or pull requests

3 participants