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

📄 tabbedframe.java

📁 员工管理系统 在一个公司里员工之间都有工作上的联系。对方的联系方式
💻 JAVA
字号:
package com.worker.table;

import java.awt.*;
import java.awt.event.*;
import java.awt.print.*;
import java.awt.datatransfer.*;
import java.io.*;
import javax.swing.*;
import javax.swing.event.*;
import javax.swing.text.*;
import java.util.*;
import java.sql.*;
import javax.swing.table.*;

import com.tool.*;
import com.worker.information.*;
import com.worker.main.*;
import com.worker.table.*;
import com.worker.userpan.*;
/**
 *
 * @author Administrator
 */
public class TabbedFrame {
    private JTabbedPane userFace;
    private Worker wo;
    /** Creates a new instance of TabbedTable */
    public TabbedFrame(Worker wo) {
        userFace=new JTabbedPane();
        this.wo=wo;
    }
    
    public JTabbedPane createEdiTable() {
        JSplitPane divSpl=new JSplitPane();
        divSpl.setDividerLocation(180);
        
        final boolean editeTA=(wo.getclassify()>=7) ? true:false;
        DataTable queTable = new DataTable(new String("SELECT * FROM workerin WHERE classify<="+wo.getclassify())) {
            //waiting to rewrite according to the workerOb
            public boolean isCellEditable(int row,int col) {
                ++row;
                ++col;
                if (col>=2 && col<=getColumnCount())
                    return editeTA;
                return false;
            }
        };
        // create JTable delegate for eQTable
        TableStr frameTable = new TableStr( queTable );
        divSpl.setRightComponent( new JScrollPane(frameTable) );
        
        EditeFrame ediF=new EditeFrame();
        if (editeTA==false) {
            ediF.setBotAb(true,false,true,false);
            ediF.setTexAb(ediF.userl,false);
            ediF.setTexAb(ediF.userp,false);
            ediF.setTexAb(ediF.classify,false);
            ediF.setTexAb(ediF.salary,false);
        }
        
        //inter communication the three conponites``
        ManageCommunication mc=new ManageCommunication();
        mc.setdatatable(queTable);
        mc.settablestr(frameTable);
        mc.setediteframe(ediF);
        queTable.setmanagecommunication(mc);
        frameTable.setmanagecommunication(mc);
        ediF.setmanagecommunication(mc);
        
        divSpl.setLeftComponent(ediF);
        userFace.addTab("员工信息查看介面",divSpl);
        return userFace;
    }
    
    public JTabbedPane getMainT() {
        return userFace;
    }
}

⌨️ 快捷键说明

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