A docked window displaying the list of published input and/or output ports associated with the input composition
.
Definition at line 28 of file VuoPublishedPortSidebar.hh.
Public Slots | |
void | updatePortList () |
Populates the published port list with an up-to-date list of published ports. More... | |
void | highlightEligibleDropLocations (VuoRendererPort *internalFixedPort, bool eventOnlyConnection) |
Highlights eligible drop locations within the published port sidebar for the provided internalFixedPort . More... | |
void | clearEligibleDropLocationHighlighting () |
Clears the highlighting from eligible drop locations (sidebar published ports and drop box). More... | |
void | externalMoveEvent () |
Handle notifications from external sources that an event affecting this sidebar's position relative to the composition viewport has occurred. More... | |
void | updateHoverHighlighting (QMouseEvent *event, qreal tolerance=0) |
Begin and/or end hover-highlighting of components within the sidebar, given the cursor position associated with the the input mouse event . More... | |
void | clearHoverHighlighting () |
End hover-highlighting of components within the sidebar. More... | |
Signals | |
void | newPublishedPortRequested (string typeName, bool isInput) |
Emitted when a new externally visible published port is to be added. More... | |
void | publishedPortNameEditorRequested (VuoRendererPublishedPort *port, bool useUndoStack) |
Emitted in order to display a published port name editor. More... | |
void | publishedPortDetailsChangeRequested (VuoRendererPublishedPort *port, json_object *newDetails) |
Emitted when a published port's details have been changed in a details editor. More... | |
void | inputEditorRequested (VuoRendererPort *port) |
Emitted in order to display a published port input editor. More... | |
void | externalPortUnpublicationRequested (VuoRendererPublishedPort *port) |
Emitted when an externally visible published port is to be unpublished. More... | |
void | portPublicationRequestedViaDropBox (VuoPort *port, bool forceEventOnlyPublication, bool useUndoStackMacro) |
Emitted when an internal port is to be published. More... | |
void | portPublicationRequestedViaSidebarPort (VuoPort *internalPort, VuoPublishedPort *externalPort, bool forceEventOnlyPublication, VuoPort *portToSpecialize, string specializedTypeName, string typecastToInsert, bool useUndoStackMacro) |
Emitted when an internal port is to be published in association with a specific external published port. More... | |
void | componentsRemoved (QList< QGraphicsItem * > removedComponents, string commandDescription="Remove") |
Emitted when components are to be removed. More... | |
void | publishedPortPositionsUpdated () |
Emitted when the stored positions of the published ports within the sidebars have been updated. More... | |
void | publishedPortsReordered (vector< VuoPublishedPort * > publishedPorts, bool isInput) |
Emitted when published ports are reordered by the user. More... | |
void | undoStackMacroBeginRequested (QString commandName) |
Emitted when the upcoming sequence of requested operations should be coalesced in an Undo stack macro. More... | |
void | undoStackMacroEndRequested () |
Emitted when the sequence of operations to be coalesced into an Undo stack macro has completed. More... | |
void | closed () |
Emitted when the published port sidebar is closed. More... | |
Public Member Functions | |
VuoPublishedPortSidebar (QWidget *parent, VuoEditorComposition *composition, bool isInput, bool enableProtocolChanges=true) | |
Creates a published port list sidebar. More... | |
void | updateActiveProtocol () |
Updates the display of the active protocol. More... | |
void | concludePublishedCableDrag (QMouseEvent *event, VuoCable *cableInProgress, bool cableInProgressWasNew) |
Conclude a cable drag in response to a mouse release event occurring directly over the sidebar. More... | |
QMenu * | getProtocolsContextMenu () |
Returns the "Protocols" context menu associated with the sidebar. More... | |
QAction * | getRemoveProtocolAction () |
Returns the "Remove Protocol" action associated with the sidebar. More... | |
VuoRendererPublishedPort * | getPublishedPortUnderCursorForEvent (QMouseEvent *event, qreal tolerance=0, bool limitPortCollisionRange=false) |
Returns the published port under the cursor at the time of mouse event event , or NULL if no published port was under the cursor. More... | |
QPoint | getGlobalPosOfPublishedPort (VuoRendererPublishedPort *port) |
Returns the global position of the center of the port circle. More... | |
bool | getMenuSelectionInProgress () |
Returns a boolean indicating whether selection from a context menu is currently in progress. More... | |
string | showPublishedPortNameEditor (VuoRendererPublishedPort *port) |
Displays an input editor for a published port name. More... | |
void | limitAllowedPortTypes (const set< string > &allowedPortTypes) |
Limits the menu options available for data type when creating a published port. More... | |
void | limitInitialTypeOptions (bool limit) |
Limits the menu options displayed in the initial type menu to core types only, with a "More…" option to expand the menu. More... | |
Static Public Member Functions | |
static QColor | getActiveProtocolPortColor (int protocolIndex, bool isInput) |
Returns the background color to be used for a published port belonging to an active protocol, given the index of the protocol within the sidebar. More... | |
Protected Member Functions | |
void | contextMenuEvent (QContextMenuEvent *event) |
Handle context menu events. More... | |
void | mouseMoveEvent (QMouseEvent *event) |
Handle mouse move events. More... | |
void | mousePressEvent (QMouseEvent *event) |
Handle mouse press events. More... | |
void | dragEnterEvent (QDragEnterEvent *event) |
Handle drag enter events. More... | |
void | dropEvent (QDropEvent *event) |
Handle drop events. More... | |
void | closeEvent (QCloseEvent *event) |
Handle close events. More... | |
|
explicit |
Creates a published port list sidebar.
Definition at line 31 of file VuoPublishedPortSidebar.cc.
|
slot |
Clears the highlighting from eligible drop locations (sidebar published ports and drop box).
Definition at line 326 of file VuoPublishedPortSidebar.cc.
|
slot |
End hover-highlighting of components within the sidebar.
Components may include:
Definition at line 437 of file VuoPublishedPortSidebar.cc.
|
signal |
Emitted when the published port sidebar is closed.
|
protected |
Handle close events.
Definition at line 660 of file VuoPublishedPortSidebar.cc.
|
signal |
Emitted when components are to be removed.
void VuoPublishedPortSidebar::concludePublishedCableDrag | ( | QMouseEvent * | event, |
VuoCable * | cableInProgress, | ||
bool | cableInProgressWasNew | ||
) |
Conclude a cable drag in response to a mouse release event
occurring directly over the sidebar.
This may mean:
Definition at line 462 of file VuoPublishedPortSidebar.cc.
|
protected |
Handle context menu events.
Definition at line 582 of file VuoPublishedPortSidebar.cc.
|
protected |
Handle drag enter events.
Definition at line 635 of file VuoPublishedPortSidebar.cc.
|
protected |
Handle drop events.
Definition at line 646 of file VuoPublishedPortSidebar.cc.
|
slot |
Handle notifications from external sources that an event affecting this sidebar's position relative to the composition viewport has occurred.
When the widget receives this event, it is already at the new position.
Definition at line 627 of file VuoPublishedPortSidebar.cc.
|
signal |
Emitted when an externally visible published port is to be unpublished.
|
static |
Returns the background color to be used for a published port belonging to an active protocol, given the index of the protocol within the sidebar.
Definition at line 748 of file VuoPublishedPortSidebar.cc.
QPoint VuoPublishedPortSidebar::getGlobalPosOfPublishedPort | ( | VuoRendererPublishedPort * | port | ) |
Returns the global position of the center of the port circle.
Definition at line 718 of file VuoPublishedPortSidebar.cc.
bool VuoPublishedPortSidebar::getMenuSelectionInProgress | ( | ) |
Returns a boolean indicating whether selection from a context menu is currently in progress.
Definition at line 726 of file VuoPublishedPortSidebar.cc.
QMenu * VuoPublishedPortSidebar::getProtocolsContextMenu | ( | ) |
Returns the "Protocols" context menu associated with the sidebar.
Definition at line 382 of file VuoPublishedPortSidebar.cc.
VuoRendererPublishedPort * VuoPublishedPortSidebar::getPublishedPortUnderCursorForEvent | ( | QMouseEvent * | event, |
qreal | tolerance = 0 , |
||
bool | limitPortCollisionRange = false |
||
) |
Returns the published port under the cursor at the time of mouse event event
, or NULL if no published port was under the cursor.
Definition at line 709 of file VuoPublishedPortSidebar.cc.
QAction * VuoPublishedPortSidebar::getRemoveProtocolAction | ( | ) |
Returns the "Remove Protocol" action associated with the sidebar.
Definition at line 390 of file VuoPublishedPortSidebar.cc.
|
slot |
Highlights eligible drop locations within the published port sidebar for the provided internalFixedPort
.
If eventOnlyConnection
is true, operates as if the ports will be connected with a cable that is event-only regardless of the data-carrying status of the ports. Eligible drop locations may include:
internalFixedPort
.Definition at line 292 of file VuoPublishedPortSidebar.cc.
|
signal |
Emitted in order to display a published port input editor.
void VuoPublishedPortSidebar::limitAllowedPortTypes | ( | const set< string > & | allowedPortTypes | ) |
Limits the menu options available for data type when creating a published port.
Must be called before the first time the menu is shown.
Definition at line 1035 of file VuoPublishedPortSidebar.cc.
void VuoPublishedPortSidebar::limitInitialTypeOptions | ( | bool | limit | ) |
Limits the menu options displayed in the initial type menu to core types only, with a "More…" option to expand the menu.
Must be called before the first time the menu is shown.
Definition at line 1046 of file VuoPublishedPortSidebar.cc.
|
protected |
Handle mouse move events.
Definition at line 605 of file VuoPublishedPortSidebar.cc.
|
protected |
Handle mouse press events.
Definition at line 614 of file VuoPublishedPortSidebar.cc.
|
signal |
Emitted when a new externally visible published port is to be added.
|
signal |
Emitted when an internal port is to be published.
|
signal |
Emitted when an internal port is to be published in association with a specific external published port.
|
signal |
Emitted when a published port's details have been changed in a details editor.
|
signal |
Emitted in order to display a published port name editor.
|
signal |
Emitted when the stored positions of the published ports within the sidebars have been updated.
|
signal |
Emitted when published ports are reordered by the user.
string VuoPublishedPortSidebar::showPublishedPortNameEditor | ( | VuoRendererPublishedPort * | port | ) |
Displays an input editor for a published port name.
port | The published port whose name is to be edited. |
Definition at line 762 of file VuoPublishedPortSidebar.cc.
|
signal |
Emitted when the upcoming sequence of requested operations should be coalesced in an Undo stack macro.
|
signal |
Emitted when the sequence of operations to be coalesced into an Undo stack macro has completed.
void VuoPublishedPortSidebar::updateActiveProtocol | ( | ) |
Updates the display of the active protocol.
Definition at line 354 of file VuoPublishedPortSidebar.cc.
|
slot |
Begin and/or end hover-highlighting of components within the sidebar, given the cursor position associated with the the input mouse event
.
Components may include:
Definition at line 404 of file VuoPublishedPortSidebar.cc.
|
slot |
Populates the published port list with an up-to-date list of published ports.
Definition at line 113 of file VuoPublishedPortSidebar.cc.