[ FR 2944893 ] - Improve the visual layout of Info and InfoProduct task pane
https://sourceforge.net/tracker/?func=detail&aid=2944893&group_id=176962&atid=879335 Link to SF Tracker: http://sourceforge.net/support/tracker.php?aid=2944893
This commit is contained in:
parent
217188b3f0
commit
ea9349b5cc
|
@ -20,6 +20,7 @@ import java.awt.BorderLayout;
|
||||||
import java.awt.Cursor;
|
import java.awt.Cursor;
|
||||||
import java.awt.Dimension;
|
import java.awt.Dimension;
|
||||||
import java.awt.Frame;
|
import java.awt.Frame;
|
||||||
|
import java.awt.Toolkit;
|
||||||
import java.awt.event.ActionEvent;
|
import java.awt.event.ActionEvent;
|
||||||
import java.awt.event.MouseEvent;
|
import java.awt.event.MouseEvent;
|
||||||
import java.math.BigDecimal;
|
import java.math.BigDecimal;
|
||||||
|
@ -267,8 +268,11 @@ public abstract class Info extends CDialog
|
||||||
} // showAssignment
|
} // showAssignment
|
||||||
|
|
||||||
/** Window Width */
|
/** Window Width */
|
||||||
protected static final int INFO_WIDTH = 800;
|
Toolkit toolkit = Toolkit.getDefaultToolkit();
|
||||||
|
Dimension screensize = toolkit.getScreenSize();
|
||||||
|
|
||||||
|
protected final int INFO_WIDTH = screensize.width > 1500 ? 1500 : screensize.width - 100;
|
||||||
|
protected final int SCREEN_HEIGHT = screensize.height;
|
||||||
|
|
||||||
/**************************************************************************
|
/**************************************************************************
|
||||||
* Detail Constructor
|
* Detail Constructor
|
||||||
|
@ -277,7 +281,7 @@ public abstract class Info extends CDialog
|
||||||
* @param WindowNo window no
|
* @param WindowNo window no
|
||||||
* @param tableName table name
|
* @param tableName table name
|
||||||
* @param keyColumn key column name
|
* @param keyColumn key column name
|
||||||
* @param multiSelection muiliple selection
|
* @param multiSelection multiple selection
|
||||||
* @param whereClause where clause
|
* @param whereClause where clause
|
||||||
*/
|
*/
|
||||||
protected Info (Frame frame, boolean modal, int WindowNo,
|
protected Info (Frame frame, boolean modal, int WindowNo,
|
||||||
|
|
|
@ -326,13 +326,13 @@ public class InfoProduct extends Info implements ActionListener, ChangeListener
|
||||||
|
|
||||||
CTabbedPane jTab = new CTabbedPane();
|
CTabbedPane jTab = new CTabbedPane();
|
||||||
jTab.addTab(Msg.translate(Env.getCtx(), "Warehouse"), new JScrollPane(warehouseTbl));
|
jTab.addTab(Msg.translate(Env.getCtx(), "Warehouse"), new JScrollPane(warehouseTbl));
|
||||||
jTab.setPreferredSize(new Dimension(INFO_WIDTH, 105));
|
jTab.setPreferredSize(new Dimension(INFO_WIDTH, SCREEN_HEIGHT > 600 ? 250 : 105));
|
||||||
jTab.addTab(Msg.translate(Env.getCtx(), "Description"), new JScrollPane(fieldDescription));
|
jTab.addTab(Msg.translate(Env.getCtx(), "Description"), new JScrollPane(fieldDescription));
|
||||||
jTab.addTab(Msg.translate(Env.getCtx(), "Substitute_ID"), new JScrollPane(substituteTbl));
|
jTab.addTab(Msg.translate(Env.getCtx(), "Substitute_ID"), new JScrollPane(substituteTbl));
|
||||||
jTab.addTab(Msg.translate(Env.getCtx(), "RelatedProduct_ID"), new JScrollPane(relatedTbl));
|
jTab.addTab(Msg.translate(Env.getCtx(), "RelatedProduct_ID"), new JScrollPane(relatedTbl));
|
||||||
jTab.addTab (Msg.getMsg(Env.getCtx(), "ATP"), new JScrollPane(m_tableAtp));
|
jTab.addTab (Msg.getMsg(Env.getCtx(), "ATP"), new JScrollPane(m_tableAtp));
|
||||||
jTab.addChangeListener(this);
|
jTab.addChangeListener(this);
|
||||||
tablePanel.setPreferredSize(new Dimension(INFO_WIDTH, 110));
|
tablePanel.setPreferredSize(new Dimension(INFO_WIDTH, SCREEN_HEIGHT > 600 ? 255 : 110));
|
||||||
tablePanel.add(jTab);
|
tablePanel.add(jTab);
|
||||||
|
|
||||||
warehouseStockPanel.setExpanded(false);
|
warehouseStockPanel.setExpanded(false);
|
||||||
|
|
Loading…
Reference in New Issue