Пример #1
0
        public SettingsPanel(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());
            tabbedPane = new JTabbedPane();

            EngineSettingsPanel engineSettingsPanel = new EngineSettingsPanel(gui);

            tabbedPane.addTab("Engine", null, engineSettingsPanel, "Engine Settings");
            panels.add(engineSettingsPanel);

            ShellSettingsPanel shellSettingsPanel = new ShellSettingsPanel(gui);

            tabbedPane.addTab("Shell", null, shellSettingsPanel, "Shell Settings");
            panels.add(shellSettingsPanel);

            //UPGRADE_ISSUE: Field 'java.awt.BorderLayout.CENTER' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtBorderLayout"'
            add(tabbedPane, BorderLayout.CENTER);

            //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"'
            JPanel buttonPanel = new JPanel(new FlowLayout(FlowLayout.RIGHT, 5, 1));

            saveButton = new JButton("Save Changes", IconLoader.getImageIcon("disk"));
            saveButton.addActionListener(this);
            buttonPanel.add(saveButton);
            //UPGRADE_ISSUE: Field 'java.awt.BorderLayout.SOUTH' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtBorderLayout"'
            add(buttonPanel, BorderLayout.SOUTH);
        }
Пример #2
0
        public SettingsPanel(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());
            tabbedPane = new JTabbedPane();

            EngineSettingsPanel engineSettingsPanel = new EngineSettingsPanel(gui);
            tabbedPane.addTab("Engine", null, engineSettingsPanel, "Engine Settings");
            panels.add(engineSettingsPanel);

            ShellSettingsPanel shellSettingsPanel = new ShellSettingsPanel(gui);
            tabbedPane.addTab("Shell", null, shellSettingsPanel, "Shell Settings");
            panels.add(shellSettingsPanel);

            //UPGRADE_ISSUE: Field 'java.awt.BorderLayout.CENTER' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtBorderLayout"'
            add(tabbedPane, BorderLayout.CENTER);

            //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"'
            JPanel buttonPanel = new JPanel(new FlowLayout(FlowLayout.RIGHT, 5, 1));
            saveButton = new JButton("Save Changes", IconLoader.getImageIcon("disk"));
            saveButton.addActionListener(this);
            buttonPanel.add(saveButton);
            //UPGRADE_ISSUE: Field 'java.awt.BorderLayout.SOUTH' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtBorderLayout"'
            add(buttonPanel, BorderLayout.SOUTH);
        }
Пример #3
0
        /// <summary> Initializes the Visualiser with the current Rete-network.
        ///
        /// </summary>
        private void  initVisualiser()
        {
            visualiser = new Visualiser(gui.Engine);
            JPanel panel = visualiser.VisualiserPanel;

            visualiserPanel.removeAll();
            visualiserPanel.add("view", panel);
            //UPGRADE_ISSUE: Class 'java.awt.CardLayout' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtCardLayout"'
            ((CardLayout)visualiserPanel.Layout).last(visualiserPanel);
        }
Пример #4
0
 public override void  init()
 {
     // initialize the Panels
     templatePanel = new JPanel();
     templatePanel.setBorder(BorderFactory.createTitledBorder("Set the Slots for the Template"));
     //UPGRADE_ISSUE: Field 'java.awt.BorderLayout.CENTER' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtBorderLayout"'
     contentPanel.add(new JScrollPane(templatePanel), BorderLayout.CENTER);
     initTemplatePanel();
     setVisible(true);
 }
Пример #5
0
        /// <summary>
        /// This method is called from within the constructor to initialize the form.
        /// WARNING: Do NOT modify this code. The content of this method is always
        /// regenerated by the Form Editor.
        /// </summary>
        // <editor-fold defaultstate="collapsed" desc="Generated Code">//GEN-BEGIN:initComponents
        private void initComponents()
        {
            AddressField   = new javax.swing.JTextField();
            btnGoToAddress = new javax.swing.JButton();
            btnGoToSP      = new javax.swing.JButton();
            btnDumpRawRam  = new javax.swing.JButton();
            btnGoToVRAM    = new javax.swing.JButton();
            jPanel1        = new javax.swing.JPanel();
            taMemoryView   = new javax.swing.JTextArea();

            java.util.ResourceBundle bundle = java.util.ResourceBundle.getBundle("pspsharp/languages/pspsharp"); // NOI18N
            Title         = bundle.getString("MemoryViewer.title");                                              // NOI18N
            MinimumSize   = new java.awt.Dimension(800, 380);
            PreferredSize = new java.awt.Dimension(800, 380);

            AddressField.Font = new java.awt.Font("Courier New", 0, 12); // NOI18N
            AddressField.HorizontalAlignment = javax.swing.JTextField.CENTER;
            AddressField.Text = "0x00000000";                            // NOI18N
            AddressField.addKeyListener(new KeyAdapterAnonymousInnerClass(this));

            btnGoToAddress.Text = bundle.getString("MemoryViewer.btnGoToAddress.text");             // NOI18N
            btnGoToAddress.addActionListener(new ActionListenerAnonymousInnerClass(this));

            btnGoToSP.Text = bundle.getString("MemoryViewer.btnGoToSP.text");             // NOI18N
            btnGoToSP.addActionListener(new ActionListenerAnonymousInnerClass2(this));

            btnDumpRawRam.Text = bundle.getString("MemoryViewer.btnDumpRawRam.text");             // NOI18N
            btnDumpRawRam.addActionListener(new ActionListenerAnonymousInnerClass3(this));

            btnGoToVRAM.Text = bundle.getString("MemoryViewer.btnGoToVRAM.text");             // NOI18N
            btnGoToVRAM.addActionListener(new ActionListenerAnonymousInnerClass4(this));

            jPanel1.addComponentListener(new ComponentAdapterAnonymousInnerClass(this));

            taMemoryView.Editable = false;
            taMemoryView.Font     = new java.awt.Font("Courier New", 0, 12);         // NOI18N
            taMemoryView.Border   = javax.swing.BorderFactory.createLineBorder(new java.awt.Color(0, 0, 0));
            taMemoryView.addMouseWheelListener(new MouseWheelListenerAnonymousInnerClass(this));
            taMemoryView.addKeyListener(new KeyAdapterAnonymousInnerClass2(this));

            javax.swing.GroupLayout jPanel1Layout = new javax.swing.GroupLayout(jPanel1);
            jPanel1.Layout = jPanel1Layout;
            jPanel1Layout.HorizontalGroup = jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addComponent(taMemoryView);
            jPanel1Layout.VerticalGroup   = jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addComponent(taMemoryView, javax.swing.GroupLayout.DEFAULT_SIZE, 295, short.MaxValue);

            javax.swing.GroupLayout layout = new javax.swing.GroupLayout(ContentPane);
            ContentPane.Layout     = layout;
            layout.HorizontalGroup = layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(layout.createSequentialGroup().addContainerGap().addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(layout.createSequentialGroup().addComponent(AddressField, javax.swing.GroupLayout.PREFERRED_SIZE, 100, javax.swing.GroupLayout.PREFERRED_SIZE).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addComponent(btnGoToAddress, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, short.MaxValue).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, javax.swing.GroupLayout.DEFAULT_SIZE, short.MaxValue).addComponent(btnGoToVRAM, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, short.MaxValue).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, javax.swing.GroupLayout.DEFAULT_SIZE, short.MaxValue).addComponent(btnGoToSP, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, short.MaxValue).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, javax.swing.GroupLayout.DEFAULT_SIZE, short.MaxValue).addComponent(btnDumpRawRam, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, short.MaxValue)).addComponent(jPanel1, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, short.MaxValue)).addContainerGap());
            layout.VerticalGroup   = layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(layout.createSequentialGroup().addContainerGap().addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE).addComponent(btnDumpRawRam).addComponent(AddressField, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE).addComponent(btnGoToAddress).addComponent(btnGoToSP).addComponent(btnGoToVRAM)).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addComponent(jPanel1, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, short.MaxValue).addContainerGap());

            pack();
        }         // </editor-fold>//GEN-END:initComponents
Пример #6
0
        /// <summary> The main constructor for a RetePanel.
        ///
        /// </summary>
        /// <param name="">engine
        /// The Jamocha engine that should be used with this GUI.
        ///
        /// </param>
        public RetePanel(JamochaGui gui) : base(gui)
        {
            //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());

            visualiserPanel = new JPanel();
            //UPGRADE_ISSUE: Constructor 'java.awt.CardLayout.CardLayout' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtCardLayout"'
            visualiserPanel.setLayout(new CardLayout());
            //UPGRADE_ISSUE: Field 'java.awt.BorderLayout.CENTER' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtBorderLayout"'
            add(visualiserPanel, BorderLayout.CENTER);

            initVisualiser();
        }
