Added a visual indicator when moving clients
This commit is contained in:
parent
ad42a52403
commit
9af7fe11a4
1 changed files with 18 additions and 0 deletions
|
@ -445,6 +445,24 @@ export class RDPChannelTree {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
if(target instanceof RDPChannel) {
|
||||||
|
target.setDragHint("contain");
|
||||||
|
this.dragOverChannelEntry = target;
|
||||||
|
} else {
|
||||||
|
const treeEntries = this.getTreeEntries();
|
||||||
|
|
||||||
|
let index = treeEntries.indexOf(target);
|
||||||
|
|
||||||
|
while(index >= 0 && !(treeEntries[index] instanceof RDPChannel)) {
|
||||||
|
index--;
|
||||||
|
}
|
||||||
|
|
||||||
|
if(index < 0) { return; }
|
||||||
|
this.dragOverChannelEntry = treeEntries[index] as RDPChannel;
|
||||||
|
this.dragOverChannelEntry.setDragHint("contain");
|
||||||
|
}
|
||||||
|
|
||||||
/* clients can be dropped anywhere (if they're getting dropped on another client we'll use use his channel */
|
/* clients can be dropped anywhere (if they're getting dropped on another client we'll use use his channel */
|
||||||
event.preventDefault();
|
event.preventDefault();
|
||||||
return;
|
return;
|
||||||
|
|
Loading…
Add table
Reference in a new issue