@Templated public class FileUploadPopupView extends AbstractScenarioPopupView implements FileUploadPopup
FileUploadPopup.Presenter
Modifier and Type | Field and Description |
---|---|
protected List<String> |
acceptedExtension |
protected com.google.gwt.dom.client.SpanElement |
chooseButton |
protected com.google.gwt.dom.client.InputElement |
file |
protected static String |
fileContents |
protected static String |
fileName |
protected com.google.gwt.dom.client.InputElement |
fileText |
protected com.google.gwt.dom.client.ParagraphElement |
uploadWarning |
cancelButton, mainTitle, modal, okButton, okCommand, translationService
Constructor and Description |
---|
FileUploadPopupView() |
Modifier and Type | Method and Description |
---|---|
static void |
fileLoaded(String fileContents) |
String |
getFileContents() |
String |
getFileName() |
void |
init() |
void |
onChooseButtonClickEvent(com.google.gwt.event.dom.client.ClickEvent clickEvent) |
void |
onFileChangeEvent(com.google.gwt.event.dom.client.ChangeEvent event) |
static void |
readTextFile(com.google.gwt.core.client.JavaScriptObject files) |
void |
setAcceptedExtension(List<String> acceptedExtension) |
void |
show(String mainTitleText,
String okButtonText,
org.uberfire.mvp.Command okCommand)
Makes the
ScenarioPopup visible with OK/Cancel buttons. |
void |
show(String mainTitleText,
String uploadWarningText,
String okButtonText,
org.uberfire.mvp.Command okCommand) |
conditionalShow, conditionalShow, getElement, hide, onCancelClick, onOkClick
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
getElement, hide
@DataField(value="file") protected com.google.gwt.dom.client.InputElement file
@DataField(value="fileText") protected com.google.gwt.dom.client.InputElement fileText
@DataField(value="chooseButton") protected com.google.gwt.dom.client.SpanElement chooseButton
@DataField(value="upload-warning") protected com.google.gwt.dom.client.ParagraphElement uploadWarning
protected static String fileContents
protected static String fileName
public static void fileLoaded(String fileContents)
public void init()
init
in class AbstractScenarioPopupView
public void show(String mainTitleText, String okButtonText, org.uberfire.mvp.Command okCommand)
AbstractScenarioPopup
ScenarioPopup
visible with OK/Cancel buttons.show
in interface AbstractScenarioPopup
show
in class AbstractScenarioPopupView
public void show(String mainTitleText, String uploadWarningText, String okButtonText, org.uberfire.mvp.Command okCommand)
show
in interface FileUploadPopup
public String getFileContents()
getFileContents
in interface FileUploadPopup
public String getFileName()
getFileName
in interface FileUploadPopup
public void setAcceptedExtension(List<String> acceptedExtension)
setAcceptedExtension
in interface FileUploadPopup
@EventHandler(value="chooseButton") public void onChooseButtonClickEvent(com.google.gwt.event.dom.client.ClickEvent clickEvent)
@EventHandler(value="file") public void onFileChangeEvent(com.google.gwt.event.dom.client.ChangeEvent event)
public static void readTextFile(com.google.gwt.core.client.JavaScriptObject files)
Copyright © 2001–2020 JBoss by Red Hat. All rights reserved.