79 lines
2.5 KiB
C#
79 lines
2.5 KiB
C#
using System;
|
|
using System.Collections.Generic;
|
|
using System.Linq;
|
|
using System.Reflection;
|
|
using System.Text;
|
|
using Ui.ProductionControls.Enums;
|
|
|
|
namespace Ui.ProductionControls.Converter
|
|
{
|
|
public static class ImgToImage
|
|
{
|
|
static string Path = $"{AppDomain.CurrentDomain.BaseDirectory}\\Images\\";
|
|
static string Ending = ".png";
|
|
public static string GetImagePath(Img imgState)
|
|
{
|
|
switch (imgState)
|
|
{
|
|
case Img.Default:
|
|
return $"{Path}default{Ending}";
|
|
case Img.Cloud:
|
|
return $"{Path}cloud{Ending}";
|
|
case Img.Compare:
|
|
return $"{Path}compare{Ending}";
|
|
case Img.Error:
|
|
return $"{Path}error{Ending}";
|
|
case Img.Irda:
|
|
return $"{Path}irda{Ending}";
|
|
case Img.Login:
|
|
return $"{Path}login{Ending}";
|
|
case Img.Plugin:
|
|
return $"{Path}plugin{Ending}";
|
|
case Img.Success:
|
|
return $"{Path}success{Ending}";
|
|
case Img.Waiting:
|
|
return $"{Path}waiting{Ending}";
|
|
case Img.Warning:
|
|
return $"{Path}warning{Ending}";
|
|
case Img.BarcodeScanner:
|
|
return $"{Path}barcodeScanner{Ending}";
|
|
default:
|
|
return $"{Path}default{Ending}";
|
|
}
|
|
|
|
}
|
|
public static string GetText(Img imgState)
|
|
{
|
|
switch (imgState)
|
|
{
|
|
case Img.Default:
|
|
return $" - ";
|
|
case Img.Cloud:
|
|
return $"Get Data";
|
|
case Img.Compare:
|
|
return $"Compare";
|
|
case Img.Error:
|
|
return $"Error";
|
|
case Img.Irda:
|
|
return $"IrDA communication";
|
|
case Img.Login:
|
|
return $"Login";
|
|
case Img.Plugin:
|
|
return $"Plugin connector";
|
|
case Img.Success:
|
|
return $"Success";
|
|
case Img.Waiting:
|
|
return $"Waiting";
|
|
case Img.Warning:
|
|
return $"Warning";
|
|
case Img.BarcodeScanner:
|
|
return $"Scan barcode";
|
|
default:
|
|
return $"?";
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
}
|