ToolbarWindow
An extended window that allows you to add any components to the window header. Most suitable for adding minimize/maximize buttons.
Ever wanted to place extra buttons in the window header, such as a simple minimize or maximize button? Now you can!
The toolbar area accepts any Vaadin component, so you could even place a Table there, but that's not really what this component was designer for ;)
The demo application contains an example implementation for the maximize and minimize functions, with an additional custom button in the toolbar. The Animator add-on is also used to provide the smooth minimize animation.
DEPENDENCIES -CSSInject 0.11 is required - http://vaadin.com/addon/cssinject
Sample code
final ToolbarWindow w = new ToolbarWindow("Window w/ Tools"); w.center(); w.setWidth("400px"); w.setHeight("300px"); Button b = new Button(null, new Button.ClickListener() { public void buttonClick(ClickEvent event) { w.setHeight("0px"); } }); b.setDescription("Minimize"); b.setIcon(new ClassResource("minimize.png", this)); b.addStyleName(Reindeer.BUTTON_LINK); tools.addComponent(b); b = new Button(null, new Button.ClickListener() { public void buttonClick(ClickEvent event) { if (w.getWidth() != 100) { w.setSizeFull(); } else { w.setWidth("400px"); w.setHeight("300px"); } w.center(); event.getButton().focus(); } }); b.setDescription("Maximize"); b.setIcon(new ClassResource("maximize.png", this)); b.addStyleName(Reindeer.BUTTON_LINK); tools.addComponent(b); w.setToolbar(tools); getMainWindow().addWindow(w);
Links
Compatibility
Was this helpful? Need more help?
Leave a comment or a question below. You can also join
the chat on Discord or
ask questions on StackOverflow.
Version
Initial release.
Internet Explorer 6 is not supported, and most likely never will be. The reason is that the CSS used to position the toolbar above the window header doesn't work in IE6.
- Released
- 2011-08-19
- Maturity
- BETA
- License
- Apache License 2.0
Compatibility
- Framework
- Vaadin 6.3+
- Browser
- Firefox
- Opera
- Safari
- Google Chrome
- Internet Explorer
Flow Viritin - Vaadin Add-on Directory
The commons library for Vaadin 10+. Uploads, downloads, Geolocation, forms, fieds, fluent API...GitHub
Online Demo
Flow Viritin version 0.1.6
ByteArrayUploadField, UploadFileHandler, DynamicFileDownloader
Flow Viritin version 0.1.7
Introduced BorderLayout
Flow Viritin version 0.2.3
NewFeaturesAndBugFixes
Flow Viritin version 0.2.4
NewFeaturesAndBugFixes
Flow Viritin version 0.2.8
See github timeline for changes
Flow Viritin version 0.2.10
Fixed several issues that were broken with V14. Updated dependencies.
Flow Viritin version 0.2.9
Added DisclosurePanel that was forgotten to commit to last release.
Flow Viritin version 0.3.0
Tree component added
Flow Viritin version 0.3.1
Updates to the Tree component
Flow Viritin version 0.5.0
Version for non-LTS branch, mainly V19+
Flow Viritin version 0.5.1
Added simple "application framework" bulk UIs.
Flow Viritin version 0.5.2
Added missing css file for app framework
Flow Viritin version 0.7.0
Lot of enhancements and new features
* first draft of ElementCollecitonField (for Flow). Consider this still WIP
* Greatly improved ByteArrayUploadField
* Ton of other small improvements
Flow Viritin version 0.9.0
Some bugfixes and release via Maven Central
New Maven coordinates!!
in.virit:viritin:0.9.0
Flow Viritin version 1.2.0
Added WebStorage helper for localStorage/sessionStorage handling.
Flow Viritin version 1.3.0
Sane defaults for date pickers via locale
Flow Viritin version 1.5.0
Added Geolocation API support
Flow Viritin version 1.6.0
Added CustomLayout component
Flow Viritin version 1.6.1
bugix in dynamicfiledownload
Flow Viritin version 2.1.0
Improvements to work better with the "dev-bundle" in Vaadin 24+. Technically so that custom bundle is no more needed when using Viritin -> front-end build don't become any slower when dropping in this add-on.
Flow Viritin version 2.5.0
Completely renewed UploadFileHandler component
* No extra thread created for each upload. For apps having a lot of large uploads concurrently, this might save some resources.
* Streaming now properly works in Spring Boot apps as well (doesn't use multipart request at all)
* Not extending from com.vaadin.flow.component.upload.Upload anymore, some API might be missing, please file issus for things you are missing
Flow Viritin version 2.5.1
Completely renewed UploadFileHandler component in 2.5.x series:
* The good old API that passes the [input stream for you to handle](https://vaadin.com/blog/uploads-and-downloads-inputs-and-outputs).
* No extra thread created for each upload. For apps having a lot of large uploads concurrently, this might save some resources.
* Streaming now properly works in Spring Boot apps as well (doesn't use multipart request at all). With previous version and with plain Upload you only get to access the stream once it is uploaded completely.
* The clients side opens maximum 1 server connection by default when allowing multiple files to be uploaded. This way the network/server/http2 connection don't get choked if uploading a large number of files at once.
* Not extending from com.vaadin.flow.component.upload.Upload anymore, some API might be missing, please file issus for things you are missing
Flow Viritin version 2.13.0
Uses markdown-it on the browser to render markdown content by default. The main motivation was to reduce transitive dependencies on the Java side. Most users should not see a difference, but if you manually add `com.vladsch.flexmark:flexmark` dependency to your project, the "old behaviour" is back. RichText and MarkdownMessage contain hooks to customize the behaviour if needed.
Pros/cons:
* Less JVM dependencies
* Less JVM resources consumed
* More JS "dependencies"
* More browser resources consumed
* JS is loaded dynamically (to avoid requirement for custom front-end bundle) -> might cause a tiny delay for the first markdown to appear
* Tables ("non-standard markdown") supported out of the box
* Inline html not supported out of the box (default in markdown-it, doesn't sanitize the content)