Changeset 8647:12ede5030f51 in orange


Ignore:
Timestamp:
08/10/11 12:47:55 (3 years ago)
Author:
miha <miha.stajdohar@…>
Branch:
default
Convert:
5175702fac2c59d63d37acb1702c45ac8d61928a
Message:

Fixed a bug when casting Python values.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • source/orangeplot/types.sip

    r8646 r8647  
    332332    { 
    333333        int k = SIPLong_AsLong(kobj); 
    334         double fst = (int)PyInt_AsLong(PyTuple_GET_ITEM(tobj,0)); 
    335         double sec = (int)PyInt_AsLong(PyTuple_GET_ITEM(tobj,1)); 
     334        double fst = PyFloat_AsDouble(PyTuple_GET_ITEM(tobj,0)); 
     335        double sec = PyFloat_AsDouble(PyTuple_GET_ITEM(tobj,1)); 
    336336         
    337337        QPair<double, double> t(fst,sec); 
Note: See TracChangeset for help on using the changeset viewer.