Umstrukturireung macht die internen Klassen zu externen
git-svn-id: https://svn.libreccm.org/ccm/trunk@1764 8810af33-2d31-482b-a856-94f89814c4dfmaster
parent
9f93f1a7c5
commit
29eaf69880
|
|
@ -18,46 +18,29 @@
|
|||
|
||||
package com.arsdigita.cms.contentassets.ui;
|
||||
|
||||
import com.arsdigita.bebop.ActionLink;
|
||||
import com.arsdigita.bebop.ColumnPanel;
|
||||
import com.arsdigita.bebop.Component;
|
||||
import com.arsdigita.bebop.Form;
|
||||
import com.arsdigita.bebop.FormProcessException;
|
||||
import com.arsdigita.bebop.Label;
|
||||
import com.arsdigita.bebop.MapComponentSelectionModel;
|
||||
import com.arsdigita.bebop.Page;
|
||||
import com.arsdigita.bebop.PageState;
|
||||
import com.arsdigita.bebop.ParameterSingleSelectionModel;
|
||||
import com.arsdigita.bebop.SaveCancelSection;
|
||||
import com.arsdigita.bebop.SimpleContainer;
|
||||
import com.arsdigita.bebop.event.ActionEvent;
|
||||
import com.arsdigita.bebop.event.ActionListener;
|
||||
import com.arsdigita.bebop.event.FormInitListener;
|
||||
import com.arsdigita.bebop.event.FormProcessListener;
|
||||
import com.arsdigita.bebop.event.FormSectionEvent;
|
||||
import com.arsdigita.bebop.event.ParameterEvent;
|
||||
import com.arsdigita.bebop.event.ParameterListener;
|
||||
import com.arsdigita.bebop.form.TextArea;
|
||||
import com.arsdigita.bebop.form.TextField;
|
||||
import com.arsdigita.bebop.parameters.BigDecimalParameter;
|
||||
import com.arsdigita.bebop.parameters.NotNullValidationListener;
|
||||
import com.arsdigita.bebop.parameters.ParameterData;
|
||||
import com.arsdigita.bebop.parameters.StringLengthValidationListener;
|
||||
import com.arsdigita.bebop.parameters.StringParameter;
|
||||
import com.arsdigita.cms.ContentItem;
|
||||
import com.arsdigita.cms.ImageAsset;
|
||||
import com.arsdigita.cms.ItemSelectionModel;
|
||||
import com.arsdigita.cms.ReusableImageAsset;
|
||||
import com.arsdigita.cms.contentassets.ItemImageAttachment;
|
||||
import com.arsdigita.cms.ui.FileUploadSection;
|
||||
import com.arsdigita.cms.ui.ImageBrowser;
|
||||
import com.arsdigita.cms.ui.ImageChooser;
|
||||
import com.arsdigita.domain.DataObjectNotFoundException;
|
||||
import com.arsdigita.cms.ui.ImageComponent;
|
||||
import com.arsdigita.cms.ui.ImageLibraryComponent;
|
||||
import com.arsdigita.cms.ui.ImageUploadComponent;
|
||||
import com.arsdigita.persistence.DataCollection;
|
||||
import com.arsdigita.util.Assert;
|
||||
import com.arsdigita.util.StringUtils;
|
||||
import java.io.File;
|
||||
import java.io.IOException;
|
||||
import java.math.BigDecimal;
|
||||
import java.util.HashMap;
|
||||
import java.util.Iterator;
|
||||
|
|
@ -205,281 +188,281 @@ public class ImageStepEdit extends SimpleContainer
|
|||
attachment.setUseContext( component.getUseContext( event ) );
|
||||
}
|
||||
|
||||
interface ImageComponent {
|
||||
ReusableImageAsset getImage( FormSectionEvent event )
|
||||
throws FormProcessException;
|
||||
String getCaption( FormSectionEvent event );
|
||||
String getDescription( FormSectionEvent event );
|
||||
String getTitle( FormSectionEvent event );
|
||||
String getUseContext( FormSectionEvent event );
|
||||
SaveCancelSection getSaveCancelSection();
|
||||
Form getForm();
|
||||
}
|
||||
|
||||
private class ImageUploadComponent extends Form
|
||||
implements ImageComponent {
|
||||
private final FileUploadSection m_imageFile;
|
||||
private final TextField m_caption;
|
||||
private final TextField m_title;
|
||||
private final TextArea m_description;
|
||||
private final TextField m_useContext;
|
||||
private final SaveCancelSection m_saveCancel;
|
||||
|
||||
public ImageUploadComponent() {
|
||||
super("imageStepEditUpload", new ColumnPanel(2));
|
||||
|
||||
setEncType("multipart/form-data");
|
||||
|
||||
// Ignoring deprecated constructor.
|
||||
m_imageFile = new FileUploadSection("Image Type",
|
||||
"image", ImageAsset.MIME_JPEG);
|
||||
m_imageFile.getFileUploadWidget()
|
||||
.addValidationListener(new NotNullValidationListener());
|
||||
|
||||
add( m_imageFile, ColumnPanel.FULL_WIDTH );
|
||||
|
||||
add(new Label("Caption"));
|
||||
m_caption = new TextField("caption");
|
||||
m_caption.addValidationListener(new NotNullValidationListener());
|
||||
m_caption.addValidationListener(new StringLengthValidationListener(40));
|
||||
m_caption.setSize(40);
|
||||
add(m_caption);
|
||||
|
||||
m_title = new TextField("title");
|
||||
m_description = new TextArea("description");
|
||||
|
||||
// We only show the title and description fields in the case where
|
||||
// getIsImageStepDescriptionAndTitleShown is false.
|
||||
if (ItemImageAttachment.getConfig().getIsImageStepDescriptionAndTitleShown()) {
|
||||
add(new Label("Title"));
|
||||
m_title.addValidationListener(new NotNullValidationListener());
|
||||
m_title.setSize(40);
|
||||
m_title.addValidationListener(new StringLengthValidationListener(40));
|
||||
add(m_title);
|
||||
|
||||
add(new Label("Description"));
|
||||
m_description.addValidationListener(new NotNullValidationListener());
|
||||
m_description.addValidationListener(new StringLengthValidationListener(600));
|
||||
m_description.setCols(30);
|
||||
m_description.setRows(5);
|
||||
add(m_description);
|
||||
|
||||
}
|
||||
|
||||
add(new Label("Use Context"));
|
||||
m_useContext = new TextField("useContext");
|
||||
m_useContext.setSize(40);
|
||||
// Removed to use multiple images with fancyBox
|
||||
// m_useContext.addValidationListener( new UniqueUseContextListener() );
|
||||
add(m_useContext);
|
||||
|
||||
m_saveCancel = new SaveCancelSection();
|
||||
add(m_saveCancel);
|
||||
|
||||
/* Removed by Quasimodo: Changed editing workflow, so that library comes first
|
||||
* Also, library mode has now a link to upload images whixh will link to this
|
||||
* form. Consequently, this link will create a loop, which isn't fatal but
|
||||
* confusing
|
||||
ActionLink library = new ActionLink( "Select an existing image" );
|
||||
library.addActionListener( new ActionListener() {
|
||||
public void actionPerformed( ActionEvent ev ) {
|
||||
setImageComponent( ev.getPageState(), LIBRARY );
|
||||
}
|
||||
} );
|
||||
add( library, ColumnPanel.FULL_WIDTH );
|
||||
*/
|
||||
}
|
||||
|
||||
public SaveCancelSection getSaveCancelSection() {
|
||||
return m_saveCancel;
|
||||
}
|
||||
|
||||
public ReusableImageAsset getImage( FormSectionEvent event )
|
||||
throws FormProcessException
|
||||
{
|
||||
PageState ps = event.getPageState();
|
||||
|
||||
String filename = (String) m_imageFile.getFileName( event );
|
||||
File imageFile = m_imageFile.getFile( event );
|
||||
|
||||
try {
|
||||
ReusableImageAsset image = new ReusableImageAsset();
|
||||
image.loadFromFile( filename, imageFile, ImageAsset.MIME_JPEG );
|
||||
image.setDescription( ( String ) m_caption.getValue( ps ) );
|
||||
|
||||
return image;
|
||||
} catch ( IOException ex ) {
|
||||
s_log.error( "Error loading image from file", ex );
|
||||
throw new FormProcessException( ex.getMessage() );
|
||||
}
|
||||
}
|
||||
|
||||
public String getCaption( FormSectionEvent event ) {
|
||||
PageState ps = event.getPageState();
|
||||
return (String) m_caption.getValue( ps );
|
||||
}
|
||||
|
||||
public String getDescription( FormSectionEvent event ) {
|
||||
PageState ps = event.getPageState();
|
||||
return (String) m_description.getValue( ps );
|
||||
}
|
||||
|
||||
public String getTitle( FormSectionEvent event ) {
|
||||
PageState ps = event.getPageState();
|
||||
return (String) m_title.getValue( ps );
|
||||
}
|
||||
|
||||
public String getUseContext( FormSectionEvent event ) {
|
||||
PageState ps = event.getPageState();
|
||||
return (String) m_useContext.getValue( ps );
|
||||
}
|
||||
|
||||
public Form getForm() {
|
||||
return this;
|
||||
}
|
||||
}
|
||||
|
||||
private class ImageLibraryComponent extends SimpleContainer
|
||||
implements ImageComponent {
|
||||
private final ImageChooser m_chooser;
|
||||
private final ItemSelectionModel m_imageModel;
|
||||
private final BigDecimalParameter m_imageID;
|
||||
|
||||
private final Form m_form;
|
||||
private final TextField m_caption;
|
||||
private final TextField m_description;
|
||||
private final TextField m_title;
|
||||
private final TextField m_useContext;
|
||||
private final SaveCancelSection m_saveCancel;
|
||||
|
||||
public ImageLibraryComponent() {
|
||||
m_imageID = new BigDecimalParameter( "imageID" );
|
||||
m_imageModel = new ItemSelectionModel( m_imageID );
|
||||
|
||||
m_chooser = new ImageChooser( ContentItem.DRAFT );
|
||||
m_chooser.addImageActionListener( new ImageBrowser.LinkActionListener() {
|
||||
public void deleteClicked( PageState ps, BigDecimal imageID ) {
|
||||
s_log.debug( "Clicked delete" );
|
||||
|
||||
ReusableImageAsset image =
|
||||
new ReusableImageAsset( imageID );
|
||||
image.delete();
|
||||
}
|
||||
|
||||
public void linkClicked( PageState ps, BigDecimal imageID ) {
|
||||
s_log.debug( "Clicked select" );
|
||||
try {
|
||||
ReusableImageAsset image =
|
||||
new ReusableImageAsset( imageID );
|
||||
|
||||
m_imageModel.setSelectedObject( ps, image );
|
||||
} catch( DataObjectNotFoundException ex ) {
|
||||
s_log.error( "Selected non-existant image: " + imageID, ex );
|
||||
}
|
||||
}
|
||||
} );
|
||||
// Don't display the delete links
|
||||
/*
|
||||
m_chooser.getImageBrowser().getColumn(5)
|
||||
.setCellRenderer( new TableCellRenderer() {
|
||||
public Component getComponent( Table table, PageState state,
|
||||
Object value, boolean isSelected,
|
||||
Object key, int row,
|
||||
int column ) {
|
||||
return new Label( " ", false );
|
||||
}
|
||||
} );
|
||||
*/
|
||||
add( m_chooser );
|
||||
|
||||
m_form = new Form( "imageStepEditLibrary", new ColumnPanel( 2 ) );
|
||||
add( m_form );
|
||||
|
||||
m_form.add(new Label("Caption"));
|
||||
m_caption = new TextField("caption");
|
||||
m_caption.addValidationListener(new NotNullValidationListener());
|
||||
m_caption.setSize(40);
|
||||
m_form.add(m_caption);
|
||||
|
||||
m_description = new TextField("description");
|
||||
m_description.addValidationListener(new NotNullValidationListener());
|
||||
m_description.setSize(40);
|
||||
|
||||
m_title = new TextField("title");
|
||||
m_title.addValidationListener(new NotNullValidationListener());
|
||||
m_title.setSize(40);
|
||||
|
||||
// Only show the title and description fields where these have
|
||||
// been explicitly requested.
|
||||
if (ItemImageAttachment.getConfig().getIsImageStepDescriptionAndTitleShown()) {
|
||||
m_form.add(new Label("Description"));
|
||||
m_form.add(m_description);
|
||||
m_form.add(new Label("Title"));
|
||||
m_form.add(m_title);
|
||||
}
|
||||
|
||||
|
||||
m_form.add(new Label("Use Context"));
|
||||
m_useContext = new TextField("useContext");
|
||||
m_useContext.setSize(40);
|
||||
// Removed to use multiple images with fancyBox
|
||||
// m_useContext.addValidationListener( new UniqueUseContextListener() );
|
||||
m_form.add(m_useContext);
|
||||
|
||||
m_saveCancel = new SaveCancelSection();
|
||||
m_form.add(m_saveCancel);
|
||||
|
||||
ActionLink upload = new ActionLink( "Upload a new image" );
|
||||
upload.addActionListener( new ActionListener() {
|
||||
public void actionPerformed( ActionEvent ev ) {
|
||||
setImageComponent( ev.getPageState(), UPLOAD );
|
||||
}
|
||||
} );
|
||||
add( upload, ColumnPanel.FULL_WIDTH );
|
||||
}
|
||||
|
||||
public ReusableImageAsset getImage( FormSectionEvent event ) {
|
||||
PageState ps = event.getPageState();
|
||||
|
||||
return (ReusableImageAsset) m_imageModel.getSelectedItem( ps );
|
||||
}
|
||||
|
||||
@Override
|
||||
public void register( Page p ) {
|
||||
super.register( p );
|
||||
|
||||
p.addComponentStateParam( this, m_imageID );
|
||||
}
|
||||
|
||||
public String getCaption( FormSectionEvent event ) {
|
||||
PageState ps = event.getPageState();
|
||||
return (String) m_caption.getValue( ps );
|
||||
}
|
||||
|
||||
public String getDescription( FormSectionEvent event ) {
|
||||
PageState ps = event.getPageState();
|
||||
return (String) m_description.getValue( ps );
|
||||
}
|
||||
|
||||
public String getTitle( FormSectionEvent event ) {
|
||||
PageState ps = event.getPageState();
|
||||
return (String) m_title.getValue( ps );
|
||||
}
|
||||
|
||||
|
||||
public String getUseContext( FormSectionEvent event ) {
|
||||
PageState ps = event.getPageState();
|
||||
return (String) m_useContext.getValue( ps );
|
||||
}
|
||||
|
||||
public Form getForm() {
|
||||
return m_form;
|
||||
}
|
||||
|
||||
public SaveCancelSection getSaveCancelSection() {
|
||||
return m_saveCancel;
|
||||
}
|
||||
}
|
||||
// interface ImageComponent {
|
||||
// ReusableImageAsset getImage( FormSectionEvent event )
|
||||
// throws FormProcessException;
|
||||
// String getCaption( FormSectionEvent event );
|
||||
// String getDescription( FormSectionEvent event );
|
||||
// String getTitle( FormSectionEvent event );
|
||||
// String getUseContext( FormSectionEvent event );
|
||||
// SaveCancelSection getSaveCancelSection();
|
||||
// Form getForm();
|
||||
// }
|
||||
//
|
||||
// private class ImageUploadComponent extends Form
|
||||
// implements ImageComponent {
|
||||
// private final FileUploadSection m_imageFile;
|
||||
// private final TextField m_caption;
|
||||
// private final TextField m_title;
|
||||
// private final TextArea m_description;
|
||||
// private final TextField m_useContext;
|
||||
// private final SaveCancelSection m_saveCancel;
|
||||
//
|
||||
// public ImageUploadComponent() {
|
||||
// super("imageStepEditUpload", new ColumnPanel(2));
|
||||
//
|
||||
// setEncType("multipart/form-data");
|
||||
//
|
||||
// // Ignoring deprecated constructor.
|
||||
// m_imageFile = new FileUploadSection("Image Type",
|
||||
// "image", ImageAsset.MIME_JPEG);
|
||||
// m_imageFile.getFileUploadWidget()
|
||||
// .addValidationListener(new NotNullValidationListener());
|
||||
//
|
||||
// add( m_imageFile, ColumnPanel.FULL_WIDTH );
|
||||
//
|
||||
// add(new Label("Caption"));
|
||||
// m_caption = new TextField("caption");
|
||||
// m_caption.addValidationListener(new NotNullValidationListener());
|
||||
// m_caption.addValidationListener(new StringLengthValidationListener(40));
|
||||
// m_caption.setSize(40);
|
||||
// add(m_caption);
|
||||
//
|
||||
// m_title = new TextField("title");
|
||||
// m_description = new TextArea("description");
|
||||
//
|
||||
// // We only show the title and description fields in the case where
|
||||
// // getIsImageStepDescriptionAndTitleShown is false.
|
||||
// if (ItemImageAttachment.getConfig().getIsImageStepDescriptionAndTitleShown()) {
|
||||
// add(new Label("Title"));
|
||||
// m_title.addValidationListener(new NotNullValidationListener());
|
||||
// m_title.setSize(40);
|
||||
// m_title.addValidationListener(new StringLengthValidationListener(40));
|
||||
// add(m_title);
|
||||
//
|
||||
// add(new Label("Description"));
|
||||
// m_description.addValidationListener(new NotNullValidationListener());
|
||||
// m_description.addValidationListener(new StringLengthValidationListener(600));
|
||||
// m_description.setCols(30);
|
||||
// m_description.setRows(5);
|
||||
// add(m_description);
|
||||
//
|
||||
// }
|
||||
//
|
||||
// add(new Label("Use Context"));
|
||||
// m_useContext = new TextField("useContext");
|
||||
// m_useContext.setSize(40);
|
||||
//// Removed to use multiple images with fancyBox
|
||||
//// m_useContext.addValidationListener( new UniqueUseContextListener() );
|
||||
// add(m_useContext);
|
||||
//
|
||||
// m_saveCancel = new SaveCancelSection();
|
||||
// add(m_saveCancel);
|
||||
//
|
||||
// /* Removed by Quasimodo: Changed editing workflow, so that library comes first
|
||||
// * Also, library mode has now a link to upload images whixh will link to this
|
||||
// * form. Consequently, this link will create a loop, which isn't fatal but
|
||||
// * confusing
|
||||
// ActionLink library = new ActionLink( "Select an existing image" );
|
||||
// library.addActionListener( new ActionListener() {
|
||||
// public void actionPerformed( ActionEvent ev ) {
|
||||
// setImageComponent( ev.getPageState(), LIBRARY );
|
||||
// }
|
||||
// } );
|
||||
// add( library, ColumnPanel.FULL_WIDTH );
|
||||
// */
|
||||
// }
|
||||
//
|
||||
// public SaveCancelSection getSaveCancelSection() {
|
||||
// return m_saveCancel;
|
||||
// }
|
||||
//
|
||||
// public ReusableImageAsset getImage( FormSectionEvent event )
|
||||
// throws FormProcessException
|
||||
// {
|
||||
// PageState ps = event.getPageState();
|
||||
//
|
||||
// String filename = (String) m_imageFile.getFileName( event );
|
||||
// File imageFile = m_imageFile.getFile( event );
|
||||
//
|
||||
// try {
|
||||
// ReusableImageAsset image = new ReusableImageAsset();
|
||||
// image.loadFromFile( filename, imageFile, ImageAsset.MIME_JPEG );
|
||||
// image.setDescription( ( String ) m_caption.getValue( ps ) );
|
||||
//
|
||||
// return image;
|
||||
// } catch ( IOException ex ) {
|
||||
// s_log.error( "Error loading image from file", ex );
|
||||
// throw new FormProcessException( ex.getMessage() );
|
||||
// }
|
||||
// }
|
||||
//
|
||||
// public String getCaption( FormSectionEvent event ) {
|
||||
// PageState ps = event.getPageState();
|
||||
// return (String) m_caption.getValue( ps );
|
||||
// }
|
||||
//
|
||||
// public String getDescription( FormSectionEvent event ) {
|
||||
// PageState ps = event.getPageState();
|
||||
// return (String) m_description.getValue( ps );
|
||||
// }
|
||||
//
|
||||
// public String getTitle( FormSectionEvent event ) {
|
||||
// PageState ps = event.getPageState();
|
||||
// return (String) m_title.getValue( ps );
|
||||
// }
|
||||
//
|
||||
// public String getUseContext( FormSectionEvent event ) {
|
||||
// PageState ps = event.getPageState();
|
||||
// return (String) m_useContext.getValue( ps );
|
||||
// }
|
||||
//
|
||||
// public Form getForm() {
|
||||
// return this;
|
||||
// }
|
||||
// }
|
||||
//
|
||||
// private class ImageLibraryComponent extends SimpleContainer
|
||||
// implements ImageComponent {
|
||||
// private final ImageChooser m_chooser;
|
||||
// private final ItemSelectionModel m_imageModel;
|
||||
// private final BigDecimalParameter m_imageID;
|
||||
//
|
||||
// private final Form m_form;
|
||||
// private final TextField m_caption;
|
||||
// private final TextField m_description;
|
||||
// private final TextField m_title;
|
||||
// private final TextField m_useContext;
|
||||
// private final SaveCancelSection m_saveCancel;
|
||||
//
|
||||
// public ImageLibraryComponent() {
|
||||
// m_imageID = new BigDecimalParameter( "imageID" );
|
||||
// m_imageModel = new ItemSelectionModel( m_imageID );
|
||||
//
|
||||
// m_chooser = new ImageChooser( ContentItem.DRAFT, ImageBrowser.SELECT_IMAGE );
|
||||
// m_chooser.addImageActionListener( new ImageBrowser.LinkActionListener() {
|
||||
// public void deleteClicked( PageState ps, BigDecimal imageID ) {
|
||||
// s_log.debug( "Clicked delete" );
|
||||
//
|
||||
// ReusableImageAsset image =
|
||||
// new ReusableImageAsset( imageID );
|
||||
// image.delete();
|
||||
// }
|
||||
//
|
||||
// public void linkClicked( PageState ps, BigDecimal imageID ) {
|
||||
// s_log.debug( "Clicked select" );
|
||||
// try {
|
||||
// ReusableImageAsset image =
|
||||
// new ReusableImageAsset( imageID );
|
||||
//
|
||||
// m_imageModel.setSelectedObject( ps, image );
|
||||
// } catch( DataObjectNotFoundException ex ) {
|
||||
// s_log.error( "Selected non-existant image: " + imageID, ex );
|
||||
// }
|
||||
// }
|
||||
// } );
|
||||
// // Don't display the delete links
|
||||
// /*
|
||||
// m_chooser.getImageBrowser().getColumn(5)
|
||||
// .setCellRenderer( new TableCellRenderer() {
|
||||
// public Component getComponent( Table table, PageState state,
|
||||
// Object value, boolean isSelected,
|
||||
// Object key, int row,
|
||||
// int column ) {
|
||||
// return new Label( " ", false );
|
||||
// }
|
||||
// } );
|
||||
// */
|
||||
// add( m_chooser );
|
||||
//
|
||||
// m_form = new Form( "imageStepEditLibrary", new ColumnPanel( 2 ) );
|
||||
// add( m_form );
|
||||
//
|
||||
// m_form.add(new Label("Caption"));
|
||||
// m_caption = new TextField("caption");
|
||||
// m_caption.addValidationListener(new NotNullValidationListener());
|
||||
// m_caption.setSize(40);
|
||||
// m_form.add(m_caption);
|
||||
//
|
||||
// m_description = new TextField("description");
|
||||
// m_description.addValidationListener(new NotNullValidationListener());
|
||||
// m_description.setSize(40);
|
||||
//
|
||||
// m_title = new TextField("title");
|
||||
// m_title.addValidationListener(new NotNullValidationListener());
|
||||
// m_title.setSize(40);
|
||||
//
|
||||
// // Only show the title and description fields where these have
|
||||
// // been explicitly requested.
|
||||
// if (ItemImageAttachment.getConfig().getIsImageStepDescriptionAndTitleShown()) {
|
||||
// m_form.add(new Label("Description"));
|
||||
// m_form.add(m_description);
|
||||
// m_form.add(new Label("Title"));
|
||||
// m_form.add(m_title);
|
||||
// }
|
||||
//
|
||||
//
|
||||
// m_form.add(new Label("Use Context"));
|
||||
// m_useContext = new TextField("useContext");
|
||||
// m_useContext.setSize(40);
|
||||
//// Removed to use multiple images with fancyBox
|
||||
//// m_useContext.addValidationListener( new UniqueUseContextListener() );
|
||||
// m_form.add(m_useContext);
|
||||
//
|
||||
// m_saveCancel = new SaveCancelSection();
|
||||
// m_form.add(m_saveCancel);
|
||||
//
|
||||
// ActionLink upload = new ActionLink( "Upload a new image" );
|
||||
// upload.addActionListener( new ActionListener() {
|
||||
// public void actionPerformed( ActionEvent ev ) {
|
||||
// setImageComponent( ev.getPageState(), UPLOAD );
|
||||
// }
|
||||
// } );
|
||||
// add( upload, ColumnPanel.FULL_WIDTH );
|
||||
// }
|
||||
//
|
||||
// public ReusableImageAsset getImage( FormSectionEvent event ) {
|
||||
// PageState ps = event.getPageState();
|
||||
//
|
||||
// return (ReusableImageAsset) m_imageModel.getSelectedItem( ps );
|
||||
// }
|
||||
//
|
||||
// @Override
|
||||
// public void register( Page p ) {
|
||||
// super.register( p );
|
||||
//
|
||||
// p.addComponentStateParam( this, m_imageID );
|
||||
// }
|
||||
//
|
||||
// public String getCaption( FormSectionEvent event ) {
|
||||
// PageState ps = event.getPageState();
|
||||
// return (String) m_caption.getValue( ps );
|
||||
// }
|
||||
//
|
||||
// public String getDescription( FormSectionEvent event ) {
|
||||
// PageState ps = event.getPageState();
|
||||
// return (String) m_description.getValue( ps );
|
||||
// }
|
||||
//
|
||||
// public String getTitle( FormSectionEvent event ) {
|
||||
// PageState ps = event.getPageState();
|
||||
// return (String) m_title.getValue( ps );
|
||||
// }
|
||||
//
|
||||
//
|
||||
// public String getUseContext( FormSectionEvent event ) {
|
||||
// PageState ps = event.getPageState();
|
||||
// return (String) m_useContext.getValue( ps );
|
||||
// }
|
||||
//
|
||||
// public Form getForm() {
|
||||
// return m_form;
|
||||
// }
|
||||
//
|
||||
// public SaveCancelSection getSaveCancelSection() {
|
||||
// return m_saveCancel;
|
||||
// }
|
||||
// }
|
||||
|
||||
private class UniqueUseContextListener implements ParameterListener {
|
||||
public void validate( ParameterEvent ev )
|
||||
|
|
|
|||
Loading…
Reference in New Issue