Enhanced the external command plug-in to capture the first Uri in the output, and places this on the clipboard. Additionally the Uri is linked in the notify bubble or when started from the editor. The behaviour can only be modified via the greenshot.ini and is for all commands.

This commit is contained in:
RKrom 2014-09-09 17:35:51 +02:00
commit 7d28b6a3a5
8 changed files with 319 additions and 54 deletions

View file

@ -25,6 +25,7 @@ using System.Windows.Forms;
using Greenshot.Plugin;
using log4net;
using Microsoft.Win32;
using GreenshotPlugin.UnmanagedHelpers;
namespace GreenshotPlugin.Core {
/// <summary>
@ -83,6 +84,11 @@ namespace GreenshotPlugin.Core {
return appIcon.ToBitmap();
}
}
using (Icon appIcon = Shell32.GetFileIcon(path, Shell32.IconSize.Small, false)) {
if (appIcon != null) {
return appIcon.ToBitmap();
}
}
} catch (Exception exIcon) {
LOG.Error("error retrieving icon: ", exIcon);
}