Пример #7
0
        /// <summary> The main constructor for a RetePanel.
        /// 
        /// </summary>
        /// <param name="">engine
        /// The Jamocha engine that should be used with this GUI.
        /// 
        /// </param>
        public RetePanel(JamochaGui gui)
            : base(gui)
        {
            //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());

            visualiserPanel = new JPanel();
            //UPGRADE_ISSUE: Constructor 'java.awt.CardLayout.CardLayout' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtCardLayout"'
            visualiserPanel.setLayout(new CardLayout());
            //UPGRADE_ISSUE: Field 'java.awt.BorderLayout.CENTER' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtBorderLayout"'
            add(visualiserPanel, BorderLayout.CENTER);

            initVisualiser();
        }
Пример #8
0
 //UPGRADE_ISSUE: Class 'java.awt.GridBagLayout' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtGridBagLayout"'
 //UPGRADE_ISSUE: Class 'java.awt.GridBagConstraints' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtGridBagConstraints"'
 private void  addTypesCombo(JPanel parent, JComboBox combo, GridBagLayout gridbag, GridBagConstraints c, int row)
 {
     //UPGRADE_ISSUE: Field 'java.awt.GridBagConstraints.gridx' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtGridBagConstraints"'
     c.gridx = 2;
     //UPGRADE_ISSUE: Field 'java.awt.GridBagConstraints.gridy' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtGridBagConstraints"'
     c.gridy = row;
     //UPGRADE_ISSUE: Field 'java.awt.GridBagConstraints.fill' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtGridBagConstraints"'
     //UPGRADE_ISSUE: Field 'java.awt.GridBagConstraints.NONE' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtGridBagConstraints"'
     c.fill = GridBagConstraints.NONE;
     //UPGRADE_ISSUE: Field 'java.awt.GridBagConstraints.anchor' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtGridBagConstraints"'
     //UPGRADE_ISSUE: Field 'java.awt.GridBagConstraints.WEST' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtGridBagConstraints"'
     c.anchor = GridBagConstraints.WEST;
     gridbag.setConstraints(combo, c);
     parent.add(combo);
 }
Пример #9
0
 //UPGRADE_ISSUE: Class 'java.awt.GridBagLayout' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtGridBagLayout"'
 //UPGRADE_ISSUE: Class 'java.awt.GridBagConstraints' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtGridBagConstraints"'
 public virtual void addLabel(JPanel parent, JLabel label, GridBagLayout gridbag, GridBagConstraints c, int row)
 {
     //UPGRADE_ISSUE: Field 'java.awt.GridBagConstraints.gridx' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtGridBagConstraints"'
     c.gridx = 0;
     //UPGRADE_ISSUE: Field 'java.awt.GridBagConstraints.gridy' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtGridBagConstraints"'
     c.gridy = row;
     //UPGRADE_ISSUE: Field 'java.awt.GridBagConstraints.fill' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtGridBagConstraints"'
     //UPGRADE_ISSUE: Field 'java.awt.GridBagConstraints.VERTICAL' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtGridBagConstraints"'
     c.fill = GridBagConstraints.VERTICAL;
     //UPGRADE_ISSUE: Field 'java.awt.GridBagConstraints.anchor' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtGridBagConstraints"'
     //UPGRADE_ISSUE: Field 'java.awt.GridBagConstraints.EAST' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtGridBagConstraints"'
     c.anchor = GridBagConstraints.EAST;
     gridbag.setConstraints(label, c);
     parent.add(label);
 }
Пример #10
0
 //UPGRADE_ISSUE: Class 'java.awt.GridBagLayout' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtGridBagLayout"'
 //UPGRADE_ISSUE: Class 'java.awt.GridBagConstraints' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtGridBagConstraints"'
 public virtual void  addInputComponent(JPanel parent, JComponent comp, GridBagLayout gridbag, GridBagConstraints c, int row)
 {
     //UPGRADE_ISSUE: Field 'java.awt.GridBagConstraints.gridx' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtGridBagConstraints"'
     c.gridx = 1;
     //UPGRADE_ISSUE: Field 'java.awt.GridBagConstraints.gridy' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtGridBagConstraints"'
     c.gridy = row;
     //UPGRADE_ISSUE: Field 'java.awt.GridBagConstraints.fill' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtGridBagConstraints"'
     //UPGRADE_ISSUE: Field 'java.awt.GridBagConstraints.BOTH' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtGridBagConstraints"'
     c.fill = GridBagConstraints.BOTH;
     //UPGRADE_ISSUE: Field 'java.awt.GridBagConstraints.anchor' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtGridBagConstraints"'
     //UPGRADE_ISSUE: Field 'java.awt.GridBagConstraints.WEST' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtGridBagConstraints"'
     c.anchor = GridBagConstraints.WEST;
     gridbag.setConstraints(comp, c);
     parent.add(comp);
 }
Пример #11
0
 //UPGRADE_ISSUE: Class 'java.awt.GridBagLayout' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtGridBagLayout"'
 //UPGRADE_ISSUE: Class 'java.awt.GridBagConstraints' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtGridBagConstraints"'
 public virtual void addInputComponent(JPanel parent, JComponent comp, GridBagLayout gridbag, GridBagConstraints c, int row)
 {
     //UPGRADE_ISSUE: Field 'java.awt.GridBagConstraints.gridx' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtGridBagConstraints"'
     c.gridx = 1;
     //UPGRADE_ISSUE: Field 'java.awt.GridBagConstraints.gridy' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtGridBagConstraints"'
     c.gridy = row;
     //UPGRADE_ISSUE: Field 'java.awt.GridBagConstraints.fill' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtGridBagConstraints"'
     //UPGRADE_ISSUE: Field 'java.awt.GridBagConstraints.BOTH' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtGridBagConstraints"'
     c.fill = GridBagConstraints.BOTH;
     //UPGRADE_ISSUE: Field 'java.awt.GridBagConstraints.anchor' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtGridBagConstraints"'
     //UPGRADE_ISSUE: Field 'java.awt.GridBagConstraints.WEST' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtGridBagConstraints"'
     c.anchor = GridBagConstraints.WEST;
     gridbag.setConstraints(comp, c);
     parent.add(comp);
 }
Пример #12
0
 //UPGRADE_ISSUE: Class 'java.awt.GridBagLayout' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtGridBagLayout"'
 //UPGRADE_ISSUE: Class 'java.awt.GridBagConstraints' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtGridBagConstraints"'
 private void  addRemoveButton(JPanel parent, JButton button, GridBagLayout gridbag, GridBagConstraints c, int row)
 {
     //UPGRADE_ISSUE: Field 'java.awt.GridBagConstraints.gridx' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtGridBagConstraints"'
     c.gridx = 0;
     //UPGRADE_ISSUE: Field 'java.awt.GridBagConstraints.gridy' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtGridBagConstraints"'
     c.gridy = row;
     //UPGRADE_ISSUE: Field 'java.awt.GridBagConstraints.fill' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtGridBagConstraints"'
     //UPGRADE_ISSUE: Field 'java.awt.GridBagConstraints.NONE' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtGridBagConstraints"'
     c.fill = GridBagConstraints.NONE;
     //UPGRADE_ISSUE: Field 'java.awt.GridBagConstraints.anchor' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtGridBagConstraints"'
     //UPGRADE_ISSUE: Field 'java.awt.GridBagConstraints.EAST' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtGridBagConstraints"'
     c.anchor = GridBagConstraints.EAST;
     gridbag.setConstraints(button, c);
     parent.add(button);
 }
