Beispiel #1
0
        public Bitmap doCutting(int mode)
        {
            Bitmap bmp = null;

            bmp = showCaptureArea(getScreenSize(), captureScreen(), mode);

            if (!IsHidden)
            {
                Show();
            }
            if (f_EditorScreen != null && !f_EditorScreen.IsDisposed)
            {
                f_EditorScreen.Show();
            }
            if (tools != null && !tools.IsDisposed)
            {
                tools.Show();
            }
            if (f_EditorScreen != null && f_EditorScreen.pw != null && !f_EditorScreen.pw.IsDisposed && QshowPreview())
            {
                f_EditorScreen.pw.Show();
            }

            return(bmp);
        }
Beispiel #2
0
        public void handleCutouts(int mode)
        {
            Bitmap bmp = null;

            if (Properties.Settings.Default.s_hasDelay)
            {
            }
            else
            {
            }

            bmp = doCutting(mode);

            if (mode == -1)
            {
                if (bmp != null)
                {
                    Clipboard.SetImage(bmp);
                }
            }
            else
            {
                int i = 0;

                var x = Application.OpenForms;
                foreach (Form f in x)
                {
                    if (f is f_Screen)
                    {
                        i++;
                        break;
                    }
                }

                if (i == 0)
                {
                    f_EditorScreen = new f_Screen
                    {
                        parent = this
                    };
                    f_EditorScreen.Show();
                    f_EditorScreen.Refresh();
                    if (Properties.Settings.Default.s_ToolbarPanel == 0)
                    {
                        tools = new f_ToolsPanel
                        {
                            parent = f_EditorScreen
                        };
                        f_EditorScreen.child = tools;
                        tools.Show();
                    }
                }

                if (f_EditorScreen != null)
                {
                    f_EditorScreen.addImage(bmp, lastCutoutId);
                    lastCutoutId = "";
                }
            }
        }