error.fxml 4.7 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394
  1. <?xml version="1.0" encoding="UTF-8"?>
  2. <?import org.cryptomator.ui.controls.FontAwesome5IconView?>
  3. <?import org.cryptomator.ui.controls.FontAwesome5Spinner?>
  4. <?import org.cryptomator.ui.controls.FormattedLabel?>
  5. <?import javafx.geometry.Insets?>
  6. <?import javafx.scene.control.Button?>
  7. <?import javafx.scene.control.ButtonBar?>
  8. <?import javafx.scene.control.Hyperlink?>
  9. <?import javafx.scene.control.Label?>
  10. <?import javafx.scene.control.TextArea?>
  11. <?import javafx.scene.layout.HBox?>
  12. <?import javafx.scene.layout.Region?>
  13. <?import javafx.scene.layout.StackPane?>
  14. <?import javafx.scene.layout.VBox?>
  15. <?import javafx.scene.shape.Circle?>
  16. <VBox xmlns:fx="http://javafx.com/fxml"
  17. xmlns="http://javafx.com/javafx"
  18. fx:controller="org.cryptomator.ui.error.ErrorController"
  19. prefWidth="450"
  20. prefHeight="450"
  21. spacing="18"
  22. alignment="TOP_CENTER">
  23. <padding>
  24. <Insets topRightBottomLeft="24"/>
  25. </padding>
  26. <children>
  27. <HBox spacing="12" VBox.vgrow="NEVER">
  28. <StackPane alignment="CENTER" HBox.hgrow="NEVER">
  29. <Circle styleClass="glyph-icon-primary" radius="24"/>
  30. <FontAwesome5IconView styleClass="glyph-icon-white" glyph="EXCLAMATION" glyphSize="24"/>
  31. </StackPane>
  32. <VBox spacing="6" HBox.hgrow="ALWAYS">
  33. <FormattedLabel styleClass="label-extra-large" format="%error.message" arg1="${controller.errorCode}"/>
  34. <VBox visible="${!controller.askedForLookupDatabasePermission}" managed="${!controller.askedForLookupDatabasePermission}">
  35. <Label text="%error.lookupPermissionMessage" wrapText="true"/>
  36. <Region VBox.vgrow="ALWAYS" minHeight="18"/>
  37. <ButtonBar buttonMinWidth="120" buttonOrder="+NY">
  38. <buttons>
  39. <Button text="%error.dismiss" ButtonBar.buttonData="NO" onAction="#dismiss"/>
  40. <Button text="%error.lookUpSolution" ButtonBar.buttonData="YES" defaultButton="true" onAction="#lookUpSolution"/>
  41. </buttons>
  42. </ButtonBar>
  43. </VBox>
  44. <VBox visible="${controller.askedForLookupDatabasePermission}" managed="${controller.askedForLookupDatabasePermission}">
  45. <FontAwesome5Spinner glyphSize="24" visible="${controller.isLoadingHttpResponse}" managed="${controller.isLoadingHttpResponse}"/>
  46. <VBox visible="${!controller.isLoadingHttpResponse}" managed="${!controller.isLoadingHttpResponse}">
  47. <Label text="%error.existingSolutionDescription" wrapText="true" visible="${controller.errorSolutionFound}" managed="${controller.errorSolutionFound}"/>
  48. <Hyperlink styleClass="hyperlink-underline" text="%error.hyperlink.solution" onAction="#showSolution" contentDisplay="LEFT" visible="${controller.errorSolutionFound}" managed="${controller.errorSolutionFound}">
  49. <graphic>
  50. <FontAwesome5IconView glyph="LINK" glyphSize="12"/>
  51. </graphic>
  52. </Hyperlink>
  53. <Label text="%error.description" wrapText="true" visible="${!controller.errorSolutionFound}" managed="${!controller.errorSolutionFound}"/>
  54. <Hyperlink styleClass="hyperlink-underline" text="%error.hyperlink.lookup" onAction="#searchError" contentDisplay="LEFT" visible="${!controller.errorSolutionFound}" managed="${!controller.errorSolutionFound}">
  55. <graphic>
  56. <FontAwesome5IconView glyph="LINK" glyphSize="12"/>
  57. </graphic>
  58. </Hyperlink>
  59. <Hyperlink styleClass="hyperlink-underline" text="%error.hyperlink.report" onAction="#reportError" contentDisplay="LEFT" visible="${!controller.errorSolutionFound}" managed="${!controller.errorSolutionFound}">
  60. <graphic>
  61. <FontAwesome5IconView glyph="LINK" glyphSize="12"/>
  62. </graphic>
  63. </Hyperlink>
  64. </VBox>
  65. </VBox>
  66. </VBox>
  67. </HBox>
  68. <VBox spacing="6" VBox.vgrow="ALWAYS">
  69. <HBox>
  70. <Label text="%error.technicalDetails"/>
  71. <Region HBox.hgrow="ALWAYS"/>
  72. <Hyperlink styleClass="hyperlink-underline" text="%generic.button.copy" onAction="#copyDetails" contentDisplay="LEFT" visible="${!controller.copiedDetails}" managed="${!controller.copiedDetails}">
  73. <graphic>
  74. <FontAwesome5IconView glyph="CLIPBOARD" glyphSize="12"/>
  75. </graphic>
  76. </Hyperlink>
  77. <Hyperlink styleClass="hyperlink-underline" text="%generic.button.copied" onAction="#copyDetails" contentDisplay="LEFT" visible="${controller.copiedDetails}" managed="${controller.copiedDetails}">
  78. <graphic>
  79. <FontAwesome5IconView glyph="CHECK" glyphSize="12"/>
  80. </graphic>
  81. </Hyperlink>
  82. </HBox>
  83. <TextArea VBox.vgrow="ALWAYS" text="${controller.detailText}" prefRowCount="5" editable="false"/>
  84. </VBox>
  85. <ButtonBar buttonMinWidth="120" buttonOrder="B+C">
  86. <buttons>
  87. <Button text="%generic.button.back" ButtonBar.buttonData="BACK_PREVIOUS" onAction="#back" visible="${controller.previousScenePresent}"/>
  88. <Button text="%generic.button.cancel" ButtonBar.buttonData="CANCEL_CLOSE" onAction="#close"/>
  89. </buttons>
  90. </ButtonBar>
  91. </children>
  92. </VBox>