List of usage examples for com.vaadin.ui Embedded Embedded
public Embedded()
From source file:edu.nps.moves.mmowgli.components.Header.java
License:Open Source License
@HibernateSessionThreadLocalConstructor public Header() { Game game = Game.getTL();/* www. j a v a 2s .co m*/ GameLinks gl = GameLinks.getTL(); mediaLoc = Mmowgli2UI.getGlobals().getMediaLocator(); leaderBoardButt = makeSmallButt("Leaderboard", LEADERBOARDCLICK, leaderboard_tt); mapButt = makeSmallButt("Map", MAPCLICK, "View " + game.getMapTitle()); liveBlogButt = makeSmallLink("Game Blog", liveblog_tt, gl.getBlogLink()); learnMoreButt = makeSmallLink("Learn More", learnmore_tt, gl.getLearnMoreLink()); buttonChars = 11 + 3 + 9 + 10; // num chars of above signOutButt = makeSmallButt("Sign Out", SIGNOUTCLICK, signout_tt); signOutButt.setId(SIGNOUT_BUTTON); if (game.isActionPlansEnabled()) takeActionButt = makeTakeActionButt(); playIdeaButt = makePlayIdeaButt(game); userNameButt = makeUserNameButt("usernamehere", SHOWUSERPROFILECLICK); searchButt = makeSearchButt("", SEARCHCLICK, search_tt); callToActionButt = makeCallToActionButton(); avatar = new Embedded(); searchField = new TextField(); searchField.setDescription(search_tt); implPtsLab = makeImplementationPtsLabel(w_implPoints, h_implPoints); explorPtsLab = makeExplorationPtsLabel(w_explPoints, h_explPoints); blogHeadlinesLink = makeBlogHeadlineLink(); moveNumLab = new HtmlLabel(); moveNumLab.setWidth(w_movenum); moveNumLab.setHeight(h_movenum); moveNumLab.addStyleName("m-header-movenum-text"); brandingLab = new HtmlLabel(); brandingLab.setWidth(w_movetitle); brandingLab.setHeight(h_movetitle); brandingLab.addStyleName("m-header-branding-text"); //m-header-movetitle-text"); }
From source file:edu.nps.moves.mmowgli.utility.Res.java
License:Open Source License
public Embedded getClasspathImage(String filename) { ClassResource clR = getClasspathImageResource(filename); Embedded emb = new Embedded(); emb.setSource(clR);//from w w w . ja v a 2 s .c om return emb; }
From source file:edu.nps.moves.mmowgli.utility.Res.java
License:Open Source License
public Embedded getExternalImage(String url) { ExternalResource exR = new ExternalResource(url); Embedded emb = new Embedded(); emb.setSource(exR);// w w w .j a v a 2 s .c o m return emb; }
From source file:eu.lod2.CKAN.java
License:Apache License
public CKAN(LOD2DemoState st) { // The internal state state = st;/* w ww . java2s . co m*/ Embedded browser = new Embedded(); try { URL url = new URL("http://ckan.net"); browser = new Embedded("", new ExternalResource(url)); browser.setType(Embedded.TYPE_BROWSER); browser.setSizeFull(); //panel.addComponent(browser); } catch (MalformedURLException e) { e.printStackTrace(); } ; // The composition root MUST be set setCompositionRoot(browser); }
From source file:eu.lod2.D2RCordis.java
License:Apache License
public D2RCordis(LOD2DemoState st) { // The internal state state = st;//from w w w . j a v a2 s .c om Embedded browser = new Embedded(); try { LOD2DemoInitApp urlD2r = new LOD2DemoInitApp(st, "http://localhost/d2r-cordis"); System.err.println(urlD2r.service); URL url = new URL(urlD2r.service); browser = new Embedded("", new ExternalResource(url)); browser.setType(Embedded.TYPE_BROWSER); browser.setSizeFull(); //panel.addComponent(browser); } catch (MalformedURLException e) { e.printStackTrace(); } ; // The composition root MUST be set setCompositionRoot(browser); }
From source file:eu.lod2.DBpedia.java
License:Apache License
public DBpedia(LOD2DemoState st) { // The internal state state = st;//w w w. j a va2s.co m Embedded browser = new Embedded(); try { URL url = new URL("http://live.dbpedia.org"); browser = new Embedded("", new ExternalResource(url)); browser.setType(Embedded.TYPE_BROWSER); browser.setSizeFull(); //panel.addComponent(browser); } catch (MalformedURLException e) { e.printStackTrace(); } ; // The composition root MUST be set setCompositionRoot(browser); }
From source file:eu.lod2.ELoadRDFFile.java
License:Apache License
public ELoadRDFFile(LOD2DemoState st) { // The internal state and state = st;/*from w w w. ja va2 s.c om*/ initVirtuoso(); Embedded browser = new Embedded(); try { URL url; if (virtuoso_username.equals("") || virtuoso_password.equals("")) { url = new URL( "http://localhost:8890/conductor/rdf_import.vspx?username=dba&t_login_pwd=dba&password=dba"); } else if (virtuoso_service.equals("")) { url = new URL(state.getHostName() + "/conductor/rdf_import.vspx?username=" + virtuoso_username + "&t_login_pwd=" + virtuoso_password + "&password=" + virtuoso_password); } else { url = new URL(virtuoso_service + "/rdf_import.vspx?username=" + virtuoso_username + "&t_login_pwd=" + virtuoso_password + "&password=" + virtuoso_password); } ; browser = new Embedded("", new ExternalResource(url)); browser.setType(Embedded.TYPE_BROWSER); browser.setSizeFull(); //panel.addComponent(browser); } catch (MalformedURLException e) { e.printStackTrace(); } ; browser.setSizeUndefined(); setSizeUndefined(); // The composition root MUST be set setCompositionRoot(browser); }
From source file:eu.lod2.GeoSpatial.java
License:Apache License
public GeoSpatial(LOD2DemoState st) { // The internal state and state = st;//from w ww . j a v a2 s .com initLogin(); HorizontalLayout geospatiallayout = new HorizontalLayout(); // Configuration form start // Set all properties at once for the moment. Form t2f = new Form(); t2f.setDebugId(this.getClass().getSimpleName() + "_t2f"); t2f.setCaption("Configuration"); exportGraph = new ExportSelector3(state, true, "Select graph with geo data:"); exportGraph.setDebugId(this.getClass().getSimpleName() + "_exportGraph"); t2f.getLayout().addComponent(exportGraph); // initialize the footer area of the form HorizontalLayout t2ffooterlayout = new HorizontalLayout(); t2f.setFooter(t2ffooterlayout); Button commitButton = new Button("Set configuration", new ClickListener() { public void buttonClick(ClickEvent event) { storeConfiguration(event); } }); commitButton.setDebugId(this.getClass().getSimpleName() + "_commitButton"); commitButton.setDescription("Commit the new configuration settings."); t2f.getFooter().addComponent(commitButton); geospatiallayout.addComponent(t2f); // Configuration form end geobrowser = new Embedded(); try { URL url = new URL(service); geobrowser = new Embedded("", new ExternalResource(url)); geobrowser.setType(Embedded.TYPE_BROWSER); geospatiallayout.addComponent(geobrowser); //geobrowser.setHeight(-1, Sizeable.UNITS_PERCENTAGE); geobrowser.setSizeFull(); } catch (MalformedURLException e) { e.printStackTrace(); } ; // The composition root MUST be set setCompositionRoot(geospatiallayout); geospatiallayout.setSizeFull(); }
From source file:eu.lod2.IframedUrl.java
License:Apache License
public IframedUrl(LOD2DemoState st, String urlref) { // The internal state state = st;//from w w w .j av a 2s . c o m Embedded browser = new Embedded(); try { URL url = new URL(urlref); browser = new Embedded("", new ExternalResource(url)); browser.setType(Embedded.TYPE_BROWSER); browser.setSizeFull(); //panel.addComponent(browser); } catch (MalformedURLException e) { e.printStackTrace(); } ; // The composition root MUST be set setCompositionRoot(browser); }
From source file:eu.lod2.LinkingTab.java
License:Apache License
public LinkingTab(LOD2DemoState st) { // The internal state and state = st;//from w ww . j a v a2 s .co m Embedded browser = new Embedded(); try { URL url = new URL(state.getHostName() + "/silk"); browser = new Embedded("", new ExternalResource(url)); browser.setType(Embedded.TYPE_BROWSER); browser.setSizeFull(); } catch (MalformedURLException e) { e.printStackTrace(); } ; // The composition root MUST be set setCompositionRoot(browser); }