diff --git a/.github/FUNDING.yml b/.github/FUNDING.yml
new file mode 100644
index 000000000..a7184f71b
--- /dev/null
+++ b/.github/FUNDING.yml
@@ -0,0 +1,9 @@
+# These are supported funding model platforms
+
+# Replace with up to 4 GitHub Sponsors-enabled usernames e.g., [user1, user2]
+github: lakritzator
+patreon: # Replace with a single Patreon username
+open_collective: greenshot
+ko_fi: # Replace with a single Ko-fi username
+tidelift: # Replace with a single Tidelift platform-name/package-name e.g., npm/babel
+custom: https://getgreenshot.org/support/
diff --git a/.github/ISSUE_TEMPLATE/bug_report.md b/.github/ISSUE_TEMPLATE/bug_report.md
new file mode 100644
index 000000000..1f5ca2f11
--- /dev/null
+++ b/.github/ISSUE_TEMPLATE/bug_report.md
@@ -0,0 +1,33 @@
+---
+name: Bug report
+about: Create a report to help us improve
+title: ''
+labels: ''
+assignees: ''
+
+---
+
+This GitHub repository is for developers, if you want to report a bug for Greenshot as a user please do so in our JIRA issue system here: https://greenshot.atlassian.net/projects/BUGS/issues/filter=allopenissues
+
+**Describe the bug**
+A clear and concise description of what the bug is.
+
+**To Reproduce**
+Example steps to reproduce the behavior:
+1. Capture '....'
+2. Open Editor
+3. Add a line
+4. Resize
+
+**Expected behavior**
+A clear and concise description of what you expected to happen.
+
+**Screenshots**
+If applicable, add screenshots to help explain your problem.
+
+**Versions (please complete the following information):**
+ - Greenshot version
+ - Windows version
+
+**Additional context**
+Add any other context about the problem here.
diff --git a/.github/ISSUE_TEMPLATE/developer-bug-report.md b/.github/ISSUE_TEMPLATE/developer-bug-report.md
new file mode 100644
index 000000000..1ffa7da1e
--- /dev/null
+++ b/.github/ISSUE_TEMPLATE/developer-bug-report.md
@@ -0,0 +1,33 @@
+---
+name: Developer Bug report
+about: Create a bug report to help us improve our code
+title: ''
+labels: ''
+assignees: ''
+
+---
+
+This GitHub repository is for developers, if you want to report a bug for Greenshot as a user please do so in our JIRA issue system here: https://greenshot.atlassian.net/projects/BUGS/issues/filter=allopenissues
+
+**Describe the bug**
+A clear and concise description of what the bug is.
+
+**To Reproduce**
+Example steps to reproduce the behavior:
+1. Capture '....'
+2. Open Editor
+3. Add a line
+4. Resize
+
+**Expected behavior**
+A clear and concise description of what you expected to happen.
+
+**Screenshots**
+If applicable, add screenshots to help explain your problem.
+
+**Versions (please complete the following information):**
+ - Greenshot version
+ - Windows version
+
+**Additional context**
+Add any other context about the problem here.
diff --git a/.github/ISSUE_TEMPLATE/developer-feature-request.md b/.github/ISSUE_TEMPLATE/developer-feature-request.md
new file mode 100644
index 000000000..883534a57
--- /dev/null
+++ b/.github/ISSUE_TEMPLATE/developer-feature-request.md
@@ -0,0 +1,22 @@
+---
+name: Developer feature request
+about: Suggest an technical idea for this project
+title: ''
+labels: ''
+assignees: ''
+
+---
+
+This GitHub repository is for developers, if you want to request a feature for Greenshot as a user please do so in our JIRA issue system here: https://greenshot.atlassian.net/projects/FEATURE/issues/filter=allopenissues
+
+**Is your feature request related to a problem? Please describe.**
+A clear and concise description of what the problem is. Ex. I'm always frustrated when [...]
+
+**Describe the solution you'd like**
+A clear and concise description of what you want to happen.
+
+**Describe alternatives you've considered**
+A clear and concise description of any alternative solutions or features you've considered.
+
+**Additional context**
+Add any other context or screenshots about the feature request here.
diff --git a/.github/ISSUE_TEMPLATE/feature_request.md b/.github/ISSUE_TEMPLATE/feature_request.md
new file mode 100644
index 000000000..64323a13d
--- /dev/null
+++ b/.github/ISSUE_TEMPLATE/feature_request.md
@@ -0,0 +1,22 @@
+---
+name: Feature request
+about: Suggest an idea for this project
+title: ''
+labels: ''
+assignees: ''
+
+---
+
+This GitHub repository is for developers, if you want to request a feature for Greenshot as a user please do so in our JIRA issue system here: https://greenshot.atlassian.net/projects/FEATURE/issues/filter=allopenissues
+
+**Is your feature request related to a problem? Please describe.**
+A clear and concise description of what the problem is. Ex. I'm always frustrated when [...]
+
+**Describe the solution you'd like**
+A clear and concise description of what you want to happen.
+
+**Describe alternatives you've considered**
+A clear and concise description of any alternative solutions or features you've considered.
+
+**Additional context**
+Add any other context or screenshots about the feature request here.
diff --git a/.gitignore b/.gitignore
index 2f5969501..3afd2d7ab 100644
--- a/.gitignore
+++ b/.gitignore
@@ -211,4 +211,7 @@ _Pvt_Extensions/
ModelManifest.xml
# Greenshot credentials files
-*.credentials.cs
\ No newline at end of file
+*.credentials.cs
+
+# Rider files
+.idea
\ No newline at end of file
diff --git a/Directory.Build.props b/Directory.Build.props
index ce53be91e..1a2e9d3a4 100644
--- a/Directory.Build.props
+++ b/Directory.Build.props
@@ -1,6 +1,6 @@
- Copyright © Greenshot 2004-2020
+ Copyright © Greenshot 2004-2021
Greenshot
https://getgreenshot.org/favicon.ico
https://github.com/greenshot/greenshot
@@ -18,6 +18,7 @@
true
net472
Off
+ true
@@ -102,19 +103,10 @@
-
+
+
-
- $(userprofile)\.nuget\packages\msbuildtasks\1.5.0.235\tools\
-
-
-
-
-
-
-
-
+ $(PkgMSBuildTasks)\tools\
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/Greenshot.sln b/Greenshot.sln
index 6b3723f7a..27df62d85 100644
--- a/Greenshot.sln
+++ b/Greenshot.sln
@@ -54,172 +54,129 @@ EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
Debug|Any CPU = Debug|Any CPU
- Debug|Mixed Platforms = Debug|Mixed Platforms
Debug|x86 = Debug|x86
Release|Any CPU = Release|Any CPU
- Release|Mixed Platforms = Release|Mixed Platforms
Release|x86 = Release|x86
EndGlobalSection
GlobalSection(ProjectConfigurationPlatforms) = postSolution
{CD642BF4-D815-4D67-A0B5-C69F0B8231AF}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{CD642BF4-D815-4D67-A0B5-C69F0B8231AF}.Debug|Any CPU.Build.0 = Debug|Any CPU
- {CD642BF4-D815-4D67-A0B5-C69F0B8231AF}.Debug|Mixed Platforms.ActiveCfg = Debug|Any CPU
- {CD642BF4-D815-4D67-A0B5-C69F0B8231AF}.Debug|Mixed Platforms.Build.0 = Debug|Any CPU
{CD642BF4-D815-4D67-A0B5-C69F0B8231AF}.Debug|x86.ActiveCfg = Debug|Any CPU
{CD642BF4-D815-4D67-A0B5-C69F0B8231AF}.Debug|x86.Build.0 = Debug|Any CPU
{CD642BF4-D815-4D67-A0B5-C69F0B8231AF}.Release|Any CPU.ActiveCfg = Release|Any CPU
{CD642BF4-D815-4D67-A0B5-C69F0B8231AF}.Release|Any CPU.Build.0 = Release|Any CPU
- {CD642BF4-D815-4D67-A0B5-C69F0B8231AF}.Release|Mixed Platforms.ActiveCfg = Release|Any CPU
{CD642BF4-D815-4D67-A0B5-C69F0B8231AF}.Release|x86.ActiveCfg = Release|Any CPU
{CD642BF4-D815-4D67-A0B5-C69F0B8231AF}.Release|x86.Build.0 = Release|Any CPU
{5B924697-4DCD-4F98-85F1-105CB84B7341}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{5B924697-4DCD-4F98-85F1-105CB84B7341}.Debug|Any CPU.Build.0 = Debug|Any CPU
- {5B924697-4DCD-4F98-85F1-105CB84B7341}.Debug|Mixed Platforms.ActiveCfg = Debug|Any CPU
- {5B924697-4DCD-4F98-85F1-105CB84B7341}.Debug|Mixed Platforms.Build.0 = Debug|Any CPU
{5B924697-4DCD-4F98-85F1-105CB84B7341}.Debug|x86.ActiveCfg = Debug|Any CPU
{5B924697-4DCD-4F98-85F1-105CB84B7341}.Debug|x86.Build.0 = Debug|Any CPU
{5B924697-4DCD-4F98-85F1-105CB84B7341}.Release|Any CPU.ActiveCfg = Release|Any CPU
{5B924697-4DCD-4F98-85F1-105CB84B7341}.Release|Any CPU.Build.0 = Release|Any CPU
- {5B924697-4DCD-4F98-85F1-105CB84B7341}.Release|Mixed Platforms.ActiveCfg = Release|Any CPU
{5B924697-4DCD-4F98-85F1-105CB84B7341}.Release|x86.ActiveCfg = Release|Any CPU
{5B924697-4DCD-4F98-85F1-105CB84B7341}.Release|x86.Build.0 = Release|Any CPU
{47F23C86-604E-4CC3-8767-B3D4088F30BB}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{47F23C86-604E-4CC3-8767-B3D4088F30BB}.Debug|Any CPU.Build.0 = Debug|Any CPU
- {47F23C86-604E-4CC3-8767-B3D4088F30BB}.Debug|Mixed Platforms.ActiveCfg = Debug|Any CPU
{47F23C86-604E-4CC3-8767-B3D4088F30BB}.Debug|x86.ActiveCfg = Debug|Any CPU
{47F23C86-604E-4CC3-8767-B3D4088F30BB}.Debug|x86.Build.0 = Debug|Any CPU
{47F23C86-604E-4CC3-8767-B3D4088F30BB}.Release|Any CPU.ActiveCfg = Release|Any CPU
{47F23C86-604E-4CC3-8767-B3D4088F30BB}.Release|Any CPU.Build.0 = Release|Any CPU
- {47F23C86-604E-4CC3-8767-B3D4088F30BB}.Release|Mixed Platforms.ActiveCfg = Release|Any CPU
{47F23C86-604E-4CC3-8767-B3D4088F30BB}.Release|x86.ActiveCfg = Release|Any CPU
{47F23C86-604E-4CC3-8767-B3D4088F30BB}.Release|x86.Build.0 = Release|Any CPU
{C3052651-598A-44E2-AAB3-2E41311D50F9}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{C3052651-598A-44E2-AAB3-2E41311D50F9}.Debug|Any CPU.Build.0 = Debug|Any CPU
- {C3052651-598A-44E2-AAB3-2E41311D50F9}.Debug|Mixed Platforms.ActiveCfg = Debug|Any CPU
{C3052651-598A-44E2-AAB3-2E41311D50F9}.Debug|x86.ActiveCfg = Debug|Any CPU
{C3052651-598A-44E2-AAB3-2E41311D50F9}.Debug|x86.Build.0 = Debug|Any CPU
{C3052651-598A-44E2-AAB3-2E41311D50F9}.Release|Any CPU.ActiveCfg = Release|Any CPU
{C3052651-598A-44E2-AAB3-2E41311D50F9}.Release|Any CPU.Build.0 = Release|Any CPU
- {C3052651-598A-44E2-AAB3-2E41311D50F9}.Release|Mixed Platforms.ActiveCfg = Release|Any CPU
{C3052651-598A-44E2-AAB3-2E41311D50F9}.Release|x86.ActiveCfg = Release|Any CPU
{C3052651-598A-44E2-AAB3-2E41311D50F9}.Release|x86.Build.0 = Release|Any CPU
{80D8DEB9-94E3-4876-8CCA-2DF1ED5F2C50}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{80D8DEB9-94E3-4876-8CCA-2DF1ED5F2C50}.Debug|Any CPU.Build.0 = Debug|Any CPU
- {80D8DEB9-94E3-4876-8CCA-2DF1ED5F2C50}.Debug|Mixed Platforms.ActiveCfg = Debug|Any CPU
{80D8DEB9-94E3-4876-8CCA-2DF1ED5F2C50}.Debug|x86.ActiveCfg = Debug|Any CPU
{80D8DEB9-94E3-4876-8CCA-2DF1ED5F2C50}.Debug|x86.Build.0 = Debug|Any CPU
{80D8DEB9-94E3-4876-8CCA-2DF1ED5F2C50}.Release|Any CPU.ActiveCfg = Release|Any CPU
{80D8DEB9-94E3-4876-8CCA-2DF1ED5F2C50}.Release|Any CPU.Build.0 = Release|Any CPU
- {80D8DEB9-94E3-4876-8CCA-2DF1ED5F2C50}.Release|Mixed Platforms.ActiveCfg = Release|Any CPU
{80D8DEB9-94E3-4876-8CCA-2DF1ED5F2C50}.Release|x86.ActiveCfg = Release|Any CPU
{80D8DEB9-94E3-4876-8CCA-2DF1ED5F2C50}.Release|x86.Build.0 = Release|Any CPU
{19FEEF09-313F-43C7-819D-F1BCA782B08B}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{19FEEF09-313F-43C7-819D-F1BCA782B08B}.Debug|Any CPU.Build.0 = Debug|Any CPU
- {19FEEF09-313F-43C7-819D-F1BCA782B08B}.Debug|Mixed Platforms.ActiveCfg = Debug|Any CPU
{19FEEF09-313F-43C7-819D-F1BCA782B08B}.Debug|x86.ActiveCfg = Debug|Any CPU
{19FEEF09-313F-43C7-819D-F1BCA782B08B}.Debug|x86.Build.0 = Debug|Any CPU
{19FEEF09-313F-43C7-819D-F1BCA782B08B}.Release|Any CPU.ActiveCfg = Release|Any CPU
{19FEEF09-313F-43C7-819D-F1BCA782B08B}.Release|Any CPU.Build.0 = Release|Any CPU
- {19FEEF09-313F-43C7-819D-F1BCA782B08B}.Release|Mixed Platforms.ActiveCfg = Release|Any CPU
{19FEEF09-313F-43C7-819D-F1BCA782B08B}.Release|x86.ActiveCfg = Release|Any CPU
{19FEEF09-313F-43C7-819D-F1BCA782B08B}.Release|x86.Build.0 = Release|Any CPU
{C6988EE8-2FEE-4349-9F09-F9628A0D8965}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{C6988EE8-2FEE-4349-9F09-F9628A0D8965}.Debug|Any CPU.Build.0 = Debug|Any CPU
- {C6988EE8-2FEE-4349-9F09-F9628A0D8965}.Debug|Mixed Platforms.ActiveCfg = Debug|Any CPU
{C6988EE8-2FEE-4349-9F09-F9628A0D8965}.Debug|x86.ActiveCfg = Debug|Any CPU
{C6988EE8-2FEE-4349-9F09-F9628A0D8965}.Debug|x86.Build.0 = Debug|Any CPU
{C6988EE8-2FEE-4349-9F09-F9628A0D8965}.Release|Any CPU.ActiveCfg = Release|Any CPU
{C6988EE8-2FEE-4349-9F09-F9628A0D8965}.Release|Any CPU.Build.0 = Release|Any CPU
- {C6988EE8-2FEE-4349-9F09-F9628A0D8965}.Release|Mixed Platforms.ActiveCfg = Release|Any CPU
{C6988EE8-2FEE-4349-9F09-F9628A0D8965}.Release|x86.ActiveCfg = Release|Any CPU
{C6988EE8-2FEE-4349-9F09-F9628A0D8965}.Release|x86.Build.0 = Release|Any CPU
{D61E6ECE-E0B6-4467-B492-F08A06BA8F02}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{D61E6ECE-E0B6-4467-B492-F08A06BA8F02}.Debug|Any CPU.Build.0 = Debug|Any CPU
- {D61E6ECE-E0B6-4467-B492-F08A06BA8F02}.Debug|Mixed Platforms.ActiveCfg = Debug|Any CPU
- {D61E6ECE-E0B6-4467-B492-F08A06BA8F02}.Debug|Mixed Platforms.Build.0 = Debug|Any CPU
{D61E6ECE-E0B6-4467-B492-F08A06BA8F02}.Debug|x86.ActiveCfg = Debug|Any CPU
{D61E6ECE-E0B6-4467-B492-F08A06BA8F02}.Debug|x86.Build.0 = Debug|Any CPU
{D61E6ECE-E0B6-4467-B492-F08A06BA8F02}.Release|Any CPU.ActiveCfg = Release|Any CPU
{D61E6ECE-E0B6-4467-B492-F08A06BA8F02}.Release|Any CPU.Build.0 = Release|Any CPU
- {D61E6ECE-E0B6-4467-B492-F08A06BA8F02}.Release|Mixed Platforms.ActiveCfg = Release|Any CPU
- {D61E6ECE-E0B6-4467-B492-F08A06BA8F02}.Release|Mixed Platforms.Build.0 = Release|Any CPU
{D61E6ECE-E0B6-4467-B492-F08A06BA8F02}.Release|x86.ActiveCfg = Release|Any CPU
{D61E6ECE-E0B6-4467-B492-F08A06BA8F02}.Release|x86.Build.0 = Release|Any CPU
{697CF066-9077-4F22-99D9-D989CCE7282B}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{697CF066-9077-4F22-99D9-D989CCE7282B}.Debug|Any CPU.Build.0 = Debug|Any CPU
- {697CF066-9077-4F22-99D9-D989CCE7282B}.Debug|Mixed Platforms.ActiveCfg = Debug|Any CPU
- {697CF066-9077-4F22-99D9-D989CCE7282B}.Debug|Mixed Platforms.Build.0 = Debug|Any CPU
{697CF066-9077-4F22-99D9-D989CCE7282B}.Debug|x86.ActiveCfg = Debug|Any CPU
{697CF066-9077-4F22-99D9-D989CCE7282B}.Debug|x86.Build.0 = Debug|Any CPU
{697CF066-9077-4F22-99D9-D989CCE7282B}.Release|Any CPU.ActiveCfg = Release|Any CPU
{697CF066-9077-4F22-99D9-D989CCE7282B}.Release|Any CPU.Build.0 = Release|Any CPU
- {697CF066-9077-4F22-99D9-D989CCE7282B}.Release|Mixed Platforms.ActiveCfg = Release|Any CPU
{697CF066-9077-4F22-99D9-D989CCE7282B}.Release|x86.ActiveCfg = Release|Any CPU
{697CF066-9077-4F22-99D9-D989CCE7282B}.Release|x86.Build.0 = Release|Any CPU
{AD7CFFE2-40E7-46CF-A172-D48CF7AE9A12}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{AD7CFFE2-40E7-46CF-A172-D48CF7AE9A12}.Debug|Any CPU.Build.0 = Debug|Any CPU
- {AD7CFFE2-40E7-46CF-A172-D48CF7AE9A12}.Debug|Mixed Platforms.ActiveCfg = Debug|Any CPU
{AD7CFFE2-40E7-46CF-A172-D48CF7AE9A12}.Debug|x86.ActiveCfg = Debug|Any CPU
{AD7CFFE2-40E7-46CF-A172-D48CF7AE9A12}.Debug|x86.Build.0 = Debug|Any CPU
{AD7CFFE2-40E7-46CF-A172-D48CF7AE9A12}.Release|Any CPU.ActiveCfg = Release|Any CPU
{AD7CFFE2-40E7-46CF-A172-D48CF7AE9A12}.Release|Any CPU.Build.0 = Release|Any CPU
- {AD7CFFE2-40E7-46CF-A172-D48CF7AE9A12}.Release|Mixed Platforms.ActiveCfg = Release|Any CPU
{AD7CFFE2-40E7-46CF-A172-D48CF7AE9A12}.Release|x86.ActiveCfg = Release|Any CPU
{AD7CFFE2-40E7-46CF-A172-D48CF7AE9A12}.Release|x86.Build.0 = Release|Any CPU
{7EC72A5A-D73A-4B4B-9CA1-2216C7D92D5E}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{7EC72A5A-D73A-4B4B-9CA1-2216C7D92D5E}.Debug|Any CPU.Build.0 = Debug|Any CPU
- {7EC72A5A-D73A-4B4B-9CA1-2216C7D92D5E}.Debug|Mixed Platforms.ActiveCfg = Debug|Any CPU
{7EC72A5A-D73A-4B4B-9CA1-2216C7D92D5E}.Debug|x86.ActiveCfg = Debug|Any CPU
{7EC72A5A-D73A-4B4B-9CA1-2216C7D92D5E}.Debug|x86.Build.0 = Debug|Any CPU
{7EC72A5A-D73A-4B4B-9CA1-2216C7D92D5E}.Release|Any CPU.ActiveCfg = Release|Any CPU
{7EC72A5A-D73A-4B4B-9CA1-2216C7D92D5E}.Release|Any CPU.Build.0 = Release|Any CPU
- {7EC72A5A-D73A-4B4B-9CA1-2216C7D92D5E}.Release|Mixed Platforms.ActiveCfg = Release|Any CPU
{7EC72A5A-D73A-4B4B-9CA1-2216C7D92D5E}.Release|x86.ActiveCfg = Release|Any CPU
{7EC72A5A-D73A-4B4B-9CA1-2216C7D92D5E}.Release|x86.Build.0 = Release|Any CPU
{1893A2E4-A78A-4713-A8E7-E70058DABEE0}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{1893A2E4-A78A-4713-A8E7-E70058DABEE0}.Debug|Any CPU.Build.0 = Debug|Any CPU
- {1893A2E4-A78A-4713-A8E7-E70058DABEE0}.Debug|Mixed Platforms.ActiveCfg = Debug|Any CPU
{1893A2E4-A78A-4713-A8E7-E70058DABEE0}.Debug|x86.ActiveCfg = Debug|Any CPU
{1893A2E4-A78A-4713-A8E7-E70058DABEE0}.Debug|x86.Build.0 = Debug|Any CPU
{1893A2E4-A78A-4713-A8E7-E70058DABEE0}.Release|Any CPU.ActiveCfg = Release|Any CPU
{1893A2E4-A78A-4713-A8E7-E70058DABEE0}.Release|Any CPU.Build.0 = Release|Any CPU
- {1893A2E4-A78A-4713-A8E7-E70058DABEE0}.Release|Mixed Platforms.ActiveCfg = Release|Any CPU
{1893A2E4-A78A-4713-A8E7-E70058DABEE0}.Release|x86.ActiveCfg = Release|Any CPU
{1893A2E4-A78A-4713-A8E7-E70058DABEE0}.Release|x86.Build.0 = Release|Any CPU
{92599C09-FF29-4ABD-B6E6-C48ECD781BAB}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{92599C09-FF29-4ABD-B6E6-C48ECD781BAB}.Debug|Any CPU.Build.0 = Debug|Any CPU
- {92599C09-FF29-4ABD-B6E6-C48ECD781BAB}.Debug|Mixed Platforms.ActiveCfg = Debug|Any CPU
- {92599C09-FF29-4ABD-B6E6-C48ECD781BAB}.Debug|Mixed Platforms.Build.0 = Debug|Any CPU
{92599C09-FF29-4ABD-B6E6-C48ECD781BAB}.Debug|x86.ActiveCfg = Debug|Any CPU
{92599C09-FF29-4ABD-B6E6-C48ECD781BAB}.Debug|x86.Build.0 = Debug|Any CPU
{92599C09-FF29-4ABD-B6E6-C48ECD781BAB}.Release|Any CPU.ActiveCfg = Release|Any CPU
{92599C09-FF29-4ABD-B6E6-C48ECD781BAB}.Release|Any CPU.Build.0 = Release|Any CPU
- {92599C09-FF29-4ABD-B6E6-C48ECD781BAB}.Release|Mixed Platforms.ActiveCfg = Release|Any CPU
- {92599C09-FF29-4ABD-B6E6-C48ECD781BAB}.Release|Mixed Platforms.Build.0 = Release|Any CPU
{92599C09-FF29-4ABD-B6E6-C48ECD781BAB}.Release|x86.ActiveCfg = Release|Any CPU
{92599C09-FF29-4ABD-B6E6-C48ECD781BAB}.Release|x86.Build.0 = Release|Any CPU
{9C0ECC4C-7807-4111-916A-4F57BB29788A}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{9C0ECC4C-7807-4111-916A-4F57BB29788A}.Debug|Any CPU.Build.0 = Debug|Any CPU
- {9C0ECC4C-7807-4111-916A-4F57BB29788A}.Debug|Mixed Platforms.ActiveCfg = Debug|Any CPU
- {9C0ECC4C-7807-4111-916A-4F57BB29788A}.Debug|Mixed Platforms.Build.0 = Debug|Any CPU
{9C0ECC4C-7807-4111-916A-4F57BB29788A}.Debug|x86.ActiveCfg = Debug|Any CPU
{9C0ECC4C-7807-4111-916A-4F57BB29788A}.Debug|x86.Build.0 = Debug|Any CPU
{9C0ECC4C-7807-4111-916A-4F57BB29788A}.Release|Any CPU.ActiveCfg = Release|Any CPU
{9C0ECC4C-7807-4111-916A-4F57BB29788A}.Release|Any CPU.Build.0 = Release|Any CPU
- {9C0ECC4C-7807-4111-916A-4F57BB29788A}.Release|Mixed Platforms.ActiveCfg = Release|Any CPU
- {9C0ECC4C-7807-4111-916A-4F57BB29788A}.Release|Mixed Platforms.Build.0 = Release|Any CPU
{9C0ECC4C-7807-4111-916A-4F57BB29788A}.Release|x86.ActiveCfg = Release|Any CPU
{9C0ECC4C-7807-4111-916A-4F57BB29788A}.Release|x86.Build.0 = Release|Any CPU
{9801F62C-540F-4BFE-9211-6405DEDE563B}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{9801F62C-540F-4BFE-9211-6405DEDE563B}.Debug|Any CPU.Build.0 = Debug|Any CPU
- {9801F62C-540F-4BFE-9211-6405DEDE563B}.Debug|Mixed Platforms.ActiveCfg = Debug|Any CPU
- {9801F62C-540F-4BFE-9211-6405DEDE563B}.Debug|Mixed Platforms.Build.0 = Debug|Any CPU
{9801F62C-540F-4BFE-9211-6405DEDE563B}.Debug|x86.ActiveCfg = Debug|Any CPU
{9801F62C-540F-4BFE-9211-6405DEDE563B}.Debug|x86.Build.0 = Debug|Any CPU
{9801F62C-540F-4BFE-9211-6405DEDE563B}.Release|Any CPU.ActiveCfg = Release|Any CPU
{9801F62C-540F-4BFE-9211-6405DEDE563B}.Release|Any CPU.Build.0 = Release|Any CPU
- {9801F62C-540F-4BFE-9211-6405DEDE563B}.Release|Mixed Platforms.ActiveCfg = Release|Any CPU
- {9801F62C-540F-4BFE-9211-6405DEDE563B}.Release|Mixed Platforms.Build.0 = Release|Any CPU
{9801F62C-540F-4BFE-9211-6405DEDE563B}.Release|x86.ActiveCfg = Release|Any CPU
{9801F62C-540F-4BFE-9211-6405DEDE563B}.Release|x86.Build.0 = Release|Any CPU
EndGlobalSection
diff --git a/Greenshot.sln.DotSettings b/Greenshot.sln.DotSettings
new file mode 100644
index 000000000..aecc39af3
--- /dev/null
+++ b/Greenshot.sln.DotSettings
@@ -0,0 +1,4 @@
+
+ True
+ True
+ True
\ No newline at end of file
diff --git a/Greenshot/Configuration/EditorConfiguration.cs b/Greenshot/Configuration/EditorConfiguration.cs
index 61bdc0733..019ea9ef6 100644
--- a/Greenshot/Configuration/EditorConfiguration.cs
+++ b/Greenshot/Configuration/EditorConfiguration.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/Greenshot/Configuration/LanguageKeys.cs b/Greenshot/Configuration/LanguageKeys.cs
index 08f982374..022f141f1 100644
--- a/Greenshot/Configuration/LanguageKeys.cs
+++ b/Greenshot/Configuration/LanguageKeys.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/Greenshot/Controls/BindableToolStripButton.cs b/Greenshot/Controls/BindableToolStripButton.cs
index 893264403..b44a1a31c 100644
--- a/Greenshot/Controls/BindableToolStripButton.cs
+++ b/Greenshot/Controls/BindableToolStripButton.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/Greenshot/Controls/BindableToolStripComboBox.cs b/Greenshot/Controls/BindableToolStripComboBox.cs
index e6e8ad105..3637f2380 100644
--- a/Greenshot/Controls/BindableToolStripComboBox.cs
+++ b/Greenshot/Controls/BindableToolStripComboBox.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/Greenshot/Controls/BindableToolStripDropDownButton.cs b/Greenshot/Controls/BindableToolStripDropDownButton.cs
index 4a04e1f23..4071d6b81 100644
--- a/Greenshot/Controls/BindableToolStripDropDownButton.cs
+++ b/Greenshot/Controls/BindableToolStripDropDownButton.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/Greenshot/Controls/ColorButton.cs b/Greenshot/Controls/ColorButton.cs
index 935729732..fe31d2e11 100644
--- a/Greenshot/Controls/ColorButton.cs
+++ b/Greenshot/Controls/ColorButton.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
@@ -24,6 +24,7 @@ using System.Drawing;
using System.Drawing.Drawing2D;
using System.Windows.Forms;
using GreenshotPlugin.Controls;
+using ColorDialog = Greenshot.Forms.ColorDialog;
namespace Greenshot.Controls {
///
diff --git a/Greenshot/Controls/ContextMenuToolStripProfessionalRenderer.cs b/Greenshot/Controls/ContextMenuToolStripProfessionalRenderer.cs
index 5031f82bb..e5ebf5478 100644
--- a/Greenshot/Controls/ContextMenuToolStripProfessionalRenderer.cs
+++ b/Greenshot/Controls/ContextMenuToolStripProfessionalRenderer.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/Greenshot/Controls/CustomToolStripProfessionalRenderer.cs b/Greenshot/Controls/CustomToolStripProfessionalRenderer.cs
index cb851ea2f..d559d771b 100644
--- a/Greenshot/Controls/CustomToolStripProfessionalRenderer.cs
+++ b/Greenshot/Controls/CustomToolStripProfessionalRenderer.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/Greenshot/Controls/FontFamilyComboBox.cs b/Greenshot/Controls/FontFamilyComboBox.cs
index dc5975be3..d37244eab 100644
--- a/Greenshot/Controls/FontFamilyComboBox.cs
+++ b/Greenshot/Controls/FontFamilyComboBox.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/Greenshot/Controls/MenuStripEx.cs b/Greenshot/Controls/MenuStripEx.cs
index ea973a791..31aa8f190 100644
--- a/Greenshot/Controls/MenuStripEx.cs
+++ b/Greenshot/Controls/MenuStripEx.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/Greenshot/Controls/NonJumpingPanel.cs b/Greenshot/Controls/NonJumpingPanel.cs
index 51658a105..d5565c637 100644
--- a/Greenshot/Controls/NonJumpingPanel.cs
+++ b/Greenshot/Controls/NonJumpingPanel.cs
@@ -1,6 +1,6 @@
-/*
+/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
@@ -22,33 +22,49 @@
using System.Drawing;
using System.Windows.Forms;
-namespace GreenshotPlugin.Controls {
- ///
- /// See: http://nickstips.wordpress.com/2010/03/03/c-panel-resets-scroll-position-after-focus-is-lost-and-regained/
- ///
- public class NonJumpingPanel : Panel {
- protected override Point ScrollToControl(Control activeControl) {
- // Returning the current location prevents the panel from
- // scrolling to the active control when the panel loses and regains focus
- return DisplayRectangle.Location;
- }
+namespace Greenshot.Controls
+{
+ ///
+ /// See: http://nickstips.wordpress.com/2010/03/03/c-panel-resets-scroll-position-after-focus-is-lost-and-regained/
+ ///
+ public class NonJumpingPanel : Panel
+ {
+ protected override Point ScrollToControl(Control activeControl)
+ {
+ // Returning the current location prevents the panel from
+ // scrolling to the active control when the panel loses and regains focus
+ return DisplayRectangle.Location;
+ }
- ///
- /// Add horizontal scrolling to the panel, when using the wheel and the shift key is pressed
- ///
- /// MouseEventArgs
- protected override void OnMouseWheel(MouseEventArgs e)
- {
- if (VScroll && (ModifierKeys & Keys.Shift) == Keys.Shift)
- {
- VScroll = false;
- base.OnMouseWheel(e);
- VScroll = true;
- }
- else
- {
- base.OnMouseWheel(e);
- }
- }
- }
+ ///
+ /// Add horizontal scrolling to the panel, when using the wheel and the shift key is pressed
+ ///
+ /// MouseEventArgs
+ protected override void OnMouseWheel(MouseEventArgs e)
+ {
+ //Check if Scrollbars available and CTRL key pressed -> Zoom IN OUT
+ if ((VScroll || HScroll) && (ModifierKeys & Keys.Control) == Keys.Control)
+ {
+ VScroll = false;
+ HScroll = false;
+ base.OnMouseWheel(e);
+ VScroll = true;
+ HScroll = true;
+ }
+ else
+ {
+ //Vertical Scoll with SHIFT key pressed
+ if (VScroll && (ModifierKeys & Keys.Shift) == Keys.Shift)
+ {
+ VScroll = false;
+ base.OnMouseWheel(e);
+ VScroll = true;
+ }
+ else
+ {
+ base.OnMouseWheel(e);
+ }
+ }
+ }
+ }
}
diff --git a/Greenshot/Controls/Pipette.cs b/Greenshot/Controls/Pipette.cs
index bbe2b5686..ca7333d81 100644
--- a/Greenshot/Controls/Pipette.cs
+++ b/Greenshot/Controls/Pipette.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
@@ -25,6 +25,7 @@ using System.Windows.Forms;
using Greenshot.Forms;
using GreenshotPlugin.UnmanagedHelpers;
using GreenshotPlugin.UnmanagedHelpers.Enums;
+using ColorDialog = Greenshot.Forms.ColorDialog;
namespace Greenshot.Controls {
///
diff --git a/Greenshot/Controls/ToolStripColorButton.cs b/Greenshot/Controls/ToolStripColorButton.cs
index 706a54cf3..951e117fd 100644
--- a/Greenshot/Controls/ToolStripColorButton.cs
+++ b/Greenshot/Controls/ToolStripColorButton.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
@@ -24,6 +24,7 @@ using System.Drawing;
using System.Drawing.Drawing2D;
using System.Windows.Forms;
using GreenshotPlugin.Controls;
+using ColorDialog = Greenshot.Forms.ColorDialog;
namespace Greenshot.Controls {
public class ToolStripColorButton : ToolStripButton, INotifyPropertyChanged, IGreenshotLanguageBindable {
diff --git a/Greenshot/Controls/ToolStripEx.cs b/Greenshot/Controls/ToolStripEx.cs
index b3f669fdd..7d2ca63ed 100644
--- a/Greenshot/Controls/ToolStripEx.cs
+++ b/Greenshot/Controls/ToolStripEx.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/Greenshot/Controls/ToolStripNumericUpDown.cs b/Greenshot/Controls/ToolStripNumericUpDown.cs
index 2cb53314b..13652fc41 100644
--- a/Greenshot/Controls/ToolStripNumericUpDown.cs
+++ b/Greenshot/Controls/ToolStripNumericUpDown.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/Greenshot/Destinations/ClipboardDestination.cs b/Greenshot/Destinations/ClipboardDestination.cs
index 9cfb0aec5..a1172ede4 100644
--- a/Greenshot/Destinations/ClipboardDestination.cs
+++ b/Greenshot/Destinations/ClipboardDestination.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/Greenshot/Destinations/EditorDestination.cs b/Greenshot/Destinations/EditorDestination.cs
index 09cce0f56..415607640 100644
--- a/Greenshot/Destinations/EditorDestination.cs
+++ b/Greenshot/Destinations/EditorDestination.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
@@ -22,6 +22,7 @@ using System;
using System.Collections.Generic;
using System.Drawing;
using Greenshot.Configuration;
+using Greenshot.Forms;
using GreenshotPlugin.Core;
using GreenshotPlugin.IniFile;
using GreenshotPlugin.Interfaces;
diff --git a/Greenshot/Destinations/EmailDestination.cs b/Greenshot/Destinations/EmailDestination.cs
index abda77c7c..326e27e9c 100644
--- a/Greenshot/Destinations/EmailDestination.cs
+++ b/Greenshot/Destinations/EmailDestination.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
@@ -26,6 +26,7 @@ using Greenshot.Configuration;
using Greenshot.Helpers;
using GreenshotPlugin.Core;
using GreenshotPlugin.Interfaces;
+using Microsoft.Win32;
namespace Greenshot.Destinations {
///
@@ -39,12 +40,9 @@ namespace Greenshot.Destinations {
static EmailDestination() {
// Logic to decide what email implementation we use
- if (!EmailConfigHelper.HasMapi()) return;
-
- _isActiveFlag = false;
- _mapiClient = EmailConfigHelper.GetMapiClient();
+ _mapiClient = RegistryHive.LocalMachine.ReadKey64Or32(@"Clients\Mail");
if (!string.IsNullOrEmpty(_mapiClient)) {
- // Active as we have a mapi client, can be disabled later
+ // Active as we have a MAPI client, can be disabled later
_isActiveFlag = true;
}
}
@@ -66,11 +64,9 @@ namespace Greenshot.Destinations {
if (_isActiveFlag) {
// Disable if the office plugin is installed and the client is outlook
// TODO: Change this! It always creates an exception, as the plugin has not been loaded the type is not there :(
- Type outlookdestination = Type.GetType("GreenshotOfficePlugin.OutlookDestination,GreenshotOfficePlugin");
- if (outlookdestination != null) {
- if (_mapiClient.ToLower().Contains("microsoft outlook")) {
- _isActiveFlag = false;
- }
+ var outlookDestination = Type.GetType("GreenshotOfficePlugin.OutlookDestination,GreenshotOfficePlugin", false);
+ if (outlookDestination != null && _mapiClient.ToLower().Contains("microsoft outlook")) {
+ _isActiveFlag = false;
}
}
return base.IsActive && _isActiveFlag;
diff --git a/Greenshot/Destinations/FileDestination.cs b/Greenshot/Destinations/FileDestination.cs
index 559d28135..d6e89c0d5 100644
--- a/Greenshot/Destinations/FileDestination.cs
+++ b/Greenshot/Destinations/FileDestination.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
@@ -24,6 +24,7 @@ using System.IO;
using System.Windows.Forms;
using Greenshot.Configuration;
+using Greenshot.Forms;
using GreenshotPlugin.Core;
using GreenshotPlugin.Controls;
using GreenshotPlugin.IniFile;
diff --git a/Greenshot/Destinations/FileWithDialogDestination.cs b/Greenshot/Destinations/FileWithDialogDestination.cs
index e211d14f7..b378f5f34 100644
--- a/Greenshot/Destinations/FileWithDialogDestination.cs
+++ b/Greenshot/Destinations/FileWithDialogDestination.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/Greenshot/Destinations/PickerDestination.cs b/Greenshot/Destinations/PickerDestination.cs
index 26f8fbfb5..e7ea94c83 100644
--- a/Greenshot/Destinations/PickerDestination.cs
+++ b/Greenshot/Destinations/PickerDestination.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/Greenshot/Destinations/PrinterDestination.cs b/Greenshot/Destinations/PrinterDestination.cs
index e2156256b..3a45268e2 100644
--- a/Greenshot/Destinations/PrinterDestination.cs
+++ b/Greenshot/Destinations/PrinterDestination.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/Greenshot/Drawing/Adorners/AbstractAdorner.cs b/Greenshot/Drawing/Adorners/AbstractAdorner.cs
index ecf0ce53d..5461b4df4 100644
--- a/Greenshot/Drawing/Adorners/AbstractAdorner.cs
+++ b/Greenshot/Drawing/Adorners/AbstractAdorner.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on Sourceforge: http://sourceforge.net/projects/greenshot/
diff --git a/Greenshot/Drawing/Adorners/MoveAdorner.cs b/Greenshot/Drawing/Adorners/MoveAdorner.cs
index 916d569f4..c8ef3ea22 100644
--- a/Greenshot/Drawing/Adorners/MoveAdorner.cs
+++ b/Greenshot/Drawing/Adorners/MoveAdorner.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on Sourceforge: http://sourceforge.net/projects/greenshot/
diff --git a/Greenshot/Drawing/Adorners/ResizeAdorner.cs b/Greenshot/Drawing/Adorners/ResizeAdorner.cs
index d624add48..b2e7261a9 100644
--- a/Greenshot/Drawing/Adorners/ResizeAdorner.cs
+++ b/Greenshot/Drawing/Adorners/ResizeAdorner.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on Sourceforge: http://sourceforge.net/projects/greenshot/
diff --git a/Greenshot/Drawing/Adorners/TargetAdorner.cs b/Greenshot/Drawing/Adorners/TargetAdorner.cs
index 542657c14..e0d0bbf13 100644
--- a/Greenshot/Drawing/Adorners/TargetAdorner.cs
+++ b/Greenshot/Drawing/Adorners/TargetAdorner.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on Sourceforge: http://sourceforge.net/projects/greenshot/
diff --git a/Greenshot/Drawing/ArrowContainer.cs b/Greenshot/Drawing/ArrowContainer.cs
index 739f9d430..acfd1ad03 100644
--- a/Greenshot/Drawing/ArrowContainer.cs
+++ b/Greenshot/Drawing/ArrowContainer.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/Greenshot/Drawing/CropContainer.cs b/Greenshot/Drawing/CropContainer.cs
index 58cee17b1..da160f11e 100644
--- a/Greenshot/Drawing/CropContainer.cs
+++ b/Greenshot/Drawing/CropContainer.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
@@ -57,12 +57,13 @@ namespace Greenshot.Drawing {
/// (we create a transparent brown over the complete picture)
///
public override Rectangle DrawingBounds {
- get {
- if (_parent?.Image is Image image) {
+ get
+ {
+ if (_parent?.Image is { } image) {
return new Rectangle(0, 0, image.Width, image.Height);
- } else {
- return Rectangle.Empty;
}
+
+ return Rectangle.Empty;
}
}
@@ -89,11 +90,9 @@ namespace Greenshot.Drawing {
g.FillRectangle(cropBrush, new Rectangle(0, cropRectangle.Top + cropRectangle.Height, imageSize.Width, imageSize.Height - (cropRectangle.Top + cropRectangle.Height)));
}
- public override bool HasContextMenu {
- get {
- // No context menu for the CropContainer
- return false;
- }
- }
+ ///
+ /// No context menu for the CropContainer
+ ///
+ public override bool HasContextMenu => false;
}
}
diff --git a/Greenshot/Drawing/CursorContainer.cs b/Greenshot/Drawing/CursorContainer.cs
index 1c756dd83..7b3078510 100644
--- a/Greenshot/Drawing/CursorContainer.cs
+++ b/Greenshot/Drawing/CursorContainer.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/Greenshot/Drawing/DrawableContainer.cs b/Greenshot/Drawing/DrawableContainer.cs
index 6c4433662..bc0973300 100644
--- a/Greenshot/Drawing/DrawableContainer.cs
+++ b/Greenshot/Drawing/DrawableContainer.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
@@ -98,8 +98,8 @@ namespace Greenshot.Drawing
[NonSerialized]
private PropertyChangedEventHandler _propertyChanged;
public event PropertyChangedEventHandler PropertyChanged {
- add { _propertyChanged += value; }
- remove{ _propertyChanged -= value; }
+ add => _propertyChanged += value;
+ remove => _propertyChanged -= value;
}
public IList Filters {
@@ -117,22 +117,18 @@ namespace Greenshot.Drawing
[NonSerialized]
internal Surface _parent;
public ISurface Parent {
- get { return _parent; }
- set { SwitchParent((Surface)value); }
+ get => _parent;
+ set => SwitchParent((Surface)value);
}
[NonSerialized]
private TargetAdorner _targetAdorner;
- public TargetAdorner TargetAdorner {
- get {
- return _targetAdorner;
- }
- }
+ public TargetAdorner TargetAdorner => _targetAdorner;
[NonSerialized]
private bool _selected;
public bool Selected {
- get {return _selected;}
+ get => _selected;
set {
_selected = value;
OnPropertyChanged("Selected");
@@ -142,18 +138,14 @@ namespace Greenshot.Drawing
[NonSerialized]
private EditStatus _status = EditStatus.UNDRAWN;
public EditStatus Status {
- get {
- return _status;
- }
- set {
- _status = value;
- }
+ get => _status;
+ set => _status = value;
}
private int left;
public int Left {
- get { return left; }
+ get => left;
set {
if (value == left) {
return;
@@ -164,7 +156,7 @@ namespace Greenshot.Drawing
private int top;
public int Top {
- get { return top; }
+ get => top;
set {
if (value == top) {
return;
@@ -175,7 +167,7 @@ namespace Greenshot.Drawing
private int width;
public int Width {
- get { return width; }
+ get => width;
set {
if (value == width) {
return;
@@ -186,7 +178,7 @@ namespace Greenshot.Drawing
private int height;
public int Height {
- get { return height; }
+ get => height;
set {
if (value == height) {
return;
@@ -196,9 +188,7 @@ namespace Greenshot.Drawing
}
public Point Location {
- get {
- return new Point(left, top);
- }
+ get => new Point(left, top);
set {
left = value.X;
top = value.Y;
@@ -330,11 +320,7 @@ namespace Greenshot.Drawing
Adorners.Add(new ResizeAdorner(this, Positions.MiddleRight));
}
- public bool hasFilters {
- get {
- return Filters.Count > 0;
- }
- }
+ public bool hasFilters => Filters.Count > 0;
public abstract void Draw(Graphics graphics, RenderMode renderMode);
diff --git a/Greenshot/Drawing/DrawableContainerList.cs b/Greenshot/Drawing/DrawableContainerList.cs
index 666986002..a7107543e 100644
--- a/Greenshot/Drawing/DrawableContainerList.cs
+++ b/Greenshot/Drawing/DrawableContainerList.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
@@ -30,6 +30,7 @@ using System.Drawing;
using System.Drawing.Drawing2D;
using System.Threading;
using System.Windows.Forms;
+using Greenshot.Forms;
using GreenshotPlugin.Interfaces;
namespace Greenshot.Drawing {
diff --git a/Greenshot/Drawing/EllipseContainer.cs b/Greenshot/Drawing/EllipseContainer.cs
index c7a3985d6..b7d03ecfe 100644
--- a/Greenshot/Drawing/EllipseContainer.cs
+++ b/Greenshot/Drawing/EllipseContainer.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/Greenshot/Drawing/Fields/AbstractFieldHolder.cs b/Greenshot/Drawing/Fields/AbstractFieldHolder.cs
index 561501634..48dfd95f9 100644
--- a/Greenshot/Drawing/Fields/AbstractFieldHolder.cs
+++ b/Greenshot/Drawing/Fields/AbstractFieldHolder.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/Greenshot/Drawing/Fields/AbstractFieldHolderWithChildren.cs b/Greenshot/Drawing/Fields/AbstractFieldHolderWithChildren.cs
index 636e708e4..bb6ae068c 100644
--- a/Greenshot/Drawing/Fields/AbstractFieldHolderWithChildren.cs
+++ b/Greenshot/Drawing/Fields/AbstractFieldHolderWithChildren.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/Greenshot/Drawing/Fields/Binding/AbstractBindingConverter.cs b/Greenshot/Drawing/Fields/Binding/AbstractBindingConverter.cs
index ff3232d2f..a1ffd80c1 100644
--- a/Greenshot/Drawing/Fields/Binding/AbstractBindingConverter.cs
+++ b/Greenshot/Drawing/Fields/Binding/AbstractBindingConverter.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/Greenshot/Drawing/Fields/Binding/BidirectionalBinding.cs b/Greenshot/Drawing/Fields/Binding/BidirectionalBinding.cs
index 28a4bddf0..5a9652d5c 100644
--- a/Greenshot/Drawing/Fields/Binding/BidirectionalBinding.cs
+++ b/Greenshot/Drawing/Fields/Binding/BidirectionalBinding.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/Greenshot/Drawing/Fields/Binding/DecimalDoublePercentageConverter.cs b/Greenshot/Drawing/Fields/Binding/DecimalDoublePercentageConverter.cs
index b1efb78f3..0ac7d02bb 100644
--- a/Greenshot/Drawing/Fields/Binding/DecimalDoublePercentageConverter.cs
+++ b/Greenshot/Drawing/Fields/Binding/DecimalDoublePercentageConverter.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/Greenshot/Drawing/Fields/Binding/DecimalFloatConverter.cs b/Greenshot/Drawing/Fields/Binding/DecimalFloatConverter.cs
index 70581bc10..528af1c2e 100644
--- a/Greenshot/Drawing/Fields/Binding/DecimalFloatConverter.cs
+++ b/Greenshot/Drawing/Fields/Binding/DecimalFloatConverter.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/Greenshot/Drawing/Fields/Binding/DecimalIntConverter.cs b/Greenshot/Drawing/Fields/Binding/DecimalIntConverter.cs
index 693e532dd..6a8ff7e84 100644
--- a/Greenshot/Drawing/Fields/Binding/DecimalIntConverter.cs
+++ b/Greenshot/Drawing/Fields/Binding/DecimalIntConverter.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/Greenshot/Drawing/Fields/Binding/IBindingConverter.cs b/Greenshot/Drawing/Fields/Binding/IBindingConverter.cs
index 1a8fcefc3..cdb573470 100644
--- a/Greenshot/Drawing/Fields/Binding/IBindingConverter.cs
+++ b/Greenshot/Drawing/Fields/Binding/IBindingConverter.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/Greenshot/Drawing/Fields/Binding/IBindingValidator.cs b/Greenshot/Drawing/Fields/Binding/IBindingValidator.cs
index 146b91afb..d21b575a4 100644
--- a/Greenshot/Drawing/Fields/Binding/IBindingValidator.cs
+++ b/Greenshot/Drawing/Fields/Binding/IBindingValidator.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/Greenshot/Drawing/Fields/Binding/NotNullValidator.cs b/Greenshot/Drawing/Fields/Binding/NotNullValidator.cs
index 692254c37..5d15b6699 100644
--- a/Greenshot/Drawing/Fields/Binding/NotNullValidator.cs
+++ b/Greenshot/Drawing/Fields/Binding/NotNullValidator.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/Greenshot/Drawing/Fields/Field.cs b/Greenshot/Drawing/Fields/Field.cs
index 798444625..f08033fd0 100644
--- a/Greenshot/Drawing/Fields/Field.cs
+++ b/Greenshot/Drawing/Fields/Field.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/Greenshot/Drawing/Fields/FieldAggregator.cs b/Greenshot/Drawing/Fields/FieldAggregator.cs
index c22268091..6606a96b1 100644
--- a/Greenshot/Drawing/Fields/FieldAggregator.cs
+++ b/Greenshot/Drawing/Fields/FieldAggregator.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/Greenshot/Drawing/Fields/FieldType.cs b/Greenshot/Drawing/Fields/FieldType.cs
index 9976d24af..7531e5b27 100644
--- a/Greenshot/Drawing/Fields/FieldType.cs
+++ b/Greenshot/Drawing/Fields/FieldType.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/Greenshot/Drawing/FilterContainer.cs b/Greenshot/Drawing/FilterContainer.cs
index 489e8e357..9ea6bc1a1 100644
--- a/Greenshot/Drawing/FilterContainer.cs
+++ b/Greenshot/Drawing/FilterContainer.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/Greenshot/Drawing/Filters/AbstractFilter.cs b/Greenshot/Drawing/Filters/AbstractFilter.cs
index 7c54545bd..419038d40 100644
--- a/Greenshot/Drawing/Filters/AbstractFilter.cs
+++ b/Greenshot/Drawing/Filters/AbstractFilter.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/Greenshot/Drawing/Filters/BlurFilter.cs b/Greenshot/Drawing/Filters/BlurFilter.cs
index 711c1d02b..79f617ac6 100644
--- a/Greenshot/Drawing/Filters/BlurFilter.cs
+++ b/Greenshot/Drawing/Filters/BlurFilter.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/Greenshot/Drawing/Filters/BrightnessFilter.cs b/Greenshot/Drawing/Filters/BrightnessFilter.cs
index 852aca9de..a43a68f67 100644
--- a/Greenshot/Drawing/Filters/BrightnessFilter.cs
+++ b/Greenshot/Drawing/Filters/BrightnessFilter.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/Greenshot/Drawing/Filters/GrayscaleFilter.cs b/Greenshot/Drawing/Filters/GrayscaleFilter.cs
index 4758d12bd..f66b29fba 100644
--- a/Greenshot/Drawing/Filters/GrayscaleFilter.cs
+++ b/Greenshot/Drawing/Filters/GrayscaleFilter.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/Greenshot/Drawing/Filters/HighlightFilter.cs b/Greenshot/Drawing/Filters/HighlightFilter.cs
index 36c574493..38b6a8ee7 100644
--- a/Greenshot/Drawing/Filters/HighlightFilter.cs
+++ b/Greenshot/Drawing/Filters/HighlightFilter.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/Greenshot/Drawing/Filters/IFilter.cs b/Greenshot/Drawing/Filters/IFilter.cs
index 91fdfe74d..8c3b5b23e 100644
--- a/Greenshot/Drawing/Filters/IFilter.cs
+++ b/Greenshot/Drawing/Filters/IFilter.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/Greenshot/Drawing/Filters/MagnifierFilter.cs b/Greenshot/Drawing/Filters/MagnifierFilter.cs
index 601d09967..68b033ef5 100644
--- a/Greenshot/Drawing/Filters/MagnifierFilter.cs
+++ b/Greenshot/Drawing/Filters/MagnifierFilter.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/Greenshot/Drawing/Filters/PixelizationFilter.cs b/Greenshot/Drawing/Filters/PixelizationFilter.cs
index 7be7d47a6..dbf19d3f7 100644
--- a/Greenshot/Drawing/Filters/PixelizationFilter.cs
+++ b/Greenshot/Drawing/Filters/PixelizationFilter.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/Greenshot/Drawing/FreehandContainer.cs b/Greenshot/Drawing/FreehandContainer.cs
index c7d5cf1e8..0485f2ae5 100644
--- a/Greenshot/Drawing/FreehandContainer.cs
+++ b/Greenshot/Drawing/FreehandContainer.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/Greenshot/Drawing/HighlightContainer.cs b/Greenshot/Drawing/HighlightContainer.cs
index 858e1508b..788360004 100644
--- a/Greenshot/Drawing/HighlightContainer.cs
+++ b/Greenshot/Drawing/HighlightContainer.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/Greenshot/Drawing/IconContainer.cs b/Greenshot/Drawing/IconContainer.cs
index 2924a376f..6d5c90986 100644
--- a/Greenshot/Drawing/IconContainer.cs
+++ b/Greenshot/Drawing/IconContainer.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/Greenshot/Drawing/ImageContainer.cs b/Greenshot/Drawing/ImageContainer.cs
index 2d96d12c8..5840c9507 100644
--- a/Greenshot/Drawing/ImageContainer.cs
+++ b/Greenshot/Drawing/ImageContainer.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/Greenshot/Drawing/LineContainer.cs b/Greenshot/Drawing/LineContainer.cs
index af73529d4..eac855644 100644
--- a/Greenshot/Drawing/LineContainer.cs
+++ b/Greenshot/Drawing/LineContainer.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/Greenshot/Drawing/ObfuscateContainer.cs b/Greenshot/Drawing/ObfuscateContainer.cs
index 07ea899ba..f1fdbf156 100644
--- a/Greenshot/Drawing/ObfuscateContainer.cs
+++ b/Greenshot/Drawing/ObfuscateContainer.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/Greenshot/Drawing/Positions.cs b/Greenshot/Drawing/Positions.cs
index 847d08415..f7061d023 100644
--- a/Greenshot/Drawing/Positions.cs
+++ b/Greenshot/Drawing/Positions.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on Sourceforge: http://sourceforge.net/projects/greenshot/
diff --git a/Greenshot/Drawing/RectangleContainer.cs b/Greenshot/Drawing/RectangleContainer.cs
index 623e28b22..2e86fa509 100644
--- a/Greenshot/Drawing/RectangleContainer.cs
+++ b/Greenshot/Drawing/RectangleContainer.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/Greenshot/Drawing/RoundedRectangle.cs b/Greenshot/Drawing/RoundedRectangle.cs
index 8a519d1ed..a5d4ea6a0 100644
--- a/Greenshot/Drawing/RoundedRectangle.cs
+++ b/Greenshot/Drawing/RoundedRectangle.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/Greenshot/Drawing/SpeechbubbleContainer.cs b/Greenshot/Drawing/SpeechbubbleContainer.cs
index f585af7aa..ee00714e9 100644
--- a/Greenshot/Drawing/SpeechbubbleContainer.cs
+++ b/Greenshot/Drawing/SpeechbubbleContainer.cs
@@ -329,5 +329,17 @@ namespace Greenshot.Drawing
public override bool ClickableAt(int x, int y) {
return Contains(x,y);
}
+
+ ///
+ /// Additional to the Transform of the TextContainer the bubble tail coordinates also need to be moved
+ ///
+ /// Matrix
+ public override void Transform(Matrix matrix)
+ {
+ Point[] points = { TargetAdorner.Location };
+ matrix.TransformPoints(points);
+ TargetAdorner.Location = points[0];
+ base.Transform(matrix);
+ }
}
}
diff --git a/Greenshot/Drawing/Surface.cs b/Greenshot/Drawing/Surface.cs
index d7a4487fc..ed3118db6 100644
--- a/Greenshot/Drawing/Surface.cs
+++ b/Greenshot/Drawing/Surface.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/Greenshot/Drawing/TextContainer.cs b/Greenshot/Drawing/TextContainer.cs
index ddfb2918e..fda883f16 100644
--- a/Greenshot/Drawing/TextContainer.cs
+++ b/Greenshot/Drawing/TextContainer.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
@@ -67,25 +67,21 @@ namespace Greenshot.Drawing
// there is a binding on the following property!
public string Text
{
- get { return text; }
- set
- {
- ChangeText(value, true);
- }
+ get => text;
+ set => ChangeText(value, true);
}
internal void ChangeText(string newText, bool allowUndoable)
{
- if ((text == null && newText != null) || !string.Equals(text, newText))
+ if ((text != null || newText == null) && string.Equals(text, newText)) return;
+
+ if (makeUndoable && allowUndoable)
{
- if (makeUndoable && allowUndoable)
- {
- makeUndoable = false;
- _parent.MakeUndoable(new TextChangeMemento(this), false);
- }
- text = newText;
- OnPropertyChanged("Text");
+ makeUndoable = false;
+ _parent.MakeUndoable(new TextChangeMemento(this), false);
}
+ text = newText;
+ OnPropertyChanged("Text");
}
public TextContainer(Surface parent) : base(parent)
@@ -602,6 +598,41 @@ namespace Greenshot.Drawing
DrawText(graphics, rect, lineThickness, lineColor, drawShadow, _stringFormat, text, _font);
}
+ private static TextFormatFlags ConvertStringFormat(StringFormat stringFormat)
+ {
+ TextFormatFlags flags = TextFormatFlags.Default;
+ if (stringFormat == null)
+ {
+ return flags;
+ }
+ switch (stringFormat.LineAlignment)
+ {
+ case StringAlignment.Center:
+ flags |= TextFormatFlags.VerticalCenter;
+ break;
+ case StringAlignment.Far:
+ flags |= TextFormatFlags.Bottom;
+ break;
+ case StringAlignment.Near:
+ flags |= TextFormatFlags.Top;
+ break;
+ }
+ switch (stringFormat.Alignment)
+ {
+ case StringAlignment.Center:
+ flags |= TextFormatFlags.HorizontalCenter;
+ break;
+ case StringAlignment.Far:
+ flags |= TextFormatFlags.Right;
+ break;
+ case StringAlignment.Near:
+ flags |= TextFormatFlags.Left;
+ break;
+ }
+
+ return flags;
+ }
+
///
/// This method can be used from other containers
///
@@ -640,8 +671,8 @@ namespace Greenshot.Drawing
shadowRect.Inflate(-textOffset, -textOffset);
}
- using Brush fontBrush = new SolidBrush(Color.FromArgb(alpha, 100, 100, 100));
- graphics.DrawString(text, font, fontBrush, shadowRect, stringFormat);
+ TextRenderer.DrawText(graphics, text, font, shadowRect, Color.FromArgb(alpha, 100, 100, 100), ConvertStringFormat(stringFormat));
+
currentStep++;
alpha -= basealpha / steps;
}
@@ -651,16 +682,14 @@ namespace Greenshot.Drawing
{
drawingRectange.Inflate(-textOffset, -textOffset);
}
- using (Brush fontBrush = new SolidBrush(fontColor))
+
+ if (stringFormat != null)
{
- if (stringFormat != null)
- {
- graphics.DrawString(text, font, fontBrush, drawingRectange, stringFormat);
- }
- else
- {
- graphics.DrawString(text, font, fontBrush, drawingRectange);
- }
+ TextRenderer.DrawText(graphics, text, font, drawingRectange, fontColor, ConvertStringFormat(stringFormat));
+ }
+ else
+ {
+ TextRenderer.DrawText(graphics, text, font, drawingRectange, fontColor);
}
}
diff --git a/Greenshot/Forms/AboutForm.Designer.cs b/Greenshot/Forms/AboutForm.Designer.cs
index a2ff0904b..830237010 100644
--- a/Greenshot/Forms/AboutForm.Designer.cs
+++ b/Greenshot/Forms/AboutForm.Designer.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/Greenshot/Forms/AboutForm.cs b/Greenshot/Forms/AboutForm.cs
index 0be368cbe..f3c67edd8 100644
--- a/Greenshot/Forms/AboutForm.cs
+++ b/Greenshot/Forms/AboutForm.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
-* Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+* Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/Greenshot/Forms/AnimatingBaseForm.cs b/Greenshot/Forms/AnimatingBaseForm.cs
index db1c2b54d..5456ba037 100644
--- a/Greenshot/Forms/AnimatingBaseForm.cs
+++ b/Greenshot/Forms/AnimatingBaseForm.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
@@ -21,7 +21,7 @@
using GreenshotPlugin.Controls;
-namespace Greenshot {
+namespace Greenshot.Forms {
///
/// This class is only here to help in the Designer mode, so it's clear where the language files are
///
diff --git a/Greenshot/Forms/BaseForm.cs b/Greenshot/Forms/BaseForm.cs
index 392f37803..ffc0e86db 100644
--- a/Greenshot/Forms/BaseForm.cs
+++ b/Greenshot/Forms/BaseForm.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
@@ -21,7 +21,7 @@
using GreenshotPlugin.Controls;
-namespace Greenshot {
+namespace Greenshot.Forms {
///
/// This class is only here to help in the Designer mode, so it's clear where the language files are
///
diff --git a/Greenshot/Forms/BugReportForm.Designer.cs b/Greenshot/Forms/BugReportForm.Designer.cs
index 3b4c6afdb..2c5a7ae52 100644
--- a/Greenshot/Forms/BugReportForm.Designer.cs
+++ b/Greenshot/Forms/BugReportForm.Designer.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/Greenshot/Forms/BugReportForm.cs b/Greenshot/Forms/BugReportForm.cs
index f74aa431d..7c26e1b54 100644
--- a/Greenshot/Forms/BugReportForm.cs
+++ b/Greenshot/Forms/BugReportForm.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/Greenshot/Forms/CaptureForm.Designer.cs b/Greenshot/Forms/CaptureForm.Designer.cs
index ee3b43b99..9f36ebdb9 100644
--- a/Greenshot/Forms/CaptureForm.Designer.cs
+++ b/Greenshot/Forms/CaptureForm.Designer.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/Greenshot/Forms/CaptureForm.cs b/Greenshot/Forms/CaptureForm.cs
index bad4a0d24..bf21382e8 100644
--- a/Greenshot/Forms/CaptureForm.cs
+++ b/Greenshot/Forms/CaptureForm.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/Greenshot/Forms/ColorDialog.Designer.cs b/Greenshot/Forms/ColorDialog.Designer.cs
index 32330fb3a..d5060d8c0 100644
--- a/Greenshot/Forms/ColorDialog.Designer.cs
+++ b/Greenshot/Forms/ColorDialog.Designer.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
@@ -18,7 +18,7 @@
* You should have received a copy of the GNU General Public License
* along with this program. If not, see .
*/
-namespace Greenshot {
+namespace Greenshot.Forms {
public partial class ColorDialog {
///
/// Designer variable used to keep track of non-visual components.
diff --git a/Greenshot/Forms/ColorDialog.cs b/Greenshot/Forms/ColorDialog.cs
index bcf7e8889..f69c8f2fc 100644
--- a/Greenshot/Forms/ColorDialog.cs
+++ b/Greenshot/Forms/ColorDialog.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
@@ -19,17 +19,17 @@
* along with this program. If not, see .
*/
-using Greenshot.Configuration;
-using Greenshot.Controls;
using System;
using System.Collections.Generic;
using System.Drawing;
using System.Globalization;
using System.Threading;
using System.Windows.Forms;
+using Greenshot.Configuration;
+using Greenshot.Controls;
using GreenshotPlugin.IniFile;
-namespace Greenshot {
+namespace Greenshot.Forms {
///
/// Description of ColorDialog.
///
diff --git a/Greenshot/Forms/ColorPickerToolStripButton.cs b/Greenshot/Forms/ColorPickerToolStripButton.cs
index 53816dca5..8f7730845 100644
--- a/Greenshot/Forms/ColorPickerToolStripButton.cs
+++ b/Greenshot/Forms/ColorPickerToolStripButton.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
@@ -20,12 +20,12 @@
*/
using System;
+using System.Diagnostics;
using System.Drawing;
using System.Drawing.Imaging;
using System.Windows.Forms;
-using System.Diagnostics;
-namespace Greenshot
+namespace Greenshot.Forms
{
public delegate void ColorPickerEventHandler(object o, ColorPickerEventArgs e);
@@ -34,12 +34,12 @@ namespace Greenshot
private Color _color;
public Point Offset = new Point(0,0);
public event ColorPickerEventHandler ColorPicked;
- private readonly Greenshot.ColorDialog _cd;
+ private readonly ColorDialog _cd;
public ColorPickerToolStripButton()
{
- _cd = Greenshot.ColorDialog.GetInstance();
+ _cd = ColorDialog.GetInstance();
Click += ToolStripButton1Click;
}
diff --git a/Greenshot/Forms/DropShadowSettingsForm.Designer.cs b/Greenshot/Forms/DropShadowSettingsForm.Designer.cs
index ba8e7b3bc..0f7a89618 100644
--- a/Greenshot/Forms/DropShadowSettingsForm.Designer.cs
+++ b/Greenshot/Forms/DropShadowSettingsForm.Designer.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/Greenshot/Forms/DropShadowSettingsForm.cs b/Greenshot/Forms/DropShadowSettingsForm.cs
index 2511a3328..4f7c413c7 100644
--- a/Greenshot/Forms/DropShadowSettingsForm.cs
+++ b/Greenshot/Forms/DropShadowSettingsForm.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/Greenshot/Forms/ImageEditorForm.Designer.cs b/Greenshot/Forms/ImageEditorForm.Designer.cs
index cce905007..0db33a212 100644
--- a/Greenshot/Forms/ImageEditorForm.Designer.cs
+++ b/Greenshot/Forms/ImageEditorForm.Designer.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
@@ -21,7 +21,7 @@
using Greenshot.Controls;
-namespace Greenshot {
+namespace Greenshot.Forms {
partial class ImageEditorForm {
///
/// Designer variable used to keep track of non-visual components.
@@ -56,7 +56,7 @@ namespace Greenshot {
this.dimensionsLabel = new System.Windows.Forms.ToolStripStatusLabel();
this.statusLabel = new System.Windows.Forms.ToolStripStatusLabel();
this.tableLayoutPanel1 = new System.Windows.Forms.TableLayoutPanel();
- this.panel1 = new GreenshotPlugin.Controls.NonJumpingPanel();
+ this.panel1 = new NonJumpingPanel();
this.toolsToolStrip = new Greenshot.Controls.ToolStripEx();
this.btnCursor = new GreenshotPlugin.Controls.GreenshotToolStripButton();
this.toolStripSeparator1 = new System.Windows.Forms.ToolStripSeparator();
@@ -1977,7 +1977,7 @@ namespace Greenshot {
private GreenshotPlugin.Controls.GreenshotToolStripButton btnRect;
private System.Windows.Forms.ToolStripContainer topToolStripContainer;
private Greenshot.Controls.ToolStripEx destinationsToolStrip;
- private GreenshotPlugin.Controls.NonJumpingPanel panel1;
+ private NonJumpingPanel panel1;
private Greenshot.Controls.ToolStripColorButton btnFillColor;
private Greenshot.Controls.ToolStripColorButton btnLineColor;
private GreenshotPlugin.Controls.GreenshotToolStripMenuItem autoCropToolStripMenuItem;
diff --git a/Greenshot/Forms/ImageEditorForm.cs b/Greenshot/Forms/ImageEditorForm.cs
index 6e19df179..a9fe79239 100644
--- a/Greenshot/Forms/ImageEditorForm.cs
+++ b/Greenshot/Forms/ImageEditorForm.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
@@ -31,7 +31,6 @@ using Greenshot.Destinations;
using Greenshot.Drawing;
using Greenshot.Drawing.Fields;
using Greenshot.Drawing.Fields.Binding;
-using Greenshot.Forms;
using Greenshot.Help;
using Greenshot.Helpers;
using GreenshotPlugin.Controls;
@@ -45,7 +44,7 @@ using GreenshotPlugin.UnmanagedHelpers;
using GreenshotPlugin.UnmanagedHelpers.Structs;
using log4net;
-namespace Greenshot {
+namespace Greenshot.Forms {
///
/// Description of ImageEditorForm.
///
@@ -66,6 +65,9 @@ namespace Greenshot {
// whether part of the editor controls are disabled depending on selected item(s)
private bool _controlsDisabledDueToConfirmable;
+ // Used for tracking the mouse scrollwheel changes
+ private DateTime _zoomStartTime = DateTime.Now;
+
///
/// All provided zoom values (in percents) in ascending order.
///
@@ -904,11 +906,33 @@ namespace Greenshot {
///
///
///
- private void PanelMouseWheel(object sender, MouseEventArgs e) {
+ ///
+ /// This is a "work-around" for the MouseWheel event which doesn't get to the panel
+ ///
+ ///
+ ///
+ private void PanelMouseWheel(object sender, MouseEventArgs e)
+ {
+ if (System.Windows.Forms.Control.ModifierKeys.Equals(Keys.Control))
+ {
+ if (_zoomStartTime.AddMilliseconds(100) < DateTime.Now) //waiting for next zoom step 100 ms
+ {
+ _zoomStartTime = DateTime.Now;
+ if (e.Delta > 0)
+ {
+ ZoomInMenuItemClick(sender, e);
+ }
+ else if (e.Delta < 0)
+ {
+ ZoomOutMenuItemClick(sender, e);
+ }
+ }
+
+ }
panel1.Focus();
}
- protected override bool ProcessKeyPreview(ref Message msg) {
+ protected override bool ProcessKeyPreview(ref Message msg) {
// disable default key handling if surface has requested a lock
if (!_surface.KeysLocked) {
return base.ProcessKeyPreview(ref msg);
diff --git a/Greenshot/Forms/LanguageDialog.Designer.cs b/Greenshot/Forms/LanguageDialog.Designer.cs
index 6ae29249b..6ad4c0e60 100644
--- a/Greenshot/Forms/LanguageDialog.Designer.cs
+++ b/Greenshot/Forms/LanguageDialog.Designer.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/Greenshot/Forms/LanguageDialog.cs b/Greenshot/Forms/LanguageDialog.cs
index 7d6ba2f33..d78c36008 100644
--- a/Greenshot/Forms/LanguageDialog.cs
+++ b/Greenshot/Forms/LanguageDialog.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/Greenshot/Forms/MainForm.Designer.cs b/Greenshot/Forms/MainForm.Designer.cs
index 751d43452..281886180 100644
--- a/Greenshot/Forms/MainForm.Designer.cs
+++ b/Greenshot/Forms/MainForm.Designer.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
@@ -18,7 +18,7 @@
* You should have received a copy of the GNU General Public License
* along with this program. If not, see .
*/
-namespace Greenshot {
+namespace Greenshot.Forms {
partial class MainForm {
///
/// Designer variable used to keep track of non-visual components.
diff --git a/Greenshot/Forms/MainForm.cs b/Greenshot/Forms/MainForm.cs
index 61f5141bd..4053b41f5 100644
--- a/Greenshot/Forms/MainForm.cs
+++ b/Greenshot/Forms/MainForm.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
@@ -29,25 +29,24 @@ using System.Linq;
using System.Reflection;
using System.Text;
using System.Threading;
+using System.Threading.Tasks;
using System.Windows.Forms;
using System.Windows.Forms.Integration;
using Greenshot.Configuration;
-using Greenshot.Forms;
-using Greenshot.Help;
-using Greenshot.Helpers;
-using GreenshotPlugin.UnmanagedHelpers;
-using GreenshotPlugin.Controls;
-using GreenshotPlugin.Core;
using Greenshot.Destinations;
using Greenshot.Drawing;
-using log4net;
-using Timer = System.Timers.Timer;
-using System.Threading.Tasks;
+using Greenshot.Help;
+using Greenshot.Helpers;
+using GreenshotPlugin.Controls;
+using GreenshotPlugin.Core;
using GreenshotPlugin.IniFile;
using GreenshotPlugin.Interfaces;
using GreenshotPlugin.Interfaces.Plugin;
+using GreenshotPlugin.UnmanagedHelpers;
+using log4net;
+using Timer = System.Timers.Timer;
-namespace Greenshot {
+namespace Greenshot.Forms {
///
/// Description of MainForm.
///
@@ -533,21 +532,26 @@ namespace Greenshot {
private static bool RegisterWrapper(StringBuilder failedKeys, string functionName, string configurationKey, HotKeyHandler handler, bool ignoreFailedRegistration) {
IniValue hotkeyValue = _conf.Values[configurationKey];
+ var hotkeyStringValue = hotkeyValue.Value?.ToString();
+ if (string.IsNullOrEmpty(hotkeyStringValue))
+ {
+ return true;
+ }
try {
- bool success = RegisterHotkey(failedKeys, functionName, hotkeyValue.Value.ToString(), handler);
+ bool success = RegisterHotkey(failedKeys, functionName, hotkeyStringValue, handler);
if (!success && ignoreFailedRegistration) {
- LOG.DebugFormat("Ignoring failed hotkey registration for {0}, with value '{1}', resetting to 'None'.", functionName, hotkeyValue);
+ LOG.DebugFormat("Ignoring failed hotkey registration for {0}, with value '{1}', resetting to 'None'.", functionName, hotkeyStringValue);
_conf.Values[configurationKey].Value = Keys.None.ToString();
_conf.IsDirty = true;
}
return success;
} catch (Exception ex) {
LOG.Warn(ex);
- LOG.WarnFormat("Restoring default hotkey for {0}, stored under {1} from '{2}' to '{3}'", functionName, configurationKey, hotkeyValue.Value, hotkeyValue.Attributes.DefaultValue);
+ LOG.WarnFormat("Restoring default hotkey for {0}, stored under {1} from '{2}' to '{3}'", functionName, configurationKey, hotkeyStringValue, hotkeyValue.Attributes.DefaultValue);
// when getting an exception the key wasn't found: reset the hotkey value
hotkeyValue.UseValueOrDefault(null);
hotkeyValue.ContainingIniSection.IsDirty = true;
- return RegisterHotkey(failedKeys, functionName, hotkeyValue.Value.ToString(), handler);
+ return RegisterHotkey(failedKeys, functionName, hotkeyStringValue, handler);
}
}
@@ -609,6 +613,10 @@ namespace Greenshot {
if (!RegisterWrapper(failedKeys, "CaptureLastRegion", "LastregionHotkey", _instance.CaptureLastRegion, ignoreFailedRegistration)) {
success = false;
}
+ if (!RegisterWrapper(failedKeys, "CaptureClipboard", "ClipboardHotkey", _instance.CaptureClipboard, true))
+ {
+ success = false;
+ }
if (_conf.IECapture) {
if (!RegisterWrapper(failedKeys, "CaptureIE", "IEHotkey", _instance.CaptureIE, ignoreFailedRegistration)) {
success = false;
@@ -689,7 +697,12 @@ namespace Greenshot {
contextmenu_capturewindow.ShortcutKeyDisplayString = HotkeyControl.GetLocalizedHotkeyStringFromString(_conf.WindowHotkey);
contextmenu_capturefullscreen.ShortcutKeyDisplayString = HotkeyControl.GetLocalizedHotkeyStringFromString(_conf.FullscreenHotkey);
contextmenu_captureie.ShortcutKeyDisplayString = HotkeyControl.GetLocalizedHotkeyStringFromString(_conf.IEHotkey);
- }
+ var clipboardHotkey = HotkeyControl.GetLocalizedHotkeyStringFromString(_conf.ClipboardHotkey);
+ if (!string.IsNullOrEmpty(clipboardHotkey) && !"None".Equals(clipboardHotkey))
+ {
+ contextmenu_captureclipboard.ShortcutKeyDisplayString = clipboardHotkey;
+ }
+ }
private void MainFormFormClosing(object sender, FormClosingEventArgs e) {
@@ -729,6 +742,14 @@ namespace Greenshot {
CaptureHelper.CaptureLastRegion(true);
}
+ ///
+ /// This is used by the hotkey trigger
+ ///
+ private void CaptureClipboard()
+ {
+ CaptureHelper.CaptureClipboard(DestinationHelper.GetDestination(EditorDestination.DESIGNATION));
+ }
+
private void CaptureIE() {
if (_conf.IECapture) {
CaptureHelper.CaptureIe(true, null);
@@ -1394,7 +1415,7 @@ namespace Greenshot {
catch (Exception ex)
{
// Make sure we show what we tried to open in the exception
- ex.Data.Add("path", path);
+ ex.Data["path"] = path;
LOG.Warn("Couldn't open the path to the last exported file", ex);
// No reason to create a bug-form, we just display the error.
MessageBox.Show(this, ex.Message, "Opening " + path, MessageBoxButtons.OK, MessageBoxIcon.Error);
diff --git a/Greenshot/Forms/MovableShowColorForm.cs b/Greenshot/Forms/MovableShowColorForm.cs
index 22c40183f..fb8e7df5f 100644
--- a/Greenshot/Forms/MovableShowColorForm.cs
+++ b/Greenshot/Forms/MovableShowColorForm.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/Greenshot/Forms/PrintOptionsDialog.Designer.cs b/Greenshot/Forms/PrintOptionsDialog.Designer.cs
index 43d40c06e..0de6ca3a9 100644
--- a/Greenshot/Forms/PrintOptionsDialog.Designer.cs
+++ b/Greenshot/Forms/PrintOptionsDialog.Designer.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/Greenshot/Forms/PrintOptionsDialog.cs b/Greenshot/Forms/PrintOptionsDialog.cs
index b4a2de28e..7e1ae603c 100644
--- a/Greenshot/Forms/PrintOptionsDialog.cs
+++ b/Greenshot/Forms/PrintOptionsDialog.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/Greenshot/Forms/ResizeSettingsForm.Designer.cs b/Greenshot/Forms/ResizeSettingsForm.Designer.cs
index f6a7fad48..e7675bb57 100644
--- a/Greenshot/Forms/ResizeSettingsForm.Designer.cs
+++ b/Greenshot/Forms/ResizeSettingsForm.Designer.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/Greenshot/Forms/ResizeSettingsForm.cs b/Greenshot/Forms/ResizeSettingsForm.cs
index 0d0aad23f..52bfb8d21 100644
--- a/Greenshot/Forms/ResizeSettingsForm.cs
+++ b/Greenshot/Forms/ResizeSettingsForm.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/Greenshot/Forms/SettingsForm.Designer.cs b/Greenshot/Forms/SettingsForm.Designer.cs
index 80cbd9437..f0cb33f46 100644
--- a/Greenshot/Forms/SettingsForm.Designer.cs
+++ b/Greenshot/Forms/SettingsForm.Designer.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
@@ -18,7 +18,7 @@
* You should have received a copy of the GNU General Public License
* along with this program. If not, see .
*/
-namespace Greenshot {
+namespace Greenshot.Forms {
partial class SettingsForm {
///
/// Designer variable used to keep track of non-visual components.
diff --git a/Greenshot/Forms/SettingsForm.cs b/Greenshot/Forms/SettingsForm.cs
index 90fc1df51..7bd37e0ec 100644
--- a/Greenshot/Forms/SettingsForm.cs
+++ b/Greenshot/Forms/SettingsForm.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
@@ -26,22 +26,20 @@ using System.Drawing;
using System.Globalization;
using System.IO;
using System.Linq;
+using System.Text.RegularExpressions;
using System.Windows.Forms;
-
using Greenshot.Configuration;
using Greenshot.Destinations;
using Greenshot.Helpers;
using GreenshotPlugin.Controls;
using GreenshotPlugin.Core;
-using System.Text.RegularExpressions;
using GreenshotPlugin.IniFile;
using GreenshotPlugin.Interfaces;
using GreenshotPlugin.Interfaces.Plugin;
using GreenshotPlugin.UnmanagedHelpers;
-using GreenshotPlugin.UnmanagedHelpers.Enums;
using log4net;
-namespace Greenshot {
+namespace Greenshot.Forms {
///
/// Description of SettingsForm.
///
@@ -453,9 +451,9 @@ namespace Greenshot {
}
// retrieve the set clipboard formats
- List clipboardFormats = new List();
+ var clipboardFormats = new List();
foreach (int index in listview_clipboardformats.CheckedIndices) {
- ListViewItem item = listview_clipboardformats.Items[index];
+ var item = listview_clipboardformats.Items[index];
if (item.Checked) {
clipboardFormats.Add((ClipboardFormat)item.Tag);
}
diff --git a/Greenshot/Forms/ToolStripMenuSelectList.cs b/Greenshot/Forms/ToolStripMenuSelectList.cs
index a109798f5..4ddfe7cdd 100644
--- a/Greenshot/Forms/ToolStripMenuSelectList.cs
+++ b/Greenshot/Forms/ToolStripMenuSelectList.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/Greenshot/Forms/TornEdgeSettingsForm.Designer.cs b/Greenshot/Forms/TornEdgeSettingsForm.Designer.cs
index 5320e17de..f2692729f 100644
--- a/Greenshot/Forms/TornEdgeSettingsForm.Designer.cs
+++ b/Greenshot/Forms/TornEdgeSettingsForm.Designer.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/Greenshot/Forms/TornEdgeSettingsForm.cs b/Greenshot/Forms/TornEdgeSettingsForm.cs
index 632d554ae..520f795b9 100644
--- a/Greenshot/Forms/TornEdgeSettingsForm.cs
+++ b/Greenshot/Forms/TornEdgeSettingsForm.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/Greenshot/GreenshotMain.cs b/Greenshot/GreenshotMain.cs
index 6a993d99b..045478d6d 100644
--- a/Greenshot/GreenshotMain.cs
+++ b/Greenshot/GreenshotMain.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
@@ -22,6 +22,7 @@ using System;
using System.Globalization;
using System.Net;
using System.Reflection;
+using Greenshot.Forms;
// Remove AppendPrivatePath warning:
#pragma warning disable 0618
@@ -38,11 +39,11 @@ namespace Greenshot {
Assembly ayResult = null;
string sShortAssemblyName = args.Name.Split(',')[0];
Assembly[] ayAssemblies = AppDomain.CurrentDomain.GetAssemblies();
- foreach (Assembly ayAssembly in ayAssemblies) {
- if (sShortAssemblyName == ayAssembly.FullName.Split(',')[0]) {
- ayResult = ayAssembly;
- break;
- }
+ foreach (Assembly ayAssembly in ayAssemblies)
+ {
+ if (sShortAssemblyName != ayAssembly.FullName.Split(',')[0]) continue;
+ ayResult = ayAssembly;
+ break;
}
return ayResult;
}
diff --git a/Greenshot/Help/HelpFileLoader.cs b/Greenshot/Help/HelpFileLoader.cs
index 10c4c69bb..4dec29979 100644
--- a/Greenshot/Help/HelpFileLoader.cs
+++ b/Greenshot/Help/HelpFileLoader.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/Greenshot/Helpers/CaptureHelper.cs b/Greenshot/Helpers/CaptureHelper.cs
index 42f28e4ad..19acda012 100644
--- a/Greenshot/Helpers/CaptureHelper.cs
+++ b/Greenshot/Helpers/CaptureHelper.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
@@ -85,11 +85,23 @@ namespace Greenshot.Helpers {
PsAPI.EmptyWorkingSet();
}
}
+
public static void CaptureClipboard()
+ {
+ using CaptureHelper captureHelper = new CaptureHelper(CaptureMode.Clipboard);
+ captureHelper.MakeCapture();
+ }
+
+ public static void CaptureClipboard(IDestination destination)
{
using CaptureHelper captureHelper = new CaptureHelper(CaptureMode.Clipboard);
+ if (destination != null)
+ {
+ captureHelper.AddDestination(destination);
+ }
captureHelper.MakeCapture();
}
+
public static void CaptureRegion(bool captureMouse)
{
using CaptureHelper captureHelper = new CaptureHelper(CaptureMode.Region, captureMouse);
@@ -194,12 +206,8 @@ namespace Greenshot.Helpers {
}
public WindowDetails SelectedCaptureWindow {
- get {
- return _selectedCaptureWindow;
- }
- set {
- _selectedCaptureWindow = value;
- }
+ get => _selectedCaptureWindow;
+ set => _selectedCaptureWindow = value;
}
private void DoCaptureFeedback() {
@@ -244,7 +252,7 @@ namespace Greenshot.Helpers {
Log.Debug($"Capturing with mode {_captureMode} and using Cursor {_captureMouseCursor}");
_capture.CaptureDetails.CaptureMode = _captureMode;
- // Get the windows details in a seperate thread, only for those captures that have a Feedback
+ // Get the windows details in a separate thread, only for those captures that have a Feedback
// As currently the "elements" aren't used, we don't need them yet
switch (_captureMode) {
case CaptureMode.Region:
@@ -270,7 +278,7 @@ namespace Greenshot.Helpers {
CoreConfig.CaptureDelay = 0;
}
- // Capture Mousecursor if we are not loading from file or clipboard, only show when needed
+ // Capture Mouse cursor if we are not loading from file or clipboard, only show when needed
if (_captureMode != CaptureMode.File && _captureMode != CaptureMode.Clipboard)
{
_capture = WindowCapture.CaptureCursor(_capture);
diff --git a/Greenshot/Helpers/Colors.cs b/Greenshot/Helpers/Colors.cs
index 0b30c7373..4588f4274 100644
--- a/Greenshot/Helpers/Colors.cs
+++ b/Greenshot/Helpers/Colors.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/Greenshot/Helpers/CopyData.cs b/Greenshot/Helpers/CopyData.cs
index 2168c0736..3bbebc8b4 100644
--- a/Greenshot/Helpers/CopyData.cs
+++ b/Greenshot/Helpers/CopyData.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
@@ -158,11 +158,12 @@ namespace Greenshot.Helpers {
///
/// Clears up any resources associated with this object.
///
- protected virtual void Dispose(bool disposing) {
- if (disposing && _channels != null) {
- _channels.Clear();
- _channels = null;
- }
+ protected virtual void Dispose(bool disposing)
+ {
+ if (!disposing || _channels == null) return;
+
+ _channels.Clear();
+ _channels = null;
}
///
@@ -249,10 +250,10 @@ namespace Greenshot.Helpers {
int i = 0;
foreach (CopyDataChannel cdc in Dictionary.Values) {
i++;
- if (i == index) {
- ret = cdc;
- break;
- }
+ if (i != index) continue;
+
+ ret = cdc;
+ break;
}
return ret;
}
@@ -337,14 +338,14 @@ namespace Greenshot.Helpers {
///
public class CopyDataChannel : IDisposable {
[DllImport("user32", CharSet = CharSet.Unicode, SetLastError = true)]
- private static extern IntPtr GetProp(IntPtr hwnd, string lpString);
+ private static extern IntPtr GetProp(IntPtr hWnd, string lpString);
[DllImport("user32", CharSet = CharSet.Unicode, SetLastError = true)]
- private static extern bool SetProp(IntPtr hwnd, string lpString, IntPtr hData);
+ private static extern bool SetProp(IntPtr hWnd, string lpString, IntPtr hData);
[DllImport("user32", CharSet = CharSet.Unicode, SetLastError = true)]
- private static extern IntPtr RemoveProp(IntPtr hwnd, string lpString);
+ private static extern IntPtr RemoveProp(IntPtr hWnd, string lpString);
[DllImport("user32", CharSet = CharSet.Unicode, SetLastError = true)]
- private static extern IntPtr SendMessage(IntPtr hwnd, int wMsg, IntPtr wParam, ref COPYDATASTRUCT lParam);
+ private static extern IntPtr SendMessage(IntPtr hWnd, int wMsg, IntPtr wParam, ref COPYDATASTRUCT lParam);
[StructLayout(LayoutKind.Sequential)]
private struct COPYDATASTRUCT {
@@ -460,13 +461,14 @@ namespace Greenshot.Helpers {
///
/// Clears up any resources associated with this channel.
///
- protected virtual void Dispose(bool disposing) {
- if (disposing) {
- if (ChannelName.Length > 0) {
- RemoveChannel();
- }
- ChannelName = string.Empty;
+ protected virtual void Dispose(bool disposing)
+ {
+ if (!disposing) return;
+
+ if (ChannelName.Length > 0) {
+ RemoveChannel();
}
+ ChannelName = string.Empty;
}
///
diff --git a/Greenshot/Helpers/DestinationHelper.cs b/Greenshot/Helpers/DestinationHelper.cs
index 49cec43da..1169edb40 100644
--- a/Greenshot/Helpers/DestinationHelper.cs
+++ b/Greenshot/Helpers/DestinationHelper.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/Greenshot/Helpers/Entities/UpdateFeed.cs b/Greenshot/Helpers/Entities/UpdateFeed.cs
index a7a80afb8..280518fc8 100644
--- a/Greenshot/Helpers/Entities/UpdateFeed.cs
+++ b/Greenshot/Helpers/Entities/UpdateFeed.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/Greenshot/Helpers/GeometryHelper.cs b/Greenshot/Helpers/GeometryHelper.cs
index d8f2dd3fd..e20cf5035 100644
--- a/Greenshot/Helpers/GeometryHelper.cs
+++ b/Greenshot/Helpers/GeometryHelper.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/Greenshot/Helpers/GuiRectangle.cs b/Greenshot/Helpers/GuiRectangle.cs
index 770874e78..c24e591ec 100644
--- a/Greenshot/Helpers/GuiRectangle.cs
+++ b/Greenshot/Helpers/GuiRectangle.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/Greenshot/Helpers/IECaptureHelper.cs b/Greenshot/Helpers/IECaptureHelper.cs
index cfe36a96b..f74403176 100644
--- a/Greenshot/Helpers/IECaptureHelper.cs
+++ b/Greenshot/Helpers/IECaptureHelper.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
@@ -50,14 +50,14 @@ namespace Greenshot.Helpers {
// Helper method to activate a certain IE Tab
public static void ActivateIeTab(WindowDetails ieWindowDetails, int tabIndex) {
WindowDetails directUiWindowDetails = IEHelper.GetDirectUI(ieWindowDetails);
- if(directUiWindowDetails != null) {
- // Bring window to the front
- ieWindowDetails.Restore();
- // Get accessible
- Accessible ieAccessible = new Accessible(directUiWindowDetails.Handle);
- // Activate Tab
- ieAccessible.ActivateIETab(tabIndex);
- }
+ if (directUiWindowDetails == null) return;
+
+ // Bring window to the front
+ ieWindowDetails.Restore();
+ // Get accessible
+ Accessible ieAccessible = new Accessible(directUiWindowDetails.Handle);
+ // Activate Tab
+ ieAccessible.ActivateIETab(tabIndex);
}
///
@@ -68,14 +68,14 @@ namespace Greenshot.Helpers {
///
public static bool IsMostlyIeWindow(WindowDetails someWindow, int minimumPercentage) {
WindowDetails ieWindow = someWindow.GetChild("Internet Explorer_Server");
- if (ieWindow != null) {
- Rectangle wholeClient = someWindow.ClientRectangle;
- Rectangle partClient = ieWindow.ClientRectangle;
- int percentage = (int)(100*(float)(partClient.Width * partClient.Height) / (wholeClient.Width * wholeClient.Height));
- Log.InfoFormat("Window {0}, ie part {1}, percentage {2}", wholeClient, partClient, percentage);
- if (percentage > minimumPercentage) {
- return true;
- }
+ if (ieWindow == null) return false;
+
+ Rectangle wholeClient = someWindow.ClientRectangle;
+ Rectangle partClient = ieWindow.ClientRectangle;
+ int percentage = (int)(100*(float)(partClient.Width * partClient.Height) / (wholeClient.Width * wholeClient.Height));
+ Log.InfoFormat("Window {0}, ie part {1}, percentage {2}", wholeClient, partClient, percentage);
+ if (percentage > minimumPercentage) {
+ return true;
}
return false;
}
@@ -336,9 +336,8 @@ namespace Greenshot.Helpers {
/// window to use
/// ICapture with the content (if any)
public static ICapture CaptureIe(ICapture capture, WindowDetails windowToCapture) {
- if (windowToCapture == null) {
- windowToCapture = WindowDetails.GetActiveWindow();
- }
+ windowToCapture ??= WindowDetails.GetActiveWindow();
+
// Show backgroundform after retrieving the active window..
BackgroundForm backgroundForm = new BackgroundForm(Language.GetString(LangKey.contextmenu_captureie), Language.GetString(LangKey.wait_ie_capture));
backgroundForm.Show();
@@ -474,27 +473,28 @@ namespace Greenshot.Helpers {
continue;
}
// check if we need to move
- if (otherFrame.DestinationRectangle.IntersectsWith(currentFrame.DestinationRectangle) && !otherFrame.SourceRectangle.IntersectsWith(currentFrame.SourceRectangle)) {
- bool horizalResize = currentFrame.SourceSize.Width < currentFrame.DestinationSize.Width;
- bool verticalResize = currentFrame.SourceSize.Width < currentFrame.DestinationSize.Width;
- bool horizalMove = currentFrame.SourceLeft < currentFrame.DestinationLeft;
- bool verticalMove = currentFrame.SourceTop < currentFrame.DestinationTop;
- bool leftOf = currentFrame.SourceRight <= otherFrame.SourceLeft;
- bool belowOf = currentFrame.SourceBottom <= otherFrame.SourceTop;
+ if (!otherFrame.DestinationRectangle.IntersectsWith(currentFrame.DestinationRectangle) ||
+ otherFrame.SourceRectangle.IntersectsWith(currentFrame.SourceRectangle)) continue;
+
+ bool horizontalResize = currentFrame.SourceSize.Width < currentFrame.DestinationSize.Width;
+ bool verticalResize = currentFrame.SourceSize.Width < currentFrame.DestinationSize.Width;
+ bool horizontalMove = currentFrame.SourceLeft < currentFrame.DestinationLeft;
+ bool verticalMove = currentFrame.SourceTop < currentFrame.DestinationTop;
+ bool leftOf = currentFrame.SourceRight <= otherFrame.SourceLeft;
+ bool belowOf = currentFrame.SourceBottom <= otherFrame.SourceTop;
- if ((horizalResize || horizalMove) && leftOf) {
- // Current frame resized horizontally, so move other horizontally
- Log.DebugFormat("Moving Frame {0} horizontally to the right of {1}", otherFrame.Name, currentFrame.Name);
- otherFrame.DestinationLeft = currentFrame.DestinationRight;
- movedFrame = true;
- } else if ((verticalResize || verticalMove) && belowOf){
- // Current frame resized vertically, so move other vertically
- Log.DebugFormat("Moving Frame {0} vertically to the bottom of {1}", otherFrame.Name, currentFrame.Name);
- otherFrame.DestinationTop = currentFrame.DestinationBottom;
- movedFrame = true;
- } else {
- Log.DebugFormat("Frame {0} intersects with {1}", otherFrame.Name, currentFrame.Name);
- }
+ if ((horizontalResize || horizontalMove) && leftOf) {
+ // Current frame resized horizontally, so move other horizontally
+ Log.DebugFormat("Moving Frame {0} horizontally to the right of {1}", otherFrame.Name, currentFrame.Name);
+ otherFrame.DestinationLeft = currentFrame.DestinationRight;
+ movedFrame = true;
+ } else if ((verticalResize || verticalMove) && belowOf){
+ // Current frame resized vertically, so move other vertically
+ Log.DebugFormat("Moving Frame {0} vertically to the bottom of {1}", otherFrame.Name, currentFrame.Name);
+ otherFrame.DestinationTop = currentFrame.DestinationBottom;
+ movedFrame = true;
+ } else {
+ Log.DebugFormat("Frame {0} intersects with {1}", otherFrame.Name, currentFrame.Name);
}
}
}
@@ -504,7 +504,7 @@ namespace Greenshot.Helpers {
// Correct cursor location to be inside the window
capture.MoveMouseLocation(-documentContainer.ContentWindow.Location.X, -documentContainer.ContentWindow.Location.Y);
// See if the page has the correct size, as we capture the full frame content AND might have moved them
- // the normal pagesize will no longer be enough
+ // the normal pageSize will no longer be enough
foreach(DocumentContainer frameData in documentContainer.Frames) {
if (!movedMouse && frameData.SourceRectangle.Contains(capture.CursorLocation)) {
// Correct mouse cursor location for scrolled position (so it shows on the capture where it really was)
diff --git a/Greenshot/Helpers/IEInterop/IEContainer.cs b/Greenshot/Helpers/IEInterop/IEContainer.cs
index 56d83ff29..824cf3fa9 100644
--- a/Greenshot/Helpers/IEInterop/IEContainer.cs
+++ b/Greenshot/Helpers/IEInterop/IEContainer.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/Greenshot/Helpers/MailHelper.cs b/Greenshot/Helpers/MailHelper.cs
index a78799eae..3bc09b5f8 100644
--- a/Greenshot/Helpers/MailHelper.cs
+++ b/Greenshot/Helpers/MailHelper.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
@@ -76,20 +76,12 @@ namespace Greenshot.Helpers {
public static void SendImage(ISurface surface, ICaptureDetails captureDetails) {
string tmpFile = ImageOutput.SaveNamedTmpFile(surface, captureDetails, new SurfaceOutputSettings());
- if (tmpFile != null) {
- // Store the list of currently active windows, so we can make sure we show the email window later!
- var windowsBefore = WindowDetails.GetVisibleWindows();
- //bool isEmailSend = false;
- //if (EmailConfigHelper.HasOutlook() && (CoreConfig.OutputEMailFormat == EmailFormat.OUTLOOK_HTML || CoreConfig.OutputEMailFormat == EmailFormat.OUTLOOK_TXT)) {
- // isEmailSend = OutlookExporter.ExportToOutlook(tmpFile, captureDetails);
- //}
- if (/*!isEmailSend &&*/ EmailConfigHelper.HasMapi()) {
- // Fallback to MAPI
- // Send the email
- SendImage(tmpFile, captureDetails.Title);
- }
- WindowDetails.ActiveNewerWindows(windowsBefore);
- }
+ if (tmpFile == null) return;
+
+ // Store the list of currently active windows, so we can make sure we show the email window later!
+ var windowsBefore = WindowDetails.GetVisibleWindows();
+ SendImage(tmpFile, captureDetails.Title);
+ WindowDetails.ActiveNewerWindows(windowsBefore);
}
[StructLayout(LayoutKind.Sequential, CharSet = CharSet.Ansi)]
@@ -199,74 +191,83 @@ namespace Greenshot.Helpers {
_manualResetEvent?.Close();
}
- ///
- /// Sends the mail message.
- ///
- private void ShowMail() {
- var message = new MapiHelperInterop.MapiMessage();
+ ///
+ /// Sends the mail message.
+ ///
+ private void ShowMail()
+ {
+ while (true)
+ {
+ var message = new MapiHelperInterop.MapiMessage();
- using var interopRecipients = Recipients.GetInteropRepresentation();
- message.Subject = Subject;
- message.NoteText = Body;
+ using var interopRecipients = Recipients.GetInteropRepresentation();
+ message.Subject = Subject;
+ message.NoteText = Body;
- message.Recipients = interopRecipients.Handle;
- message.RecipientCount = Recipients.Count;
+ message.Recipients = interopRecipients.Handle;
+ message.RecipientCount = Recipients.Count;
- // Check if we need to add attachments
- if (Files.Count > 0) {
- // Add attachments
- message.Files = AllocAttachments(out message.FileCount);
- }
+ // Check if we need to add attachments
+ if (Files.Count > 0)
+ {
+ // Add attachments
+ message.Files = AllocAttachments(out message.FileCount);
+ }
- // Signal the creating thread (make the remaining code async)
- _manualResetEvent.Set();
+ // Signal the creating thread (make the remaining code async)
+ _manualResetEvent.Set();
- const int MAPI_DIALOG = 0x8;
- //const int MAPI_LOGON_UI = 0x1;
- int error = MapiHelperInterop.MAPISendMail(IntPtr.Zero, IntPtr.Zero, message, MAPI_DIALOG, 0);
+ const int MAPI_DIALOG = 0x8;
+ //const int MAPI_LOGON_UI = 0x1;
+ int error = MapiHelperInterop.MAPISendMail(IntPtr.Zero, IntPtr.Zero, message, MAPI_DIALOG, 0);
- if (Files.Count > 0) {
- // Deallocate the files
- DeallocFiles(message);
- }
- MAPI_CODES errorCode = (MAPI_CODES)Enum.ToObject(typeof(MAPI_CODES), error);
+ if (Files.Count > 0)
+ {
+ // Deallocate the files
+ DeallocFiles(message);
+ }
- // Check for error
- if (errorCode == MAPI_CODES.SUCCESS || errorCode == MAPI_CODES.USER_ABORT)
- {
- return;
- }
- string errorText = GetMapiError(errorCode);
- Log.Error("Error sending MAPI Email. Error: " + errorText + " (code = " + errorCode + ").");
- MessageBox.Show(errorText, "Mail (MAPI) destination", MessageBoxButtons.OK, MessageBoxIcon.Error);
- // Recover from bad settings, show again
- if (errorCode != MAPI_CODES.INVALID_RECIPS)
- {
- return;
- }
- Recipients = new RecipientCollection();
- ShowMail();
+ MAPI_CODES errorCode = (MAPI_CODES) Enum.ToObject(typeof(MAPI_CODES), error);
+
+ // Check for error
+ if (errorCode == MAPI_CODES.SUCCESS || errorCode == MAPI_CODES.USER_ABORT)
+ {
+ return;
+ }
+
+ string errorText = GetMapiError(errorCode);
+ Log.Error("Error sending MAPI Email. Error: " + errorText + " (code = " + errorCode + ").");
+ MessageBox.Show(errorText, "Mail (MAPI) destination", MessageBoxButtons.OK, MessageBoxIcon.Error);
+ // Recover from bad settings, show again
+ if (errorCode != MAPI_CODES.INVALID_RECIPS)
+ {
+ return;
+ }
+
+ Recipients = new RecipientCollection();
+ }
}
- ///
+ ///
/// Deallocates the files in a message.
///
/// The message to deallocate the files from.
- private void DeallocFiles(MapiHelperInterop.MapiMessage message) {
- if (message.Files != IntPtr.Zero) {
- Type fileDescType = typeof(MapiFileDescriptor);
- int fsize = Marshal.SizeOf(fileDescType);
+ private void DeallocFiles(MapiHelperInterop.MapiMessage message)
+ {
+ if (message.Files == IntPtr.Zero) return;
+
+ Type fileDescType = typeof(MapiFileDescriptor);
+ int fsize = Marshal.SizeOf(fileDescType);
- // Get the ptr to the files
- IntPtr runptr = message.Files;
- // Release each file
- for (int i = 0; i < message.FileCount; i++) {
- Marshal.DestroyStructure(runptr, fileDescType);
- runptr = new IntPtr(runptr.ToInt64() + fsize);
- }
- // Release the file
- Marshal.FreeHGlobal(message.Files);
+ // Get the ptr to the files
+ IntPtr runptr = message.Files;
+ // Release each file
+ for (int i = 0; i < message.FileCount; i++) {
+ Marshal.DestroyStructure(runptr, fileDescType);
+ runptr = new IntPtr(runptr.ToInt64() + fsize);
}
+ // Release the file
+ Marshal.FreeHGlobal(message.Files);
}
///
@@ -337,93 +338,39 @@ namespace Greenshot.Helpers {
///
/// Logs any Mapi errors.
///
- private string GetMapiError(MAPI_CODES errorCode) {
-
- string error = string.Empty;
-
- switch (errorCode) {
- case MAPI_CODES.USER_ABORT:
- error = "User Aborted.";
- break;
- case MAPI_CODES.FAILURE:
- error = "MAPI Failure.";
- break;
- case MAPI_CODES.LOGIN_FAILURE:
- error = "Login Failure.";
- break;
- case MAPI_CODES.DISK_FULL:
- error = "MAPI Disk full.";
- break;
- case MAPI_CODES.INSUFFICIENT_MEMORY:
- error = "MAPI Insufficient memory.";
- break;
- case MAPI_CODES.BLK_TOO_SMALL:
- error = "MAPI Block too small.";
- break;
- case MAPI_CODES.TOO_MANY_SESSIONS:
- error = "MAPI Too many sessions.";
- break;
- case MAPI_CODES.TOO_MANY_FILES:
- error = "MAPI too many files.";
- break;
- case MAPI_CODES.TOO_MANY_RECIPIENTS:
- error = "MAPI too many recipients.";
- break;
- case MAPI_CODES.ATTACHMENT_NOT_FOUND:
- error = "MAPI Attachment not found.";
- break;
- case MAPI_CODES.ATTACHMENT_OPEN_FAILURE:
- error = "MAPI Attachment open failure.";
- break;
- case MAPI_CODES.ATTACHMENT_WRITE_FAILURE:
- error = "MAPI Attachment Write Failure.";
- break;
- case MAPI_CODES.UNKNOWN_RECIPIENT:
- error = "MAPI Unknown recipient.";
- break;
- case MAPI_CODES.BAD_RECIPTYPE:
- error = "MAPI Bad recipient type.";
- break;
- case MAPI_CODES.NO_MESSAGES:
- error = "MAPI No messages.";
- break;
- case MAPI_CODES.INVALID_MESSAGE:
- error = "MAPI Invalid message.";
- break;
- case MAPI_CODES.TEXT_TOO_LARGE:
- error = "MAPI Text too large.";
- break;
- case MAPI_CODES.INVALID_SESSION:
- error = "MAPI Invalid session.";
- break;
- case MAPI_CODES.TYPE_NOT_SUPPORTED:
- error = "MAPI Type not supported.";
- break;
- case MAPI_CODES.AMBIGUOUS_RECIPIENT:
- error = "MAPI Ambiguous recipient.";
- break;
- case MAPI_CODES.MESSAGE_IN_USE:
- error = "MAPI Message in use.";
- break;
- case MAPI_CODES.NETWORK_FAILURE:
- error = "MAPI Network failure.";
- break;
- case MAPI_CODES.INVALID_EDITFIELDS:
- error = "MAPI Invalid edit fields.";
- break;
- case MAPI_CODES.INVALID_RECIPS:
- error = "MAPI Invalid Recipients.";
- break;
- case MAPI_CODES.NOT_SUPPORTED:
- error = "MAPI Not supported.";
- break;
- case MAPI_CODES.NO_LIBRARY:
- error = "MAPI No Library.";
- break;
- case MAPI_CODES.INVALID_PARAMETER:
- error = "MAPI Invalid parameter.";
- break;
- }
+ private string GetMapiError(MAPI_CODES errorCode)
+ {
+ string error = errorCode switch
+ {
+ MAPI_CODES.USER_ABORT => "User Aborted.",
+ MAPI_CODES.FAILURE => "MAPI Failure.",
+ MAPI_CODES.LOGIN_FAILURE => "Login Failure.",
+ MAPI_CODES.DISK_FULL => "MAPI Disk full.",
+ MAPI_CODES.INSUFFICIENT_MEMORY => "MAPI Insufficient memory.",
+ MAPI_CODES.BLK_TOO_SMALL => "MAPI Block too small.",
+ MAPI_CODES.TOO_MANY_SESSIONS => "MAPI Too many sessions.",
+ MAPI_CODES.TOO_MANY_FILES => "MAPI too many files.",
+ MAPI_CODES.TOO_MANY_RECIPIENTS => "MAPI too many recipients.",
+ MAPI_CODES.ATTACHMENT_NOT_FOUND => "MAPI Attachment not found.",
+ MAPI_CODES.ATTACHMENT_OPEN_FAILURE => "MAPI Attachment open failure.",
+ MAPI_CODES.ATTACHMENT_WRITE_FAILURE => "MAPI Attachment Write Failure.",
+ MAPI_CODES.UNKNOWN_RECIPIENT => "MAPI Unknown recipient.",
+ MAPI_CODES.BAD_RECIPTYPE => "MAPI Bad recipient type.",
+ MAPI_CODES.NO_MESSAGES => "MAPI No messages.",
+ MAPI_CODES.INVALID_MESSAGE => "MAPI Invalid message.",
+ MAPI_CODES.TEXT_TOO_LARGE => "MAPI Text too large.",
+ MAPI_CODES.INVALID_SESSION => "MAPI Invalid session.",
+ MAPI_CODES.TYPE_NOT_SUPPORTED => "MAPI Type not supported.",
+ MAPI_CODES.AMBIGUOUS_RECIPIENT => "MAPI Ambiguous recipient.",
+ MAPI_CODES.MESSAGE_IN_USE => "MAPI Message in use.",
+ MAPI_CODES.NETWORK_FAILURE => "MAPI Network failure.",
+ MAPI_CODES.INVALID_EDITFIELDS => "MAPI Invalid edit fields.",
+ MAPI_CODES.INVALID_RECIPS => "MAPI Invalid Recipients.",
+ MAPI_CODES.NOT_SUPPORTED => "MAPI Not supported.",
+ MAPI_CODES.NO_LIBRARY => "MAPI No Library.",
+ MAPI_CODES.INVALID_PARAMETER => "MAPI Invalid parameter.",
+ _ => string.Empty
+ };
return error;
}
@@ -466,7 +413,7 @@ namespace Greenshot.Helpers {
}
[DllImport("MAPI32.DLL", SetLastError = true, CharSet=CharSet.Ansi)]
- public static extern int MAPISendMail(IntPtr session, IntPtr hwnd, MapiMessage message, int flg, int rsv);
+ public static extern int MAPISendMail(IntPtr session, IntPtr hWnd, MapiMessage message, int flg, int rsv);
}
}
@@ -542,7 +489,7 @@ namespace Greenshot.Helpers {
}
///
- /// Represents a colleciton of recipients for a mail message.
+ /// Represents a collection of recipients for a mail message.
///
public class RecipientCollection : CollectionBase {
///
@@ -627,25 +574,26 @@ namespace Greenshot.Helpers {
///
/// Disposes of resources.
///
- public void Dispose() {
- if (Handle != IntPtr.Zero) {
- Type type = typeof(MapiMailMessage.MapiHelperInterop.MapiRecipDesc);
- int size = Marshal.SizeOf(type);
+ public void Dispose()
+ {
+ if (Handle == IntPtr.Zero) return;
+
+ Type type = typeof(MapiMailMessage.MapiHelperInterop.MapiRecipDesc);
+ int size = Marshal.SizeOf(type);
- // destroy all the structures in the memory area
- IntPtr ptr = Handle;
- for (int i = 0; i < _count; i++) {
- Marshal.DestroyStructure(ptr, type);
- ptr = new IntPtr(ptr.ToInt64() + size);
- }
+ // destroy all the structures in the memory area
+ IntPtr ptr = Handle;
+ for (int i = 0; i < _count; i++) {
+ Marshal.DestroyStructure(ptr, type);
+ ptr = new IntPtr(ptr.ToInt64() + size);
+ }
- // free the memory
- Marshal.FreeHGlobal(Handle);
+ // free the memory
+ Marshal.FreeHGlobal(Handle);
- Handle = IntPtr.Zero;
- _count = 0;
- }
- }
+ Handle = IntPtr.Zero;
+ _count = 0;
+ }
}
}
}
\ No newline at end of file
diff --git a/Greenshot/Helpers/NotifyIconNotificationService.cs b/Greenshot/Helpers/NotifyIconNotificationService.cs
index 7398a7890..708da7592 100644
--- a/Greenshot/Helpers/NotifyIconNotificationService.cs
+++ b/Greenshot/Helpers/NotifyIconNotificationService.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/Greenshot/Helpers/PluginHelper.cs b/Greenshot/Helpers/PluginHelper.cs
index 1d31e8e38..38de55b24 100644
--- a/Greenshot/Helpers/PluginHelper.cs
+++ b/Greenshot/Helpers/PluginHelper.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/Greenshot/Helpers/PrintHelper.cs b/Greenshot/Helpers/PrintHelper.cs
index 5de51a20f..d04f8e317 100644
--- a/Greenshot/Helpers/PrintHelper.cs
+++ b/Greenshot/Helpers/PrintHelper.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
@@ -102,7 +102,7 @@ namespace Greenshot.Helpers {
returnPrinterSettings = _printDocument.PrinterSettings;
}
} catch (Exception e) {
- Log.Error("An error ocurred while trying to print", e);
+ Log.Error("An error occurred while trying to print", e);
MessageBox.Show(Language.GetString(LangKey.print_error), Language.GetString(LangKey.error));
}
return returnPrinterSettings;
@@ -115,21 +115,20 @@ namespace Greenshot.Helpers {
/// printer settings if actually printed, or null if print was cancelled or has failed
public PrinterSettings PrintWithDialog() {
PrinterSettings returnPrinterSettings = null;
- if (_printDialog.ShowDialog() == DialogResult.OK) {
- DialogResult? printOptionsResult = ShowPrintOptionsDialog();
- try {
- if (printOptionsResult == null || printOptionsResult == DialogResult.OK) {
- if (!IsColorPrint()) {
- _printDocument.DefaultPageSettings.Color = false;
- }
- _printDocument.Print();
- returnPrinterSettings = _printDialog.PrinterSettings;
- }
- } catch (Exception e) {
- Log.Error("An error ocurred while trying to print", e);
- MessageBox.Show(Language.GetString(LangKey.print_error), Language.GetString(LangKey.error));
- }
+ if (_printDialog.ShowDialog() != DialogResult.OK) return null;
+ DialogResult? printOptionsResult = ShowPrintOptionsDialog();
+ try {
+ if (printOptionsResult == null || printOptionsResult == DialogResult.OK) {
+ if (!IsColorPrint()) {
+ _printDocument.DefaultPageSettings.Color = false;
+ }
+ _printDocument.Print();
+ returnPrinterSettings = _printDialog.PrinterSettings;
+ }
+ } catch (Exception e) {
+ Log.Error("An error occurred while trying to print", e);
+ MessageBox.Show(Language.GetString(LangKey.print_error), Language.GetString(LangKey.error));
}
return returnPrinterSettings;
}
@@ -153,9 +152,7 @@ namespace Greenshot.Helpers {
}
private void DrawImageForPrint(object sender, PrintPageEventArgs e) {
-
-
- // Create the output settins
+ // Create the output settings
SurfaceOutputSettings printOutputSettings = new SurfaceOutputSettings(OutputFormat.png, 100, false);
ApplyEffects(printOutputSettings);
@@ -190,7 +187,7 @@ namespace Greenshot.Helpers {
RectangleF imageRect = image.GetBounds(ref gu);
// rotate the image if it fits the page better
if (CoreConfig.OutputPrintAllowRotate) {
- if ((pageRect.Width > pageRect.Height && imageRect.Width < imageRect.Height) || (pageRect.Width < pageRect.Height && imageRect.Width > imageRect.Height)) {
+ if (pageRect.Width > pageRect.Height && imageRect.Width < imageRect.Height || pageRect.Width < pageRect.Height && imageRect.Width > imageRect.Height) {
image.RotateFlip(RotateFlipType.Rotate270FlipNone);
imageRect = image.GetBounds(ref gu);
if (alignment.Equals(ContentAlignment.TopLeft)) {
@@ -203,7 +200,7 @@ namespace Greenshot.Helpers {
// scale the image to fit the page better
if (CoreConfig.OutputPrintAllowEnlarge || CoreConfig.OutputPrintAllowShrink) {
SizeF resizedRect = ScaleHelper.GetScaledSize(imageRect.Size, pageRect.Size, false);
- if ((CoreConfig.OutputPrintAllowShrink && resizedRect.Width < printRect.Width) || CoreConfig.OutputPrintAllowEnlarge && resizedRect.Width > printRect.Width) {
+ if (CoreConfig.OutputPrintAllowShrink && resizedRect.Width < printRect.Width || CoreConfig.OutputPrintAllowEnlarge && resizedRect.Width > printRect.Width) {
printRect.Size = resizedRect;
}
}
diff --git a/Greenshot/Helpers/ProcessorHelper.cs b/Greenshot/Helpers/ProcessorHelper.cs
index 0ccf0fbe6..25598944a 100644
--- a/Greenshot/Helpers/ProcessorHelper.cs
+++ b/Greenshot/Helpers/ProcessorHelper.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/Greenshot/Helpers/ResourceMutex.cs b/Greenshot/Helpers/ResourceMutex.cs
index 7a70031c1..9854c3dca 100644
--- a/Greenshot/Helpers/ResourceMutex.cs
+++ b/Greenshot/Helpers/ResourceMutex.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
@@ -106,7 +106,7 @@ namespace Greenshot.Helpers
catch (AbandonedMutexException e)
{
// Another instance didn't cleanup correctly!
- // we can ignore the exception, it happend on the "waitone" but still the mutex belongs to us
+ // we can ignore the exception, it happened on the "waitOne" but still the mutex belongs to us
Log.WarnFormat("{0} didn't cleanup correctly, but we got the mutex {1}.", _resourceName, _mutexId);
Log.Warn(e);
}
@@ -132,26 +132,25 @@ namespace Greenshot.Helpers
/// The real disposing code
///
/// true if dispose is called, false when the finalizer is called
- protected virtual void Dispose(bool disposing)
+ protected void Dispose(bool disposing)
{
- if (!_disposedValue)
+ if (_disposedValue) return;
+
+ if (_applicationMutex != null)
{
- if (_applicationMutex != null)
+ try
{
- try
- {
- _applicationMutex.ReleaseMutex();
- _applicationMutex = null;
- Log.InfoFormat("Released Mutex {0} for {1}", _mutexId, _resourceName);
- }
- catch (Exception ex)
- {
- Log.ErrorFormat("Error releasing Mutex {0} for {1}", _mutexId, _resourceName);
- Log.Error(ex);
- }
+ _applicationMutex.ReleaseMutex();
+ _applicationMutex = null;
+ Log.InfoFormat("Released Mutex {0} for {1}", _mutexId, _resourceName);
+ }
+ catch (Exception ex)
+ {
+ Log.ErrorFormat("Error releasing Mutex {0} for {1}", _mutexId, _resourceName);
+ Log.Error(ex);
}
- _disposedValue = true;
}
+ _disposedValue = true;
}
///
diff --git a/Greenshot/Helpers/ScaleHelper.cs b/Greenshot/Helpers/ScaleHelper.cs
index b7c7b1d62..76e0091c6 100644
--- a/Greenshot/Helpers/ScaleHelper.cs
+++ b/Greenshot/Helpers/ScaleHelper.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
@@ -64,7 +64,7 @@ namespace Greenshot.Helpers {
/// calculates the position of an element depending on the desired alignment within a RectangleF
///
/// the bounds of the element to be aligned
- /// the rectangle reference for aligment of the element
+ /// the rectangle reference for alignment of the element
/// the System.Drawing.ContentAlignment value indicating how the element is to be aligned should the width or height differ from targetSize
/// a new RectangleF object with Location aligned aligned to targetRect
public static RectangleF GetAlignedRectangle(RectangleF currentRect, RectangleF targetRect, ContentAlignment alignment) {
@@ -136,15 +136,13 @@ namespace Greenshot.Helpers {
/// coordinates of the used handle/gripper
/// ScaleOptions to use when scaling
public static void Scale(ref RectangleF originalRectangle, Positions resizeHandlePosition, PointF resizeHandleCoords, ScaleOptions? options) {
- if(options == null) {
- options = GetScaleOptions();
- }
+ options ??= GetScaleOptions();
- if((options & ScaleOptions.Rational) == ScaleOptions.Rational) {
+ if ((options & ScaleOptions.Rational) == ScaleOptions.Rational) {
adjustCoordsForRationalScale(originalRectangle, resizeHandlePosition, ref resizeHandleCoords);
}
- if((options & ScaleOptions.Centered) == ScaleOptions.Centered) {
+ if ((options & ScaleOptions.Centered) == ScaleOptions.Centered) {
// store center coordinates of rectangle
float rectCenterX = originalRectangle.Left + originalRectangle.Width / 2;
float rectCenterY = originalRectangle.Top + originalRectangle.Height / 2;
@@ -332,14 +330,14 @@ namespace Greenshot.Helpers {
}
public class ShapeAngleRoundBehavior : IDoubleProcessor {
- public static ShapeAngleRoundBehavior Instance = new ShapeAngleRoundBehavior();
+ public static ShapeAngleRoundBehavior Instance = new();
private ShapeAngleRoundBehavior() {}
public double Process(double angle) {
return Math.Round((angle+45)/90)*90 - 45;
}
}
public class LineAngleRoundBehavior : IDoubleProcessor {
- public static LineAngleRoundBehavior Instance = new LineAngleRoundBehavior();
+ public static LineAngleRoundBehavior Instance = new();
private LineAngleRoundBehavior() {}
public double Process(double angle) {
return Math.Round(angle/15)*15;
@@ -354,21 +352,6 @@ namespace Greenshot.Helpers {
return fixedAngle;
}
}
-
-
-
-
-
- /*public static int FindGripperPostition(float anchorX, float anchorY, float gripperX, float gripperY) {
- if(gripperY > anchorY) {
- if(gripperX > anchorY) return Gripper.POSITION_BOTTOM_RIGHT;
- else return Gripper.POSITION_BOTTOM_LEFT;
- } else {
- if(gripperX > anchorY) return Gripper.POSITION_TOP_RIGHT;
- else return Gripper.POSITION_TOP_LEFT;
- }
- }*/
-
}
}
\ No newline at end of file
diff --git a/Greenshot/Helpers/SoundHelper.cs b/Greenshot/Helpers/SoundHelper.cs
index eb9139290..427909d86 100644
--- a/Greenshot/Helpers/SoundHelper.cs
+++ b/Greenshot/Helpers/SoundHelper.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/Greenshot/Helpers/StartupHelper.cs b/Greenshot/Helpers/StartupHelper.cs
index 9e5e4461b..1ca5180e8 100644
--- a/Greenshot/Helpers/StartupHelper.cs
+++ b/Greenshot/Helpers/StartupHelper.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
@@ -226,9 +226,9 @@ namespace Greenshot.Helpers {
}
///
- /// Test if there is a link in the Statup folder
+ /// Test if there is a link in the Startup folder
///
- ///
+ /// bool
public static bool IsInStartupFolder() {
try {
string lnkName = Path.GetFileNameWithoutExtension(Application.ExecutablePath) + ".lnk";
diff --git a/Greenshot/Helpers/ToolStripItemEndisabler.cs b/Greenshot/Helpers/ToolStripItemEndisabler.cs
index 268a8d2b2..db5a5d178 100644
--- a/Greenshot/Helpers/ToolStripItemEndisabler.cs
+++ b/Greenshot/Helpers/ToolStripItemEndisabler.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
@@ -63,24 +63,26 @@ namespace Greenshot.Helpers {
Endisable(tsi, false, PropagationMode.CHILDREN);
}
- private static void Endisable(ToolStrip ts, bool enable, PropagationMode mode){
- if((mode & PropagationMode.CHILDREN) == PropagationMode.CHILDREN) {
- foreach(ToolStripItem tsi in ts.Items) {
- Endisable(tsi, enable, PropagationMode.CHILDREN);
- }
+ private static void Endisable(ToolStrip ts, bool enable, PropagationMode mode)
+ {
+ if ((mode & PropagationMode.CHILDREN) != PropagationMode.CHILDREN) return;
+
+ foreach(ToolStripItem tsi in ts.Items) {
+ Endisable(tsi, enable, PropagationMode.CHILDREN);
}
}
private static void Endisable(ToolStripItem tsi, bool enable, PropagationMode mode){
- if(tsi is ToolStripDropDownItem) {
- Endisable(tsi as ToolStripDropDownItem, enable, mode);
+ if (tsi is ToolStripDropDownItem item) {
+ Endisable(item, enable, mode);
} else {
tsi.Enabled = enable;
}
- if((mode & PropagationMode.ANCESTORS) == PropagationMode.ANCESTORS) {
- if(tsi.OwnerItem != null) Endisable(tsi.OwnerItem, enable, PropagationMode.ANCESTORS);
- }
+
+ if ((mode & PropagationMode.ANCESTORS) != PropagationMode.ANCESTORS) return;
+ if (tsi.OwnerItem != null) Endisable(tsi.OwnerItem, enable, PropagationMode.ANCESTORS);
+
}
private static void Endisable(ToolStripDropDownItem tsddi, bool enable, PropagationMode mode) {
diff --git a/Greenshot/Helpers/UpdateService.cs b/Greenshot/Helpers/UpdateService.cs
index ceb3488be..8c1728fb8 100644
--- a/Greenshot/Helpers/UpdateService.cs
+++ b/Greenshot/Helpers/UpdateService.cs
@@ -1,5 +1,5 @@
// Greenshot - a free and open source screenshot tool
-// Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+// Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
//
// For more information see: http://getgreenshot.org/
// The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/Greenshot/Helpers/WindowWrapper.cs b/Greenshot/Helpers/WindowWrapper.cs
deleted file mode 100644
index 1fde215e0..000000000
--- a/Greenshot/Helpers/WindowWrapper.cs
+++ /dev/null
@@ -1,32 +0,0 @@
-/*
- * Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
- *
- * For more information see: http://getgreenshot.org/
- * The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
- *
- * This program is free software: you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation, either version 1 of the License, or
- * (at your option) any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program. If not, see .
- */
-using System;
-using System.Windows.Forms;
-
-namespace Greenshot.Helpers {
- public class WindowWrapper : IWin32Window {
- public WindowWrapper(IntPtr handle) {
- Handle = handle;
- }
-
- public IntPtr Handle { get; }
- }
-}
diff --git a/Greenshot/Languages/language-ar-SY.xml b/Greenshot/Languages/language-ar-SY.xml
index eec227d75..c5c6edc84 100644
--- a/Greenshot/Languages/language-ar-SY.xml
+++ b/Greenshot/Languages/language-ar-SY.xml
@@ -5,7 +5,7 @@
اذا اعجبك البرنامج انت مدعو لدعمنا:
جرين شوت استضيف بواسطة GitHub في
الايقونات بواسطة مجموعة ايقونات يوسوكي كامياماني (تحت رخصة المشاع الإبداعي الاصدار 3.0)
- حقوق النشر © 2007 - 2020 توماس براون, جينس كلنجين, روبين كروم
+ حقوق النشر © 2007 -2021 توماس براون, جينس كلنجين, روبين كروم
جرين شوت لا يأتي مع أية ضمان. هذا برنامج حر, مرحبا بك لتعيد توزيعه تحت شروط معينة.
تفاصيل حول رخصة جنو العمومية:
حول جرين شوت
diff --git a/Greenshot/Languages/language-ca-CA.xml b/Greenshot/Languages/language-ca-CA.xml
index 374d58705..9f92f7446 100644
--- a/Greenshot/Languages/language-ca-CA.xml
+++ b/Greenshot/Languages/language-ca-CA.xml
@@ -5,7 +5,7 @@
Si Greenshot us agrada , us agrairem que ens ajudeu:
Greenshot s'allotja a sourceforge.net
Icones del conjunt d'icones Fugue de Yusuke Kamiyamane(Creative Commons Attribution 3.0 license)
- Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
Greenshot s'ofereix SENSE CAP GARANTIA. Aquest és un programari gratuït, i podeu redistribuir-lo amb algunes condicions.
Detalls sobre la Llicència General Publica GNU:
Quant a Greenshot
diff --git a/Greenshot/Languages/language-cs-CZ.xml b/Greenshot/Languages/language-cs-CZ.xml
index 392ba617d..c34389ebf 100644
--- a/Greenshot/Languages/language-cs-CZ.xml
+++ b/Greenshot/Languages/language-cs-CZ.xml
@@ -5,7 +5,7 @@
Pokud se vám Greenshot líbí, uvítáme Vaší podporu
Greenshot je hostován na sourceforge.net
Ikony pochází ze sady Yusuke Kamiyamane's Fugue (licence Creative Commons Attribution 3.0)
- Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
Greenshot je ABSOLUTNĚ BEZ ZÁRUKY. Toto je svobodný software, můžete jej dále šířit za určitých podmínek.
Podrobnosti o GNU General Public License:
O programu Greenshot
diff --git a/Greenshot/Languages/language-de-DE.xml b/Greenshot/Languages/language-de-DE.xml
index 2435a7105..9ece82568 100644
--- a/Greenshot/Languages/language-de-DE.xml
+++ b/Greenshot/Languages/language-de-DE.xml
@@ -5,7 +5,7 @@
Wenn Sie Greenshot mögen, können Sie uns gerne unterstützen:
Greenshot wird von GitHub gehostet unter
Icons aus Yusuke Kamiyamane's Fugue icon set (Creative Commons Attribution 3.0 license)
- Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
Für Greenshot besteht KEINERLEI GARANTIE. Greenshot ist freie Software, die Sie unter bestimmten Bedingungen weitergeben dürfen.
Detaillierte Informationen zur GNU General Public License:
Über Greenshot
diff --git a/Greenshot/Languages/language-de-x-franconia.xml b/Greenshot/Languages/language-de-x-franconia.xml
index abbf24bbf..b989bcfe7 100644
--- a/Greenshot/Languages/language-de-x-franconia.xml
+++ b/Greenshot/Languages/language-de-x-franconia.xml
@@ -5,7 +5,7 @@
Wenn der Greenshot gfälld, kannsd uns gern a weng helfn:
Greenshot is a bei GitHub, und zwa dordn:
Dei Fuztl-Bildla sin vom Yusuke Kamiyamane's Fugue icon set (Griäidif Gommens Äddribuschn 3.0 Laisns)
- Kobbireid (C) 2007-2020 Domas Braun, Jens Glingen, Robin Grohm
+ Kobbireid (C) 2007-2021 Domas Braun, Jens Glingen, Robin Grohm
A Garandie gibds für Greenshot ned, des kannst vergessn. Greenshot is umsonsd und wennsd mogst, kannsd es a rumreichn.
Mehr Infos zur GNU Dschännerel Bablig Laisns:
Was issn Greenshot???
diff --git a/Greenshot/Languages/language-el-GR.xml b/Greenshot/Languages/language-el-GR.xml
index 732b54f0c..14cb68bef 100644
--- a/Greenshot/Languages/language-el-GR.xml
+++ b/Greenshot/Languages/language-el-GR.xml
@@ -5,7 +5,7 @@
Αν σας αρέσει το Greenshot, είστε ευπρόσδεκτοι να μας υποστηρίξετε:
Το Greenshot φιλοξενείται από τη GitHub:
Εικονίδια από Yusuke Kamiyamane's Fugue icon set (Creative Commons Attribution 3.0 license)
- Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
Δεν παρέχεται ΚΑΜΙΑ ΕΓΓΥΗΣΗ για το Greenshot. Είναι ελεύθερο λογισμικό. Είστε ελεύθεροι να το αναδιανείμετε κάτω από ορισμένες συνθήκες.
Λεπτομέρειες σχετικά με την GNU General Public License:
Πληροφορίες για το Greenshot
diff --git a/Greenshot/Languages/language-en-US.xml b/Greenshot/Languages/language-en-US.xml
index 1efcd15e9..0537c965b 100644
--- a/Greenshot/Languages/language-en-US.xml
+++ b/Greenshot/Languages/language-en-US.xml
@@ -5,7 +5,7 @@
If you like Greenshot, you are welcome to support us:
Greenshot is hosted by GitHub at
Icons from Yusuke Kamiyamane's Fugue icon set (Creative Commons Attribution 3.0 license)
- Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
Greenshot comes with ABSOLUTELY NO WARRANTY. This is free software, and you are welcome to redistribute it under certain conditions.
Details about the GNU General Public License:
About Greenshot
diff --git a/Greenshot/Languages/language-es-ES.xml b/Greenshot/Languages/language-es-ES.xml
index 22d44abf5..b84aee912 100644
--- a/Greenshot/Languages/language-es-ES.xml
+++ b/Greenshot/Languages/language-es-ES.xml
@@ -5,7 +5,7 @@
Si te gusta Greenshot, te agradeceremos que nos ayudes:
Greenshot está alojado en GitHub en
Iconos del conjunto de iconos Fugue de Yusuke Kamiyamane(Creative Commons Attribution 3.0 license)
- Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
Greenshot viene ABSOLUTAMENTE SIN GARANTIA. Este es software gratuito, y eres bienvenido a redistribuirlo bajo ciertas condiciones.
Detalles acerca de la Licencia General Publica GNU:
Acerca de Greenshot
diff --git a/Greenshot/Languages/language-et-EE.xml b/Greenshot/Languages/language-et-EE.xml
index 0de7a68f7..b358977e8 100644
--- a/Greenshot/Languages/language-et-EE.xml
+++ b/Greenshot/Languages/language-et-EE.xml
@@ -5,7 +5,7 @@
Greenshoti kasutamismugavust ja arendust saate toetada siin:
Greenshot asub portaalis GitHub
Yusuke Kamiyamane on ikoonide tegija Fugue ikooni paketist (Creative Commons Attribution 3.0 litsents)
- Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
Greenshot ei paku GARANTIID. See on vabaravaline programm ja Te võite seda levitava vabalt teatud tingimuste alusel.
Lisainfo GNU Põhilise Avaliku Litsentsi kohta:
Info Greenshoti kohta
diff --git a/Greenshot/Languages/language-fi-FI.xml b/Greenshot/Languages/language-fi-FI.xml
index 13a01263c..f66cc5013 100644
--- a/Greenshot/Languages/language-fi-FI.xml
+++ b/Greenshot/Languages/language-fi-FI.xml
@@ -5,7 +5,7 @@
Jos pidät Greenshotista niin toivottavasti tuet meitä:
Greenshot is hosted by GitHub at
Ikonit ovat Yusuke Kamiyamane:n Fugue ikonisarjasta (Creative Commons Attribution 3.0 license)
- Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
Greenshot comes with ABSOLUTELY NO WARRANTY. This is free software, and you are welcome to redistribute it under certain conditions.
Details about the GNU General Public License:
Tietoja Greenshotista
diff --git a/Greenshot/Languages/language-fr-FR.xml b/Greenshot/Languages/language-fr-FR.xml
index 26349708d..53f8e21f6 100644
--- a/Greenshot/Languages/language-fr-FR.xml
+++ b/Greenshot/Languages/language-fr-FR.xml
@@ -5,7 +5,7 @@
Si vous aimez Greenshot, vous pouvez nous soutenir :
Greenshot est hébergé par GitHub à
Icônes provenant du lot d'icônes Fugue de Kamiyamane Yuusuke (Creative Commons Attribution 3.0 license)
- Copyright © 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ Copyright © 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
Greenshot vous est fourni SANS AUCUNE GARANTIE. C'est un logiciel gratuit que vous êtes libres de redistribuer sous certaines conditions.
Détails de la GNU General Public License :
À propos de Greenshot
diff --git a/Greenshot/Languages/language-fr-QC.xml b/Greenshot/Languages/language-fr-QC.xml
index 629591d62..17c0e5537 100644
--- a/Greenshot/Languages/language-fr-QC.xml
+++ b/Greenshot/Languages/language-fr-QC.xml
@@ -5,7 +5,7 @@
Si vous aimez Greenshot, vous pouvez nous soutenir :
Greenshot est hébergé par GitHub à
Icônes provenant du lot d'icônes Fugue de Kamiyamane Yuusuke (Creative Commons Attribution 3.0 license)
- Copyright © 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ Copyright © 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
Greenshot vous est fourni SANS AUCUNE GARANTIE. C'est un logiciel gratuit que vous êtes libres de redistribuer sous certaines conditions.
Détails de la GNU General Public License :
A propos de Greenshot
diff --git a/Greenshot/Languages/language-he-IL.xml b/Greenshot/Languages/language-he-IL.xml
index 10f5a3c31..4df909d37 100644
--- a/Greenshot/Languages/language-he-IL.xml
+++ b/Greenshot/Languages/language-he-IL.xml
@@ -5,7 +5,7 @@
:אם את\ה נהנה\ית משימוש בתוכנה, את\ה מוזמן לתרום לנו
Greenshot is hosted by GitHub at
Icons from Yusuke Kamiyamane's Fugue icon set (Creative Commons Attribution 3.0 license)
- Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
Greenshot comes with ABSOLUTELY NO WARRANTY. This is free software, and you are welcome to redistribute it under certain conditions.
Details about the GNU General Public License:
Greenshot אודות התוכנה
diff --git a/Greenshot/Languages/language-hu-HU.xml b/Greenshot/Languages/language-hu-HU.xml
index c20c0cf99..0d5a06df9 100644
--- a/Greenshot/Languages/language-hu-HU.xml
+++ b/Greenshot/Languages/language-hu-HU.xml
@@ -5,7 +5,7 @@
Ha szereted Greenshot -ot, akkor támogass minket:
Greenshot kiszolgálója a GitHub
Az ikonokat Yusuke Kamiyamane's Fugue készítette (Creative Commons Attribution 3.0 license)
- Szerzői jog (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ Szerzői jog (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
SEMMIFÉLE GARANCIA sincs a Greenshot -hoz. Ez egy ingyenes program, és hálásak vagyunk, hogy terjeszted bizonyos feltételekkel.
Részletek a GNU Fő Nyílvános Engedélyről:
Greenshot névjegye
diff --git a/Greenshot/Languages/language-id-ID.xml b/Greenshot/Languages/language-id-ID.xml
index ea35af361..e474cae59 100644
--- a/Greenshot/Languages/language-id-ID.xml
+++ b/Greenshot/Languages/language-id-ID.xml
@@ -5,18 +5,18 @@
Jika anda menyukai Greenshot, anda dipersilahkan untuk mendukung kami:
Greenshot dikelola oleh GitHub di
Ikon dari Yusuke Kamiyamane Fugue ikon set (lisensi Creative Commons Attribution 3.0)
- Hak Cipta milik Thomas Braun, Jens Klingen, Robin Krom 2007-2020
-Greenshot comes with ABSOLUTELY NO WARRANTY. This is free software, and you are welcome to redistribute it under certain conditions.
+ Hak Cipta milik Thomas Braun, Jens Klingen, Robin Krom 2007-2021
+Greenshot comes with ABSOLUTELY NO WARRANTY. This is free software, and you are welcome to redistribute it under certain conditions.
Details about the GNU General Public License:
Tentang Greenshot
Greenshot - utilitas penangkap layar yang revolusioner
Tutup
- Maaf, kesalahan yang tak terduga terjadi.
-
-Kabar baiknya: anda dapat membantu kami memperbaikinya dengan mengisi laporan kesalahan.
-Harap kunjungi laman berikut, buat laporan kesalahan baru dan letakkan konten dari area teks ke wadah deskripsi.
-
-Harap tambah penjelasan yang berarti dan sertakan informasi lain yang penting untuk kami tiru kesalahannya.
+ Maaf, kesalahan yang tak terduga terjadi.
+
+Kabar baiknya: anda dapat membantu kami memperbaikinya dengan mengisi laporan kesalahan.
+Harap kunjungi laman berikut, buat laporan kesalahan baru dan letakkan konten dari area teks ke wadah deskripsi.
+
+Harap tambah penjelasan yang berarti dan sertakan informasi lain yang penting untuk kami tiru kesalahannya.
Juga, kami sangat terbantu apabila anda mengecek laporan lain yang sama dengan kepunyaan anda. (Anda dapat menggunakan pencarian untuk mencari dengan cepat.) Terima kasih :)
Kesalahan
Batal
@@ -180,7 +180,7 @@ Juga, kami sangat terbantu apabila anda mengecek laporan lain yang sama dengan k
Outlook dengan teks
Kesalahan
Sesuatu dari Greenshot telah dijalankan.
- Tidak dapat berkas {0}.
+ Tidak dapat berkas {0}.
Harap cek aksesibilitas menuis pada lokasi penyimpanan yang dipilih.
Berkas "{0}" tidak dapat dibuka.
Tidak dapat membuka link '{0}'.
@@ -245,22 +245,22 @@ Harap cek aksesibilitas menuis pada lokasi penyimpanan yang dipilih.
Tangkap Internet Explorer
Kualitas JPEG
Bahasa
- Pedoman berikut akan ditimpa otomatis dalam pola yang ditetapkan:
-${YYYY} tahun, 4 digit
-${MM} bulan, 2 digit
-${DD} hari, 2 digit
-${hh} jam, 2 digit
-${mm} menit, 2 digit
-${ss} detik, 2 digit
-${NUM} angka tambahan, 6 digit
-${title} judul jendela
-${user} pengguna Windows
-${domain} domain Windows
-${hostname} nama PC
-
-Anda juga dapat membuat direktori Greenshot secara dinamis, cukup gunakan simbol garis miring {\} untuk memisahkan folder dan nama berkas
-Contoh: pola ${YYYY}-${MM}-${DD}\${hh}-${mm}-${ss}
-akan menbuat folder untuk hari terbaru di lokasi penyimpan default, cont. 2008-06-29, nama berkas didasarkan pada waktu terbaru
+ Pedoman berikut akan ditimpa otomatis dalam pola yang ditetapkan:
+${YYYY} tahun, 4 digit
+${MM} bulan, 2 digit
+${DD} hari, 2 digit
+${hh} jam, 2 digit
+${mm} menit, 2 digit
+${ss} detik, 2 digit
+${NUM} angka tambahan, 6 digit
+${title} judul jendela
+${user} pengguna Windows
+${domain} domain Windows
+${hostname} nama PC
+
+Anda juga dapat membuat direktori Greenshot secara dinamis, cukup gunakan simbol garis miring {\} untuk memisahkan folder dan nama berkas
+Contoh: pola ${YYYY}-${MM}-${DD}\${hh}-${mm}-${ss}
+akan menbuat folder untuk hari terbaru di lokasi penyimpan default, cont. 2008-06-29, nama berkas didasarkan pada waktu terbaru
cont, 11_58_32 (ditambah ekstensi yang ditetapkan pada pengaturan)
Jaringan dan pembaruan
Output
@@ -296,8 +296,8 @@ cont, 11_58_32 (ditambah ekstensi yang ditetapkan pada pengaturan)
Versi baru Greenshot telah tersedia! Apakah anda ingin mengunduh Greenshot {0}?
Harap tunggu ketika halaman Internet Explorer sedang ditangkap
Peringatan
- hotkey {0} tak dapat terdaftar, kemungkinan akibat alat lain telah mengklaim penggunaan hotkey, anda dapat mengganti hotkey yang lain atau menonaktifkannya.
-
+ hotkey {0} tak dapat terdaftar, kemungkinan akibat alat lain telah mengklaim penggunaan hotkey, anda dapat mengganti hotkey yang lain atau menonaktifkannya.
+
Semua fitur Greenshot masih bekerja dengan baik dari ikon tray menu konteks tanpa hotkey.
Gunakan warna kesukaan
Pertahankan kebeningan
diff --git a/Greenshot/Languages/language-it-IT.xml b/Greenshot/Languages/language-it-IT.xml
index 2d9fc43e0..53fa10837 100644
--- a/Greenshot/Languages/language-it-IT.xml
+++ b/Greenshot/Languages/language-it-IT.xml
@@ -5,12 +5,12 @@
Se ti piace Greenshot, supportaci su:
Greenshot è disponibile nel repository GitHub
Libreria icone del set icone Fugue di Yusuke Kamiyamane (Creative Commons Attribution 3.0 license)
- Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
Greenshot viene fornito SENZA ALCUNA GARANZIA.
-Questo software è garuitio", e potete ri-distribuirlo secondo certe condizioni.
+Questo software è gratuito", e potete ri-distribuirlo secondo certe condizioni.
Dettagli della General Public License GNU:
Info su Greenshot
- Traduzione italiana (v. 16.08.2020) di bovirus e tonytogna
+ Traduzione italiana (v. 29.01.2021) di bovirus e tonytogna
Greenshot - Uno straordinario strumento per copiare immagini dallo schermo
Chiudi
Si è verificato un errore inaspettato.
@@ -133,7 +133,7 @@ Controlla i permessi di accesso per '{0}'.
Adatta a dimensioni di cattura
Offusca (O)
Sfuma
- Modalità di offuscamento
+ Modalità offuscamento
Offusca/pixelizza
Oggetti
Apri cartella su Windows Explorer
@@ -185,7 +185,7 @@ Correggi la maschera noem file e riprova.
Esegui ottimizzazioni per uso con desktop remoto
Riutilizza se possibile la gestione immagini
Evita avviso di salvataggio in chiusura della gestione immagini
- Visualizza anteprima finestra nel menù di contesto (Vista e Windows 7)
+ Visualizza anteprima finestra nel menù contestuale (Vista e Windows 7)
Esportato in: {0}
Si è verificato un errore durante l'esportazione in {0}:
Guida in linea Greenshot
@@ -207,7 +207,7 @@ Correggi la maschera noem file e riprova.
Aggiungi data/ora nel piè di pagina
Opzioni di stampa di Greenshot
Salva come qualità predefinita e non chiedere più
- Qualità di Greenshot
+ Qualità Greenshot
Salva direttamente (usando le impostazioni preferite file destinazione)
Visualizza scelta opzioni di stampa ogni volta che stampi un'immagine
Visualizza scelta qualità ogni volta che si salva un'immagine
diff --git a/Greenshot/Languages/language-ja-JP.xml b/Greenshot/Languages/language-ja-JP.xml
index 2111930ad..c894b9573 100644
--- a/Greenshot/Languages/language-ja-JP.xml
+++ b/Greenshot/Languages/language-ja-JP.xml
@@ -5,7 +5,7 @@
Greenshot がお気に召したなら、是非支援をお願いします :
Greenshot は GitHub によって運営されています :
上山根 祐輔氏の Fugue Icons を使用しています (Creative Commons Attribution 3.0 license) :
- Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
Greenshot には一切の保障がありません。GNU General Public License に定められた条件下で再配布をおこなうことができます。:
Greenshot について
Greenshot - the revolutionary screenshot utility
diff --git a/Greenshot/Languages/language-kab-DZ.xml b/Greenshot/Languages/language-kab-DZ.xml
index 39244e170..31930d2db 100644
--- a/Greenshot/Languages/language-kab-DZ.xml
+++ b/Greenshot/Languages/language-kab-DZ.xml
@@ -5,7 +5,7 @@
Ma tḥemled Greenshot, Mudd-aɣ-d afus :
Greenshot yezdeɣ di sourceforge.net di
Tignitin i d-yekkan seg uqettun n tignitin Fugue n Kamiyamane Yuusuke (Creative Commons Attribution 3.0 license)
- Copyright © 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ Copyright © 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
Greenshot yettunefk-d S WAR ṬMANA. d aseɣẓan ilelli i tzemreḍ ad tezuzreḍ s kra n tewtilin.
Talqayt ɣef GNU General Public License :
Ɣef Greenshot
diff --git a/Greenshot/Languages/language-ko-KR.xml b/Greenshot/Languages/language-ko-KR.xml
index 64379ce8c..a332cea33 100644
--- a/Greenshot/Languages/language-ko-KR.xml
+++ b/Greenshot/Languages/language-ko-KR.xml
@@ -5,7 +5,7 @@
Greenshot이 좋다면 아래 URL로 방문하셔서 지원할 수 있습니다.
Greenshot은 GitHub 관리하에 아래 링크에서 호스팅되고 있습니다
아이콘은 Yusuke Kamiyamane's Fugue icon set으로부터 제공받은 것입니다. (Creative Commons Attribution 3.0 license)
- Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
Greenshot comes with ABSOLUTELY NO WARRANTY. This is free software, and you are welcome to redistribute it under certain conditions.
Details about the GNU General Public License:
Greenshot 프로그램 소개...
diff --git a/Greenshot/Languages/language-lt-LT.xml b/Greenshot/Languages/language-lt-LT.xml
index f69425916..e84388901 100644
--- a/Greenshot/Languages/language-lt-LT.xml
+++ b/Greenshot/Languages/language-lt-LT.xml
@@ -5,7 +5,7 @@
Jei jums patiko Greenshot, galite mus paremti:
Greenshot talpinamas GitHub
IIkonų rinkinys Fugue, аutorius Yusuke Kamiyamane, licencija Creative Commons Attribution 3.0
- Visos teisės saugomos (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ Visos teisės saugomos (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
Greenshot pateikiama BE JOKIŲ GARANTIJŲ. Greenshot — laisvai platinama PĮ su GPL licencija ir jūs galite laisvai ją platinti, laikydamasi licencinės sutarties:
Apie Greenshot
Greenshot — revoliucinis įrankis ekrano nuotraukoms daryti
diff --git a/Greenshot/Languages/language-nl-NL.xml b/Greenshot/Languages/language-nl-NL.xml
index 66601348d..507ece7dc 100644
--- a/Greenshot/Languages/language-nl-NL.xml
+++ b/Greenshot/Languages/language-nl-NL.xml
@@ -5,7 +5,7 @@
Als Greenshot u bevalt, wilt u ons wellicht ondersteunen:
Greenshot wordt uitgegeven door sourceforge.net op
Iconen afkomstig van Yusuke Kamiyamane's Fugue (Creative Commons Attribution 3.0 license)
- Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
Greenshot komt zonder enige garantie! Dit is gratis software en het staat u vrij het onder bepaalde voorwaarden te verspreiden.
Details over de GNU General Public License:
Over Greenshot
diff --git a/Greenshot/Languages/language-nn-NO.xml b/Greenshot/Languages/language-nn-NO.xml
index 291e1e2db..003b11b9a 100644
--- a/Greenshot/Languages/language-nn-NO.xml
+++ b/Greenshot/Languages/language-nn-NO.xml
@@ -5,7 +5,7 @@
Om du likar Greenshot er du velkomen til å støtte oss:
Greenshot held virtuelt hus hjå GitHub:
Ikon frå Yusuke Kamiyamane sit "Fugue" ikonsett (Creative Commons Attribution 3.0-lisens)
- Med kopirett (C) 2007-2020 Thomas Braun, Jens Klingen og Robin Krom. Norsk omsetjing av Ivar Barstad.
+ Med kopirett (C) 2007-2021 Thomas Braun, Jens Klingen og Robin Krom. Norsk omsetjing av Ivar Barstad.
Greenshot har ABSOLUTT INGEN GARANTI. Dette er gratis programvare, og du står fritt til å distribuere det under visse vilkår.
Detaljar om GNU General Public-lisens:
Om Greenshot
diff --git a/Greenshot/Languages/language-pl-PL.xml b/Greenshot/Languages/language-pl-PL.xml
index ea6e96b0a..54e2fd993 100644
--- a/Greenshot/Languages/language-pl-PL.xml
+++ b/Greenshot/Languages/language-pl-PL.xml
@@ -5,7 +5,7 @@
Jeśli podoba Ci się Greenshot, chętnie przyjmiemy Twoje wsparcie:
Greenshot jest utrzymywany przez GitHub pod adresem:
Ikony z zestawu Fugue od Yusuke Kamiyamane (licencja Creative Commons Attribution 3.0):
- Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
Greenshot nie jest objęty JAKĄKOLWIEK GWARANCJĄ. Jako wolne oprogramowanie może być rozpowszechniany na określonych warunkach.
Szczegóły na temat Powszechnej Licencji Publicznej GNU:
O Greenshot
diff --git a/Greenshot/Languages/language-pt-BR.xml b/Greenshot/Languages/language-pt-BR.xml
index 4f379ae80..8bfd938ed 100644
--- a/Greenshot/Languages/language-pt-BR.xml
+++ b/Greenshot/Languages/language-pt-BR.xml
@@ -6,7 +6,7 @@
O Greenshot está armazenado no GitHub em
Ícones de Yusuke Kamiyamane (Biblioteca Fugue, licença "Creative Commons Attribution 3.0")
- Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
O Greenshot não tem NENHUMA GARANTIA. Este software gratuito pode ser redistribuído sob algumas condições.
Detalhes sobre a licença GNU:
diff --git a/Greenshot/Languages/language-pt-PT.xml b/Greenshot/Languages/language-pt-PT.xml
index 8e53f804b..dabc42762 100644
--- a/Greenshot/Languages/language-pt-PT.xml
+++ b/Greenshot/Languages/language-pt-PT.xml
@@ -5,7 +5,7 @@
Se gostou do Greenshot, por favor contribua:
O Greenshot está armazenado no GitHub em
Ícones da colecção Fugue de Yusuke Kamiyamane (Licença "Creative Commons Attribution 3.0")
- Direitos de Autor (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ Direitos de Autor (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
O Greenshot não tem NENHUMA GARANTIA. Este software gratuito pode ser redistribuído sob algumas condições.
Detalhes sobre a licença GNU:
Acerca do Greenshot
diff --git a/Greenshot/Languages/language-ru-RU.xml b/Greenshot/Languages/language-ru-RU.xml
index 9823d8bf1..42d85df80 100644
--- a/Greenshot/Languages/language-ru-RU.xml
+++ b/Greenshot/Languages/language-ru-RU.xml
@@ -5,7 +5,7 @@
Если вам нравится Greenshot, вы можете поддержать нас:
Greenshot размещается на GitHub
Набор иконок Yusuke Kamiyamane's Fugue (Creative Commons Attribution 3.0 license)
- Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
Greenshot поставляется БЕЗ КАКИХ-ЛИБО ГАРАНТИЙ.Это бесплатная программа и вы можете распространять её на определённых условиях.
Подробно о GNU General Public License:
О программе Greenshot
diff --git a/Greenshot/Languages/language-sk-SK.xml b/Greenshot/Languages/language-sk-SK.xml
index 47ed2b116..f47c2bd5b 100644
--- a/Greenshot/Languages/language-sk-SK.xml
+++ b/Greenshot/Languages/language-sk-SK.xml
@@ -5,7 +5,7 @@
Ak se vám Greenshot páči, uvítame vašu podporu:
Greenshot je na GitHub
Ikony z Yusuke Kamiyamane's Fugue icon set (Creative Commons Attribution 3.0 license)
- Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
Greenshot je ÚPLNE BEZ ZÁRUKY. Toto je FREE software, a môžete ho distribuovať za určitých podmienok.
Podrobnosti o GNU General Public License:
O Greenshote
diff --git a/Greenshot/Languages/language-sl-SI.xml b/Greenshot/Languages/language-sl-SI.xml
index 5993e8c89..fd0dc2bc4 100644
--- a/Greenshot/Languages/language-sl-SI.xml
+++ b/Greenshot/Languages/language-sl-SI.xml
@@ -5,18 +5,18 @@
Če vam je Greenshot všeč nas prosim podprite:
Greenshot gostuje pri GitHub
Ikone: Yusuke Kamiyamane's Fugue icon set (Creative Commons Attribution 3.0 license)
- Avtorske pravice (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
-Greenshot absolutno ne ponuja NOBENE GARANCIJE. Program je brezplačen in ga lahko distribuirate pod določenimi pogoji.
+ Avtorske pravice (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
+Greenshot absolutno ne ponuja NOBENE GARANCIJE. Program je brezplačen in ga lahko distribuirate pod določenimi pogoji.
Licenčne podrobnosti GNU General Public License:
O Greenshot-u
Greenshot - revolucija zajema zaslonskih slik
Zapri
- Oprostite, program je izvedel nepričakovano napako.
-
-Dobra novica je, da nam lahko pomagate pri odpravi te napake.
-Prosimo obiščite spodnji URL, prijavite napako (create bug) in prilepite vsebino opisa napake.
-
-Prosimo dopišite še razumljiv opis kako ste prišli do težave, da jo bomo lahko ponovili.
+ Oprostite, program je izvedel nepričakovano napako.
+
+Dobra novica je, da nam lahko pomagate pri odpravi te napake.
+Prosimo obiščite spodnji URL, prijavite napako (create bug) in prilepite vsebino opisa napake.
+
+Prosimo dopišite še razumljiv opis kako ste prišli do težave, da jo bomo lahko ponovili.
Pred objavo preverite tudi ali je napaka že prijavlja s strani kakšnega drugega uporabnika. Hvala :)
Napaka
Prekliči
@@ -143,7 +143,7 @@ Pred objavo preverite tudi ali je napaka že prijavlja s strani kakšnega drugeg
Outlook kot text
Napaka
Greenshot že teče!
- Ne morem shraniti v {0}.
+ Ne morem shraniti v {0}.
Prosim preverite pravice pisanja v ta direktorij.
Datoteka "{0}" ne more biti odprta.
Ne morem odpreti povezave '{0}'.
@@ -235,8 +235,8 @@ Prosim preverite pravice pisanja v ta direktorij.
Na voljo je nova verzija Greenshot-a! Ali želite prenesti Greenshot {0}?
Prosimo počakajte - zajema se Internet Explorer...
Opozorilo
- Bližnjica "{0}" ne more biti registrirana. Težava je verjetno v tem, da nek drug program uporablja isto bližnjico ! Nastavite si drugo bližnjično tipko ali deaktivirajte bližnjice za ta program.
-
+ Bližnjica "{0}" ne more biti registrirana. Težava je verjetno v tem, da nek drug program uporablja isto bližnjico ! Nastavite si drugo bližnjično tipko ali deaktivirajte bližnjice za ta program.
+
Vse funkcije Greenshota še vedno delujejo preko ikone za hitri zagon.
Uporabi lastne barve
Ohrani prosojnost
diff --git a/Greenshot/Languages/language-sr-RS.xml b/Greenshot/Languages/language-sr-RS.xml
index f26d84da6..6b624dd9c 100644
--- a/Greenshot/Languages/language-sr-RS.xml
+++ b/Greenshot/Languages/language-sr-RS.xml
@@ -5,7 +5,7 @@
Ако вам се свиђа Гриншот, помозите нам:
Гриншот покреће Сорсфорџ (GitHub):
Иконе су преузете из пакета „Fugue“ Јусуке Камијамане (лиценца Кријејтив комонс Ауторство 3.0)
- Ауторска права © 2007–2020 Томас Браун, Џенс Клинџен, Робин Кром
+ Ауторска права © 2007–2021 Томас Браун, Џенс Клинџен, Робин Кром
Гриншот се издаје БЕЗ ИКАКВЕ ГАРАНЦИЈЕ. Он је бесплатан програм, који можете да делите под одређеним условима.
Више информација о ГНУ-овој општој јавној лиценци:
О програму
diff --git a/Greenshot/Languages/language-sv-SE.xml b/Greenshot/Languages/language-sv-SE.xml
index dedd0b5ef..3fe2df709 100644
--- a/Greenshot/Languages/language-sv-SE.xml
+++ b/Greenshot/Languages/language-sv-SE.xml
@@ -5,7 +5,7 @@
Om du gillar Greenshot, så är du välkommen att stödja oss:
Greenshots hemsida tillhandahålls av GitHub på
Ikoner från "Yusuke Kamiyamane's Fugue icon set" (Creative Commons Attribution 3.0 license)
- Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
Greenshot lämnar ABSOLUT INGA GARANTIER. Detta är ett gratisprogram, och du får vidaredistribuera programmet under vissa villkor.
Detaljer om "GNU General Public License":
Om Greenshot
diff --git a/Greenshot/Languages/language-tr-TR.xml b/Greenshot/Languages/language-tr-TR.xml
index 16c5e94ed..b5a43f083 100644
--- a/Greenshot/Languages/language-tr-TR.xml
+++ b/Greenshot/Languages/language-tr-TR.xml
@@ -5,7 +5,7 @@
Greenshot'ı sevdiyseniz, bizi destekleyin:
Greenshot GitHub üzerinde şu adreste barındırılmaktadır:
Simgeler Yusuke Kamiyamane'nin Fugue simge setidir (Creative Commons Attribution 3.0 lisansı)
- Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
Greenshot HİÇ BİR GARANTİ vermez. Serbest bir yazılımdır ve belirli koşullar altında dağıtmakta serbestsiniz. GNU
Genel Kamu Lisanslı hakkında daha fazla bilgi için:
Greenshot Hakkında
diff --git a/Greenshot/Languages/language-uk-UA.xml b/Greenshot/Languages/language-uk-UA.xml
index 041d73095..850a5ea7f 100644
--- a/Greenshot/Languages/language-uk-UA.xml
+++ b/Greenshot/Languages/language-uk-UA.xml
@@ -5,7 +5,7 @@
Якщо Вам подобається Greenshot, можете підтримати нас:
Greenshot розташовується на GitHub
Набір піктограм Fugue від Yusuke Kamiyamane (ліцензія Creative Commons Attribution 3.0)
- Авторство © 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ Авторство © 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
Greenshot постачається АБСОЛЮТНО БЕЗ ГАРАНТІЇ. Це вільне програмне забезпечення, Ви можете розповсюджувати його за певних умов.
Подробиці Загальної Публічної Ліцензії GNU:
Про Greenshot
diff --git a/Greenshot/Languages/language-vi-VN.xml b/Greenshot/Languages/language-vi-VN.xml
index 541513466..a4b1a73c2 100644
--- a/Greenshot/Languages/language-vi-VN.xml
+++ b/Greenshot/Languages/language-vi-VN.xml
@@ -5,7 +5,7 @@
Hãy ủng hộ nếu bạn thấy Greenshot hữu dụng:
Greenshot được tài trợ bởi GitHub
Dùng biểu tượng Fugue (Giấy phép Commons Attribution 3.0 license) :
- Bản quyền (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ Bản quyền (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
Greenshot không đi kèm theo đảm bảo nào và được phân phối dưới giấy phép GNU General Public License.
Giới thiệu Greenshot
Greenshot - Công cụ chụp màn hình
diff --git a/Greenshot/Languages/language-zh-CN.xml b/Greenshot/Languages/language-zh-CN.xml
index 77519c498..7325fff33 100644
--- a/Greenshot/Languages/language-zh-CN.xml
+++ b/Greenshot/Languages/language-zh-CN.xml
@@ -5,7 +5,7 @@
如果您喜欢这个软件,希望您可以捐助我们:
Greenshot 托管在 GitHub
图标来源:Yusuke Kamiyamane的Fugue图标基于(Creative Commons Attribution 3.0 协议)
- 版权所有 (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ 版权所有 (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
作者不会对程序进行任何担保。
此程序为自由软件,您可以在遵守 GNU 通用公共许可协议下任意传播本软件。
关于 GNU 通用公共许可协议:
diff --git a/Greenshot/Languages/language-zh-TW.xml b/Greenshot/Languages/language-zh-TW.xml
index 320db2614..590ec8f05 100644
--- a/Greenshot/Languages/language-zh-TW.xml
+++ b/Greenshot/Languages/language-zh-TW.xml
@@ -5,7 +5,7 @@
如果您喜歡 Greenshot,歡迎您支持我們:
Greenshot 的主機在 GitHub 網址是
圖片來源: Yusuke Kamiyamane's Fugue 圖示集 (Creative Commons Attribution 3.0 授權)
- Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
Greenshot 不對這個程式做任何擔保。 這個程式是自由軟體,您可以在 GNU General Public License 下任意散佈本軟體。
關於GNU General Public License 詳細資料:
關於 Greenshot
diff --git a/Greenshot/Memento/AddElementMemento.cs b/Greenshot/Memento/AddElementMemento.cs
index 980bb17b1..07b4f18d3 100644
--- a/Greenshot/Memento/AddElementMemento.cs
+++ b/Greenshot/Memento/AddElementMemento.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/Greenshot/Memento/AddElementsMemento.cs b/Greenshot/Memento/AddElementsMemento.cs
index 91a4f4d56..1f73f2106 100644
--- a/Greenshot/Memento/AddElementsMemento.cs
+++ b/Greenshot/Memento/AddElementsMemento.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/Greenshot/Memento/ChangeFieldHolderMemento.cs b/Greenshot/Memento/ChangeFieldHolderMemento.cs
index fc94df076..225e8de20 100644
--- a/Greenshot/Memento/ChangeFieldHolderMemento.cs
+++ b/Greenshot/Memento/ChangeFieldHolderMemento.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
@@ -55,18 +55,11 @@ namespace Greenshot.Memento
public bool Merge(IMemento otherMemento)
{
- if (otherMemento is ChangeFieldHolderMemento other)
- {
- if (other._drawableContainer.Equals(_drawableContainer))
- {
- if (other._fieldToBeChanged.Equals(_fieldToBeChanged))
- {
- // Match, do not store anything as the initial state is what we want.
- return true;
- }
- }
- }
- return false;
+ if (otherMemento is not ChangeFieldHolderMemento other) return false;
+
+ if (!other._drawableContainer.Equals(_drawableContainer)) return false;
+
+ return other._fieldToBeChanged.Equals(_fieldToBeChanged);
}
public IMemento Restore()
diff --git a/Greenshot/Memento/DeleteElementMemento.cs b/Greenshot/Memento/DeleteElementMemento.cs
index fd9e793b2..cf921713f 100644
--- a/Greenshot/Memento/DeleteElementMemento.cs
+++ b/Greenshot/Memento/DeleteElementMemento.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
@@ -27,12 +27,12 @@ namespace Greenshot.Memento {
/// The DeleteElementMemento makes it possible to undo deleting an element
///
public class DeleteElementMemento : IMemento {
- private IDrawableContainer drawableContainer;
- private readonly Surface surface;
+ private IDrawableContainer _drawableContainer;
+ private readonly Surface _surface;
public DeleteElementMemento(Surface surface, IDrawableContainer drawableContainer) {
- this.surface = surface;
- this.drawableContainer = drawableContainer;
+ _surface = surface;
+ _drawableContainer = drawableContainer;
}
public void Dispose() {
@@ -40,12 +40,13 @@ namespace Greenshot.Memento {
GC.SuppressFinalize(this);
}
- protected virtual void Dispose(bool disposing) {
- if (disposing) {
- if (drawableContainer != null) {
- drawableContainer.Dispose();
- drawableContainer = null;
- }
+ protected virtual void Dispose(bool disposing)
+ {
+ if (!disposing) return;
+
+ if (_drawableContainer != null) {
+ _drawableContainer.Dispose();
+ _drawableContainer = null;
}
}
@@ -55,17 +56,17 @@ namespace Greenshot.Memento {
public IMemento Restore() {
// Before
- drawableContainer.Invalidate();
+ _drawableContainer.Invalidate();
- AddElementMemento oldState = new AddElementMemento(surface, drawableContainer);
- surface.AddElement(drawableContainer, false);
+ var oldState = new AddElementMemento(_surface, _drawableContainer);
+ _surface.AddElement(_drawableContainer, false);
// The container has a selected flag which represents the state at the moment it was deleted.
- if (drawableContainer.Selected) {
- surface.SelectElement(drawableContainer);
+ if (_drawableContainer.Selected) {
+ _surface.SelectElement(_drawableContainer);
}
// After
- drawableContainer.Invalidate();
+ _drawableContainer.Invalidate();
return oldState;
}
}
diff --git a/Greenshot/Memento/DeleteElementsMemento.cs b/Greenshot/Memento/DeleteElementsMemento.cs
index 98e3c63bf..33b0fe0ac 100644
--- a/Greenshot/Memento/DeleteElementsMemento.cs
+++ b/Greenshot/Memento/DeleteElementsMemento.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
@@ -59,7 +59,7 @@ namespace Greenshot.Memento
public IMemento Restore()
{
- AddElementsMemento oldState = new AddElementsMemento(_surface, _containerList);
+ var oldState = new AddElementsMemento(_surface, _containerList);
_surface.AddElements(_containerList, false);
// After
_surface.Invalidate();
diff --git a/Greenshot/Memento/DrawableContainerBoundsChangeMemento.cs b/Greenshot/Memento/DrawableContainerBoundsChangeMemento.cs
index 9d29ea05d..32870a88a 100644
--- a/Greenshot/Memento/DrawableContainerBoundsChangeMemento.cs
+++ b/Greenshot/Memento/DrawableContainerBoundsChangeMemento.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
@@ -31,8 +31,8 @@ namespace Greenshot.Memento
///
public class DrawableContainerBoundsChangeMemento : IMemento
{
- private readonly List _points = new List();
- private readonly List _sizes = new List();
+ private readonly List _points = new();
+ private readonly List _sizes = new();
private IDrawableContainerList _listOfdrawableContainer;
private void StoreBounds()
@@ -76,15 +76,14 @@ namespace Greenshot.Memento
public bool Merge(IMemento otherMemento)
{
- if (otherMemento is DrawableContainerBoundsChangeMemento other)
- {
- if (ObjectExtensions.CompareLists(_listOfdrawableContainer, other._listOfdrawableContainer))
- {
- // Lists are equal, as we have the state already we can ignore the new memento
- return true;
- }
- }
- return false;
+ if (otherMemento is not DrawableContainerBoundsChangeMemento other) return false;
+
+ if (ObjectExtensions.CompareLists(_listOfdrawableContainer, other._listOfdrawableContainer))
+ {
+ // Lists are equal, as we have the state already we can ignore the new memento
+ return true;
+ }
+ return false;
}
public IMemento Restore()
diff --git a/Greenshot/Memento/SurfaceBackgroundChangeMemento.cs b/Greenshot/Memento/SurfaceBackgroundChangeMemento.cs
index efece64d2..a20823878 100644
--- a/Greenshot/Memento/SurfaceBackgroundChangeMemento.cs
+++ b/Greenshot/Memento/SurfaceBackgroundChangeMemento.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
@@ -45,18 +45,19 @@ namespace Greenshot.Memento {
Dispose(true);
}
- protected virtual void Dispose(bool disposing) {
- if (disposing) {
- if (_matrix != null) {
- _matrix.Dispose();
- _matrix = null;
- }
- if (_image != null) {
- _image.Dispose();
- _image = null;
- }
- _surface = null;
+ protected virtual void Dispose(bool disposing)
+ {
+ if (!disposing) return;
+
+ if (_matrix != null) {
+ _matrix.Dispose();
+ _matrix = null;
}
+ if (_image != null) {
+ _image.Dispose();
+ _image = null;
+ }
+ _surface = null;
}
public bool Merge(IMemento otherMemento) {
diff --git a/Greenshot/Memento/TextChangeMemento.cs b/Greenshot/Memento/TextChangeMemento.cs
index a15907adb..4971b8ff0 100644
--- a/Greenshot/Memento/TextChangeMemento.cs
+++ b/Greenshot/Memento/TextChangeMemento.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
@@ -27,12 +27,12 @@ namespace Greenshot.Memento {
/// The TextChangeMemento makes it possible to undo-redo an IDrawableContainer move
///
public class TextChangeMemento : IMemento {
- private TextContainer textContainer;
- private readonly string oldText;
+ private TextContainer _textContainer;
+ private readonly string _oldText;
public TextChangeMemento(TextContainer textContainer) {
- this.textContainer = textContainer;
- oldText = textContainer.Text;
+ _textContainer = textContainer;
+ _oldText = textContainer.Text;
}
public void Dispose() {
@@ -41,27 +41,23 @@ namespace Greenshot.Memento {
protected virtual void Dispose(bool disposing) {
if (disposing) {
- textContainer = null;
+ _textContainer = null;
}
}
public bool Merge(IMemento otherMemento) {
- if (otherMemento is TextChangeMemento other) {
- if (other.textContainer.Equals(textContainer)) {
- // Match, do not store anything as the initial state is what we want.
- return true;
- }
- }
- return false;
+ if (otherMemento is not TextChangeMemento other) return false;
+
+ return other._textContainer.Equals(_textContainer);
}
public IMemento Restore() {
// Before
- textContainer.Invalidate();
- TextChangeMemento oldState = new TextChangeMemento(textContainer);
- textContainer.ChangeText(oldText, false);
+ _textContainer.Invalidate();
+ TextChangeMemento oldState = new TextChangeMemento(_textContainer);
+ _textContainer.ChangeText(_oldText, false);
// After
- textContainer.Invalidate();
+ _textContainer.Invalidate();
return oldState;
}
}
diff --git a/Greenshot/Processors/TitleFixProcessor.cs b/Greenshot/Processors/TitleFixProcessor.cs
index 7c44e218e..7bcc59f01 100644
--- a/Greenshot/Processors/TitleFixProcessor.cs
+++ b/Greenshot/Processors/TitleFixProcessor.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/Greenshot/releases/innosetup/scripts/products.pas b/Greenshot/releases/innosetup/scripts/products.pas
index 3fa140e54..3335007e7 100644
--- a/Greenshot/releases/innosetup/scripts/products.pas
+++ b/Greenshot/releases/innosetup/scripts/products.pas
@@ -251,7 +251,7 @@ begin
//if SuppressibleMsgBox(FmtMessage(CustomMessage('depdownload_msg'), [FmtMessage(downloadMessage, [''])]), mbConfirmation, MB_YESNO, IDYES) = IDNO then
// Result := false
//else if
- if isxdl_DownloadFiles(StrToInt(ExpandConstant('{wizardhwnd}'))) = 0 then
+ if isxdl_DownloadFiles(StrToInt(ExpandConstant('{wizardhWnd}'))) = 0 then
Result := false;
end;
end;
diff --git a/Greenshot/releases/innosetup/setup.iss b/Greenshot/releases/innosetup/setup.iss
index 7735af213..3195d1f55 100644
--- a/Greenshot/releases/innosetup/setup.iss
+++ b/Greenshot/releases/innosetup/setup.iss
@@ -85,7 +85,7 @@ Source: {#BaseDir}\GreenshotOCRCommand\{#BinDir}\GreenshotOCRCommand.exe; DestDi
Source: {#BaseDir}\GreenshotOCRCommand\{#BinDir}\GreenshotOCRCommand.exe.config; DestDir: {app}\Plugins\GreenshotOCRPlugin; Components: plugins\ocr; Flags: overwritereadonly recursesubdirs ignoreversion replacesameversion;
;JIRA Plugin
Source: {#BaseDir}\GreenshotJiraPlugin\{#BinDir}\GreenshotJiraPlugin.dll; DestDir: {app}\Plugins\GreenshotJiraPlugin; Components: plugins\jira; Flags: overwritereadonly recursesubdirs ignoreversion replacesameversion;
-Source: {#BaseDir}\GreenshotJiraPlugin\{#BinDir}\Dapplo.Jira.dll; DestDir: {app}\Plugins\GreenshotJiraPlugin; Components: plugins\jira; Flags: overwritereadonly recursesubdirs ignoreversion replacesameversion;
+Source: {#BaseDir}\GreenshotJiraPlugin\{#BinDir}\Dapplo.Jira*.dll; DestDir: {app}\Plugins\GreenshotJiraPlugin; Components: plugins\jira; Flags: overwritereadonly recursesubdirs ignoreversion replacesameversion;
Source: {#BaseDir}\GreenshotJiraPlugin\Languages\language_jira*.xml; DestDir: {app}\Languages\Plugins\GreenshotJiraPlugin; Components: plugins\jira; Flags: overwritereadonly ignoreversion replacesameversion;
;Imgur Plugin
Source: {#BaseDir}\GreenshotImgurPlugin\{#BinDir}\GreenshotImgurPlugin.dll; DestDir: {app}\Plugins\GreenshotImgurPlugin; Components: plugins\imgur; Flags: overwritereadonly recursesubdirs ignoreversion replacesameversion;
@@ -133,7 +133,7 @@ DefaultGroupName={#ExeName}
InfoBeforeFile=..\additional_files\readme.txt
LicenseFile=..\additional_files\license.txt
LanguageDetectionMethod=uilanguage
-MinVersion=6.1.7600
+MinVersion=6.1sp1
OutputBaseFilename={#ExeName}-INSTALLER-{#Version}-UNSTABLE
OutputDir=..\
PrivilegesRequired=lowest
diff --git a/GreenshotBoxPlugin/BoxConfiguration.cs b/GreenshotBoxPlugin/BoxConfiguration.cs
index 27ac67676..b8e9e0965 100644
--- a/GreenshotBoxPlugin/BoxConfiguration.cs
+++ b/GreenshotBoxPlugin/BoxConfiguration.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom, Francis Noel
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom, Francis Noel
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
@@ -22,6 +22,7 @@
using System.Windows.Forms;
using GreenshotPlugin.Core;
using System;
+using GreenshotBoxPlugin.Forms;
using GreenshotPlugin.IniFile;
namespace GreenshotBoxPlugin {
diff --git a/GreenshotBoxPlugin/BoxDestination.cs b/GreenshotBoxPlugin/BoxDestination.cs
index 8cdd53515..06402ca89 100644
--- a/GreenshotBoxPlugin/BoxDestination.cs
+++ b/GreenshotBoxPlugin/BoxDestination.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom, Francis Noel
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom, Francis Noel
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotBoxPlugin/BoxEntities.cs b/GreenshotBoxPlugin/BoxEntities.cs
index 23cc4a8c4..a1f1a5c61 100644
--- a/GreenshotBoxPlugin/BoxEntities.cs
+++ b/GreenshotBoxPlugin/BoxEntities.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom, Francis Noel
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom, Francis Noel
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotBoxPlugin/BoxPlugin.cs b/GreenshotBoxPlugin/BoxPlugin.cs
index 4848c4df2..b15835063 100644
--- a/GreenshotBoxPlugin/BoxPlugin.cs
+++ b/GreenshotBoxPlugin/BoxPlugin.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom, Francis Noel
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom, Francis Noel
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
@@ -45,13 +45,14 @@ namespace GreenshotBoxPlugin {
GC.SuppressFinalize(this);
}
- protected void Dispose(bool disposing) {
- if (disposing) {
- if (_itemPlugInConfig != null) {
- _itemPlugInConfig.Dispose();
- _itemPlugInConfig = null;
- }
- }
+ protected void Dispose(bool disposing)
+ {
+ if (!disposing) return;
+
+ if (_itemPlugInConfig == null) return;
+
+ _itemPlugInConfig.Dispose();
+ _itemPlugInConfig = null;
}
///
diff --git a/GreenshotBoxPlugin/BoxUtils.cs b/GreenshotBoxPlugin/BoxUtils.cs
index fb14aae29..7b4d50756 100644
--- a/GreenshotBoxPlugin/BoxUtils.cs
+++ b/GreenshotBoxPlugin/BoxUtils.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom, Francis Noel
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom, Francis Noel
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotBoxPlugin/Forms/BoxForm.cs b/GreenshotBoxPlugin/Forms/BoxForm.cs
index 7083d89d0..1ab7aed75 100644
--- a/GreenshotBoxPlugin/Forms/BoxForm.cs
+++ b/GreenshotBoxPlugin/Forms/BoxForm.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom, Francis Noel
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom, Francis Noel
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotBoxPlugin/Forms/SettingsForm.Designer.cs b/GreenshotBoxPlugin/Forms/SettingsForm.Designer.cs
index 385452002..556cfe413 100644
--- a/GreenshotBoxPlugin/Forms/SettingsForm.Designer.cs
+++ b/GreenshotBoxPlugin/Forms/SettingsForm.Designer.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom, Francis Noel
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom, Francis Noel
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
@@ -18,7 +18,7 @@
* You should have received a copy of the GNU General Public License
* along with this program. If not, see .
*/
-namespace GreenshotBoxPlugin {
+namespace GreenshotBoxPlugin.Forms {
partial class SettingsForm {
///
/// Designer variable used to keep track of non-visual components.
diff --git a/GreenshotBoxPlugin/Forms/SettingsForm.cs b/GreenshotBoxPlugin/Forms/SettingsForm.cs
index 954dc13de..49e62fd17 100644
--- a/GreenshotBoxPlugin/Forms/SettingsForm.cs
+++ b/GreenshotBoxPlugin/Forms/SettingsForm.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom, Francis Noel
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom, Francis Noel
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
@@ -19,9 +19,7 @@
* along with this program. If not, see .
*/
-using GreenshotBoxPlugin.Forms;
-
-namespace GreenshotBoxPlugin {
+namespace GreenshotBoxPlugin.Forms {
///
/// Description of PasswordRequestForm.
///
diff --git a/GreenshotBoxPlugin/GreenshotBoxPlugin.Credentials.template b/GreenshotBoxPlugin/GreenshotBoxPlugin.Credentials.template
index 253514e60..9ad35eced 100644
--- a/GreenshotBoxPlugin/GreenshotBoxPlugin.Credentials.template
+++ b/GreenshotBoxPlugin/GreenshotBoxPlugin.Credentials.template
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotBoxPlugin/LanguageKeys.cs b/GreenshotBoxPlugin/LanguageKeys.cs
index 7019cdca2..6e757a01d 100644
--- a/GreenshotBoxPlugin/LanguageKeys.cs
+++ b/GreenshotBoxPlugin/LanguageKeys.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom, Francis Noel
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom, Francis Noel
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotBoxPlugin/Properties/AssemblyInfo.cs b/GreenshotBoxPlugin/Properties/AssemblyInfo.cs
index ce75d8750..b6b19f1c8 100644
--- a/GreenshotBoxPlugin/Properties/AssemblyInfo.cs
+++ b/GreenshotBoxPlugin/Properties/AssemblyInfo.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom, Francis Noel
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom, Francis Noel
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotConfluencePlugin/Confluence.cs b/GreenshotConfluencePlugin/Confluence.cs
index 3ccfce630..bb803602c 100644
--- a/GreenshotConfluencePlugin/Confluence.cs
+++ b/GreenshotConfluencePlugin/Confluence.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
@@ -18,15 +18,15 @@
* You should have received a copy of the GNU General Public License
* along with this program. If not, see .
*/
+
using System;
using System.Collections.Generic;
using System.Windows.Forms;
-using GreenshotConfluencePlugin;
using GreenshotConfluencePlugin.confluence;
using GreenshotPlugin.Core;
using GreenshotPlugin.IniFile;
-namespace Confluence {
+namespace GreenshotConfluencePlugin {
public class Page {
public Page(RemotePage page) {
Id = page.id;
diff --git a/GreenshotConfluencePlugin/ConfluenceConfiguration.cs b/GreenshotConfluencePlugin/ConfluenceConfiguration.cs
index a62dcbf38..5a3e7019c 100644
--- a/GreenshotConfluencePlugin/ConfluenceConfiguration.cs
+++ b/GreenshotConfluencePlugin/ConfluenceConfiguration.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotConfluencePlugin/ConfluenceDestination.cs b/GreenshotConfluencePlugin/ConfluenceDestination.cs
index 63bf60f01..d7794989a 100644
--- a/GreenshotConfluencePlugin/ConfluenceDestination.cs
+++ b/GreenshotConfluencePlugin/ConfluenceDestination.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
@@ -25,7 +25,6 @@ using System.Drawing;
using System.IO;
using System.Threading;
using System.Windows;
-using Confluence;
using GreenshotPlugin.Controls;
using GreenshotPlugin.Core;
using GreenshotPlugin.IniFile;
@@ -129,7 +128,7 @@ namespace GreenshotConfluencePlugin {
bool openPage = (_page == null) && ConfluenceConfig.OpenPageAfterUpload;
string filename = FilenameHelper.GetFilenameWithoutExtensionFromPattern(CoreConfig.OutputFileFilenamePattern, captureDetails);
if (selectedPage == null) {
- ConfluenceUpload confluenceUpload = new ConfluenceUpload(filename);
+ Forms.ConfluenceUpload confluenceUpload = new Forms.ConfluenceUpload(filename);
bool? dialogResult = confluenceUpload.ShowDialog();
if (dialogResult.HasValue && dialogResult.Value) {
selectedPage = confluenceUpload.SelectedPage;
diff --git a/GreenshotConfluencePlugin/ConfluencePlugin.cs b/GreenshotConfluencePlugin/ConfluencePlugin.cs
index 78680f24a..f0014f221 100644
--- a/GreenshotConfluencePlugin/ConfluencePlugin.cs
+++ b/GreenshotConfluencePlugin/ConfluencePlugin.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
@@ -19,14 +19,14 @@
* along with this program. If not, see .
*/
-using Confluence;
using GreenshotPlugin.Core;
using System;
using System.Windows;
+using GreenshotConfluencePlugin.Forms;
+using GreenshotConfluencePlugin.Support;
using GreenshotPlugin.IniFile;
using GreenshotPlugin.Interfaces;
using GreenshotPlugin.Interfaces.Plugin;
-using TranslationByMarkupExtension;
namespace GreenshotConfluencePlugin {
///
diff --git a/GreenshotConfluencePlugin/ConfluenceUtils.cs b/GreenshotConfluencePlugin/ConfluenceUtils.cs
index 7c9e84b00..ccb808a0f 100644
--- a/GreenshotConfluencePlugin/ConfluenceUtils.cs
+++ b/GreenshotConfluencePlugin/ConfluenceUtils.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
@@ -33,8 +33,8 @@ namespace GreenshotConfluencePlugin {
public class ConfluenceUtils {
private static readonly log4net.ILog LOG = log4net.LogManager.GetLogger(typeof(ConfluenceUtils));
- public static List GetCurrentPages() {
- List pages = new List();
+ public static List GetCurrentPages() {
+ List pages = new List();
Regex pageIdRegex = new Regex(@"pageId=(\d+)");
Regex spacePageRegex = new Regex(@"\/display\/([^\/]+)\/([^#]+)");
foreach(string browserurl in GetBrowserUrls()) {
@@ -50,7 +50,7 @@ namespace GreenshotConfluencePlugin {
long pageId = long.Parse(pageIdMatch[0].Groups[1].Value);
try {
bool pageDouble = false;
- foreach(Confluence.Page page in pages) {
+ foreach(Page page in pages) {
if (page.Id == pageId) {
pageDouble = true;
LOG.DebugFormat("Skipping double page with ID {0}", pageId);
@@ -58,7 +58,7 @@ namespace GreenshotConfluencePlugin {
}
}
if (!pageDouble) {
- Confluence.Page page = ConfluencePlugin.ConfluenceConnector.GetPage(pageId);
+ Page page = ConfluencePlugin.ConfluenceConnector.GetPage(pageId);
LOG.DebugFormat("Adding page {0}", page.Title);
pages.Add(page);
}
@@ -82,7 +82,7 @@ namespace GreenshotConfluencePlugin {
}
try {
bool pageDouble = false;
- foreach(Confluence.Page page in pages) {
+ foreach(Page page in pages) {
if (page.Title.Equals(title)) {
LOG.DebugFormat("Skipping double page with title {0}", title);
pageDouble = true;
@@ -90,7 +90,7 @@ namespace GreenshotConfluencePlugin {
}
}
if (!pageDouble) {
- Confluence.Page page = ConfluencePlugin.ConfluenceConnector.GetPage(space, title);
+ Page page = ConfluencePlugin.ConfluenceConnector.GetPage(space, title);
LOG.DebugFormat("Adding page {0}", page.Title);
pages.Add(page);
diff --git a/GreenshotConfluencePlugin/EnumDisplayer.cs b/GreenshotConfluencePlugin/EnumDisplayer.cs
index 2e4ded768..84ca2925e 100644
--- a/GreenshotConfluencePlugin/EnumDisplayer.cs
+++ b/GreenshotConfluencePlugin/EnumDisplayer.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotConfluencePlugin/Forms/ConfluenceConfigurationForm.xaml b/GreenshotConfluencePlugin/Forms/ConfluenceConfigurationForm.xaml
index b22e55d9b..c6b6b48a6 100644
--- a/GreenshotConfluencePlugin/Forms/ConfluenceConfigurationForm.xaml
+++ b/GreenshotConfluencePlugin/Forms/ConfluenceConfigurationForm.xaml
@@ -1,33 +1,33 @@
-
+ xmlns:gsc="clr-namespace:GreenshotPlugin.Core;assembly=GreenshotPlugin"
+ xmlns:support="clr-namespace:GreenshotConfluencePlugin.Support"
+ Title="{support:Translate plugin_settings}" SizeToContent="WidthAndHeight" ResizeMode="NoResize" Icon="/GreenshotConfluencePlugin;component/Images/Confluence.ico">
-
-
-
+
+
+
-
+
-
+
-
+
-
-
+
+
\ No newline at end of file
diff --git a/GreenshotConfluencePlugin/Forms/ConfluenceConfigurationForm.xaml.cs b/GreenshotConfluencePlugin/Forms/ConfluenceConfigurationForm.xaml.cs
index ca662b316..9269072d4 100644
--- a/GreenshotConfluencePlugin/Forms/ConfluenceConfigurationForm.xaml.cs
+++ b/GreenshotConfluencePlugin/Forms/ConfluenceConfigurationForm.xaml.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
@@ -21,7 +21,7 @@
using System.Windows;
-namespace GreenshotConfluencePlugin {
+namespace GreenshotConfluencePlugin.Forms {
///
/// Interaction logic for ConfluenceConfigurationForm.xaml
///
diff --git a/GreenshotConfluencePlugin/Forms/ConfluencePagePicker.xaml b/GreenshotConfluencePlugin/Forms/ConfluencePagePicker.xaml
index 6455e86b5..e9ae3f97b 100644
--- a/GreenshotConfluencePlugin/Forms/ConfluencePagePicker.xaml
+++ b/GreenshotConfluencePlugin/Forms/ConfluencePagePicker.xaml
@@ -1,4 +1,4 @@
-
diff --git a/GreenshotConfluencePlugin/Forms/ConfluencePagePicker.xaml.cs b/GreenshotConfluencePlugin/Forms/ConfluencePagePicker.xaml.cs
index 9d52f49e9..4f2723c89 100644
--- a/GreenshotConfluencePlugin/Forms/ConfluencePagePicker.xaml.cs
+++ b/GreenshotConfluencePlugin/Forms/ConfluencePagePicker.xaml.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
@@ -19,10 +19,9 @@
* along with this program. If not, see .
*/
-using Confluence;
using System.Collections.Generic;
-namespace GreenshotConfluencePlugin {
+namespace GreenshotConfluencePlugin.Forms {
///
/// Interaction logic for ConfluencePagePicker.xaml
///
diff --git a/GreenshotConfluencePlugin/Forms/ConfluenceSearch.xaml b/GreenshotConfluencePlugin/Forms/ConfluenceSearch.xaml
index e30f9ab6e..073a437fe 100644
--- a/GreenshotConfluencePlugin/Forms/ConfluenceSearch.xaml
+++ b/GreenshotConfluencePlugin/Forms/ConfluenceSearch.xaml
@@ -1,8 +1,9 @@
-
+ xmlns:support="clr-namespace:GreenshotConfluencePlugin.Support"
+ Loaded="Page_Loaded">
@@ -16,9 +17,9 @@
-
-
-
+
+
+
diff --git a/GreenshotConfluencePlugin/Forms/ConfluenceSearch.xaml.cs b/GreenshotConfluencePlugin/Forms/ConfluenceSearch.xaml.cs
index 1b5c3877e..0702ddff7 100644
--- a/GreenshotConfluencePlugin/Forms/ConfluenceSearch.xaml.cs
+++ b/GreenshotConfluencePlugin/Forms/ConfluenceSearch.xaml.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
@@ -25,15 +25,15 @@ using System.Linq;
using System.Windows;
using GreenshotPlugin.IniFile;
-namespace GreenshotConfluencePlugin {
+namespace GreenshotConfluencePlugin.Forms {
public partial class ConfluenceSearch
{
private static readonly ConfluenceConfiguration ConfluenceConfig = IniConfig.GetIniSection();
private readonly ConfluenceUpload _confluenceUpload;
- public IEnumerable Spaces => _confluenceUpload.Spaces;
+ public IEnumerable Spaces => _confluenceUpload.Spaces;
- public ObservableCollection Pages { get; } = new ObservableCollection();
+ public ObservableCollection Pages { get; } = new ObservableCollection();
public ConfluenceSearch(ConfluenceUpload confluenceUpload) {
_confluenceUpload = confluenceUpload;
@@ -56,7 +56,7 @@ namespace GreenshotConfluencePlugin {
private void SelectionChanged() {
if (PageListView.HasItems && PageListView.SelectedItems.Count > 0) {
- _confluenceUpload.SelectedPage = (Confluence.Page)PageListView.SelectedItem;
+ _confluenceUpload.SelectedPage = (Page)PageListView.SelectedItem;
} else {
_confluenceUpload.SelectedPage = null;
}
@@ -86,7 +86,7 @@ namespace GreenshotConfluencePlugin {
SelectionChanged();
}
- private void searchText_TextChanged(object sender, System.Windows.Controls.TextChangedEventArgs e) {
+ private void SearchText_TextChanged(object sender, System.Windows.Controls.TextChangedEventArgs e) {
Search.IsEnabled = !string.IsNullOrEmpty(searchText.Text);
}
}
diff --git a/GreenshotConfluencePlugin/Forms/ConfluenceTreePicker.xaml b/GreenshotConfluencePlugin/Forms/ConfluenceTreePicker.xaml
index 97352d47e..4ca2a11ad 100644
--- a/GreenshotConfluencePlugin/Forms/ConfluenceTreePicker.xaml
+++ b/GreenshotConfluencePlugin/Forms/ConfluenceTreePicker.xaml
@@ -1,8 +1,8 @@
-
+ FontSize="18" FontWeight="Bold" Foreground="#7EFFFFFF" Text="{support:Translate loading}"/>
\ No newline at end of file
diff --git a/GreenshotConfluencePlugin/Forms/ConfluenceTreePicker.xaml.cs b/GreenshotConfluencePlugin/Forms/ConfluenceTreePicker.xaml.cs
index 78fb2235d..1897a8f53 100644
--- a/GreenshotConfluencePlugin/Forms/ConfluenceTreePicker.xaml.cs
+++ b/GreenshotConfluencePlugin/Forms/ConfluenceTreePicker.xaml.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
@@ -27,10 +27,7 @@ using System.Windows.Controls;
using System.Windows.Input;
using System.Windows.Threading;
-using Confluence;
-using Page = Confluence.Page;
-
-namespace GreenshotConfluencePlugin {
+namespace GreenshotConfluencePlugin.Forms {
///
/// Interaction logic for ConfluenceTreePicker.xaml
///
@@ -47,10 +44,10 @@ namespace GreenshotConfluencePlugin {
InitializeComponent();
}
- private void pageTreeViewItem_DoubleClick(object sender, MouseButtonEventArgs eventArgs) {
+ private void PageTreeViewItem_DoubleClick(object sender, MouseButtonEventArgs eventArgs) {
Log.Debug("spaceTreeViewItem_MouseLeftButtonDown is called!");
TreeViewItem clickedItem = eventArgs.Source as TreeViewItem;
- if (!(clickedItem?.Tag is Page page)) {
+ if (clickedItem?.Tag is not Page page) {
return;
}
if (clickedItem.HasItems)
@@ -70,20 +67,20 @@ namespace GreenshotConfluencePlugin {
Tag = childPage
};
clickedItem.Items.Add(pageTreeViewItem);
- pageTreeViewItem.PreviewMouseDoubleClick += pageTreeViewItem_DoubleClick;
- pageTreeViewItem.PreviewMouseLeftButtonDown += pageTreeViewItem_Click;
+ pageTreeViewItem.PreviewMouseDoubleClick += PageTreeViewItem_DoubleClick;
+ pageTreeViewItem.PreviewMouseLeftButtonDown += PageTreeViewItem_Click;
}
ShowBusy.Visibility = Visibility.Collapsed;
}));
}) { Name = "Loading childpages for confluence page " + page.Title }.Start();
}
- private void pageTreeViewItem_Click(object sender, MouseButtonEventArgs eventArgs) {
+ private void PageTreeViewItem_Click(object sender, MouseButtonEventArgs eventArgs) {
Log.Debug("pageTreeViewItem_PreviewMouseDoubleClick is called!");
- if (!(eventArgs.Source is TreeViewItem clickedItem)) {
+ if (eventArgs.Source is not TreeViewItem clickedItem) {
return;
}
- Confluence.Page page = clickedItem.Tag as Confluence.Page;
+ Page page = clickedItem.Tag as Page;
_confluenceUpload.SelectedPage = page;
if (page != null) {
Log.Debug("Page selected: " + page.Title);
@@ -107,14 +104,14 @@ namespace GreenshotConfluencePlugin {
// Get homepage
try {
- Confluence.Page page = _confluenceConnector.GetSpaceHomepage(space);
+ Page page = _confluenceConnector.GetSpaceHomepage(space);
TreeViewItem pageTreeViewItem = new TreeViewItem
{
Header = page.Title,
Tag = page
};
- pageTreeViewItem.PreviewMouseDoubleClick += pageTreeViewItem_DoubleClick;
- pageTreeViewItem.PreviewMouseLeftButtonDown += pageTreeViewItem_Click;
+ pageTreeViewItem.PreviewMouseDoubleClick += PageTreeViewItem_DoubleClick;
+ pageTreeViewItem.PreviewMouseLeftButtonDown += PageTreeViewItem_Click;
spaceTreeViewItem.Items.Add(pageTreeViewItem);
ConfluenceTreeView.Items.Add(spaceTreeViewItem);
} catch (Exception ex) {
diff --git a/GreenshotConfluencePlugin/Forms/ConfluenceUpload.xaml b/GreenshotConfluencePlugin/Forms/ConfluenceUpload.xaml
index aa97142a6..f6ec6f13a 100644
--- a/GreenshotConfluencePlugin/Forms/ConfluenceUpload.xaml
+++ b/GreenshotConfluencePlugin/Forms/ConfluenceUpload.xaml
@@ -1,17 +1,17 @@
-
+ xmlns:support="clr-namespace:GreenshotConfluencePlugin.Support"
+ Title="{support:Translate upload_menu_item}" Height="640" Width="500" Icon="/GreenshotConfluencePlugin;component/Images/Confluence.ico">
-
+
-
+
-
+
@@ -23,12 +23,12 @@
-
+
-
-
+
+
\ No newline at end of file
diff --git a/GreenshotConfluencePlugin/Forms/ConfluenceUpload.xaml.cs b/GreenshotConfluencePlugin/Forms/ConfluenceUpload.xaml.cs
index 76c82b2df..291581a2b 100644
--- a/GreenshotConfluencePlugin/Forms/ConfluenceUpload.xaml.cs
+++ b/GreenshotConfluencePlugin/Forms/ConfluenceUpload.xaml.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
@@ -18,23 +18,23 @@
* You should have received a copy of the GNU General Public License
* along with this program. If not, see .
*/
+
using System;
using System.Collections.Generic;
using System.Linq;
using System.Threading;
using System.Windows;
-using System.Windows.Controls;
-namespace GreenshotConfluencePlugin {
+namespace GreenshotConfluencePlugin.Forms {
///
/// Interaction logic for ConfluenceUpload.xaml
///
public partial class ConfluenceUpload : Window {
- private Page _pickerPage;
- public Page PickerPage {
+ private System.Windows.Controls.Page _pickerPage;
+ public System.Windows.Controls.Page PickerPage {
get {
if (_pickerPage == null) {
- List pages = ConfluenceUtils.GetCurrentPages();
+ List pages = ConfluenceUtils.GetCurrentPages();
if (pages != null && pages.Count > 0) {
_pickerPage = new ConfluencePagePicker(this, pages);
}
@@ -43,21 +43,19 @@ namespace GreenshotConfluencePlugin {
}
}
- private Page _searchPage;
- public Page SearchPage {
+ private System.Windows.Controls.Page _searchPage;
+ public System.Windows.Controls.Page SearchPage {
get { return _searchPage ??= new ConfluenceSearch(this); }
}
- private Page _browsePage;
- public Page BrowsePage {
+ private System.Windows.Controls.Page _browsePage;
+ public System.Windows.Controls.Page BrowsePage {
get { return _browsePage ??= new ConfluenceTreePicker(this); }
}
- private Confluence.Page _selectedPage;
- public Confluence.Page SelectedPage {
- get {
- return _selectedPage;
- }
+ private Page _selectedPage;
+ public Page SelectedPage {
+ get => _selectedPage;
set {
_selectedPage = value;
Upload.IsEnabled = _selectedPage != null;
@@ -75,8 +73,8 @@ namespace GreenshotConfluencePlugin {
}
private static DateTime _lastLoad = DateTime.Now;
- private static IList _spaces;
- public IList Spaces {
+ private static IList _spaces;
+ public IList Spaces {
get {
UpdateSpaces();
while (_spaces == null) {
diff --git a/GreenshotConfluencePlugin/Forms/ListViewColumnSorter.cs b/GreenshotConfluencePlugin/Forms/ListViewColumnSorter.cs
index fa3d4e027..d4cbe59d4 100644
--- a/GreenshotConfluencePlugin/Forms/ListViewColumnSorter.cs
+++ b/GreenshotConfluencePlugin/Forms/ListViewColumnSorter.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
@@ -18,92 +18,96 @@
* You should have received a copy of the GNU General Public License
* along with this program. If not, see .
*/
+
using System.Collections;
using System.Windows.Forms;
-///
-/// This class is an implementation of the 'IComparer' interface.
-///
-public class ListViewColumnSorter : IComparer {
+namespace GreenshotConfluencePlugin.Forms
+{
///
- /// Specifies the column to be sorted
+ /// This class is an implementation of the 'IComparer' interface.
///
- private int _columnToSort;
- ///
- /// Specifies the order in which to sort (i.e. 'Ascending').
- ///
- private SortOrder _orderOfSort;
- ///
- /// Case insensitive comparer object
- ///
- private readonly CaseInsensitiveComparer _objectCompare;
+ public class ListViewColumnSorter : IComparer {
+ ///
+ /// Specifies the column to be sorted
+ ///
+ private int _columnToSort;
+ ///
+ /// Specifies the order in which to sort (i.e. 'Ascending').
+ ///
+ private SortOrder _orderOfSort;
+ ///
+ /// Case insensitive comparer object
+ ///
+ private readonly CaseInsensitiveComparer _objectCompare;
- ///
- /// Class constructor. Initializes various elements
- ///
- public ListViewColumnSorter() {
- // Initialize the column to '0'
- _columnToSort = 0;
+ ///
+ /// Class constructor. Initializes various elements
+ ///
+ public ListViewColumnSorter() {
+ // Initialize the column to '0'
+ _columnToSort = 0;
- // Initialize the sort order to 'none'
- _orderOfSort = SortOrder.None;
+ // Initialize the sort order to 'none'
+ _orderOfSort = SortOrder.None;
+
+ // Initialize the CaseInsensitiveComparer object
+ _objectCompare = new CaseInsensitiveComparer();
+ }
+
+ ///
+ /// This method is inherited from the IComparer interface. It compares the two objects passed using a case insensitive comparison.
+ ///
+ /// First object to be compared
+ /// Second object to be compared
+ /// The result of the comparison. "0" if equal, negative if 'x' is less than 'y' and positive if 'x' is greater than 'y'
+ public int Compare(object x, object y) {
+ int compareResult;
+ ListViewItem listviewX, listviewY;
+
+ // Cast the objects to be compared to ListViewItem objects
+ listviewX = (ListViewItem)x;
+ listviewY = (ListViewItem)y;
+
+ // Compare the two items
+ compareResult = _objectCompare.Compare(listviewX.SubItems[_columnToSort].Text, listviewY.SubItems[_columnToSort].Text);
+
+ // Calculate correct return value based on object comparison
+ if (_orderOfSort == SortOrder.Ascending) {
+ // Ascending sort is selected, return normal result of compare operation
+ return compareResult;
+ } else if (_orderOfSort == SortOrder.Descending) {
+ // Descending sort is selected, return negative result of compare operation
+ return (-compareResult);
+ } else {
+ // Return '0' to indicate they are equal
+ return 0;
+ }
+ }
+
+ ///
+ /// Gets or sets the number of the column to which to apply the sorting operation (Defaults to '0').
+ ///
+ public int SortColumn {
+ set {
+ _columnToSort = value;
+ }
+ get {
+ return _columnToSort;
+ }
+ }
+
+ ///
+ /// Gets or sets the order of sorting to apply (for example, 'Ascending' or 'Descending').
+ ///
+ public SortOrder Order {
+ set {
+ _orderOfSort = value;
+ }
+ get {
+ return _orderOfSort;
+ }
+ }
- // Initialize the CaseInsensitiveComparer object
- _objectCompare = new CaseInsensitiveComparer();
}
-
- ///
- /// This method is inherited from the IComparer interface. It compares the two objects passed using a case insensitive comparison.
- ///
- /// First object to be compared
- /// Second object to be compared
- /// The result of the comparison. "0" if equal, negative if 'x' is less than 'y' and positive if 'x' is greater than 'y'
- public int Compare(object x, object y) {
- int compareResult;
- ListViewItem listviewX, listviewY;
-
- // Cast the objects to be compared to ListViewItem objects
- listviewX = (ListViewItem)x;
- listviewY = (ListViewItem)y;
-
- // Compare the two items
- compareResult = _objectCompare.Compare(listviewX.SubItems[_columnToSort].Text, listviewY.SubItems[_columnToSort].Text);
-
- // Calculate correct return value based on object comparison
- if (_orderOfSort == SortOrder.Ascending) {
- // Ascending sort is selected, return normal result of compare operation
- return compareResult;
- } else if (_orderOfSort == SortOrder.Descending) {
- // Descending sort is selected, return negative result of compare operation
- return (-compareResult);
- } else {
- // Return '0' to indicate they are equal
- return 0;
- }
- }
-
- ///
- /// Gets or sets the number of the column to which to apply the sorting operation (Defaults to '0').
- ///
- public int SortColumn {
- set {
- _columnToSort = value;
- }
- get {
- return _columnToSort;
- }
- }
-
- ///
- /// Gets or sets the order of sorting to apply (for example, 'Ascending' or 'Descending').
- ///
- public SortOrder Order {
- set {
- _orderOfSort = value;
- }
- get {
- return _orderOfSort;
- }
- }
-
}
diff --git a/GreenshotConfluencePlugin/LanguageKeys.cs b/GreenshotConfluencePlugin/LanguageKeys.cs
index 0caa382cb..9cd71ea8e 100644
--- a/GreenshotConfluencePlugin/LanguageKeys.cs
+++ b/GreenshotConfluencePlugin/LanguageKeys.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotConfluencePlugin/Support/ITranslationProvider.cs b/GreenshotConfluencePlugin/Support/ITranslationProvider.cs
index 79efd538c..02180f036 100644
--- a/GreenshotConfluencePlugin/Support/ITranslationProvider.cs
+++ b/GreenshotConfluencePlugin/Support/ITranslationProvider.cs
@@ -1,4 +1,4 @@
-namespace TranslationByMarkupExtension {
+namespace GreenshotConfluencePlugin.Support {
public interface ITranslationProvider {
///
/// Translates the specified key.
diff --git a/GreenshotConfluencePlugin/Support/LanguageChangedEventManager.cs b/GreenshotConfluencePlugin/Support/LanguageChangedEventManager.cs
index 8fe9289d3..c9fb55704 100644
--- a/GreenshotConfluencePlugin/Support/LanguageChangedEventManager.cs
+++ b/GreenshotConfluencePlugin/Support/LanguageChangedEventManager.cs
@@ -1,7 +1,7 @@
using System;
using System.Windows;
-namespace TranslationByMarkupExtension
+namespace GreenshotConfluencePlugin.Support
{
public class LanguageChangedEventManager : WeakEventManager
{
diff --git a/GreenshotConfluencePlugin/Support/LanguageXMLTranslationProvider.cs b/GreenshotConfluencePlugin/Support/LanguageXMLTranslationProvider.cs
index 3b23c0d58..23dbc4fc1 100644
--- a/GreenshotConfluencePlugin/Support/LanguageXMLTranslationProvider.cs
+++ b/GreenshotConfluencePlugin/Support/LanguageXMLTranslationProvider.cs
@@ -1,6 +1,6 @@
using GreenshotPlugin.Core;
-namespace TranslationByMarkupExtension {
+namespace GreenshotConfluencePlugin.Support {
///
///
///
diff --git a/GreenshotConfluencePlugin/Support/TranslateExtension.cs b/GreenshotConfluencePlugin/Support/TranslateExtension.cs
index c581efc77..3730e7baa 100644
--- a/GreenshotConfluencePlugin/Support/TranslateExtension.cs
+++ b/GreenshotConfluencePlugin/Support/TranslateExtension.cs
@@ -2,7 +2,7 @@
using System.Windows.Data;
using System.Windows.Markup;
-namespace TranslationByMarkupExtension
+namespace GreenshotConfluencePlugin.Support
{
///
/// The Translate Markup extension returns a binding to a TranslationData
diff --git a/GreenshotConfluencePlugin/Support/TranslationData.cs b/GreenshotConfluencePlugin/Support/TranslationData.cs
index e659a0be3..0b6371505 100644
--- a/GreenshotConfluencePlugin/Support/TranslationData.cs
+++ b/GreenshotConfluencePlugin/Support/TranslationData.cs
@@ -2,7 +2,7 @@
using System.ComponentModel;
using System.Windows;
-namespace TranslationByMarkupExtension {
+namespace GreenshotConfluencePlugin.Support {
public class TranslationData : IWeakEventListener, INotifyPropertyChanged {
private readonly string _key;
diff --git a/GreenshotConfluencePlugin/Support/TranslationManager.cs b/GreenshotConfluencePlugin/Support/TranslationManager.cs
index d11d36cd5..241cce868 100644
--- a/GreenshotConfluencePlugin/Support/TranslationManager.cs
+++ b/GreenshotConfluencePlugin/Support/TranslationManager.cs
@@ -1,6 +1,6 @@
using System;
-namespace TranslationByMarkupExtension {
+namespace GreenshotConfluencePlugin.Support {
public class TranslationManager {
private static TranslationManager _translationManager;
diff --git a/GreenshotDropboxPlugin/DropboxDestination.cs b/GreenshotDropboxPlugin/DropboxDestination.cs
index 8b14de6cf..9762652c4 100644
--- a/GreenshotDropboxPlugin/DropboxDestination.cs
+++ b/GreenshotDropboxPlugin/DropboxDestination.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom, Francis Noel
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom, Francis Noel
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
@@ -8,7 +8,7 @@
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 1 of the License, or
- * (at your option) any later version.
+ * (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
@@ -44,9 +44,9 @@ namespace GreenshotDropboxPlugin {
}
}
- public override ExportInformation ExportCapture(bool manually, ISurface surface, ICaptureDetails captureDetails) {
+ public override ExportInformation ExportCapture(bool manually, ISurface surface, ICaptureDetails captureDetails) {
ExportInformation exportInformation = new ExportInformation(Designation, Description);
- bool uploaded = _plugin.Upload(captureDetails, surface, out var uploadUrl);
+ bool uploaded = _plugin.Upload(captureDetails, surface, out var uploadUrl);
if (uploaded) {
exportInformation.Uri = uploadUrl;
exportInformation.ExportMade = true;
diff --git a/GreenshotDropboxPlugin/DropboxPlugin.cs b/GreenshotDropboxPlugin/DropboxPlugin.cs
index bf8842ecb..476dfda54 100644
--- a/GreenshotDropboxPlugin/DropboxPlugin.cs
+++ b/GreenshotDropboxPlugin/DropboxPlugin.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom, Francis Noel
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom, Francis Noel
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotDropboxPlugin/DropboxPluginConfiguration.cs b/GreenshotDropboxPlugin/DropboxPluginConfiguration.cs
index c57d31073..b13622db2 100644
--- a/GreenshotDropboxPlugin/DropboxPluginConfiguration.cs
+++ b/GreenshotDropboxPlugin/DropboxPluginConfiguration.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom, Francis Noel
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom, Francis Noel
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
@@ -21,6 +21,7 @@
using System;
using System.Windows.Forms;
+using GreenshotDropboxPlugin.Forms;
using GreenshotPlugin.Core;
using GreenshotPlugin.IniFile;
@@ -43,7 +44,7 @@ namespace GreenshotDropboxPlugin {
[IniProperty("RefreshToken", Description = "Dropbox refresh Token", Encrypted = true, ExcludeIfNull = true)]
public string RefreshToken { get; set; }
- ///
+ ///
/// AccessToken, not stored
///
public string AccessToken { get; set; }
diff --git a/GreenshotDropboxPlugin/DropboxUtils.cs b/GreenshotDropboxPlugin/DropboxUtils.cs
index eeb2b6405..8bf1d57b5 100644
--- a/GreenshotDropboxPlugin/DropboxUtils.cs
+++ b/GreenshotDropboxPlugin/DropboxUtils.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom, Francis Noel
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom, Francis Noel
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
@@ -40,7 +40,7 @@ namespace GreenshotDropboxPlugin {
}
public static bool UploadToDropbox(ISurface surfaceToUpload, SurfaceOutputSettings outputSettings, ICaptureDetails captureDetails)
- {
+ {
var oauth2Settings = new OAuth2Settings
{
AuthUrlPattern = "https://api.dropbox.com/oauth2/authorize?response_type=token&client_id={ClientId}&state={State}&redirect_uri={RedirectUrl}",
@@ -54,7 +54,6 @@ namespace GreenshotDropboxPlugin {
AccessToken = DropboxConfig.AccessToken,
AccessTokenExpires = DropboxConfig.AccessTokenExpires
};
-
try
{
string filename = Path.GetFileName(FilenameHelper.GetFilename(DropboxConfig.UploadFormat, captureDetails));
@@ -87,7 +86,7 @@ namespace GreenshotDropboxPlugin {
DropboxConfig.AccessTokenExpires = oauth2Settings.AccessTokenExpires;
DropboxConfig.IsDirty = true;
IniConfig.Save();
- }
- }
+ }
+ }
}
}
diff --git a/GreenshotDropboxPlugin/Forms/DropboxForm.cs b/GreenshotDropboxPlugin/Forms/DropboxForm.cs
index 97c4b9d92..e0a96b5bf 100644
--- a/GreenshotDropboxPlugin/Forms/DropboxForm.cs
+++ b/GreenshotDropboxPlugin/Forms/DropboxForm.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom, Francis Noel
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom, Francis Noel
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotDropboxPlugin/Forms/SettingsForm.Designer.cs b/GreenshotDropboxPlugin/Forms/SettingsForm.Designer.cs
index 80c0009b1..1baae2160 100644
--- a/GreenshotDropboxPlugin/Forms/SettingsForm.Designer.cs
+++ b/GreenshotDropboxPlugin/Forms/SettingsForm.Designer.cs
@@ -18,7 +18,7 @@
* You should have received a copy of the GNU General Public License
* along with this program. If not, see .
*/
-namespace GreenshotDropboxPlugin {
+namespace GreenshotDropboxPlugin.Forms {
partial class SettingsForm {
///
/// Designer variable used to keep track of non-visual components.
diff --git a/GreenshotDropboxPlugin/Forms/SettingsForm.cs b/GreenshotDropboxPlugin/Forms/SettingsForm.cs
index 5be2a25b2..98e1147ce 100644
--- a/GreenshotDropboxPlugin/Forms/SettingsForm.cs
+++ b/GreenshotDropboxPlugin/Forms/SettingsForm.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom, Francis Noel
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom, Francis Noel
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
@@ -19,9 +19,7 @@
* along with this program. If not, see .
*/
-using GreenshotDropboxPlugin.Forms;
-
-namespace GreenshotDropboxPlugin {
+namespace GreenshotDropboxPlugin.Forms {
///
/// Description of PasswordRequestForm.
///
diff --git a/GreenshotDropboxPlugin/GreenshotDropboxPlugin.Credentials.template b/GreenshotDropboxPlugin/GreenshotDropboxPlugin.Credentials.template
index 3baf9fb94..6a13eb6d7 100644
--- a/GreenshotDropboxPlugin/GreenshotDropboxPlugin.Credentials.template
+++ b/GreenshotDropboxPlugin/GreenshotDropboxPlugin.Credentials.template
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotDropboxPlugin/LanguageKeys.cs b/GreenshotDropboxPlugin/LanguageKeys.cs
index 16cd587fb..d50660add 100644
--- a/GreenshotDropboxPlugin/LanguageKeys.cs
+++ b/GreenshotDropboxPlugin/LanguageKeys.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom, Francis Noel
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom, Francis Noel
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotDropboxPlugin/Properties/AssemblyInfo.cs b/GreenshotDropboxPlugin/Properties/AssemblyInfo.cs
index 10b737886..9e9b18e04 100644
--- a/GreenshotDropboxPlugin/Properties/AssemblyInfo.cs
+++ b/GreenshotDropboxPlugin/Properties/AssemblyInfo.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom, Francis Noel
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom, Francis Noel
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotExternalCommandPlugin/ExternalCommandConfiguration.cs b/GreenshotExternalCommandPlugin/ExternalCommandConfiguration.cs
index aa5e76d98..f8981b820 100644
--- a/GreenshotExternalCommandPlugin/ExternalCommandConfiguration.cs
+++ b/GreenshotExternalCommandPlugin/ExternalCommandConfiguration.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotExternalCommandPlugin/ExternalCommandDestination.cs b/GreenshotExternalCommandPlugin/ExternalCommandDestination.cs
index 74676182c..81575c947 100644
--- a/GreenshotExternalCommandPlugin/ExternalCommandDestination.cs
+++ b/GreenshotExternalCommandPlugin/ExternalCommandDestination.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotExternalCommandPlugin/ExternalCommandForm.cs b/GreenshotExternalCommandPlugin/ExternalCommandForm.cs
index dd42fbbe2..6436fc988 100644
--- a/GreenshotExternalCommandPlugin/ExternalCommandForm.cs
+++ b/GreenshotExternalCommandPlugin/ExternalCommandForm.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotExternalCommandPlugin/ExternalCommandPlugin.cs b/GreenshotExternalCommandPlugin/ExternalCommandPlugin.cs
index 67a278a3a..13d1868d1 100644
--- a/GreenshotExternalCommandPlugin/ExternalCommandPlugin.cs
+++ b/GreenshotExternalCommandPlugin/ExternalCommandPlugin.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotExternalCommandPlugin/IconCache.cs b/GreenshotExternalCommandPlugin/IconCache.cs
index f510c0823..bf9094c7e 100644
--- a/GreenshotExternalCommandPlugin/IconCache.cs
+++ b/GreenshotExternalCommandPlugin/IconCache.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on Sourceforge: http://sourceforge.net/projects/greenshot/
diff --git a/GreenshotExternalCommandPlugin/SettingsForm.Designer.cs b/GreenshotExternalCommandPlugin/SettingsForm.Designer.cs
index 0a7ed7d7f..f0a000f9b 100644
--- a/GreenshotExternalCommandPlugin/SettingsForm.Designer.cs
+++ b/GreenshotExternalCommandPlugin/SettingsForm.Designer.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotExternalCommandPlugin/SettingsForm.cs b/GreenshotExternalCommandPlugin/SettingsForm.cs
index 7aecfb04e..01eea89bf 100644
--- a/GreenshotExternalCommandPlugin/SettingsForm.cs
+++ b/GreenshotExternalCommandPlugin/SettingsForm.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotExternalCommandPlugin/SettingsFormDetail.Designer.cs b/GreenshotExternalCommandPlugin/SettingsFormDetail.Designer.cs
index 028efa2cd..dd928449d 100644
--- a/GreenshotExternalCommandPlugin/SettingsFormDetail.Designer.cs
+++ b/GreenshotExternalCommandPlugin/SettingsFormDetail.Designer.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotExternalCommandPlugin/SettingsFormDetail.cs b/GreenshotExternalCommandPlugin/SettingsFormDetail.cs
index db154be58..8affd6976 100644
--- a/GreenshotExternalCommandPlugin/SettingsFormDetail.cs
+++ b/GreenshotExternalCommandPlugin/SettingsFormDetail.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotFlickrPlugin/FlickrConfiguration.cs b/GreenshotFlickrPlugin/FlickrConfiguration.cs
index 56b74432e..06f65c9fd 100644
--- a/GreenshotFlickrPlugin/FlickrConfiguration.cs
+++ b/GreenshotFlickrPlugin/FlickrConfiguration.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom, Francis Noel
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom, Francis Noel
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
@@ -19,6 +19,7 @@
* along with this program. If not, see .
*/
using System.Windows.Forms;
+using GreenshotFlickrPlugin.Forms;
using GreenshotPlugin.Core;
using GreenshotPlugin.IniFile;
diff --git a/GreenshotFlickrPlugin/FlickrDestination.cs b/GreenshotFlickrPlugin/FlickrDestination.cs
index 6cc874d29..ccd9392d2 100644
--- a/GreenshotFlickrPlugin/FlickrDestination.cs
+++ b/GreenshotFlickrPlugin/FlickrDestination.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom, Francis Noel
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom, Francis Noel
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotFlickrPlugin/FlickrPlugin.cs b/GreenshotFlickrPlugin/FlickrPlugin.cs
index 524c6ad68..abf663625 100644
--- a/GreenshotFlickrPlugin/FlickrPlugin.cs
+++ b/GreenshotFlickrPlugin/FlickrPlugin.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom, Francis Noel
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom, Francis Noel
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotFlickrPlugin/FlickrUtils.cs b/GreenshotFlickrPlugin/FlickrUtils.cs
index c5d5ade1e..9337c51f6 100644
--- a/GreenshotFlickrPlugin/FlickrUtils.cs
+++ b/GreenshotFlickrPlugin/FlickrUtils.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom, Francis Noel
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom, Francis Noel
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotFlickrPlugin/Forms/FlickrForm.cs b/GreenshotFlickrPlugin/Forms/FlickrForm.cs
index 897f20eef..94e161d64 100644
--- a/GreenshotFlickrPlugin/Forms/FlickrForm.cs
+++ b/GreenshotFlickrPlugin/Forms/FlickrForm.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom, Francis Noel
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom, Francis Noel
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotFlickrPlugin/Forms/SettingsForm.Designer.cs b/GreenshotFlickrPlugin/Forms/SettingsForm.Designer.cs
index 498e37d18..18001eab2 100644
--- a/GreenshotFlickrPlugin/Forms/SettingsForm.Designer.cs
+++ b/GreenshotFlickrPlugin/Forms/SettingsForm.Designer.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom, Francis Noel
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom, Francis Noel
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
@@ -18,7 +18,7 @@
* You should have received a copy of the GNU General Public License
* along with this program. If not, see .
*/
-namespace GreenshotFlickrPlugin {
+namespace GreenshotFlickrPlugin.Forms {
partial class SettingsForm {
///
/// Designer variable used to keep track of non-visual components.
diff --git a/GreenshotFlickrPlugin/Forms/SettingsForm.cs b/GreenshotFlickrPlugin/Forms/SettingsForm.cs
index eed62ee7d..59d0e3cbf 100644
--- a/GreenshotFlickrPlugin/Forms/SettingsForm.cs
+++ b/GreenshotFlickrPlugin/Forms/SettingsForm.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom, Francis Noel
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom, Francis Noel
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
@@ -19,9 +19,7 @@
* along with this program. If not, see .
*/
-using GreenshotFlickrPlugin.Forms;
-
-namespace GreenshotFlickrPlugin {
+namespace GreenshotFlickrPlugin.Forms {
///
/// Description of PasswordRequestForm.
///
diff --git a/GreenshotFlickrPlugin/GreenshotFlickrPlugin.Credentials.template b/GreenshotFlickrPlugin/GreenshotFlickrPlugin.Credentials.template
index 865c9e3e5..fb69e4460 100644
--- a/GreenshotFlickrPlugin/GreenshotFlickrPlugin.Credentials.template
+++ b/GreenshotFlickrPlugin/GreenshotFlickrPlugin.Credentials.template
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotFlickrPlugin/LanguageKeys.cs b/GreenshotFlickrPlugin/LanguageKeys.cs
index aa08ff867..44320512b 100644
--- a/GreenshotFlickrPlugin/LanguageKeys.cs
+++ b/GreenshotFlickrPlugin/LanguageKeys.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom, Francis Noel
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom, Francis Noel
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotFlickrPlugin/Properties/AssemblyInfo.cs b/GreenshotFlickrPlugin/Properties/AssemblyInfo.cs
index 6b06e2aa5..7cc8b4a3a 100644
--- a/GreenshotFlickrPlugin/Properties/AssemblyInfo.cs
+++ b/GreenshotFlickrPlugin/Properties/AssemblyInfo.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom, Francis Noel
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom, Francis Noel
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotImgurPlugin/Forms/ImgurForm.cs b/GreenshotImgurPlugin/Forms/ImgurForm.cs
index c379e49fe..37316ac99 100644
--- a/GreenshotImgurPlugin/Forms/ImgurForm.cs
+++ b/GreenshotImgurPlugin/Forms/ImgurForm.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
@@ -21,7 +21,7 @@
using GreenshotPlugin.Controls;
-namespace GreenshotImgurPlugin {
+namespace GreenshotImgurPlugin.Forms {
///
/// This class is needed for design-time resolving of the language files
///
diff --git a/GreenshotImgurPlugin/Forms/ImgurHistory.Designer.cs b/GreenshotImgurPlugin/Forms/ImgurHistory.Designer.cs
index 5b38b0e65..f8fb05dd2 100644
--- a/GreenshotImgurPlugin/Forms/ImgurHistory.Designer.cs
+++ b/GreenshotImgurPlugin/Forms/ImgurHistory.Designer.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
@@ -18,7 +18,7 @@
* You should have received a copy of the GNU General Public License
* along with this program. If not, see .
*/
-namespace GreenshotImgurPlugin
+namespace GreenshotImgurPlugin.Forms
{
partial class ImgurHistory
{
diff --git a/GreenshotImgurPlugin/Forms/ImgurHistory.cs b/GreenshotImgurPlugin/Forms/ImgurHistory.cs
index cc5dc4cf1..359130a90 100644
--- a/GreenshotImgurPlugin/Forms/ImgurHistory.cs
+++ b/GreenshotImgurPlugin/Forms/ImgurHistory.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
@@ -18,16 +18,16 @@
* You should have received a copy of the GNU General Public License
* along with this program. If not, see .
*/
+
using System;
using System.Globalization;
using System.Text;
using System.Windows.Forms;
-
using GreenshotPlugin.Controls;
using GreenshotPlugin.Core;
using GreenshotPlugin.IniFile;
-namespace GreenshotImgurPlugin {
+namespace GreenshotImgurPlugin.Forms {
///
/// Imgur history form
///
diff --git a/GreenshotImgurPlugin/Forms/SettingsForm.Designer.cs b/GreenshotImgurPlugin/Forms/SettingsForm.Designer.cs
index 788597c39..79192da09 100644
--- a/GreenshotImgurPlugin/Forms/SettingsForm.Designer.cs
+++ b/GreenshotImgurPlugin/Forms/SettingsForm.Designer.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
@@ -18,7 +18,7 @@
* You should have received a copy of the GNU General Public License
* along with this program. If not, see .
*/
-namespace GreenshotImgurPlugin {
+namespace GreenshotImgurPlugin.Forms {
partial class SettingsForm {
///
/// Designer variable used to keep track of non-visual components.
diff --git a/GreenshotImgurPlugin/Forms/SettingsForm.cs b/GreenshotImgurPlugin/Forms/SettingsForm.cs
index db7809a98..2ce863660 100644
--- a/GreenshotImgurPlugin/Forms/SettingsForm.cs
+++ b/GreenshotImgurPlugin/Forms/SettingsForm.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
@@ -18,9 +18,10 @@
* You should have received a copy of the GNU General Public License
* along with this program. If not, see .
*/
+
using System;
-namespace GreenshotImgurPlugin {
+namespace GreenshotImgurPlugin.Forms {
///
/// Description of PasswordRequestForm.
///
diff --git a/GreenshotImgurPlugin/GreenshotImgurPlugin.Credentials.template b/GreenshotImgurPlugin/GreenshotImgurPlugin.Credentials.template
index ea6d7c5ca..42dd7986f 100644
--- a/GreenshotImgurPlugin/GreenshotImgurPlugin.Credentials.template
+++ b/GreenshotImgurPlugin/GreenshotImgurPlugin.Credentials.template
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotImgurPlugin/ImgurConfiguration.cs b/GreenshotImgurPlugin/ImgurConfiguration.cs
index 795814192..d487c2387 100644
--- a/GreenshotImgurPlugin/ImgurConfiguration.cs
+++ b/GreenshotImgurPlugin/ImgurConfiguration.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
@@ -22,6 +22,7 @@
using System;
using System.Collections.Generic;
using System.Windows.Forms;
+using GreenshotImgurPlugin.Forms;
using GreenshotPlugin.Core;
using GreenshotPlugin.IniFile;
diff --git a/GreenshotImgurPlugin/ImgurDestination.cs b/GreenshotImgurPlugin/ImgurDestination.cs
index c4d1ad445..5303ac295 100644
--- a/GreenshotImgurPlugin/ImgurDestination.cs
+++ b/GreenshotImgurPlugin/ImgurDestination.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotImgurPlugin/ImgurInfo.cs b/GreenshotImgurPlugin/ImgurInfo.cs
index 08c454904..85ec5b39e 100644
--- a/GreenshotImgurPlugin/ImgurInfo.cs
+++ b/GreenshotImgurPlugin/ImgurInfo.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotImgurPlugin/ImgurPlugin.cs b/GreenshotImgurPlugin/ImgurPlugin.cs
index 39cd8b9c0..d87c91f8e 100644
--- a/GreenshotImgurPlugin/ImgurPlugin.cs
+++ b/GreenshotImgurPlugin/ImgurPlugin.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
@@ -24,6 +24,7 @@ using System.ComponentModel;
using System.Drawing;
using System.IO;
using System.Windows.Forms;
+using GreenshotImgurPlugin.Forms;
using GreenshotPlugin.Controls;
using GreenshotPlugin.Core;
using GreenshotPlugin.IniFile;
diff --git a/GreenshotImgurPlugin/ImgurUtils.cs b/GreenshotImgurPlugin/ImgurUtils.cs
index 580b89c66..6c4b06674 100644
--- a/GreenshotImgurPlugin/ImgurUtils.cs
+++ b/GreenshotImgurPlugin/ImgurUtils.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotImgurPlugin/LanguageKeys.cs b/GreenshotImgurPlugin/LanguageKeys.cs
index c0aeb0295..25b3e311f 100644
--- a/GreenshotImgurPlugin/LanguageKeys.cs
+++ b/GreenshotImgurPlugin/LanguageKeys.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotImgurPlugin/Properties/AssemblyInfo.cs b/GreenshotImgurPlugin/Properties/AssemblyInfo.cs
index 19a2e1176..6818a420b 100644
--- a/GreenshotImgurPlugin/Properties/AssemblyInfo.cs
+++ b/GreenshotImgurPlugin/Properties/AssemblyInfo.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotJiraPlugin/AsyncMemoryCache.cs b/GreenshotJiraPlugin/AsyncMemoryCache.cs
index 0242573e3..de2a61d04 100644
--- a/GreenshotJiraPlugin/AsyncMemoryCache.cs
+++ b/GreenshotJiraPlugin/AsyncMemoryCache.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotJiraPlugin/Forms/JiraForm.Designer.cs b/GreenshotJiraPlugin/Forms/JiraForm.Designer.cs
index ac718241e..bcd10427a 100644
--- a/GreenshotJiraPlugin/Forms/JiraForm.Designer.cs
+++ b/GreenshotJiraPlugin/Forms/JiraForm.Designer.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotJiraPlugin/Forms/JiraForm.cs b/GreenshotJiraPlugin/Forms/JiraForm.cs
index 551fadadc..b9e4c3df8 100644
--- a/GreenshotJiraPlugin/Forms/JiraForm.cs
+++ b/GreenshotJiraPlugin/Forms/JiraForm.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotJiraPlugin/Forms/JiraFormBase.cs b/GreenshotJiraPlugin/Forms/JiraFormBase.cs
index 47266fda8..efc4d0201 100644
--- a/GreenshotJiraPlugin/Forms/JiraFormBase.cs
+++ b/GreenshotJiraPlugin/Forms/JiraFormBase.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotJiraPlugin/Forms/SettingsForm.Designer.cs b/GreenshotJiraPlugin/Forms/SettingsForm.Designer.cs
index e3f26b571..0b0195cf4 100644
--- a/GreenshotJiraPlugin/Forms/SettingsForm.Designer.cs
+++ b/GreenshotJiraPlugin/Forms/SettingsForm.Designer.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotJiraPlugin/Forms/SettingsForm.cs b/GreenshotJiraPlugin/Forms/SettingsForm.cs
index 5599da8ac..043df8f8b 100644
--- a/GreenshotJiraPlugin/Forms/SettingsForm.cs
+++ b/GreenshotJiraPlugin/Forms/SettingsForm.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotJiraPlugin/IssueTypeBitmapCache.cs b/GreenshotJiraPlugin/IssueTypeBitmapCache.cs
index 2edc0ed3e..c37cee314 100644
--- a/GreenshotJiraPlugin/IssueTypeBitmapCache.cs
+++ b/GreenshotJiraPlugin/IssueTypeBitmapCache.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotJiraPlugin/JiraConfiguration.cs b/GreenshotJiraPlugin/JiraConfiguration.cs
index 89c4fcf9b..ba8cad80c 100644
--- a/GreenshotJiraPlugin/JiraConfiguration.cs
+++ b/GreenshotJiraPlugin/JiraConfiguration.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotJiraPlugin/JiraConnector.cs b/GreenshotJiraPlugin/JiraConnector.cs
index b836ea560..6bf5739fe 100644
--- a/GreenshotJiraPlugin/JiraConnector.cs
+++ b/GreenshotJiraPlugin/JiraConnector.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
@@ -210,7 +210,7 @@ namespace GreenshotJiraPlugin {
await CheckCredentialsAsync(cancellationToken);
try
{
- return await _jiraClient.Issue.GetAsync(issueKey, cancellationToken).ConfigureAwait(false);
+ return await _jiraClient.Issue.GetAsync(issueKey, cancellationToken: cancellationToken).ConfigureAwait(false);
}
catch
{
diff --git a/GreenshotJiraPlugin/JiraDestination.cs b/GreenshotJiraPlugin/JiraDestination.cs
index 76d2314b3..080ec8619 100644
--- a/GreenshotJiraPlugin/JiraDestination.cs
+++ b/GreenshotJiraPlugin/JiraDestination.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotJiraPlugin/JiraDetails.cs b/GreenshotJiraPlugin/JiraDetails.cs
index 61f746f81..67bbc0f61 100644
--- a/GreenshotJiraPlugin/JiraDetails.cs
+++ b/GreenshotJiraPlugin/JiraDetails.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub: https://github.com/greenshot
diff --git a/GreenshotJiraPlugin/JiraEventArgs.cs b/GreenshotJiraPlugin/JiraEventArgs.cs
index b1c4887d6..eb60e5fcf 100644
--- a/GreenshotJiraPlugin/JiraEventArgs.cs
+++ b/GreenshotJiraPlugin/JiraEventArgs.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub: https://github.com/greenshot
diff --git a/GreenshotJiraPlugin/JiraEventTypes.cs b/GreenshotJiraPlugin/JiraEventTypes.cs
index 36866e863..37e62cab1 100644
--- a/GreenshotJiraPlugin/JiraEventTypes.cs
+++ b/GreenshotJiraPlugin/JiraEventTypes.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub: https://github.com/greenshot
diff --git a/GreenshotJiraPlugin/JiraMonitor.cs b/GreenshotJiraPlugin/JiraMonitor.cs
index 4fcb083a7..65b73924a 100644
--- a/GreenshotJiraPlugin/JiraMonitor.cs
+++ b/GreenshotJiraPlugin/JiraMonitor.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub: https://github.com/greenshot
diff --git a/GreenshotJiraPlugin/JiraPlugin.cs b/GreenshotJiraPlugin/JiraPlugin.cs
index 9448829c2..d58978328 100644
--- a/GreenshotJiraPlugin/JiraPlugin.cs
+++ b/GreenshotJiraPlugin/JiraPlugin.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotJiraPlugin/LanguageKeys.cs b/GreenshotJiraPlugin/LanguageKeys.cs
index 94f162dd6..d881be575 100644
--- a/GreenshotJiraPlugin/LanguageKeys.cs
+++ b/GreenshotJiraPlugin/LanguageKeys.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotJiraPlugin/Log4NetLogger.cs b/GreenshotJiraPlugin/Log4NetLogger.cs
index 186e7e75b..d7b8d601c 100644
--- a/GreenshotJiraPlugin/Log4NetLogger.cs
+++ b/GreenshotJiraPlugin/Log4NetLogger.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotOCRCommand/COMWrapper.cs b/GreenshotOCRCommand/COMWrapper.cs
index e64824f8d..fd26cfeb9 100644
--- a/GreenshotOCRCommand/COMWrapper.cs
+++ b/GreenshotOCRCommand/COMWrapper.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
@@ -18,6 +18,7 @@
* You should have received a copy of the GNU General Public License
* along with this program. If not, see .
*/
+
using System;
using System.Diagnostics;
using System.Reflection;
@@ -26,7 +27,7 @@ using System.Runtime.Remoting;
using System.Runtime.Remoting.Messaging;
using System.Runtime.Remoting.Proxies;
-namespace Greenshot.Interop {
+namespace GreenshotOCRCommand {
///
/// Wraps a late-bound COM server.
///
diff --git a/GreenshotOCRCommand/ComProgIdAttribute.cs b/GreenshotOCRCommand/ComProgIdAttribute.cs
index ae581d031..936ea34f9 100644
--- a/GreenshotOCRCommand/ComProgIdAttribute.cs
+++ b/GreenshotOCRCommand/ComProgIdAttribute.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
@@ -21,7 +21,7 @@
using System;
-namespace Greenshot.Interop {
+namespace GreenshotOCRCommand {
///
/// An attribute to specifiy the ProgID of the COM class to create. (As suggested by Kristen Wegner)
///
diff --git a/GreenshotOCRCommand/Modi/CompressionLevel.cs b/GreenshotOCRCommand/Modi/CompressionLevel.cs
index 87a3a2e7c..0cb9a4bc7 100644
--- a/GreenshotOCRCommand/Modi/CompressionLevel.cs
+++ b/GreenshotOCRCommand/Modi/CompressionLevel.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotOCRCommand/Modi/FileFormat.cs b/GreenshotOCRCommand/Modi/FileFormat.cs
index bd738cdaf..42c86a104 100644
--- a/GreenshotOCRCommand/Modi/FileFormat.cs
+++ b/GreenshotOCRCommand/Modi/FileFormat.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
@@ -19,7 +19,7 @@
* along with this program. If not, see .
*/
-namespace GreenshotOCR
+namespace GreenshotOCRCommand.Modi
{
public enum FileFormat {
miFILE_FORMAT_DEFAULTVALUE = -1,
diff --git a/GreenshotOCRCommand/Modi/ICommon.cs b/GreenshotOCRCommand/Modi/ICommon.cs
index a8995c826..433fcd121 100644
--- a/GreenshotOCRCommand/Modi/ICommon.cs
+++ b/GreenshotOCRCommand/Modi/ICommon.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotOCRCommand/Modi/IDispatch.cs b/GreenshotOCRCommand/Modi/IDispatch.cs
index f2d5e9ed0..623feef72 100644
--- a/GreenshotOCRCommand/Modi/IDispatch.cs
+++ b/GreenshotOCRCommand/Modi/IDispatch.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotOCRCommand/Modi/IDocument.cs b/GreenshotOCRCommand/Modi/IDocument.cs
index 6b1d44e99..cd9098f61 100644
--- a/GreenshotOCRCommand/Modi/IDocument.cs
+++ b/GreenshotOCRCommand/Modi/IDocument.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
@@ -19,9 +19,6 @@
* along with this program. If not, see .
*/
-using Greenshot.Interop;
-using GreenshotOCR;
-
namespace GreenshotOCRCommand.Modi {
///
/// The MODI Document object represents an ordered collection of document images saved as a single file.
diff --git a/GreenshotOCRCommand/Modi/IImage.cs b/GreenshotOCRCommand/Modi/IImage.cs
index f53ffa089..5329c4eaf 100644
--- a/GreenshotOCRCommand/Modi/IImage.cs
+++ b/GreenshotOCRCommand/Modi/IImage.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotOCRCommand/Modi/IImages.cs b/GreenshotOCRCommand/Modi/IImages.cs
index 7eeeb6401..3c429c7d0 100644
--- a/GreenshotOCRCommand/Modi/IImages.cs
+++ b/GreenshotOCRCommand/Modi/IImages.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotOCRCommand/Modi/ILayout.cs b/GreenshotOCRCommand/Modi/ILayout.cs
index 2b8d8beb5..351724150 100644
--- a/GreenshotOCRCommand/Modi/ILayout.cs
+++ b/GreenshotOCRCommand/Modi/ILayout.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotOCRCommand/Modi/IMiRect.cs b/GreenshotOCRCommand/Modi/IMiRect.cs
index 060a838f9..3474a5e86 100644
--- a/GreenshotOCRCommand/Modi/IMiRect.cs
+++ b/GreenshotOCRCommand/Modi/IMiRect.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotOCRCommand/Modi/IMiRects.cs b/GreenshotOCRCommand/Modi/IMiRects.cs
index b9ae99af5..e322b577d 100644
--- a/GreenshotOCRCommand/Modi/IMiRects.cs
+++ b/GreenshotOCRCommand/Modi/IMiRects.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotOCRCommand/Modi/IWord.cs b/GreenshotOCRCommand/Modi/IWord.cs
index f905c2617..6ba1a425b 100644
--- a/GreenshotOCRCommand/Modi/IWord.cs
+++ b/GreenshotOCRCommand/Modi/IWord.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotOCRCommand/Modi/IWords.cs b/GreenshotOCRCommand/Modi/IWords.cs
index 41acfb0fe..4e7243cdd 100644
--- a/GreenshotOCRCommand/Modi/IWords.cs
+++ b/GreenshotOCRCommand/Modi/IWords.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotOCRCommand/Modi/ModiLanguage.cs b/GreenshotOCRCommand/Modi/ModiLanguage.cs
index 89e49ed5b..b1af9f30c 100644
--- a/GreenshotOCRCommand/Modi/ModiLanguage.cs
+++ b/GreenshotOCRCommand/Modi/ModiLanguage.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotOCRCommand/Program.cs b/GreenshotOCRCommand/Program.cs
index 2bd757e8d..7f1c81b09 100644
--- a/GreenshotOCRCommand/Program.cs
+++ b/GreenshotOCRCommand/Program.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
@@ -23,7 +23,6 @@ using System;
using System.Collections.Generic;
using System.Diagnostics;
using System.IO;
-using Greenshot.Interop;
using GreenshotOCRCommand.Modi;
namespace GreenshotOCRCommand {
diff --git a/GreenshotOCRCommand/Properties/AssemblyInfo.cs b/GreenshotOCRCommand/Properties/AssemblyInfo.cs
index ff10a1848..85d71c24d 100644
--- a/GreenshotOCRCommand/Properties/AssemblyInfo.cs
+++ b/GreenshotOCRCommand/Properties/AssemblyInfo.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotOCRPlugin/ModiLanguage.cs b/GreenshotOCRPlugin/ModiLanguage.cs
index ae531b6ab..3edd95d0f 100644
--- a/GreenshotOCRPlugin/ModiLanguage.cs
+++ b/GreenshotOCRPlugin/ModiLanguage.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotOCRPlugin/OCRConfiguration.cs b/GreenshotOCRPlugin/OCRConfiguration.cs
index bee6c33e1..8eebcc91e 100644
--- a/GreenshotOCRPlugin/OCRConfiguration.cs
+++ b/GreenshotOCRPlugin/OCRConfiguration.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotOCRPlugin/OCRDestination.cs b/GreenshotOCRPlugin/OCRDestination.cs
index ee2dd975d..5c774bfc1 100644
--- a/GreenshotOCRPlugin/OCRDestination.cs
+++ b/GreenshotOCRPlugin/OCRDestination.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotOCRPlugin/OCRForm.cs b/GreenshotOCRPlugin/OCRForm.cs
index 299bd990a..5ba8fda84 100644
--- a/GreenshotOCRPlugin/OCRForm.cs
+++ b/GreenshotOCRPlugin/OCRForm.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotOCRPlugin/OCRPlugin.cs b/GreenshotOCRPlugin/OCRPlugin.cs
index 96ad08135..677e22342 100644
--- a/GreenshotOCRPlugin/OCRPlugin.cs
+++ b/GreenshotOCRPlugin/OCRPlugin.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotOCRPlugin/SettingsForm.Designer.cs b/GreenshotOCRPlugin/SettingsForm.Designer.cs
index 5b0dfe877..a9e57749a 100644
--- a/GreenshotOCRPlugin/SettingsForm.Designer.cs
+++ b/GreenshotOCRPlugin/SettingsForm.Designer.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotOCRPlugin/SettingsForm.cs b/GreenshotOCRPlugin/SettingsForm.cs
index b2c88629d..94805f941 100644
--- a/GreenshotOCRPlugin/SettingsForm.cs
+++ b/GreenshotOCRPlugin/SettingsForm.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
@@ -26,13 +26,13 @@ namespace GreenshotOCRPlugin {
/// Description of SettingsForm.
///
public partial class SettingsForm : OcrForm {
- private readonly OCRConfiguration config;
+ private readonly OCRConfiguration _config;
public SettingsForm(string [] languages, OCRConfiguration config) {
//
// The InitializeComponent() call is required for Windows Forms designer support.
//
- this.config = config;
+ this._config = config;
InitializeComponent();
AcceptButton = buttonOK;
CancelButton = buttonCancel;
@@ -58,7 +58,7 @@ namespace GreenshotOCRPlugin {
private void ButtonOKClick(object sender, EventArgs e) {
string selectedString = (string) comboBox_languages.SelectedItem;
if (selectedString != null) {
- config.Language = selectedString.ToUpper();
+ _config.Language = selectedString.ToUpper();
}
}
}
diff --git a/GreenshotOfficePlugin/Destinations/ExcelDestination.cs b/GreenshotOfficePlugin/Destinations/ExcelDestination.cs
index 93ea6ed85..dfd0ed7e0 100644
--- a/GreenshotOfficePlugin/Destinations/ExcelDestination.cs
+++ b/GreenshotOfficePlugin/Destinations/ExcelDestination.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotOfficePlugin/Destinations/OneNoteDestination.cs b/GreenshotOfficePlugin/Destinations/OneNoteDestination.cs
index 77d3c0a03..df833c6a1 100644
--- a/GreenshotOfficePlugin/Destinations/OneNoteDestination.cs
+++ b/GreenshotOfficePlugin/Destinations/OneNoteDestination.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotOfficePlugin/Destinations/OutlookDestination.cs b/GreenshotOfficePlugin/Destinations/OutlookDestination.cs
index ac88ec091..f08269c51 100644
--- a/GreenshotOfficePlugin/Destinations/OutlookDestination.cs
+++ b/GreenshotOfficePlugin/Destinations/OutlookDestination.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
@@ -30,6 +30,7 @@ using GreenshotPlugin.IniFile;
using GreenshotPlugin.Interfaces;
using GreenshotPlugin.Interfaces.Plugin;
using Microsoft.Office.Interop.Outlook;
+using Microsoft.Win32;
namespace GreenshotOfficePlugin.Destinations {
///
@@ -47,23 +48,40 @@ namespace GreenshotOfficePlugin.Destinations {
private const string MapiClient = "Microsoft Outlook";
private readonly string _outlookInspectorCaption;
private readonly OlObjectClass _outlookInspectorType;
- private readonly OutlookEmailExporter _outlookEmailExporter = new OutlookEmailExporter();
+ private readonly OutlookEmailExporter _outlookEmailExporter = new();
static OutlookDestination() {
- if (EmailConfigHelper.HasOutlook()) {
+ if (HasOutlook()) {
IsActiveFlag = true;
}
ExePath = PluginUtils.GetExePath("OUTLOOK.EXE");
if (ExePath != null && File.Exists(ExePath)) {
WindowDetails.AddProcessToExcludeFromFreeze("outlook");
} else {
- ExePath = null;
+ ExePath = GetOutlookExePath();
}
if (ExePath == null) {
IsActiveFlag = false;
}
}
+
+ private static string GetOutlookExePath() => RegistryHive.LocalMachine.ReadKey64Or32(@"Microsoft\Windows\CurrentVersion\App Paths\OUTLOOK.EXE");
+
+ ///
+ /// Check if Outlook is installed
+ ///
+ /// Returns true if outlook is installed
+ private static bool HasOutlook()
+ {
+ string outlookPath = GetOutlookExePath();
+ if (outlookPath == null)
+ {
+ return false;
+ }
+ return File.Exists(outlookPath);
+ }
+
public OutlookDestination() {
}
diff --git a/GreenshotOfficePlugin/Destinations/PowerpointDestination.cs b/GreenshotOfficePlugin/Destinations/PowerpointDestination.cs
index 1000fb7d9..3e3700e4c 100644
--- a/GreenshotOfficePlugin/Destinations/PowerpointDestination.cs
+++ b/GreenshotOfficePlugin/Destinations/PowerpointDestination.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotOfficePlugin/Destinations/WordDestination.cs b/GreenshotOfficePlugin/Destinations/WordDestination.cs
index a8a80893d..a7d630d1d 100644
--- a/GreenshotOfficePlugin/Destinations/WordDestination.cs
+++ b/GreenshotOfficePlugin/Destinations/WordDestination.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotOfficePlugin/OfficeConfiguration.cs b/GreenshotOfficePlugin/OfficeConfiguration.cs
index 3971e5cd4..7064715fd 100644
--- a/GreenshotOfficePlugin/OfficeConfiguration.cs
+++ b/GreenshotOfficePlugin/OfficeConfiguration.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotOfficePlugin/OfficeExport/Entities/OneNoteNotebook.cs b/GreenshotOfficePlugin/OfficeExport/Entities/OneNoteNotebook.cs
index 75c2f23d3..40bf4255e 100644
--- a/GreenshotOfficePlugin/OfficeExport/Entities/OneNoteNotebook.cs
+++ b/GreenshotOfficePlugin/OfficeExport/Entities/OneNoteNotebook.cs
@@ -1,5 +1,5 @@
// Greenshot - a free and open source screenshot tool
-// Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+// Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
//
// For more information see: http://getgreenshot.org/
// The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotOfficePlugin/OfficeExport/Entities/OneNotePage.cs b/GreenshotOfficePlugin/OfficeExport/Entities/OneNotePage.cs
index b9fd2c4a9..6bc67084b 100644
--- a/GreenshotOfficePlugin/OfficeExport/Entities/OneNotePage.cs
+++ b/GreenshotOfficePlugin/OfficeExport/Entities/OneNotePage.cs
@@ -1,5 +1,5 @@
// Greenshot - a free and open source screenshot tool
-// Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+// Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
//
// For more information see: http://getgreenshot.org/
// The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotOfficePlugin/OfficeExport/Entities/OneNoteSection.cs b/GreenshotOfficePlugin/OfficeExport/Entities/OneNoteSection.cs
index e02908c11..00eafb5ae 100644
--- a/GreenshotOfficePlugin/OfficeExport/Entities/OneNoteSection.cs
+++ b/GreenshotOfficePlugin/OfficeExport/Entities/OneNoteSection.cs
@@ -1,5 +1,5 @@
// Greenshot - a free and open source screenshot tool
-// Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+// Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
//
// For more information see: http://getgreenshot.org/
// The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotOfficePlugin/OfficeExport/ExcelExporter.cs b/GreenshotOfficePlugin/OfficeExport/ExcelExporter.cs
index 71939296e..ad92c6743 100644
--- a/GreenshotOfficePlugin/OfficeExport/ExcelExporter.cs
+++ b/GreenshotOfficePlugin/OfficeExport/ExcelExporter.cs
@@ -1,5 +1,5 @@
// Greenshot - a free and open source screenshot tool
-// Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+// Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
//
// For more information see: http://getgreenshot.org/
// The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotOfficePlugin/OfficeExport/OneNoteExporter.cs b/GreenshotOfficePlugin/OfficeExport/OneNoteExporter.cs
index 611594334..5b0fcb8c5 100644
--- a/GreenshotOfficePlugin/OfficeExport/OneNoteExporter.cs
+++ b/GreenshotOfficePlugin/OfficeExport/OneNoteExporter.cs
@@ -1,5 +1,5 @@
// Greenshot - a free and open source screenshot tool
-// Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+// Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
//
// For more information see: http://getgreenshot.org/
// The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotOfficePlugin/OfficeExport/OutlookEmailExporter.cs b/GreenshotOfficePlugin/OfficeExport/OutlookEmailExporter.cs
index a0d0f54e0..40306ecf7 100644
--- a/GreenshotOfficePlugin/OfficeExport/OutlookEmailExporter.cs
+++ b/GreenshotOfficePlugin/OfficeExport/OutlookEmailExporter.cs
@@ -1,5 +1,5 @@
// Greenshot - a free and open source screenshot tool
-// Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+// Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
//
// For more information see: http://getgreenshot.org/
// The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotOfficePlugin/OfficeExport/PowerpointExporter.cs b/GreenshotOfficePlugin/OfficeExport/PowerpointExporter.cs
index a9d5632c4..7f87ff111 100644
--- a/GreenshotOfficePlugin/OfficeExport/PowerpointExporter.cs
+++ b/GreenshotOfficePlugin/OfficeExport/PowerpointExporter.cs
@@ -1,5 +1,5 @@
// Greenshot - a free and open source screenshot tool
-// Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+// Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
//
// For more information see: http://getgreenshot.org/
// The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotOfficePlugin/OfficeExport/WordExporter.cs b/GreenshotOfficePlugin/OfficeExport/WordExporter.cs
index 0132d86b0..b44f08161 100644
--- a/GreenshotOfficePlugin/OfficeExport/WordExporter.cs
+++ b/GreenshotOfficePlugin/OfficeExport/WordExporter.cs
@@ -1,5 +1,5 @@
// Greenshot - a free and open source screenshot tool
-// Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+// Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
//
// For more information see: http://getgreenshot.org/
// The Greenshot project is hosted on GitHub: https://github.com/greenshot
diff --git a/GreenshotOfficePlugin/OfficeInterop/EmailFormat.cs b/GreenshotOfficePlugin/OfficeInterop/EmailFormat.cs
index 98969057f..2de5cbf71 100644
--- a/GreenshotOfficePlugin/OfficeInterop/EmailFormat.cs
+++ b/GreenshotOfficePlugin/OfficeInterop/EmailFormat.cs
@@ -1,5 +1,5 @@
// Greenshot - a free and open source screenshot tool
-// Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+// Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
//
// For more information see: http://getgreenshot.org/
// The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotOfficePlugin/OfficeInterop/OfficeVersions.cs b/GreenshotOfficePlugin/OfficeInterop/OfficeVersions.cs
index 6d8a992ba..03943e4db 100644
--- a/GreenshotOfficePlugin/OfficeInterop/OfficeVersions.cs
+++ b/GreenshotOfficePlugin/OfficeInterop/OfficeVersions.cs
@@ -1,5 +1,5 @@
// Greenshot - a free and open source screenshot tool
-// Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+// Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
//
// For more information see: http://getgreenshot.org/
// The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotOfficePlugin/OfficePlugin.cs b/GreenshotOfficePlugin/OfficePlugin.cs
index 4e01b38fa..6a17626a8 100644
--- a/GreenshotOfficePlugin/OfficePlugin.cs
+++ b/GreenshotOfficePlugin/OfficePlugin.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotOfficePlugin/Properties/AssemblyInfo.cs b/GreenshotOfficePlugin/Properties/AssemblyInfo.cs
index 50c27e0ec..3e2563a07 100644
--- a/GreenshotOfficePlugin/Properties/AssemblyInfo.cs
+++ b/GreenshotOfficePlugin/Properties/AssemblyInfo.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPhotobucketPlugin/Forms/PhotobucketForm.cs b/GreenshotPhotobucketPlugin/Forms/PhotobucketForm.cs
index 21c90f7d1..70971ca61 100644
--- a/GreenshotPhotobucketPlugin/Forms/PhotobucketForm.cs
+++ b/GreenshotPhotobucketPlugin/Forms/PhotobucketForm.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
@@ -19,7 +19,7 @@
* along with this program. If not, see .
*/
-namespace GreenshotPhotobucketPlugin {
+namespace GreenshotPhotobucketPlugin.Forms {
///
/// This class is needed for design-time resolving of the language files
///
diff --git a/GreenshotPhotobucketPlugin/Forms/SettingsForm.Designer.cs b/GreenshotPhotobucketPlugin/Forms/SettingsForm.Designer.cs
index a7dcc758e..4a0486dd1 100644
--- a/GreenshotPhotobucketPlugin/Forms/SettingsForm.Designer.cs
+++ b/GreenshotPhotobucketPlugin/Forms/SettingsForm.Designer.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
@@ -18,7 +18,7 @@
* You should have received a copy of the GNU General Public License
* along with this program. If not, see .
*/
-namespace GreenshotPhotobucketPlugin {
+namespace GreenshotPhotobucketPlugin.Forms {
partial class SettingsForm {
///
/// Designer variable used to keep track of non-visual components.
diff --git a/GreenshotPhotobucketPlugin/Forms/SettingsForm.cs b/GreenshotPhotobucketPlugin/Forms/SettingsForm.cs
index 056d696a9..1d221b2a9 100644
--- a/GreenshotPhotobucketPlugin/Forms/SettingsForm.cs
+++ b/GreenshotPhotobucketPlugin/Forms/SettingsForm.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
@@ -19,7 +19,7 @@
* along with this program. If not, see .
*/
-namespace GreenshotPhotobucketPlugin {
+namespace GreenshotPhotobucketPlugin.Forms {
///
/// Description of PasswordRequestForm.
///
diff --git a/GreenshotPhotobucketPlugin/GreenshotPhotobucketPlugin.Credentials.template b/GreenshotPhotobucketPlugin/GreenshotPhotobucketPlugin.Credentials.template
index 20a033ea8..312099888 100644
--- a/GreenshotPhotobucketPlugin/GreenshotPhotobucketPlugin.Credentials.template
+++ b/GreenshotPhotobucketPlugin/GreenshotPhotobucketPlugin.Credentials.template
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPhotobucketPlugin/LanguageKeys.cs b/GreenshotPhotobucketPlugin/LanguageKeys.cs
index 5c077c4ad..b94f13722 100644
--- a/GreenshotPhotobucketPlugin/LanguageKeys.cs
+++ b/GreenshotPhotobucketPlugin/LanguageKeys.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPhotobucketPlugin/PhotobucketConfiguration.cs b/GreenshotPhotobucketPlugin/PhotobucketConfiguration.cs
index 7b00ad768..8136adbff 100644
--- a/GreenshotPhotobucketPlugin/PhotobucketConfiguration.cs
+++ b/GreenshotPhotobucketPlugin/PhotobucketConfiguration.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
@@ -19,6 +19,7 @@
* along with this program. If not, see .
*/
using System.Windows.Forms;
+using GreenshotPhotobucketPlugin.Forms;
using GreenshotPlugin.Controls;
using GreenshotPlugin.Core;
using GreenshotPlugin.IniFile;
diff --git a/GreenshotPhotobucketPlugin/PhotobucketDestination.cs b/GreenshotPhotobucketPlugin/PhotobucketDestination.cs
index 9a22488bf..96dc98926 100644
--- a/GreenshotPhotobucketPlugin/PhotobucketDestination.cs
+++ b/GreenshotPhotobucketPlugin/PhotobucketDestination.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPhotobucketPlugin/PhotobucketInfo.cs b/GreenshotPhotobucketPlugin/PhotobucketInfo.cs
index cf0fd0c54..b9759eb3c 100644
--- a/GreenshotPhotobucketPlugin/PhotobucketInfo.cs
+++ b/GreenshotPhotobucketPlugin/PhotobucketInfo.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPhotobucketPlugin/PhotobucketPlugin.cs b/GreenshotPhotobucketPlugin/PhotobucketPlugin.cs
index 971ccc0e6..a9670a6a2 100644
--- a/GreenshotPhotobucketPlugin/PhotobucketPlugin.cs
+++ b/GreenshotPhotobucketPlugin/PhotobucketPlugin.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPhotobucketPlugin/PhotobucketUtils.cs b/GreenshotPhotobucketPlugin/PhotobucketUtils.cs
index 677084e92..bb59ff09a 100644
--- a/GreenshotPhotobucketPlugin/PhotobucketUtils.cs
+++ b/GreenshotPhotobucketPlugin/PhotobucketUtils.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPhotobucketPlugin/Properties/AssemblyInfo.cs b/GreenshotPhotobucketPlugin/Properties/AssemblyInfo.cs
index 9aa4884a4..99952c5c0 100644
--- a/GreenshotPhotobucketPlugin/Properties/AssemblyInfo.cs
+++ b/GreenshotPhotobucketPlugin/Properties/AssemblyInfo.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPicasaPlugin/Forms/PicasaForm.cs b/GreenshotPicasaPlugin/Forms/PicasaForm.cs
index a1d093e30..cea5a2f35 100644
--- a/GreenshotPicasaPlugin/Forms/PicasaForm.cs
+++ b/GreenshotPicasaPlugin/Forms/PicasaForm.cs
@@ -16,10 +16,11 @@
*
* You should have received a copy of the GNU General Public License
* along with this program. If not, see .
- */
-using GreenshotPlugin.Controls;
-
-namespace GreenshotPicasaPlugin {
- public class PicasaForm : GreenshotForm {
- }
-}
+ */
+
+using GreenshotPlugin.Controls;
+
+namespace GreenshotPicasaPlugin.Forms {
+ public class PicasaForm : GreenshotForm {
+ }
+}
diff --git a/GreenshotPicasaPlugin/Forms/SettingsForm.Designer.cs b/GreenshotPicasaPlugin/Forms/SettingsForm.Designer.cs
index 0d2447e41..38555c179 100644
--- a/GreenshotPicasaPlugin/Forms/SettingsForm.Designer.cs
+++ b/GreenshotPicasaPlugin/Forms/SettingsForm.Designer.cs
@@ -17,7 +17,7 @@
* You should have received a copy of the GNU General Public License
* along with this program. If not, see .
*/
-namespace GreenshotPicasaPlugin {
+namespace GreenshotPicasaPlugin.Forms {
partial class SettingsForm {
///
/// Designer variable used to keep track of non-visual components.
diff --git a/GreenshotPicasaPlugin/Forms/SettingsForm.cs b/GreenshotPicasaPlugin/Forms/SettingsForm.cs
index 734559762..a6691a424 100644
--- a/GreenshotPicasaPlugin/Forms/SettingsForm.cs
+++ b/GreenshotPicasaPlugin/Forms/SettingsForm.cs
@@ -18,7 +18,7 @@
* along with this program. If not, see .
*/
-namespace GreenshotPicasaPlugin {
+namespace GreenshotPicasaPlugin.Forms {
///
/// Description of PasswordRequestForm.
///
diff --git a/GreenshotPicasaPlugin/GreenshotPicasaPlugin.Credentials.template b/GreenshotPicasaPlugin/GreenshotPicasaPlugin.Credentials.template
index 5cb7a2aac..47172f2d4 100644
--- a/GreenshotPicasaPlugin/GreenshotPicasaPlugin.Credentials.template
+++ b/GreenshotPicasaPlugin/GreenshotPicasaPlugin.Credentials.template
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPicasaPlugin/PicasaConfiguration.cs b/GreenshotPicasaPlugin/PicasaConfiguration.cs
index a1372f598..202929459 100644
--- a/GreenshotPicasaPlugin/PicasaConfiguration.cs
+++ b/GreenshotPicasaPlugin/PicasaConfiguration.cs
@@ -20,6 +20,7 @@
using System.Windows.Forms;
using GreenshotPlugin.Core;
using System;
+using GreenshotPicasaPlugin.Forms;
using GreenshotPlugin.IniFile;
namespace GreenshotPicasaPlugin {
diff --git a/GreenshotPicasaPlugin/Properties/AssemblyInfo.cs b/GreenshotPicasaPlugin/Properties/AssemblyInfo.cs
index 35cc458c3..3a917ddcd 100644
--- a/GreenshotPicasaPlugin/Properties/AssemblyInfo.cs
+++ b/GreenshotPicasaPlugin/Properties/AssemblyInfo.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom, Francis Noel
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom, Francis Noel
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/Controls/AnimatingForm.cs b/GreenshotPlugin/Controls/AnimatingForm.cs
index 91f4762f0..55d6e1865 100644
--- a/GreenshotPlugin/Controls/AnimatingForm.cs
+++ b/GreenshotPlugin/Controls/AnimatingForm.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/Controls/BackgroundForm.Designer.cs b/GreenshotPlugin/Controls/BackgroundForm.Designer.cs
index fbfee52bd..cafbb6e18 100644
--- a/GreenshotPlugin/Controls/BackgroundForm.Designer.cs
+++ b/GreenshotPlugin/Controls/BackgroundForm.Designer.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/Controls/BackgroundForm.cs b/GreenshotPlugin/Controls/BackgroundForm.cs
index 5d90c6920..5ce737185 100644
--- a/GreenshotPlugin/Controls/BackgroundForm.cs
+++ b/GreenshotPlugin/Controls/BackgroundForm.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/Controls/ExtendedWebBrowser.cs b/GreenshotPlugin/Controls/ExtendedWebBrowser.cs
index 78a793866..c18a2071f 100644
--- a/GreenshotPlugin/Controls/ExtendedWebBrowser.cs
+++ b/GreenshotPlugin/Controls/ExtendedWebBrowser.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/Controls/FormWithoutActivation.cs b/GreenshotPlugin/Controls/FormWithoutActivation.cs
index 3fd3f8e30..4491bbf2b 100644
--- a/GreenshotPlugin/Controls/FormWithoutActivation.cs
+++ b/GreenshotPlugin/Controls/FormWithoutActivation.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/Controls/GreenshotButton.cs b/GreenshotPlugin/Controls/GreenshotButton.cs
index 2cbee2916..16288ce43 100644
--- a/GreenshotPlugin/Controls/GreenshotButton.cs
+++ b/GreenshotPlugin/Controls/GreenshotButton.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/Controls/GreenshotCheckBox.cs b/GreenshotPlugin/Controls/GreenshotCheckBox.cs
index 53300d5d7..e7e3483ab 100644
--- a/GreenshotPlugin/Controls/GreenshotCheckBox.cs
+++ b/GreenshotPlugin/Controls/GreenshotCheckBox.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/Controls/GreenshotColumnSorter.cs b/GreenshotPlugin/Controls/GreenshotColumnSorter.cs
index 379d53883..efad46cd0 100644
--- a/GreenshotPlugin/Controls/GreenshotColumnSorter.cs
+++ b/GreenshotPlugin/Controls/GreenshotColumnSorter.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/Controls/GreenshotComboBox.cs b/GreenshotPlugin/Controls/GreenshotComboBox.cs
index e5245b5a2..c9f0b3d9e 100644
--- a/GreenshotPlugin/Controls/GreenshotComboBox.cs
+++ b/GreenshotPlugin/Controls/GreenshotComboBox.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/Controls/GreenshotForm.cs b/GreenshotPlugin/Controls/GreenshotForm.cs
index 1f6ce5675..1375c0b7a 100644
--- a/GreenshotPlugin/Controls/GreenshotForm.cs
+++ b/GreenshotPlugin/Controls/GreenshotForm.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/Controls/GreenshotGroupBox.cs b/GreenshotPlugin/Controls/GreenshotGroupBox.cs
index b61f64436..954027948 100644
--- a/GreenshotPlugin/Controls/GreenshotGroupBox.cs
+++ b/GreenshotPlugin/Controls/GreenshotGroupBox.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/Controls/GreenshotLabel.cs b/GreenshotPlugin/Controls/GreenshotLabel.cs
index fa10711e0..887bdb2ea 100644
--- a/GreenshotPlugin/Controls/GreenshotLabel.cs
+++ b/GreenshotPlugin/Controls/GreenshotLabel.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/Controls/GreenshotRadioButton.cs b/GreenshotPlugin/Controls/GreenshotRadioButton.cs
index 7ef3d41d7..ca68fb284 100644
--- a/GreenshotPlugin/Controls/GreenshotRadioButton.cs
+++ b/GreenshotPlugin/Controls/GreenshotRadioButton.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/Controls/GreenshotTabPage.cs b/GreenshotPlugin/Controls/GreenshotTabPage.cs
index 189c9173a..6941a861a 100644
--- a/GreenshotPlugin/Controls/GreenshotTabPage.cs
+++ b/GreenshotPlugin/Controls/GreenshotTabPage.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/Controls/GreenshotTextBox.cs b/GreenshotPlugin/Controls/GreenshotTextBox.cs
index e370c0b35..a4f743f25 100644
--- a/GreenshotPlugin/Controls/GreenshotTextBox.cs
+++ b/GreenshotPlugin/Controls/GreenshotTextBox.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/Controls/GreenshotToolDropDownButton.cs b/GreenshotPlugin/Controls/GreenshotToolDropDownButton.cs
index 585334a5f..e9a9edb7d 100644
--- a/GreenshotPlugin/Controls/GreenshotToolDropDownButton.cs
+++ b/GreenshotPlugin/Controls/GreenshotToolDropDownButton.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/Controls/GreenshotToolStripButton.cs b/GreenshotPlugin/Controls/GreenshotToolStripButton.cs
index c5ffff3b0..06bf59597 100644
--- a/GreenshotPlugin/Controls/GreenshotToolStripButton.cs
+++ b/GreenshotPlugin/Controls/GreenshotToolStripButton.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/Controls/GreenshotToolStripLabel.cs b/GreenshotPlugin/Controls/GreenshotToolStripLabel.cs
index 2c7051c21..5bee42167 100644
--- a/GreenshotPlugin/Controls/GreenshotToolStripLabel.cs
+++ b/GreenshotPlugin/Controls/GreenshotToolStripLabel.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/Controls/GreenshotToolStripMenuItem.cs b/GreenshotPlugin/Controls/GreenshotToolStripMenuItem.cs
index 1adca374d..8547b65c8 100644
--- a/GreenshotPlugin/Controls/GreenshotToolStripMenuItem.cs
+++ b/GreenshotPlugin/Controls/GreenshotToolStripMenuItem.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/Controls/HotkeyControl.cs b/GreenshotPlugin/Controls/HotkeyControl.cs
index 89f0889b2..cb9f4593a 100644
--- a/GreenshotPlugin/Controls/HotkeyControl.cs
+++ b/GreenshotPlugin/Controls/HotkeyControl.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
@@ -463,10 +463,10 @@ namespace GreenshotPlugin.Controls {
if (RegisterHotKey(_hotkeyHwnd, _hotKeyCounter, modifiers, (uint)virtualKeyCode)) {
KeyHandlers.Add(_hotKeyCounter, handler);
return _hotKeyCounter++;
- } else {
- Log.Warn($"Couldn't register hotkey modifier {modifierKeyCode} virtualKeyCode {virtualKeyCode}");
- return -1;
}
+
+ Log.Warn($"Couldn't register hotkey modifier {modifierKeyCode} virtualKeyCode {virtualKeyCode}");
+ return -1;
}
public static void UnregisterHotkeys() {
@@ -574,9 +574,9 @@ namespace GreenshotPlugin.Controls {
visibleName = visibleName.Substring(0,1) + visibleName.Substring(1).ToLower();
}
return visibleName;
- } else {
- return givenKey.ToString();
}
+
+ return givenKey.ToString();
}
}
}
\ No newline at end of file
diff --git a/GreenshotPlugin/Controls/IGreenshotConfigBindable.cs b/GreenshotPlugin/Controls/IGreenshotConfigBindable.cs
index 7211ed402..d20ed1cd1 100644
--- a/GreenshotPlugin/Controls/IGreenshotConfigBindable.cs
+++ b/GreenshotPlugin/Controls/IGreenshotConfigBindable.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/Controls/IGreenshotLanguageBindable.cs b/GreenshotPlugin/Controls/IGreenshotLanguageBindable.cs
index 7b5775a22..06237dcc9 100644
--- a/GreenshotPlugin/Controls/IGreenshotLanguageBindable.cs
+++ b/GreenshotPlugin/Controls/IGreenshotLanguageBindable.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/Controls/OAuthLoginForm.Designer.cs b/GreenshotPlugin/Controls/OAuthLoginForm.Designer.cs
index e8ca384a2..abf92060c 100644
--- a/GreenshotPlugin/Controls/OAuthLoginForm.Designer.cs
+++ b/GreenshotPlugin/Controls/OAuthLoginForm.Designer.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/Controls/OAuthLoginForm.cs b/GreenshotPlugin/Controls/OAuthLoginForm.cs
index a44940be1..998b938bb 100644
--- a/GreenshotPlugin/Controls/OAuthLoginForm.cs
+++ b/GreenshotPlugin/Controls/OAuthLoginForm.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
@@ -35,7 +35,7 @@ namespace GreenshotPlugin.Controls {
public IDictionary CallbackParameters { get; private set; }
- public bool IsOk => DialogResult == DialogResult.OK;
+ public bool IsOk => DialogResult == DialogResult.OK;
public OAuthLoginForm(string browserTitle, Size size, string authorizationLink, string callbackUrl) {
// Make sure Greenshot uses the correct browser version
diff --git a/GreenshotPlugin/Controls/PleaseWaitForm.Designer.cs b/GreenshotPlugin/Controls/PleaseWaitForm.Designer.cs
index c308b4b07..a3ab2832b 100644
--- a/GreenshotPlugin/Controls/PleaseWaitForm.Designer.cs
+++ b/GreenshotPlugin/Controls/PleaseWaitForm.Designer.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/Controls/PleaseWaitForm.cs b/GreenshotPlugin/Controls/PleaseWaitForm.cs
index 995b0c17c..fecd1afc9 100644
--- a/GreenshotPlugin/Controls/PleaseWaitForm.cs
+++ b/GreenshotPlugin/Controls/PleaseWaitForm.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/Controls/QualityDialog.Designer.cs b/GreenshotPlugin/Controls/QualityDialog.Designer.cs
index eaf714d06..5f1c03fce 100644
--- a/GreenshotPlugin/Controls/QualityDialog.Designer.cs
+++ b/GreenshotPlugin/Controls/QualityDialog.Designer.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/Controls/QualityDialog.cs b/GreenshotPlugin/Controls/QualityDialog.cs
index ada7ad476..0e196f387 100644
--- a/GreenshotPlugin/Controls/QualityDialog.cs
+++ b/GreenshotPlugin/Controls/QualityDialog.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/Controls/SaveImageFileDialog.cs b/GreenshotPlugin/Controls/SaveImageFileDialog.cs
index 45f98118f..0245dc05e 100644
--- a/GreenshotPlugin/Controls/SaveImageFileDialog.cs
+++ b/GreenshotPlugin/Controls/SaveImageFileDialog.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/Controls/ThumbnailForm.cs b/GreenshotPlugin/Controls/ThumbnailForm.cs
index 3e8256cf3..3578b63d3 100644
--- a/GreenshotPlugin/Controls/ThumbnailForm.cs
+++ b/GreenshotPlugin/Controls/ThumbnailForm.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/Core/AbstractDestination.cs b/GreenshotPlugin/Core/AbstractDestination.cs
index ba9878c23..7efa0f570 100644
--- a/GreenshotPlugin/Core/AbstractDestination.cs
+++ b/GreenshotPlugin/Core/AbstractDestination.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/Core/AbstractProcessor.cs b/GreenshotPlugin/Core/AbstractProcessor.cs
index 1dce1ab16..f93a405fb 100644
--- a/GreenshotPlugin/Core/AbstractProcessor.cs
+++ b/GreenshotPlugin/Core/AbstractProcessor.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/Core/AccessibleHelper.cs b/GreenshotPlugin/Core/AccessibleHelper.cs
index f6d5770b3..871892e64 100644
--- a/GreenshotPlugin/Core/AccessibleHelper.cs
+++ b/GreenshotPlugin/Core/AccessibleHelper.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
@@ -40,7 +40,7 @@ namespace GreenshotPlugin.Core {
return num;
}
[DllImport("oleacc.dll")]
- private static extern int AccessibleObjectFromWindow(IntPtr hwnd, uint id, ref Guid iid, [In, Out, MarshalAs(UnmanagedType.IUnknown)] ref object ppvObject);
+ private static extern int AccessibleObjectFromWindow(IntPtr hWnd, uint id, ref Guid iid, [In, Out, MarshalAs(UnmanagedType.IUnknown)] ref object ppvObject);
[DllImport("oleacc.dll")]
private static extern int AccessibleChildren(IAccessible paccContainer, int iChildStart, int cChildren, [In, Out, MarshalAs(UnmanagedType.LPArray, SizeParamIndex = 2)] object[] rgvarChildren, out int pcObtained);
diff --git a/GreenshotPlugin/Core/AnimationHelpers.cs b/GreenshotPlugin/Core/AnimationHelpers.cs
index cd96b890a..9ed92eef6 100644
--- a/GreenshotPlugin/Core/AnimationHelpers.cs
+++ b/GreenshotPlugin/Core/AnimationHelpers.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/Core/BinaryStructHelper.cs b/GreenshotPlugin/Core/BinaryStructHelper.cs
index b8584c572..1d8af4700 100644
--- a/GreenshotPlugin/Core/BinaryStructHelper.cs
+++ b/GreenshotPlugin/Core/BinaryStructHelper.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/Core/Cache.cs b/GreenshotPlugin/Core/Cache.cs
index ae41d7d60..857f5327a 100644
--- a/GreenshotPlugin/Core/Cache.cs
+++ b/GreenshotPlugin/Core/Cache.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/Core/CaptureHandler.cs b/GreenshotPlugin/Core/CaptureHandler.cs
index 4f832004a..7716b56c1 100644
--- a/GreenshotPlugin/Core/CaptureHandler.cs
+++ b/GreenshotPlugin/Core/CaptureHandler.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/Core/ClipboardHelper.cs b/GreenshotPlugin/Core/ClipboardHelper.cs
index 3933ccf71..046838716 100644
--- a/GreenshotPlugin/Core/ClipboardHelper.cs
+++ b/GreenshotPlugin/Core/ClipboardHelper.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/Core/CoreConfiguration.cs b/GreenshotPlugin/Core/CoreConfiguration.cs
index 1db95dd93..bf2570ce9 100644
--- a/GreenshotPlugin/Core/CoreConfiguration.cs
+++ b/GreenshotPlugin/Core/CoreConfiguration.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
@@ -74,6 +74,9 @@ namespace GreenshotPlugin.Core {
public string LastregionHotkey { get; set; }
[IniProperty("IEHotkey", Description="Hotkey for starting the IE capture", DefaultValue="Shift + Ctrl + PrintScreen")]
public string IEHotkey { get; set; }
+
+ [IniProperty("ClipboardHotkey", Description = "Hotkey for opening the clipboard contents into the editor")]
+ public string ClipboardHotkey { get; set; }
[IniProperty("IsFirstLaunch", Description="Is this the first time launch?", DefaultValue="true")]
public bool IsFirstLaunch { get; set; }
diff --git a/GreenshotPlugin/Core/CredentialsHelper.cs b/GreenshotPlugin/Core/CredentialsHelper.cs
index 7732c4f46..95426e934 100644
--- a/GreenshotPlugin/Core/CredentialsHelper.cs
+++ b/GreenshotPlugin/Core/CredentialsHelper.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
@@ -382,7 +382,7 @@ namespace GreenshotPlugin.Core {
/// The System.Windows.Forms.IWin32Window the dialog will display in front of.
private CredUi.INFO GetInfo(IWin32Window owner) {
CredUi.INFO info = new CredUi.INFO();
- if (owner != null) info.hwndParent = owner.Handle;
+ if (owner != null) info.hWndParent = owner.Handle;
info.pszCaptionText = Caption;
info.pszMessageText = Message;
if (Banner != null) {
@@ -498,7 +498,7 @@ namespace GreenshotPlugin.Core {
///
public struct INFO {
public int cbSize;
- public IntPtr hwndParent;
+ public IntPtr hWndParent;
[MarshalAs(UnmanagedType.LPWStr)] public string pszMessageText;
[MarshalAs(UnmanagedType.LPWStr)] public string pszCaptionText;
public IntPtr hbmBanner;
diff --git a/GreenshotPlugin/Core/DisplayKeyAttribute.cs b/GreenshotPlugin/Core/DisplayKeyAttribute.cs
index d055b91ad..8f1b81b68 100644
--- a/GreenshotPlugin/Core/DisplayKeyAttribute.cs
+++ b/GreenshotPlugin/Core/DisplayKeyAttribute.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/Core/EmailConfigHelper.cs b/GreenshotPlugin/Core/EmailConfigHelper.cs
deleted file mode 100644
index 354f02c33..000000000
--- a/GreenshotPlugin/Core/EmailConfigHelper.cs
+++ /dev/null
@@ -1,55 +0,0 @@
-/*
- * Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
- *
- * For more information see: http://getgreenshot.org/
- * The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
- *
- * This program is free software: you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation, either version 1 of the License, or
- * (at your option) any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program. If not, see .
- */
-
-using System.IO;
-using Microsoft.Win32;
-
-namespace GreenshotPlugin.Core {
- ///
- /// Description of EmailConfigHelper.
- ///
- public static class EmailConfigHelper {
-
- public static string GetMapiClient() => Registry.LocalMachine.ReadKey64Or32(@"Clients\Mail");
-
- public static bool HasMapi()
- {
- var value = Registry.LocalMachine.ReadKey64Or32(@"Microsoft\Windows Messaging Subsystem", "MAPI", "0");
- return "1".Equals(value);
-
- }
-
- public static string GetOutlookExePath() => Registry.LocalMachine.ReadKey64Or32(@"Microsoft\Windows\CurrentVersion\App Paths\OUTLOOK.EXE");
-
- ///
- /// Check if Outlook is installed
- ///
- /// Returns true if outlook is installed
- public static bool HasOutlook() {
- string outlookPath = GetOutlookExePath();
- if (outlookPath == null)
- {
- return false;
- }
- return File.Exists(outlookPath);
- }
- }
-}
diff --git a/GreenshotPlugin/Core/EnumExtensions.cs b/GreenshotPlugin/Core/EnumExtensions.cs
index 39aff04f1..1bda1071f 100644
--- a/GreenshotPlugin/Core/EnumExtensions.cs
+++ b/GreenshotPlugin/Core/EnumExtensions.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/Core/Enums/HResult.cs b/GreenshotPlugin/Core/Enums/HResult.cs
index 55f61aaf0..40bb62a7b 100644
--- a/GreenshotPlugin/Core/Enums/HResult.cs
+++ b/GreenshotPlugin/Core/Enums/HResult.cs
@@ -1,5 +1,5 @@
// Greenshot - a free and open source screenshot tool
-// Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+// Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
//
// For more information see: http://getgreenshot.org/
// The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/Core/EnvironmentInfo.cs b/GreenshotPlugin/Core/EnvironmentInfo.cs
index ba0c061d2..7a7c3d7ea 100644
--- a/GreenshotPlugin/Core/EnvironmentInfo.cs
+++ b/GreenshotPlugin/Core/EnvironmentInfo.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
@@ -208,18 +208,18 @@ namespace GreenshotPlugin.Core
}
}
}
- if (ex is ExternalException)
+ if (ex is ExternalException externalException)
{
// e.g. COMException
- report.AppendLine().AppendLine("ErrorCode: 0x" + (ex as ExternalException).ErrorCode.ToString("X"));
+ report.AppendLine().AppendLine("ErrorCode: 0x" + externalException.ErrorCode.ToString("X"));
}
report.AppendLine().AppendLine("Stack:").AppendLine(ex.StackTrace);
- if (ex is ReflectionTypeLoadException)
+ if (ex is ReflectionTypeLoadException reflectionTypeLoadException)
{
report.AppendLine().AppendLine("LoaderExceptions: ");
- foreach (Exception cbE in (ex as ReflectionTypeLoadException).LoaderExceptions)
+ foreach (Exception cbE in reflectionTypeLoadException.LoaderExceptions)
{
report.AppendLine(cbE.Message);
}
diff --git a/GreenshotPlugin/Core/EventDelay.cs b/GreenshotPlugin/Core/EventDelay.cs
index 84860f7ae..c00306309 100644
--- a/GreenshotPlugin/Core/EventDelay.cs
+++ b/GreenshotPlugin/Core/EventDelay.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/Core/FastBitmap.cs b/GreenshotPlugin/Core/FastBitmap.cs
index a76045a42..0e52e04fb 100644
--- a/GreenshotPlugin/Core/FastBitmap.cs
+++ b/GreenshotPlugin/Core/FastBitmap.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/Core/FilenameHelper.cs b/GreenshotPlugin/Core/FilenameHelper.cs
index 23fdbd9b4..5edf92afb 100644
--- a/GreenshotPlugin/Core/FilenameHelper.cs
+++ b/GreenshotPlugin/Core/FilenameHelper.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/Core/GreenshotResources.cs b/GreenshotPlugin/Core/GreenshotResources.cs
index 8f59dee91..6b80acf3f 100644
--- a/GreenshotPlugin/Core/GreenshotResources.cs
+++ b/GreenshotPlugin/Core/GreenshotResources.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/Core/HResultExtensions.cs b/GreenshotPlugin/Core/HResultExtensions.cs
index bc0f8e4ba..a85bd7600 100644
--- a/GreenshotPlugin/Core/HResultExtensions.cs
+++ b/GreenshotPlugin/Core/HResultExtensions.cs
@@ -1,5 +1,5 @@
// Greenshot - a free and open source screenshot tool
-// Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+// Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
//
// For more information see: http://getgreenshot.org/
// The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/Core/IEHelper.cs b/GreenshotPlugin/Core/IEHelper.cs
index 703d42a15..2a85958fc 100644
--- a/GreenshotPlugin/Core/IEHelper.cs
+++ b/GreenshotPlugin/Core/IEHelper.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/Core/IImage.cs b/GreenshotPlugin/Core/IImage.cs
index 53fa64bd3..710a0d04d 100644
--- a/GreenshotPlugin/Core/IImage.cs
+++ b/GreenshotPlugin/Core/IImage.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/Core/ImageHelper.cs b/GreenshotPlugin/Core/ImageHelper.cs
index e5e5a1b60..b80879141 100644
--- a/GreenshotPlugin/Core/ImageHelper.cs
+++ b/GreenshotPlugin/Core/ImageHelper.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/Core/ImageOutput.cs b/GreenshotPlugin/Core/ImageOutput.cs
index 97c8f8cf3..4388f2b59 100644
--- a/GreenshotPlugin/Core/ImageOutput.cs
+++ b/GreenshotPlugin/Core/ImageOutput.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/Core/InterfaceUtils.cs b/GreenshotPlugin/Core/InterfaceUtils.cs
index b592474f0..89c8079f0 100644
--- a/GreenshotPlugin/Core/InterfaceUtils.cs
+++ b/GreenshotPlugin/Core/InterfaceUtils.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/Core/Language.cs b/GreenshotPlugin/Core/Language.cs
index 31200d8ff..f5f2caa26 100644
--- a/GreenshotPlugin/Core/Language.cs
+++ b/GreenshotPlugin/Core/Language.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/Core/LogHelper.cs b/GreenshotPlugin/Core/LogHelper.cs
index 1b5d8764b..c0849537e 100644
--- a/GreenshotPlugin/Core/LogHelper.cs
+++ b/GreenshotPlugin/Core/LogHelper.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/Core/NetworkHelper.cs b/GreenshotPlugin/Core/NetworkHelper.cs
index 8d275cf21..dbeba1f62 100644
--- a/GreenshotPlugin/Core/NetworkHelper.cs
+++ b/GreenshotPlugin/Core/NetworkHelper.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/Core/ObjectExtensions.cs b/GreenshotPlugin/Core/ObjectExtensions.cs
index 491d24238..a948242b0 100644
--- a/GreenshotPlugin/Core/ObjectExtensions.cs
+++ b/GreenshotPlugin/Core/ObjectExtensions.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/Core/PluginUtils.cs b/GreenshotPlugin/Core/PluginUtils.cs
index d7c1ce08b..0db458a3f 100644
--- a/GreenshotPlugin/Core/PluginUtils.cs
+++ b/GreenshotPlugin/Core/PluginUtils.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/Core/QuantizerHelper.cs b/GreenshotPlugin/Core/QuantizerHelper.cs
index 0946b4385..f5396810f 100644
--- a/GreenshotPlugin/Core/QuantizerHelper.cs
+++ b/GreenshotPlugin/Core/QuantizerHelper.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/Core/RegistryKeyExtensions.cs b/GreenshotPlugin/Core/RegistryKeyExtensions.cs
index 73fd66a47..bfdb63e10 100644
--- a/GreenshotPlugin/Core/RegistryKeyExtensions.cs
+++ b/GreenshotPlugin/Core/RegistryKeyExtensions.cs
@@ -32,36 +32,57 @@ namespace GreenshotPlugin.Core
///
/// Retrieve a registry value
///
- /// RegistryKey like Registry.LocalMachine
+ /// RegistryHive like RegistryHive.LocalMachine
/// string with the name of the key
/// string with the name of the value below the key, null will retrieve the default
/// string with the default value to return
/// string with the value
- public static string ReadKey64Or32(this RegistryKey registryKey, string keyName, string value = null, string defaultValue = null)
+ public static string ReadKey64Or32(this RegistryHive registryHive, string keyName, string value = null, string defaultValue = null)
{
string result = null;
value ??= string.Empty;
- if (Environment.Is64BitOperatingSystem)
+
+ using var registryKey32 = RegistryKey.OpenBaseKey(registryHive, RegistryView.Registry32);
+ // Logic for 32-bit Windows is just reading the key
+ if (!Environment.Is64BitOperatingSystem)
{
- using var key = registryKey.OpenSubKey($@"SOFTWARE\{keyName}", false);
-
+ using var key = registryKey32.OpenSubKey($@"SOFTWARE\{keyName}", false);
+
if (key != null)
{
- result = (string)key.GetValue(value, defaultValue);
+ result = (string)key.GetValue(value);
+ }
+ if (string.IsNullOrEmpty(result))
+ {
+ result = defaultValue;
+ }
+ return result;
+ }
+ using var registryKey64 = RegistryKey.OpenBaseKey(registryHive, RegistryView.Registry64);
+ // Logic for 64 bit Windows, is trying the key which is 64 bit
+ using (var key = registryKey64.OpenSubKey($@"SOFTWARE\{keyName}", false))
+ {
+ if (key != null)
+ {
+ result = (string)key.GetValue(value);
+ }
+ if (!string.IsNullOrEmpty(result)) return result;
+ }
+
+ // if there is no value use the wow6432node key which is 32 bit
+ using (var key = registryKey32.OpenSubKey($@"SOFTWARE\{keyName}", false))
+ {
+ if (key != null)
+ {
+ result = (string)key.GetValue(value);
}
}
if (string.IsNullOrEmpty(result))
{
- using var key = registryKey.OpenSubKey($@"SOFTWARE\wow6432node\{keyName}", false);
-
- if (key != null)
- {
- result = (string)key.GetValue(value, defaultValue);
- }
+ result = defaultValue;
}
-
return result;
}
}
-}
+}
\ No newline at end of file
diff --git a/GreenshotPlugin/Core/StringExtensions.cs b/GreenshotPlugin/Core/StringExtensions.cs
index 6676500af..e7ee8cf81 100644
--- a/GreenshotPlugin/Core/StringExtensions.cs
+++ b/GreenshotPlugin/Core/StringExtensions.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/Core/SvgImage.cs b/GreenshotPlugin/Core/SvgImage.cs
index 64111a7eb..d777d30ad 100644
--- a/GreenshotPlugin/Core/SvgImage.cs
+++ b/GreenshotPlugin/Core/SvgImage.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/Core/WindowCapture.cs b/GreenshotPlugin/Core/WindowCapture.cs
index 7d2c9e4d3..828851444 100644
--- a/GreenshotPlugin/Core/WindowCapture.cs
+++ b/GreenshotPlugin/Core/WindowCapture.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
@@ -305,7 +305,7 @@ namespace GreenshotPlugin.Core {
}
// get a .NET image object for it
- // A suggestion for the "A generic error occurred in GDI+." E_FAIL/080004005 error is to re-try...
+ // A suggestion for the "A generic error occurred in GDI+." E_FAIL/0�80004005 error is to re-try...
bool success = false;
ExternalException exception = null;
for (int i = 0; i < 3; i++) {
diff --git a/GreenshotPlugin/Core/WindowDetails.cs b/GreenshotPlugin/Core/WindowDetails.cs
index 4fff18959..0410d79c7 100644
--- a/GreenshotPlugin/Core/WindowDetails.cs
+++ b/GreenshotPlugin/Core/WindowDetails.cs
@@ -196,33 +196,33 @@ namespace GreenshotPlugin.Core
///
/// Get the icon for a hWnd
///
- ///
+ ///
///
- private static Icon GetAppIcon(IntPtr hwnd) {
+ private static Icon GetAppIcon(IntPtr hWnd) {
IntPtr iconSmall = IntPtr.Zero;
IntPtr iconBig = new IntPtr(1);
IntPtr iconSmall2 = new IntPtr(2);
IntPtr iconHandle;
if (Conf.UseLargeIcons) {
- iconHandle = User32.SendMessage(hwnd, (int)WindowsMessages.WM_GETICON, iconBig, IntPtr.Zero);
+ iconHandle = User32.SendMessage(hWnd, (int)WindowsMessages.WM_GETICON, iconBig, IntPtr.Zero);
if (iconHandle == IntPtr.Zero) {
- iconHandle = User32.GetClassLongWrapper(hwnd, (int)ClassLongIndex.GCL_HICON);
+ iconHandle = User32.GetClassLongWrapper(hWnd, (int)ClassLongIndex.GCL_HICON);
}
} else {
- iconHandle = User32.SendMessage(hwnd, (int)WindowsMessages.WM_GETICON, iconSmall2, IntPtr.Zero);
+ iconHandle = User32.SendMessage(hWnd, (int)WindowsMessages.WM_GETICON, iconSmall2, IntPtr.Zero);
}
if (iconHandle == IntPtr.Zero) {
- iconHandle = User32.SendMessage(hwnd, (int)WindowsMessages.WM_GETICON, iconSmall, IntPtr.Zero);
+ iconHandle = User32.SendMessage(hWnd, (int)WindowsMessages.WM_GETICON, iconSmall, IntPtr.Zero);
}
if (iconHandle == IntPtr.Zero) {
- iconHandle = User32.GetClassLongWrapper(hwnd, (int)ClassLongIndex.GCL_HICONSM);
+ iconHandle = User32.GetClassLongWrapper(hWnd, (int)ClassLongIndex.GCL_HICONSM);
}
if (iconHandle == IntPtr.Zero) {
- iconHandle = User32.SendMessage(hwnd, (int)WindowsMessages.WM_GETICON, iconBig, IntPtr.Zero);
+ iconHandle = User32.SendMessage(hWnd, (int)WindowsMessages.WM_GETICON, iconBig, IntPtr.Zero);
}
if (iconHandle == IntPtr.Zero) {
- iconHandle = User32.GetClassLongWrapper(hwnd, (int)ClassLongIndex.GCL_HICON);
+ iconHandle = User32.GetClassLongWrapper(hWnd, (int)ClassLongIndex.GCL_HICON);
}
if (iconHandle == IntPtr.Zero) {
diff --git a/GreenshotPlugin/Core/WindowsEnumerator.cs b/GreenshotPlugin/Core/WindowsEnumerator.cs
index 2df7fce54..3bc1095a5 100644
--- a/GreenshotPlugin/Core/WindowsEnumerator.cs
+++ b/GreenshotPlugin/Core/WindowsEnumerator.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/Core/WmInputLangChangeRequestFilter.cs b/GreenshotPlugin/Core/WmInputLangChangeRequestFilter.cs
index 755854616..e48062f57 100644
--- a/GreenshotPlugin/Core/WmInputLangChangeRequestFilter.cs
+++ b/GreenshotPlugin/Core/WmInputLangChangeRequestFilter.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/Effects/AdjustEffect.cs b/GreenshotPlugin/Effects/AdjustEffect.cs
index a3a542c53..a01dd16d2 100644
--- a/GreenshotPlugin/Effects/AdjustEffect.cs
+++ b/GreenshotPlugin/Effects/AdjustEffect.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/Effects/BorderEffect.cs b/GreenshotPlugin/Effects/BorderEffect.cs
index 32822f4a9..4e45f920c 100644
--- a/GreenshotPlugin/Effects/BorderEffect.cs
+++ b/GreenshotPlugin/Effects/BorderEffect.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/Effects/DropShadowEffect.cs b/GreenshotPlugin/Effects/DropShadowEffect.cs
index b1f23bf1e..5f05b889f 100644
--- a/GreenshotPlugin/Effects/DropShadowEffect.cs
+++ b/GreenshotPlugin/Effects/DropShadowEffect.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/Effects/GrayscaleEffect.cs b/GreenshotPlugin/Effects/GrayscaleEffect.cs
index 8210be695..7c8e5c7b2 100644
--- a/GreenshotPlugin/Effects/GrayscaleEffect.cs
+++ b/GreenshotPlugin/Effects/GrayscaleEffect.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/Effects/IEffect.cs b/GreenshotPlugin/Effects/IEffect.cs
index aee145ea4..1beeb1aa5 100644
--- a/GreenshotPlugin/Effects/IEffect.cs
+++ b/GreenshotPlugin/Effects/IEffect.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/Effects/InvertEffect.cs b/GreenshotPlugin/Effects/InvertEffect.cs
index 64f44c4c6..f890f5dd5 100644
--- a/GreenshotPlugin/Effects/InvertEffect.cs
+++ b/GreenshotPlugin/Effects/InvertEffect.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/Effects/MonochromeEffect.cs b/GreenshotPlugin/Effects/MonochromeEffect.cs
index 4ee358cba..8e0b69c7b 100644
--- a/GreenshotPlugin/Effects/MonochromeEffect.cs
+++ b/GreenshotPlugin/Effects/MonochromeEffect.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/Effects/ReduceColorsEffect.cs b/GreenshotPlugin/Effects/ReduceColorsEffect.cs
index c82b10e71..a432850b6 100644
--- a/GreenshotPlugin/Effects/ReduceColorsEffect.cs
+++ b/GreenshotPlugin/Effects/ReduceColorsEffect.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/Effects/ResizeCanvasEffect.cs b/GreenshotPlugin/Effects/ResizeCanvasEffect.cs
index 750dc41ea..67bbf6e7d 100644
--- a/GreenshotPlugin/Effects/ResizeCanvasEffect.cs
+++ b/GreenshotPlugin/Effects/ResizeCanvasEffect.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/Effects/ResizeEffect.cs b/GreenshotPlugin/Effects/ResizeEffect.cs
index 528d1a0dc..38f997f71 100644
--- a/GreenshotPlugin/Effects/ResizeEffect.cs
+++ b/GreenshotPlugin/Effects/ResizeEffect.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/Effects/RotateEffect.cs b/GreenshotPlugin/Effects/RotateEffect.cs
index dedab9a34..772a41a6a 100644
--- a/GreenshotPlugin/Effects/RotateEffect.cs
+++ b/GreenshotPlugin/Effects/RotateEffect.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/Effects/TornEdgeEffect.cs b/GreenshotPlugin/Effects/TornEdgeEffect.cs
index dbd5f5120..682435132 100644
--- a/GreenshotPlugin/Effects/TornEdgeEffect.cs
+++ b/GreenshotPlugin/Effects/TornEdgeEffect.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/Hooking/WindowsEventHook.cs b/GreenshotPlugin/Hooking/WindowsEventHook.cs
index 2b838008b..8893bd57e 100644
--- a/GreenshotPlugin/Hooking/WindowsEventHook.cs
+++ b/GreenshotPlugin/Hooking/WindowsEventHook.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
@@ -39,12 +39,12 @@ namespace GreenshotPlugin.Hooking
/// Used with Register hook
///
///
- ///
+ ///
///
///
///
///
- public delegate void WinEventHandler(WinEvent eventType, IntPtr hwnd, EventObjects idObject, int idChild, uint dwEventThread, uint dwmsEventTime);
+ public delegate void WinEventHandler(WinEvent eventType, IntPtr hWnd, EventObjects idObject, int idChild, uint dwEventThread, uint dwmsEventTime);
///
/// Create a WindowsEventHook object
@@ -65,12 +65,12 @@ namespace GreenshotPlugin.Hooking
///
///
///
- ///
+ ///
///
///
///
///
- private delegate void WinEventDelegate(IntPtr hWinEventHook, WinEvent eventType, IntPtr hwnd, EventObjects idObject, int idChild, uint dwEventThread, uint dwmsEventTime);
+ private delegate void WinEventDelegate(IntPtr hWinEventHook, WinEvent eventType, IntPtr hWnd, EventObjects idObject, int idChild, uint dwEventThread, uint dwmsEventTime);
private readonly IDictionary _winEventHandlers = new Dictionary();
diff --git a/GreenshotPlugin/Hooking/WindowsOpenCloseMonitor.cs b/GreenshotPlugin/Hooking/WindowsOpenCloseMonitor.cs
index e62cdf89a..97634b92f 100644
--- a/GreenshotPlugin/Hooking/WindowsOpenCloseMonitor.cs
+++ b/GreenshotPlugin/Hooking/WindowsOpenCloseMonitor.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/Hooking/WindowsTitleMonitor.cs b/GreenshotPlugin/Hooking/WindowsTitleMonitor.cs
index 2fbda9dce..c35dbf2e8 100644
--- a/GreenshotPlugin/Hooking/WindowsTitleMonitor.cs
+++ b/GreenshotPlugin/Hooking/WindowsTitleMonitor.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/IEInterop/IHTMLBodyElement.cs b/GreenshotPlugin/IEInterop/IHTMLBodyElement.cs
index fb344f237..0890cc628 100644
--- a/GreenshotPlugin/IEInterop/IHTMLBodyElement.cs
+++ b/GreenshotPlugin/IEInterop/IHTMLBodyElement.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/IEInterop/IHTMLCurrentStyle.cs b/GreenshotPlugin/IEInterop/IHTMLCurrentStyle.cs
index 4de30a205..cfbab4b3f 100644
--- a/GreenshotPlugin/IEInterop/IHTMLCurrentStyle.cs
+++ b/GreenshotPlugin/IEInterop/IHTMLCurrentStyle.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/IEInterop/IHTMLDocument.cs b/GreenshotPlugin/IEInterop/IHTMLDocument.cs
index 79f2b622a..5faeda803 100644
--- a/GreenshotPlugin/IEInterop/IHTMLDocument.cs
+++ b/GreenshotPlugin/IEInterop/IHTMLDocument.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/IEInterop/IHTMLDocument2.cs b/GreenshotPlugin/IEInterop/IHTMLDocument2.cs
index 2e0ab177f..6ca8d9c9b 100644
--- a/GreenshotPlugin/IEInterop/IHTMLDocument2.cs
+++ b/GreenshotPlugin/IEInterop/IHTMLDocument2.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/IEInterop/IHTMLDocument3.cs b/GreenshotPlugin/IEInterop/IHTMLDocument3.cs
index 74af3d8c9..e12344f62 100644
--- a/GreenshotPlugin/IEInterop/IHTMLDocument3.cs
+++ b/GreenshotPlugin/IEInterop/IHTMLDocument3.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/IEInterop/IHTMLDocument4.cs b/GreenshotPlugin/IEInterop/IHTMLDocument4.cs
index 308243eff..57e4a32ee 100644
--- a/GreenshotPlugin/IEInterop/IHTMLDocument4.cs
+++ b/GreenshotPlugin/IEInterop/IHTMLDocument4.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/IEInterop/IHTMLDocument5.cs b/GreenshotPlugin/IEInterop/IHTMLDocument5.cs
index 574edbefe..60b5aab8c 100644
--- a/GreenshotPlugin/IEInterop/IHTMLDocument5.cs
+++ b/GreenshotPlugin/IEInterop/IHTMLDocument5.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/IEInterop/IHTMLElement.cs b/GreenshotPlugin/IEInterop/IHTMLElement.cs
index a7fcae716..aa0a54b79 100644
--- a/GreenshotPlugin/IEInterop/IHTMLElement.cs
+++ b/GreenshotPlugin/IEInterop/IHTMLElement.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/IEInterop/IHTMLElement2.cs b/GreenshotPlugin/IEInterop/IHTMLElement2.cs
index a6d258b06..44ace8d30 100644
--- a/GreenshotPlugin/IEInterop/IHTMLElement2.cs
+++ b/GreenshotPlugin/IEInterop/IHTMLElement2.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/IEInterop/IHTMLElementCollection.cs b/GreenshotPlugin/IEInterop/IHTMLElementCollection.cs
index 3901edc30..d9a7211dc 100644
--- a/GreenshotPlugin/IEInterop/IHTMLElementCollection.cs
+++ b/GreenshotPlugin/IEInterop/IHTMLElementCollection.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/IEInterop/IHTMLFrameBase.cs b/GreenshotPlugin/IEInterop/IHTMLFrameBase.cs
index ac26be320..d9566c0cc 100644
--- a/GreenshotPlugin/IEInterop/IHTMLFrameBase.cs
+++ b/GreenshotPlugin/IEInterop/IHTMLFrameBase.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/IEInterop/IHTMLFramesCollection2.cs b/GreenshotPlugin/IEInterop/IHTMLFramesCollection2.cs
index 731ff60a4..2c651db26 100644
--- a/GreenshotPlugin/IEInterop/IHTMLFramesCollection2.cs
+++ b/GreenshotPlugin/IEInterop/IHTMLFramesCollection2.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/IEInterop/IHTMLRect.cs b/GreenshotPlugin/IEInterop/IHTMLRect.cs
index ae398299b..c2d6d375a 100644
--- a/GreenshotPlugin/IEInterop/IHTMLRect.cs
+++ b/GreenshotPlugin/IEInterop/IHTMLRect.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/IEInterop/IHTMLScreen.cs b/GreenshotPlugin/IEInterop/IHTMLScreen.cs
index 97f87124e..f65b77da7 100644
--- a/GreenshotPlugin/IEInterop/IHTMLScreen.cs
+++ b/GreenshotPlugin/IEInterop/IHTMLScreen.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/IEInterop/IHTMLScreen2.cs b/GreenshotPlugin/IEInterop/IHTMLScreen2.cs
index e3c6fb5d2..3814da360 100644
--- a/GreenshotPlugin/IEInterop/IHTMLScreen2.cs
+++ b/GreenshotPlugin/IEInterop/IHTMLScreen2.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/IEInterop/IHTMLSelectionObject.cs b/GreenshotPlugin/IEInterop/IHTMLSelectionObject.cs
index ac618945b..fadb35ca0 100644
--- a/GreenshotPlugin/IEInterop/IHTMLSelectionObject.cs
+++ b/GreenshotPlugin/IEInterop/IHTMLSelectionObject.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/IEInterop/IHTMLStyle.cs b/GreenshotPlugin/IEInterop/IHTMLStyle.cs
index 5541f0541..43d10fa84 100644
--- a/GreenshotPlugin/IEInterop/IHTMLStyle.cs
+++ b/GreenshotPlugin/IEInterop/IHTMLStyle.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/IEInterop/IHTMLTxtRange.cs b/GreenshotPlugin/IEInterop/IHTMLTxtRange.cs
index c45d4313b..f9ff8d690 100644
--- a/GreenshotPlugin/IEInterop/IHTMLTxtRange.cs
+++ b/GreenshotPlugin/IEInterop/IHTMLTxtRange.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/IEInterop/IHTMLWindow2.cs b/GreenshotPlugin/IEInterop/IHTMLWindow2.cs
index c8846dfb4..02b2a756c 100644
--- a/GreenshotPlugin/IEInterop/IHTMLWindow2.cs
+++ b/GreenshotPlugin/IEInterop/IHTMLWindow2.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/IEInterop/IHTMLWindow3.cs b/GreenshotPlugin/IEInterop/IHTMLWindow3.cs
index 6363d31ac..f3c872f5a 100644
--- a/GreenshotPlugin/IEInterop/IHTMLWindow3.cs
+++ b/GreenshotPlugin/IEInterop/IHTMLWindow3.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/IEInterop/IHTMLWindow4.cs b/GreenshotPlugin/IEInterop/IHTMLWindow4.cs
index b267901a7..8643c88c1 100644
--- a/GreenshotPlugin/IEInterop/IHTMLWindow4.cs
+++ b/GreenshotPlugin/IEInterop/IHTMLWindow4.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/IEInterop/IWebBrowser2.cs b/GreenshotPlugin/IEInterop/IWebBrowser2.cs
index 42b6c3fc1..36b06d6e4 100644
--- a/GreenshotPlugin/IEInterop/IWebBrowser2.cs
+++ b/GreenshotPlugin/IEInterop/IWebBrowser2.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/IniFile/IniAttributes.cs b/GreenshotPlugin/IniFile/IniAttributes.cs
index 611661586..0b23b679e 100644
--- a/GreenshotPlugin/IniFile/IniAttributes.cs
+++ b/GreenshotPlugin/IniFile/IniAttributes.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/IniFile/IniConfig.cs b/GreenshotPlugin/IniFile/IniConfig.cs
index 7981712f6..5ea33f6df 100644
--- a/GreenshotPlugin/IniFile/IniConfig.cs
+++ b/GreenshotPlugin/IniFile/IniConfig.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/IniFile/IniReader.cs b/GreenshotPlugin/IniFile/IniReader.cs
index 6e399ab5e..641b5414e 100644
--- a/GreenshotPlugin/IniFile/IniReader.cs
+++ b/GreenshotPlugin/IniFile/IniReader.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/IniFile/IniSection.cs b/GreenshotPlugin/IniFile/IniSection.cs
index 5022f5ab0..c8c9221dd 100644
--- a/GreenshotPlugin/IniFile/IniSection.cs
+++ b/GreenshotPlugin/IniFile/IniSection.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/IniFile/IniValue.cs b/GreenshotPlugin/IniFile/IniValue.cs
index 9a39ce995..de04c0b44 100644
--- a/GreenshotPlugin/IniFile/IniValue.cs
+++ b/GreenshotPlugin/IniFile/IniValue.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/Interfaces/CaptureMode.cs b/GreenshotPlugin/Interfaces/CaptureMode.cs
index a0aef56c4..8c9c9e268 100644
--- a/GreenshotPlugin/Interfaces/CaptureMode.cs
+++ b/GreenshotPlugin/Interfaces/CaptureMode.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/Interfaces/Drawing/Adorners/IAdorner.cs b/GreenshotPlugin/Interfaces/Drawing/Adorners/IAdorner.cs
index 5d729376c..db5319e2c 100644
--- a/GreenshotPlugin/Interfaces/Drawing/Adorners/IAdorner.cs
+++ b/GreenshotPlugin/Interfaces/Drawing/Adorners/IAdorner.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on Sourceforge: http://sourceforge.net/projects/greenshot/
diff --git a/GreenshotPlugin/Interfaces/Drawing/Container.cs b/GreenshotPlugin/Interfaces/Drawing/Container.cs
index 0044a0bb0..a97ff5ffc 100644
--- a/GreenshotPlugin/Interfaces/Drawing/Container.cs
+++ b/GreenshotPlugin/Interfaces/Drawing/Container.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/Interfaces/Drawing/IField.cs b/GreenshotPlugin/Interfaces/Drawing/IField.cs
index 54d083a3a..97c13c2d9 100644
--- a/GreenshotPlugin/Interfaces/Drawing/IField.cs
+++ b/GreenshotPlugin/Interfaces/Drawing/IField.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/Interfaces/Drawing/IFieldholder.cs b/GreenshotPlugin/Interfaces/Drawing/IFieldholder.cs
index fc10175c2..c67303ffb 100644
--- a/GreenshotPlugin/Interfaces/Drawing/IFieldholder.cs
+++ b/GreenshotPlugin/Interfaces/Drawing/IFieldholder.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/Interfaces/Drawing/IMemento.cs b/GreenshotPlugin/Interfaces/Drawing/IMemento.cs
index 40e1ab61c..bb64237fe 100644
--- a/GreenshotPlugin/Interfaces/Drawing/IMemento.cs
+++ b/GreenshotPlugin/Interfaces/Drawing/IMemento.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/Interfaces/DrawingModes.cs b/GreenshotPlugin/Interfaces/DrawingModes.cs
index 9ada15b2d..e6d25a359 100644
--- a/GreenshotPlugin/Interfaces/DrawingModes.cs
+++ b/GreenshotPlugin/Interfaces/DrawingModes.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/Interfaces/Forms/ImageEditor.cs b/GreenshotPlugin/Interfaces/Forms/ImageEditor.cs
index b499231a3..bd42b9aca 100644
--- a/GreenshotPlugin/Interfaces/Forms/ImageEditor.cs
+++ b/GreenshotPlugin/Interfaces/Forms/ImageEditor.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/Interfaces/ICapture.cs b/GreenshotPlugin/Interfaces/ICapture.cs
index 231af2d08..24f67a9f0 100644
--- a/GreenshotPlugin/Interfaces/ICapture.cs
+++ b/GreenshotPlugin/Interfaces/ICapture.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/Interfaces/ICaptureDetails.cs b/GreenshotPlugin/Interfaces/ICaptureDetails.cs
index 055cd598b..c475283da 100644
--- a/GreenshotPlugin/Interfaces/ICaptureDetails.cs
+++ b/GreenshotPlugin/Interfaces/ICaptureDetails.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/Interfaces/ICaptureElement.cs b/GreenshotPlugin/Interfaces/ICaptureElement.cs
index 36c0bbc72..fc84c1536 100644
--- a/GreenshotPlugin/Interfaces/ICaptureElement.cs
+++ b/GreenshotPlugin/Interfaces/ICaptureElement.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/Interfaces/IDestination.cs b/GreenshotPlugin/Interfaces/IDestination.cs
index e4f39d796..8bfb72ac3 100644
--- a/GreenshotPlugin/Interfaces/IDestination.cs
+++ b/GreenshotPlugin/Interfaces/IDestination.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/Interfaces/INotificationService.cs b/GreenshotPlugin/Interfaces/INotificationService.cs
index c1342b5e4..43980a8e2 100644
--- a/GreenshotPlugin/Interfaces/INotificationService.cs
+++ b/GreenshotPlugin/Interfaces/INotificationService.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/Interfaces/IProcessor.cs b/GreenshotPlugin/Interfaces/IProcessor.cs
index 927933abf..d5f4c0ba8 100644
--- a/GreenshotPlugin/Interfaces/IProcessor.cs
+++ b/GreenshotPlugin/Interfaces/IProcessor.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/Interfaces/ISurface.cs b/GreenshotPlugin/Interfaces/ISurface.cs
index 068ab0f29..d6928b87e 100644
--- a/GreenshotPlugin/Interfaces/ISurface.cs
+++ b/GreenshotPlugin/Interfaces/ISurface.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/Interfaces/Ocr/IOcrProvider.cs b/GreenshotPlugin/Interfaces/Ocr/IOcrProvider.cs
index 451ffb403..4a9fd657e 100644
--- a/GreenshotPlugin/Interfaces/Ocr/IOcrProvider.cs
+++ b/GreenshotPlugin/Interfaces/Ocr/IOcrProvider.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/Interfaces/Plugin/PluginAttribute.cs b/GreenshotPlugin/Interfaces/Plugin/PluginAttribute.cs
index 73fa60653..c44d7f120 100644
--- a/GreenshotPlugin/Interfaces/Plugin/PluginAttribute.cs
+++ b/GreenshotPlugin/Interfaces/Plugin/PluginAttribute.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/Interfaces/ScreenCaptureMode.cs b/GreenshotPlugin/Interfaces/ScreenCaptureMode.cs
index 0a03f74c8..bdcc14d81 100644
--- a/GreenshotPlugin/Interfaces/ScreenCaptureMode.cs
+++ b/GreenshotPlugin/Interfaces/ScreenCaptureMode.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/Interfaces/SurfaceDrawingModeEventArgs.cs b/GreenshotPlugin/Interfaces/SurfaceDrawingModeEventArgs.cs
index cfc4f040a..b30a68828 100644
--- a/GreenshotPlugin/Interfaces/SurfaceDrawingModeEventArgs.cs
+++ b/GreenshotPlugin/Interfaces/SurfaceDrawingModeEventArgs.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/Interfaces/SurfaceDrawingModeEventHandler.cs b/GreenshotPlugin/Interfaces/SurfaceDrawingModeEventHandler.cs
index bada273cf..5582f77d3 100644
--- a/GreenshotPlugin/Interfaces/SurfaceDrawingModeEventHandler.cs
+++ b/GreenshotPlugin/Interfaces/SurfaceDrawingModeEventHandler.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/Interfaces/SurfaceElementEventArgs.cs b/GreenshotPlugin/Interfaces/SurfaceElementEventArgs.cs
index 296ca1a08..f53241447 100644
--- a/GreenshotPlugin/Interfaces/SurfaceElementEventArgs.cs
+++ b/GreenshotPlugin/Interfaces/SurfaceElementEventArgs.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/Interfaces/SurfaceElementEventHandler.cs b/GreenshotPlugin/Interfaces/SurfaceElementEventHandler.cs
index 1ae41be70..eef546545 100644
--- a/GreenshotPlugin/Interfaces/SurfaceElementEventHandler.cs
+++ b/GreenshotPlugin/Interfaces/SurfaceElementEventHandler.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/Interfaces/SurfaceMessageEventArgs.cs b/GreenshotPlugin/Interfaces/SurfaceMessageEventArgs.cs
index 44273f810..2908e9ffb 100644
--- a/GreenshotPlugin/Interfaces/SurfaceMessageEventArgs.cs
+++ b/GreenshotPlugin/Interfaces/SurfaceMessageEventArgs.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/Interfaces/SurfaceMessageEventHandler.cs b/GreenshotPlugin/Interfaces/SurfaceMessageEventHandler.cs
index 72ffa01a0..1bea86b37 100644
--- a/GreenshotPlugin/Interfaces/SurfaceMessageEventHandler.cs
+++ b/GreenshotPlugin/Interfaces/SurfaceMessageEventHandler.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/Interfaces/SurfaceMessageTyp.cs b/GreenshotPlugin/Interfaces/SurfaceMessageTyp.cs
index abae0d6f1..84efe7609 100644
--- a/GreenshotPlugin/Interfaces/SurfaceMessageTyp.cs
+++ b/GreenshotPlugin/Interfaces/SurfaceMessageTyp.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/Interfaces/SurfaceSizeChangeEventHandler.cs b/GreenshotPlugin/Interfaces/SurfaceSizeChangeEventHandler.cs
index 5f2dd1245..f9fe667f3 100644
--- a/GreenshotPlugin/Interfaces/SurfaceSizeChangeEventHandler.cs
+++ b/GreenshotPlugin/Interfaces/SurfaceSizeChangeEventHandler.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/Interfaces/VerticalAlignment.cs b/GreenshotPlugin/Interfaces/VerticalAlignment.cs
index 59e77f35e..f5cb71f0f 100644
--- a/GreenshotPlugin/Interfaces/VerticalAlignment.cs
+++ b/GreenshotPlugin/Interfaces/VerticalAlignment.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/Interop/COMWrapper.cs b/GreenshotPlugin/Interop/COMWrapper.cs
index 0a0dee361..f31392124 100644
--- a/GreenshotPlugin/Interop/COMWrapper.cs
+++ b/GreenshotPlugin/Interop/COMWrapper.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/Interop/ComProgIdAttribute.cs b/GreenshotPlugin/Interop/ComProgIdAttribute.cs
index 9138c1ce6..ed88fa7be 100644
--- a/GreenshotPlugin/Interop/ComProgIdAttribute.cs
+++ b/GreenshotPlugin/Interop/ComProgIdAttribute.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/Interop/IAppVisibility.cs b/GreenshotPlugin/Interop/IAppVisibility.cs
index ed6ceaf1f..2feb78b76 100644
--- a/GreenshotPlugin/Interop/IAppVisibility.cs
+++ b/GreenshotPlugin/Interop/IAppVisibility.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/Interop/IDispatch.cs b/GreenshotPlugin/Interop/IDispatch.cs
index eb9f4c918..b4391c621 100644
--- a/GreenshotPlugin/Interop/IDispatch.cs
+++ b/GreenshotPlugin/Interop/IDispatch.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/Interop/IOleCommandTarget.cs b/GreenshotPlugin/Interop/IOleCommandTarget.cs
index 3bab1bb5c..6207d196e 100644
--- a/GreenshotPlugin/Interop/IOleCommandTarget.cs
+++ b/GreenshotPlugin/Interop/IOleCommandTarget.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/Interop/IOleWindow.cs b/GreenshotPlugin/Interop/IOleWindow.cs
index 650bf6100..c5361dc0d 100644
--- a/GreenshotPlugin/Interop/IOleWindow.cs
+++ b/GreenshotPlugin/Interop/IOleWindow.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
@@ -27,7 +27,7 @@ namespace GreenshotPlugin.Interop {
// See: http://msdn.microsoft.com/en-us/library/ms680102%28v=vs.85%29.aspx
[ComImport, Guid("00000114-0000-0000-C000-000000000046"), InterfaceType(ComInterfaceType.InterfaceIsIUnknown)]
public interface IOleWindow {
- void GetWindow(out IntPtr phwnd);
+ void GetWindow(out IntPtr phWnd);
void ContextSensitiveHelp([In, MarshalAs(UnmanagedType.Bool)] bool fEnterMode);
}
}
diff --git a/GreenshotPlugin/Interop/IServiceProvider.cs b/GreenshotPlugin/Interop/IServiceProvider.cs
index ea6a7d437..d058f81c3 100644
--- a/GreenshotPlugin/Interop/IServiceProvider.cs
+++ b/GreenshotPlugin/Interop/IServiceProvider.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/Interop/IUnknown.cs b/GreenshotPlugin/Interop/IUnknown.cs
index 323bbafa3..bee0da243 100644
--- a/GreenshotPlugin/Interop/IUnknown.cs
+++ b/GreenshotPlugin/Interop/IUnknown.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/UnmanagedHelpers/DWM.cs b/GreenshotPlugin/UnmanagedHelpers/DWM.cs
index 0a801fe57..bc17f3ab2 100644
--- a/GreenshotPlugin/UnmanagedHelpers/DWM.cs
+++ b/GreenshotPlugin/UnmanagedHelpers/DWM.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/UnmanagedHelpers/EnumWindowsProc.cs b/GreenshotPlugin/UnmanagedHelpers/EnumWindowsProc.cs
index fdec7c001..db0185e07 100644
--- a/GreenshotPlugin/UnmanagedHelpers/EnumWindowsProc.cs
+++ b/GreenshotPlugin/UnmanagedHelpers/EnumWindowsProc.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/UnmanagedHelpers/Enums/DWMWINDOWATTRIBUTE.cs b/GreenshotPlugin/UnmanagedHelpers/Enums/DWMWINDOWATTRIBUTE.cs
index 0a8491806..e58bde613 100644
--- a/GreenshotPlugin/UnmanagedHelpers/Enums/DWMWINDOWATTRIBUTE.cs
+++ b/GreenshotPlugin/UnmanagedHelpers/Enums/DWMWINDOWATTRIBUTE.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/UnmanagedHelpers/Enums/DWM_BB.cs b/GreenshotPlugin/UnmanagedHelpers/Enums/DWM_BB.cs
index c794d251c..1541e9143 100644
--- a/GreenshotPlugin/UnmanagedHelpers/Enums/DWM_BB.cs
+++ b/GreenshotPlugin/UnmanagedHelpers/Enums/DWM_BB.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/UnmanagedHelpers/Enums/DWM_BLURBEHIND.cs b/GreenshotPlugin/UnmanagedHelpers/Enums/DWM_BLURBEHIND.cs
index f5629d9b4..29180d445 100644
--- a/GreenshotPlugin/UnmanagedHelpers/Enums/DWM_BLURBEHIND.cs
+++ b/GreenshotPlugin/UnmanagedHelpers/Enums/DWM_BLURBEHIND.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/UnmanagedHelpers/Enums/DWM_THUMBNAIL_PROPERTIES.cs b/GreenshotPlugin/UnmanagedHelpers/Enums/DWM_THUMBNAIL_PROPERTIES.cs
index 73dee612b..e442abfd5 100644
--- a/GreenshotPlugin/UnmanagedHelpers/Enums/DWM_THUMBNAIL_PROPERTIES.cs
+++ b/GreenshotPlugin/UnmanagedHelpers/Enums/DWM_THUMBNAIL_PROPERTIES.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/UnmanagedHelpers/Enums/SYSCOLOR.cs b/GreenshotPlugin/UnmanagedHelpers/Enums/SYSCOLOR.cs
index a6c535462..7d6802081 100644
--- a/GreenshotPlugin/UnmanagedHelpers/Enums/SYSCOLOR.cs
+++ b/GreenshotPlugin/UnmanagedHelpers/Enums/SYSCOLOR.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/UnmanagedHelpers/Enums/WindowStyleFlags.cs b/GreenshotPlugin/UnmanagedHelpers/Enums/WindowStyleFlags.cs
index 5082f7e0b..b0045e3e5 100644
--- a/GreenshotPlugin/UnmanagedHelpers/Enums/WindowStyleFlags.cs
+++ b/GreenshotPlugin/UnmanagedHelpers/Enums/WindowStyleFlags.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/UnmanagedHelpers/GDI32.cs b/GreenshotPlugin/UnmanagedHelpers/GDI32.cs
index ed064e835..72f863e1a 100644
--- a/GreenshotPlugin/UnmanagedHelpers/GDI32.cs
+++ b/GreenshotPlugin/UnmanagedHelpers/GDI32.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/UnmanagedHelpers/GDIplus.cs b/GreenshotPlugin/UnmanagedHelpers/GDIplus.cs
index e0bbed83c..c8caf7700 100644
--- a/GreenshotPlugin/UnmanagedHelpers/GDIplus.cs
+++ b/GreenshotPlugin/UnmanagedHelpers/GDIplus.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/UnmanagedHelpers/Kernel32.cs b/GreenshotPlugin/UnmanagedHelpers/Kernel32.cs
index c877db6dd..9734806a1 100644
--- a/GreenshotPlugin/UnmanagedHelpers/Kernel32.cs
+++ b/GreenshotPlugin/UnmanagedHelpers/Kernel32.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/UnmanagedHelpers/PsAPI.cs b/GreenshotPlugin/UnmanagedHelpers/PsAPI.cs
index 94e230a57..8b77f8d97 100644
--- a/GreenshotPlugin/UnmanagedHelpers/PsAPI.cs
+++ b/GreenshotPlugin/UnmanagedHelpers/PsAPI.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/UnmanagedHelpers/Shell32.cs b/GreenshotPlugin/UnmanagedHelpers/Shell32.cs
index cd53741a0..e1b7ba0b0 100644
--- a/GreenshotPlugin/UnmanagedHelpers/Shell32.cs
+++ b/GreenshotPlugin/UnmanagedHelpers/Shell32.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/UnmanagedHelpers/Structs/SIZE.cs b/GreenshotPlugin/UnmanagedHelpers/Structs/SIZE.cs
index 2481a993c..be5d00bbc 100644
--- a/GreenshotPlugin/UnmanagedHelpers/Structs/SIZE.cs
+++ b/GreenshotPlugin/UnmanagedHelpers/Structs/SIZE.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/UnmanagedHelpers/User32.cs b/GreenshotPlugin/UnmanagedHelpers/User32.cs
index d6ae3acb1..8ba05f48f 100644
--- a/GreenshotPlugin/UnmanagedHelpers/User32.cs
+++ b/GreenshotPlugin/UnmanagedHelpers/User32.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
@@ -109,7 +109,7 @@ namespace GreenshotPlugin.UnmanagedHelpers {
public static extern bool IsIconic(IntPtr hWnd);
[DllImport("user32", SetLastError = true)]
[return: MarshalAs(UnmanagedType.Bool)]
- public static extern bool IsZoomed(IntPtr hwnd);
+ public static extern bool IsZoomed(IntPtr hWnd);
[DllImport("user32", CharSet = CharSet.Unicode, SetLastError = true)]
public static extern int GetClassName (IntPtr hWnd, StringBuilder lpClassName, int nMaxCount);
[DllImport("user32", SetLastError = true)]
@@ -118,7 +118,7 @@ namespace GreenshotPlugin.UnmanagedHelpers {
public static extern IntPtr GetClassLongPtr(IntPtr hWnd, int nIndex);
[DllImport("user32", SetLastError = true)]
[return: MarshalAs(UnmanagedType.Bool)]
- public static extern bool PrintWindow(IntPtr hwnd, IntPtr hDc, uint nFlags);
+ public static extern bool PrintWindow(IntPtr hWnd, IntPtr hDc, uint nFlags);
[DllImport("user32", CharSet=CharSet.Unicode, SetLastError=true)]
public static extern IntPtr SendMessage(IntPtr hWnd, uint wMsg, IntPtr wParam, IntPtr lParam);
[DllImport("user32", SetLastError = true)]
@@ -181,7 +181,7 @@ namespace GreenshotPlugin.UnmanagedHelpers {
[DllImport("user32", SetLastError = true, CharSet = CharSet.Unicode)]
public static extern IntPtr FindWindow(string lpClassName, string lpWindowName);
[DllImport("user32", SetLastError = true, CharSet = CharSet.Unicode)]
- public static extern IntPtr FindWindowEx(IntPtr hwndParent, IntPtr hwndChildAfter, string lpszClass, string lpszWindow);
+ public static extern IntPtr FindWindowEx(IntPtr hWndParent, IntPtr hWndChildAfter, string lpszClass, string lpszWindow);
/// uiFlags: 0 - Count of GDI objects
/// uiFlags: 1 - Count of USER objects
@@ -199,7 +199,7 @@ namespace GreenshotPlugin.UnmanagedHelpers {
[DllImport("user32", SetLastError = true)]
private static extern bool GetPhysicalCursorPos(out POINT cursorLocation);
[DllImport("user32", SetLastError=true)]
- public static extern int MapWindowPoints(IntPtr hwndFrom, IntPtr hwndTo, ref POINT lpPoints, [MarshalAs(UnmanagedType.U4)] int cPoints);
+ public static extern int MapWindowPoints(IntPtr hWndFrom, IntPtr hWndTo, ref POINT lpPoints, [MarshalAs(UnmanagedType.U4)] int cPoints);
[DllImport("user32", SetLastError = true)]
public static extern int GetSystemMetrics(SystemMetric index);
@@ -281,28 +281,28 @@ namespace GreenshotPlugin.UnmanagedHelpers {
///
/// Wrapper for the GetWindowLong which decides if the system is 64-bit or not and calls the right one.
///
- ///
+ ///
///
///
- public static long GetWindowLongWrapper(IntPtr hwnd, int nIndex) {
+ public static long GetWindowLongWrapper(IntPtr hWnd, int nIndex) {
if (IntPtr.Size == 8) {
- return GetWindowLongPtr(hwnd, nIndex).ToInt64();
+ return GetWindowLongPtr(hWnd, nIndex).ToInt64();
} else {
- return GetWindowLong(hwnd, nIndex);
+ return GetWindowLong(hWnd, nIndex);
}
}
///
/// Wrapper for the SetWindowLong which decides if the system is 64-bit or not and calls the right one.
///
- ///
+ ///
///
///
- public static void SetWindowLongWrapper(IntPtr hwnd, int nIndex, IntPtr styleFlags) {
+ public static void SetWindowLongWrapper(IntPtr hWnd, int nIndex, IntPtr styleFlags) {
if (IntPtr.Size == 8) {
- SetWindowLongPtr(hwnd, nIndex, styleFlags);
+ SetWindowLongPtr(hWnd, nIndex, styleFlags);
} else {
- SetWindowLong(hwnd, nIndex, styleFlags.ToInt32());
+ SetWindowLong(hWnd, nIndex, styleFlags.ToInt32());
}
}
diff --git a/GreenshotPlugin/UnmanagedHelpers/Win32.cs b/GreenshotPlugin/UnmanagedHelpers/Win32.cs
index 471f38049..77aaf2256 100644
--- a/GreenshotPlugin/UnmanagedHelpers/Win32.cs
+++ b/GreenshotPlugin/UnmanagedHelpers/Win32.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotPlugin/UnmanagedHelpers/WinEventDelegate.cs b/GreenshotPlugin/UnmanagedHelpers/WinEventDelegate.cs
index e285418e7..551b75410 100644
--- a/GreenshotPlugin/UnmanagedHelpers/WinEventDelegate.cs
+++ b/GreenshotPlugin/UnmanagedHelpers/WinEventDelegate.cs
@@ -8,10 +8,10 @@ namespace GreenshotPlugin.UnmanagedHelpers
///
///
///
- ///
+ ///
///
///
///
///
- public delegate void WinEventDelegate(IntPtr hWinEventHook, WinEvent eventType, IntPtr hwnd, EventObjects idObject, int idChild, uint dwEventThread, uint dwmsEventTime);
+ public delegate void WinEventDelegate(IntPtr hWinEventHook, WinEvent eventType, IntPtr hWnd, EventObjects idObject, int idChild, uint dwEventThread, uint dwmsEventTime);
}
\ No newline at end of file
diff --git a/GreenshotPlugin/UnmanagedHelpers/WinMM.cs b/GreenshotPlugin/UnmanagedHelpers/WinMM.cs
index c2e46eaa7..71e8f6b7b 100644
--- a/GreenshotPlugin/UnmanagedHelpers/WinMM.cs
+++ b/GreenshotPlugin/UnmanagedHelpers/WinMM.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotWin10Plugin/Destinations/Win10OcrDestination.cs b/GreenshotWin10Plugin/Destinations/Win10OcrDestination.cs
index 617e18763..3bcad532d 100644
--- a/GreenshotWin10Plugin/Destinations/Win10OcrDestination.cs
+++ b/GreenshotWin10Plugin/Destinations/Win10OcrDestination.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotWin10Plugin/Destinations/Win10ShareDestination.cs b/GreenshotWin10Plugin/Destinations/Win10ShareDestination.cs
index a01ae2216..fb52ef925 100644
--- a/GreenshotWin10Plugin/Destinations/Win10ShareDestination.cs
+++ b/GreenshotWin10Plugin/Destinations/Win10ShareDestination.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotWin10Plugin/GreenshotWin10Plugin.csproj b/GreenshotWin10Plugin/GreenshotWin10Plugin.csproj
index 00229a0ab..2c8237637 100644
--- a/GreenshotWin10Plugin/GreenshotWin10Plugin.csproj
+++ b/GreenshotWin10Plugin/GreenshotWin10Plugin.csproj
@@ -12,7 +12,7 @@
-
+
diff --git a/GreenshotWin10Plugin/Internal/ShareInfo.cs b/GreenshotWin10Plugin/Internal/ShareInfo.cs
index 9b06d0d47..7516de371 100644
--- a/GreenshotWin10Plugin/Internal/ShareInfo.cs
+++ b/GreenshotWin10Plugin/Internal/ShareInfo.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotWin10Plugin/Native/GreenshotNotificationActivator.cs b/GreenshotWin10Plugin/Native/GreenshotNotificationActivator.cs
deleted file mode 100644
index a892e20f4..000000000
--- a/GreenshotWin10Plugin/Native/GreenshotNotificationActivator.cs
+++ /dev/null
@@ -1,44 +0,0 @@
-/*
- * Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
- *
- * For more information see: http://getgreenshot.org/
- * The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
- *
- * This program is free software: you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation, either version 1 of the License, or
- * (at your option) any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program. If not, see .
- */
-
-using System.Runtime.InteropServices;
-using log4net;
-using Microsoft.Toolkit.Uwp.Notifications;
-
-namespace GreenshotWin10Plugin.Native
-{
- ///
- /// This implements the NotificationActivator
- ///
- [ClassInterface(ClassInterfaceType.None)]
- [ComSourceInterfaces(typeof(NotificationActivator.INotificationActivationCallback))]
- [Guid("F48E86D3-E34C-4DB7-8F8F-9A0EA55F0D08"), ComVisible(true)]
- public class GreenshotNotificationActivator : NotificationActivator
- {
- private static readonly ILog Log = LogManager.GetLogger(typeof(GreenshotNotificationActivator));
-
- public override void OnActivated(string invokedArgs, NotificationUserInput userInput, string appUserModelId)
- {
- // TODO: Handle activation
- Log.Info("Activated");
- }
- }
-}
diff --git a/GreenshotWin10Plugin/Native/IDataTransferManagerInterOp.cs b/GreenshotWin10Plugin/Native/IDataTransferManagerInterOp.cs
index a4cef4ce4..14fb4c8eb 100644
--- a/GreenshotWin10Plugin/Native/IDataTransferManagerInterOp.cs
+++ b/GreenshotWin10Plugin/Native/IDataTransferManagerInterOp.cs
@@ -1,5 +1,5 @@
// Greenshot - a free and open source screenshot tool
-// Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+// Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
//
// For more information see: http://getgreenshot.org/
// The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotWin10Plugin/Processors/Win10OcrProcessor.cs b/GreenshotWin10Plugin/Processors/Win10OcrProcessor.cs
index 6cab7b81d..341153eab 100644
--- a/GreenshotWin10Plugin/Processors/Win10OcrProcessor.cs
+++ b/GreenshotWin10Plugin/Processors/Win10OcrProcessor.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
diff --git a/GreenshotWin10Plugin/ToastNotificationService.cs b/GreenshotWin10Plugin/ToastNotificationService.cs
index 4b41f6f61..e7c932ab7 100644
--- a/GreenshotWin10Plugin/ToastNotificationService.cs
+++ b/GreenshotWin10Plugin/ToastNotificationService.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
@@ -22,13 +22,12 @@
using System;
using System.Drawing.Imaging;
using System.IO;
-using System.Linq;
+using Windows.Foundation.Collections;
using Windows.Foundation.Metadata;
using Windows.UI.Notifications;
using GreenshotPlugin.Core;
using GreenshotPlugin.IniFile;
using GreenshotPlugin.Interfaces;
-using GreenshotWin10Plugin.Native;
using log4net;
using Microsoft.Toolkit.Uwp.Notifications;
@@ -45,10 +44,21 @@ namespace GreenshotWin10Plugin
private readonly string _imageFilePath;
public ToastNotificationService()
{
- // Register AUMID and COM server (for Desktop Bridge apps, this no-ops)
- DesktopNotificationManagerCompat.RegisterAumidAndComServer("Greenshot");
- // Register COM server and activator type
- DesktopNotificationManagerCompat.RegisterActivator();
+ if (ToastNotificationManagerCompat.WasCurrentProcessToastActivated())
+ {
+ Log.Info("Greenshot was activated due to a toast.");
+ }
+ // Listen to notification activation
+ ToastNotificationManagerCompat.OnActivated += toastArgs =>
+ {
+ // Obtain the arguments from the notification
+ ToastArguments args = ToastArguments.Parse(toastArgs.Argument);
+
+ // Obtain any user input (text boxes, menu selections) from the notification
+ ValueSet userInput = toastArgs.UserInput;
+
+ Log.Info("Toast activated. Args: " + toastArgs.Argument);
+ };
var localAppData = Path.Combine(Environment.GetFolderPath(Environment.SpecialFolder.LocalApplicationData), "Greenshot");
if (!Directory.Exists(localAppData))
@@ -81,7 +91,7 @@ namespace GreenshotWin10Plugin
return;
}
// Prepare the toast notifier. Be sure to specify the AppUserModelId on your application's shortcut!
- var toastNotifier = DesktopNotificationManagerCompat.CreateToastNotifier();
+ var toastNotifier = ToastNotificationManagerCompat.CreateToastNotifier();
// Here is an interesting article on reading the settings: https://www.rudyhuyn.com/blog/2018/02/10/toastnotifier-and-settings-careful-with-non-uwp-applications/
try
@@ -97,82 +107,62 @@ namespace GreenshotWin10Plugin
Log.Info("Ignoring exception as this means that there was no stored settings.");
}
- // Get a toast XML template
- var toastXml = ToastNotificationManager.GetTemplateContent(ToastTemplateType.ToastImageAndText01);
+ // Generate the toast and send it off
+ new ToastContentBuilder()
- // Fill in the text elements
- var stringElement = toastXml.GetElementsByTagName("text").First();
- stringElement.AppendChild(toastXml.CreateTextNode(message));
-
- if (_imageFilePath != null && File.Exists(_imageFilePath))
- {
- // Specify the absolute path to an image
- var imageElement = toastXml.GetElementsByTagName("image").First();
- var imageSrcNode = imageElement.Attributes.GetNamedItem("src");
- if (imageSrcNode != null)
+ .AddArgument("ToastID", 100)
+ // Inline image
+ .AddText(message)
+ // Profile (app logo override) image
+ //.AddAppLogoOverride(new Uri($@"file://{_imageFilePath}"), ToastGenericAppLogoCrop.None)
+ .Show(toast =>
{
- imageSrcNode.NodeValue = _imageFilePath;
- }
- }
+ // Windows 10 first with 1903: ExpiresOnReboot = true
+ toast.ExpirationTime = timeout.HasValue ? DateTimeOffset.Now.Add(timeout.Value) : (DateTimeOffset?) null;
+ void ToastActivatedHandler(ToastNotification toastNotification, object sender)
+ {
+ try
+ {
+ onClickAction?.Invoke();
+ }
+ catch (Exception ex)
+ {
+ Log.Warn("Exception while handling the onclick action: ", ex);
+ }
- // Create the toast and attach event listeners
- var toast = new ToastNotification(toastXml)
- {
- // Windows 10 first with 1903: ExpiresOnReboot = true,
- ExpirationTime = timeout.HasValue ? DateTimeOffset.Now.Add(timeout.Value) : (DateTimeOffset?)null
- };
+ toast.Activated -= ToastActivatedHandler;
+ }
- void ToastActivatedHandler(ToastNotification toastNotification, object sender)
- {
- try
- {
- onClickAction?.Invoke();
- }
- catch (Exception ex)
- {
- Log.Warn("Exception while handling the onclick action: ", ex);
- }
+ if (onClickAction != null)
+ {
+ toast.Activated += ToastActivatedHandler;
+ }
- toast.Activated -= ToastActivatedHandler;
- }
+ void ToastDismissedHandler(ToastNotification toastNotification, ToastDismissedEventArgs eventArgs)
+ {
+ Log.Debug($"Toast closed with reason {eventArgs.Reason}");
+ if (eventArgs.Reason != ToastDismissalReason.UserCanceled)
+ {
+ return;
+ }
+ try
+ {
+ onClosedAction?.Invoke();
+ }
+ catch (Exception ex)
+ {
+ Log.Warn("Exception while handling the onClosed action: ", ex);
+ }
- if (onClickAction != null)
- {
- toast.Activated += ToastActivatedHandler;
- }
+ toast.Dismissed -= ToastDismissedHandler;
+ // Remove the other handler too
+ toast.Activated -= ToastActivatedHandler;
+ toast.Failed -= ToastOnFailed;
- void ToastDismissedHandler(ToastNotification toastNotification, ToastDismissedEventArgs eventArgs)
- {
- Log.Debug($"Toast closed with reason {eventArgs.Reason}");
- if (eventArgs.Reason != ToastDismissalReason.UserCanceled)
- {
- return;
- }
- try
- {
- onClosedAction?.Invoke();
- }
- catch (Exception ex)
- {
- Log.Warn("Exception while handling the onClosed action: ", ex);
- }
-
- toast.Dismissed -= ToastDismissedHandler;
- // Remove the other handler too
- toast.Activated -= ToastActivatedHandler;
- toast.Failed -= ToastOnFailed;
-
- }
- toast.Dismissed += ToastDismissedHandler;
- toast.Failed += ToastOnFailed;
- try
- {
- toastNotifier.Show(toast);
- }
- catch (Exception ex)
- {
- Log.Error("Couldn't show notification.", ex);
- }
+ }
+ toast.Dismissed += ToastDismissedHandler;
+ toast.Failed += ToastOnFailed;
+ });
}
private void ToastOnFailed(ToastNotification sender, ToastFailedEventArgs args)
diff --git a/GreenshotWin10Plugin/Win10Configuration.cs b/GreenshotWin10Plugin/Win10Configuration.cs
index 642296e94..ba3091909 100644
--- a/GreenshotWin10Plugin/Win10Configuration.cs
+++ b/GreenshotWin10Plugin/Win10Configuration.cs
@@ -1,8 +1,9 @@
/*
- * A Picasa Plugin for Greenshot
- * Copyright (C) 2011 Francis Noel
+ * Greenshot - a free and open source screenshot tool
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
+ * The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
diff --git a/GreenshotWin10Plugin/Win10OcrProvider.cs b/GreenshotWin10Plugin/Win10OcrProvider.cs
index e8187b35e..81fd442e8 100644
--- a/GreenshotWin10Plugin/Win10OcrProvider.cs
+++ b/GreenshotWin10Plugin/Win10OcrProvider.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
@@ -115,7 +115,7 @@ namespace GreenshotWin10Plugin
///
/// OcrResult
/// OcrInformation
- private OcrInformation CreateOcrInformation(OcrResult ocrResult)
+ private static OcrInformation CreateOcrInformation(OcrResult ocrResult)
{
var result = new OcrInformation();
diff --git a/GreenshotWin10Plugin/Win10Plugin.cs b/GreenshotWin10Plugin/Win10Plugin.cs
index 53344f391..dc5190bbe 100644
--- a/GreenshotWin10Plugin/Win10Plugin.cs
+++ b/GreenshotWin10Plugin/Win10Plugin.cs
@@ -1,6 +1,6 @@
/*
* Greenshot - a free and open source screenshot tool
- * Copyright (C) 2007-2020 Thomas Braun, Jens Klingen, Robin Krom
+ * Copyright (C) 2007-2021 Thomas Braun, Jens Klingen, Robin Krom
*
* For more information see: http://getgreenshot.org/
* The Greenshot project is hosted on GitHub https://github.com/greenshot/greenshot
@@ -39,17 +39,10 @@ namespace GreenshotWin10Plugin
public void Dispose()
{
- Dispose(true);
+ // Nothing to dispose
}
- private void Dispose(bool disposing)
- {
- if (disposing)
- {
- }
- }
-
- public void Configure()
+ public void Configure()
{
throw new NotImplementedException();
}
@@ -81,6 +74,7 @@ namespace GreenshotWin10Plugin
public void Shutdown()
{
+ // Nothing to shutdown
}
}
diff --git a/azure-pipelines.yml b/azure-pipelines.yml
index 5043dd397..21d640496 100644
--- a/azure-pipelines.yml
+++ b/azure-pipelines.yml
@@ -28,22 +28,13 @@ stages:
vmImage: 'Windows-latest'
steps:
- - task: NuGetToolInstaller@1
-
- - task: NuGetCommand@2
- displayName: NuGet restore
- inputs:
- command: 'restore'
- restoreSolution: '$(solution)'
- feedsToUse: config
-
- task: MSBuild@1
- displayName: Generate templates
+ displayName: Restore nuget packages and generate credential templates
inputs:
solution: '$(solution)'
platform: $(buildPlatform)
configuration: $(buildConfiguration)
- msbuildArguments: '/t:PrepareForBuild'
+ msbuildArguments: '/restore /t:PrepareForBuild'
- task: MSBuild@1
displayName: Build and package