Пример #13
0
 //UPGRADE_ISSUE: Class 'java.awt.GridBagLayout' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtGridBagLayout"'
 //UPGRADE_ISSUE: Class 'java.awt.GridBagConstraints' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtGridBagConstraints"'
 public virtual void  addLabel(JPanel parent, JLabel label, GridBagLayout gridbag, GridBagConstraints c, int row)
 {
     //UPGRADE_ISSUE: Field 'java.awt.GridBagConstraints.gridx' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtGridBagConstraints"'
     c.gridx = 0;
     //UPGRADE_ISSUE: Field 'java.awt.GridBagConstraints.gridy' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtGridBagConstraints"'
     c.gridy = row;
     //UPGRADE_ISSUE: Field 'java.awt.GridBagConstraints.fill' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtGridBagConstraints"'
     //UPGRADE_ISSUE: Field 'java.awt.GridBagConstraints.VERTICAL' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtGridBagConstraints"'
     c.fill = GridBagConstraints.VERTICAL;
     //UPGRADE_ISSUE: Field 'java.awt.GridBagConstraints.anchor' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtGridBagConstraints"'
     //UPGRADE_ISSUE: Field 'java.awt.GridBagConstraints.EAST' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtGridBagConstraints"'
     c.anchor = GridBagConstraints.EAST;
     gridbag.setConstraints(label, c);
     parent.add(label);
 }
Пример #14
0
 //UPGRADE_ISSUE: Class 'java.awt.GridBagLayout' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtGridBagLayout"'
 //UPGRADE_ISSUE: Class 'java.awt.GridBagConstraints' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtGridBagConstraints"'
 private void  addNameField(JPanel parent, JTextField field, GridBagLayout gridbag, GridBagConstraints c, int row)
 {
     //UPGRADE_ISSUE: Field 'java.awt.GridBagConstraints.gridx' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtGridBagConstraints"'
     c.gridx = 3;
     //UPGRADE_ISSUE: Field 'java.awt.GridBagConstraints.gridy' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtGridBagConstraints"'
     c.gridy = row;
     //UPGRADE_ISSUE: Field 'java.awt.GridBagConstraints.fill' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtGridBagConstraints"'
     //UPGRADE_ISSUE: Field 'java.awt.GridBagConstraints.HORIZONTAL' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtGridBagConstraints"'
     c.fill = GridBagConstraints.HORIZONTAL;
     //UPGRADE_ISSUE: Field 'java.awt.GridBagConstraints.anchor' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtGridBagConstraints"'
     //UPGRADE_ISSUE: Field 'java.awt.GridBagConstraints.WEST' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtGridBagConstraints"'
     c.anchor = GridBagConstraints.WEST;
     field.setColumns(30);
     gridbag.setConstraints(field, c);
     parent.add(field);
 }
Пример #15
0
        internal BatchResultBrowser(JButton batchResultsButton)
        {
            this.batchResultsButton = batchResultsButton;
            topPanel = new JPanel();
            setSize(500, 400);
            //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());
            resultsBoxModel = new ResultBoxModel(this);
            resultsBox      = new JComboBox(resultsBoxModel);
            removeButton    = new JButton(IconLoader.getImageIcon("delete"));
            removeButton.addActionListener(this);
            removeButton.setToolTipText("Remove this batch result");
            reloadButton = new JButton(IconLoader.getImageIcon("arrow_refresh"));
            reloadButton.addActionListener(this);
            reloadButton.setToolTipText("Reload the list of available batch results");

            topPanel.add(resultsBox);
            topPanel.add(removeButton);
            topPanel.add(reloadButton);
            //UPGRADE_ISSUE: Field 'java.awt.BorderLayout.NORTH' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtBorderLayout"'
            add(topPanel, BorderLayout.NORTH);
            aboutArea = new JTextArea();
            aboutArea.setBorder(BorderFactory.createEmptyBorder());
            aboutArea.setLineWrap(true);
            aboutArea.setWrapStyleWord(true);
            aboutArea.setEditable(false);
            //UPGRADE_ISSUE: Field 'java.awt.BorderLayout.CENTER' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtBorderLayout"'
            add(new JScrollPane(aboutArea, JScrollPane.VERTICAL_SCROLLBAR_ALWAYS, JScrollPane.HORIZONTAL_SCROLLBAR_NEVER), BorderLayout.CENTER);
            resultsBox.addActionListener(this);
            //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"'
            JPanel closePanel = new JPanel(new FlowLayout(FlowLayout.RIGHT));

            closeButton = new JButton("close");
            closeButton.addActionListener(this);
            closePanel.add(closeButton);
            //UPGRADE_ISSUE: Field 'java.awt.BorderLayout.SOUTH' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtBorderLayout"'
            add(closePanel, BorderLayout.SOUTH);
            batchResultsButton.setIcon(IconLoader.getImageIcon("lorry"));
        }
Пример #16
0
        internal BatchResultBrowser(JButton batchResultsButton)
        {
            this.batchResultsButton = batchResultsButton;
            topPanel = new JPanel();
            setSize(500, 400);
            //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());
            resultsBoxModel = new ResultBoxModel(this);
            resultsBox = new JComboBox(resultsBoxModel);
            removeButton = new JButton(IconLoader.getImageIcon("delete"));
            removeButton.addActionListener(this);
            removeButton.setToolTipText("Remove this batch result");
            reloadButton = new JButton(IconLoader.getImageIcon("arrow_refresh"));
            reloadButton.addActionListener(this);
            reloadButton.setToolTipText("Reload the list of available batch results");

            topPanel.add(resultsBox);
            topPanel.add(removeButton);
            topPanel.add(reloadButton);
            //UPGRADE_ISSUE: Field 'java.awt.BorderLayout.NORTH' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtBorderLayout"'
            add(topPanel, BorderLayout.NORTH);
            aboutArea = new JTextArea();
            aboutArea.setBorder(BorderFactory.createEmptyBorder());
            aboutArea.setLineWrap(true);
            aboutArea.setWrapStyleWord(true);
            aboutArea.setEditable(false);
            //UPGRADE_ISSUE: Field 'java.awt.BorderLayout.CENTER' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtBorderLayout"'
            add(new JScrollPane(aboutArea, JScrollPane.VERTICAL_SCROLLBAR_ALWAYS, JScrollPane.HORIZONTAL_SCROLLBAR_NEVER), BorderLayout.CENTER);
            resultsBox.addActionListener(this);
            //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"'
            JPanel closePanel = new JPanel(new FlowLayout(FlowLayout.RIGHT));
            closeButton = new JButton("close");
            closeButton.addActionListener(this);
            closePanel.add(closeButton);
            //UPGRADE_ISSUE: Field 'java.awt.BorderLayout.SOUTH' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtBorderLayout"'
            add(closePanel, BorderLayout.SOUTH);
            batchResultsButton.setIcon(IconLoader.getImageIcon("lorry"));
        }
Пример #17
0
 public override void init()
 {
     // initialize the Panels
     templatePanel = new JPanel();
     templatePanel.setBorder(BorderFactory.createTitledBorder("Set the Slots for the Template"));
     //UPGRADE_ISSUE: Field 'java.awt.BorderLayout.CENTER' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtBorderLayout"'
     contentPanel.add(new JScrollPane(templatePanel), BorderLayout.CENTER);
     initTemplatePanel();
     setVisible(true);
 }
