[Uml-devel] kdesdk/umbrello/umbrello

Oliver Kellogg okellogg at users.sourceforge.net
Wed May 26 22:01:09 UTC 2004


CVS commit by okellogg: 

Support multiply importing the same files (as promised in the ChangeLog :)


  M +15 -13    classimport.cpp   1.32


--- kdesdk/umbrello/umbrello/classimport.cpp  #1.31:1.32
@@ -38,17 +38,4 @@ ClassImport::ClassImport(UMLDoc * parent
         m_umldoc = parentDoc;
         m_driver = new CppDriver();
-        // Add some standard include paths
-        m_driver->addIncludePath( "/usr/include" );
-        m_driver->addIncludePath( "/usr/include/c++" );
-        m_driver->addIncludePath( "/usr/include/g++" );
-        m_driver->addIncludePath( "/usr/local/include" );
-        // FIXME: The following hack is to be replaced by a config menu in umbrello
-        char *umbrello_incpath = getenv( "UMBRELLO_INCPATH" );
-        if (umbrello_incpath) {
-                QStringList includes = QStringList::split( ':', umbrello_incpath );
-                for (QStringList::Iterator i = includes.begin();
-                                           i != includes.end(); i++)
-                        m_driver->addIncludePath( *i );
-        }
 }
 
@@ -197,4 +184,19 @@ void ClassImport::createGeneralization(U
 
 void ClassImport::importCPP(QStringList headerFileList) {
+        // Reset the driver
+        m_driver->reset();
+        // Add some standard include paths
+        m_driver->addIncludePath( "/usr/include" );
+        m_driver->addIncludePath( "/usr/include/c++" );
+        m_driver->addIncludePath( "/usr/include/g++" );
+        m_driver->addIncludePath( "/usr/local/include" );
+        // FIXME: The following hack is to be replaced by a config menu in umbrello
+        char *umbrello_incpath = getenv( "UMBRELLO_INCPATH" );
+        if (umbrello_incpath) {
+                QStringList includes = QStringList::split( ':', umbrello_incpath );
+                for (QStringList::Iterator i = includes.begin();
+                                           i != includes.end(); i++)
+                        m_driver->addIncludePath( *i );
+        }
         for (QStringList::Iterator fileIT = headerFileList.begin();
                                    fileIT != headerFileList.end(); ++fileIT) {






More information about the umbrello-devel mailing list