Skip to content

Commit

Permalink
Reuse the existing ribbon builder for the temporary demo
Browse files Browse the repository at this point in the history
Also move the popup menu presentation model to be non-configurable in preparation for the work on it

For #56
  • Loading branch information
kirill-grouchnikov committed Jan 14, 2023
1 parent c335290 commit 46d765a
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 614 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -181,7 +181,6 @@ data class RibbonApplicationMenuCommandButtonPresentationModel(
override val textOverflow: TextOverflow = TextOverflow.Clip,
override val popupPlacementStrategy: PopupPlacementStrategy = PopupPlacementStrategy.Downward.HAlignStart,
override val popupKeyTip: String? = null,
override val popupMenuPresentationModel: CommandPopupMenuPresentationModel = CommandPopupMenuPresentationModel(),
override val popupRichTooltipPresentationModel: RichTooltipPresentationModel = RichTooltipPresentationModel(),
override val contentPadding: PaddingValues = CommandButtonSizingConstants.WideButtonContentPadding,
override val sides: Sides = Sides()
Expand All @@ -203,6 +202,8 @@ data class RibbonApplicationMenuCommandButtonPresentationModel(
override val textClick = TextClick.Action
override val actionRichTooltipPresentationModel = RichTooltipPresentationModel()
override val toDismissPopupsOnActivation: Boolean = true
override val popupMenuPresentationModel: CommandPopupMenuPresentationModel =
CommandPopupMenuPresentationModel(menuPresentationState = CommandButtonPresentationState.Tile)
override val horizontalGapScaleFactor: Float = 1.0f
override val verticalGapScaleFactor: Float = 1.0f
override val minWidth: Dp = 0.dp
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -189,7 +189,7 @@ fun main() = auroraApplication {
)
}

private class RibbonBuilder(val resourceBundle: ResourceBundle) {
internal class RibbonBuilder(val resourceBundle: ResourceBundle) {
val mf = MessageFormat(resourceBundle.getString("TestMenuItem.text"))
val popupCommand1 = Command(
text = mf.format(arrayOf("1")),
Expand Down
Loading

0 comments on commit 46d765a

Please sign in to comment.