Skip to content
This repository has been archived by the owner on Aug 31, 2021. It is now read-only.

Adding new item to revMenuBarStandardContextMenu #2126

Open
wants to merge 1 commit into
base: develop-9.6
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
33 changes: 31 additions & 2 deletions Toolset/palettes/menubar/revmenubar.livecodescript
Original file line number Diff line number Diff line change
Expand Up @@ -2182,10 +2182,24 @@ function revMenuBarStandardContextMenu pObject, pIndent, pSelectable
put tIndent & "Property Inspector" & return after tText
put tIndent & "-" & return after tText
put tIndent & enableMenuItem("Cut", pSelectable) & return after tText
put tIndent & enableMenuItem("Copy", pSelectable) after tText
put tIndent & enableMenuItem("Copy", pSelectable) & return after tText
put tIndent & "-" & return after tText
put tIndent & buildArrangeSubmenu() after tText
return tText
end revMenuBarStandardContextMenu

private function buildArrangeSubmenu
local tArrange
put "Arrange" & return after tArrange
put tab & "Send to Back" & return after tArrange
put tab & "Move Backward" & return after tArrange
put tab & "Move Forward" & return after tArrange
put tab & "Bring to Front" after tArrange
return tArrange
end buildArrangeSubmenu



function revBuildContextSensitiveMenu pExtraText, pTarget, pType, pSelectable
local tText
if word 1 of pTarget is "stack" then
Expand Down Expand Up @@ -2549,7 +2563,7 @@ on revMenubarContextMenuPickTarget pWhich, pTarget

set the itemdelimiter to "|"
switch item 1 of pWhich
######## OBJECTS #########
######## OBJECTS #########
case "Edit Script"
revIDEEditScriptOfObjects pTarget
break
Expand Down Expand Up @@ -2696,6 +2710,21 @@ on revMenubarContextMenuPickTarget pWhich, pTarget
case "Stack"
revMenubarContextMenuPickTarget item 2 to 3 of pWhich, tTargetStack
break
end switch
######## ARRANGESUBMENU #########
switch item 2 of pWhich
case "Send to Back"
revIDEActionSendToBack
break
case "Move Backward"
revIDEActionMoveBackward
break
case "Move forward"
revIDEActionMoveForward
break
case "Bring to Front"
revIDEActionBringToFront
break
default
break
end switch
Expand Down