diff --git a/Greenshot/Forms/CaptureForm.cs b/Greenshot/Forms/CaptureForm.cs index c402aeb91..1c32bb2d6 100644 --- a/Greenshot/Forms/CaptureForm.cs +++ b/Greenshot/Forms/CaptureForm.cs @@ -124,6 +124,7 @@ namespace Greenshot.Forms { // Fix missing focus WindowDetails.ToForeground(this.Handle); + this.TopMost = true; } #region key handling @@ -147,9 +148,6 @@ namespace Greenshot.Forms { // Toggle mouse cursor capture.CursorVisible = !capture.CursorVisible; pictureBox.Invalidate(); - } else if (e.KeyCode == Keys.V && conf.isExperimentalFeatureEnabled("Video")) { - capture.CaptureDetails.CaptureMode = CaptureMode.Video; - pictureBox.Invalidate(); } else if (e.KeyCode == Keys.Space) { switch (captureMode) { case CaptureMode.Region: @@ -347,11 +345,6 @@ namespace Greenshot.Forms { if (mouseDown || captureMode == CaptureMode.Window) { captureRect.Intersect(new Rectangle(Point.Empty, capture.ScreenBounds.Size)); // crop what is outside the screen Rectangle fixedRect = new Rectangle( captureRect.X, captureRect.Y, captureRect.Width, captureRect.Height ); - if (capture.CaptureDetails.CaptureMode == CaptureMode.Video) { - graphics.FillRectangle( RedOverlayBrush, fixedRect ); - } else { - graphics.FillRectangle( GreenOverlayBrush, fixedRect ); - } graphics.DrawRectangle( OverlayPen, fixedRect ); // rulers diff --git a/Greenshot/Helpers/CaptureHelper.cs b/Greenshot/Helpers/CaptureHelper.cs index 3d6dd4883..9f950b62d 100644 --- a/Greenshot/Helpers/CaptureHelper.cs +++ b/Greenshot/Helpers/CaptureHelper.cs @@ -45,7 +45,7 @@ namespace Greenshot.Helpers { public class CaptureHelper { private static readonly log4net.ILog LOG = log4net.LogManager.GetLogger(typeof(CaptureHelper)); private static CoreConfiguration conf = IniConfig.GetIniSection(); - private static ScreenCaptureHelper screenCapture = null; + //private static ScreenCaptureHelper screenCapture = null; private List windows = new List(); private WindowDetails selectedCaptureWindow = null; private Rectangle captureRect = Rectangle.Empty; @@ -154,13 +154,6 @@ namespace Greenshot.Helpers { /// Make Capture with specified destinations /// private void MakeCapture() { - // Experimental code - if (screenCapture != null) { - screenCapture.Stop(); - screenCapture = null; - return; - } - LOG.Debug(String.Format("Capturing with mode {0} and using Cursor {1}", captureMode, captureMouseCursor)); capture.CaptureDetails.CaptureMode = captureMode; @@ -343,13 +336,6 @@ namespace Greenshot.Helpers { HandleCapture(); } break; - case CaptureMode.Video: - capture = WindowCapture.CaptureScreen(capture); - // Set the capturemode to be window - captureMode = CaptureMode.Window; - capture.CaptureDetails.AddMetaData("source", "Video"); - CaptureWithFeedback(); - break; default: LOG.Warn("Unknown capture mode: " + captureMode); break; @@ -784,25 +770,6 @@ namespace Greenshot.Helpers { capture.CaptureDetails.Title = selectedCaptureWindow.Text; } - // Experimental code - if (capture.CaptureDetails.CaptureMode == CaptureMode.Video) { - if (captureForm.UsedCaptureMode == CaptureMode.Window) { - screenCapture = new ScreenCaptureHelper(selectedCaptureWindow); - } else if (captureForm.UsedCaptureMode == CaptureMode.Region) { - screenCapture = new ScreenCaptureHelper(captureRect); - } - if (screenCapture != null) { - screenCapture.RecordMouse = capture.CursorVisible; - if (screenCapture.Start(25)) { - return; - } - // User clicked cancel or a problem occured - screenCapture.Stop(); - screenCapture = null; - return; - } - } - if (captureRect.Height > 0 && captureRect.Width > 0) { if (windowDetailsThread != null) { windowDetailsThread.Join(); diff --git a/GreenshotPlugin/Interfaces/Capture.cs b/GreenshotPlugin/Interfaces/Capture.cs index 384b78167..8feca439e 100644 --- a/GreenshotPlugin/Interfaces/Capture.cs +++ b/GreenshotPlugin/Interfaces/Capture.cs @@ -26,7 +26,7 @@ namespace Greenshot.Plugin { /// /// The capture mode for Greenshot /// - public enum CaptureMode { None, Region, FullScreen, ActiveWindow, Window, LastRegion, Clipboard, File, IE, Video, Import }; + public enum CaptureMode { None, Region, FullScreen, ActiveWindow, Window, LastRegion, Clipboard, File, IE, Import }; public enum ScreenCaptureMode { Auto, FullScreen, Fixed}; ///