Skip to content

Commit

Permalink
Review fixes
Browse files Browse the repository at this point in the history
Signed-off-by: Esther Perelman <[email protected]>
  • Loading branch information
EstherPerelman committed Aug 15, 2021
1 parent b6b0f1b commit cbeebd3
Show file tree
Hide file tree
Showing 4 changed files with 6 additions and 5 deletions.
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@

- [core] registering toolbar items for commands that explicitly target a `ViewContainer` rather than a child widget may not behave as expected. Such registrations should be made in the `ViewContainer` by overriding the `updateToolbarItems` method and using the `registerToolbarItem` utility. See the modifications to the `scm` and `vsx-registry` packages in the PR for examples. [#9798](https://github.com/eclipse-theia/theia/pull/9798)
- [vsx-registry] `VSXExtensionsContribution` no longer implements `TabBarToolbarContribution` and is not bound as such. Extensions of the class that expect such behavior should reimplement it with caution. See caveats in PR. [#9798](https://github.com/eclipse-theia/theia/pull/9798)
- [view-container] `ViewContainerPart` constructor takes new 2 parameters: `originalContainerId` and `originalContainerTitle`, The existing `viewContainerId` parameter has been renamed to `currentContainerId` to enable drag & drop views. [#9644](https://github.com/eclipse-theia/theia/pull/9644)

## v1.16.0 - 7/29/2021

Expand Down
4 changes: 2 additions & 2 deletions packages/core/src/browser/shell/tab-bars.ts
Original file line number Diff line number Diff line change
Expand Up @@ -489,10 +489,10 @@ export class TabBarRenderer extends TabBar.Renderer {
const { top, bottom, left, right, height } = currentTarget.getBoundingClientRect();
const mouseOnTop = (clientY - top) < (height / 2);
const dropTargetClass = `drop-target-${mouseOnTop ? 'top' : 'bottom'}`;
currentTarget.className += ' ' + dropTargetClass;
currentTarget.classList.add(dropTargetClass);
this.toCancelViewContainerDND.push(Disposable.create(() => {
if (currentTarget) {
currentTarget.className = currentTarget.className.replace(dropTargetClass, '');
currentTarget.classList.remove(dropTargetClass);
}
}));
const openTabTimer = setTimeout(() => {
Expand Down
4 changes: 2 additions & 2 deletions packages/core/src/browser/style/tabs.css
Original file line number Diff line number Diff line change
Expand Up @@ -52,11 +52,11 @@
}

.p-TabBar[data-orientation='vertical'] .p-TabBar-tab.drop-target-top {
border-top-color: white !important;
border-top-color: var(--theia-activityBar-activeBorder) !important;
}

.p-TabBar[data-orientation='vertical'] .p-TabBar-tab.drop-target-bottom {
border-bottom-color: white !important;
border-bottom-color: var(--theia-activityBar-activeBorder) !important;
}

.p-TabBar[data-orientation='horizontal'] .p-TabBar-tab .theia-tab-icon-label,
Expand Down
2 changes: 1 addition & 1 deletion packages/core/src/browser/view-container.ts
Original file line number Diff line number Diff line change
Expand Up @@ -643,8 +643,8 @@ export class ViewContainer extends BaseWidget implements StatefulWidget, Applica

protected moveBetweenContainers(fromIndex: number, toIndex: number, fromContainer: ViewContainer): void {
const partToMove = fromContainer.getParts()[fromIndex];
fromContainer.removeWidget(partToMove);
this.appendPart(partToMove, toIndex);
fromContainer.removeWidget(partToMove.wrapped);
fromContainer.updateTitle();
fromContainer.lastVisibleState = fromContainer.doStoreState();
}
Expand Down

0 comments on commit cbeebd3

Please sign in to comment.