|
|
马上注册,结交更多好友,享用更多功能,让你轻松玩转社区。如果您注册时有任何问题请联系客服QQ: 83569622 。
您需要 登录 才可以下载或查看,没有帐号?注册
x
希望对初学者有一点点帮助:
1.去掉启动时的主界面下面显示的进度条
package org.compiere.apps;
public class AMenuStartItem extends Thread implements ActionListener
{
*****************
public void run()
{
*********************
//SwingUtilities.invokeLater(m_resetPB);//把所有出现这行代码的地方去掉
********************
//SwingUtilities.invokeLater(m_updatePB);//把所有出现这行代码的地方去掉
}
}
2.去掉选择下的"显示翻译"CHECKBOX控件
package org.compiere.apps;
public final class Preference extends CDialog
implements ActionListener, ListSelectionListener
{
*******************
void jbInit() throws Exception
{
************************8
//customizePane.add(showTrl, new GridBagConstraints(2, 4, 1, 1, 0.0, 0.0
// ,GridBagConstraints.WEST, GridBagConstraints.NONE, new Insets(5, 5, 5, 5), 0, 0));
***************************
}
}
3.去掉"选项"下的"上下文"和"错误"页
package org.compiere.apps;
public final class Preference extends CDialog
implements ActionListener, ListSelectionListener
{
********************
void jbInit() throws Exception
{
*********************
//tabPane.add(contextPane, Msg.getMsg(Env.getCtx(), "Context"));
*****************************
//tabPane.add(errorPane, "Errors");
**********************
}
private void cmd_displayErrors()
{
**********************
/*if (bErrorsOnly.isSelected())
tabPane.setTitleAt(2, Msg.getMsg(Env.getCtx(), "Errors") + " (" + data.size() + ")");
else
tabPane.setTitleAt(2, Msg.getMsg(Env.getCtx(), "TraceInfo") + " (" + data.size() + ")");
*/
******************
}
4.去掉"选项"中的选择下的"用户界面设置""角色"两个按钮
package org.compiere.apps;
public final class Preference extends CDialog
implements ActionListener, ListSelectionListener
{
***************
void jbInit() throws Exception
{
*********************
//customizePane.add(uiTheme, new GridBagConstraints(1, 1, 1, 1, 0.0, 0.0
// ,GridBagConstraints.WEST, GridBagConstraints.NONE, new Insets(5, 5, 5, 5), 0, 0));
//customizePane.add(bRoleInfo, new GridBagConstraints(2, 1, 1, 1, 0.0, 0.0
// ,GridBagConstraints.EAST, GridBagConstraints.NONE, new Insets(5, 5, 5, 5), 0, 0));
*****************
}
}
5.去掉菜单中的"脚本""编辑器"
package org.compiere.apps;
public final class APanel extends CPanel
implements DataStatusListener, ChangeListener, ActionListener, ASyncProcess
{
***************
private void createMenu()
{
****************
//不显示下面两个菜单项
//aEditor = addAction("Editor", mTools, null, false);
//aScript = addAction("Script", mTools, null, false);
******************
}
****************
}
package org.compiere.apps.form;
public class FormFrame extends JFrame
implements ActionListener
{
***********************
private void createMenu()
{
********************
//AEnv.addMenuItem("Editor", null, null, mTools, this);
//AEnv.addMenuItem("Script", null, null, mTools, this);
****************************
}
******************
}
package org.compiere.apps;
public final class AMenu extends JFrame
implements ActionListener, PropertyChangeListener, ChangeListener
{
********************
private void createMenu()
{
***********************
//AEnv.addMenuItem("Editor", null, null, mTools, this);
//AEnv.addMenuItem("Script", null, null, mTools, this);
******************
}
**********
}
6.设置启动时"连接服务器"
注释掉代码:
package org.compiere.apps;
public final class ALogin extends JDialog
implements ActionListener, ChangeListener
{
private void jbInit() throws Exception
{
**********************
//loginPanel.add(hostLabel, new GridBagConstraints(0, 2, 1, 1, 0.0, 0.0
// ,GridBagConstraints.EAST, GridBagConstraints.NONE, new Insets(5, 12, 5, 5), 0, 0));
//loginPanel.add(hostField, new GridBagConstraints(1, 2, 3, 1, 1.0, 0.0
// ,GridBagConstraints.WEST, GridBagConstraints.HORIZONTAL, new Insets(5, 0, 5, 12), 0, 0));
*********************
cbPanel.add(hostField,FlowLayout.LEFT);
*******************************
southPanel.add(cbPanel,BorderLayout.WEST);
mainPanel.add(southPanel, BorderLayout.SOUTH);
**********************
}
}
package org.compiere.db;
public class CConnectionEditor extends JComponent
implements CEditor
{
public CConnectionEditor()
{
*****************
m_db.setFocusable(true);//可以得到焦点 修改后
****************
m_db.addFocusListener(new FocusListener(){
public void focusGained(FocusEvent e)
{
m_db.setIcon(new ImageIcon(getClass().getResource("Database15.gif")));
}
public void focusLost(FocusEvent ev)
{
m_db.setIcon(new ImageIcon(getClass().getResource("Database16.gif")));
}
});
********************
//add(m_server, BorderLayout.WEST);
//add(m_text, BorderLayout.CENTER);
这个是我把启动时的连接服务器的显示控件隐藏然后改变样式...
7.修改登录界面的图像
package org.compiere.apps;public final class ALogin extends JDialog implements ActionListener, ChangeListener{ private CPanel imagePanel = new CPanel(new BorderLayout()); ************************* private CLabel lblTitle = new CLabel(); ************************* private void jbInit() throws Exception { ********************************* lblTitle.setIcon(Env.getImageIcon("title.gif")); lblTitle.setOpaque(true); lblTitle.setHorizontalAlignment(SwingConstants.CENTER); lblTitle.setVerticalTextPosition(SwingConstants.CENTER); ************************* imagePanel.add(lblTitle,BorderLayout.CENTER); ******************************* mainPanel.add(imagePanel,BorderLayout.NORTH); }
9.设置固定的背景颜色
package org.compiere.plaf;
classname CompiereTheme
504行
CompiereColor.setDefaultBackground(CompiereColor.parse("CompiereColor[Flat [r=204,g=204,b=204,a=255]]"));//Ini.getProperty(P_CompiereColor))); 注:这个类用于设置用户自定义的用户界面.和一些常用的配置
10.因翻译工作没有完成,所以现在系统中的所有帮助去掉
(一)去掉所有应用程序的帮助文本
在Client/org.compiere.apps/Help.java
94行
//2005-8-30 去掉帮助
//info.setText(helpHtml);
140行
//info.setText(doc.toString());
(二)去掉处理对话框中的处理帮助信息
在Client/org.compiere.apps/ProcessDidog.java
260行
//message.setText(m_messageText.toString());
(三)去掉报表帮助信息
在Client/org.compiere.print/Viewer.java
410行
mHelp.setVisible(false);//增加
(四)去掉要独立窗口上的帮助
在Client/org.compiere.form/FormFrame.java
143行
mHelp.setVisible(false);//增加
(五)去掉登录系统时的帮助
在Client/org.compiere.apps/ALogin.java
281行
//loginTabPane.add(helpPanel, "?");
(六)去掉主窗口上的帮助
在Client/org.compiere.apps/Amenu.java
333行
mHelp.setVisible(false);//增加
(七)去掉业务窗口上的帮助
在Client/org.compiere.apps/
245行
mHelp.setVisible(false);//增加 |
|