-
Notifications
You must be signed in to change notification settings - Fork 0
Add notification manager API #2
Conversation
}; | ||
|
||
export const MAIN_RPC_CONTEXT = { | ||
HOSTED_PLUGIN_MANAGER_EXT: createProxyIdentifier<HostedPluginManagerExt>('HostedPluginManagerExt'), | ||
COMMAND_REGISTRY_EXT: createProxyIdentifier<CommandRegistryExt>('CommandRegistryExt'), | ||
QUICK_OPEN_EXT: createProxyIdentifier<QuickOpenExt>('QuickOpenExt') | ||
QUICK_OPEN_EXT: createProxyIdentifier<QuickOpenExt>('QuickOpenExt'), | ||
MESSAGE_REGISTRY_EXT: createProxyIdentifier('MessageRegistryExt') |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why you add this MESSAGE_REGISTRY_EXT
? Is this used anywhere?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I used it in plugin-context.ts
https://github.com/theia-demo-plugins/wiptheia/pull/2/files#diff-761ce14ea07b1d3bb10a3b02a8fb1763R22
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It's unnecessary, see comment below
|
||
export function createAPI(rpc: RPCProtocol): typeof theia { | ||
const commandRegistryExt = rpc.set(MAIN_RPC_CONTEXT.COMMAND_REGISTRY_EXT, new CommandRegistryImpl(rpc)); | ||
const quickOpenExt = rpc.set(MAIN_RPC_CONTEXT.QUICK_OPEN_EXT, new QuickOpenExtImpl(rpc)); | ||
const messageRegistryExt = rpc.set(MAIN_RPC_CONTEXT.MESSAGE_REGISTRY_EXT, new MessageRegistryExt(rpc)); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You don't need to do rpc.set
, as your MessageRegistryExt
is never called from Theia core part
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ok. I just added a mechanism for possible future In the first realization. I'll remove.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
done
e8a9416
to
fdd626c
Compare
.dialogContent .theia-Notification .icon { | ||
font-size: 20px; | ||
padding: 5px 0; | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
there is a missing EOF
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
done
Signed-off-by: Oleksii Orel <oorel@redhat.com>
Signed-off-by: Oleksii Orel <oorel@redhat.com>
Signed-off-by: Oleksii Orel <oorel@redhat.com>
Signed-off-by: Oleksii Orel <oorel@redhat.com>
Signed-off-by: Oleksii Orel <oorel@redhat.com>
Signed-off-by: Oleksii Orel <oorel@redhat.com>
Signed-off-by: Oleksii Orel <oorel@redhat.com>
Signed-off-by: Oleksii Orel <oorel@redhat.com>
Add notification manager API to the new plugin system.
Discussion about architecture and principles can be found here: eclipse-theia#1482
This API allows implementation of notifications to show an information message. Optionally provide an array of items which will be presented as clickable buttons and can be shown using the showInformationMessage,
showWarningMessage and showErrorMessage functions.
Simple example that show an information message:
Simple example that show an information message with buttons:
eclipse-che/che#9525
Both kind of notifications with buttons:
Signed-off-by: Oleksii Orel oorel@redhat.com