nc 自定义dialog
来源:互联网 发布:ansys仿真软件价格 编辑:程序博客网 时间:2024/05/16 23:33
package nc.ui.so.m30.billui.action.link;
import java.awt.BorderLayout;
import java.awt.FlowLayout;
import java.awt.event.ActionEvent;
import java.awt.event.ActionListener;
import nc.ui.pub.beans.UIButton;
import nc.ui.pub.beans.UIDialog;
import nc.ui.pub.beans.UIPanel;
import nc.ui.pub.bill.BillCardPanel;
import nc.ui.pub.bill.BillData;
import nc.ui.pub.bill.BillItem;
public class GPSMessageDialog extends UIDialog{
public static void main(String[] args) {
BillItem[] bodyItems1 = new BillItem[11];
for(int i = 0;i<bodyItems1.length;i++){
bodyItems1[i] = new BillItem();
bodyItems1[i].setName("测试"+i);
bodyItems1[i].setKey("test"+i);
bodyItems1[i].setShow(true);
bodyItems1[i].setRefType("");
bodyItems1[i].setEdit(false);
bodyItems1[i].setLoadFormula(null);
bodyItems1[i].setWidth(159);
}
GPSMessageDialog td=new GPSMessageDialog();
td.setBodyItems(bodyItems1);
td.showModal();
}
public GPSMessageDialog(){
this.setName("出库车辆GPS信息");
this.setTitle("出库车辆GPS信息");
this.setSize(500, 500);
this.setContentPane(getPanel());
}
private BillCardPanel cardPanel = null;
private BillItem[] bodyItems = null;
private UIPanel panel = null;
private UIPanel btnPanel=null;
public BillCardPanel getCardPanel() {
if(cardPanel == null){
cardPanel = new BillCardPanel();
cardPanel.setName("cardPanel");
BillData data = new BillData();
data.setBodyItems(getBodyItems());
cardPanel.setBillData(data);
cardPanel.setBodyMenuShow(false);
cardPanel.setEnabled(false);
cardPanel.addLine();
}
return cardPanel;
}
public void setCardPanel(BillCardPanel cardPanel) {
this.cardPanel = cardPanel;
}
public BillItem[] getBodyItems() {
if(bodyItems == null){
bodyItems = new BillItem[11];
for(int i = 0;i<bodyItems.length;i++){
bodyItems[i] = new BillItem();
bodyItems[i].setName("测试"+(i+1));
bodyItems[i].setKey("test"+i);
bodyItems[i].setShow(true);
bodyItems[i].setRefType("");
bodyItems[i].setEdit(false);
bodyItems[i].setLoadFormula(null);
bodyItems[i].setWidth(159);
}
}
return bodyItems;
}
public void setBodyItems(BillItem[] bodyItems) {
this.bodyItems = bodyItems;
}
public UIPanel getPanel() {
if(panel == null){
panel = new UIPanel();
panel.setName("panel");
panel.setLayout(new BorderLayout());
panel.add(getCardPanel(),BorderLayout.CENTER);
panel.add(getBtnPanel(),BorderLayout.SOUTH);
}
return panel;
}
public void setPanel(UIPanel panel) {
this.panel = panel;
}
public UIPanel getBtnPanel() {
if(btnPanel == null){
btnPanel = new UIPanel();
btnPanel.setName("btnPanel");
UIButton btn=new UIButton("确定");
btn.addActionListener(new ActionListener() {
@Override
public void actionPerformed(ActionEvent e) {
closeOK();
}
});
FlowLayout fl=new FlowLayout(FlowLayout.RIGHT);
btnPanel.setLayout(fl);
btnPanel.add(btn);
}
return btnPanel;
}
public void setBtnPanel(UIPanel btnPanel) {
this.btnPanel = btnPanel;
}
}
import java.awt.BorderLayout;
import java.awt.FlowLayout;
import java.awt.event.ActionEvent;
import java.awt.event.ActionListener;
import nc.ui.pub.beans.UIButton;
import nc.ui.pub.beans.UIDialog;
import nc.ui.pub.beans.UIPanel;
import nc.ui.pub.bill.BillCardPanel;
import nc.ui.pub.bill.BillData;
import nc.ui.pub.bill.BillItem;
public class GPSMessageDialog extends UIDialog{
public static void main(String[] args) {
BillItem[] bodyItems1 = new BillItem[11];
for(int i = 0;i<bodyItems1.length;i++){
bodyItems1[i] = new BillItem();
bodyItems1[i].setName("测试"+i);
bodyItems1[i].setKey("test"+i);
bodyItems1[i].setShow(true);
bodyItems1[i].setRefType("");
bodyItems1[i].setEdit(false);
bodyItems1[i].setLoadFormula(null);
bodyItems1[i].setWidth(159);
}
GPSMessageDialog td=new GPSMessageDialog();
td.setBodyItems(bodyItems1);
td.showModal();
}
public GPSMessageDialog(){
this.setName("出库车辆GPS信息");
this.setTitle("出库车辆GPS信息");
this.setSize(500, 500);
this.setContentPane(getPanel());
}
private BillCardPanel cardPanel = null;
private BillItem[] bodyItems = null;
private UIPanel panel = null;
private UIPanel btnPanel=null;
public BillCardPanel getCardPanel() {
if(cardPanel == null){
cardPanel = new BillCardPanel();
cardPanel.setName("cardPanel");
BillData data = new BillData();
data.setBodyItems(getBodyItems());
cardPanel.setBillData(data);
cardPanel.setBodyMenuShow(false);
cardPanel.setEnabled(false);
cardPanel.addLine();
}
return cardPanel;
}
public void setCardPanel(BillCardPanel cardPanel) {
this.cardPanel = cardPanel;
}
public BillItem[] getBodyItems() {
if(bodyItems == null){
bodyItems = new BillItem[11];
for(int i = 0;i<bodyItems.length;i++){
bodyItems[i] = new BillItem();
bodyItems[i].setName("测试"+(i+1));
bodyItems[i].setKey("test"+i);
bodyItems[i].setShow(true);
bodyItems[i].setRefType("");
bodyItems[i].setEdit(false);
bodyItems[i].setLoadFormula(null);
bodyItems[i].setWidth(159);
}
}
return bodyItems;
}
public void setBodyItems(BillItem[] bodyItems) {
this.bodyItems = bodyItems;
}
public UIPanel getPanel() {
if(panel == null){
panel = new UIPanel();
panel.setName("panel");
panel.setLayout(new BorderLayout());
panel.add(getCardPanel(),BorderLayout.CENTER);
panel.add(getBtnPanel(),BorderLayout.SOUTH);
}
return panel;
}
public void setPanel(UIPanel panel) {
this.panel = panel;
}
public UIPanel getBtnPanel() {
if(btnPanel == null){
btnPanel = new UIPanel();
btnPanel.setName("btnPanel");
UIButton btn=new UIButton("确定");
btn.addActionListener(new ActionListener() {
@Override
public void actionPerformed(ActionEvent e) {
closeOK();
}
});
FlowLayout fl=new FlowLayout(FlowLayout.RIGHT);
btnPanel.setLayout(fl);
btnPanel.add(btn);
}
return btnPanel;
}
public void setBtnPanel(UIPanel btnPanel) {
this.btnPanel = btnPanel;
}
}
0 0
- nc 自定义dialog
- nc Dialog 的自定义 BillCardPanel
- nc 自定义VO
- 自定义Dialog---继承Dialog
- 自定义Dialog android Dialog
- 自定义Dialog
- 自定义Dialog
- 自定义dialog
- 自定义 Dialog
- 自定义dialog
- 自定义 dialog
- 自定义Dialog
- 自定义 Dialog
- 自定义Dialog
- 自定义dialog
- 自定义Dialog
- 自定义 Dialog
- 自定义Dialog
- 浅谈java字符串
- 图结构练习——最小生成树
- android 逆向 初级(一)
- Git工具比较:sourcetree tortoisegit
- Android中自动跳转到系统设置界面
- nc 自定义dialog
- Couchbase 分享 PPT
- 黑马程序员--代码块学习
- Servlet 工作原理解析
- 欢迎使用CSDN-markdown编辑器
- 【日常学习】乘法逆元&&欧拉定理&&费马小定理&&欧拉函数应用&&常大学霸
- 使用fuel 6.0 部署openstack Juno 版本
- 【shell】ps 结合grep查找时,去掉grep自身匹配的那行
- GA/GP中的适应度函数