List of usage examples for com.vaadin.server FontAwesome CAMERA_RETRO
FontAwesome CAMERA_RETRO
To view the source code for com.vaadin.server FontAwesome CAMERA_RETRO.
Click Source Link
From source file:ui.button.AddPhotoButton.java
License:Apache License
public AddPhotoButton(final Integer userId, final String language) { super(Translator.getTranslation("Add professional photo", language), FontAwesome.CAMERA_RETRO); setDescription(Translator.getTranslation("Add professional photo", language)); addClickListener(new Button.ClickListener() { @Override/*from w ww. j a va2s . c o m*/ public void buttonClick(Button.ClickEvent event) { UploadReceiver receiver = new PhotoUploadReceiver(userId, language); Upload upload = new Upload(Translator.getTranslation("Choose your best photo", language), receiver); upload.addSucceededListener((Upload.SucceededListener) receiver); String wcaption = Translator.getTranslation("Upload a photo", language); final Window window = new Window(wcaption, upload); window.center(); //window.setModal(true); window.setStyleName("window"); receiver.setWindow(window); window.addCloseListener(new Window.CloseListener() { @Override public void windowClose(Window.CloseEvent e) { window.close(); } }); getUI().addWindow(window); } }); }