~ubuntu-branches/ubuntu/wily/ginkgocadx/wily-proposed

« back to all changes in this revision

Viewing changes to src/cadxcore/main/tools/resettool.cpp

  • Committer: Package Import Robot
  • Author(s): Dmitry Smirnov
  • Date: 2013-10-24 21:28:17 UTC
  • mfrom: (1.2.2)
  • Revision ID: package-import@ubuntu.com-20131024212817-ej1skb9og09d3ht6
Tags: 3.5.0.1137.31+dfsg-1
New upstream release [October 2013]

Show diffs side-by-side

added added

removed removed

Lines of Context:
3
3
 *  $Id: resettool.cpp $
4
4
 *  Ginkgo CADx Project
5
5
 *
6
 
 *  Copyright 2008-12 MetaEmotion S.L. All rights reserved.
 
6
 *  Copyright 2008-14 MetaEmotion S.L. All rights reserved.
7
7
 *  http://ginkgo-cadx.com
8
8
 *
9
9
 *  This file is licensed under LGPL v3 license.
13
13
 */
14
14
 
15
15
#include "resettool.h"
16
 
#if defined(ENABLE_RESETTOOL)
 
16
#if defined(ENABLE_RESETTOOL)
17
17
#include <export/contracts/iwidgetscontract.h>
18
18
#include <api/controllers/ieventscontroller.h>
19
 
#include <eventos/modificacionimagen.h>
20
 
#include <eventos/render.h>
 
19
#include <eventos/modificacionimagen.h>
 
20
#include <eventos/render.h>
21
21
#include <api/iwidgetsmanager.h>
22
22
 
23
23
 
37
37
#include <vtk/vtkginkgoimageviewer.h>
38
38
#include <resources/ginkgoresourcesmanager.h>
39
39
 
40
 
GNC::GCS::ITool* GNC::ResetTool::NewTool()
41
 
{
42
 
        return new GNC::ResetTool();
43
 
}
44
 
 
45
 
GNC::ResetTool::ResetTool()
46
 
{
47
 
}
48
 
GNC::ResetTool::~ResetTool()
49
 
{
50
 
}
51
 
                
52
 
bool GNC::ResetTool::ExecuteAction()
 
40
GNC::GCS::ITool* GNC::ResetTool::NewTool()
 
41
{
 
42
        return new GNC::ResetTool();
 
43
}
 
44
 
 
45
GNC::ResetTool::ResetTool()
 
46
{
 
47
}
 
48
GNC::ResetTool::~ResetTool()
 
49
{
 
50
}
 
51
                
 
52
bool GNC::ResetTool::ExecuteAction()
53
53
{       
54
54
        GNC::GCS::Events::EventoModificacionImagen* pEvt = new GNC::GCS::Events::EventoModificacionImagen(WidgetsContract->GetManager()->GetVista(),GNC::GCS::Events::EventoModificacionImagen::VisualizacionImagenModificada);
55
55
        pEvt->EnableResetWindowLevel();
 
56
        pEvt->EnableResetBrightnessContrast();
56
57
        pEvt->EnableResetCurrentPoint();
57
58
        pEvt->EnableResetZoom();
58
59
        GNC::GCS::IEventsController::Instance()->ProcesarEvento(pEvt);
59
60
        GNC::GCS::IEventsController::Instance()->ProcesarEvento(new GNC::GCS::Events::EventoRender(WidgetsContract->GetManager()->GetVista()));
60
61
        return true;
61
 
}
62
 
 
 
62
}
 
63
 
63
64
#endif
 
 
b'\\ No newline at end of file'