1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
package com.iailab.module.data.video.dahua.frame;
 
import com.iailab.netsdk.common.BorderEx;
import com.iailab.netsdk.common.Res;
 
import javax.swing.*;
import javax.swing.border.EmptyBorder;
import java.awt.*;
 
/**
 * @author PanZhibao
 * @Description
 * @createTime 2024年04月15日
 */
public class DHCapturePictureFrame extends JFrame {
    private static final long serialVersionUID = 1L;
 
    public DHCapturePictureFrame(Panel realPlayWindow) {
        setTitle(Res.string().getCapturePicture());
        setLayout(new BorderLayout());
        pack();
        setSize(800, 560);
        setResizable(false);
        setLocationRelativeTo(null);
 
        this.realPlayWindow = realPlayWindow;
        realPanel = new RealPanel();
        this.realPlayWindow.setEnabled(true);
 
        add(realPanel, BorderLayout.CENTER);
    }
 
    /*
     * realplay show and control panel
     */
    private class RealPanel extends JPanel {
        private static final long serialVersionUID = 1L;
 
        public RealPanel() {
            BorderEx.set(this, Res.string().getRealplay(), 2);
            setLayout(new BorderLayout());
 
            realplayPanel = new JPanel();
            add(realplayPanel, BorderLayout.CENTER);
 
            /************ realplay panel **************/
            realplayPanel.setLayout(new BorderLayout());
            realplayPanel.setBorder(new EmptyBorder(5, 5, 5, 5));
            //realPlayWindow = new Panel();
            realPlayWindow.setBackground(Color.GRAY);
            realplayPanel.add(realPlayWindow, BorderLayout.CENTER);
 
            realPlayWindow.setEnabled(false);
 
        }
    }
 
    private RealPanel realPanel;
    private JPanel realplayPanel;
    private Panel realPlayWindow;
}