Esempio n. 1
0
        public LogPanel(JamochaGui gui)
            : base(gui)
        {
            InitBlock();
            //UPGRADE_ISSUE: Constructor 'java.awt.BorderLayout.BorderLayout' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtBorderLayout"'
            setLayout(new BorderLayout());
            logChannel = gui.Engine.MessageRouter.openChannel("gui_log", InterestType.ALL);
            detailView = new JTextArea();
            detailView.setEditable(false);
            //UPGRADE_NOTE: If the given Font Name does not exist, a default Font instance is created. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1075"'
            //UPGRADE_TODO: Method 'java.awt.Font.Plain' was converted to 'System.Drawing.FontStyle.Regular' which has a different behavior. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1073_javaawtFontPLAIN_f"'
            detailView.setFont(new System.Drawing.Font("Courier", 12, (System.Drawing.FontStyle) System.Drawing.FontStyle.Regular));
            cellRenderer = new LogTableCellRenderer(this);
            logTable = new AnonymousClassJTable(this, dataModel);
            logTable.setSelectionMode(ListSelectionModel.SINGLE_SELECTION);
            logTable.SelectionModel.addListSelectionListener(this);
            pane = new JSplitPane(JSplitPane.VERTICAL_SPLIT, new JScrollPane(logTable), new JScrollPane(detailView));
            pane.setDividerLocation(gui.Preferences.getInt("log.dividerlocation", 300));
            //UPGRADE_ISSUE: Field 'java.awt.BorderLayout.CENTER' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtBorderLayout"'
            add(pane, BorderLayout.CENTER);

            SupportClass.ThreadClass logThread = new AnonymousClassThread(this);
            logThread.Start();
            clearButton = new JButton("Clear Log", IconLoader.getImageIcon("monitor"));
            clearButton.addActionListener(this);
            JPanel buttonPanel = new JPanel();
            //UPGRADE_ISSUE: Constructor 'java.awt.FlowLayout.FlowLayout' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtFlowLayout"'
            //UPGRADE_ISSUE: Field 'java.awt.FlowLayout.RIGHT' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtFlowLayout"'
            buttonPanel.setLayout(new FlowLayout(FlowLayout.RIGHT, 5, 1));
            buttonPanel.add(clearButton);
            //UPGRADE_ISSUE: Field 'java.awt.BorderLayout' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000"'
            add(buttonPanel, BorderLayout.PAGE_END);
        }