~ubuntu-branches/ubuntu/trusty/ginkgocadx/trusty

« back to all changes in this revision

Viewing changes to src/cadxcore/api/iwidgets.cpp

  • Committer: Package Import Robot
  • Author(s): Dmitry Smirnov
  • Date: 2013-07-21 11:58:53 UTC
  • mfrom: (1.2.1) (7.1.6 experimental)
  • mto: This revision was merged to the branch mainline in revision 14.
  • Revision ID: package-import@ubuntu.com-20130721115853-0aii5ee76hxm8z1f
* New upstream release [July 2013]
  + new B-D: "libjsoncpp-dev".
  + new patch "unbundle-libjsoncpp.patch" to avoid building bundled
    "libjsoncpp-dev".
  + new patch "fix-wx.patch" to avoid FTBFS due to missing
    "-lwx_gtk2u_html-2.8".
* Removed unnecessary versioned Build-Depends.
* Removed obsolete lintian override.
* Reference get-orig-source implementation for orig.tar clean-up and
  DFSG-repackaging.
* Upload to unstable.

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
1
/*
2
2
 *  
3
 
 *  $Id: iwidgets.cpp 4478 2011-12-13 11:55:00Z carlos $
 
3
 *  $Id: iwidgets.cpp $
4
4
 *  Ginkgo CADx Project
5
5
 *
6
 
 *  Copyright 2008-10 MetaEmotion S.L. All rights reserved.
 
6
 *  Copyright 2008-12 MetaEmotion S.L. All rights reserved.
7
7
 *  http://ginkgo-cadx.com
8
8
 *
9
9
 *  This file is licensed under LGPL v3 license.
20
20
#include <wx/propiedades/wxpropiedades.h>
21
21
 
22
22
#include <api/iwidgetsrenderer.h>
 
23
#include <api/internationalization/internationalization.h>
23
24
#include <vtk/vtkginkgoimageviewer.h>
24
25
 
25
26
#include <sstream>
32
33
        wxString strTmp = nodo->GetPropVal(wxT("x"),wxT("0.0"));
33
34
        double doubleTmp;
34
35
        strTmp.ToDouble(&doubleTmp);
35
 
        n.x = (TComponente) doubleTmp;
 
36
        n.x = (TComp) doubleTmp;
36
37
 
37
38
        strTmp = nodo->GetPropVal(wxT("y"),wxT("0.0"));
38
39
        strTmp.ToDouble(&doubleTmp);
39
 
        n.y = (TComponente) doubleTmp;
 
40
        n.y = (TComp) doubleTmp;
40
41
 
41
42
        strTmp = nodo->GetPropVal(wxT("size"),wxT("10.0"));
42
43
        strTmp.ToDouble(&doubleTmp);
242
243
        double wp[3];
243
244
        std::stringstream out;
244
245
        out.precision(3);
245
 
        const double ip[2] = {valor.x, valor.y};
 
246
        const double ip[3] = {valor.x, valor.y, m_pManager->GetRendererActivo()->m_pImageViewer->GetTindex()};
246
247
        m_pManager->GetRendererActivo()->m_pImageViewer->CoordenadasImagenACoordenadasMundo(ip, wp);
247
248
        out << "[ x = " << wp[0] << ", y = " << wp[1] << ", z=" << wp[2] << "  ]";
248
249
        return out.str();
294
295
                {
295
296
                        std::ostringstream ostr;
296
297
                        unsigned int i =0;
297
 
                        for(std::list<GNC::GCS::Vector>::iterator it = recorrido.begin(); it!= recorrido.end(); it++, i++) {
 
298
                        for(std::list<GNC::GCS::Vector>::iterator it = recorrido.begin(); it!= recorrido.end(); ++it, i++) {
298
299
                                ostr << PuntoToString((*it));
299
300
                                if((i+1) != recorrido.size())
300
301
                                        ostr << "," << std::endl;
304
305
                {
305
306
                        std::stringstream out;
306
307
                        unsigned int i =0;
307
 
                        for(std::list<GNC::GCS::Vector>::iterator it = recorrido.begin(); it!= recorrido.end(); it++, i++) {
 
308
                        for(std::list<GNC::GCS::Vector>::iterator it = recorrido.begin(); it!= recorrido.end(); ++it, i++) {
308
309
                                out << PuntoToStringMundo(*it);
309
310
                                if((i+1) != recorrido.size())
310
311
                                        out << "," << std::endl;
321
322
        InsertarPropiedades(listaMapas);
322
323
 
323
324
        //si es serializable...
324
 
        GNC::GCS::Widgets::IWidgetSerializable* pSerializable = dynamic_cast<GNC::GCS::Widgets::IWidgetSerializable*>(this);
 
325
/*      GNC::GCS::Widgets::IWidgetSerializable* pSerializable = dynamic_cast<GNC::GCS::Widgets::IWidgetSerializable*>(this);
325
326
        if(pSerializable != NULL) {
326
327
                listaMapas.push_back(pSerializable->GetPropiedades());
327
 
        }
 
328
        }*/
328
329
        GNC::GUI::wxPropiedades pProp(pParent,m_Nombre, listaMapas);
329
330
        pProp.ShowModal();
330
331