⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 output.java~21~

📁 这个是朋友作的毕业设计
💻 JAVA~21~
字号:
package Resource_Selection;

import java.awt.*;
import java.awt.event.*;
import javax.swing.*;

public class output extends JFrame {
  JPanel contentPane;
  //Construct the frame
  public output() {
    enableEvents(AWTEvent.WINDOW_EVENT_MASK);
    try {
      jbInit();
    }
    catch(Exception e) {
      e.printStackTrace();
    }
  }
  //Component initialization
  private void jbInit() throws Exception  {
    contentPane = (JPanel) this.getContentPane();
    contentPane.setLayout(null);
    this.setSize(new Dimension(400, 300));
    this.setTitle("输出选择结果");
    int i=0,j=0;
    JLabel jLabel[];
    jLabel = new JLabel[10];
    i=0;
    while(i<Resource_Selection.select.contra2)
    {
      if(Resource_Selection.select.a[Resource_Selection.select.output_no][i]==1)
      {
        jLabel[j] = new JLabel();
        jLabel[j].setText(Resource_Selection.select.que[i].ip);
        jLabel[j].setBounds(new Rectangle(20, 10 + 30 * j, 100, 30));
        contentPane.add(jLabel[j], null);
        j++;
      }
      i++;
      if(j==Resource_Selection.select.process_no){
        break;
      }
    }
  }
  //Overridden so we can exit when window is closed
  protected void processWindowEvent(WindowEvent e) {
    super.processWindowEvent(e);
    if (e.getID() == WindowEvent.WINDOW_CLOSING) {
      this.dispose();
    }
  }
}

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -