package cn.edu.ynu.sei.atm.client.ui;
import org.eclipse.swt.SWT;
import org.eclipse.swt.widgets.Button;
import org.eclipse.swt.widgets.Composite;
import org.eclipse.swt.widgets.Label;
/**
* 注意事項視窗
* @author 88250
*/
public class NoticeComposite extends Composite
{
/**
* 返回按鈕
*/
private Button returnBtn = null;
/**
* 注意事項內容
*/
private Label label = null;
/**
* 建立注意事項執行個體
* @param parent 父視窗
*/
public NoticeComposite(Composite parent)
{
super(parent, SWT.NONE);
returnBtn = new Button(parent, SWT.NONE);
returnBtn.setText("返回");
returnBtn.setBounds(79, 150, 54, 29);
label = new Label(parent, SWT.NONE);
label.setText("1、提示安全使用… 2、防止周圍有人竊取密碼 3、吞卡處理");
label.setBounds(71, 81, 150, 50);
}
/**
* 設定注意事項容器內控制項的可見度
* @param b 可見度
*/
public void setContentsVisible(boolean b)
{
label.setVisible(b);
returnBtn.setVisible(b);
}
/**
* 取得返回按鈕
* @return 返回按鈕
*/
public Button getReturnBtn()
{
return returnBtn;
}
@Override
public void dispose()
{
super.dispose();
}
@Override
protected void checkSubclass()
{
// Disable the check that prevents subclassing of SWT components
}
}