Пример #18
0
        public TemplateEditor(Rete engine) : base(engine)
        {
            InitBlock();
            setSize(600, 500);
            //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());
            setTitle("Create new Template");
            //UPGRADE_ISSUE: Constructor 'java.awt.BorderLayout.BorderLayout' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtBorderLayout"'
            contentPanel = new JPanel(new BorderLayout());
            //UPGRADE_ISSUE: Field 'java.awt.BorderLayout.CENTER' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtBorderLayout"'
            add(contentPanel, BorderLayout.CENTER);
            cancelButton = new JButton("Cancel", IconLoader.getImageIcon("cancel"));
            cancelButton.addActionListener(this);
            assertButton = new JButton("Create Template", IconLoader.getImageIcon("brick_add"));
            assertButton.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.CENTER' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtFlowLayout"'
            buttonPanel.setLayout(new FlowLayout(FlowLayout.CENTER, 5, 1));
            buttonPanel.add(cancelButton);
            buttonPanel.add(assertButton);
            //UPGRADE_ISSUE: Field 'java.awt.BorderLayout.SOUTH' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtBorderLayout"'
            add(buttonPanel, BorderLayout.SOUTH);

            nameField = new JTextField(15);
            Collection modules = engine.WorkingMemory.Modules;

            System.String[] moduleNames = new System.String[modules.size()];
            int             i           = 0;
            Iterator        itr         = modules.iterator();

            while (itr.hasNext())
            {
                System.Object obj = itr.next();
                moduleNames[i++] = ((Module)obj).ModuleName;
            }
            moduleBox = new JComboBox(moduleNames);


            addSlotButton = new JButton("Add Slot", IconLoader.getImageIcon("add"));
            addSlotButton.addActionListener(this);
            //UPGRADE_ISSUE: Field 'java.awt.Component.RIGHT_ALIGNMENT' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtComponentRIGHT_ALIGNMENT_f"'
            addSlotButton.setAlignmentX(Component.RIGHT_ALIGNMENT);

            JPanel topPanel = new JPanel();

            topPanel.setBorder(BorderFactory.createTitledBorder("General Template Settings"));
            //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.LEFT' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtFlowLayout"'
            topPanel.setLayout(new FlowLayout(FlowLayout.LEFT, 20, 1));
            //UPGRADE_ISSUE: Constructor 'java.awt.GridLayout.GridLayout' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtGridLayout"'
            JPanel innerTopPanel = new JPanel(new GridLayout(2, 2));

            innerTopPanel.add(new JLabel("Template-name:"));
            innerTopPanel.add(nameField);
            innerTopPanel.add(new JLabel("Template-Module:"));
            innerTopPanel.add(moduleBox);
            //UPGRADE_ISSUE: Field 'java.awt.BorderLayout.WEST' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtBorderLayout"'
            topPanel.add(innerTopPanel, BorderLayout.WEST);
            topPanel.add(addSlotButton);
            //UPGRADE_ISSUE: Field 'java.awt.BorderLayout.NORTH' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtBorderLayout"'
            add(topPanel, BorderLayout.NORTH);

            dumpAreaTemplate.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"'
            dumpAreaTemplate.setFont(new System.Drawing.Font("Courier", 12, (System.Drawing.FontStyle)System.Drawing.FontStyle.Regular));
            dumpAreaTemplate.setRows(5);

            JPanel dumpAreaPanel = new JPanel();

            dumpAreaPanel.setLayout(new BoxLayout(dumpAreaPanel, BoxLayout.Y_AXIS));
            dumpAreaPanel.setBorder(BorderFactory.createTitledBorder("Template Preview"));
            dumpAreaPanel.add(new JScrollPane(dumpAreaTemplate));
            reloadButtonDumpAreaTemplate = new JButton("Reload Template Preview", IconLoader.getImageIcon("arrow_refresh"));
            reloadButtonDumpAreaTemplate.addActionListener(this);
            dumpAreaPanel.add(reloadButtonDumpAreaTemplate);

            //UPGRADE_ISSUE: Field 'java.awt.BorderLayout.SOUTH' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtBorderLayout"'
            contentPanel.add(dumpAreaPanel, BorderLayout.SOUTH);
        }
Пример #19
0
 //UPGRADE_ISSUE: Class 'java.awt.GridBagLayout' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtGridBagLayout"'
 //UPGRADE_ISSUE: Class 'java.awt.GridBagConstraints' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtGridBagConstraints"'
 private void addTypesCombo(JPanel parent, JComboBox combo, GridBagLayout gridbag, GridBagConstraints c, int row)
 {
     //UPGRADE_ISSUE: Field 'java.awt.GridBagConstraints.gridx' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtGridBagConstraints"'
     c.gridx = 2;
     //UPGRADE_ISSUE: Field 'java.awt.GridBagConstraints.gridy' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtGridBagConstraints"'
     c.gridy = row;
     //UPGRADE_ISSUE: Field 'java.awt.GridBagConstraints.fill' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtGridBagConstraints"'
     //UPGRADE_ISSUE: Field 'java.awt.GridBagConstraints.NONE' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtGridBagConstraints"'
     c.fill = GridBagConstraints.NONE;
     //UPGRADE_ISSUE: Field 'java.awt.GridBagConstraints.anchor' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtGridBagConstraints"'
     //UPGRADE_ISSUE: Field 'java.awt.GridBagConstraints.WEST' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtGridBagConstraints"'
     c.anchor = GridBagConstraints.WEST;
     gridbag.setConstraints(combo, c);
     parent.add(combo);
 }
Пример #20
0
        public EngineSettingsPanel(JamochaGui gui)
            : base(gui)
        {
            //UPGRADE_ISSUE: Class 'java.awt.GridBagLayout' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtGridBagLayout"'
            //UPGRADE_ISSUE: Constructor 'java.awt.GridBagLayout.GridBagLayout' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtGridBagLayout"'
            GridBagLayout gridbag = new GridBagLayout();
            //UPGRADE_ISSUE: Class 'java.awt.GridBagConstraints' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtGridBagConstraints"'
            //UPGRADE_ISSUE: Constructor 'java.awt.GridBagConstraints.GridBagConstraints' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtGridBagConstraints"'
            GridBagConstraints c = new GridBagConstraints();
            //UPGRADE_ISSUE: Field 'java.awt.GridBagConstraints.weightx' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtGridBagConstraints"'
            c.weightx = 1.0;
            setLayout(gridbag);

            // Evaluation
            addLabel(this, new JLabel("Evaluation"), gridbag, c, 0);
            //UPGRADE_ISSUE: Constructor 'java.awt.BorderLayout.BorderLayout' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtBorderLayout"'
            JPanel evaluationPanel = new JPanel(new BorderLayout());

            evaluationCheckBox = new JCheckBox();
            evaluationCheckBox.setEnabled(true);
            evaluationCheckBox.addActionListener(this);
            //UPGRADE_ISSUE: Field 'java.awt.BorderLayout.WEST' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtBorderLayout"'
            evaluationPanel.add(evaluationCheckBox, BorderLayout.WEST);
            addInputComponent(this, evaluationPanel, gridbag, c, 0);

            // Profile Assert
            addLabel(this, new JLabel("Profile Assert:"), gridbag, c, 1);
            //UPGRADE_ISSUE: Constructor 'java.awt.BorderLayout.BorderLayout' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtBorderLayout"'
            JPanel profileAssertPanel = new JPanel(new BorderLayout());

            profileAssertCheckBox = new JCheckBox();
            profileAssertCheckBox.setEnabled(true);
            profileAssertCheckBox.addActionListener(this);
            //UPGRADE_ISSUE: Field 'java.awt.BorderLayout.WEST' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtBorderLayout"'
            profileAssertPanel.add(profileAssertCheckBox, BorderLayout.WEST);
            addInputComponent(this, profileAssertPanel, gridbag, c, 1);

            // Profile Retract
            addLabel(this, new JLabel("Profile Retract:"), gridbag, c, 2);
            //UPGRADE_ISSUE: Constructor 'java.awt.BorderLayout.BorderLayout' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtBorderLayout"'
            JPanel profileRetractPanel = new JPanel(new BorderLayout());

            profileRetractCheckBox = new JCheckBox();
            profileRetractCheckBox.setEnabled(true);
            profileRetractCheckBox.addActionListener(this);
            //UPGRADE_ISSUE: Field 'java.awt.BorderLayout.WEST' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtBorderLayout"'
            profileRetractPanel.add(profileRetractCheckBox, BorderLayout.WEST);
            addInputComponent(this, profileRetractPanel, gridbag, c, 2);

            // Profile Fire
            addLabel(this, new JLabel("Profile Fire:"), gridbag, c, 3);
            //UPGRADE_ISSUE: Constructor 'java.awt.BorderLayout.BorderLayout' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtBorderLayout"'
            JPanel profileFirePanel = new JPanel(new BorderLayout());

            profileFireCheckBox = new JCheckBox();
            profileFireCheckBox.setEnabled(true);
            profileFireCheckBox.addActionListener(this);
            //UPGRADE_ISSUE: Field 'java.awt.BorderLayout.WEST' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtBorderLayout"'
            profileFirePanel.add(profileFireCheckBox, BorderLayout.WEST);
            addInputComponent(this, profileFirePanel, gridbag, c, 3);

            // Profile Add Activation
            addLabel(this, new JLabel("Profile Add Activation:"), gridbag, c, 4);
            //UPGRADE_ISSUE: Constructor 'java.awt.BorderLayout.BorderLayout' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtBorderLayout"'
            JPanel profileAddActivationPanel = new JPanel(new BorderLayout());

            profileAddActivationCheckBox = new JCheckBox();
            profileAddActivationCheckBox.setEnabled(true);
            profileAddActivationCheckBox.addActionListener(this);
            //UPGRADE_ISSUE: Field 'java.awt.BorderLayout.WEST' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtBorderLayout"'
            profileAddActivationPanel.add(profileAddActivationCheckBox, BorderLayout.WEST);
            addInputComponent(this, profileAddActivationPanel, gridbag, c, 4);

            // Profile Remove Activation
            addLabel(this, new JLabel("Profile Remove Activation:"), gridbag, c, 5);
            //UPGRADE_ISSUE: Constructor 'java.awt.BorderLayout.BorderLayout' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtBorderLayout"'
            JPanel profileRemoveActivationPanel = new JPanel(new BorderLayout());

            profileRemoveActivationCheckBox = new JCheckBox();
            profileRemoveActivationCheckBox.setEnabled(true);
            profileRemoveActivationCheckBox.addActionListener(this);
            //UPGRADE_ISSUE: Field 'java.awt.BorderLayout.WEST' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtBorderLayout"'
            profileRemoveActivationPanel.add(profileRemoveActivationCheckBox, BorderLayout.WEST);
            addInputComponent(this, profileRemoveActivationPanel, gridbag, c, 5);

            // Activations
            addLabel(this, new JLabel(" Watch Activations:"), gridbag, c, 6);
            //UPGRADE_ISSUE: Constructor 'java.awt.BorderLayout.BorderLayout' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtBorderLayout"'
            JPanel watchActivationsPanel = new JPanel(new BorderLayout());

            watchActivationsCheckBox = new JCheckBox();
            watchActivationsCheckBox.setEnabled(true);
            watchActivationsCheckBox.addActionListener(this);
            //UPGRADE_ISSUE: Field 'java.awt.BorderLayout.WEST' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtBorderLayout"'
            watchActivationsPanel.add(watchActivationsCheckBox, BorderLayout.WEST);
            addInputComponent(this, watchActivationsPanel, gridbag, c, 6);

            // Facts
            addLabel(this, new JLabel("Watch Facts:"), gridbag, c, 7);
            //UPGRADE_ISSUE: Constructor 'java.awt.BorderLayout.BorderLayout' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtBorderLayout"'
            JPanel watchFactsPanel = new JPanel(new BorderLayout());

            watchFactsCheckBox = new JCheckBox();
            watchFactsCheckBox.setEnabled(true);
            watchFactsCheckBox.addActionListener(this);
            //UPGRADE_ISSUE: Field 'java.awt.BorderLayout.WEST' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtBorderLayout"'
            watchFactsPanel.add(watchFactsCheckBox, BorderLayout.WEST);
            addInputComponent(this, watchFactsPanel, gridbag, c, 7);

            // Rules
            addLabel(this, new JLabel("Watch Rules:"), gridbag, c, 8);
            //UPGRADE_ISSUE: Constructor 'java.awt.BorderLayout.BorderLayout' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtBorderLayout"'
            JPanel watchRulesPanel = new JPanel(new BorderLayout());

            watchRulesCheckBox = new JCheckBox();
            watchRulesCheckBox.setEnabled(true);
            watchRulesCheckBox.addActionListener(this);
            //UPGRADE_ISSUE: Field 'java.awt.BorderLayout.WEST' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtBorderLayout"'
            watchRulesPanel.add(watchRulesCheckBox, BorderLayout.WEST);
            addInputComponent(this, watchRulesPanel, gridbag, c, 8);
        }
