spinetoolbox.project_items.data_connection.data_connection_icon

Module for data connection icon class.

authors:
  1. Marin (KTH), P. Savolainen (VTT)
date:

4.4.2018

Module Contents

class spinetoolbox.project_items.data_connection.data_connection_icon.DataConnectionIcon(toolbox, x, y, w, h, name)[source]

Bases: spinetoolbox.graphics_items.ProjectItemIcon

Data Connection icon for the Design View.

Parameters:
  • toolbox (ToolboxUI) – main window instance
  • x (float) – Icon x coordinate
  • y (float) – Icon y coordinate
  • w (float) – Width of master icon
  • h (float) – Height of master icon
  • name (str) – Item name
class _SignalHolder[source]

Bases: PySide2.QtCore.QObject

files_dropped_on_icon[source]

A signal that it triggered when files are dragged and dropped on the item.

dragEnterEvent(self, event)[source]

Drag and drop action enters. Accept file drops from the filesystem.

Parameters:event (QGraphicsSceneDragDropEvent) – Event
dragLeaveEvent(self, event)[source]

Drag and drop action leaves.

Parameters:event (QGraphicsSceneDragDropEvent) – Event
dragMoveEvent(self, event)[source]

Accept event.

dropEvent(self, event)[source]

Emit files_dropped_on_dc signal from scene, with this instance, and a list of files for each dropped url.

select_on_drag_over(self)[source]

Called when the timer started in drag_enter_event is elapsed. Select this item if the drag action is still over it.