Isis 3 Programmer Reference
CubeDnView.h
1#ifndef CubeDnView_h
2#define CubeDnView_h
3
10/* SPDX-License-Identifier: CC0-1.0 */
11
12#include <QList>
13#include <QMap>
14#include <QWidgetAction>
15
16#include "AbstractProjectItemView.h"
17#include "FileName.h"
18
19class QAction;
20class QMenu;
21class QModelIndex;
22class QToolBar;
23class QXmlStreamWriter;
24class QWidget;
25
26namespace Isis {
27
28 class ControlPoint;
29 class Cube;
30 class Directory;
31 class Image;
32 class ImageList;
33 class MdiCubeViewport;
34 class Project;
35 class ToolPad;
36 class Workspace;
37 class ProjectItemViewMenu;
38
96
97 Q_OBJECT
98
99 public:
100 CubeDnView(Directory *directory, QWidget *parent=0);
101 ~CubeDnView();
102
103 bool viewportContainsShape(MdiCubeViewport *viewport);
104
105 void save(QXmlStreamWriter &stream, Project *project, FileName newProjectRoot) const;
106
107 signals:
108 void modifyControlPoint(ControlPoint *controlPoint, QString serialNumber);
109 void deleteControlPoint(ControlPoint *controlPoint);
110 void createControlPoint(double latitude, double longitude, Cube *cube,
111 bool isGroundSource = false);
112
113 void controlPointAdded(QString newPointId);
114 void redrawMeasures();
115
116 public slots:
117 void addItem(ProjectItem *item);
118 void enableControlNetTool(bool value);
119
120 private slots:
121 void createActions(Directory *directory);
122
123 void onCurrentChanged(const QModelIndex &current);
125 void onItemAdded(ProjectItem *item);
126 void onCubeViewportAdded(MdiCubeViewport *viewport);
128 void disableActions();
129
130 private:
132 void setWorkspaceActiveCube(Image *image);
133 void leaveEvent(QEvent *event);
134 void enableActions();
135
136 private:
137 QMap<Cube *, ProjectItem *> m_cubeItemMap;
140
144
146
150 QList<QWidget *> m_childWidgets;
151 };
152}
153
154#endif
AbstractProjectItemView is a base class for views of a ProjectItemModel in Qt's model-view framework.
A single control point.
View that displays cubes in a QView-like way.
Definition CubeDnView.h:95
void onCubeViewportActivated(MdiCubeViewport *)
Slot to connect to the cubeViewportActivated signal from the Workspace.
void disableActions()
Disables toolbars and toolpad actions/widgets.
ProjectItemViewMenu * m_windowMenu
Window menu for storing actions.
Definition CubeDnView.h:143
ProjectItemViewMenu * m_viewMenu
View menu for storing actions.
Definition CubeDnView.h:141
void leaveEvent(QEvent *event)
Disables actions when the cursor leaves the view.
QMap< Cube *, ProjectItem * > m_cubeItemMap
Maps cubes to their items.
Definition CubeDnView.h:137
void onCurrentChanged(const QModelIndex &current)
Slot to connect to the currentChanged() signal from a selection model.
QToolBar * m_permToolBar
A tool bar for storing actions.
Definition CubeDnView.h:147
ProjectItemViewMenu * m_optionsMenu
Options menu for storing actions.
Definition CubeDnView.h:142
void addItem(ProjectItem *item)
Adds an item to the view.
Directory * m_directory
The directory.
Definition CubeDnView.h:139
Cube * workspaceActiveCube()
Returns the cube of the active viewport in the Workspace, or a null pointer if no viewports are activ...
ToolPad * m_toolPad
A tool bar for storing actions.
Definition CubeDnView.h:149
void enableActions()
Enables toolbars and toolpad actions/widgets.
void onItemAdded(ProjectItem *item)
Slot to connect to the itemAdded signal from a ProjectItemModel.
Workspace * m_workspace
The workspace.
Definition CubeDnView.h:138
QList< QWidget * > m_childWidgets
Child widgets of the active toolbar.
Definition CubeDnView.h:150
CubeDnView(Directory *directory, QWidget *parent=0)
Constructs the view, initializing the tools.
~CubeDnView()
Destructor.
QToolBar * m_activeToolBar
A tool bar for storing actions.
Definition CubeDnView.h:148
void onCubeViewportDeleted(QObject *obj)
Slot to connect to the destroyed signal from a viewport.
void onCubeViewportAdded(MdiCubeViewport *viewport)
Slot to connect to the viewportAdded signal from a Workspace.
void setWorkspaceActiveCube(Image *image)
Raises the subwindow corresponding with an image to the top.
QAction * m_separatorAction
A separator action that is reused.
Definition CubeDnView.h:145
void enableControlNetTool(bool value)
A slot function that is called when directory emits a signal that an active control network is set.
IO Handler for Isis Cubes.
Definition Cube.h:168
File name manipulation and expansion.
Definition FileName.h:100
This represents a cube in a project-based GUI interface.
Definition Image.h:105
Cube display widget for certain Isis MDI applications.
The main project for ipce.
Definition Project.h:287
Represents an item of a ProjectItemModel in Qt's model-view framework.
QMenu subclass that overrides the closeEvent.
This is free and unencumbered software released into the public domain.
Definition Apollo.h:16