Пример #21
0
 //UPGRADE_ISSUE: Class 'java.awt.GridBagLayout' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtGridBagLayout"'
 //UPGRADE_ISSUE: Class 'java.awt.GridBagConstraints' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtGridBagConstraints"'
 private void addNameField(JPanel parent, JTextField field, GridBagLayout gridbag, GridBagConstraints c, int row)
 {
     //UPGRADE_ISSUE: Field 'java.awt.GridBagConstraints.gridx' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtGridBagConstraints"'
     c.gridx = 3;
     //UPGRADE_ISSUE: Field 'java.awt.GridBagConstraints.gridy' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtGridBagConstraints"'
     c.gridy = row;
     //UPGRADE_ISSUE: Field 'java.awt.GridBagConstraints.fill' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtGridBagConstraints"'
     //UPGRADE_ISSUE: Field 'java.awt.GridBagConstraints.HORIZONTAL' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtGridBagConstraints"'
     c.fill = GridBagConstraints.HORIZONTAL;
     //UPGRADE_ISSUE: Field 'java.awt.GridBagConstraints.anchor' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtGridBagConstraints"'
     //UPGRADE_ISSUE: Field 'java.awt.GridBagConstraints.WEST' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtGridBagConstraints"'
     c.anchor = GridBagConstraints.WEST;
     field.setColumns(30);
     gridbag.setConstraints(field, c);
     parent.add(field);
 }
Пример #22
0
        public ShellSettingsPanel(JamochaGui gui) : base(gui)
        {
            //UPGRADE_ISSUE: Class 'java.awt.GridBagLayout' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtGridBagLayout"'
            //UPGRADE_ISSUE: Constructor 'java.awt.GridBagLayout.GridBagLayout' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtGridBagLayout"'
            GridBagLayout gridbag = new GridBagLayout();
            //UPGRADE_ISSUE: Class 'java.awt.GridBagConstraints' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtGridBagConstraints"'
            //UPGRADE_ISSUE: Constructor 'java.awt.GridBagConstraints.GridBagConstraints' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtGridBagConstraints"'
            GridBagConstraints c = new GridBagConstraints();

            //UPGRADE_ISSUE: Field 'java.awt.GridBagConstraints.weightx' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtGridBagConstraints"'
            c.weightx = 1.0;
            setLayout(gridbag);

            // Font
            addLabel(this, new JLabel("Font:"), gridbag, c, 0);
            GraphicsEnvironment ge = GraphicsEnvironment.LocalGraphicsEnvironment;

            System.Drawing.Font[] allFonts = ge.AllFonts;
            fonts = new JComboBox(allFonts);
            System.Drawing.Font selFont     = null;
            System.String       selFontName = gui.Preferences.get("shell.font", "Courier");
            for (int idx = 0; idx < allFonts.Length; idx++)
            {
                System.Drawing.Font curFont = allFonts[idx];
                if (curFont.FontName.equals(selFontName))
                {
                    selFont = curFont;
                    break;
                }
            }
            if (selFont != null)
            {
                fonts.setSelectedItem(selFont);
            }
            fonts.setRenderer(new FontListCellRenderer(this));
            addInputComponent(this, fonts, gridbag, c, 0);

            // Fontsize
            addLabel(this, new JLabel("Fontsize:"), gridbag, c, 1);
            System.Int32[] sizes = new System.Int32[17];
            for (int i = 0; i < sizes.Length; ++i)
            {
                sizes[i] = 8 + i;
            }
            fontsizes = new JComboBox(sizes);
            //fontsizes.setSelectedItem(gui.getPreferences().getInt("shell.fontsize",
            //		12));
            addInputComponent(this, fontsizes, gridbag, c, 1);

            // Fontcolor
            addLabel(this, new JLabel("Fontcolor:"), gridbag, c, 2);
            //UPGRADE_ISSUE: Constructor 'java.awt.FlowLayout.FlowLayout' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtFlowLayout"'
            JPanel fontColorChooserPanel = new JPanel(new FlowLayout());

            fontColorChooserPreview = new JTextField(5);
            fontColorChooserPreview.setEditable(false);
            fontColorChooserPreview.setBackground(new Color(gui.Preferences.getInt("shell.fontcolor", System.Drawing.Color.WHITE.RGB)));
            fontColorChooserButton = new JButton("Choose Color", IconLoader.getImageIcon("color_swatch"));
            fontColorChooserButton.addActionListener(this);
            fontColorChooserPanel.add(fontColorChooserPreview);
            fontColorChooserPanel.add(fontColorChooserButton);
            addInputComponent(this, fontColorChooserPanel, gridbag, c, 2);

            // Backgroundcolor
            addLabel(this, new JLabel("Backgroundcolor:"), gridbag, c, 3);
            //UPGRADE_ISSUE: Constructor 'java.awt.FlowLayout.FlowLayout' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtFlowLayout"'
            JPanel backgroundColorChooserPanel = new JPanel(new FlowLayout());

            backgroundColorChooserPreview = new JTextField(5);
            backgroundColorChooserPreview.setEditable(false);
            backgroundColorChooserPreview.setBackground(new Color(gui.Preferences.getInt("shell.backgroundcolor", System.Drawing.Color.BLACK.RGB)));
            backgroundColorChooserButton = new JButton("Choose Color", IconLoader.getImageIcon("color_swatch"));
            backgroundColorChooserButton.addActionListener(this);
            backgroundColorChooserPanel.add(backgroundColorChooserPreview);
            backgroundColorChooserPanel.add(backgroundColorChooserButton);
            addInputComponent(this, backgroundColorChooserPanel, gridbag, c, 3);
        }
