Skip to content
Snippets Groups Projects
Commit 4ace5fcd authored by Robert Goldmann's avatar Robert Goldmann
Browse files

Fixed #97 - don't select chart categories on refresh every time

parent 4ddfb1e6
Branches
Tags
2 merge requests!104merge v_1_2_0 into master,!100merge charts into v_1_2_0
...@@ -45,9 +45,7 @@ public class CategoriesChartGenerator ...@@ -45,9 +45,7 @@ public class CategoriesChartGenerator
for(CategoryInOutSum currentItem : categoryInOutSums) for(CategoryInOutSum currentItem : categoryInOutSums)
{ {
Label currentPart = new Label(); Label currentPart = new Label();
//TODO maybe use gradient
currentPart.setStyle("-fx-background-color: " + ConvertTo.toRGBHexWithoutOpacity(currentItem.getColor())); currentPart.setStyle("-fx-background-color: " + ConvertTo.toRGBHexWithoutOpacity(currentItem.getColor()));
// currentPart.setStyle("-fx-background-color: linear-gradient(to bottom right, " + ConvertTo.toRGBHexWithoutOpacity(currentItem.getColor()) + ", " + ConvertTo.toRGBHexWithoutOpacity(currentItem.getColor().darker()) + ")");
currentPart.prefHeightProperty().bind(chart.heightProperty()); currentPart.prefHeightProperty().bind(chart.heightProperty());
chart.getChildren().add(currentPart); chart.getChildren().add(currentPart);
......
...@@ -112,6 +112,8 @@ public class ChartController implements Refreshable ...@@ -112,6 +112,8 @@ public class ChartController implements Refreshable
radioButtonBars.setToggleGroup(toggleGroup); radioButtonBars.setToggleGroup(toggleGroup);
radioButtonBars.setSelected(true); radioButtonBars.setSelected(true);
radioButtonLines.setToggleGroup(toggleGroup); radioButtonLines.setToggleGroup(toggleGroup);
accordion.setExpandedPane(accordion.getPanes().get(0));
} }
public void chartCategoriesShow() public void chartCategoriesShow()
...@@ -226,9 +228,5 @@ public class ChartController implements Refreshable ...@@ -226,9 +228,5 @@ public class ChartController implements Refreshable
// chart month // chart month
chartMonthShow(); chartMonthShow();
// TODO combine bar und line chart (radio buttons)
accordion.setExpandedPane(accordion.getPanes().get(0));
} }
} }
\ No newline at end of file
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment