Package javafx.embed.swing

Examples of javafx.embed.swing.JFXPanel


    // this.setDefaultCloseOperation(JDialog.DISPOSE_ON_CLOSE);
    this.setModal(true);

    final ClassLoader classLoader = getClass().getClassLoader();
    // JavaFXのコンポーネントを貼り付けるPanel
    final JFXPanel fxPanel = new JFXPanel();
    this.add(fxPanel);
    this.init = true;
    // JavaFXのThreadを使用すること
    FutureTask<Void> futureTask = new FutureTask<Void>(new Callable<Void>() {
      @Override
      public Void call() throws Exception {
        SelectPackagesApplication app = new SelectPackagesApplication();
        app.setClassLoader(classLoader);
        fxPanel.setScene(app.createScene());
        controller = app.getController();
        controller.setCloseDialog(new CloseDialog() {
          @Override
          public void closeByOk() {
            chooseState = ChooseState.OK;
View Full Code Here


        if (addNavigationBar) {
            navigationBar = new WebViewNavigationBar();
            panel.add(navigationBar.getComponent(), BorderLayout.NORTH);
        }

        final JFXPanel browserPanel = new JFXPanel();
        panel.add(browserPanel, BorderLayout.CENTER);

        WebViewInitialization webViewInitialization = new WebViewInitialization(browserPanel);
        if (Platform.isFxApplicationThread()) {
            webViewInitialization.run();
View Full Code Here

        xmppSession.addPresenceListener(presenceListener);

        SwingUtilities.invokeLater(new Runnable() {
            @Override
            public void run() {
                new JFXPanel(); // this will prepare JavaFX toolkit and environment
                Platform.runLater(new Runnable() {
                    @Override
                    public void run() {
                        try {
                            Font.loadFont(getClass().getResource("Inconsolata.ttf").toExternalForm(), 12);
View Full Code Here

    private WebView webView;

    private String currentContent = "";

    public FXHtmlView() {
        fxPanel = new JFXPanel();
        Platform.setImplicitExit(false);
        Platform.runLater(new Runnable() {
            @Override
            public void run() {
                createScene();
View Full Code Here

                Rectangle sceneBounds = getSceneBounds(env, scene);
                Point stageCoordinates = null;
                // TODO: stub
                String prop = System.getProperty("javafx.swinginteroperability");
                if (prop != null && prop.compareToIgnoreCase("true") == 0) {
                    JFXPanel panel = AWT.getAWT().lookup(JFXPanel.class, new Showing<JFXPanel>() {

                        @Override
                        public boolean check(JFXPanel control) {
                            return super.check(control) && (control.getScene() == scene);
                        }
                    }).wrap().getControl();
                    sceneBounds.translate((int) panel.getLocationOnScreen().getX(), (int) panel.getLocationOnScreen().getY());
                } else {
                    Window window = scene.getWindow();
                    /*
                     * Field host_field =
                     * window.getClass().getDeclaredField("host");
 
View Full Code Here

        } catch (MalformedURLException e) {
            e.printStackTrace();
        } catch (IOException e) {
            e.printStackTrace();
        }
        JFXPanel fxPanel = new JFXPanel();
        Media media=new Media(mp3.toURI().toString());
        MediaPlayer mediaPlayer=new MediaPlayer(media);
        mediaPlayer.play();
        if(mp3.exists()){
            mp3.setWritable(true);
View Full Code Here

     */
    public static void main(String[] args) {
        Dimension screenSize = Toolkit.getDefaultToolkit().getScreenSize();
        final JFrame f = new JFrame();
        f.setExtendedState(JFrame.MAXIMIZED_BOTH);
        final JFXPanel panel = new JFXPanel();
        f.add(panel);
        f.pack();
        f.setVisible(true);

        JavaFxOAuthFlow oauthflow = new JavaFxOAuthFlow(screenSize.width, screenSize.height, screenSize.width,
View Full Code Here

        }
        return true;
    }

    protected void initializeBrowser() {
        panel = new JFXPanel();

        runLater(new Runnable() {
            public void run() {
                webView = createWebView();
                if (webView == null)
View Full Code Here

  private static final void initializeIfRequired() {
    if (!initialized) {
      synchronized (TTSUtils.class) {
        if (!initialized) {
          new JFXPanel();
          initialized = true;
        }
      }
    }
  }
View Full Code Here

     * regenerated by the Form Editor.
     */
    // <editor-fold defaultstate="collapsed" desc="Generated Code">//GEN-BEGIN:initComponents
    private void initComponents() {

        jfxPanel = new JFXPanel();

        javax.swing.GroupLayout layout = new javax.swing.GroupLayout(this);
        this.setLayout(layout);
        layout.setHorizontalGroup(
            layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
View Full Code Here

TOP

Related Classes of javafx.embed.swing.JFXPanel

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.