Пример #23
0
        /// <summary>
        /// This method is called from within the constructor to initialize the form.
        /// WARNING: Do NOT modify this code. The content of this method is always
        /// regenerated by the Form Editor.
        /// </summary>
//JAVA TO C# CONVERTER TODO TASK: Most Java annotations will not have direct .NET equivalent attributes:
//ORIGINAL LINE: @SuppressWarnings("unchecked") private void initComponents()
        private void initComponents()
        {
            btnAdd         = new javax.swing.JButton();
            btnRemove      = new javax.swing.JButton();
            jPanel2        = new javax.swing.JPanel();
            jSeparator1    = new javax.swing.JSeparator();
            jPanel1        = new javax.swing.JPanel();
            cbTraceRead    = new javax.swing.JCheckBox();
            cbTraceWrite   = new javax.swing.JCheckBox();
            cbTraceRead8   = new javax.swing.JCheckBox();
            cbTraceWrite8  = new javax.swing.JCheckBox();
            cbTraceRead16  = new javax.swing.JCheckBox();
            cbTraceWrite16 = new javax.swing.JCheckBox();
            cbTraceRead32  = new javax.swing.JCheckBox();
            cbTraceWrite32 = new javax.swing.JCheckBox();
            chkPauseOnHit  = new javax.swing.JCheckBox();
            btnClose       = new javax.swing.JButton();
            btnExport      = new javax.swing.JButton();
            btnImport      = new javax.swing.JButton();
            jScrollPane2   = new javax.swing.JScrollPane();
            tblBreakpoints = new JTable();

            java.util.ResourceBundle bundle = java.util.ResourceBundle.getBundle("pspsharp/languages/pspsharp"); // NOI18N
            Title = bundle.getString("MemoryBreakpointsDialog.title");                                           // NOI18N
            LocationByPlatform = true;
            Name = "dialog";                                                                                     // NOI18N

            btnAdd.Text          = bundle.getString("MemoryBreakpointsDialog.btnAdd.text");                      // NOI18N
            btnAdd.MaximumSize   = new java.awt.Dimension(140, 25);
            btnAdd.MinimumSize   = new java.awt.Dimension(140, 25);
            btnAdd.PreferredSize = new java.awt.Dimension(140, 25);
            btnAdd.addActionListener(new ActionListenerAnonymousInnerClass(this));

            btnRemove.Text          = bundle.getString("MemoryBreakpointsDialog.btnRemove.text");    // NOI18N
            btnRemove.Enabled       = false;
            btnRemove.MaximumSize   = new java.awt.Dimension(140, 25);
            btnRemove.MinimumSize   = new java.awt.Dimension(140, 25);
            btnRemove.PreferredSize = new java.awt.Dimension(140, 25);
            btnRemove.addActionListener(new ActionListenerAnonymousInnerClass2(this));

            jPanel1.Layout = new java.awt.GridLayout(5, 2);

            cbTraceRead.Text = bundle.getString("MemoryBreakpointsDialog.cbTraceRead.text");             // NOI18N
            cbTraceRead.addItemListener(new ItemListenerAnonymousInnerClass(this));
            jPanel1.add(cbTraceRead);

            cbTraceWrite.Text = bundle.getString("MemoryBreakpointsDialog.cbTraceWrite.text");             // NOI18N
            cbTraceWrite.addItemListener(new ItemListenerAnonymousInnerClass2(this));
            jPanel1.add(cbTraceWrite);

            cbTraceRead8.Text = bundle.getString("MemoryBreakpointsDialog.cbTraceRead8.text");             // NOI18N
            cbTraceRead8.addItemListener(new ItemListenerAnonymousInnerClass3(this));
            jPanel1.add(cbTraceRead8);

            cbTraceWrite8.Text = bundle.getString("MemoryBreakpointsDialog.cbTraceWrite8.text");             // NOI18N
            cbTraceWrite8.addItemListener(new ItemListenerAnonymousInnerClass4(this));
            jPanel1.add(cbTraceWrite8);

            cbTraceRead16.Text = bundle.getString("MemoryBreakpointsDialog.cbTraceRead16.text");             // NOI18N
            cbTraceRead16.addItemListener(new ItemListenerAnonymousInnerClass5(this));
            jPanel1.add(cbTraceRead16);

            cbTraceWrite16.Text = bundle.getString("MemoryBreakpointsDialog.cbTraceWrite16.text");             // NOI18N
            cbTraceWrite16.addItemListener(new ItemListenerAnonymousInnerClass6(this));
            jPanel1.add(cbTraceWrite16);

            cbTraceRead32.Text = bundle.getString("MemoryBreakpointsDialog.cbTraceRead32.text");             // NOI18N
            cbTraceRead32.addItemListener(new ItemListenerAnonymousInnerClass7(this));
            jPanel1.add(cbTraceRead32);

            cbTraceWrite32.Text = bundle.getString("MemoryBreakpointsDialog.cbTraceWrite32.text");             // NOI18N
            cbTraceWrite32.addItemListener(new ItemListenerAnonymousInnerClass8(this));
            jPanel1.add(cbTraceWrite32);

            chkPauseOnHit.Selected = ((DebuggerMemory)Memory.Instance).pauseEmulatorOnMemoryBreakpoint;
            chkPauseOnHit.Text     = bundle.getString("MemoryBreakpointsDialog.chkPauseOnHit.text");         // NOI18N
            chkPauseOnHit.addItemListener(new ItemListenerAnonymousInnerClass9(this));
            jPanel1.add(chkPauseOnHit);

            btnClose.Text = bundle.getString("CloseButton.text");             // NOI18N
            btnClose.addActionListener(new ActionListenerAnonymousInnerClass3(this));

            btnExport.Text    = bundle.getString("MemoryBreakpointsDialog.btnExport.text");          // NOI18N
            btnExport.Enabled = false;
            btnExport.addActionListener(new ActionListenerAnonymousInnerClass4(this));

            btnImport.Text = bundle.getString("MemoryBreakpointsDialog.btnImport.text");             // NOI18N
            btnImport.addActionListener(new ActionListenerAnonymousInnerClass5(this));

            javax.swing.GroupLayout jPanel2Layout = new javax.swing.GroupLayout(jPanel2);
            jPanel2.Layout = jPanel2Layout;
            jPanel2Layout.HorizontalGroup = jPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addComponent(jSeparator1).addGroup(jPanel2Layout.createSequentialGroup().addGap(0, 0, short.MaxValue).addComponent(btnImport).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addComponent(btnExport).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addComponent(btnClose)).addComponent(jPanel1, javax.swing.GroupLayout.DEFAULT_SIZE, 576, short.MaxValue);
            jPanel2Layout.VerticalGroup   = jPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(jPanel2Layout.createSequentialGroup().addContainerGap().addComponent(jSeparator1, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addComponent(jPanel1, javax.swing.GroupLayout.PREFERRED_SIZE, 127, javax.swing.GroupLayout.PREFERRED_SIZE).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, javax.swing.GroupLayout.DEFAULT_SIZE, short.MaxValue).addGroup(jPanel2Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE).addComponent(btnExport).addComponent(btnClose).addComponent(btnImport)).addGap(31, 31, 31));

            tblBreakpoints.Font          = new Font("Courier New", 0, 12);    // NOI18N
            tblBreakpoints.Model         = memoryBreakpointsModel;
            tblBreakpoints.SelectionMode = ListSelectionModel.SINGLE_SELECTION;
            jScrollPane2.ViewportView    = tblBreakpoints;

            javax.swing.GroupLayout layout = new javax.swing.GroupLayout(ContentPane);
            ContentPane.Layout     = layout;
            layout.HorizontalGroup = layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(layout.createSequentialGroup().addContainerGap().addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING).addComponent(jScrollPane2, javax.swing.GroupLayout.PREFERRED_SIZE, 0, short.MaxValue).addGroup(javax.swing.GroupLayout.Alignment.LEADING, layout.createSequentialGroup().addGap(0, 0, short.MaxValue).addComponent(btnAdd, javax.swing.GroupLayout.PREFERRED_SIZE, 140, javax.swing.GroupLayout.PREFERRED_SIZE).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addComponent(btnRemove, javax.swing.GroupLayout.PREFERRED_SIZE, 140, javax.swing.GroupLayout.PREFERRED_SIZE)).addComponent(jPanel2, javax.swing.GroupLayout.Alignment.LEADING, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, short.MaxValue)).addContainerGap());
            layout.VerticalGroup   = layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING).addGroup(layout.createSequentialGroup().addContainerGap().addComponent(jScrollPane2, javax.swing.GroupLayout.DEFAULT_SIZE, 104, short.MaxValue).addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED).addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE).addComponent(btnAdd, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE).addComponent(btnRemove, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)).addGap(18, 18, 18).addComponent(jPanel2, javax.swing.GroupLayout.PREFERRED_SIZE, 178, javax.swing.GroupLayout.PREFERRED_SIZE).addContainerGap());

            pack();
        }         // </editor-fold>//GEN-END:initComponents
