mirror of https://github.com/acidanthera/audk.git
Do not display token number for Pcd in ModuleSA and Dynamic Pcd editors for FPD file.
git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@1821 6f19259b-4bc3-4df7-8a09-765794883524
This commit is contained in:
parent
453a815ba0
commit
2cd33eaf82
|
@ -11,6 +11,7 @@ import javax.swing.ListSelectionModel;
|
||||||
import javax.swing.event.ListSelectionEvent;
|
import javax.swing.event.ListSelectionEvent;
|
||||||
import javax.swing.event.ListSelectionListener;
|
import javax.swing.event.ListSelectionListener;
|
||||||
import javax.swing.table.DefaultTableModel;
|
import javax.swing.table.DefaultTableModel;
|
||||||
|
import javax.swing.table.TableColumn;
|
||||||
|
|
||||||
import org.tianocore.PlatformSurfaceAreaDocument;
|
import org.tianocore.PlatformSurfaceAreaDocument;
|
||||||
import org.tianocore.frameworkwizard.common.DataValidation;
|
import org.tianocore.frameworkwizard.common.DataValidation;
|
||||||
|
@ -84,6 +85,7 @@ public class FpdDynamicPcdBuildDefinitions extends IInternalFrame {
|
||||||
public void init(PlatformSurfaceAreaDocument.PlatformSurfaceArea fpd) {
|
public void init(PlatformSurfaceAreaDocument.PlatformSurfaceArea fpd) {
|
||||||
if (ffc == null) {
|
if (ffc == null) {
|
||||||
ffc = new FpdFileContents(fpd);
|
ffc = new FpdFileContents(fpd);
|
||||||
|
ffc.initDynPcdMap();
|
||||||
}
|
}
|
||||||
String[][] saa = new String[ffc.getDynamicPcdBuildDataCount()][5];
|
String[][] saa = new String[ffc.getDynamicPcdBuildDataCount()][5];
|
||||||
ffc.getDynamicPcdBuildData(saa);
|
ffc.getDynamicPcdBuildData(saa);
|
||||||
|
@ -154,7 +156,8 @@ public class FpdDynamicPcdBuildDefinitions extends IInternalFrame {
|
||||||
modelPcd.addColumn("DatumType");
|
modelPcd.addColumn("DatumType");
|
||||||
jTableDynPcd = new JTable(modelPcd);
|
jTableDynPcd = new JTable(modelPcd);
|
||||||
jTableDynPcd.setRowHeight(20);
|
jTableDynPcd.setRowHeight(20);
|
||||||
|
TableColumn tokenColumn = jTableDynPcd.getColumnModel().getColumn(1);
|
||||||
|
jTableDynPcd.removeColumn(tokenColumn);
|
||||||
jTableDynPcd.getColumnModel().getColumn(0).setMinWidth(250);
|
jTableDynPcd.getColumnModel().getColumn(0).setMinWidth(250);
|
||||||
|
|
||||||
jTableDynPcd.setSelectionMode(ListSelectionModel.SINGLE_SELECTION);
|
jTableDynPcd.setSelectionMode(ListSelectionModel.SINGLE_SELECTION);
|
||||||
|
@ -556,6 +559,9 @@ public class FpdDynamicPcdBuildDefinitions extends IInternalFrame {
|
||||||
if (jRadioButtonHii.isSelected()) {
|
if (jRadioButtonHii.isSelected()) {
|
||||||
ffc.genDynamicPcdBuildDataSkuInfo("0", varName, varGuid, varOffset, hiiDefault, null, null, pcdSelected);
|
ffc.genDynamicPcdBuildDataSkuInfo("0", varName, varGuid, varOffset, hiiDefault, null, null, pcdSelected);
|
||||||
ArrayList<String> al = ffc.getDynPcdMapValue(cName + " " + tsGuid);
|
ArrayList<String> al = ffc.getDynPcdMapValue(cName + " " + tsGuid);
|
||||||
|
if (al == null) {
|
||||||
|
return;
|
||||||
|
}
|
||||||
for (int i = 0; i < al.size(); ++i) {
|
for (int i = 0; i < al.size(); ++i) {
|
||||||
String mKey = moduleInfo (al.get(i));
|
String mKey = moduleInfo (al.get(i));
|
||||||
ffc.updatePcdData(mKey, cName, tsGuid, null, null, hiiDefault);
|
ffc.updatePcdData(mKey, cName, tsGuid, null, null, hiiDefault);
|
||||||
|
@ -564,6 +570,9 @@ public class FpdDynamicPcdBuildDefinitions extends IInternalFrame {
|
||||||
else if (jRadioButtonVpd.isSelected()){
|
else if (jRadioButtonVpd.isSelected()){
|
||||||
ffc.genDynamicPcdBuildDataSkuInfo("0", null, null, null, null, vpdOffset, null, pcdSelected);
|
ffc.genDynamicPcdBuildDataSkuInfo("0", null, null, null, null, vpdOffset, null, pcdSelected);
|
||||||
ArrayList<String> al = ffc.getDynPcdMapValue(cName + " " + tsGuid);
|
ArrayList<String> al = ffc.getDynPcdMapValue(cName + " " + tsGuid);
|
||||||
|
if (al == null) {
|
||||||
|
return;
|
||||||
|
}
|
||||||
for (int i = 0; i < al.size(); ++i) {
|
for (int i = 0; i < al.size(); ++i) {
|
||||||
String mKey = moduleInfo (al.get(i));
|
String mKey = moduleInfo (al.get(i));
|
||||||
ffc.updatePcdData(mKey, cName, tsGuid, null, null, vpdOffset);
|
ffc.updatePcdData(mKey, cName, tsGuid, null, null, vpdOffset);
|
||||||
|
@ -572,6 +581,9 @@ public class FpdDynamicPcdBuildDefinitions extends IInternalFrame {
|
||||||
else{
|
else{
|
||||||
ffc.genDynamicPcdBuildDataSkuInfo("0", null, null, null, null, null, value, pcdSelected);
|
ffc.genDynamicPcdBuildDataSkuInfo("0", null, null, null, null, null, value, pcdSelected);
|
||||||
ArrayList<String> al = ffc.getDynPcdMapValue(cName + " " + tsGuid);
|
ArrayList<String> al = ffc.getDynPcdMapValue(cName + " " + tsGuid);
|
||||||
|
if (al == null) {
|
||||||
|
return;
|
||||||
|
}
|
||||||
for (int i = 0; i < al.size(); ++i) {
|
for (int i = 0; i < al.size(); ++i) {
|
||||||
String mKey = moduleInfo (al.get(i));
|
String mKey = moduleInfo (al.get(i));
|
||||||
ffc.updatePcdData(mKey, cName, tsGuid, null, null, value);
|
ffc.updatePcdData(mKey, cName, tsGuid, null, null, value);
|
||||||
|
|
|
@ -689,6 +689,9 @@ public class FpdModuleSA extends JDialog implements ActionListener {
|
||||||
|
|
||||||
jTablePcd.getColumnModel().getColumn(0).setMinWidth(250);
|
jTablePcd.getColumnModel().getColumn(0).setMinWidth(250);
|
||||||
|
|
||||||
|
TableColumn tokenColumn = jTablePcd.getColumnModel().getColumn(3);
|
||||||
|
jTablePcd.removeColumn(tokenColumn);
|
||||||
|
|
||||||
jTablePcd.setSelectionMode(ListSelectionModel.SINGLE_SELECTION);
|
jTablePcd.setSelectionMode(ListSelectionModel.SINGLE_SELECTION);
|
||||||
jTablePcd.getSelectionModel().addListSelectionListener(new ListSelectionListener(){
|
jTablePcd.getSelectionModel().addListSelectionListener(new ListSelectionListener(){
|
||||||
public void valueChanged(ListSelectionEvent e) {
|
public void valueChanged(ListSelectionEvent e) {
|
||||||
|
|
Loading…
Reference in New Issue