Changeset 11395:480384789e76 in orange


Ignore:
Timestamp:
03/12/13 13:49:27 (13 months ago)
Author:
Ales Erjavec <ales.erjavec@…>
Branch:
default
Message:

Replaced the use of PyOrange_AsGraphAsList, with a dynamic cast (fixed a linker error with msvc).

File:
1 edited

Legend:

Unmodified
Added
Removed
  • source/orangeom/network.cpp

    r10312 r11395  
    461461#include "orange_api.hpp" 
    462462WRAPPER(GraphAsList); 
     463 
    463464PyObject *Network_new(PyTypeObject *type, PyObject *args, PyObject *kwds) BASED_ON (GraphAsList, "(nVertices, directed[, nEdgeTypes])") 
    464465{ 
     
    488489        { 
    489490            //cout << "2" << endl; 
    490         TGraphAsList *graph = PyOrange_AsGraphAsList(pygraph).getUnwrappedPtr(); 
     491            TGraphAsList *graph = dynamic_cast<TGraphAsList *>(PyOrange_AsOrange(pygraph).getUnwrappedPtr()); 
    491492            TNetwork *network = mlnew TNetwork(graph); 
    492493             
Note: See TracChangeset for help on using the changeset viewer.