Пример #24
0
        /// <summary> The main constructor for a ShellPanel.
        /// 
        /// </summary>
        /// <param name="">engine
        /// The Jamocha engine that should be used with this GUI.
        /// 
        /// </param>
        public ShellPanel(JamochaGui gui)
            : base(gui)
        {
            InitBlock();
            // GUI construction
            // create the output area
            outputArea = new JTextArea();
            outputArea.setEditable(false);
            outputArea.setLineWrap(true);
            outputArea.setWrapStyleWord(true);
            outputArea.addFocusListener(this);
            // set the font and the colors
            settingsChanged();
            this.addFocusListener(this);
            // create a scroll pane to embedd the output area
            scrollPane = new JScrollPane(outputArea, JScrollPane.VERTICAL_SCROLLBAR_AS_NEEDED, JScrollPane.HORIZONTAL_SCROLLBAR_NEVER);
            scrollPane.VerticalScrollBar.addAdjustmentListener(this);
            // Assemble the GUI
            //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());
            //UPGRADE_ISSUE: Field 'java.awt.BorderLayout.CENTER' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtBorderLayout"'
            add(scrollPane, BorderLayout.CENTER);

            // create the button that clears the output area
            clearButton = new JButton("Clear Shell", IconLoader.getImageIcon("application_osx_terminal"));
            clearButton.addActionListener(this);
            JPanel clearButtonPanel = 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"'
            clearButtonPanel.setLayout(new FlowLayout(FlowLayout.RIGHT, 5, 1));
            clearButtonPanel.add(clearButton);
            //UPGRADE_ISSUE: Field 'java.awt.BorderLayout' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000"'
            add(clearButtonPanel, BorderLayout.PAGE_END);

            // initialize the channel to the engine
            //UPGRADE_ISSUE: Constructor 'java.io.PipedOutputStream.PipedOutputStream' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaioPipedOutputStreamPipedOutputStream"'
            System.IO.StreamWriter outStream = new PipedOutputStream();
            //UPGRADE_ISSUE: Constructor 'java.io.PipedInputStream.PipedInputStream' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaioPipedInputStreamPipedInputStream"'
            System.IO.StreamReader inStream = new PipedInputStream();
            outWriter = new System.IO.StreamWriter(outStream);
            try
            {
                //UPGRADE_ISSUE: Method 'java.io.PipedInputStream.connect' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaioPipedInputStreamconnect_javaioPipedOutputStream"'
                inStream.connect(outStream);
            }
            catch (System.IO.IOException e)
            {
                SupportClass.WriteStackTrace(e, Console.Error);
                System.Environment.Exit(1);
            }
            channel = gui.Engine.MessageRouter.openChannel("JamochaGui", inStream);

            printPrompt();
            moveCursorToEnd();
            startTimer();

            // initialize the channellistener for outputs from the engine
            initChannelListener();

            // initialize the keylistener for key events
            initKeyListener();

            // initialize the mouselistener for the context menu
            initPopupMenu();
        }
Пример #25
0
        public TemplateEditor(Rete engine)
            : base(engine)
        {
            InitBlock();
            setSize(600, 500);
            //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());
            setTitle("Create new Template");
            //UPGRADE_ISSUE: Constructor 'java.awt.BorderLayout.BorderLayout' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtBorderLayout"'
            contentPanel = new JPanel(new BorderLayout());
            //UPGRADE_ISSUE: Field 'java.awt.BorderLayout.CENTER' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtBorderLayout"'
            add(contentPanel, BorderLayout.CENTER);
            cancelButton = new JButton("Cancel", IconLoader.getImageIcon("cancel"));
            cancelButton.addActionListener(this);
            assertButton = new JButton("Create Template", IconLoader.getImageIcon("brick_add"));
            assertButton.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.CENTER' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtFlowLayout"'
            buttonPanel.setLayout(new FlowLayout(FlowLayout.CENTER, 5, 1));
            buttonPanel.add(cancelButton);
            buttonPanel.add(assertButton);
            //UPGRADE_ISSUE: Field 'java.awt.BorderLayout.SOUTH' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtBorderLayout"'
            add(buttonPanel, BorderLayout.SOUTH);

            nameField = new JTextField(15);
            Collection modules = engine.WorkingMemory.Modules;
            System.String[] moduleNames = new System.String[modules.size()];
            int i = 0;
            Iterator itr = modules.iterator();
            while (itr.hasNext())
            {
                System.Object obj = itr.next();
                moduleNames[i++] = ((Module) obj).ModuleName;
            }
            moduleBox = new JComboBox(moduleNames);

            addSlotButton = new JButton("Add Slot", IconLoader.getImageIcon("add"));
            addSlotButton.addActionListener(this);
            //UPGRADE_ISSUE: Field 'java.awt.Component.RIGHT_ALIGNMENT' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtComponentRIGHT_ALIGNMENT_f"'
            addSlotButton.setAlignmentX(Component.RIGHT_ALIGNMENT);

            JPanel topPanel = new JPanel();
            topPanel.setBorder(BorderFactory.createTitledBorder("General Template Settings"));
            //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.LEFT' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtFlowLayout"'
            topPanel.setLayout(new FlowLayout(FlowLayout.LEFT, 20, 1));
            //UPGRADE_ISSUE: Constructor 'java.awt.GridLayout.GridLayout' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtGridLayout"'
            JPanel innerTopPanel = new JPanel(new GridLayout(2, 2));
            innerTopPanel.add(new JLabel("Template-name:"));
            innerTopPanel.add(nameField);
            innerTopPanel.add(new JLabel("Template-Module:"));
            innerTopPanel.add(moduleBox);
            //UPGRADE_ISSUE: Field 'java.awt.BorderLayout.WEST' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtBorderLayout"'
            topPanel.add(innerTopPanel, BorderLayout.WEST);
            topPanel.add(addSlotButton);
            //UPGRADE_ISSUE: Field 'java.awt.BorderLayout.NORTH' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtBorderLayout"'
            add(topPanel, BorderLayout.NORTH);

            dumpAreaTemplate.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"'
            dumpAreaTemplate.setFont(new System.Drawing.Font("Courier", 12, (System.Drawing.FontStyle) System.Drawing.FontStyle.Regular));
            dumpAreaTemplate.setRows(5);

            JPanel dumpAreaPanel = new JPanel();
            dumpAreaPanel.setLayout(new BoxLayout(dumpAreaPanel, BoxLayout.Y_AXIS));
            dumpAreaPanel.setBorder(BorderFactory.createTitledBorder("Template Preview"));
            dumpAreaPanel.add(new JScrollPane(dumpAreaTemplate));
            reloadButtonDumpAreaTemplate = new JButton("Reload Template Preview", IconLoader.getImageIcon("arrow_refresh"));
            reloadButtonDumpAreaTemplate.addActionListener(this);
            dumpAreaPanel.add(reloadButtonDumpAreaTemplate);

            //UPGRADE_ISSUE: Field 'java.awt.BorderLayout.SOUTH' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtBorderLayout"'
            contentPanel.add(dumpAreaPanel, BorderLayout.SOUTH);
        }
