public void LayerToClipboard()
        {
            if (SelectedLayer == null || !ActiveWindowHelper.MainWindowActive || !IsActive)
            {
                return;
            }

            // Probably not how the cool kids do it but leveraging on JsonConvert gives flawless serialization
            GeneralHelpers.ExecuteSta(() => Clipboard.SetData("layer", JsonConvert.SerializeObject(SelectedLayer)));
        }
        public void ClipboardToLayer()
        {
            if (!ActiveWindowHelper.MainWindowActive || !IsActive)
            {
                return;
            }

            try
            {
                GeneralHelpers.ExecuteSta(() =>
                {
                    var data = (string)Clipboard.GetData("layer");
                    if (data == null)
                    {
                        return;
                    }

                    var layerModel = JsonConvert.DeserializeObject <LayerModel>(data);
                    if (layerModel == null)
                    {
                        return;
                    }

                    if (SelectedLayer != null)
                    {
                        SelectedLayer.InsertAfter(layerModel);
                    }
                    else
                    {
                        SelectedProfile.Layers.Add(layerModel);
                        SelectedProfile.FixOrder();
                    }
                    Execute.OnUIThread(() => UpdateLayerList(layerModel));
                });
            }
            catch (Exception)
            {
                // ignored
            }
        }