Skip to content

Commit 230edf7

Browse files
committed
improving scaling
1 parent 85329c0 commit 230edf7

File tree

4 files changed

+2
-14
lines changed

4 files changed

+2
-14
lines changed

CGTeaApp.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
#include "BasicDrawPane.h"
99

1010
class CGTeaApp: public wxApp {
11-
BasicDrawPane *drawPane;
11+
BasicDrawPane * drawPane = nullptr;
1212
public:
1313
bool OnInit() override;
1414
};

CGTeaFrame.cpp

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -202,9 +202,6 @@ void CGTeaFrame::OnFitWidth(wxCommandEvent& event)
202202
});
203203

204204
auto panelSize = this->GetSizer()->GetItem(1)->GetSize();
205-
cout << this->GetSizer()->GetItemCount();
206-
cout << panelSize.GetWidth() << endl;
207-
cout << panelSize.GetHeight() << endl;
208205
double padding = 40;
209206
double scaleX = (panelSize.GetWidth() - 2 * padding) / (maxX - minX);
210207
double scaleY = (panelSize.GetHeight() - 2 * padding) / (maxY - minY);

CGTeaSidebar.h

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -5,15 +5,8 @@
55
#ifndef CGTEA_CGTEASIDEBAR_H
66
#define CGTEA_CGTEASIDEBAR_H
77

8-
#include "datatypes.h"
9-
10-
#include <wx/wxprec.h>
118
#ifndef WX_PRECOMP
129
#include <wx/wx.h>
13-
#include <wx/sizer.h>
14-
#include <wx/dir.h>
15-
#include "datatypes.h"
16-
#include <string>
1710
#endif
1811

1912
#include "CGTeaFrame.h"

datatypes.h

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -7,11 +7,9 @@
77
#include "boost/cstdlib.hpp"
88
#include "boost/graph/topology.hpp"
99
#include <memory>
10-
#include <iostream>
1110
#include <fstream>
1211
#include <boost/dynamic_bitset.hpp>
1312
#include <random>
14-
#include "boost/graph/simple_point.hpp"
1513
#include "generators/point.h"
1614
#include <boost/graph/exterior_property.hpp>
1715

@@ -157,7 +155,7 @@ static void for_each_neighbor(const Ver& v, Graph& g, Lambda func) {
157155

158156
template<typename Lambda>
159157
static void for_each_out_edges(const Ver& v, Graph& g, Lambda func) {
160-
typename graph_traits < Graph >::out_edge_iterator ei, ei_end;
158+
graph_traits < Graph >::out_edge_iterator ei, ei_end;
161159
boost::tie(ei, ei_end) = out_edges(v, g);
162160
std::for_each(ei, ei_end, func);
163161
}

0 commit comments

Comments
 (0)