mirror of
https://github.com/ckaczor/azuredatastudio.git
synced 2026-02-17 02:51:36 -05:00
Merge from vscode 4c9161a3f125f5a788aafa73a4ecfcb27dcfc319 (#9143)
* Merge from vscode 4c9161a3f125f5a788aafa73a4ecfcb27dcfc319 * minor spacing fix
This commit is contained in:
@@ -19,6 +19,7 @@ import { FuzzyScore, createMatches } from 'vs/base/common/filters';
|
||||
import { LinkDetector } from 'vs/workbench/contrib/debug/browser/linkDetector';
|
||||
import { ReplEvaluationResult } from 'vs/workbench/contrib/debug/common/replModel';
|
||||
import { once } from 'vs/base/common/functional';
|
||||
import { ViewPane } from 'vs/workbench/browser/parts/views/viewPaneContainer';
|
||||
|
||||
export const MAX_VALUE_RENDER_LENGTH_IN_VIEWLET = 1024;
|
||||
export const twistiePixels = 20;
|
||||
@@ -232,3 +233,11 @@ export abstract class AbstractExpressionsRenderer implements ITreeRenderer<IExpr
|
||||
templateData.toDispose.dispose();
|
||||
}
|
||||
}
|
||||
|
||||
export abstract class BaseDebugViewPane extends ViewPane {
|
||||
|
||||
render(): void {
|
||||
super.render();
|
||||
dom.addClass(this.element, 'debug-pane');
|
||||
}
|
||||
}
|
||||
|
||||
@@ -28,13 +28,14 @@ import { attachInputBoxStyler } from 'vs/platform/theme/common/styler';
|
||||
import { isCodeEditor } from 'vs/editor/browser/editorBrowser';
|
||||
import { IConfigurationService } from 'vs/platform/configuration/common/configuration';
|
||||
import { IEditorService, SIDE_GROUP, ACTIVE_GROUP } from 'vs/workbench/services/editor/common/editorService';
|
||||
import { ViewPane, IViewPaneOptions } from 'vs/workbench/browser/parts/views/viewPaneContainer';
|
||||
import { IViewPaneOptions } from 'vs/workbench/browser/parts/views/viewPaneContainer';
|
||||
import { ILabelService } from 'vs/platform/label/common/label';
|
||||
import { IContextKeyService } from 'vs/platform/contextkey/common/contextkey';
|
||||
import { Gesture } from 'vs/base/browser/touch';
|
||||
import { IViewDescriptorService } from 'vs/workbench/common/views';
|
||||
import { TextEditorSelectionRevealType } from 'vs/platform/editor/common/editor';
|
||||
import { IOpenerService } from 'vs/platform/opener/common/opener';
|
||||
import { BaseDebugViewPane } from 'vs/workbench/contrib/debug/browser/baseDebugView';
|
||||
|
||||
const $ = dom.$;
|
||||
|
||||
@@ -53,7 +54,7 @@ export function getExpandedBodySize(model: IDebugModel): number {
|
||||
return Math.min(MAX_VISIBLE_BREAKPOINTS, length) * 22;
|
||||
}
|
||||
|
||||
export class BreakpointsView extends ViewPane {
|
||||
export class BreakpointsView extends BaseDebugViewPane {
|
||||
|
||||
private list!: WorkbenchList<IEnablement>;
|
||||
private needsRefresh = false;
|
||||
@@ -153,12 +154,6 @@ export class BreakpointsView extends ViewPane {
|
||||
this.onBreakpointsChange();
|
||||
}
|
||||
}));
|
||||
|
||||
this._register(this.viewDescriptorService.onDidChangeLocation(({ views, from, to }) => {
|
||||
if (views.some(v => v.id === this.id)) {
|
||||
this.list.updateOptions({ overrideStyles: { listBackground: this.getBackgroundColor() } });
|
||||
}
|
||||
}));
|
||||
}
|
||||
|
||||
public focus(): void {
|
||||
|
||||
@@ -13,12 +13,12 @@ import { IContextMenuService } from 'vs/platform/contextview/browser/contextView
|
||||
import { IInstantiationService } from 'vs/platform/instantiation/common/instantiation';
|
||||
import { MenuId, IMenu, IMenuService } from 'vs/platform/actions/common/actions';
|
||||
import { IKeybindingService } from 'vs/platform/keybinding/common/keybinding';
|
||||
import { renderViewTree } from 'vs/workbench/contrib/debug/browser/baseDebugView';
|
||||
import { renderViewTree, BaseDebugViewPane } from 'vs/workbench/contrib/debug/browser/baseDebugView';
|
||||
import { IAction, Action } from 'vs/base/common/actions';
|
||||
import { IEditorService } from 'vs/workbench/services/editor/common/editorService';
|
||||
import { IConfigurationService } from 'vs/platform/configuration/common/configuration';
|
||||
import { IContextKey, IContextKeyService } from 'vs/platform/contextkey/common/contextkey';
|
||||
import { IViewPaneOptions, ViewPane } from 'vs/workbench/browser/parts/views/viewPaneContainer';
|
||||
import { IViewPaneOptions } from 'vs/workbench/browser/parts/views/viewPaneContainer';
|
||||
import { ILabelService } from 'vs/platform/label/common/label';
|
||||
import { IAccessibilityProvider } from 'vs/base/browser/ui/list/listWidget';
|
||||
import { createAndFillInContextMenuActions } from 'vs/platform/actions/browser/menuEntryActionViewItem';
|
||||
@@ -74,7 +74,7 @@ export function getContextForContributedActions(element: CallStackItem | null):
|
||||
return '';
|
||||
}
|
||||
|
||||
export class CallStackView extends ViewPane {
|
||||
export class CallStackView extends BaseDebugViewPane {
|
||||
private pauseMessage!: HTMLSpanElement;
|
||||
private pauseMessageLabel!: HTMLSpanElement;
|
||||
private onCallStackChangeScheduler: RunOnceScheduler;
|
||||
@@ -298,12 +298,6 @@ export class CallStackView extends ViewPane {
|
||||
this.parentSessionToExpand.add(s.parentSession);
|
||||
}
|
||||
}));
|
||||
|
||||
this._register(this.viewDescriptorService.onDidChangeLocation(({ views, from, to }) => {
|
||||
if (views.some(v => v.id === this.id)) {
|
||||
this.tree.updateOptions({ overrideStyles: { listBackground: this.getBackgroundColor() } });
|
||||
}
|
||||
}));
|
||||
}
|
||||
|
||||
layoutBody(height: number, width: number): void {
|
||||
|
||||
@@ -165,7 +165,7 @@ export class DebugService implements IDebugService {
|
||||
this.debugUx.set(!!(this.state !== State.Inactive || this.configurationManager.selectedConfiguration.name) ? 'default' : 'simple');
|
||||
}));
|
||||
this.toDispose.push(this.model.onDidChangeCallStack(() => {
|
||||
const numberOfSessions = this.model.getSessions().length;
|
||||
const numberOfSessions = this.model.getSessions().filter(s => !s.parentSession).length;
|
||||
if (this.activity) {
|
||||
this.activity.dispose();
|
||||
}
|
||||
|
||||
@@ -72,7 +72,7 @@ export class DebugTaskRunner {
|
||||
await this.viewsService.openView(Constants.MARKERS_VIEW_ID);
|
||||
return Promise.resolve(TaskRunResult.Failure);
|
||||
}
|
||||
if (onTaskErrors === 'cancel') {
|
||||
if (onTaskErrors === 'abort') {
|
||||
return Promise.resolve(TaskRunResult.Failure);
|
||||
}
|
||||
|
||||
@@ -85,7 +85,7 @@ export class DebugTaskRunner {
|
||||
? nls.localize('preLaunchTaskExitCode', "The preLaunchTask '{0}' terminated with exit code {1}.", taskLabel, taskSummary.exitCode)
|
||||
: nls.localize('preLaunchTaskTerminated', "The preLaunchTask '{0}' terminated.", taskLabel);
|
||||
|
||||
const result = await this.dialogService.show(severity.Warning, message, [nls.localize('debugAnyway', "Debug Anyway"), nls.localize('showErrors', "Show Errors"), nls.localize('cancel', "Cancel")], {
|
||||
const result = await this.dialogService.show(severity.Warning, message, [nls.localize('debugAnyway', "Debug Anyway"), nls.localize('showErrors', "Show Errors"), nls.localize('abort', "Abort")], {
|
||||
checkbox: {
|
||||
label: nls.localize('remember', "Remember my choice in user settings"),
|
||||
},
|
||||
@@ -94,12 +94,12 @@ export class DebugTaskRunner {
|
||||
|
||||
|
||||
const debugAnyway = result.choice === 0;
|
||||
const cancel = result.choice = 2;
|
||||
const abort = result.choice === 2;
|
||||
if (result.checkboxChecked) {
|
||||
this.configurationService.updateValue('debug.onTaskErrors', result.choice === 0 ? 'debugAnyway' : cancel ? 'cancel' : 'showErrors');
|
||||
this.configurationService.updateValue('debug.onTaskErrors', result.choice === 0 ? 'debugAnyway' : abort ? 'abort' : 'showErrors');
|
||||
}
|
||||
|
||||
if (cancel) {
|
||||
if (abort) {
|
||||
return Promise.resolve(TaskRunResult.Failure);
|
||||
}
|
||||
if (debugAnyway) {
|
||||
|
||||
@@ -7,12 +7,12 @@ import * as nls from 'vs/nls';
|
||||
import * as dom from 'vs/base/browser/dom';
|
||||
import { IViewletViewOptions } from 'vs/workbench/browser/parts/views/viewsViewlet';
|
||||
import { normalize, isAbsolute, posix } from 'vs/base/common/path';
|
||||
import { IViewPaneOptions, ViewPane } from 'vs/workbench/browser/parts/views/viewPaneContainer';
|
||||
import { IViewPaneOptions } from 'vs/workbench/browser/parts/views/viewPaneContainer';
|
||||
import { IContextMenuService } from 'vs/platform/contextview/browser/contextView';
|
||||
import { IKeybindingService } from 'vs/platform/keybinding/common/keybinding';
|
||||
import { IInstantiationService } from 'vs/platform/instantiation/common/instantiation';
|
||||
import { IConfigurationService } from 'vs/platform/configuration/common/configuration';
|
||||
import { renderViewTree } from 'vs/workbench/contrib/debug/browser/baseDebugView';
|
||||
import { renderViewTree, BaseDebugViewPane } from 'vs/workbench/contrib/debug/browser/baseDebugView';
|
||||
import { IDebugSession, IDebugService, CONTEXT_LOADED_SCRIPTS_ITEM_TYPE } from 'vs/workbench/contrib/debug/common/debug';
|
||||
import { Source } from 'vs/workbench/contrib/debug/common/debugSource';
|
||||
import { IWorkspaceContextService, IWorkspaceFolder } from 'vs/platform/workspace/common/workspace';
|
||||
@@ -402,7 +402,7 @@ function asTreeElement(item: BaseTreeItem, viewState?: IViewState): ITreeElement
|
||||
};
|
||||
}
|
||||
|
||||
export class LoadedScriptsView extends ViewPane {
|
||||
export class LoadedScriptsView extends BaseDebugViewPane {
|
||||
|
||||
private treeContainer!: HTMLElement;
|
||||
private loadedScriptsItemType: IContextKey<string>;
|
||||
@@ -573,12 +573,6 @@ export class LoadedScriptsView extends ViewPane {
|
||||
}
|
||||
}));
|
||||
|
||||
this._register(this.viewDescriptorService.onDidChangeLocation(({ views, from, to }) => {
|
||||
if (views.some(v => v.id === this.id)) {
|
||||
this.tree.updateOptions({ overrideStyles: { listBackground: this.getBackgroundColor() } });
|
||||
}
|
||||
}));
|
||||
|
||||
// feature: expand all nodes when filtering (not when finding)
|
||||
let viewState: IViewState | undefined;
|
||||
this._register(this.tree.onDidChangeTypeFilterPattern(pattern => {
|
||||
|
||||
@@ -5,7 +5,7 @@
|
||||
|
||||
/* Debug viewlet */
|
||||
|
||||
.debug-viewlet {
|
||||
.debug-pane {
|
||||
height: 100%;
|
||||
}
|
||||
|
||||
@@ -13,27 +13,27 @@
|
||||
height: 100%;
|
||||
}
|
||||
|
||||
.debug-viewlet .debug-start-view {
|
||||
.debug-pane .debug-start-view {
|
||||
padding: 0 20px 0 20px;
|
||||
}
|
||||
|
||||
.debug-viewlet .debug-start-view .monaco-button,
|
||||
.debug-viewlet .debug-start-view .section {
|
||||
.debug-pane .debug-start-view .monaco-button,
|
||||
.debug-pane .debug-start-view .section {
|
||||
margin-top: 20px;
|
||||
}
|
||||
|
||||
.debug-viewlet .debug-start-view .top-section {
|
||||
.debug-pane .debug-start-view .top-section {
|
||||
margin-top: 10px;
|
||||
}
|
||||
|
||||
.debug-viewlet .debug-start-view .monaco-button {
|
||||
.debug-pane .debug-start-view .monaco-button {
|
||||
max-width: 260px;
|
||||
margin-left: auto;
|
||||
margin-right: auto;
|
||||
display: block;
|
||||
}
|
||||
|
||||
.debug-viewlet .debug-start-view .click {
|
||||
.debug-pane .debug-start-view .click {
|
||||
cursor: pointer;
|
||||
color: #007ACC;
|
||||
}
|
||||
@@ -87,7 +87,7 @@
|
||||
|
||||
/* Debug viewlet trees */
|
||||
|
||||
.debug-viewlet .line-number {
|
||||
.debug-pane .line-number {
|
||||
background: rgba(136, 136, 136, 0.3);
|
||||
border-radius: 2px;
|
||||
font-size: 0.9em;
|
||||
@@ -95,29 +95,29 @@
|
||||
line-height: 20px;
|
||||
}
|
||||
|
||||
.debug-viewlet .monaco-list-row.selected .line-number,
|
||||
.debug-viewlet .monaco-list-row.selected .thread > .state > .label,
|
||||
.debug-viewlet .monaco-list-row.selected .session > .state > .label {
|
||||
.debug-pane .monaco-list-row.selected .line-number,
|
||||
.debug-pane .monaco-list-row.selected .thread > .state > .label,
|
||||
.debug-pane .monaco-list-row.selected .session > .state > .label {
|
||||
background-color: #ffffff;
|
||||
color: #666;
|
||||
}
|
||||
|
||||
.debug-viewlet .monaco-list:focus .monaco-list-row.selected.focused .codicon {
|
||||
.debug-pane .monaco-list:focus .monaco-list-row.selected.focused .codicon {
|
||||
color: inherit !important;
|
||||
}
|
||||
|
||||
.debug-viewlet .disabled {
|
||||
.debug-pane .disabled {
|
||||
opacity: 0.65;
|
||||
}
|
||||
|
||||
/* Call stack */
|
||||
|
||||
.debug-viewlet .debug-call-stack-title {
|
||||
.debug-pane .debug-call-stack-title {
|
||||
display: flex;
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
.debug-viewlet .debug-call-stack-title > .pause-message {
|
||||
.debug-pane .debug-call-stack-title > .pause-message {
|
||||
flex: 1;
|
||||
text-align: right;
|
||||
text-overflow: ellipsis;
|
||||
@@ -126,41 +126,41 @@
|
||||
margin: 0px 10px;
|
||||
}
|
||||
|
||||
.debug-viewlet .debug-call-stack-title > .pause-message > .label {
|
||||
.debug-pane .debug-call-stack-title > .pause-message > .label {
|
||||
border-radius: 3px;
|
||||
padding: 1px 2px;
|
||||
font-size: 9px;
|
||||
}
|
||||
|
||||
.debug-viewlet .debug-call-stack-title > .pause-message > .label.exception {
|
||||
.debug-pane .debug-call-stack-title > .pause-message > .label.exception {
|
||||
background-color: #A31515;
|
||||
color: rgb(255, 255, 255);
|
||||
}
|
||||
|
||||
.vs-dark .debug-viewlet .debug-call-stack-title > .pause-message > .label.exception {
|
||||
.vs-dark .debug-pane .debug-call-stack-title > .pause-message > .label.exception {
|
||||
background-color: #6C2022;
|
||||
color: inherit;
|
||||
}
|
||||
|
||||
.hc-black .debug-viewlet .debug-call-stack-title > .pause-message > .label.exception {
|
||||
.hc-black .debug-pane .debug-call-stack-title > .pause-message > .label.exception {
|
||||
background-color: #6C2022;
|
||||
color: inherit;
|
||||
}
|
||||
|
||||
.debug-viewlet .debug-call-stack .thread,
|
||||
.debug-viewlet .debug-call-stack .session {
|
||||
.debug-pane .debug-call-stack .thread,
|
||||
.debug-pane .debug-call-stack .session {
|
||||
display: flex;
|
||||
}
|
||||
|
||||
.debug-viewlet .debug-call-stack .thread > .name,
|
||||
.debug-viewlet .debug-call-stack .session > .name {
|
||||
.debug-pane .debug-call-stack .thread > .name,
|
||||
.debug-pane .debug-call-stack .session > .name {
|
||||
flex: 1;
|
||||
overflow: hidden;
|
||||
text-overflow: ellipsis;
|
||||
}
|
||||
|
||||
.debug-viewlet .debug-call-stack .thread > .state,
|
||||
.debug-viewlet .debug-call-stack .session > .state {
|
||||
.debug-pane .debug-call-stack .thread > .state,
|
||||
.debug-pane .debug-call-stack .session > .state {
|
||||
text-align: right;
|
||||
overflow: hidden;
|
||||
text-overflow: ellipsis;
|
||||
@@ -168,116 +168,116 @@
|
||||
text-transform: uppercase;
|
||||
}
|
||||
|
||||
.debug-viewlet .debug-call-stack .monaco-list-row:hover .state {
|
||||
.debug-pane .debug-call-stack .monaco-list-row:hover .state {
|
||||
display: none;
|
||||
}
|
||||
|
||||
.debug-viewlet .debug-call-stack .monaco-list-row:hover .stack-frame.has-actions .file .line-number {
|
||||
.debug-pane .debug-call-stack .monaco-list-row:hover .stack-frame.has-actions .file .line-number {
|
||||
display: none;
|
||||
}
|
||||
|
||||
.debug-viewlet .debug-call-stack .monaco-list-row .monaco-action-bar {
|
||||
.debug-pane .debug-call-stack .monaco-list-row .monaco-action-bar {
|
||||
display: none;
|
||||
}
|
||||
|
||||
.debug-viewlet .debug-call-stack .monaco-list-row:hover .monaco-action-bar {
|
||||
.debug-pane .debug-call-stack .monaco-list-row:hover .monaco-action-bar {
|
||||
display: initial;
|
||||
}
|
||||
|
||||
.monaco-workbench .debug-viewlet .debug-call-stack .monaco-action-bar .action-item > .action-label {
|
||||
.monaco-workbench .debug-pane .debug-call-stack .monaco-action-bar .action-item > .action-label {
|
||||
width: 16px;
|
||||
height: 100%;
|
||||
margin-right: 8px;
|
||||
vertical-align: text-top;
|
||||
}
|
||||
|
||||
.debug-viewlet .debug-call-stack .thread > .state > .label,
|
||||
.debug-viewlet .debug-call-stack .session > .state > .label {
|
||||
.debug-pane .debug-call-stack .thread > .state > .label,
|
||||
.debug-pane .debug-call-stack .session > .state > .label {
|
||||
background: rgba(136, 136, 136, 0.3);
|
||||
border-radius: 2px;
|
||||
font-size: 0.8em;
|
||||
padding: 0 3px;
|
||||
}
|
||||
|
||||
.debug-viewlet .debug-call-stack .stack-frame {
|
||||
.debug-pane .debug-call-stack .stack-frame {
|
||||
overflow: hidden;
|
||||
text-overflow: ellipsis;
|
||||
padding-right: 0.8em;
|
||||
display: flex;
|
||||
}
|
||||
|
||||
.debug-viewlet .debug-call-stack .stack-frame.label {
|
||||
.debug-pane .debug-call-stack .stack-frame.label {
|
||||
text-align: center;
|
||||
font-style: italic;
|
||||
}
|
||||
|
||||
.debug-viewlet .debug-call-stack .stack-frame .label {
|
||||
.debug-pane .debug-call-stack .stack-frame .label {
|
||||
flex: 1;
|
||||
flex-shrink: 0;
|
||||
min-width: fit-content;
|
||||
min-width: -moz-fit-content;
|
||||
}
|
||||
|
||||
.debug-viewlet .debug-call-stack .stack-frame.subtle {
|
||||
.debug-pane .debug-call-stack .stack-frame.subtle {
|
||||
font-style: italic;
|
||||
}
|
||||
|
||||
.debug-viewlet .debug-call-stack .stack-frame.label > .file {
|
||||
.debug-pane .debug-call-stack .stack-frame.label > .file {
|
||||
display: none;
|
||||
}
|
||||
|
||||
.debug-viewlet .debug-call-stack .stack-frame > .file {
|
||||
.debug-pane .debug-call-stack .stack-frame > .file {
|
||||
display: flex;
|
||||
overflow: hidden;
|
||||
flex-wrap: wrap;
|
||||
justify-content: flex-end;
|
||||
}
|
||||
|
||||
.debug-viewlet .debug-call-stack .stack-frame > .file > .line-number.unavailable {
|
||||
.debug-pane .debug-call-stack .stack-frame > .file > .line-number.unavailable {
|
||||
display: none;
|
||||
}
|
||||
|
||||
.debug-viewlet .debug-call-stack .monaco-list-row:not(.selected) .stack-frame > .file {
|
||||
.debug-pane .debug-call-stack .monaco-list-row:not(.selected) .stack-frame > .file {
|
||||
color: rgba(108, 108, 108, 0.8);
|
||||
}
|
||||
|
||||
.debug-viewlet .debug-call-stack .stack-frame > .file > .file-name {
|
||||
.debug-pane .debug-call-stack .stack-frame > .file > .file-name {
|
||||
overflow: hidden;
|
||||
text-overflow: ellipsis;
|
||||
margin-right: 0.8em;
|
||||
}
|
||||
|
||||
.vs-dark .debug-viewlet .debug-call-stack .monaco-list-row:not(.selected) .stack-frame > .file {
|
||||
.vs-dark .debug-pane .debug-call-stack .monaco-list-row:not(.selected) .stack-frame > .file {
|
||||
color: rgba(204, 204, 204, 0.6);
|
||||
}
|
||||
|
||||
.debug-viewlet .debug-call-stack .stack-frame > .file:not(:first-child) {
|
||||
.debug-pane .debug-call-stack .stack-frame > .file:not(:first-child) {
|
||||
margin-left: 0.8em;
|
||||
}
|
||||
|
||||
.debug-viewlet .debug-call-stack .load-more {
|
||||
.debug-pane .debug-call-stack .load-more {
|
||||
font-style: italic;
|
||||
text-align: center;
|
||||
}
|
||||
|
||||
.debug-viewlet .debug-call-stack .show-more {
|
||||
.debug-pane .debug-call-stack .show-more {
|
||||
font-style: italic;
|
||||
opacity: 0.35;
|
||||
}
|
||||
|
||||
.debug-viewlet .debug-call-stack .error {
|
||||
.debug-pane .debug-call-stack .error {
|
||||
font-style: italic;
|
||||
text-overflow: ellipsis;
|
||||
overflow: hidden;
|
||||
}
|
||||
|
||||
.debug-viewlet .debug-call-stack .monaco-list:focus .monaco-list-row.selected .codicon {
|
||||
.debug-pane .debug-call-stack .monaco-list:focus .monaco-list-row.selected .codicon {
|
||||
color: inherit !important;
|
||||
}
|
||||
|
||||
/* Variables & Expression view */
|
||||
|
||||
.debug-viewlet .scope {
|
||||
.debug-pane .scope {
|
||||
font-weight: bold;
|
||||
font-size: 11px;
|
||||
}
|
||||
@@ -295,7 +295,7 @@
|
||||
100% { background-color: rgba(86, 156, 214, .2) }
|
||||
}
|
||||
|
||||
.debug-viewlet .monaco-list-row .expression .value.changed {
|
||||
.debug-pane .monaco-list-row .expression .value.changed {
|
||||
padding: 2px;
|
||||
margin: 4px;
|
||||
border-radius: 4px;
|
||||
@@ -305,67 +305,67 @@
|
||||
animation-fill-mode: forwards;
|
||||
}
|
||||
|
||||
.debug-viewlet .monaco-inputbox {
|
||||
.debug-pane .monaco-inputbox {
|
||||
width: 100%;
|
||||
line-height: normal;
|
||||
}
|
||||
|
||||
.debug-viewlet .inputBoxContainer {
|
||||
.debug-pane .inputBoxContainer {
|
||||
box-sizing: border-box;
|
||||
flex-grow: 1;
|
||||
}
|
||||
|
||||
.debug-viewlet .debug-watch .monaco-inputbox {
|
||||
.debug-pane .debug-watch .monaco-inputbox {
|
||||
font-family: var(--monaco-monospace-font);
|
||||
}
|
||||
|
||||
.debug-viewlet .monaco-inputbox > .wrapper {
|
||||
.debug-pane .monaco-inputbox > .wrapper {
|
||||
height: 19px;
|
||||
}
|
||||
|
||||
.debug-viewlet .monaco-inputbox > .wrapper > .input {
|
||||
.debug-pane .monaco-inputbox > .wrapper > .input {
|
||||
padding: 0px;
|
||||
color: initial;
|
||||
}
|
||||
|
||||
.debug-viewlet .watch-expression {
|
||||
.debug-pane .watch-expression {
|
||||
display: flex;
|
||||
}
|
||||
|
||||
.debug-viewlet .watch-expression .expression {
|
||||
.debug-pane .watch-expression .expression {
|
||||
flex : 1;
|
||||
}
|
||||
|
||||
.vs-dark .debug-viewlet .monaco-list-row .expression .value.changed {
|
||||
.vs-dark .debug-pane .monaco-list-row .expression .value.changed {
|
||||
animation-name: debugViewletValueChanged;
|
||||
}
|
||||
|
||||
/* Breakpoints */
|
||||
|
||||
.debug-viewlet .monaco-list-row {
|
||||
.debug-pane .monaco-list-row {
|
||||
line-height: 22px;
|
||||
}
|
||||
|
||||
.debug-viewlet .debug-breakpoints .monaco-list-row .breakpoint {
|
||||
.debug-pane .debug-breakpoints .monaco-list-row .breakpoint {
|
||||
padding-left: 2px;
|
||||
}
|
||||
|
||||
.debug-viewlet .debug-breakpoints .breakpoint.exception {
|
||||
.debug-pane .debug-breakpoints .breakpoint.exception {
|
||||
padding-left: 20px;
|
||||
}
|
||||
|
||||
.debug-viewlet .debug-breakpoints .breakpoint {
|
||||
.debug-pane .debug-breakpoints .breakpoint {
|
||||
display: flex;
|
||||
padding-right: 0.8em;
|
||||
flex: 1;
|
||||
align-items: center;
|
||||
}
|
||||
|
||||
.debug-viewlet .debug-breakpoints .breakpoint input {
|
||||
.debug-pane .debug-breakpoints .breakpoint input {
|
||||
flex-shrink: 0;
|
||||
}
|
||||
|
||||
.debug-viewlet .debug-breakpoints .breakpoint > .codicon {
|
||||
.debug-pane .debug-breakpoints .breakpoint > .codicon {
|
||||
width: 19px;
|
||||
height: 19px;
|
||||
min-width: 19px;
|
||||
@@ -374,7 +374,7 @@
|
||||
justify-content: center;
|
||||
}
|
||||
|
||||
.debug-viewlet .debug-breakpoints .breakpoint > .file-path {
|
||||
.debug-pane .debug-breakpoints .breakpoint > .file-path {
|
||||
opacity: 0.7;
|
||||
font-size: 0.9em;
|
||||
margin-left: 0.8em;
|
||||
@@ -383,7 +383,7 @@
|
||||
overflow: hidden;
|
||||
}
|
||||
|
||||
.debug-viewlet .debug-breakpoints .breakpoint .name {
|
||||
.debug-pane .debug-breakpoints .breakpoint .name {
|
||||
overflow: hidden;
|
||||
text-overflow: ellipsis
|
||||
}
|
||||
|
||||
@@ -12,12 +12,12 @@ import { IDebugService, IExpression, IScope, CONTEXT_VARIABLES_FOCUSED, IViewMod
|
||||
import { Variable, Scope } from 'vs/workbench/contrib/debug/common/debugModel';
|
||||
import { IContextMenuService } from 'vs/platform/contextview/browser/contextView';
|
||||
import { IKeybindingService } from 'vs/platform/keybinding/common/keybinding';
|
||||
import { renderViewTree, renderVariable, IInputBoxOptions, AbstractExpressionsRenderer, IExpressionTemplateData } from 'vs/workbench/contrib/debug/browser/baseDebugView';
|
||||
import { renderViewTree, renderVariable, IInputBoxOptions, AbstractExpressionsRenderer, IExpressionTemplateData, BaseDebugViewPane } from 'vs/workbench/contrib/debug/browser/baseDebugView';
|
||||
import { IAction, Action } from 'vs/base/common/actions';
|
||||
import { CopyValueAction } from 'vs/workbench/contrib/debug/browser/debugActions';
|
||||
import { Separator } from 'vs/base/browser/ui/actionbar/actionbar';
|
||||
import { IConfigurationService } from 'vs/platform/configuration/common/configuration';
|
||||
import { IViewPaneOptions, ViewPane } from 'vs/workbench/browser/parts/views/viewPaneContainer';
|
||||
import { IViewPaneOptions } from 'vs/workbench/browser/parts/views/viewPaneContainer';
|
||||
import { IAccessibilityProvider } from 'vs/base/browser/ui/list/listWidget';
|
||||
import { IListVirtualDelegate } from 'vs/base/browser/ui/list/list';
|
||||
import { ITreeRenderer, ITreeNode, ITreeMouseEvent, ITreeContextMenuEvent, IAsyncDataSource } from 'vs/base/browser/ui/tree/tree';
|
||||
@@ -39,7 +39,7 @@ let forgetScopes = true;
|
||||
|
||||
export const variableSetEmitter = new Emitter<void>();
|
||||
|
||||
export class VariablesView extends ViewPane {
|
||||
export class VariablesView extends BaseDebugViewPane {
|
||||
|
||||
private onFocusStackFrameScheduler: RunOnceScheduler;
|
||||
private needsRefresh = false;
|
||||
@@ -143,11 +143,6 @@ export class VariablesView extends ViewPane {
|
||||
this.tree.rerender(e);
|
||||
}
|
||||
}));
|
||||
this._register(this.viewDescriptorService.onDidChangeLocation(({ views, from, to }) => {
|
||||
if (views.some(v => v.id === this.id)) {
|
||||
this.tree.updateOptions({ overrideStyles: { listBackground: this.getBackgroundColor() } });
|
||||
}
|
||||
}));
|
||||
}
|
||||
|
||||
getActions(): IAction[] {
|
||||
|
||||
@@ -16,9 +16,9 @@ import { IInstantiationService } from 'vs/platform/instantiation/common/instanti
|
||||
import { IKeybindingService } from 'vs/platform/keybinding/common/keybinding';
|
||||
import { IAction, Action } from 'vs/base/common/actions';
|
||||
import { Separator } from 'vs/base/browser/ui/actionbar/actionbar';
|
||||
import { renderExpressionValue, renderViewTree, IInputBoxOptions, AbstractExpressionsRenderer, IExpressionTemplateData } from 'vs/workbench/contrib/debug/browser/baseDebugView';
|
||||
import { renderExpressionValue, renderViewTree, IInputBoxOptions, AbstractExpressionsRenderer, IExpressionTemplateData, BaseDebugViewPane } from 'vs/workbench/contrib/debug/browser/baseDebugView';
|
||||
import { IConfigurationService } from 'vs/platform/configuration/common/configuration';
|
||||
import { IViewPaneOptions, ViewPane } from 'vs/workbench/browser/parts/views/viewPaneContainer';
|
||||
import { IViewPaneOptions } from 'vs/workbench/browser/parts/views/viewPaneContainer';
|
||||
import { IListVirtualDelegate } from 'vs/base/browser/ui/list/list';
|
||||
import { IAccessibilityProvider } from 'vs/base/browser/ui/list/listWidget';
|
||||
import { WorkbenchAsyncDataTree } from 'vs/platform/list/browser/listService';
|
||||
@@ -38,7 +38,7 @@ const MAX_VALUE_RENDER_LENGTH_IN_VIEWLET = 1024;
|
||||
let ignoreVariableSetEmitter = false;
|
||||
let useCachedEvaluation = false;
|
||||
|
||||
export class WatchExpressionsView extends ViewPane {
|
||||
export class WatchExpressionsView extends BaseDebugViewPane {
|
||||
|
||||
private onWatchExpressionsUpdatedScheduler: RunOnceScheduler;
|
||||
private needsRefresh = false;
|
||||
@@ -138,11 +138,6 @@ export class WatchExpressionsView extends ViewPane {
|
||||
this.tree.rerender(e);
|
||||
}
|
||||
}));
|
||||
this._register(this.viewDescriptorService.onDidChangeLocation(({ views, from, to }) => {
|
||||
if (views.some(v => v.id === this.id)) {
|
||||
this.tree.updateOptions({ overrideStyles: { listBackground: this.getBackgroundColor() } });
|
||||
}
|
||||
}));
|
||||
}
|
||||
|
||||
layoutBody(height: number, width: number): void {
|
||||
|
||||
@@ -467,7 +467,7 @@ export interface IDebugConfiguration {
|
||||
closeOnEnd: boolean;
|
||||
};
|
||||
focusWindowOnBreak: boolean;
|
||||
onTaskErrors: 'debugAnyway' | 'showErrors' | 'prompt' | 'cancel';
|
||||
onTaskErrors: 'debugAnyway' | 'showErrors' | 'prompt' | 'abort';
|
||||
showBreakpointsInOverviewRuler: boolean;
|
||||
showInlineBreakpointCandidates: boolean;
|
||||
}
|
||||
|
||||
@@ -73,7 +73,7 @@ export class Source {
|
||||
|
||||
openInEditor(editorService: IEditorService, selection: IRange, preserveFocus?: boolean, sideBySide?: boolean, pinned?: boolean): Promise<ITextEditor | undefined> {
|
||||
return !this.available ? Promise.resolve(undefined) : editorService.openEditor({
|
||||
resource: this.uri.with({ query: null }),
|
||||
resource: this.uri,
|
||||
description: this.origin,
|
||||
options: {
|
||||
preserveFocus,
|
||||
|
||||
@@ -94,7 +94,8 @@ export function prepareCommand(args: DebugProtocol.RunInTerminalRequestArguments
|
||||
}
|
||||
|
||||
let quote: (s: string) => string;
|
||||
let command = '';
|
||||
// begin command with a space to avoid polluting shell history
|
||||
let command = ' ';
|
||||
|
||||
switch (shellType) {
|
||||
|
||||
|
||||
@@ -108,6 +108,7 @@ export class ExplorerViewletViewsContribution extends Disposable implements IWor
|
||||
order: 0,
|
||||
when: OpenEditorsVisibleContext,
|
||||
canToggleVisibility: true,
|
||||
canMoveView: true,
|
||||
focusCommand: {
|
||||
id: 'workbench.files.action.focusOpenEditorsView',
|
||||
keybindings: { primary: KeyChord(KeyMod.CtrlCmd | KeyCode.KEY_K, KeyCode.KEY_E) }
|
||||
|
||||
@@ -19,7 +19,6 @@
|
||||
}
|
||||
|
||||
.explorer-viewlet .explorer-item,
|
||||
.explorer-viewlet .open-editor,
|
||||
.explorer-viewlet .editor-group {
|
||||
height: 22px;
|
||||
line-height: 22px;
|
||||
@@ -31,7 +30,6 @@
|
||||
}
|
||||
|
||||
.explorer-viewlet .explorer-item > a,
|
||||
.explorer-viewlet .open-editor > a,
|
||||
.explorer-viewlet .editor-group {
|
||||
text-overflow: ellipsis;
|
||||
overflow: hidden;
|
||||
@@ -50,16 +48,6 @@
|
||||
flex: 0; /* do not steal space when label is hidden because we are in edit mode */
|
||||
}
|
||||
|
||||
.explorer-viewlet .explorer-open-editors .monaco-list .monaco-list-row {
|
||||
padding-left: 22px;
|
||||
display: flex;
|
||||
}
|
||||
|
||||
.explorer-viewlet .explorer-open-editors .monaco-list .monaco-list-row > .monaco-action-bar {
|
||||
visibility: hidden;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
}
|
||||
|
||||
.explorer-viewlet .pane-header .count {
|
||||
min-width: fit-content;
|
||||
@@ -72,42 +60,6 @@
|
||||
display: none;
|
||||
}
|
||||
|
||||
.explorer-viewlet .explorer-open-editors .monaco-list .monaco-list-row:hover > .monaco-action-bar,
|
||||
.explorer-viewlet .explorer-open-editors .monaco-list .monaco-list-row.focused > .monaco-action-bar,
|
||||
.explorer-viewlet .explorer-open-editors .monaco-list .monaco-list-row.dirty > .monaco-action-bar {
|
||||
visibility: visible;
|
||||
}
|
||||
|
||||
.explorer-viewlet .explorer-open-editors .monaco-list .monaco-list-row > .monaco-action-bar .action-label {
|
||||
display: block;
|
||||
}
|
||||
|
||||
.explorer-viewlet .explorer-open-editors .monaco-list .monaco-list-row > .monaco-action-bar .codicon {
|
||||
color: inherit;
|
||||
}
|
||||
|
||||
.explorer-viewlet .explorer-open-editors .monaco-list .monaco-list-row > .monaco-action-bar .codicon-close {
|
||||
width: 8px;
|
||||
height: 22px;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
}
|
||||
|
||||
.explorer-viewlet .explorer-open-editors .monaco-list .monaco-list-row > .monaco-action-bar .action-close-all-files,
|
||||
.explorer-viewlet .explorer-open-editors .monaco-list .monaco-list-row > .monaco-action-bar .save-all {
|
||||
width: 23px;
|
||||
height: 22px;
|
||||
}
|
||||
|
||||
.explorer-viewlet .explorer-open-editors .monaco-list .monaco-list-row > .open-editor {
|
||||
flex: 1;
|
||||
}
|
||||
|
||||
.explorer-viewlet .explorer-open-editors .monaco-list .monaco-list-row > .editor-group {
|
||||
flex: 1;
|
||||
}
|
||||
|
||||
.explorer-viewlet .monaco-count-badge {
|
||||
padding: 1px 6px 2px;
|
||||
margin-left: 6px;
|
||||
@@ -155,24 +107,7 @@
|
||||
height: 20px;
|
||||
}
|
||||
|
||||
.explorer-viewlet .explorer-open-editors .monaco-list .monaco-list-row .editor-group {
|
||||
font-size: 11px;
|
||||
font-weight: bold;
|
||||
text-transform: uppercase;
|
||||
cursor: default;
|
||||
}
|
||||
|
||||
/* Bold font style does not go well with CJK fonts */
|
||||
.explorer-viewlet:lang(zh-Hans) .explorer-open-editors .monaco-list .monaco-list-row .editor-group,
|
||||
.explorer-viewlet:lang(zh-Hant) .explorer-open-editors .monaco-list .monaco-list-row .editor-group,
|
||||
.explorer-viewlet:lang(ja) .explorer-open-editors .monaco-list .monaco-list-row .editor-group,
|
||||
.explorer-viewlet:lang(ko) .explorer-open-editors .monaco-list .monaco-list-row .editor-group {
|
||||
font-weight: normal;
|
||||
}
|
||||
|
||||
/* High Contrast Theming */
|
||||
.hc-black .monaco-workbench .explorer-viewlet .explorer-item,
|
||||
.hc-black .monaco-workbench .explorer-viewlet .open-editor,
|
||||
.hc-black .monaco-workbench .explorer-viewlet .editor-group {
|
||||
.hc-black .monaco-workbench .explorer-viewlet .explorer-item {
|
||||
line-height: 20px;
|
||||
}
|
||||
|
||||
@@ -50,7 +50,7 @@ export class EmptyView extends ViewPane {
|
||||
@IContextKeyService contextKeyService: IContextKeyService,
|
||||
@IOpenerService openerService: IOpenerService
|
||||
) {
|
||||
super({ ...(options as IViewPaneOptions), ariaHeaderLabel: nls.localize('explorerSection', "Files Explorer Section") }, keybindingService, contextMenuService, configurationService, contextKeyService, viewDescriptorService, instantiationService, openerService, themeService);
|
||||
super({ ...(options as IViewPaneOptions), ariaHeaderLabel: nls.localize('explorerSection', "Explorer Section: No Folder Opened") }, keybindingService, contextMenuService, configurationService, contextKeyService, viewDescriptorService, instantiationService, openerService, themeService);
|
||||
this._register(this.contextService.onDidChangeWorkbenchState(() => this.setLabels()));
|
||||
this._register(this.labelService.onDidChangeFormatters(() => this.setLabels()));
|
||||
}
|
||||
|
||||
@@ -172,7 +172,7 @@ export class ExplorerView extends ViewPane {
|
||||
@IFileService private readonly fileService: IFileService,
|
||||
@IOpenerService openerService: IOpenerService,
|
||||
) {
|
||||
super({ ...(options as IViewPaneOptions), id: ExplorerView.ID, ariaHeaderLabel: nls.localize('explorerSection', "Files Explorer Section") }, keybindingService, contextMenuService, configurationService, contextKeyService, viewDescriptorService, instantiationService, openerService, themeService);
|
||||
super({ ...(options as IViewPaneOptions), id: ExplorerView.ID, ariaHeaderLabel: nls.localize('explorerSection', "Explorer Section: {0}", labelService.getWorkspaceLabel(contextService.getWorkspace())) }, keybindingService, contextMenuService, configurationService, contextKeyService, viewDescriptorService, instantiationService, openerService, themeService);
|
||||
|
||||
this.resourceContext = instantiationService.createInstance(ResourceContextKey);
|
||||
this._register(this.resourceContext);
|
||||
@@ -229,6 +229,7 @@ export class ExplorerView extends ViewPane {
|
||||
const title = workspace.folders.map(folder => folder.name).join();
|
||||
titleElement.textContent = this.name;
|
||||
titleElement.title = title;
|
||||
titleElement.setAttribute('aria-label', nls.localize('explorerSection', "Explorer Section: {0}", this.name));
|
||||
};
|
||||
|
||||
this._register(this.contextService.onDidChangeWorkspaceName(setHeader));
|
||||
|
||||
@@ -0,0 +1,83 @@
|
||||
/*---------------------------------------------------------------------------------------------
|
||||
* Copyright (c) Microsoft Corporation. All rights reserved.
|
||||
* Licensed under the Source EULA. See License.txt in the project root for license information.
|
||||
*--------------------------------------------------------------------------------------------*/
|
||||
|
||||
.open-editors .monaco-list .monaco-list-row:hover > .monaco-action-bar,
|
||||
.open-editors .monaco-list .monaco-list-row.focused > .monaco-action-bar,
|
||||
.open-editors .monaco-list .monaco-list-row.dirty > .monaco-action-bar {
|
||||
visibility: visible;
|
||||
}
|
||||
|
||||
.open-editors .monaco-list .monaco-list-row > .monaco-action-bar .action-label {
|
||||
display: block;
|
||||
}
|
||||
|
||||
.open-editors .monaco-list .monaco-list-row > .monaco-action-bar .codicon {
|
||||
color: inherit;
|
||||
}
|
||||
|
||||
.open-editors .monaco-list .monaco-list-row > .monaco-action-bar .codicon-close {
|
||||
width: 8px;
|
||||
height: 22px;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
}
|
||||
|
||||
.open-editors .monaco-list .monaco-list-row > .monaco-action-bar .action-close-all-files,
|
||||
.open-editors .monaco-list .monaco-list-row > .monaco-action-bar .save-all {
|
||||
width: 23px;
|
||||
height: 22px;
|
||||
}
|
||||
|
||||
.open-editors .monaco-list .monaco-list-row > .open-editor {
|
||||
flex: 1;
|
||||
}
|
||||
|
||||
.open-editors .monaco-list .monaco-list-row > .editor-group {
|
||||
flex: 1;
|
||||
}
|
||||
|
||||
.open-editors .monaco-list .monaco-list-row {
|
||||
padding-left: 22px;
|
||||
display: flex;
|
||||
}
|
||||
|
||||
.open-editors .monaco-list .monaco-list-row > .monaco-action-bar {
|
||||
visibility: hidden;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
}
|
||||
|
||||
.open-editors .monaco-list .monaco-list-row .editor-group {
|
||||
font-size: 11px;
|
||||
font-weight: bold;
|
||||
text-transform: uppercase;
|
||||
cursor: default;
|
||||
}
|
||||
|
||||
/* Bold font style does not go well with CJK fonts */
|
||||
.composite:lang(zh-Hans) .open-editors .monaco-list .monaco-list-row .editor-group,
|
||||
.composite:lang(zh-Hant) .open-editors .monaco-list .monaco-list-row .editor-group,
|
||||
.composite:lang(ja) .open-editors .monaco-list .monaco-list-row .editor-group,
|
||||
.composite:lang(ko) .open-editors .monaco-list .monaco-list-row .editor-group {
|
||||
font-weight: normal;
|
||||
}
|
||||
|
||||
.open-editors .open-editor,
|
||||
.open-editors .editor-group {
|
||||
height: 22px;
|
||||
line-height: 22px;
|
||||
}
|
||||
|
||||
.open-editors .open-editor > a,
|
||||
.open-editors .editor-group {
|
||||
text-overflow: ellipsis;
|
||||
overflow: hidden;
|
||||
}
|
||||
|
||||
.hc-black .monaco-workbench .open-editors .open-editor,
|
||||
.hc-black .monaco-workbench .open-editors .editor-group {
|
||||
line-height: 20px;
|
||||
}
|
||||
@@ -3,6 +3,7 @@
|
||||
* Licensed under the Source EULA. See License.txt in the project root for license information.
|
||||
*--------------------------------------------------------------------------------------------*/
|
||||
|
||||
import 'vs/css!./media/openeditors';
|
||||
import * as nls from 'vs/nls';
|
||||
import { RunOnceScheduler } from 'vs/base/common/async';
|
||||
import { IAction, ActionRunner, WorkbenchActionExecutedEvent, WorkbenchActionExecutedClassification } from 'vs/base/common/actions';
|
||||
@@ -42,7 +43,6 @@ import { URI } from 'vs/base/common/uri';
|
||||
import { withUndefinedAsNull } from 'vs/base/common/types';
|
||||
import { isWeb } from 'vs/base/common/platform';
|
||||
import { IWorkingCopyService, IWorkingCopy, WorkingCopyCapabilities } from 'vs/workbench/services/workingCopy/common/workingCopyService';
|
||||
import { SIDE_BAR_BACKGROUND } from 'vs/workbench/common/theme';
|
||||
import { AutoSaveMode, IFilesConfigurationService } from 'vs/workbench/services/filesConfiguration/common/filesConfigurationService';
|
||||
import { IViewDescriptorService } from 'vs/workbench/common/views';
|
||||
import { IOpenerService } from 'vs/platform/opener/common/opener';
|
||||
@@ -206,7 +206,7 @@ export class OpenEditorsView extends ViewPane {
|
||||
renderBody(container: HTMLElement): void {
|
||||
super.renderBody(container);
|
||||
|
||||
dom.addClass(container, 'explorer-open-editors');
|
||||
dom.addClass(container, 'open-editors');
|
||||
dom.addClass(container, 'show-file-icons');
|
||||
|
||||
const delegate = new OpenEditorsDelegate();
|
||||
@@ -225,7 +225,7 @@ export class OpenEditorsView extends ViewPane {
|
||||
identityProvider: { getId: (element: OpenEditor | IEditorGroup) => element instanceof OpenEditor ? element.getId() : element.id.toString() },
|
||||
dnd: new OpenEditorsDragAndDrop(this.instantiationService, this.editorGroupService),
|
||||
overrideStyles: {
|
||||
listBackground: SIDE_BAR_BACKGROUND
|
||||
listBackground: this.getBackgroundColor()
|
||||
}
|
||||
});
|
||||
this._register(this.list);
|
||||
|
||||
@@ -7,8 +7,9 @@ import * as nls from 'vs/nls';
|
||||
import { Registry } from 'vs/platform/registry/common/platform';
|
||||
import { IWorkbenchActionRegistry, Extensions as WorkbenchActionExtensions } from 'vs/workbench/common/actions';
|
||||
import { SyncActionDescriptor } from 'vs/platform/actions/common/actions';
|
||||
import { OpenLogsFolderAction } from 'vs/workbench/contrib/logs/electron-browser/logsActions';
|
||||
import { OpenLogsFolderAction, OpenExtensionLogsFolderAction } from 'vs/workbench/contrib/logs/electron-browser/logsActions';
|
||||
|
||||
const workbenchActionsRegistry = Registry.as<IWorkbenchActionRegistry>(WorkbenchActionExtensions.WorkbenchActions);
|
||||
const devCategory = nls.localize('developer', "Developer");
|
||||
workbenchActionsRegistry.registerWorkbenchAction(SyncActionDescriptor.create(OpenLogsFolderAction, OpenLogsFolderAction.ID, OpenLogsFolderAction.LABEL), 'Developer: Open Logs Folder', devCategory);
|
||||
workbenchActionsRegistry.registerWorkbenchAction(SyncActionDescriptor.create(OpenExtensionLogsFolderAction, OpenExtensionLogsFolderAction.ID, OpenExtensionLogsFolderAction.LABEL), 'Developer: Open Extension Logs Folder', devCategory);
|
||||
|
||||
@@ -3,12 +3,14 @@
|
||||
* Licensed under the Source EULA. See License.txt in the project root for license information.
|
||||
*--------------------------------------------------------------------------------------------*/
|
||||
|
||||
import * as nls from 'vs/nls';
|
||||
import { Action } from 'vs/base/common/actions';
|
||||
import { join } from 'vs/base/common/path';
|
||||
import { IEnvironmentService } from 'vs/platform/environment/common/environment';
|
||||
import { URI } from 'vs/base/common/uri';
|
||||
import * as nls from 'vs/nls';
|
||||
import { IElectronService } from 'vs/platform/electron/node/electron';
|
||||
import { IEnvironmentService } from 'vs/platform/environment/common/environment';
|
||||
import { IElectronEnvironmentService } from 'vs/workbench/services/electron/electron-browser/electronEnvironmentService';
|
||||
import { IFileService } from 'vs/platform/files/common/files';
|
||||
|
||||
export class OpenLogsFolderAction extends Action {
|
||||
|
||||
@@ -26,3 +28,24 @@ export class OpenLogsFolderAction extends Action {
|
||||
return this.electronService.showItemInFolder(URI.file(join(this.environmentService.logsPath, 'main.log')).fsPath);
|
||||
}
|
||||
}
|
||||
|
||||
export class OpenExtensionLogsFolderAction extends Action {
|
||||
|
||||
static readonly ID = 'workbench.action.openExtensionLogsFolder';
|
||||
static readonly LABEL = nls.localize('openExtensionLogsFolder', "Open Extension Logs Folder");
|
||||
|
||||
constructor(id: string, label: string,
|
||||
@IElectronEnvironmentService private readonly electronEnvironmentSerice: IElectronEnvironmentService,
|
||||
@IFileService private readonly fileService: IFileService,
|
||||
@IElectronService private readonly electronService: IElectronService
|
||||
) {
|
||||
super(id, label);
|
||||
}
|
||||
|
||||
async run(): Promise<void> {
|
||||
const folderStat = await this.fileService.resolve(this.electronEnvironmentSerice.extHostLogsPath);
|
||||
if (folderStat.children && folderStat.children[0]) {
|
||||
return this.electronService.showItemInFolder(folderStat.children[0].resource.fsPath);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -18,6 +18,8 @@ import { joinPath } from 'vs/base/common/resources';
|
||||
import { Disposable } from 'vs/base/common/lifecycle';
|
||||
import { TunnelFactoryContribution } from 'vs/workbench/contrib/remote/common/tunnelFactory';
|
||||
import { ShowCandidateContribution } from 'vs/workbench/contrib/remote/common/showCandidate';
|
||||
import { IConfigurationRegistry, Extensions as ConfigurationExtensions } from 'vs/platform/configuration/common/configurationRegistry';
|
||||
import { IJSONSchema } from 'vs/base/common/jsonSchema';
|
||||
|
||||
export const VIEWLET_ID = 'workbench.view.remote';
|
||||
|
||||
@@ -90,3 +92,37 @@ workbenchContributionsRegistry.registerWorkbenchContribution(RemoteChannelsContr
|
||||
workbenchContributionsRegistry.registerWorkbenchContribution(RemoteLogOutputChannels, LifecyclePhase.Restored);
|
||||
workbenchContributionsRegistry.registerWorkbenchContribution(TunnelFactoryContribution, LifecyclePhase.Ready);
|
||||
workbenchContributionsRegistry.registerWorkbenchContribution(ShowCandidateContribution, LifecyclePhase.Ready);
|
||||
|
||||
const extensionKindSchema: IJSONSchema = {
|
||||
type: 'string',
|
||||
enum: [
|
||||
'ui',
|
||||
'workspace'
|
||||
],
|
||||
enumDescriptions: [
|
||||
localize('ui', "UI extension kind. In a remote window, such extensions are enabled only when available on the local machine."),
|
||||
localize('workspace', "Workspace extension kind. In a remote window, such extensions are enabled only when available on the remote.")
|
||||
],
|
||||
};
|
||||
|
||||
Registry.as<IConfigurationRegistry>(ConfigurationExtensions.Configuration)
|
||||
.registerConfiguration({
|
||||
id: 'remote',
|
||||
title: localize('remote', "Remote"),
|
||||
type: 'object',
|
||||
properties: {
|
||||
'remote.extensionKind': {
|
||||
type: 'object',
|
||||
markdownDescription: localize('remote.extensionKind', "Override the kind of an extension. `ui` extensions are installed and run on the local machine while `workspace` extensions are run on the remote. By overriding an extension's default kind using this setting, you specify if that extension should be installed and enabled locally or remotely."),
|
||||
patternProperties: {
|
||||
'([a-z0-9A-Z][a-z0-9\-A-Z]*)\\.([a-z0-9A-Z][a-z0-9\-A-Z]*)$': {
|
||||
oneOf: [{ type: 'array', items: extensionKindSchema }, extensionKindSchema],
|
||||
default: ['ui'],
|
||||
},
|
||||
},
|
||||
default: {
|
||||
'pub.name': ['ui']
|
||||
}
|
||||
},
|
||||
}
|
||||
});
|
||||
|
||||
@@ -38,7 +38,6 @@ import { IHostService } from 'vs/workbench/services/host/browser/host';
|
||||
import { RemoteConnectionState, Deprecated_RemoteAuthorityContext, RemoteFileDialogContext } from 'vs/workbench/browser/contextkeys';
|
||||
import { IDownloadService } from 'vs/platform/download/common/download';
|
||||
import { OpenLocalFileFolderCommand, OpenLocalFileCommand, OpenLocalFolderCommand, SaveLocalFileCommand } from 'vs/workbench/services/dialogs/browser/simpleFileDialog';
|
||||
import { IJSONSchema } from 'vs/base/common/jsonSchema';
|
||||
|
||||
const WINDOW_ACTIONS_COMMAND_ID = 'workbench.action.remote.showMenu';
|
||||
const CLOSE_REMOTE_COMMAND_ID = 'workbench.action.remote.close';
|
||||
@@ -370,37 +369,12 @@ workbenchContributionsRegistry.registerWorkbenchContribution(RemoteWindowActiveI
|
||||
workbenchContributionsRegistry.registerWorkbenchContribution(RemoteTelemetryEnablementUpdater, LifecyclePhase.Ready);
|
||||
workbenchContributionsRegistry.registerWorkbenchContribution(RemoteEmptyWorkbenchPresentation, LifecyclePhase.Starting);
|
||||
|
||||
const extensionKindSchema: IJSONSchema = {
|
||||
type: 'string',
|
||||
enum: [
|
||||
'ui',
|
||||
'workspace'
|
||||
],
|
||||
enumDescriptions: [
|
||||
nls.localize('ui', "UI extension kind. In a remote window, such extensions are enabled only when available on the local machine."),
|
||||
nls.localize('workspace', "Workspace extension kind. In a remote window, such extensions are enabled only when available on the remote.")
|
||||
],
|
||||
};
|
||||
|
||||
Registry.as<IConfigurationRegistry>(ConfigurationExtensions.Configuration)
|
||||
.registerConfiguration({
|
||||
id: 'remote',
|
||||
title: nls.localize('remote', "Remote"),
|
||||
type: 'object',
|
||||
properties: {
|
||||
'remote.extensionKind': {
|
||||
type: 'object',
|
||||
markdownDescription: nls.localize('remote.extensionKind', "Override the kind of an extension. `ui` extensions are installed and run on the local machine while `workspace` extensions are run on the remote. By overriding an extension's default kind using this setting, you specify if that extension should be installed and enabled locally or remotely."),
|
||||
patternProperties: {
|
||||
'([a-z0-9A-Z][a-z0-9\-A-Z]*)\\.([a-z0-9A-Z][a-z0-9\-A-Z]*)$': {
|
||||
oneOf: [{ type: 'array', items: extensionKindSchema }, extensionKindSchema],
|
||||
default: ['ui'],
|
||||
},
|
||||
},
|
||||
default: {
|
||||
'pub.name': ['ui']
|
||||
}
|
||||
},
|
||||
'remote.downloadExtensionsLocally': {
|
||||
type: 'boolean',
|
||||
markdownDescription: nls.localize('remote.downloadExtensionsLocally', "When enabled extensions are downloaded locally and installed on remote."),
|
||||
|
||||
@@ -26,7 +26,7 @@ import { FileEditorInput } from 'vs/workbench/contrib/files/common/editors/fileE
|
||||
import * as SearchConstants from 'vs/workbench/contrib/search/common/constants';
|
||||
import * as SearchEditorConstants from 'vs/workbench/contrib/searchEditor/browser/constants';
|
||||
import { SearchEditor } from 'vs/workbench/contrib/searchEditor/browser/searchEditor';
|
||||
import { OpenResultsInEditorAction, OpenSearchEditorAction, ReRunSearchEditorSearchAction, toggleSearchEditorCaseSensitiveCommand, toggleSearchEditorContextLinesCommand, toggleSearchEditorRegexCommand, toggleSearchEditorWholeWordCommand } from 'vs/workbench/contrib/searchEditor/browser/searchEditorActions';
|
||||
import { OpenResultsInEditorAction, OpenSearchEditorAction, toggleSearchEditorCaseSensitiveCommand, toggleSearchEditorContextLinesCommand, toggleSearchEditorRegexCommand, toggleSearchEditorWholeWordCommand } from 'vs/workbench/contrib/searchEditor/browser/searchEditorActions';
|
||||
import { getOrMakeSearchEditorInput, SearchEditorInput } from 'vs/workbench/contrib/searchEditor/browser/searchEditorInput';
|
||||
import { IEditorService } from 'vs/workbench/services/editor/common/editorService';
|
||||
import { ISearchConfigurationProperties } from 'vs/workbench/services/search/common/search';
|
||||
@@ -164,10 +164,6 @@ KeybindingsRegistry.registerCommandAndKeybindingRule({
|
||||
const registry = Registry.as<IWorkbenchActionRegistry>(ActionExtensions.WorkbenchActions);
|
||||
const category = localize('search', "Search Editor");
|
||||
|
||||
registry.registerWorkbenchAction(
|
||||
SyncActionDescriptor.create(ReRunSearchEditorSearchAction, ReRunSearchEditorSearchAction.ID, ReRunSearchEditorSearchAction.LABEL),
|
||||
'Search Editor: Rerun search', category, ContextKeyExpr.and(SearchEditorConstants.InSearchEditor));
|
||||
|
||||
registry.registerWorkbenchAction(
|
||||
SyncActionDescriptor.create(OpenResultsInEditorAction, OpenResultsInEditorAction.ID, OpenResultsInEditorAction.LABEL,
|
||||
{ mac: { primary: KeyMod.CtrlCmd | KeyCode.Enter } },
|
||||
|
||||
@@ -112,25 +112,6 @@ export class OpenResultsInEditorAction extends Action {
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
export class ReRunSearchEditorSearchAction extends Action {
|
||||
|
||||
static readonly ID = 'searchEditor.rerunSerach';
|
||||
static readonly LABEL = localize('search.rerunSearch', "Rerun Search in Editor");
|
||||
|
||||
constructor(id: string, label: string,
|
||||
@IEditorService private readonly editorService: IEditorService) {
|
||||
super(id, label);
|
||||
}
|
||||
|
||||
async run() {
|
||||
const input = this.editorService.activeEditor;
|
||||
if (input instanceof SearchEditorInput) {
|
||||
await (this.editorService.activeControl as SearchEditor).runSearch(false, true);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
const openNewSearchEditor =
|
||||
async (accessor: ServicesAccessor) => {
|
||||
const editorService = accessor.get(IEditorService);
|
||||
|
||||
@@ -26,6 +26,8 @@ export class TimelinePaneDescriptor implements IViewDescriptor {
|
||||
readonly collapsed = true;
|
||||
readonly canToggleVisibility = true;
|
||||
readonly hideByDefault = false;
|
||||
readonly canMoveView = true;
|
||||
|
||||
focusCommand = { id: 'timeline.focus' };
|
||||
}
|
||||
|
||||
|
||||
@@ -294,7 +294,10 @@ export class TimelinePane extends ViewPane {
|
||||
const renderer = this.instantiationService.createInstance(TimelineTreeRenderer);
|
||||
this._tree = <WorkbenchObjectTree<TreeElement, FuzzyScore>>this.instantiationService.createInstance(WorkbenchObjectTree, 'TimelinePane', this._treeElement, new TimelineListVirtualDelegate(), [renderer], {
|
||||
identityProvider: new TimelineIdentityProvider(),
|
||||
keyboardNavigationLabelProvider: new TimelineKeyboardNavigationLabelProvider()
|
||||
keyboardNavigationLabelProvider: new TimelineKeyboardNavigationLabelProvider(),
|
||||
overrideStyles: {
|
||||
listBackground: this.getBackgroundColor()
|
||||
}
|
||||
});
|
||||
|
||||
const customTreeNavigator = new TreeResourceNavigator(this._tree, { openOnFocus: false, openOnSelection: false });
|
||||
|
||||
@@ -147,13 +147,13 @@ export class UserDataSyncWorkbenchContribution extends Disposable implements IWo
|
||||
}
|
||||
|
||||
if (sessions.length === 0) {
|
||||
this.setActiveAccount(undefined);
|
||||
await this.setActiveAccount(undefined);
|
||||
return;
|
||||
}
|
||||
|
||||
if (sessions.length === 1) {
|
||||
this.logAuthenticatedEvent(sessions[0]);
|
||||
this.setActiveAccount(sessions[0]);
|
||||
await this.setActiveAccount(sessions[0]);
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -167,7 +167,7 @@ export class UserDataSyncWorkbenchContribution extends Disposable implements IWo
|
||||
if (selectedAccount) {
|
||||
const selected = sessions.filter(account => selectedAccount.id === account.id)[0];
|
||||
this.logAuthenticatedEvent(selected);
|
||||
this.setActiveAccount(selected);
|
||||
await this.setActiveAccount(selected);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -565,7 +565,7 @@ export class UserDataSyncWorkbenchContribution extends Disposable implements IWo
|
||||
|
||||
private async signIn(): Promise<void> {
|
||||
try {
|
||||
this.setActiveAccount(await this.authenticationService.login(this.userDataSyncStore!.authenticationProviderId, ['https://management.core.windows.net/.default', 'offline_access']));
|
||||
await this.setActiveAccount(await this.authenticationService.login(this.userDataSyncStore!.authenticationProviderId, ['https://management.core.windows.net/.default', 'offline_access']));
|
||||
} catch (e) {
|
||||
this.notificationService.error(e);
|
||||
throw e;
|
||||
@@ -575,7 +575,7 @@ export class UserDataSyncWorkbenchContribution extends Disposable implements IWo
|
||||
private async signOut(): Promise<void> {
|
||||
if (this.activeAccount) {
|
||||
await this.authenticationService.logout(this.userDataSyncStore!.authenticationProviderId, this.activeAccount.id);
|
||||
this.setActiveAccount(undefined);
|
||||
await this.setActiveAccount(undefined);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user