Skip to content

Commit

Permalink
Fix Issues
Browse files Browse the repository at this point in the history
  • Loading branch information
AlexVelezLl committed May 12, 2020
1 parent 7810f59 commit ffa0af1
Show file tree
Hide file tree
Showing 5 changed files with 644 additions and 666 deletions.
12 changes: 6 additions & 6 deletions src/Interfaz/Index.java
Original file line number Diff line number Diff line change
Expand Up @@ -3,29 +3,29 @@
* To change this template file, choose Tools | Templates
* and open the template in the editor.
*/
package Interfaz;
package interfaz;

import javafx.application.Application;
import javafx.scene.Scene;
import javafx.stage.Stage;

/**
*
* @author CORE i7 ULTIMATE
* @author AlexVelezLl
*/
public class Index extends Application{
public static void main(String [] args){
public class Index extends Application {
public static void main(String[] args) {
launch(args);
}

@Override
public void start(Stage primaryStage) throws Exception {
InterfazArbol ia = new InterfazArbol();
Scene sc = new Scene(ia.getRoot(),1366,768);
Scene sc = new Scene(ia.getRoot(), 1366, 768);
primaryStage.setScene(sc);
primaryStage.setFullScreen(true);
primaryStage.setResizable(false);
primaryStage.show();

}
}
6 changes: 3 additions & 3 deletions src/Interfaz/InterfazArbol.java
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
* To change this template file, choose Tools | Templates
* and open the template in the editor.
*/
package Interfaz;
package interfaz;

import javafx.application.Platform;
import javafx.geometry.Pos;
Expand Down Expand Up @@ -34,7 +34,6 @@ public InterfazArbol() {
root = new VBox();
avlTree = new AVL<>(Integer::compareTo);
sp = new ScrollPane();

createRoot();
}

Expand Down Expand Up @@ -74,6 +73,7 @@ private void createRoot() {
StackPane arbol = new StackPane();
arbol.setMinHeight(200);
arbol.setMinWidth(1366);
arbol.setMinWidth(avlTree.height() * 100);
btnClear.setOnMouseClicked(e -> {
avlTree = new AVL<>(Integer::compareTo);
arbol.getChildren().clear();
Expand All @@ -90,7 +90,7 @@ private void createRoot() {
num = Integer.parseInt(txtInsertar.getText());
txtInsertar.setText("");
txtInsertar.requestFocus();
avlTree.Insert(num);
avlTree.insert(num);

arbol.getChildren().clear();
Pane avlPane = avlTree.mostrarArbol();
Expand Down
Loading

0 comments on commit ffa0af1

Please sign in to comment.