mirror of
https://github.com/greenshot/greenshot
synced 2025-08-14 02:37:03 -07:00
Changed IDestination, added a manuallyInitiated so the destination can change its behavior depending on the flag. An example use-case would be the word exporter: if the flag is false, which it would be if the word destination is set as THE destination, it would add to the current document if one is available otherwise create a new. This makes it possible to have a kind of session behavior.
git-svn-id: http://svn.code.sf.net/p/greenshot/code/trunk@1749 7dccd23d-a4a3-4e1f-8c07-b4c1b4018ab4
This commit is contained in:
parent
c092712561
commit
eb616472c4
24 changed files with 68 additions and 47 deletions
|
@ -112,11 +112,11 @@ namespace Greenshot.Helpers {
|
|||
/// <param name="designation"></param>
|
||||
/// <param name="surface"></param>
|
||||
/// <param name="captureDetails"></param>
|
||||
public static void ExportCapture(string designation, ISurface surface, ICaptureDetails captureDetails) {
|
||||
public static void ExportCapture(bool manuallyInitiated, string designation, ISurface surface, ICaptureDetails captureDetails) {
|
||||
if (RegisteredDestinations.ContainsKey(designation)) {
|
||||
IDestination destination = RegisteredDestinations[designation];
|
||||
if (destination.isActive) {
|
||||
if (destination.ExportCapture(surface, captureDetails)) {
|
||||
if (destination.ExportCapture(manuallyInitiated, surface, captureDetails)) {
|
||||
// Export worked, set the modified flag
|
||||
surface.Modified = false;
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue