]> SALOME platform Git repositories - modules/gui.git/commitdiff
Salome HOME
Executable version on Windows Platform
authorabd <abd@opencascade.com>
Thu, 17 Jul 2008 06:38:49 +0000 (06:38 +0000)
committerabd <abd@opencascade.com>
Thu, 17 Jul 2008 06:38:49 +0000 (06:38 +0000)
src/OCCViewer/OCCViewer_ViewPort.cxx
src/PyConsole/PyConsole_Editor.cxx
src/PyInterp/PyInterp_Dispatcher.cxx
src/PyInterp/PyInterp_Dispatcher.h
src/SVTK/SALOME_Actor.h
src/SVTK/SVTK_RenderWindowInteractor.cxx
src/SVTK/SVTK_RenderWindowInteractor.h
src/Session/SALOME_Session_Server.cxx
src/Session/Session_Session_i.cxx
src/Session/Session_Session_i.hxx

index 166a7bb34c27ea1ae44423febd608734390ab89b..d21fb39f3b87aec145508f42a63abbbfe0dfd4ed 100755 (executable)
 #include <QColorDialog>
 #include <QColormap>
 #include <QCoreApplication>
-#include <QX11Info>
 
 #include <stdlib.h>
 
 #if !defined WNT
+#include <QX11Info>
 #include <GL/glx.h>
 #include <X11/Xlib.h>
 #include <X11/Xutil.h>
index fea5d6804604178ef75d6115f5db99fc23c3634f..af69ea1fb31bbcbf9e5118286f0a146663a992ed 100644 (file)
@@ -138,7 +138,7 @@ public:
               PyConsole_Editor*       theListener, 
               bool                    sync = false )
     : PyInterp_LockRequest( theInterp, theListener, sync ),
-      myCommand( theCommand ), myState( PyInterp_Event::OK )
+      myCommand( theCommand ), myState( PyInterp_Event::ES_OK )
   {}
 
 protected:
@@ -152,9 +152,9 @@ protected:
     {
       int ret = getInterp()->run( myCommand.toLatin1() );
       if ( ret < 0 )
-       myState = PyInterp_Event::ERROR;
+       myState = PyInterp_Event::ES_ERROR;
       else if ( ret > 0 )
-       myState = PyInterp_Event::INCOMPLETE;
+       myState = PyInterp_Event::ES_INCOMPLETE;
     } 
   }
 
@@ -906,8 +906,8 @@ void PyConsole_Editor::customEvent( QEvent* event )
       addText( pe->text() );
       return;
     }
-  case PyInterp_Event::OK:
-  case PyInterp_Event::ERROR:
+  case PyInterp_Event::ES_OK:
+  case PyInterp_Event::ES_ERROR:
   {
     // clear command buffer
     myCommandBuffer.truncate( 0 );
@@ -928,7 +928,7 @@ void PyConsole_Editor::customEvent( QEvent* event )
       myEventLoop->exit();
     break;
   }
