From 958febdddef312058988350e4ec81c1816561aa4 Mon Sep 17 00:00:00 2001 From: vsr Date: Fri, 15 Apr 2005 05:53:11 +0000 Subject: [PATCH] PAL8598: Provide an access to "Dump View" functionality from the context popup menu for the viewer --- src/OCCViewer/OCCViewer_ViewFrame.cxx | 2 ++ src/OCCViewer/OCCViewer_ViewPort.h | 2 ++ src/OCCViewer/OCCViewer_ViewPort3d.cxx | 2 ++ 3 files changed, 6 insertions(+) diff --git a/src/OCCViewer/OCCViewer_ViewFrame.cxx b/src/OCCViewer/OCCViewer_ViewFrame.cxx index 90645fdb2..8396a6a6c 100644 --- a/src/OCCViewer/OCCViewer_ViewFrame.cxx +++ b/src/OCCViewer/OCCViewer_ViewFrame.cxx @@ -189,6 +189,8 @@ void OCCViewer_ViewFrame::initViewPort() this, SIGNAL( vfKeyPress( QKeyEvent* ) ) ) ); QAD_ASSERT( connect( myViewPort, SIGNAL( vpKeyRelease( QKeyEvent* ) ), this, SIGNAL( vfKeyRelease( QKeyEvent* ) ) ) ); + QAD_ASSERT( connect( myViewPort, SIGNAL( vpDumpView() ), + this, SLOT( onProcessViewDump() ) ) ); } //======================================================================= diff --git a/src/OCCViewer/OCCViewer_ViewPort.h b/src/OCCViewer/OCCViewer_ViewPort.h index 6f80c7816..1ddf54a18 100644 --- a/src/OCCViewer/OCCViewer_ViewPort.h +++ b/src/OCCViewer/OCCViewer_ViewPort.h @@ -171,6 +171,8 @@ signals: void vpPaint (QPaintEvent*); void vpDrawExternal (QPainter* painter); + void vpDumpView(); + protected slots: virtual void onChangeBackgroundColor() = 0; diff --git a/src/OCCViewer/OCCViewer_ViewPort3d.cxx b/src/OCCViewer/OCCViewer_ViewPort3d.cxx index 0ace89025..6b39a2add 100644 --- a/src/OCCViewer/OCCViewer_ViewPort3d.cxx +++ b/src/OCCViewer/OCCViewer_ViewPort3d.cxx @@ -99,6 +99,8 @@ void OCCViewer_ViewPort3d::onCreatePopup() int id; myIDs.append ( id = myPopup->insertItem (tr ("MEN_VP3D_CHANGEBGR")) ); QAD_ASSERT ( myPopup->connectItem ( id, this, SLOT(onChangeBackgroundColor())) ); + myIDs.append ( id = myPopup->insertItem (tr ("MEN_VP3D_DUMPVIEW")) ); + QAD_ASSERT ( myPopup->connectItem ( id, this, SIGNAL(vpDumpView())) ); // } } } -- 2.39.2