Trying to replace the Gripper (which is a Label/Control) with adorners (custom code). This should prevent the slow cleanup, reduce resources and speedup the editor. Also we should have better "UI" feedback. This is still very experimental.

This commit is contained in:
Robin 2016-05-23 13:32:52 +02:00
commit 31db071394
15 changed files with 643 additions and 349 deletions

View file

@ -63,12 +63,7 @@ namespace Greenshot.Drawing {
protected void Init() {
if (_grippers != null) {
for (int i = 0; i < _grippers.Length; i++) {
_grippers[i].Enabled = false;
_grippers[i].Visible = false;
}
}
// TODO: Remove grippers
}
public override void Transform(Matrix matrix) {
@ -258,17 +253,6 @@ namespace Greenshot.Drawing {
return freehandPath.GetHashCode();
}
/// <summary>
/// This is overriden to prevent the grippers to be modified.
/// Might not be the best way...
/// </summary>
protected override void DoLayout() {
}
public override void ShowGrippers() {
ResumeLayout();
}
public override bool ClickableAt(int x, int y) {
bool returnValue = base.ClickableAt(x, y);
if (returnValue) {