Пример #26
0
        public EngineSettingsPanel(JamochaGui gui) : base(gui)
        {
            //UPGRADE_ISSUE: Class 'java.awt.GridBagLayout' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtGridBagLayout"'
            //UPGRADE_ISSUE: Constructor 'java.awt.GridBagLayout.GridBagLayout' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtGridBagLayout"'
            GridBagLayout gridbag = new GridBagLayout();
            //UPGRADE_ISSUE: Class 'java.awt.GridBagConstraints' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtGridBagConstraints"'
            //UPGRADE_ISSUE: Constructor 'java.awt.GridBagConstraints.GridBagConstraints' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtGridBagConstraints"'
            GridBagConstraints c = new GridBagConstraints();

            //UPGRADE_ISSUE: Field 'java.awt.GridBagConstraints.weightx' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtGridBagConstraints"'
            c.weightx = 1.0;
            setLayout(gridbag);

            // Evaluation
            addLabel(this, new JLabel("Evaluation"), gridbag, c, 0);
            //UPGRADE_ISSUE: Constructor 'java.awt.BorderLayout.BorderLayout' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtBorderLayout"'
            JPanel evaluationPanel = new JPanel(new BorderLayout());

            evaluationCheckBox = new JCheckBox();
            evaluationCheckBox.setEnabled(true);
            evaluationCheckBox.addActionListener(this);
            //UPGRADE_ISSUE: Field 'java.awt.BorderLayout.WEST' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtBorderLayout"'
            evaluationPanel.add(evaluationCheckBox, BorderLayout.WEST);
            addInputComponent(this, evaluationPanel, gridbag, c, 0);

            // Profile Assert
            addLabel(this, new JLabel("Profile Assert:"), gridbag, c, 1);
            //UPGRADE_ISSUE: Constructor 'java.awt.BorderLayout.BorderLayout' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtBorderLayout"'
            JPanel profileAssertPanel = new JPanel(new BorderLayout());

            profileAssertCheckBox = new JCheckBox();
            profileAssertCheckBox.setEnabled(true);
            profileAssertCheckBox.addActionListener(this);
            //UPGRADE_ISSUE: Field 'java.awt.BorderLayout.WEST' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtBorderLayout"'
            profileAssertPanel.add(profileAssertCheckBox, BorderLayout.WEST);
            addInputComponent(this, profileAssertPanel, gridbag, c, 1);

            // Profile Retract
            addLabel(this, new JLabel("Profile Retract:"), gridbag, c, 2);
            //UPGRADE_ISSUE: Constructor 'java.awt.BorderLayout.BorderLayout' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtBorderLayout"'
            JPanel profileRetractPanel = new JPanel(new BorderLayout());

            profileRetractCheckBox = new JCheckBox();
            profileRetractCheckBox.setEnabled(true);
            profileRetractCheckBox.addActionListener(this);
            //UPGRADE_ISSUE: Field 'java.awt.BorderLayout.WEST' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtBorderLayout"'
            profileRetractPanel.add(profileRetractCheckBox, BorderLayout.WEST);
            addInputComponent(this, profileRetractPanel, gridbag, c, 2);

            // Profile Fire
            addLabel(this, new JLabel("Profile Fire:"), gridbag, c, 3);
            //UPGRADE_ISSUE: Constructor 'java.awt.BorderLayout.BorderLayout' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtBorderLayout"'
            JPanel profileFirePanel = new JPanel(new BorderLayout());

            profileFireCheckBox = new JCheckBox();
            profileFireCheckBox.setEnabled(true);
            profileFireCheckBox.addActionListener(this);
            //UPGRADE_ISSUE: Field 'java.awt.BorderLayout.WEST' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtBorderLayout"'
            profileFirePanel.add(profileFireCheckBox, BorderLayout.WEST);
            addInputComponent(this, profileFirePanel, gridbag, c, 3);

            // Profile Add Activation
            addLabel(this, new JLabel("Profile Add Activation:"), gridbag, c, 4);
            //UPGRADE_ISSUE: Constructor 'java.awt.BorderLayout.BorderLayout' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtBorderLayout"'
            JPanel profileAddActivationPanel = new JPanel(new BorderLayout());

            profileAddActivationCheckBox = new JCheckBox();
            profileAddActivationCheckBox.setEnabled(true);
            profileAddActivationCheckBox.addActionListener(this);
            //UPGRADE_ISSUE: Field 'java.awt.BorderLayout.WEST' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtBorderLayout"'
            profileAddActivationPanel.add(profileAddActivationCheckBox, BorderLayout.WEST);
            addInputComponent(this, profileAddActivationPanel, gridbag, c, 4);

            // Profile Remove Activation
            addLabel(this, new JLabel("Profile Remove Activation:"), gridbag, c, 5);
            //UPGRADE_ISSUE: Constructor 'java.awt.BorderLayout.BorderLayout' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtBorderLayout"'
            JPanel profileRemoveActivationPanel = new JPanel(new BorderLayout());

            profileRemoveActivationCheckBox = new JCheckBox();
            profileRemoveActivationCheckBox.setEnabled(true);
            profileRemoveActivationCheckBox.addActionListener(this);
            //UPGRADE_ISSUE: Field 'java.awt.BorderLayout.WEST' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtBorderLayout"'
            profileRemoveActivationPanel.add(profileRemoveActivationCheckBox, BorderLayout.WEST);
            addInputComponent(this, profileRemoveActivationPanel, gridbag, c, 5);

            // Activations
            addLabel(this, new JLabel(" Watch Activations:"), gridbag, c, 6);
            //UPGRADE_ISSUE: Constructor 'java.awt.BorderLayout.BorderLayout' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtBorderLayout"'
            JPanel watchActivationsPanel = new JPanel(new BorderLayout());

            watchActivationsCheckBox = new JCheckBox();
            watchActivationsCheckBox.setEnabled(true);
            watchActivationsCheckBox.addActionListener(this);
            //UPGRADE_ISSUE: Field 'java.awt.BorderLayout.WEST' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtBorderLayout"'
            watchActivationsPanel.add(watchActivationsCheckBox, BorderLayout.WEST);
            addInputComponent(this, watchActivationsPanel, gridbag, c, 6);

            // Facts
            addLabel(this, new JLabel("Watch Facts:"), gridbag, c, 7);
            //UPGRADE_ISSUE: Constructor 'java.awt.BorderLayout.BorderLayout' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtBorderLayout"'
            JPanel watchFactsPanel = new JPanel(new BorderLayout());

            watchFactsCheckBox = new JCheckBox();
            watchFactsCheckBox.setEnabled(true);
            watchFactsCheckBox.addActionListener(this);
            //UPGRADE_ISSUE: Field 'java.awt.BorderLayout.WEST' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtBorderLayout"'
            watchFactsPanel.add(watchFactsCheckBox, BorderLayout.WEST);
            addInputComponent(this, watchFactsPanel, gridbag, c, 7);

            // Rules
            addLabel(this, new JLabel("Watch Rules:"), gridbag, c, 8);
            //UPGRADE_ISSUE: Constructor 'java.awt.BorderLayout.BorderLayout' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtBorderLayout"'
            JPanel watchRulesPanel = new JPanel(new BorderLayout());

            watchRulesCheckBox = new JCheckBox();
            watchRulesCheckBox.setEnabled(true);
            watchRulesCheckBox.addActionListener(this);
            //UPGRADE_ISSUE: Field 'java.awt.BorderLayout.WEST' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtBorderLayout"'
            watchRulesPanel.add(watchRulesCheckBox, BorderLayout.WEST);
            addInputComponent(this, watchRulesPanel, gridbag, c, 8);
        }
Пример #27
0
 //UPGRADE_ISSUE: Class 'java.awt.GridBagLayout' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtGridBagLayout"'
 //UPGRADE_ISSUE: Class 'java.awt.GridBagConstraints' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtGridBagConstraints"'
 private void addRemoveButton(JPanel parent, JButton button, GridBagLayout gridbag, GridBagConstraints c, int row)
 {
     //UPGRADE_ISSUE: Field 'java.awt.GridBagConstraints.gridx' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtGridBagConstraints"'
     c.gridx = 0;
     //UPGRADE_ISSUE: Field 'java.awt.GridBagConstraints.gridy' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtGridBagConstraints"'
     c.gridy = row;
     //UPGRADE_ISSUE: Field 'java.awt.GridBagConstraints.fill' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtGridBagConstraints"'
     //UPGRADE_ISSUE: Field 'java.awt.GridBagConstraints.NONE' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtGridBagConstraints"'
     c.fill = GridBagConstraints.NONE;
     //UPGRADE_ISSUE: Field 'java.awt.GridBagConstraints.anchor' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtGridBagConstraints"'
     //UPGRADE_ISSUE: Field 'java.awt.GridBagConstraints.EAST' was not converted. 'ms-help://MS.VSCC.2003/commoner/redir/redirect.htm?keyword="jlca1000_javaawtGridBagConstraints"'
     c.anchor = GridBagConstraints.EAST;
     gridbag.setConstraints(button, c);
     parent.add(button);
 }