Example usage for javafx.scene.control TextField paste

List of usage examples for javafx.scene.control TextField paste

Introduction

In this page you can find the example usage for javafx.scene.control TextField paste.

Prototype

public void paste() 

Source Link

Document

Transfers the contents in the clipboard into this text, replacing the current selection.

Usage

From source file:com.bekwam.mavenpomupdater.MenuBarDelegate.java

public void copy() {
    if (log.isDebugEnabled()) {
        log.debug("[COPY]");
    }//from  ww  w  .  j a  v a 2s.  c o  m

    TextField focusedTF = getFocusedTextField();
    focusedTF.paste();
}

From source file:com.bekwam.mavenpomupdater.MenuBarDelegate.java

public void paste() {
    if (log.isDebugEnabled()) {
        log.debug("[PASTE]");
    }/* ww w  .  ja v  a 2s  .  c  o  m*/

    if (!systemClipboard.hasContent(DataFormat.PLAIN_TEXT)) {
        adjustForEmptyClipboard();
        return;
    }

    TextField focusedTF = getFocusedTextField();

    focusedTF.paste();
}