Extended the ExportCapture with ExportInformation as a result object, this allows us to better and more consistently return & handle information from the export. Also it should be easier to extend the functionality. TODO: Still need to cleanup some messages, some are no longer needed

git-svn-id: http://svn.code.sf.net/p/greenshot/code/trunk@2034 7dccd23d-a4a3-4e1f-8c07-b4c1b4018ab4
This commit is contained in:
RKrom 2012-09-14 15:04:37 +00:00
commit be797ecf8a
27 changed files with 379 additions and 172 deletions

View file

@ -497,7 +497,7 @@ namespace Greenshot.Helpers {
MainForm.instance.notifyIcon.ShowBalloonTip(10000, "Greenshot", eventArgs.Message, ToolTipIcon.Info);
break;
case SurfaceMessageTyp.FileSaved:
case SurfaceMessageTyp.UploadedUrl:
case SurfaceMessageTyp.UploadedUri:
EventHandler balloonTipClickedHandler = null;
EventHandler balloonTipClosedHandler = null;
balloonTipClosedHandler = delegate(object sender, EventArgs e) {
@ -570,8 +570,8 @@ namespace Greenshot.Helpers {
}
LOG.InfoFormat("Calling destination {0}", destination.Description);
bool destinationOk = destination.ExportCapture(false, surface, captureDetails);
if (Destinations.EditorDestination.DESIGNATION.Equals(destination.Designation) && destinationOk) {
ExportInformation exportInformation = destination.ExportCapture(false, surface, captureDetails);
if (Destinations.EditorDestination.DESIGNATION.Equals(destination.Designation) && exportInformation.ExportMade) {
canDisposeSurface = false;
}
}