-  case PyInterp_Event::INCOMPLETE:
+  case PyInterp_Event::ES_INCOMPLETE:
   {
     // extend command buffer (multi-line command)
     myCommandBuffer.append( "\n" );
@@ -958,7 +958,7 @@ void PyConsole_Editor::customEvent( QEvent* event )
   // unset history browsing mode
   myCmdInHistory = -1;
 
-  if ( (int)event->type() == (int)PyInterp_Event::OK && myQueue.count() > 0 )
+  if ( (int)event->type() == (int)PyInterp_Event::ES_OK && myQueue.count() > 0 )
   {
     // process the next sheduled command from the queue (if there is any)
     QString nextcmd = myQueue[0];
index e3adb001d7f0ee33789b683ef02856a4784bc994..052ccbf19b844639631472b8410f8f7d31d646bb 100755 (executable)
@@ -62,7 +62,7 @@ void PyInterp_Request::Destroy( PyInterp_Request* request )
 
 QEvent* PyInterp_Request::createEvent() const
 {
-  return new PyInterp_Event( PyInterp_Event::NOTIFY, (PyInterp_Request*)this );
+  return new PyInterp_Event( PyInterp_Event::ES_NOTIFY, (PyInterp_Request*)this );
 }
 
 void PyInterp_Request::processEvent( QObject* o )
index cf46694e41f22d7eb1b0d89d12eab5bd3d63e1e0..66cd2c0a2c22d0d259d145180205b3fd7a7c8a0b 100755 (executable)
@@ -102,7 +102,8 @@ class PYINTERP_EXPORT PyInterp_Event : public QEvent
   PyInterp_Event( const PyInterp_Event& );
 
 public:
-  enum { NOTIFY = QEvent::User + 5000, OK, ERROR, INCOMPLETE, LAST };
+  //Execution status
+  enum { ES_NOTIFY = QEvent::User + 5000, ES_OK, ES_ERROR, ES_INCOMPLETE, ES_LAST };
 
   PyInterp_Event( int type, PyInterp_Request* request )
     : QEvent( (QEvent::Type)type ), myRequest( request ) {}
index db4e2e56e440aa897fbc31799729bf0bb7f7e1e1..4316ef3dc59e31bc397e47e349265a2370c85373 100644 (file)
@@ -54,8 +54,8 @@ class SVTK_Actor;
 class SVTK_RectPicker;
 class SVTK_InteractorStyle;
 
-extern int SALOME_POINT_SIZE;
-extern int SALOME_LINE_WIDTH;
+SVTK_EXPORT extern int SALOME_POINT_SIZE;
+SVTK_EXPORT extern int SALOME_LINE_WIDTH;
 
 #ifdef WIN32
 #pragma warning ( disable:4251 )
index 56236ad891bf837d568aac88d26873ed1f5efee8..66287bf793afe5f5fed35bef99bf9a5b2d8415c3 100644 (file)
@@ -37,7 +37,9 @@
 // QT Includes
 // Put Qt includes before the X11 includes which #define the symbol None
 // (see SVTK_SpaceMouse.h) to avoid the compilation error.
-#include <QX11Info>
+#ifndef WIN32
+# include <QX11Info>
+#endif
 #include <QMouseEvent>
 
 #include "SVTK_SpaceMouse.h" 
@@ -414,10 +416,10 @@ QVTK_RenderWindowInteractor
 /*!
   To handle native Win32 events (from such devices as SpaceMouse)
 */
-bool QVTK_RenderWindowInteractor::winEvent( MSG* msg )
+bool QVTK_RenderWindowInteractor::winEvent( MSG* msg, long* result )
 {
   // TODO: Implement event handling for SpaceMouse
-  return QWidget::winEvent( msg );
+  return QWidget::winEvent( msg, result);
 }
 
 #else
index 51aa1ec5999cb752c57df896fe3fee3f570bce66..ab5f9c1827be14f456b2a888aa86515084f12308 100644 (file)
@@ -122,7 +122,7 @@ class SVTK_EXPORT QVTK_RenderWindowInteractor: public QWidget
 
   //! To handle native events (from such devices as SpaceMouse)
 #ifdef WIN32
-  virtual bool winEvent( MSG* );
+  virtual bool winEvent( MSG*, long* );
 #else
   virtual bool x11Event( XEvent *e );
 #endif
index 72a74fd3e211cb484d2da2a3b348b9588725a3e7..dc322b67995b6c242ae483b1ca75c8555aef0bee 100755 (executable)
@@ -64,6 +64,8 @@
 #include <SUIT_ResourceMgr.h>
 #include <SUIT_ExceptionHandler.h>
 
+#include <Standard_Version.hxx>
+
 /*! - read arguments, define list of server to launch with their arguments.
  * - wait for naming service
  * - create and run a thread for launch of all servers
index 88d2b3fadea10539425c9e94f136dd157920e779..089c223f06d0104932f41de3118d214f07407154 100755 (executable)
 #include "SALOME_Event.h"
 
 #include "SUIT_Session.h"
-//#include "SUIT_Application.h"
 #include "SUIT_Desktop.h"
 #include "SUIT_Study.h"
 
-//#include <QApplication>
 #include <QMutex>
 #include <QWaitCondition>
 
 #include <OSD_SharedLibrary.hxx>
 #include <OSD_Function.hxx>
 
+#ifdef WNT
+# include <process.h>
+#endif
+
+
 using namespace std;
 
 /*!
@@ -203,6 +206,15 @@ CORBA::Long SALOME_Session_i::GetActiveStudyId()
   return aStudyId;
 }
 
+CORBA::Long SALOME_Session_i::getPID() {
+  return (CORBA::Long)
+#ifndef WNT
+    getpid();
+#else
+    _getpid();
+#endif
+}
+
 bool SALOME_Session_i::restoreVisualState(CORBA::Long theSavePoint)
 {
   class TEvent: public SALOME_Event {
index efef52f60a3fda705e0e88c56a9af9bb68644eea..fc7a1e56e4f7cb7f55b275ff0231b15c6bd23b47 100755 (executable)
@@ -69,7 +69,7 @@ public:
   CORBA::Long GetActiveStudyId();
 
   void ping(){};
-  CORBA::Long getPID() { return (CORBA::Long)getpid(); };
+  CORBA::Long getPID();
 
   //! Restors a visual state of the study at theSavePoint
   bool restoreVisualState(CORBA::Long theSavePoint);