Code quality changes, and added the possibility to set the amount of colors for the Quantizer.

This commit is contained in:
RKrom 2014-05-11 11:23:56 +02:00
commit 77a92d98c3
92 changed files with 690 additions and 653 deletions

View file

@ -21,7 +21,7 @@
using System;
namespace GreenshotPlugin.Core {
public static class EnumerationExtensions {
public static bool Has<T>(this System.Enum type, T value) {
public static bool Has<T>(this Enum type, T value) {
Type underlyingType = Enum.GetUnderlyingType(value.GetType());
try {
if (underlyingType == typeof(int)) {
@ -34,7 +34,7 @@ namespace GreenshotPlugin.Core {
return false;
}
public static bool Is<T>(this System.Enum type, T value) {
public static bool Is<T>(this Enum type, T value) {
Type underlyingType = Enum.GetUnderlyingType(value.GetType());
try {
if (underlyingType == typeof(int)) {
@ -53,7 +53,7 @@ namespace GreenshotPlugin.Core {
/// <param name="type"></param>
/// <param name="value"></param>
/// <returns></returns>
public static T Add<T>(this System.Enum type, T value) {
public static T Add<T>(this Enum type, T value) {
Type underlyingType = Enum.GetUnderlyingType(value.GetType());
try {
if (underlyingType == typeof(int)) {
@ -73,7 +73,7 @@ namespace GreenshotPlugin.Core {
/// <param name="type"></param>
/// <param name="value"></param>
/// <returns></returns>
public static T Remove<T>(this System.Enum type, T value) {
public static T Remove<T>(this Enum type, T value) {
Type underlyingType = Enum.GetUnderlyingType(value.GetType());
try {
if (underlyingType == typeof(int)) {