Ignore:
Timestamp:
Nov 22, 2007, 6:07:00 PM (17 years ago)
Author:
garnier
Message:

r661@mac-90108: laurentgarnier | 2007-11-22 18:10:43 +0100
en debug

Location:
trunk/geant4/visualization/OpenGL
Files:
6 edited

Legend:

Unmodified
Added
Removed
  • trunk/geant4/visualization/OpenGL/History

    r609 r610  
    1 $Id: History,v 1.100 2007/11/16 10:41:54 lgarnier Exp $
     1$Id: History,v 1.101 2007/11/16 11:15:43 lgarnier Exp $
    22-------------------------------------------------------------------
    33
     
    2121-------------------------------------
    2222
    23 <<<<<<< History
     2315th November 2007  John Allison  (opengl-V09-00-03)
     24- Re-introduced Qt files, now properly protected by cpp flags.
     25- cpp flags also added to some other files not previously properly protected.
     26
    242715 Nov 2007, Laurent Garnier
    2528 - G4UIQt,G4Qt : Adding a GEANT4_QT_DEBUG flag to hide all debug messages
     
    3336     Adding protection for Qt version between 4.0 and 4.2
    3437
     3813th November 2007  John Allison  (opengl-V09-00-02)
     39- Removed Qt files from tag.  File are still at head - need fixing.
     40
    354113 Nov 2007, Laurent Garnier
    3642 - G4UIQt,G4Qt : Moving all moc in one big file interface/G4UIQT_moc.cc,
    3743   including Qt3 and Qt4 moc support
     44
     4510th November 2007  John Allison  (opengl-V09-00-01)
     46- Moved WinSize_x, y to base class G4OpenGLViewer.
     47- Minor improvement in guidance for /vis/ogl/printEPS.
    3848
    394909 Nov 2007, Laurent Garnier
     
    5565   - moc_G4OpenGLQtViewer.cc
    5666
    57 =======
    58 15th November 2007  John Allison  (opengl-V09-00-03)
    59 - Re-introduced Qt files, now properly protected by cpp flags.
    60 - cpp flags also added to some other files not previously properly protected.
    61 
    62 13th November 2007  John Allison  (opengl-V09-00-02)
    63 - Removed Qt files from tag.  File are still at head - need fixing.
    64 
    65 10th November 2007  John Allison  (opengl-V09-00-01)
    66 - Moved WinSize_x, y to base class G4OpenGLViewer.
    67 - Minor improvement in guidance for /vis/ogl/printEPS.
    68 
    696728th September 2007  lgarnier
    7068- first import of G4UI Qt files : Do not try to compil them
    7169
    72 >>>>>>> 1.99
    737021st August 2007  John Allison  (opengl-V09-00-00)
    7471- Removed redundant G4OpenGLXViewerMessenger.
  • trunk/geant4/visualization/OpenGL/include/G4OpenGLQtViewer.hh

    r606 r610  
    132132  void toggleFullScreen(bool);
    133133
    134   void dialogClosed();
    135134};
    136135
  • trunk/geant4/visualization/OpenGL/src/G4OpenGLQtViewer.cc

    r608 r610  
    3636#ifdef G4VIS_BUILD_OPENGLQT_DRIVER
    3737
     38#define GEANT4_QT_DEBUG
     39
    3840#include "G4OpenGLQtViewer.hh"
    3941
     
    194196    }
    195197#endif
     198    // FIXME : not tested in Qt4
     199    glWidget->reparent(GLWindow,0,QPoint(0,0)); 
    196200
    197201    if (found==false) {
     
    224228  GLWindow->resize(300, 300);
    225229  GLWindow->move(900,300);
     230#ifdef GEANT4_QT_DEBUG
     231  printf("G4OpenGLQtViewer::Should show glWidget\n");
     232#endif
    226233  GLWindow->show();
    227234 
     
    229236  //  GLWindow->setAttribute(Qt::WA_DeleteOnClose);
    230237
     238#if QT_VERSION >= 0x040000
    231239  QObject ::connect(GLWindow,
    232240                    SIGNAL(rejected()),
    233241                    this,
    234242                    SLOT(dialogClosed()));
     243#endif
    235244
    236245  WinSize_x = 400;
     
    251260}
    252261
     262#if QT_VERSION >= 0x040000
    253263/**  Close the dialog and set the pointer to NULL
    254264 */
    255265void G4OpenGLQtViewer::dialogClosed() {
    256   GLWindow = NULL;
    257 }
    258 
     266#ifdef GEANT4_QT_DEBUG
     267  printf("G4OpenGLQtViewer::dialogClosed END\n");
     268#endif
     269  //  GLWindow = NULL;
     270}
     271#endif
    259272
    260273//////////////////////////////////////////////////////////////////////////////
     
    340353
    341354  QMenu *mRepresentation = mStyle->addMenu("&Representation");
    342   QAction *polyhedron = mRepresentation->addAction("Polyhedron");
     355 QAction *polyhedron = mRepresentation->addAction("Polyhedron");
    343356  QAction *nurbs = mRepresentation->addAction("NURBS");
    344357#endif
     
    362375  fDrawingWireframe = new QPopupMenu(mDrawing);
    363376  mDrawing->insertItem("&Wireframe",fDrawingWireframe);
     377#ifdef GEANT4_QT_DEBUG
     378  printf("G4OpenGLQtViewer:: fDrawingWireframe creation\n");
     379#endif
    364380
    365381  mDrawing->setCheckable(true);
     
    410426    mDrawing->clear();
    411427  }
     428#ifdef GEANT4_QT_DEBUG
     429  printf("G4OpenGLQtViewer:: fDrawingWireframe 1\n");
     430#endif
     431  QObject ::connect(fDrawingWireframe,
     432                    SIGNAL(activated(int)),
     433                    this,
     434                    SLOT(actionDrawingWireframe()));
     435#ifdef GEANT4_QT_DEBUG
     436  printf("G4OpenGLQtViewer:: fDrawingWireframe 2\n");
     437#endif
     438  QObject ::connect(fDrawingLineRemoval,
     439                    SIGNAL(activated(int)),
     440                    this,
     441                    SLOT(actionDrawingLineRemoval()));
     442  QObject ::connect(fDrawingSurfaceRemoval,
     443                    SIGNAL(activated(int)),
     444                    this,
     445                    SLOT(actionDrawingSurfaceRemoval()));
     446  QObject ::connect(fDrawingLineSurfaceRemoval,
     447                    SIGNAL(activated(int)),
     448                    this,
     449                    SLOT(actionDrawingLineSurfaceRemoval()));
    412450#else
    413451  if (d_style == G4ViewParameters::wireframe) {
     
    422460    mDrawing->clear();
    423461  }
    424 #endif
    425 
    426462  QObject ::connect(fDrawingWireframe,
    427463                    SIGNAL(triggered(bool)),
     
    440476                    this,
    441477                    SLOT(actionDrawingLineSurfaceRemoval()));
     478#endif
     479
    442480
    443481
     
    477515  exitG4->addTo(mActions);
    478516  createEPS->addTo(mActions);
     517  QObject ::connect(controlPanels,
     518                    SIGNAL(activated()),
     519                    this,
     520                    SLOT(actionControlPanels()));
     521  QObject ::connect(exitG4,
     522                    SIGNAL(activated()),
     523                    this,
     524                    SLOT(actionExitG4()));
     525  QObject ::connect(createEPS,
     526                    SIGNAL(activated()),
     527                    this,
     528                    SLOT(actionCreateEPS()));
    479529
    480530#else
     
    484534  QAction *exitG4 = mActions->addAction("Exit to G4Vis >");
    485535  QAction *createEPS = mActions->addAction("Save as ...");
    486 #endif
    487 
    488536  QObject ::connect(controlPanels,
    489537                    SIGNAL(triggered()),
     
    498546                    this,
    499547                    SLOT(actionCreateEPS()));
     548#endif
     549
    500550
    501551
     
    653703    ((QPopupMenu*)action1->parent())->setItemChecked(1,true);
    654704   
    655   QObject ::connect(action1, SIGNAL(triggered(bool)),action2, SLOT(toggle()));
    656   QObject ::connect(action2, SIGNAL(triggered(bool)),action1, SLOT(toggle()));
     705  //FIXME : Should not work on Qt3
     706  QObject ::connect(action1, SIGNAL(activated()),action2, SLOT(toggle()));
     707  QObject ::connect(action2, SIGNAL(activated()),action1, SLOT(toggle()));
    657708
    658709  QObject ::connect(action1, SIGNAL(toggled(bool)),this, method.c_str());
  • trunk/geant4/visualization/OpenGL/src/G4OpenGLQtViewer_moc.cc

    r607 r610  
    100100    };
    101101    static const QUMethod slot_15 = {"toggleFullScreen", 1, param_slot_15 };
    102     static const QUMethod slot_16 = {"dialogClosed", 0, 0 };
    103102    static const QMetaData slot_tbl[] = {
    104103        { "actionDrawingWireframe()", &slot_0, QMetaData::Private },
     
    117116        { "toggleHaloing(bool)", &slot_13, QMetaData::Private },
    118117        { "toggleAux(bool)", &slot_14, QMetaData::Private },
    119         { "toggleFullScreen(bool)", &slot_15, QMetaData::Private },
    120         { "dialogClosed()", &slot_16, QMetaData::Private }
     118        { "toggleFullScreen(bool)", &slot_15, QMetaData::Private }
    121119    };
    122120    metaObj = QMetaObject::new_metaobject(
    123121        "G4OpenGLQtViewer", parentObject,
    124         slot_tbl, 17,
     122        slot_tbl, 16,
    125123        0, 0,
    126124#ifndef QT_NO_PROPERTIES
     
    161159    case 14: toggleAux((bool)static_QUType_bool.get(_o+1)); break;
    162160    case 15: toggleFullScreen((bool)static_QUType_bool.get(_o+1)); break;
    163     case 16: dialogClosed(); break;
    164161    default:
    165162        return QObject::qt_invoke( _id, _o );
  • trunk/geant4/visualization/OpenGL/src/G4OpenGLStoredQt.cc

    r608 r610  
    3232
    3333#ifdef G4VIS_BUILD_OPENGLQT_DRIVER
     34
     35#define GEANT4_QT_DEBUG
    3436
    3537#include "G4VisFeaturesOfOpenGL.hh"
  • trunk/geant4/visualization/OpenGL/src/G4OpenGLStoredQtViewer.cc

    r608 r610  
    3434#ifdef G4VIS_BUILD_OPENGLQT_DRIVER
    3535
     36#define GEANT4_QT_DEBUG
     37
    3638#include "G4OpenGLStoredQtViewer.hh"
    3739#include "G4VisManager.hh"
     
    127129#ifdef GEANT4_QT_DEBUG
    128130  printf("G4OpenGLStoredQtViewer::DrawView %d %d   VVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVV\n",WinSize_x, WinSize_y);
    129   printf("G4OpenGLStoredQtViewer::DrawView Dialog adress : %d\n",GLWindow);
    130131#endif
    131132   G4ViewParameters::DrawingStyle style = GetViewParameters().GetDrawingStyle();
Note: See TracChangeset for help on using the changeset viewer.