Leave the just-pasted entities selected after a Paste Transformed.
[git-p4: depot-paths = "//depot/solvespace/": change = 2095]
This commit is contained in:
parent
3a2ec4630e
commit
58c0e44107
|
@ -115,8 +115,6 @@ void GraphicsWindow::CopySelection(void) {
|
||||||
}
|
}
|
||||||
|
|
||||||
void GraphicsWindow::PasteClipboard(Vector trans, double theta, double scale) {
|
void GraphicsWindow::PasteClipboard(Vector trans, double theta, double scale) {
|
||||||
ClearSelection();
|
|
||||||
|
|
||||||
Entity *wrkpl = SK.GetEntity(ActiveWorkplane());
|
Entity *wrkpl = SK.GetEntity(ActiveWorkplane());
|
||||||
Entity *wrkpln = SK.GetEntity(wrkpl->normal);
|
Entity *wrkpln = SK.GetEntity(wrkpl->normal);
|
||||||
Vector u = wrkpln->NormalU(),
|
Vector u = wrkpln->NormalU(),
|
||||||
|
@ -124,7 +122,6 @@ void GraphicsWindow::PasteClipboard(Vector trans, double theta, double scale) {
|
||||||
n = wrkpln->NormalN(),
|
n = wrkpln->NormalN(),
|
||||||
p = SK.GetEntity(wrkpl->point[0])->PointGetNum();
|
p = SK.GetEntity(wrkpl->point[0])->PointGetNum();
|
||||||
|
|
||||||
|
|
||||||
ClipboardRequest *cr;
|
ClipboardRequest *cr;
|
||||||
for(cr = SS.clipboard.r.First(); cr; cr = SS.clipboard.r.NextAfter(cr)) {
|
for(cr = SS.clipboard.r.First(); cr; cr = SS.clipboard.r.NextAfter(cr)) {
|
||||||
hRequest hr = AddRequest(cr->type, false);
|
hRequest hr = AddRequest(cr->type, false);
|
||||||
|
@ -193,6 +190,7 @@ void GraphicsWindow::MenuClipboard(int id) {
|
||||||
SS.UndoRemember();
|
SS.UndoRemember();
|
||||||
Vector trans = SS.GW.projRight.ScaledBy(80/SS.GW.scale).Plus(
|
Vector trans = SS.GW.projRight.ScaledBy(80/SS.GW.scale).Plus(
|
||||||
SS.GW.projUp .ScaledBy(40/SS.GW.scale));
|
SS.GW.projUp .ScaledBy(40/SS.GW.scale));
|
||||||
|
SS.GW.ClearSelection();
|
||||||
SS.GW.PasteClipboard(trans, 0, 1);
|
SS.GW.PasteClipboard(trans, 0, 1);
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
@ -300,6 +298,7 @@ void TextWindow::ScreenPasteTransformed(int link, DWORD v) {
|
||||||
} else {
|
} else {
|
||||||
Error("Select one point to define origin of rotation.");
|
Error("Select one point to define origin of rotation.");
|
||||||
}
|
}
|
||||||
|
SS.GW.ClearSelection();
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case 't':
|
case 't':
|
||||||
|
@ -311,6 +310,7 @@ void TextWindow::ScreenPasteTransformed(int link, DWORD v) {
|
||||||
} else {
|
} else {
|
||||||
Error("Select two points to define translation vector.");
|
Error("Select two points to define translation vector.");
|
||||||
}
|
}
|
||||||
|
SS.GW.ClearSelection();
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case 'g': {
|
case 'g': {
|
||||||
|
@ -334,6 +334,7 @@ void TextWindow::ScreenPasteTransformed(int link, DWORD v) {
|
||||||
Entity *wrkpln = SK.GetEntity(wrkpl->normal);
|
Entity *wrkpln = SK.GetEntity(wrkpl->normal);
|
||||||
Vector wn = wrkpln->NormalN();
|
Vector wn = wrkpln->NormalN();
|
||||||
SS.UndoRemember();
|
SS.UndoRemember();
|
||||||
|
SS.GW.ClearSelection();
|
||||||
for(int i = 0; i < SS.TW.shown.paste.times; i++) {
|
for(int i = 0; i < SS.TW.shown.paste.times; i++) {
|
||||||
Vector trans = SS.TW.shown.paste.trans.ScaledBy(i+1),
|
Vector trans = SS.TW.shown.paste.trans.ScaledBy(i+1),
|
||||||
origin = SS.TW.shown.paste.origin;
|
origin = SS.TW.shown.paste.origin;
|
||||||
|
@ -351,7 +352,6 @@ void TextWindow::ScreenPasteTransformed(int link, DWORD v) {
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
SS.GW.ClearSelection();
|
|
||||||
}
|
}
|
||||||
|
|
||||||
void TextWindow::ShowPasteTransformed(void) {
|
void TextWindow::ShowPasteTransformed(void) {
|
||||||
|
|
Loading…
Reference in New Issue
Block a user