Click here to Skip to main content
15,885,141 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
I have a reproducible problem with the Mint Cinnamon desktop locking up when hitting a breakpoint debugging with Eclipse. When I say it's locking up, I mean mouse clicks are completely inoperable (even on the Mint panel). Alt-Tab looks like it's working, but selecting another window doesn't focus or activate the window (only the Alt-Tab selector works).

Debugging and breakpoints work fine everywhere as far as I can tell except when the breakpoint is inside an anon inner class or lambda.

Public git repo with a fairly simple example project causing this:
Bitbucket

Linux Mint 17.3
Eclipse Neon 4.6.0
Java 8 (1.8.0_92) (Using JavaFX)

Code below (you'll have to grab the project files to run it though):
Java
package application;
	
import javafx.application.Application;
import javafx.fxml.FXMLLoader;
import javafx.scene.Scene;
import javafx.scene.layout.BorderPane;
import javafx.stage.Stage;

public class Main extends Application {
	@Override
	public void start(Stage primaryStage) {
		try {
			BorderPane root = (BorderPane)FXMLLoader.load(getClass().getResource("Sample.fxml"));
			Scene scene = new Scene(root,400,400);
			scene.getStylesheets().add(getClass().getResource("application.css").toExternalForm());
			primaryStage.setScene(scene);
			primaryStage.show();
		} catch(Exception e) {
			e.printStackTrace();
		}
	}
	
	public static void main(String[] args) {
		launch(args);
	}
}

package application;

import javafx.event.Event;
import javafx.event.EventHandler;
import javafx.fxml.FXML;
import javafx.scene.control.Tab;
import javafx.scene.control.TabPane;

public class SampleController {
	
	@FXML
	private TabPane tabPane;
	
	public void createTab() {
		
		Tab tab = new Tab("New tab");//Breakpoint here does NOT freeze desktop
		
//		tab.setOnCloseRequest(e -> {
//			System.out.println("bleh");//Breakpoint here, freezes desktop
//		});
		tab.setOnCloseRequest(new EventHandler<Event>(){
		    @Override public void handle(Event e){
		    	System.out.println("bleh");//Breakpoint here, also freezes desktop
		    }
		});
		
		tabPane.getTabs().add(tab);//Breakpoint here does NOT freeze desktop
		int index = tabPane.getTabs().size() - 1;
		tabPane.getSelectionModel().select(index);
	}
}


What I have tried:

Ctrl-Alt-ESC restarts Cinnamon and everything proceeds fine after that. I've tried using Lambdas and using an anon inner class, both cause this issue for me.
Posted

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900