1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92
|
#include "editmode.hpp"
#include <apps/opencs/view/widget/modebutton.hpp>
#include "worldspacewidget.hpp"
class QMouseEvent;
class QWidget;
namespace CSVWidget
{
class SceneToolbar;
}
CSVRender::WorldspaceWidget& CSVRender::EditMode::getWorldspaceWidget()
{
return *mWorldspaceWidget;
}
CSVRender::EditMode::EditMode(
WorldspaceWidget* worldspaceWidget, const QIcon& icon, unsigned int mask, const QString& tooltip, QWidget* parent)
: ModeButton(icon, tooltip, parent)
, mWorldspaceWidget(worldspaceWidget)
, mMask(mask)
{
}
unsigned int CSVRender::EditMode::getInteractionMask() const
{
return mMask;
}
void CSVRender::EditMode::activate(CSVWidget::SceneToolbar* toolbar)
{
mWorldspaceWidget->setInteractionMask(mMask);
mWorldspaceWidget->clearSelection(~mMask);
}
void CSVRender::EditMode::setEditLock(bool locked) {}
void CSVRender::EditMode::primaryOpenPressed(const WorldspaceHitResult& hit) {}
void CSVRender::EditMode::primaryEditPressed(const WorldspaceHitResult& hit) {}
void CSVRender::EditMode::secondaryEditPressed(const WorldspaceHitResult& hit) {}
void CSVRender::EditMode::primarySelectPressed(const WorldspaceHitResult& hit) {}
void CSVRender::EditMode::secondarySelectPressed(const WorldspaceHitResult& hit) {}
void CSVRender::EditMode::tertiarySelectPressed(const WorldspaceHitResult& hit) {}
bool CSVRender::EditMode::primaryEditStartDrag(const QPoint& pos)
{
return false;
}
bool CSVRender::EditMode::secondaryEditStartDrag(const QPoint& pos)
{
return false;
}
bool CSVRender::EditMode::primarySelectStartDrag(const QPoint& pos)
{
return false;
}
bool CSVRender::EditMode::secondarySelectStartDrag(const QPoint& pos)
{
return false;
}
void CSVRender::EditMode::drag(const QPoint& pos, int diffX, int diffY, double speedFactor) {}
void CSVRender::EditMode::dragCompleted(const QPoint& pos) {}
void CSVRender::EditMode::dragAborted() {}
void CSVRender::EditMode::dragWheel(int diff, double speedFactor) {}
void CSVRender::EditMode::dragEnterEvent(QDragEnterEvent* event) {}
void CSVRender::EditMode::dropEvent(QDropEvent* event) {}
void CSVRender::EditMode::dragMoveEvent(QDragMoveEvent* event) {}
void CSVRender::EditMode::mouseMoveEvent(QMouseEvent* event) {}
int CSVRender::EditMode::getSubMode() const
{
return -1;
}
|